@databrainhq/plugin 0.7.15 → 0.7.17
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/components/Button/index.d.ts +8 -0
- package/dist/components/ChartModal/ChartConfig.d.ts +18 -0
- package/dist/components/ChartModal/ChartModalOptions.d.ts +6 -0
- package/dist/components/ChartModal/SelectField.d.ts +2 -0
- package/dist/components/ChartModal/index.d.ts +3 -0
- package/dist/components/Charts/AreaChart.d.ts +3 -0
- package/dist/components/Charts/BarChart.d.ts +24 -0
- package/dist/components/Charts/BoxPlot.d.ts +3 -0
- package/dist/components/Charts/BubbleChart.d.ts +3 -0
- package/dist/components/Charts/ComboChart.d.ts +3 -0
- package/dist/components/Charts/DoughnutChart.d.ts +3 -0
- package/dist/components/Charts/FunnelChart.d.ts +3 -0
- package/dist/components/Charts/GaugeChart.d.ts +3 -0
- package/dist/components/Charts/Histogram.d.ts +3 -0
- package/dist/components/Charts/LineChart.d.ts +25 -0
- package/dist/components/Charts/PieChart.d.ts +3 -0
- package/dist/components/Charts/RowChart.d.ts +3 -0
- package/dist/components/Charts/SankeyChart.d.ts +3 -0
- package/dist/components/Charts/ScatterChart.d.ts +3 -0
- package/dist/components/Charts/SingleValueChart/index.d.ts +3 -0
- package/dist/components/Charts/StackedBarChart.d.ts +3 -0
- package/dist/components/Charts/SteppedAreaChart.d.ts +3 -0
- package/dist/components/Charts/Table/TableChart.d.ts +3 -0
- package/dist/components/Charts/WaterfallChart.d.ts +3 -0
- package/dist/components/DataType/index.d.ts +7 -0
- package/dist/components/Error/index.d.ts +6 -0
- package/dist/components/ErrorFallback/index.d.ts +2 -0
- package/dist/components/ExternalMetricForm/index.d.ts +15 -0
- package/dist/components/FilterDropDown/index.d.ts +11 -0
- package/dist/components/FilterField/index.d.ts +21 -0
- package/dist/components/FloatingDropDown/index.d.ts +23 -0
- package/dist/components/FullScreenChart/index.d.ts +9 -0
- package/dist/components/GlobalFilters/index.d.ts +11 -0
- package/dist/components/Icons/index.d.ts +7 -0
- package/dist/components/InfoTooltip/index.d.ts +10 -0
- package/dist/components/InputField/index.d.ts +15 -0
- package/dist/components/MetricChart/CsvDownloadButton.d.ts +10 -0
- package/dist/components/MetricChart/MetricChart.d.ts +36 -0
- package/dist/components/MetricChart/index.d.ts +2 -0
- package/dist/components/MetricCreation/MetricCreation.d.ts +3 -0
- package/dist/components/MetricCreation/components/ConstructMetric/ConstructMetric.d.ts +3 -0
- package/dist/components/MetricCreation/components/ConstructMetric/components/MetricForm/index.d.ts +3 -0
- package/dist/components/MetricCreation/components/ConstructMetric/index.d.ts +2 -0
- package/dist/components/MetricCreation/components/Dataset/index.d.ts +3 -0
- package/dist/components/MetricCreation/components/Header/index.d.ts +3 -0
- package/dist/components/MetricCreation/components/MetricOutput/MetricOutput.d.ts +3 -0
- package/dist/components/MetricCreation/components/MetricOutput/components/ChartTab/components/ChartConfigure/index.d.ts +20 -0
- package/dist/components/MetricCreation/components/MetricOutput/components/ChartTab/components/ChartSettings/index.d.ts +32 -0
- package/dist/components/MetricCreation/components/MetricOutput/components/ChartTab/index.d.ts +50 -0
- package/dist/components/MetricCreation/components/MetricOutput/components/TableTab/components/InputTables/index.d.ts +2 -0
- package/dist/components/MetricCreation/components/MetricOutput/components/TableTab/index.d.ts +9 -0
- package/dist/components/MetricCreation/components/MetricOutput/index.d.ts +3 -0
- package/dist/components/MetricCreation/index.d.ts +5 -0
- package/dist/components/MetricList/MetricList.d.ts +45 -0
- package/dist/components/MetricList/components/MetricCard.d.ts +18 -0
- package/dist/components/MetricList/components/SingleValueCard.d.ts +3 -0
- package/dist/components/MetricList/index.d.ts +3 -0
- package/dist/components/MetricTable/index.d.ts +7 -0
- package/dist/components/Modal/Modal.d.ts +9 -0
- package/dist/components/Modal/ModalFooter.d.ts +5 -0
- package/dist/components/Modal/index.d.ts +2 -0
- package/dist/components/PopoverMenu/index.d.ts +11 -0
- package/dist/components/SearchTab/index.d.ts +2 -0
- package/dist/components/Select/index.d.ts +48 -0
- package/dist/components/Tab/index.d.ts +10 -0
- package/dist/components/Table/index.d.ts +8 -0
- package/dist/components/Text/index.d.ts +11 -0
- package/dist/components/TextAreaField/index.d.ts +19 -0
- package/dist/components/TimeGrainField/index.d.ts +13 -0
- package/dist/components/ToggleButton/index.d.ts +12 -0
- package/dist/components/index.d.ts +28 -0
- package/dist/consts/app.d.ts +39 -0
- package/dist/consts/index.d.ts +2 -0
- package/dist/consts/metricOptions.d.ts +17 -0
- package/dist/containers/Dashboard/Dashboard.d.ts +6 -0
- package/dist/containers/Dashboard/EmbededDashboard.d.ts +12 -0
- package/dist/containers/Dashboard/index.d.ts +2 -0
- package/dist/containers/index.d.ts +1 -0
- package/dist/contexts/globalTheme.d.ts +9 -0
- package/dist/helpers/cardActions.d.ts +4 -0
- package/dist/helpers/getModifiedQuery.d.ts +6 -0
- package/dist/helpers/getTimeFilterValue.d.ts +8 -0
- package/dist/helpers/groupArray.d.ts +1 -0
- package/dist/helpers/groupBy.d.ts +6 -0
- package/dist/helpers/index.d.ts +4 -0
- package/dist/hooks/index.d.ts +5 -0
- package/dist/hooks/useEmbeddedDashboard.d.ts +53 -0
- package/dist/hooks/useExternalMetric.d.ts +39 -0
- package/dist/hooks/useGenerateDatasetMetrics.d.ts +13 -0
- package/dist/hooks/useGenerateEmbeddedMetric.d.ts +15 -0
- package/dist/hooks/useOutsideAlerter.d.ts +7 -0
- package/dist/index.d.ts +7 -0
- package/dist/index.es.js +91915 -0
- package/dist/index.umd.js +340 -0
- package/dist/style.css +1 -0
- package/dist/types/app.d.ts +132 -0
- package/dist/types/index.d.ts +2 -0
- package/dist/types/metricCreate.d.ts +132 -0
- package/dist/typings.d.ts +17 -0
- package/dist/utils/arrayToCsvString.d.ts +6 -0
- package/dist/utils/colors.d.ts +1 -0
- package/dist/utils/fetcher.d.ts +1 -0
- package/dist/utils/generated/graphql.d.ts +1863 -0
- package/dist/utils/getChartAttributes.d.ts +27 -0
- package/dist/utils/getFormattedDataType.d.ts +1 -0
- package/dist/utils/index.d.ts +5 -0
- package/dist/utils/theme.d.ts +87 -0
- package/package.json +3 -2
|
@@ -0,0 +1,340 @@
|
|
|
1
|
+
(function(Cr,R){typeof exports=="object"&&typeof module!="undefined"?R(exports,require("react"),require("react-dom")):typeof define=="function"&&define.amd?define(["exports","react","react-dom"],R):(Cr=typeof globalThis!="undefined"?globalThis:Cr||self,R(Cr.Databrain={},Cr.React,Cr.ReactDOM))})(this,function(Cr,R,Hj){"use strict";function Jw(r){return r&&typeof r=="object"&&"default"in r?r:{default:r}}function Wj(r){if(r&&r.__esModule)return r;var e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});return r&&Object.keys(r).forEach(function(t){if(t!=="default"){var n=Object.getOwnPropertyDescriptor(r,t);Object.defineProperty(e,t,n.get?n:{enumerable:!0,get:function(){return r[t]}})}}),e.default=r,Object.freeze(e)}var by=Wj(R),pe=Jw(R),Fh=Jw(Hj);function My(r,e){return My=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,a){return n.__proto__=a,n},My(r,e)}function jo(r,e){r.prototype=Object.create(e.prototype),r.prototype.constructor=r,My(r,e)}var Gj=function(e,t){return e===void 0&&(e=[]),t===void 0&&(t=[]),e.length!==t.length||e.some(function(n,a){return!Object.is(n,t[a])})},Kw={error:null},$j=function(r){jo(e,r);function e(){for(var n,a=arguments.length,i=new Array(a),o=0;o<a;o++)i[o]=arguments[o];return n=r.call.apply(r,[this].concat(i))||this,n.state=Kw,n.resetErrorBoundary=function(){for(var s,l=arguments.length,u=new Array(l),c=0;c<l;c++)u[c]=arguments[c];n.props.onReset==null||(s=n.props).onReset.apply(s,u),n.reset()},n}e.getDerivedStateFromError=function(a){return{error:a}};var t=e.prototype;return t.reset=function(){this.setState(Kw)},t.componentDidCatch=function(a,i){var o,s;(o=(s=this.props).onError)==null||o.call(s,a,i)},t.componentDidUpdate=function(a,i){var o=this.state.error,s=this.props.resetKeys;if(o!==null&&i.error!==null&&Gj(a.resetKeys,s)){var l,u;(l=(u=this.props).onResetKeysChange)==null||l.call(u,a.resetKeys,s),this.reset()}},t.render=function(){var a=this.state.error,i=this.props,o=i.fallbackRender,s=i.FallbackComponent,l=i.fallback;if(a!==null){var u={error:a,resetErrorBoundary:this.resetErrorBoundary};if(by.isValidElement(l))return l;if(typeof o=="function")return o(u);if(s)return by.createElement(s,u);throw new Error("react-error-boundary requires either a fallback, fallbackRender, or FallbackComponent prop")}return this.props.children},e}(by.Component),Ml=function(){function r(){this.listeners=[]}var e=r.prototype;return e.subscribe=function(n){var a=this,i=n||function(){};return this.listeners.push(i),this.onSubscribe(),function(){a.listeners=a.listeners.filter(function(o){return o!==i}),a.onUnsubscribe()}},e.hasListeners=function(){return this.listeners.length>0},e.onSubscribe=function(){},e.onUnsubscribe=function(){},r}();function Je(){return Je=Object.assign?Object.assign.bind():function(r){for(var e=1;e<arguments.length;e++){var t=arguments[e];for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(r[n]=t[n])}return r},Je.apply(this,arguments)}var Vh=typeof window=="undefined";function mr(){}function Uj(r,e){return typeof r=="function"?r(e):r}function xy(r){return typeof r=="number"&&r>=0&&r!==1/0}function Hh(r){return Array.isArray(r)?r:[r]}function eD(r,e){return Math.max(r+(e||0)-Date.now(),0)}function Wh(r,e,t){return ac(r)?typeof e=="function"?Je({},t,{queryKey:r,queryFn:e}):Je({},e,{queryKey:r}):r}function Yj(r,e,t){return ac(r)?typeof e=="function"?Je({},t,{mutationKey:r,mutationFn:e}):Je({},e,{mutationKey:r}):typeof r=="function"?Je({},e,{mutationFn:r}):Je({},r)}function Fi(r,e,t){return ac(r)?[Je({},e,{queryKey:r}),t]:[r||{},e]}function Qj(r,e){if(r===!0&&e===!0||r==null&&e==null)return"all";if(r===!1&&e===!1)return"none";var t=r!=null?r:!e;return t?"active":"inactive"}function tD(r,e){var t=r.active,n=r.exact,a=r.fetching,i=r.inactive,o=r.predicate,s=r.queryKey,l=r.stale;if(ac(s)){if(n){if(e.queryHash!==wy(s,e.options))return!1}else if(!Gh(e.queryKey,s))return!1}var u=Qj(t,i);if(u==="none")return!1;if(u!=="all"){var c=e.isActive();if(u==="active"&&!c||u==="inactive"&&c)return!1}return!(typeof l=="boolean"&&e.isStale()!==l||typeof a=="boolean"&&e.isFetching()!==a||o&&!o(e))}function rD(r,e){var t=r.exact,n=r.fetching,a=r.predicate,i=r.mutationKey;if(ac(i)){if(!e.options.mutationKey)return!1;if(t){if(Bo(e.options.mutationKey)!==Bo(i))return!1}else if(!Gh(e.options.mutationKey,i))return!1}return!(typeof n=="boolean"&&e.state.status==="loading"!==n||a&&!a(e))}function wy(r,e){var t=(e==null?void 0:e.queryKeyHashFn)||Bo;return t(r)}function Bo(r){var e=Hh(r);return Zj(e)}function Zj(r){return JSON.stringify(r,function(e,t){return Dy(t)?Object.keys(t).sort().reduce(function(n,a){return n[a]=t[a],n},{}):t})}function Gh(r,e){return nD(Hh(r),Hh(e))}function nD(r,e){return r===e?!0:typeof r!=typeof e?!1:r&&e&&typeof r=="object"&&typeof e=="object"?!Object.keys(e).some(function(t){return!nD(r[t],e[t])}):!1}function $h(r,e){if(r===e)return r;var t=Array.isArray(r)&&Array.isArray(e);if(t||Dy(r)&&Dy(e)){for(var n=t?r.length:Object.keys(r).length,a=t?e:Object.keys(e),i=a.length,o=t?[]:{},s=0,l=0;l<i;l++){var u=t?l:a[l];o[u]=$h(r[u],e[u]),o[u]===r[u]&&s++}return n===i&&s===n?r:o}return e}function qj(r,e){if(r&&!e||e&&!r)return!1;for(var t in r)if(r[t]!==e[t])return!1;return!0}function Dy(r){if(!aD(r))return!1;var e=r.constructor;if(typeof e=="undefined")return!0;var t=e.prototype;return!(!aD(t)||!t.hasOwnProperty("isPrototypeOf"))}function aD(r){return Object.prototype.toString.call(r)==="[object Object]"}function ac(r){return typeof r=="string"||Array.isArray(r)}function Xj(r){return new Promise(function(e){setTimeout(e,r)})}function iD(r){Promise.resolve().then(r).catch(function(e){return setTimeout(function(){throw e})})}function oD(){if(typeof AbortController=="function")return new AbortController}var Jj=function(r){jo(e,r);function e(){var n;return n=r.call(this)||this,n.setup=function(a){var i;if(!Vh&&((i=window)==null?void 0:i.addEventListener)){var o=function(){return a()};return window.addEventListener("visibilitychange",o,!1),window.addEventListener("focus",o,!1),function(){window.removeEventListener("visibilitychange",o),window.removeEventListener("focus",o)}}},n}var t=e.prototype;return t.onSubscribe=function(){this.cleanup||this.setEventListener(this.setup)},t.onUnsubscribe=function(){if(!this.hasListeners()){var a;(a=this.cleanup)==null||a.call(this),this.cleanup=void 0}},t.setEventListener=function(a){var i,o=this;this.setup=a,(i=this.cleanup)==null||i.call(this),this.cleanup=a(function(s){typeof s=="boolean"?o.setFocused(s):o.onFocus()})},t.setFocused=function(a){this.focused=a,a&&this.onFocus()},t.onFocus=function(){this.listeners.forEach(function(a){a()})},t.isFocused=function(){return typeof this.focused=="boolean"?this.focused:typeof document=="undefined"?!0:[void 0,"visible","prerender"].includes(document.visibilityState)},e}(Ml),ic=new Jj,Kj=function(r){jo(e,r);function e(){var n;return n=r.call(this)||this,n.setup=function(a){var i;if(!Vh&&((i=window)==null?void 0:i.addEventListener)){var o=function(){return a()};return window.addEventListener("online",o,!1),window.addEventListener("offline",o,!1),function(){window.removeEventListener("online",o),window.removeEventListener("offline",o)}}},n}var t=e.prototype;return t.onSubscribe=function(){this.cleanup||this.setEventListener(this.setup)},t.onUnsubscribe=function(){if(!this.hasListeners()){var a;(a=this.cleanup)==null||a.call(this),this.cleanup=void 0}},t.setEventListener=function(a){var i,o=this;this.setup=a,(i=this.cleanup)==null||i.call(this),this.cleanup=a(function(s){typeof s=="boolean"?o.setOnline(s):o.onOnline()})},t.setOnline=function(a){this.online=a,a&&this.onOnline()},t.onOnline=function(){this.listeners.forEach(function(a){a()})},t.isOnline=function(){return typeof this.online=="boolean"?this.online:typeof navigator=="undefined"||typeof navigator.onLine=="undefined"?!0:navigator.onLine},e}(Ml),Uh=new Kj;function e5(r){return Math.min(1e3*Math.pow(2,r),3e4)}function Yh(r){return typeof(r==null?void 0:r.cancel)=="function"}var sD=function(e){this.revert=e==null?void 0:e.revert,this.silent=e==null?void 0:e.silent};function Qh(r){return r instanceof sD}var lD=function(e){var t=this,n=!1,a,i,o,s;this.abort=e.abort,this.cancel=function(h){return a==null?void 0:a(h)},this.cancelRetry=function(){n=!0},this.continueRetry=function(){n=!1},this.continue=function(){return i==null?void 0:i()},this.failureCount=0,this.isPaused=!1,this.isResolved=!1,this.isTransportCancelable=!1,this.promise=new Promise(function(h,v){o=h,s=v});var l=function(v){t.isResolved||(t.isResolved=!0,e.onSuccess==null||e.onSuccess(v),i==null||i(),o(v))},u=function(v){t.isResolved||(t.isResolved=!0,e.onError==null||e.onError(v),i==null||i(),s(v))},c=function(){return new Promise(function(v){i=v,t.isPaused=!0,e.onPause==null||e.onPause()}).then(function(){i=void 0,t.isPaused=!1,e.onContinue==null||e.onContinue()})},f=function h(){if(!t.isResolved){var v;try{v=e.fn()}catch(d){v=Promise.reject(d)}a=function(p){if(!t.isResolved&&(u(new sD(p)),t.abort==null||t.abort(),Yh(v)))try{v.cancel()}catch{}},t.isTransportCancelable=Yh(v),Promise.resolve(v).then(l).catch(function(d){var p,g;if(!t.isResolved){var y=(p=e.retry)!=null?p:3,m=(g=e.retryDelay)!=null?g:e5,_=typeof m=="function"?m(t.failureCount,d):m,b=y===!0||typeof y=="number"&&t.failureCount<y||typeof y=="function"&&y(t.failureCount,d);if(n||!b){u(d);return}t.failureCount++,e.onFail==null||e.onFail(t.failureCount,d),Xj(_).then(function(){if(!ic.isFocused()||!Uh.isOnline())return c()}).then(function(){n?u(d):h()})}})}};f()},t5=function(){function r(){this.queue=[],this.transactions=0,this.notifyFn=function(t){t()},this.batchNotifyFn=function(t){t()}}var e=r.prototype;return e.batch=function(n){var a;this.transactions++;try{a=n()}finally{this.transactions--,this.transactions||this.flush()}return a},e.schedule=function(n){var a=this;this.transactions?this.queue.push(n):iD(function(){a.notifyFn(n)})},e.batchCalls=function(n){var a=this;return function(){for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];a.schedule(function(){n.apply(void 0,o)})}},e.flush=function(){var n=this,a=this.queue;this.queue=[],a.length&&iD(function(){n.batchNotifyFn(function(){a.forEach(function(i){n.notifyFn(i)})})})},e.setNotifyFunction=function(n){this.notifyFn=n},e.setBatchNotifyFunction=function(n){this.batchNotifyFn=n},r}(),Tt=new t5,uD=console;function Zh(){return uD}function r5(r){uD=r}var n5=function(){function r(t){this.abortSignalConsumed=!1,this.hadObservers=!1,this.defaultOptions=t.defaultOptions,this.setOptions(t.options),this.observers=[],this.cache=t.cache,this.queryKey=t.queryKey,this.queryHash=t.queryHash,this.initialState=t.state||this.getDefaultState(this.options),this.state=this.initialState,this.meta=t.meta,this.scheduleGc()}var e=r.prototype;return e.setOptions=function(n){var a;this.options=Je({},this.defaultOptions,n),this.meta=n==null?void 0:n.meta,this.cacheTime=Math.max(this.cacheTime||0,(a=this.options.cacheTime)!=null?a:5*60*1e3)},e.setDefaultOptions=function(n){this.defaultOptions=n},e.scheduleGc=function(){var n=this;this.clearGcTimeout(),xy(this.cacheTime)&&(this.gcTimeout=setTimeout(function(){n.optionalRemove()},this.cacheTime))},e.clearGcTimeout=function(){this.gcTimeout&&(clearTimeout(this.gcTimeout),this.gcTimeout=void 0)},e.optionalRemove=function(){this.observers.length||(this.state.isFetching?this.hadObservers&&this.scheduleGc():this.cache.remove(this))},e.setData=function(n,a){var i,o,s=this.state.data,l=Uj(n,s);return(i=(o=this.options).isDataEqual)!=null&&i.call(o,s,l)?l=s:this.options.structuralSharing!==!1&&(l=$h(s,l)),this.dispatch({data:l,type:"success",dataUpdatedAt:a==null?void 0:a.updatedAt}),l},e.setState=function(n,a){this.dispatch({type:"setState",state:n,setStateOptions:a})},e.cancel=function(n){var a,i=this.promise;return(a=this.retryer)==null||a.cancel(n),i?i.then(mr).catch(mr):Promise.resolve()},e.destroy=function(){this.clearGcTimeout(),this.cancel({silent:!0})},e.reset=function(){this.destroy(),this.setState(this.initialState)},e.isActive=function(){return this.observers.some(function(n){return n.options.enabled!==!1})},e.isFetching=function(){return this.state.isFetching},e.isStale=function(){return this.state.isInvalidated||!this.state.dataUpdatedAt||this.observers.some(function(n){return n.getCurrentResult().isStale})},e.isStaleByTime=function(n){return n===void 0&&(n=0),this.state.isInvalidated||!this.state.dataUpdatedAt||!eD(this.state.dataUpdatedAt,n)},e.onFocus=function(){var n,a=this.observers.find(function(i){return i.shouldFetchOnWindowFocus()});a&&a.refetch(),(n=this.retryer)==null||n.continue()},e.onOnline=function(){var n,a=this.observers.find(function(i){return i.shouldFetchOnReconnect()});a&&a.refetch(),(n=this.retryer)==null||n.continue()},e.addObserver=function(n){this.observers.indexOf(n)===-1&&(this.observers.push(n),this.hadObservers=!0,this.clearGcTimeout(),this.cache.notify({type:"observerAdded",query:this,observer:n}))},e.removeObserver=function(n){this.observers.indexOf(n)!==-1&&(this.observers=this.observers.filter(function(a){return a!==n}),this.observers.length||(this.retryer&&(this.retryer.isTransportCancelable||this.abortSignalConsumed?this.retryer.cancel({revert:!0}):this.retryer.cancelRetry()),this.cacheTime?this.scheduleGc():this.cache.remove(this)),this.cache.notify({type:"observerRemoved",query:this,observer:n}))},e.getObserversCount=function(){return this.observers.length},e.invalidate=function(){this.state.isInvalidated||this.dispatch({type:"invalidate"})},e.fetch=function(n,a){var i=this,o,s,l;if(this.state.isFetching){if(this.state.dataUpdatedAt&&(a==null?void 0:a.cancelRefetch))this.cancel({silent:!0});else if(this.promise){var u;return(u=this.retryer)==null||u.continueRetry(),this.promise}}if(n&&this.setOptions(n),!this.options.queryFn){var c=this.observers.find(function(m){return m.options.queryFn});c&&this.setOptions(c.options)}var f=Hh(this.queryKey),h=oD(),v={queryKey:f,pageParam:void 0,meta:this.meta};Object.defineProperty(v,"signal",{enumerable:!0,get:function(){if(h)return i.abortSignalConsumed=!0,h.signal}});var d=function(){return i.options.queryFn?(i.abortSignalConsumed=!1,i.options.queryFn(v)):Promise.reject("Missing queryFn")},p={fetchOptions:a,options:this.options,queryKey:f,state:this.state,fetchFn:d,meta:this.meta};if((o=this.options.behavior)!=null&&o.onFetch){var g;(g=this.options.behavior)==null||g.onFetch(p)}if(this.revertState=this.state,!this.state.isFetching||this.state.fetchMeta!==((s=p.fetchOptions)==null?void 0:s.meta)){var y;this.dispatch({type:"fetch",meta:(y=p.fetchOptions)==null?void 0:y.meta})}return this.retryer=new lD({fn:p.fetchFn,abort:h==null||(l=h.abort)==null?void 0:l.bind(h),onSuccess:function(_){i.setData(_),i.cache.config.onSuccess==null||i.cache.config.onSuccess(_,i),i.cacheTime===0&&i.optionalRemove()},onError:function(_){Qh(_)&&_.silent||i.dispatch({type:"error",error:_}),Qh(_)||(i.cache.config.onError==null||i.cache.config.onError(_,i),Zh().error(_)),i.cacheTime===0&&i.optionalRemove()},onFail:function(){i.dispatch({type:"failed"})},onPause:function(){i.dispatch({type:"pause"})},onContinue:function(){i.dispatch({type:"continue"})},retry:p.options.retry,retryDelay:p.options.retryDelay}),this.promise=this.retryer.promise,this.promise},e.dispatch=function(n){var a=this;this.state=this.reducer(this.state,n),Tt.batch(function(){a.observers.forEach(function(i){i.onQueryUpdate(n)}),a.cache.notify({query:a,type:"queryUpdated",action:n})})},e.getDefaultState=function(n){var a=typeof n.initialData=="function"?n.initialData():n.initialData,i=typeof n.initialData!="undefined",o=i?typeof n.initialDataUpdatedAt=="function"?n.initialDataUpdatedAt():n.initialDataUpdatedAt:0,s=typeof a!="undefined";return{data:a,dataUpdateCount:0,dataUpdatedAt:s?o!=null?o:Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchMeta:null,isFetching:!1,isInvalidated:!1,isPaused:!1,status:s?"success":"idle"}},e.reducer=function(n,a){var i,o;switch(a.type){case"failed":return Je({},n,{fetchFailureCount:n.fetchFailureCount+1});case"pause":return Je({},n,{isPaused:!0});case"continue":return Je({},n,{isPaused:!1});case"fetch":return Je({},n,{fetchFailureCount:0,fetchMeta:(i=a.meta)!=null?i:null,isFetching:!0,isPaused:!1},!n.dataUpdatedAt&&{error:null,status:"loading"});case"success":return Je({},n,{data:a.data,dataUpdateCount:n.dataUpdateCount+1,dataUpdatedAt:(o=a.dataUpdatedAt)!=null?o:Date.now(),error:null,fetchFailureCount:0,isFetching:!1,isInvalidated:!1,isPaused:!1,status:"success"});case"error":var s=a.error;return Qh(s)&&s.revert&&this.revertState?Je({},this.revertState):Je({},n,{error:s,errorUpdateCount:n.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:n.fetchFailureCount+1,isFetching:!1,isPaused:!1,status:"error"});case"invalidate":return Je({},n,{isInvalidated:!0});case"setState":return Je({},n,a.state);default:return n}},r}(),a5=function(r){jo(e,r);function e(n){var a;return a=r.call(this)||this,a.config=n||{},a.queries=[],a.queriesMap={},a}var t=e.prototype;return t.build=function(a,i,o){var s,l=i.queryKey,u=(s=i.queryHash)!=null?s:wy(l,i),c=this.get(u);return c||(c=new n5({cache:this,queryKey:l,queryHash:u,options:a.defaultQueryOptions(i),state:o,defaultOptions:a.getQueryDefaults(l),meta:i.meta}),this.add(c)),c},t.add=function(a){this.queriesMap[a.queryHash]||(this.queriesMap[a.queryHash]=a,this.queries.push(a),this.notify({type:"queryAdded",query:a}))},t.remove=function(a){var i=this.queriesMap[a.queryHash];i&&(a.destroy(),this.queries=this.queries.filter(function(o){return o!==a}),i===a&&delete this.queriesMap[a.queryHash],this.notify({type:"queryRemoved",query:a}))},t.clear=function(){var a=this;Tt.batch(function(){a.queries.forEach(function(i){a.remove(i)})})},t.get=function(a){return this.queriesMap[a]},t.getAll=function(){return this.queries},t.find=function(a,i){var o=Fi(a,i),s=o[0];return typeof s.exact=="undefined"&&(s.exact=!0),this.queries.find(function(l){return tD(s,l)})},t.findAll=function(a,i){var o=Fi(a,i),s=o[0];return Object.keys(s).length>0?this.queries.filter(function(l){return tD(s,l)}):this.queries},t.notify=function(a){var i=this;Tt.batch(function(){i.listeners.forEach(function(o){o(a)})})},t.onFocus=function(){var a=this;Tt.batch(function(){a.queries.forEach(function(i){i.onFocus()})})},t.onOnline=function(){var a=this;Tt.batch(function(){a.queries.forEach(function(i){i.onOnline()})})},e}(Ml),i5=function(){function r(t){this.options=Je({},t.defaultOptions,t.options),this.mutationId=t.mutationId,this.mutationCache=t.mutationCache,this.observers=[],this.state=t.state||cD(),this.meta=t.meta}var e=r.prototype;return e.setState=function(n){this.dispatch({type:"setState",state:n})},e.addObserver=function(n){this.observers.indexOf(n)===-1&&this.observers.push(n)},e.removeObserver=function(n){this.observers=this.observers.filter(function(a){return a!==n})},e.cancel=function(){return this.retryer?(this.retryer.cancel(),this.retryer.promise.then(mr).catch(mr)):Promise.resolve()},e.continue=function(){return this.retryer?(this.retryer.continue(),this.retryer.promise):this.execute()},e.execute=function(){var n=this,a,i=this.state.status==="loading",o=Promise.resolve();return i||(this.dispatch({type:"loading",variables:this.options.variables}),o=o.then(function(){n.mutationCache.config.onMutate==null||n.mutationCache.config.onMutate(n.state.variables,n)}).then(function(){return n.options.onMutate==null?void 0:n.options.onMutate(n.state.variables)}).then(function(s){s!==n.state.context&&n.dispatch({type:"loading",context:s,variables:n.state.variables})})),o.then(function(){return n.executeMutation()}).then(function(s){a=s,n.mutationCache.config.onSuccess==null||n.mutationCache.config.onSuccess(a,n.state.variables,n.state.context,n)}).then(function(){return n.options.onSuccess==null?void 0:n.options.onSuccess(a,n.state.variables,n.state.context)}).then(function(){return n.options.onSettled==null?void 0:n.options.onSettled(a,null,n.state.variables,n.state.context)}).then(function(){return n.dispatch({type:"success",data:a}),a}).catch(function(s){return n.mutationCache.config.onError==null||n.mutationCache.config.onError(s,n.state.variables,n.state.context,n),Zh().error(s),Promise.resolve().then(function(){return n.options.onError==null?void 0:n.options.onError(s,n.state.variables,n.state.context)}).then(function(){return n.options.onSettled==null?void 0:n.options.onSettled(void 0,s,n.state.variables,n.state.context)}).then(function(){throw n.dispatch({type:"error",error:s}),s})})},e.executeMutation=function(){var n=this,a;return this.retryer=new lD({fn:function(){return n.options.mutationFn?n.options.mutationFn(n.state.variables):Promise.reject("No mutationFn found")},onFail:function(){n.dispatch({type:"failed"})},onPause:function(){n.dispatch({type:"pause"})},onContinue:function(){n.dispatch({type:"continue"})},retry:(a=this.options.retry)!=null?a:0,retryDelay:this.options.retryDelay}),this.retryer.promise},e.dispatch=function(n){var a=this;this.state=o5(this.state,n),Tt.batch(function(){a.observers.forEach(function(i){i.onMutationUpdate(n)}),a.mutationCache.notify(a)})},r}();function cD(){return{context:void 0,data:void 0,error:null,failureCount:0,isPaused:!1,status:"idle",variables:void 0}}function o5(r,e){switch(e.type){case"failed":return Je({},r,{failureCount:r.failureCount+1});case"pause":return Je({},r,{isPaused:!0});case"continue":return Je({},r,{isPaused:!1});case"loading":return Je({},r,{context:e.context,data:void 0,error:null,isPaused:!1,status:"loading",variables:e.variables});case"success":return Je({},r,{data:e.data,error:null,status:"success",isPaused:!1});case"error":return Je({},r,{data:void 0,error:e.error,failureCount:r.failureCount+1,isPaused:!1,status:"error"});case"setState":return Je({},r,e.state);default:return r}}var s5=function(r){jo(e,r);function e(n){var a;return a=r.call(this)||this,a.config=n||{},a.mutations=[],a.mutationId=0,a}var t=e.prototype;return t.build=function(a,i,o){var s=new i5({mutationCache:this,mutationId:++this.mutationId,options:a.defaultMutationOptions(i),state:o,defaultOptions:i.mutationKey?a.getMutationDefaults(i.mutationKey):void 0,meta:i.meta});return this.add(s),s},t.add=function(a){this.mutations.push(a),this.notify(a)},t.remove=function(a){this.mutations=this.mutations.filter(function(i){return i!==a}),a.cancel(),this.notify(a)},t.clear=function(){var a=this;Tt.batch(function(){a.mutations.forEach(function(i){a.remove(i)})})},t.getAll=function(){return this.mutations},t.find=function(a){return typeof a.exact=="undefined"&&(a.exact=!0),this.mutations.find(function(i){return rD(a,i)})},t.findAll=function(a){return this.mutations.filter(function(i){return rD(a,i)})},t.notify=function(a){var i=this;Tt.batch(function(){i.listeners.forEach(function(o){o(a)})})},t.onFocus=function(){this.resumePausedMutations()},t.onOnline=function(){this.resumePausedMutations()},t.resumePausedMutations=function(){var a=this.mutations.filter(function(i){return i.state.isPaused});return Tt.batch(function(){return a.reduce(function(i,o){return i.then(function(){return o.continue().catch(mr)})},Promise.resolve())})},e}(Ml);function l5(){return{onFetch:function(e){e.fetchFn=function(){var t,n,a,i,o,s,l=(t=e.fetchOptions)==null||(n=t.meta)==null?void 0:n.refetchPage,u=(a=e.fetchOptions)==null||(i=a.meta)==null?void 0:i.fetchMore,c=u==null?void 0:u.pageParam,f=(u==null?void 0:u.direction)==="forward",h=(u==null?void 0:u.direction)==="backward",v=((o=e.state.data)==null?void 0:o.pages)||[],d=((s=e.state.data)==null?void 0:s.pageParams)||[],p=oD(),g=p==null?void 0:p.signal,y=d,m=!1,_=e.options.queryFn||function(){return Promise.reject("Missing queryFn")},b=function(E,O,P,H){return y=H?[O].concat(y):[].concat(y,[O]),H?[P].concat(E):[].concat(E,[P])},x=function(E,O,P,H){if(m)return Promise.reject("Cancelled");if(typeof P=="undefined"&&!O&&E.length)return Promise.resolve(E);var F={queryKey:e.queryKey,signal:g,pageParam:P,meta:e.meta},G=_(F),Z=Promise.resolve(G).then(function(V){return b(E,P,V,H)});if(Yh(G)){var te=Z;te.cancel=G.cancel}return Z},M;if(!v.length)M=x([]);else if(f){var w=typeof c!="undefined",D=w?c:fD(e.options,v);M=x(v,w,D)}else if(h){var T=typeof c!="undefined",I=T?c:u5(e.options,v);M=x(v,T,I,!0)}else(function(){y=[];var L=typeof e.options.getNextPageParam=="undefined",E=l&&v[0]?l(v[0],0,v):!0;M=E?x([],L,d[0]):Promise.resolve(b([],d[0],v[0]));for(var O=function(F){M=M.then(function(G){var Z=l&&v[F]?l(v[F],F,v):!0;if(Z){var te=L?d[F]:fD(e.options,G);return x(G,L,te)}return Promise.resolve(b(G,d[F],v[F]))})},P=1;P<v.length;P++)O(P)})();var A=M.then(function(L){return{pages:L,pageParams:y}}),N=A;return N.cancel=function(){m=!0,p==null||p.abort(),Yh(M)&&M.cancel()},A}}}}function fD(r,e){return r.getNextPageParam==null?void 0:r.getNextPageParam(e[e.length-1],e)}function u5(r,e){return r.getPreviousPageParam==null?void 0:r.getPreviousPageParam(e[0],e)}var c5=function(){function r(t){t===void 0&&(t={}),this.queryCache=t.queryCache||new a5,this.mutationCache=t.mutationCache||new s5,this.defaultOptions=t.defaultOptions||{},this.queryDefaults=[],this.mutationDefaults=[]}var e=r.prototype;return e.mount=function(){var n=this;this.unsubscribeFocus=ic.subscribe(function(){ic.isFocused()&&Uh.isOnline()&&(n.mutationCache.onFocus(),n.queryCache.onFocus())}),this.unsubscribeOnline=Uh.subscribe(function(){ic.isFocused()&&Uh.isOnline()&&(n.mutationCache.onOnline(),n.queryCache.onOnline())})},e.unmount=function(){var n,a;(n=this.unsubscribeFocus)==null||n.call(this),(a=this.unsubscribeOnline)==null||a.call(this)},e.isFetching=function(n,a){var i=Fi(n,a),o=i[0];return o.fetching=!0,this.queryCache.findAll(o).length},e.isMutating=function(n){return this.mutationCache.findAll(Je({},n,{fetching:!0})).length},e.getQueryData=function(n,a){var i;return(i=this.queryCache.find(n,a))==null?void 0:i.state.data},e.getQueriesData=function(n){return this.getQueryCache().findAll(n).map(function(a){var i=a.queryKey,o=a.state,s=o.data;return[i,s]})},e.setQueryData=function(n,a,i){var o=Wh(n),s=this.defaultQueryOptions(o);return this.queryCache.build(this,s).setData(a,i)},e.setQueriesData=function(n,a,i){var o=this;return Tt.batch(function(){return o.getQueryCache().findAll(n).map(function(s){var l=s.queryKey;return[l,o.setQueryData(l,a,i)]})})},e.getQueryState=function(n,a){var i;return(i=this.queryCache.find(n,a))==null?void 0:i.state},e.removeQueries=function(n,a){var i=Fi(n,a),o=i[0],s=this.queryCache;Tt.batch(function(){s.findAll(o).forEach(function(l){s.remove(l)})})},e.resetQueries=function(n,a,i){var o=this,s=Fi(n,a,i),l=s[0],u=s[1],c=this.queryCache,f=Je({},l,{active:!0});return Tt.batch(function(){return c.findAll(l).forEach(function(h){h.reset()}),o.refetchQueries(f,u)})},e.cancelQueries=function(n,a,i){var o=this,s=Fi(n,a,i),l=s[0],u=s[1],c=u===void 0?{}:u;typeof c.revert=="undefined"&&(c.revert=!0);var f=Tt.batch(function(){return o.queryCache.findAll(l).map(function(h){return h.cancel(c)})});return Promise.all(f).then(mr).catch(mr)},e.invalidateQueries=function(n,a,i){var o,s,l,u=this,c=Fi(n,a,i),f=c[0],h=c[1],v=Je({},f,{active:(o=(s=f.refetchActive)!=null?s:f.active)!=null?o:!0,inactive:(l=f.refetchInactive)!=null?l:!1});return Tt.batch(function(){return u.queryCache.findAll(f).forEach(function(d){d.invalidate()}),u.refetchQueries(v,h)})},e.refetchQueries=function(n,a,i){var o=this,s=Fi(n,a,i),l=s[0],u=s[1],c=Tt.batch(function(){return o.queryCache.findAll(l).map(function(h){return h.fetch(void 0,Je({},u,{meta:{refetchPage:l==null?void 0:l.refetchPage}}))})}),f=Promise.all(c).then(mr);return u!=null&&u.throwOnError||(f=f.catch(mr)),f},e.fetchQuery=function(n,a,i){var o=Wh(n,a,i),s=this.defaultQueryOptions(o);typeof s.retry=="undefined"&&(s.retry=!1);var l=this.queryCache.build(this,s);return l.isStaleByTime(s.staleTime)?l.fetch(s):Promise.resolve(l.state.data)},e.prefetchQuery=function(n,a,i){return this.fetchQuery(n,a,i).then(mr).catch(mr)},e.fetchInfiniteQuery=function(n,a,i){var o=Wh(n,a,i);return o.behavior=l5(),this.fetchQuery(o)},e.prefetchInfiniteQuery=function(n,a,i){return this.fetchInfiniteQuery(n,a,i).then(mr).catch(mr)},e.cancelMutations=function(){var n=this,a=Tt.batch(function(){return n.mutationCache.getAll().map(function(i){return i.cancel()})});return Promise.all(a).then(mr).catch(mr)},e.resumePausedMutations=function(){return this.getMutationCache().resumePausedMutations()},e.executeMutation=function(n){return this.mutationCache.build(this,n).execute()},e.getQueryCache=function(){return this.queryCache},e.getMutationCache=function(){return this.mutationCache},e.getDefaultOptions=function(){return this.defaultOptions},e.setDefaultOptions=function(n){this.defaultOptions=n},e.setQueryDefaults=function(n,a){var i=this.queryDefaults.find(function(o){return Bo(n)===Bo(o.queryKey)});i?i.defaultOptions=a:this.queryDefaults.push({queryKey:n,defaultOptions:a})},e.getQueryDefaults=function(n){var a;return n?(a=this.queryDefaults.find(function(i){return Gh(n,i.queryKey)}))==null?void 0:a.defaultOptions:void 0},e.setMutationDefaults=function(n,a){var i=this.mutationDefaults.find(function(o){return Bo(n)===Bo(o.mutationKey)});i?i.defaultOptions=a:this.mutationDefaults.push({mutationKey:n,defaultOptions:a})},e.getMutationDefaults=function(n){var a;return n?(a=this.mutationDefaults.find(function(i){return Gh(n,i.mutationKey)}))==null?void 0:a.defaultOptions:void 0},e.defaultQueryOptions=function(n){if(n!=null&&n._defaulted)return n;var a=Je({},this.defaultOptions.queries,this.getQueryDefaults(n==null?void 0:n.queryKey),n,{_defaulted:!0});return!a.queryHash&&a.queryKey&&(a.queryHash=wy(a.queryKey,a)),a},e.defaultQueryObserverOptions=function(n){return this.defaultQueryOptions(n)},e.defaultMutationOptions=function(n){return n!=null&&n._defaulted?n:Je({},this.defaultOptions.mutations,this.getMutationDefaults(n==null?void 0:n.mutationKey),n,{_defaulted:!0})},e.clear=function(){this.queryCache.clear(),this.mutationCache.clear()},r}(),f5=function(r){jo(e,r);function e(n,a){var i;return i=r.call(this)||this,i.client=n,i.options=a,i.trackedProps=[],i.selectError=null,i.bindMethods(),i.setOptions(a),i}var t=e.prototype;return t.bindMethods=function(){this.remove=this.remove.bind(this),this.refetch=this.refetch.bind(this)},t.onSubscribe=function(){this.listeners.length===1&&(this.currentQuery.addObserver(this),hD(this.currentQuery,this.options)&&this.executeFetch(),this.updateTimers())},t.onUnsubscribe=function(){this.listeners.length||this.destroy()},t.shouldFetchOnReconnect=function(){return Sy(this.currentQuery,this.options,this.options.refetchOnReconnect)},t.shouldFetchOnWindowFocus=function(){return Sy(this.currentQuery,this.options,this.options.refetchOnWindowFocus)},t.destroy=function(){this.listeners=[],this.clearTimers(),this.currentQuery.removeObserver(this)},t.setOptions=function(a,i){var o=this.options,s=this.currentQuery;if(this.options=this.client.defaultQueryObserverOptions(a),typeof this.options.enabled!="undefined"&&typeof this.options.enabled!="boolean")throw new Error("Expected enabled to be a boolean");this.options.queryKey||(this.options.queryKey=o.queryKey),this.updateQuery();var l=this.hasListeners();l&&vD(this.currentQuery,s,this.options,o)&&this.executeFetch(),this.updateResult(i),l&&(this.currentQuery!==s||this.options.enabled!==o.enabled||this.options.staleTime!==o.staleTime)&&this.updateStaleTimeout();var u=this.computeRefetchInterval();l&&(this.currentQuery!==s||this.options.enabled!==o.enabled||u!==this.currentRefetchInterval)&&this.updateRefetchInterval(u)},t.getOptimisticResult=function(a){var i=this.client.defaultQueryObserverOptions(a),o=this.client.getQueryCache().build(this.client,i);return this.createResult(o,i)},t.getCurrentResult=function(){return this.currentResult},t.trackResult=function(a,i){var o=this,s={},l=function(c){o.trackedProps.includes(c)||o.trackedProps.push(c)};return Object.keys(a).forEach(function(u){Object.defineProperty(s,u,{configurable:!1,enumerable:!0,get:function(){return l(u),a[u]}})}),(i.useErrorBoundary||i.suspense)&&l("error"),s},t.getNextResult=function(a){var i=this;return new Promise(function(o,s){var l=i.subscribe(function(u){u.isFetching||(l(),u.isError&&(a==null?void 0:a.throwOnError)?s(u.error):o(u))})})},t.getCurrentQuery=function(){return this.currentQuery},t.remove=function(){this.client.getQueryCache().remove(this.currentQuery)},t.refetch=function(a){return this.fetch(Je({},a,{meta:{refetchPage:a==null?void 0:a.refetchPage}}))},t.fetchOptimistic=function(a){var i=this,o=this.client.defaultQueryObserverOptions(a),s=this.client.getQueryCache().build(this.client,o);return s.fetch().then(function(){return i.createResult(s,o)})},t.fetch=function(a){var i=this;return this.executeFetch(a).then(function(){return i.updateResult(),i.currentResult})},t.executeFetch=function(a){this.updateQuery();var i=this.currentQuery.fetch(this.options,a);return a!=null&&a.throwOnError||(i=i.catch(mr)),i},t.updateStaleTimeout=function(){var a=this;if(this.clearStaleTimeout(),!(Vh||this.currentResult.isStale||!xy(this.options.staleTime))){var i=eD(this.currentResult.dataUpdatedAt,this.options.staleTime),o=i+1;this.staleTimeoutId=setTimeout(function(){a.currentResult.isStale||a.updateResult()},o)}},t.computeRefetchInterval=function(){var a;return typeof this.options.refetchInterval=="function"?this.options.refetchInterval(this.currentResult.data,this.currentQuery):(a=this.options.refetchInterval)!=null?a:!1},t.updateRefetchInterval=function(a){var i=this;this.clearRefetchInterval(),this.currentRefetchInterval=a,!(Vh||this.options.enabled===!1||!xy(this.currentRefetchInterval)||this.currentRefetchInterval===0)&&(this.refetchIntervalId=setInterval(function(){(i.options.refetchIntervalInBackground||ic.isFocused())&&i.executeFetch()},this.currentRefetchInterval))},t.updateTimers=function(){this.updateStaleTimeout(),this.updateRefetchInterval(this.computeRefetchInterval())},t.clearTimers=function(){this.clearStaleTimeout(),this.clearRefetchInterval()},t.clearStaleTimeout=function(){this.staleTimeoutId&&(clearTimeout(this.staleTimeoutId),this.staleTimeoutId=void 0)},t.clearRefetchInterval=function(){this.refetchIntervalId&&(clearInterval(this.refetchIntervalId),this.refetchIntervalId=void 0)},t.createResult=function(a,i){var o=this.currentQuery,s=this.options,l=this.currentResult,u=this.currentResultState,c=this.currentResultOptions,f=a!==o,h=f?a.state:this.currentQueryInitialState,v=f?this.currentResult:this.previousQueryResult,d=a.state,p=d.dataUpdatedAt,g=d.error,y=d.errorUpdatedAt,m=d.isFetching,_=d.status,b=!1,x=!1,M;if(i.optimisticResults){var w=this.hasListeners(),D=!w&&hD(a,i),T=w&&vD(a,o,i,s);(D||T)&&(m=!0,p||(_="loading"))}if(i.keepPreviousData&&!d.dataUpdateCount&&(v==null?void 0:v.isSuccess)&&_!=="error")M=v.data,p=v.dataUpdatedAt,_=v.status,b=!0;else if(i.select&&typeof d.data!="undefined")if(l&&d.data===(u==null?void 0:u.data)&&i.select===this.selectFn)M=this.selectResult;else try{this.selectFn=i.select,M=i.select(d.data),i.structuralSharing!==!1&&(M=$h(l==null?void 0:l.data,M)),this.selectResult=M,this.selectError=null}catch(N){Zh().error(N),this.selectError=N}else M=d.data;if(typeof i.placeholderData!="undefined"&&typeof M=="undefined"&&(_==="loading"||_==="idle")){var I;if((l==null?void 0:l.isPlaceholderData)&&i.placeholderData===(c==null?void 0:c.placeholderData))I=l.data;else if(I=typeof i.placeholderData=="function"?i.placeholderData():i.placeholderData,i.select&&typeof I!="undefined")try{I=i.select(I),i.structuralSharing!==!1&&(I=$h(l==null?void 0:l.data,I)),this.selectError=null}catch(N){Zh().error(N),this.selectError=N}typeof I!="undefined"&&(_="success",M=I,x=!0)}this.selectError&&(g=this.selectError,M=this.selectResult,y=Date.now(),_="error");var A={status:_,isLoading:_==="loading",isSuccess:_==="success",isError:_==="error",isIdle:_==="idle",data:M,dataUpdatedAt:p,error:g,errorUpdatedAt:y,failureCount:d.fetchFailureCount,errorUpdateCount:d.errorUpdateCount,isFetched:d.dataUpdateCount>0||d.errorUpdateCount>0,isFetchedAfterMount:d.dataUpdateCount>h.dataUpdateCount||d.errorUpdateCount>h.errorUpdateCount,isFetching:m,isRefetching:m&&_!=="loading",isLoadingError:_==="error"&&d.dataUpdatedAt===0,isPlaceholderData:x,isPreviousData:b,isRefetchError:_==="error"&&d.dataUpdatedAt!==0,isStale:Iy(a,i),refetch:this.refetch,remove:this.remove};return A},t.shouldNotifyListeners=function(a,i){if(!i)return!0;var o=this.options,s=o.notifyOnChangeProps,l=o.notifyOnChangePropsExclusions;if(!s&&!l||s==="tracked"&&!this.trackedProps.length)return!0;var u=s==="tracked"?this.trackedProps:s;return Object.keys(a).some(function(c){var f=c,h=a[f]!==i[f],v=u==null?void 0:u.some(function(p){return p===c}),d=l==null?void 0:l.some(function(p){return p===c});return h&&!d&&(!u||v)})},t.updateResult=function(a){var i=this.currentResult;if(this.currentResult=this.createResult(this.currentQuery,this.options),this.currentResultState=this.currentQuery.state,this.currentResultOptions=this.options,!qj(this.currentResult,i)){var o={cache:!0};(a==null?void 0:a.listeners)!==!1&&this.shouldNotifyListeners(this.currentResult,i)&&(o.listeners=!0),this.notify(Je({},o,a))}},t.updateQuery=function(){var a=this.client.getQueryCache().build(this.client,this.options);if(a!==this.currentQuery){var i=this.currentQuery;this.currentQuery=a,this.currentQueryInitialState=a.state,this.previousQueryResult=this.currentResult,this.hasListeners()&&(i==null||i.removeObserver(this),a.addObserver(this))}},t.onQueryUpdate=function(a){var i={};a.type==="success"?i.onSuccess=!0:a.type==="error"&&!Qh(a.error)&&(i.onError=!0),this.updateResult(i),this.hasListeners()&&this.updateTimers()},t.notify=function(a){var i=this;Tt.batch(function(){a.onSuccess?(i.options.onSuccess==null||i.options.onSuccess(i.currentResult.data),i.options.onSettled==null||i.options.onSettled(i.currentResult.data,null)):a.onError&&(i.options.onError==null||i.options.onError(i.currentResult.error),i.options.onSettled==null||i.options.onSettled(void 0,i.currentResult.error)),a.listeners&&i.listeners.forEach(function(o){o(i.currentResult)}),a.cache&&i.client.getQueryCache().notify({query:i.currentQuery,type:"observerResultsUpdated"})})},e}(Ml);function h5(r,e){return e.enabled!==!1&&!r.state.dataUpdatedAt&&!(r.state.status==="error"&&e.retryOnMount===!1)}function hD(r,e){return h5(r,e)||r.state.dataUpdatedAt>0&&Sy(r,e,e.refetchOnMount)}function Sy(r,e,t){if(e.enabled!==!1){var n=typeof t=="function"?t(r):t;return n==="always"||n!==!1&&Iy(r,e)}return!1}function vD(r,e,t,n){return t.enabled!==!1&&(r!==e||n.enabled===!1)&&(!t.suspense||r.state.status!=="error")&&Iy(r,t)}function Iy(r,e){return r.isStaleByTime(e.staleTime)}var v5=function(r){jo(e,r);function e(n,a){var i;return i=r.call(this)||this,i.client=n,i.setOptions(a),i.bindMethods(),i.updateResult(),i}var t=e.prototype;return t.bindMethods=function(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)},t.setOptions=function(a){this.options=this.client.defaultMutationOptions(a)},t.onUnsubscribe=function(){if(!this.listeners.length){var a;(a=this.currentMutation)==null||a.removeObserver(this)}},t.onMutationUpdate=function(a){this.updateResult();var i={listeners:!0};a.type==="success"?i.onSuccess=!0:a.type==="error"&&(i.onError=!0),this.notify(i)},t.getCurrentResult=function(){return this.currentResult},t.reset=function(){this.currentMutation=void 0,this.updateResult(),this.notify({listeners:!0})},t.mutate=function(a,i){return this.mutateOptions=i,this.currentMutation&&this.currentMutation.removeObserver(this),this.currentMutation=this.client.getMutationCache().build(this.client,Je({},this.options,{variables:typeof a!="undefined"?a:this.options.variables})),this.currentMutation.addObserver(this),this.currentMutation.execute()},t.updateResult=function(){var a=this.currentMutation?this.currentMutation.state:cD(),i=Je({},a,{isLoading:a.status==="loading",isSuccess:a.status==="success",isError:a.status==="error",isIdle:a.status==="idle",mutate:this.mutate,reset:this.reset});this.currentResult=i},t.notify=function(a){var i=this;Tt.batch(function(){i.mutateOptions&&(a.onSuccess?(i.mutateOptions.onSuccess==null||i.mutateOptions.onSuccess(i.currentResult.data,i.currentResult.variables,i.currentResult.context),i.mutateOptions.onSettled==null||i.mutateOptions.onSettled(i.currentResult.data,null,i.currentResult.variables,i.currentResult.context)):a.onError&&(i.mutateOptions.onError==null||i.mutateOptions.onError(i.currentResult.error,i.currentResult.variables,i.currentResult.context),i.mutateOptions.onSettled==null||i.mutateOptions.onSettled(void 0,i.currentResult.error,i.currentResult.variables,i.currentResult.context))),a.listeners&&i.listeners.forEach(function(o){o(i.currentResult)})})},e}(Ml),d5=Fh.default.unstable_batchedUpdates;Tt.setBatchNotifyFunction(d5);var p5=console;r5(p5);var dD=pe.default.createContext(void 0),pD=pe.default.createContext(!1);function gD(r){return r&&typeof window!="undefined"?(window.ReactQueryClientContext||(window.ReactQueryClientContext=dD),window.ReactQueryClientContext):dD}var yD=function(){var e=pe.default.useContext(gD(pe.default.useContext(pD)));if(!e)throw new Error("No QueryClient set, use QueryClientProvider to set one");return e},g5=function(e){var t=e.client,n=e.contextSharing,a=n===void 0?!1:n,i=e.children;pe.default.useEffect(function(){return t.mount(),function(){t.unmount()}},[t]);var o=gD(a);return pe.default.createElement(pD.Provider,{value:a},pe.default.createElement(o.Provider,{value:t},i))};function y5(){var r=!1;return{clearReset:function(){r=!1},reset:function(){r=!0},isReset:function(){return r}}}var m5=pe.default.createContext(y5()),_5=function(){return pe.default.useContext(m5)};function mD(r,e,t){return typeof e=="function"?e.apply(void 0,t):typeof e=="boolean"?e:!!r}function xl(r,e,t){var n=pe.default.useRef(!1),a=pe.default.useState(0),i=a[1],o=Yj(r,e,t),s=yD(),l=pe.default.useRef();l.current?l.current.setOptions(o):l.current=new v5(s,o);var u=l.current.getCurrentResult();pe.default.useEffect(function(){n.current=!0;var f=l.current.subscribe(Tt.batchCalls(function(){n.current&&i(function(h){return h+1})}));return function(){n.current=!1,f()}},[]);var c=pe.default.useCallback(function(f,h){l.current.mutate(f,h).catch(mr)},[]);if(u.error&&mD(void 0,l.current.options.useErrorBoundary,[u.error]))throw u.error;return Je({},u,{mutate:c,mutateAsync:u.mutate})}function b5(r,e){var t=pe.default.useRef(!1),n=pe.default.useState(0),a=n[1],i=yD(),o=_5(),s=i.defaultQueryObserverOptions(r);s.optimisticResults=!0,s.onError&&(s.onError=Tt.batchCalls(s.onError)),s.onSuccess&&(s.onSuccess=Tt.batchCalls(s.onSuccess)),s.onSettled&&(s.onSettled=Tt.batchCalls(s.onSettled)),s.suspense&&(typeof s.staleTime!="number"&&(s.staleTime=1e3),s.cacheTime===0&&(s.cacheTime=1)),(s.suspense||s.useErrorBoundary)&&(o.isReset()||(s.retryOnMount=!1));var l=pe.default.useState(function(){return new e(i,s)}),u=l[0],c=u.getOptimisticResult(s);if(pe.default.useEffect(function(){t.current=!0,o.clearReset();var f=u.subscribe(Tt.batchCalls(function(){t.current&&a(function(h){return h+1})}));return u.updateResult(),function(){t.current=!1,f()}},[o,u]),pe.default.useEffect(function(){u.setOptions(s,{listeners:!1})},[s,u]),s.suspense&&c.isLoading)throw u.fetchOptimistic(s).then(function(f){var h=f.data;s.onSuccess==null||s.onSuccess(h),s.onSettled==null||s.onSettled(h,null)}).catch(function(f){o.clearReset(),s.onError==null||s.onError(f),s.onSettled==null||s.onSettled(void 0,f)});if(c.isError&&!o.isReset()&&!c.isFetching&&mD(s.suspense,s.useErrorBoundary,[c.error,u.getCurrentQuery()]))throw c.error;return s.notifyOnChangeProps==="tracked"&&(c=u.trackResult(c,s)),c}function Fo(r,e,t){var n=Wh(r,e,t);return b5(n,f5)}var pn={container:"_container_1ddns_1",static:"_static_1ddns_383",fixed:"_fixed_1ddns_1",absolute:"_absolute_1ddns_1","left-2":"_left-2_1ddns_1","top-1":"_top-1_1ddns_1","mt-2.5":"_mt-2.5_1ddns_1","mt-2":"_mt-2_1ddns_1","mb-3":"_mb-3_1ddns_1",flex:"_flex_1ddns_1",table:"_table_1ddns_1",grid:"_grid_1ddns_1",hidden:"_hidden_1ddns_1","h-screen":"_h-screen_1ddns_1","h-[10%]":"_h-[10%]_1ddns_1","w-screen":"_w-screen_1ddns_1","w-full":"_w-full_1ddns_1",transform:"_transform_1ddns_1",resize:"_resize_1ddns_1","overflow-x-hidden":"_overflow-x-hidden_1ddns_1",truncate:"_truncate_1ddns_1",border:"_border_1ddns_1","p-2":"_p-2_1ddns_1","text-center":"_text-center_1ddns_1","text-sm":"_text-sm_1ddns_1","text-xs":"_text-xs_1ddns_1","text-blue-700":"_text-blue-700_1ddns_1",shadow:"_shadow_1ddns_1",filter:"_filter_1ddns_351","!filter":"_!filter_1ddns_1","embedDashboard-container":"_embedDashboard-container_1ddns_311","embedDashboard-header-static":"_embedDashboard-header-static_1ddns_319","embedDashboard-header-floating":"_embedDashboard-header-floating_1ddns_327","embedDashboard-wrapper":"_embedDashboard-wrapper_1ddns_335","alt-container":"_alt-container_1ddns_343",floatingFilterButton:"_floatingFilterButton_1ddns_359",floatingFilterButtonIcon:"_floatingFilterButtonIcon_1ddns_367",floatingButton:"_floatingButton_1ddns_375",staticContainer:"_staticContainer_1ddns_383",floatingContainer:"_floatingContainer_1ddns_391","hover:cursor-pointer":"_hover:cursor-pointer_1ddns_1","hover:cursor-text":"_hover:cursor-text_1ddns_1","disabled:cursor-text":"_disabled:cursor-text_1ddns_1"},qh=typeof globalThis!="undefined"?globalThis:typeof window!="undefined"?window:typeof global!="undefined"?global:typeof self!="undefined"?self:{};function M5(r){if(r.__esModule)return r;var e=Object.defineProperty({},"__esModule",{value:!0});return Object.keys(r).forEach(function(t){var n=Object.getOwnPropertyDescriptor(r,t);Object.defineProperty(e,t,n.get?n:{enumerable:!0,get:function(){return r[t]}})}),e}var _D={exports:{}};/*!
|
|
2
|
+
Copyright (c) 2018 Jed Watson.
|
|
3
|
+
Licensed under the MIT License (MIT), see
|
|
4
|
+
http://jedwatson.github.io/classnames
|
|
5
|
+
*/(function(r){(function(){var e={}.hasOwnProperty;function t(){for(var n=[],a=0;a<arguments.length;a++){var i=arguments[a];if(!!i){var o=typeof i;if(o==="string"||o==="number")n.push(i);else if(Array.isArray(i)){if(i.length){var s=t.apply(null,i);s&&n.push(s)}}else if(o==="object"){if(i.toString!==Object.prototype.toString&&!i.toString.toString().includes("[native code]")){n.push(i.toString());continue}for(var l in i)e.call(i,l)&&i[l]&&n.push(l)}}}return n.join(" ")}r.exports?(t.default=t,r.exports=t):window.classNames=t})()})(_D);var Na=_D.exports,bD={"btn-primary":"_btn-primary_czbha_1","btn-secondary":"_btn-secondary_czbha_5","btn-reject":"_btn-reject_czbha_9","btn-outlined":"_btn-outlined_czbha_14","btn-tertiary":"_btn-tertiary_czbha_18","btn-default":"_btn-default_czbha_22","btn-large":"_btn-large_czbha_25","btn-small":"_btn-small_czbha_28","btn-xs":"_btn-xs_czbha_31","btn-medium":"_btn-medium_czbha_34","btn-11rem":"_btn-11rem_czbha_38"},Xh={exports:{}},Jh={};/**
|
|
6
|
+
* @license React
|
|
7
|
+
* react-jsx-runtime.production.min.js
|
|
8
|
+
*
|
|
9
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
10
|
+
*
|
|
11
|
+
* This source code is licensed under the MIT license found in the
|
|
12
|
+
* LICENSE file in the root directory of this source tree.
|
|
13
|
+
*/var x5=pe.default,w5=Symbol.for("react.element"),D5=Symbol.for("react.fragment"),S5=Object.prototype.hasOwnProperty,I5=x5.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,T5={key:!0,ref:!0,__self:!0,__source:!0};function MD(r,e,t){var n,a={},i=null,o=null;t!==void 0&&(i=""+t),e.key!==void 0&&(i=""+e.key),e.ref!==void 0&&(o=e.ref);for(n in e)S5.call(e,n)&&!T5.hasOwnProperty(n)&&(a[n]=e[n]);if(r&&r.defaultProps)for(n in e=r.defaultProps,e)a[n]===void 0&&(a[n]=e[n]);return{$$typeof:w5,type:r,key:i,ref:o,props:a,_owner:I5.current}}Jh.Fragment=D5,Jh.jsx=MD,Jh.jsxs=MD,Xh.exports=Jh;const S=Xh.exports.jsx,B=Xh.exports.jsxs,we=Xh.exports.Fragment,Ce=({isDisabled:r=!1,type:e="button",className:t,children:n="",variant:a="primary",size:i="none",onClick:o,title:s,...l})=>{const u=Na(t,bD[`btn-${a}`],`dbn-btn-${a}`,i==="none"?null:bD[`btn-${i}`]);return S("button",{...l,type:e,className:a==="custom"?t:u,onClick:o,disabled:r,title:s,children:n})};var oc=r=>r.type==="checkbox",wl=r=>r instanceof Date,Nr=r=>r==null;const xD=r=>typeof r=="object";var _r=r=>!Nr(r)&&!Array.isArray(r)&&xD(r)&&!wl(r),wD=r=>_r(r)&&r.target?oc(r.target)?r.target.checked:r.target.value:r,A5=r=>r.substring(0,r.search(/\.\d+(\.|$)/))||r,DD=(r,e)=>r.has(A5(e)),Kh=r=>Array.isArray(r)?r.filter(Boolean):[],Rt=r=>r===void 0,be=(r,e,t)=>{if(!e||!_r(r))return t;const n=Kh(e.split(/[,[\].]+?/)).reduce((a,i)=>Nr(a)?a:a[i],r);return Rt(n)||n===r?Rt(r[e])?t:r[e]:n};const ev={BLUR:"blur",FOCUS_OUT:"focusout",CHANGE:"change"},oa={onBlur:"onBlur",onChange:"onChange",onSubmit:"onSubmit",onTouched:"onTouched",all:"all"},ni={max:"max",min:"min",maxLength:"maxLength",minLength:"minLength",pattern:"pattern",required:"required",validate:"validate"},C5=pe.default.createContext(null),Ty=()=>pe.default.useContext(C5);var SD=(r,e,t,n=!0)=>{const a={};for(const i in r)Object.defineProperty(a,i,{get:()=>{const o=i;return e[o]!==oa.all&&(e[o]=!n||oa.all),t&&(t[o]=!0),r[o]}});return a},En=r=>_r(r)&&!Object.keys(r).length,ID=(r,e,t)=>{const{name:n,...a}=r;return En(a)||Object.keys(a).length>=Object.keys(e).length||Object.keys(a).find(i=>e[i]===(!t||oa.all))},tv=r=>Array.isArray(r)?r:[r],TD=(r,e,t)=>t&&e?r===e:!r||!e||r===e||tv(r).some(n=>n&&(n.startsWith(e)||e.startsWith(n)));function Ay(r){const e=pe.default.useRef(r);e.current=r,pe.default.useEffect(()=>{const t=a=>{a&&a.unsubscribe()},n=!r.disabled&&e.current.subject.subscribe({next:e.current.callback});return()=>t(n)},[r.disabled])}function N5(r){const e=Ty(),{control:t=e.control,disabled:n,name:a,exact:i}=r||{},[o,s]=pe.default.useState(t._formState),l=pe.default.useRef({isDirty:!1,dirtyFields:!1,touchedFields:!1,isValidating:!1,isValid:!1,errors:!1}),u=pe.default.useRef(a),c=pe.default.useRef(!0);u.current=a;const f=pe.default.useCallback(h=>c.current&&TD(u.current,h.name,i)&&ID(h,l.current)&&s({...t._formState,...h}),[t,i]);return Ay({disabled:n,callback:f,subject:t._subjects.state}),pe.default.useEffect(()=>(c.current=!0,()=>{c.current=!1}),[]),SD(o,t._proxyFormState,l.current,!1)}var La=r=>typeof r=="string",AD=(r,e,t,n)=>{const a=Array.isArray(r);return La(r)?(n&&e.watch.add(r),be(t,r)):a?r.map(i=>(n&&e.watch.add(i),be(t,i))):(n&&(e.watchAll=!0),t)},rv=r=>typeof r=="function",Cy=r=>{for(const e in r)if(rv(r[e]))return!0;return!1};function L5(r){const e=Ty(),{control:t=e.control,name:n,defaultValue:a,disabled:i,exact:o}=r||{},s=pe.default.useRef(n);s.current=n;const l=pe.default.useCallback(f=>{if(TD(s.current,f.name,o)){const h=AD(s.current,t._names,f.values||t._formValues);c(Rt(s.current)||_r(h)&&!Cy(h)?{...h}:Array.isArray(h)?[...h]:Rt(h)?a:h)}},[t,o,a]);Ay({disabled:i,subject:t._subjects.watch,callback:l});const[u,c]=pe.default.useState(Rt(a)?t._getWatch(n):a);return pe.default.useEffect(()=>{t._removeUnmounted()}),u}function E5(r){const e=Ty(),{name:t,control:n=e.control,shouldUnregister:a}=r,i=DD(n._names.array,t),o=L5({control:n,name:t,defaultValue:be(n._formValues,t,be(n._defaultValues,t,r.defaultValue)),exact:!0}),s=N5({control:n,name:t}),l=pe.default.useRef(n.register(t,{...r.rules,value:o}));return pe.default.useEffect(()=>{const u=(c,f)=>{const h=be(n._fields,c);h&&(h._f.mount=f)};return u(t,!0),()=>{const c=n._options.shouldUnregister||a;(i?c&&!n._stateFlags.action:c)?n.unregister(t):u(t,!1)}},[t,n,i,a]),{field:{name:t,value:o,onChange:pe.default.useCallback(u=>{l.current.onChange({target:{value:wD(u),name:t},type:ev.CHANGE})},[t]),onBlur:pe.default.useCallback(()=>{l.current.onBlur({target:{value:be(n._formValues,t),name:t},type:ev.BLUR})},[t,n]),ref:pe.default.useCallback(u=>{const c=be(n._fields,t);u&&c&&u.focus&&(c._f.ref={focus:()=>u.focus(),select:()=>u.select(),setCustomValidity:f=>u.setCustomValidity(f),reportValidity:()=>u.reportValidity()})},[t,n._fields])},formState:s,fieldState:Object.defineProperties({},{invalid:{get:()=>!!be(s.errors,t)},isDirty:{get:()=>!!be(s.dirtyFields,t)},isTouched:{get:()=>!!be(s.touchedFields,t)},error:{get:()=>be(s.errors,t)}})}}const Ny=r=>r.render(E5(r));var O5=(r,e,t,n,a)=>e?{...t[r],types:{...t[r]&&t[r].types?t[r].types:{},[n]:a||!0}}:{},Ly=r=>/^\w*$/.test(r),CD=r=>Kh(r.replace(/["|']|\]/g,"").split(/\.|\[/));function jt(r,e,t){let n=-1;const a=Ly(e)?[e]:CD(e),i=a.length,o=i-1;for(;++n<i;){const s=a[n];let l=t;if(n!==o){const u=r[s];l=_r(u)||Array.isArray(u)?u:isNaN(+a[n+1])?{}:[]}r[s]=l,r=r[s]}return r}const Ey=(r,e,t)=>{for(const n of t||Object.keys(r)){const a=be(r,n);if(a){const{_f:i,...o}=a;if(i&&e(i.name)){if(i.ref.focus&&Rt(i.ref.focus()))break;if(i.refs){i.refs[0].focus();break}}else _r(o)&&Ey(o,e)}}};var ND=(r,e,t)=>!t&&(e.watchAll||e.watch.has(r)||[...e.watch].some(n=>r.startsWith(n)&&/^\.\w+/.test(r.slice(n.length)))),Oy=typeof window!="undefined"&&typeof window.HTMLElement!="undefined"&&typeof document!="undefined";function Vo(r){let e;const t=Array.isArray(r);if(r instanceof Date)e=new Date(r);else if(r instanceof Set)e=new Set(r);else if(!(Oy&&(r instanceof Blob||r instanceof FileList))&&(t||_r(r))){e=t?[]:{};for(const n in r){if(rv(r[n])){e=r;break}e[n]=Vo(r[n])}}else return r;return e}function P5(r,e){const t=e.slice(0,-1).length;let n=0;for(;n<t;)r=Rt(r)?n++:r[e[n++]];return r}function Wr(r,e){const t=Ly(e)?[e]:CD(e),n=t.length==1?r:P5(r,t),a=t[t.length-1];let i;n&&delete n[a];for(let o=0;o<t.slice(0,-1).length;o++){let s=-1,l;const u=t.slice(0,-(o+1)),c=u.length-1;for(o>0&&(i=r);++s<u.length;){const f=u[s];l=l?l[f]:r[f],c===s&&(_r(l)&&En(l)||Array.isArray(l)&&!l.filter(h=>!Rt(h)).length)&&(i?delete i[f]:delete r[f]),i=l}}return r}function Py(){let r=[];return{get observers(){return r},next:a=>{for(const i of r)i.next(a)},subscribe:a=>(r.push(a),{unsubscribe:()=>{r=r.filter(i=>i!==a)}}),unsubscribe:()=>{r=[]}}}var nv=r=>Nr(r)||!xD(r);function Dl(r,e){if(nv(r)||nv(e))return r===e;if(wl(r)&&wl(e))return r.getTime()===e.getTime();const t=Object.keys(r),n=Object.keys(e);if(t.length!==n.length)return!1;for(const a of t){const i=r[a];if(!n.includes(a))return!1;if(a!=="ref"){const o=e[a];if(wl(i)&&wl(o)||_r(i)&&_r(o)||Array.isArray(i)&&Array.isArray(o)?!Dl(i,o):i!==o)return!1}}return!0}var LD=r=>({isOnSubmit:!r||r===oa.onSubmit,isOnBlur:r===oa.onBlur,isOnChange:r===oa.onChange,isOnAll:r===oa.all,isOnTouch:r===oa.onTouched}),av=r=>typeof r=="boolean",zy=r=>r.type==="file",ky=r=>{const e=r?r.ownerDocument:0,t=e&&e.defaultView?e.defaultView.HTMLElement:HTMLElement;return r instanceof t},ED=r=>r.type==="select-multiple",Ry=r=>r.type==="radio",z5=r=>Ry(r)||oc(r),jy=r=>ky(r)&&r.isConnected;function iv(r,e={}){const t=Array.isArray(r);if(_r(r)||t)for(const n in r)Array.isArray(r[n])||_r(r[n])&&!Cy(r[n])?(e[n]=Array.isArray(r[n])?[]:{},iv(r[n],e[n])):Nr(r[n])||(e[n]=!0);return e}function OD(r,e,t){const n=Array.isArray(r);if(_r(r)||n)for(const a in r)Array.isArray(r[a])||_r(r[a])&&!Cy(r[a])?Rt(e)||nv(t[a])?t[a]=Array.isArray(r[a])?iv(r[a],[]):{...iv(r[a])}:OD(r[a],Nr(e)?{}:e[a],t[a]):t[a]=!Dl(r[a],e[a]);return t}var By=(r,e)=>OD(r,e,iv(e));const PD={value:!1,isValid:!1},zD={value:!0,isValid:!0};var kD=r=>{if(Array.isArray(r)){if(r.length>1){const e=r.filter(t=>t&&t.checked&&!t.disabled).map(t=>t.value);return{value:e,isValid:!!e.length}}return r[0].checked&&!r[0].disabled?r[0].attributes&&!Rt(r[0].attributes.value)?Rt(r[0].value)||r[0].value===""?zD:{value:r[0].value,isValid:!0}:zD:PD}return PD},RD=(r,{valueAsNumber:e,valueAsDate:t,setValueAs:n})=>Rt(r)?r:e?r===""||Nr(r)?NaN:+r:t&&La(r)?new Date(r):n?n(r):r;const jD={isValid:!1,value:null};var BD=r=>Array.isArray(r)?r.reduce((e,t)=>t&&t.checked&&!t.disabled?{isValid:!0,value:t.value}:e,jD):jD;function Fy(r){const e=r.ref;if(!(r.refs?r.refs.every(t=>t.disabled):e.disabled))return zy(e)?e.files:Ry(e)?BD(r.refs).value:ED(e)?[...e.selectedOptions].map(({value:t})=>t):oc(e)?kD(r.refs).value:RD(Rt(e.value)?r.ref.value:e.value,r)}var k5=(r,e,t,n)=>{const a={};for(const i of r){const o=be(e,i);o&&jt(a,i,o._f)}return{criteriaMode:t,names:[...r],fields:a,shouldUseNativeValidation:n}},ov=r=>r instanceof RegExp,sc=r=>Rt(r)?void 0:ov(r)?r.source:_r(r)?ov(r.value)?r.value.source:r.value:r,R5=r=>r.mount&&(r.required||r.min||r.max||r.maxLength||r.minLength||r.pattern||r.validate);function FD(r,e,t){const n=be(r,t);if(n||Ly(t))return{error:n,name:t};const a=t.split(".");for(;a.length;){const i=a.join("."),o=be(e,i),s=be(r,i);if(o&&!Array.isArray(o)&&t!==i)return{name:t};if(s&&s.type)return{name:i,error:s};a.pop()}return{name:t}}var j5=(r,e,t,n,a)=>a.isOnAll?!1:!t&&a.isOnTouch?!(e||r):(t?n.isOnBlur:a.isOnBlur)?!r:(t?n.isOnChange:a.isOnChange)?r:!0,B5=(r,e)=>!Kh(be(r,e)).length&&Wr(r,e),sv=r=>La(r)||pe.default.isValidElement(r);function VD(r,e,t="validate"){if(sv(r)||Array.isArray(r)&&r.every(sv)||av(r)&&!r)return{type:t,message:sv(r)?r:"",ref:e}}var Sl=r=>_r(r)&&!ov(r)?r:{value:r,message:""},HD=async(r,e,t,n)=>{const{ref:a,refs:i,required:o,maxLength:s,minLength:l,min:u,max:c,pattern:f,validate:h,name:v,valueAsNumber:d,mount:p,disabled:g}=r._f;if(!p||g)return{};const y=i?i[0]:a,m=I=>{n&&y.reportValidity&&(y.setCustomValidity(av(I)?"":I||" "),y.reportValidity())},_={},b=Ry(a),x=oc(a),M=b||x,w=(d||zy(a))&&!a.value||e===""||Array.isArray(e)&&!e.length,D=O5.bind(null,v,t,_),T=(I,A,N,L=ni.maxLength,E=ni.minLength)=>{const O=I?A:N;_[v]={type:I?L:E,message:O,ref:a,...D(I?L:E,O)}};if(o&&(!M&&(w||Nr(e))||av(e)&&!e||x&&!kD(i).isValid||b&&!BD(i).isValid)){const{value:I,message:A}=sv(o)?{value:!!o,message:o}:Sl(o);if(I&&(_[v]={type:ni.required,message:A,ref:y,...D(ni.required,A)},!t))return m(A),_}if(!w&&(!Nr(u)||!Nr(c))){let I,A;const N=Sl(c),L=Sl(u);if(!Nr(e)&&!isNaN(e)){const E=a.valueAsNumber||+e;Nr(N.value)||(I=E>N.value),Nr(L.value)||(A=E<L.value)}else{const E=a.valueAsDate||new Date(e);La(N.value)&&(I=E>new Date(N.value)),La(L.value)&&(A=E<new Date(L.value))}if((I||A)&&(T(!!I,N.message,L.message,ni.max,ni.min),!t))return m(_[v].message),_}if((s||l)&&!w&&La(e)){const I=Sl(s),A=Sl(l),N=!Nr(I.value)&&e.length>I.value,L=!Nr(A.value)&&e.length<A.value;if((N||L)&&(T(N,I.message,A.message),!t))return m(_[v].message),_}if(f&&!w&&La(e)){const{value:I,message:A}=Sl(f);if(ov(I)&&!e.match(I)&&(_[v]={type:ni.pattern,message:A,ref:a,...D(ni.pattern,A)},!t))return m(A),_}if(h){if(rv(h)){const I=await h(e),A=VD(I,y);if(A&&(_[v]={...A,...D(ni.validate,A.message)},!t))return m(A.message),_}else if(_r(h)){let I={};for(const A in h){if(!En(I)&&!t)break;const N=VD(await h[A](e),y,A);N&&(I={...N,...D(A,N.message)},m(N.message),t&&(_[v]=I))}if(!En(I)&&(_[v]={ref:y,...I},!t))return _}}return m(!0),_};const F5={mode:oa.onSubmit,reValidateMode:oa.onChange,shouldFocusError:!0};function V5(r={}){let e={...F5,...r},t={isDirty:!1,isValidating:!1,dirtyFields:{},isSubmitted:!1,submitCount:0,touchedFields:{},isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,errors:{}},n={},a=Vo(e.defaultValues)||{},i=e.shouldUnregister?{}:Vo(a),o={action:!1,mount:!1,watch:!1},s={mount:new Set,unMount:new Set,array:new Set,watch:new Set},l,u=0,c={};const f={isDirty:!1,dirtyFields:!1,touchedFields:!1,isValidating:!1,isValid:!1,errors:!1},h={watch:Py(),array:Py(),state:Py()},v=LD(e.mode),d=LD(e.reValidateMode),p=e.criteriaMode===oa.all,g=k=>j=>{clearTimeout(u),u=window.setTimeout(k,j)},y=async k=>{let j=!1;return f.isValid&&(j=e.resolver?En((await w()).errors):await T(n,!0),!k&&j!==t.isValid&&(t.isValid=j,h.state.next({isValid:j}))),j},m=(k,j=[],W,ae,re=!0,ee=!0)=>{if(ae&&W){if(o.action=!0,ee&&Array.isArray(be(n,k))){const se=W(be(n,k),ae.argA,ae.argB);re&&jt(n,k,se)}if(f.errors&&ee&&Array.isArray(be(t.errors,k))){const se=W(be(t.errors,k),ae.argA,ae.argB);re&&jt(t.errors,k,se),B5(t.errors,k)}if(f.touchedFields&&ee&&Array.isArray(be(t.touchedFields,k))){const se=W(be(t.touchedFields,k),ae.argA,ae.argB);re&&jt(t.touchedFields,k,se)}f.dirtyFields&&(t.dirtyFields=By(a,i)),h.state.next({isDirty:A(k,j),dirtyFields:t.dirtyFields,errors:t.errors,isValid:t.isValid})}else jt(i,k,j)},_=(k,j)=>{jt(t.errors,k,j),h.state.next({errors:t.errors})},b=(k,j,W,ae)=>{const re=be(n,k);if(re){const ee=be(i,k,Rt(W)?be(a,k):W);Rt(ee)||ae&&ae.defaultChecked||j?jt(i,k,j?ee:Fy(re._f)):E(k,ee),o.mount&&y()}},x=(k,j,W,ae,re)=>{let ee=!1;const se={name:k},Le=be(t.touchedFields,k);if(f.isDirty){const dt=t.isDirty;t.isDirty=se.isDirty=A(),ee=dt!==se.isDirty}if(f.dirtyFields&&(!W||ae)){const dt=be(t.dirtyFields,k);Dl(be(a,k),j)?Wr(t.dirtyFields,k):jt(t.dirtyFields,k,!0),se.dirtyFields=t.dirtyFields,ee=ee||dt!==be(t.dirtyFields,k)}return W&&!Le&&(jt(t.touchedFields,k,W),se.touchedFields=t.touchedFields,ee=ee||f.touchedFields&&Le!==W),ee&&re&&h.state.next(se),ee?se:{}},M=async(k,j,W,ae)=>{const re=be(t.errors,k),ee=f.isValid&&t.isValid!==j;if(r.delayError&&W?(l=g(()=>_(k,W)),l(r.delayError)):(clearTimeout(u),l=null,W?jt(t.errors,k,W):Wr(t.errors,k)),(W?!Dl(re,W):re)||!En(ae)||ee){const se={...ae,...ee?{isValid:j}:{},errors:t.errors,name:k};t={...t,...se},h.state.next(se)}c[k]--,f.isValidating&&!Object.values(c).some(se=>se)&&(h.state.next({isValidating:!1}),c={})},w=async k=>e.resolver?await e.resolver({...i},e.context,k5(k||s.mount,n,e.criteriaMode,e.shouldUseNativeValidation)):{},D=async k=>{const{errors:j}=await w();if(k)for(const W of k){const ae=be(j,W);ae?jt(t.errors,W,ae):Wr(t.errors,W)}else t.errors=j;return j},T=async(k,j,W={valid:!0})=>{for(const ae in k){const re=k[ae];if(re){const{_f:ee,...se}=re;if(ee){const Le=await HD(re,be(i,ee.name),p,e.shouldUseNativeValidation);if(Le[ee.name]&&(W.valid=!1,j))break;j||(Le[ee.name]?jt(t.errors,ee.name,Le[ee.name]):Wr(t.errors,ee.name))}se&&await T(se,j,W)}}return W.valid},I=()=>{for(const k of s.unMount){const j=be(n,k);j&&(j._f.refs?j._f.refs.every(W=>!jy(W)):!jy(j._f.ref))&&q(k)}s.unMount=new Set},A=(k,j)=>(k&&j&&jt(i,k,j),!Dl(G(),a)),N=(k,j,W)=>{const ae={...o.mount?i:Rt(j)?a:La(k)?{[k]:j}:j};return AD(k,s,ae,W)},L=k=>Kh(be(o.mount?i:a,k,r.shouldUnregister?be(a,k,[]):[])),E=(k,j,W={})=>{const ae=be(n,k);let re=j;if(ae){const ee=ae._f;ee&&(!ee.disabled&&jt(i,k,RD(j,ee)),re=Oy&&ky(ee.ref)&&Nr(j)?"":j,ED(ee.ref)?[...ee.ref.options].forEach(se=>se.selected=re.includes(se.value)):ee.refs?oc(ee.ref)?ee.refs.length>1?ee.refs.forEach(se=>!se.disabled&&(se.checked=Array.isArray(re)?!!re.find(Le=>Le===se.value):re===se.value)):ee.refs[0]&&(ee.refs[0].checked=!!re):ee.refs.forEach(se=>se.checked=se.value===re):zy(ee.ref)?ee.ref.value="":(ee.ref.value=re,ee.ref.type||h.watch.next({name:k})))}(W.shouldDirty||W.shouldTouch)&&x(k,re,W.shouldTouch,W.shouldDirty,!0),W.shouldValidate&&F(k)},O=(k,j,W)=>{for(const ae in j){const re=j[ae],ee=`${k}.${ae}`,se=be(n,ee);(s.array.has(k)||!nv(re)||se&&!se._f)&&!wl(re)?O(ee,re,W):E(ee,re,W)}},P=(k,j,W={})=>{const ae=be(n,k),re=s.array.has(k),ee=Vo(j);jt(i,k,ee),re?(h.array.next({name:k,values:i}),(f.isDirty||f.dirtyFields)&&W.shouldDirty&&(t.dirtyFields=By(a,i),h.state.next({name:k,dirtyFields:t.dirtyFields,isDirty:A(k,ee)}))):ae&&!ae._f&&!Nr(ee)?O(k,ee,W):E(k,ee,W),ND(k,s)&&h.state.next({}),h.watch.next({name:k})},H=async k=>{const j=k.target;let W=j.name;const ae=be(n,W);if(ae){let re,ee;const se=j.type?Fy(ae._f):wD(k),Le=k.type===ev.BLUR||k.type===ev.FOCUS_OUT,dt=!R5(ae._f)&&!e.resolver&&!be(t.errors,W)&&!ae._f.deps||j5(Le,be(t.touchedFields,W),t.isSubmitted,d,v),pt=ND(W,s,Le);jt(i,W,se),Le?(ae._f.onBlur&&ae._f.onBlur(k),l&&l(0)):ae._f.onChange&&ae._f.onChange(k);const _t=x(W,se,Le,!1),zt=!En(_t)||pt;if(!Le&&h.watch.next({name:W,type:k.type}),dt)return zt&&h.state.next({name:W,...pt?{}:_t});if(!Le&&pt&&h.state.next({}),c[W]=(c[W],1),h.state.next({isValidating:!0}),e.resolver){const{errors:qt}=await w([W]),Cn=FD(t.errors,n,W),nn=FD(qt,n,Cn.name||W);re=nn.error,W=nn.name,ee=En(qt)}else re=(await HD(ae,be(i,W),p,e.shouldUseNativeValidation))[W],ee=await y(!0);ae._f.deps&&F(ae._f.deps),M(W,ee,re,_t)}},F=async(k,j={})=>{let W,ae;const re=tv(k);if(h.state.next({isValidating:!0}),e.resolver){const ee=await D(Rt(k)?k:re);W=En(ee),ae=k?!re.some(se=>be(ee,se)):W}else k?(ae=(await Promise.all(re.map(async ee=>{const se=be(n,ee);return await T(se&&se._f?{[ee]:se}:se)}))).every(Boolean),!(!ae&&!t.isValid)&&y()):ae=W=await T(n);return h.state.next({...!La(k)||f.isValid&&W!==t.isValid?{}:{name:k},...e.resolver?{isValid:W}:{},errors:t.errors,isValidating:!1}),j.shouldFocus&&!ae&&Ey(n,ee=>be(t.errors,ee),k?re:s.mount),ae},G=k=>{const j={...a,...o.mount?i:{}};return Rt(k)?j:La(k)?be(j,k):k.map(W=>be(j,W))},Z=(k,j)=>({invalid:!!be((j||t).errors,k),isDirty:!!be((j||t).dirtyFields,k),isTouched:!!be((j||t).touchedFields,k),error:be((j||t).errors,k)}),te=k=>{k?tv(k).forEach(j=>Wr(t.errors,j)):t.errors={},h.state.next({errors:t.errors})},V=(k,j,W)=>{const ae=(be(n,k,{_f:{}})._f||{}).ref;jt(t.errors,k,{...j,ref:ae}),h.state.next({name:k,errors:t.errors,isValid:!1}),W&&W.shouldFocus&&ae&&ae.focus&&ae.focus()},Y=(k,j)=>rv(k)?h.watch.subscribe({next:W=>k(N(void 0,j),W)}):N(k,j,!0),q=(k,j={})=>{for(const W of k?tv(k):s.mount)s.mount.delete(W),s.array.delete(W),be(n,W)&&(j.keepValue||(Wr(n,W),Wr(i,W)),!j.keepError&&Wr(t.errors,W),!j.keepDirty&&Wr(t.dirtyFields,W),!j.keepTouched&&Wr(t.touchedFields,W),!e.shouldUnregister&&!j.keepDefaultValue&&Wr(a,W));h.watch.next({}),h.state.next({...t,...j.keepDirty?{isDirty:A()}:{}}),!j.keepIsValid&&y()},Q=(k,j={})=>{let W=be(n,k);const ae=av(j.disabled);return jt(n,k,{_f:{...W&&W._f?W._f:{ref:{name:k}},name:k,mount:!0,...j}}),s.mount.add(k),W?ae&&jt(i,k,j.disabled?void 0:be(i,k,Fy(W._f))):b(k,!0,j.value),{...ae?{disabled:j.disabled}:{},...e.shouldUseNativeValidation?{required:!!j.required,min:sc(j.min),max:sc(j.max),minLength:sc(j.minLength),maxLength:sc(j.maxLength),pattern:sc(j.pattern)}:{},name:k,onChange:H,onBlur:H,ref:re=>{if(re){Q(k,j),W=be(n,k);const ee=Rt(re.value)&&re.querySelectorAll&&re.querySelectorAll("input,select,textarea")[0]||re,se=z5(ee),Le=W._f.refs||[];if(se?Le.find(dt=>dt===ee):ee===W._f.ref)return;jt(n,k,{_f:{...W._f,...se?{refs:[...Le.filter(jy),ee,...Array.isArray(be(a,k))?[{}]:[]],ref:{type:ee.type,name:k}}:{ref:ee}}}),b(k,!1,void 0,ee)}else W=be(n,k,{}),W._f&&(W._f.mount=!1),(e.shouldUnregister||j.shouldUnregister)&&!(DD(s.array,k)&&o.action)&&s.unMount.add(k)}}};return{control:{register:Q,unregister:q,getFieldState:Z,_executeSchema:w,_getWatch:N,_getDirty:A,_updateValid:y,_removeUnmounted:I,_updateFieldArray:m,_getFieldArray:L,_subjects:h,_proxyFormState:f,get _fields(){return n},get _formValues(){return i},get _stateFlags(){return o},set _stateFlags(k){o=k},get _defaultValues(){return a},get _names(){return s},set _names(k){s=k},get _formState(){return t},set _formState(k){t=k},get _options(){return e},set _options(k){e={...e,...k}}},trigger:F,register:Q,handleSubmit:(k,j)=>async W=>{W&&(W.preventDefault&&W.preventDefault(),W.persist&&W.persist());let ae=!0,re=Vo(i);h.state.next({isSubmitting:!0});try{if(e.resolver){const{errors:ee,values:se}=await w();t.errors=ee,re=se}else await T(n);En(t.errors)?(h.state.next({errors:{},isSubmitting:!0}),await k(re,W)):(j&&await j({...t.errors},W),e.shouldFocusError&&Ey(n,ee=>be(t.errors,ee),s.mount))}catch(ee){throw ae=!1,ee}finally{t.isSubmitted=!0,h.state.next({isSubmitted:!0,isSubmitting:!1,isSubmitSuccessful:En(t.errors)&&ae,submitCount:t.submitCount+1,errors:t.errors})}},watch:Y,setValue:P,getValues:G,reset:(k,j={})=>{const W=k||a,ae=Vo(W),re=k&&!En(k)?ae:a;if(j.keepDefaultValues||(a=W),!j.keepValues){if(j.keepDirtyValues)for(const ee of s.mount)be(t.dirtyFields,ee)?jt(re,ee,be(i,ee)):P(ee,be(re,ee));else{if(Oy&&Rt(k))for(const ee of s.mount){const se=be(n,ee);if(se&&se._f){const Le=Array.isArray(se._f.refs)?se._f.refs[0]:se._f.ref;try{ky(Le)&&Le.closest("form").reset();break}catch{}}}n={}}i=r.shouldUnregister?j.keepDefaultValues?Vo(a):{}:ae,h.array.next({values:re}),h.watch.next({values:re})}s={mount:new Set,unMount:new Set,array:new Set,watch:new Set,watchAll:!1,focus:""},o.mount=!f.isValid||!!j.keepIsValid,o.watch=!!r.shouldUnregister,h.state.next({submitCount:j.keepSubmitCount?t.submitCount:0,isDirty:j.keepDirty||j.keepDirtyValues?t.isDirty:!!(j.keepDefaultValues&&!Dl(k,a)),isSubmitted:j.keepIsSubmitted?t.isSubmitted:!1,dirtyFields:j.keepDirty||j.keepDirtyValues?t.dirtyFields:j.keepDefaultValues&&k?By(a,k):{},touchedFields:j.keepTouched?t.touchedFields:{},errors:j.keepErrors?t.errors:{},isSubmitting:!1,isSubmitSuccessful:!1})},resetField:(k,j={})=>{be(n,k)&&(Rt(j.defaultValue)?P(k,be(a,k)):(P(k,j.defaultValue),jt(a,k,j.defaultValue)),j.keepTouched||Wr(t.touchedFields,k),j.keepDirty||(Wr(t.dirtyFields,k),t.isDirty=j.defaultValue?A(k,be(a,k)):A()),j.keepError||(Wr(t.errors,k),f.isValid&&y()),h.state.next({...t}))},clearErrors:te,unregister:q,setError:V,setFocus:(k,j={})=>{const W=be(n,k)._f,ae=W.refs?W.refs[0]:W.ref;ae.focus(),j.shouldSelect&&ae.select()},getFieldState:Z}}function Vy(r={}){const e=pe.default.useRef(),[t,n]=pe.default.useState({isDirty:!1,isValidating:!1,dirtyFields:{},isSubmitted:!1,submitCount:0,touchedFields:{},isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,errors:{}});e.current?e.current.control._options=r:e.current={...V5(r),formState:t};const a=e.current.control,i=pe.default.useCallback(o=>{ID(o,a._proxyFormState,!0)&&(a._formState={...a._formState,...o},n({...a._formState}))},[a]);return Ay({subject:a._subjects.state,callback:i}),pe.default.useEffect(()=>{a._stateFlags.mount||(a._proxyFormState.isValid&&a._updateValid(),a._stateFlags.mount=!0),a._stateFlags.watch&&(a._stateFlags.watch=!1,a._subjects.state.next({})),a._removeUnmounted()}),e.current.formState=SD(t,a._proxyFormState),e.current}const WD=typeof window=="undefined"||typeof document=="undefined";let Lr=WD?R.useEffect:R.useLayoutEffect;function Vi(r){let e=R.useRef(r);return Lr(()=>{e.current=r},[r]),e}function GD(r,e){let[t,n]=R.useState(r),a=Vi(r);return Lr(()=>n(a.current),[a,n,...e]),t}function H5(r){typeof queueMicrotask=="function"?queueMicrotask(r):Promise.resolve().then(r).catch(e=>setTimeout(()=>{throw e}))}function Ho(){let r=[],e=[],t={enqueue(n){e.push(n)},addEventListener(n,a,i,o){return n.addEventListener(a,i,o),t.add(()=>n.removeEventListener(a,i,o))},requestAnimationFrame(...n){let a=requestAnimationFrame(...n);return t.add(()=>cancelAnimationFrame(a))},nextFrame(...n){return t.requestAnimationFrame(()=>t.requestAnimationFrame(...n))},setTimeout(...n){let a=setTimeout(...n);return t.add(()=>clearTimeout(a))},microTask(...n){let a={current:!0};return H5(()=>{a.current&&n[0]()}),t.add(()=>{a.current=!1})},add(n){return r.push(n),()=>{let a=r.indexOf(n);if(a>=0){let[i]=r.splice(a,1);i()}}},dispose(){for(let n of r.splice(0))n()},async workQueue(){for(let n of e.splice(0))await n()}};return t}function lc(){let[r]=R.useState(Ho);return R.useEffect(()=>()=>r.dispose(),[r]),r}let nr=function(r){let e=Vi(r);return pe.default.useCallback((...t)=>e.current(...t),[e])},Hy={serverHandoffComplete:!1};function Wy(){let[r,e]=R.useState(Hy.serverHandoffComplete);return R.useEffect(()=>{r!==!0&&e(!0)},[r]),R.useEffect(()=>{Hy.serverHandoffComplete===!1&&(Hy.serverHandoffComplete=!0)},[]),r}var $D;let W5=0;function UD(){return++W5}let lv=($D=pe.default.useId)!=null?$D:function(){let r=Wy(),[e,t]=pe.default.useState(r?UD:null);return Lr(()=>{e===null&&t(UD())},[e]),e!=null?""+e:void 0};function $t(r,e,...t){if(r in e){let a=e[r];return typeof a=="function"?a(...t):a}let n=new Error(`Tried to handle "${r}" but there is no handler defined. Only defined handlers are: ${Object.keys(e).map(a=>`"${a}"`).join(", ")}.`);throw Error.captureStackTrace&&Error.captureStackTrace(n,$t),n}function YD(r){return WD?null:r instanceof Node?r.ownerDocument:r!=null&&r.hasOwnProperty("current")&&r.current instanceof Node?r.current.ownerDocument:document}let QD=["[contentEditable=true]","[tabindex]","a[href]","area[href]","button:not([disabled])","iframe","input:not([disabled])","select:not([disabled])","textarea:not([disabled])"].map(r=>`${r}:not([tabindex='-1'])`).join(",");var G5=(r=>(r[r.First=1]="First",r[r.Previous=2]="Previous",r[r.Next=4]="Next",r[r.Last=8]="Last",r[r.WrapAround=16]="WrapAround",r[r.NoScroll=32]="NoScroll",r))(G5||{}),$5=(r=>(r[r.Error=0]="Error",r[r.Overflow=1]="Overflow",r[r.Success=2]="Success",r[r.Underflow=3]="Underflow",r))($5||{}),U5=(r=>(r[r.Previous=-1]="Previous",r[r.Next=1]="Next",r))(U5||{}),Gy=(r=>(r[r.Strict=0]="Strict",r[r.Loose=1]="Loose",r))(Gy||{});function ZD(r,e=0){var t;return r===((t=YD(r))==null?void 0:t.body)?!1:$t(e,{[0](){return r.matches(QD)},[1](){let n=r;for(;n!==null;){if(n.matches(QD))return!0;n=n.parentElement}return!1}})}function Y5(r,e=t=>t){return r.slice().sort((t,n)=>{let a=e(t),i=e(n);if(a===null||i===null)return 0;let o=a.compareDocumentPosition(i);return o&Node.DOCUMENT_POSITION_FOLLOWING?-1:o&Node.DOCUMENT_POSITION_PRECEDING?1:0})}function $y(r,e,t){let n=Vi(e);R.useEffect(()=>{function a(i){n.current(i)}return document.addEventListener(r,a,t),()=>document.removeEventListener(r,a,t)},[r,t])}function Q5(r,e,t=!0){let n=R.useRef(!1);R.useEffect(()=>{requestAnimationFrame(()=>{n.current=t})},[t]);function a(o,s){if(!n.current||o.defaultPrevented)return;let l=function c(f){return typeof f=="function"?c(f()):Array.isArray(f)||f instanceof Set?f:[f]}(r),u=s(o);if(u!==null&&!!u.ownerDocument.documentElement.contains(u)){for(let c of l){if(c===null)continue;let f=c instanceof HTMLElement?c:c.current;if(f!=null&&f.contains(u))return}return!ZD(u,Gy.Loose)&&u.tabIndex!==-1&&o.preventDefault(),e(o,u)}}let i=R.useRef(null);$y("mousedown",o=>{n.current&&(i.current=o.target)},!0),$y("click",o=>{!i.current||(a(o,()=>i.current),i.current=null)},!0),$y("blur",o=>a(o,()=>window.document.activeElement instanceof HTMLIFrameElement?window.document.activeElement:null),!0)}function qD(r){var e;if(r.type)return r.type;let t=(e=r.as)!=null?e:"button";if(typeof t=="string"&&t.toLowerCase()==="button")return"button"}function Z5(r,e){let[t,n]=R.useState(()=>qD(r));return Lr(()=>{n(qD(r))},[r.type,r.as]),Lr(()=>{t||!e.current||e.current instanceof HTMLButtonElement&&!e.current.hasAttribute("type")&&n("button")},[t,e]),t}let q5=Symbol();function Wo(...r){let e=R.useRef(r);R.useEffect(()=>{e.current=r},[r]);let t=nr(n=>{for(let a of e.current)a!=null&&(typeof a=="function"?a(n):a.current=n)});return r.every(n=>n==null||(n==null?void 0:n[q5]))?void 0:t}function X5(r){throw new Error("Unexpected object: "+r)}var sa=(r=>(r[r.First=0]="First",r[r.Previous=1]="Previous",r[r.Next=2]="Next",r[r.Last=3]="Last",r[r.Specific=4]="Specific",r[r.Nothing=5]="Nothing",r))(sa||{});function J5(r,e){let t=e.resolveItems();if(t.length<=0)return null;let n=e.resolveActiveIndex(),a=n!=null?n:-1,i=(()=>{switch(r.focus){case 0:return t.findIndex(o=>!e.resolveDisabled(o));case 1:{let o=t.slice().reverse().findIndex((s,l,u)=>a!==-1&&u.length-l-1>=a?!1:!e.resolveDisabled(s));return o===-1?o:t.length-1-o}case 2:return t.findIndex((o,s)=>s<=a?!1:!e.resolveDisabled(o));case 3:{let o=t.slice().reverse().findIndex(s=>!e.resolveDisabled(s));return o===-1?o:t.length-1-o}case 4:return t.findIndex(o=>e.resolveId(o)===r.id);case 5:return null;default:X5(r)}})();return i===-1?n:i}var uv=(r=>(r[r.None=0]="None",r[r.RenderStrategy=1]="RenderStrategy",r[r.Static=2]="Static",r))(uv||{}),ai=(r=>(r[r.Unmount=0]="Unmount",r[r.Hidden=1]="Hidden",r))(ai||{});function Hi({ourProps:r,theirProps:e,slot:t,defaultTag:n,features:a,visible:i=!0,name:o}){let s=XD(e,r);if(i)return cv(s,t,n,o);let l=a!=null?a:0;if(l&2){let{static:u=!1,...c}=s;if(u)return cv(c,t,n,o)}if(l&1){let{unmount:u=!0,...c}=s;return $t(u?0:1,{[0](){return null},[1](){return cv({...c,hidden:!0,style:{display:"none"}},t,n,o)}})}return cv(s,t,n,o)}function cv(r,e={},t,n){let{as:a=t,children:i,refName:o="ref",...s}=Yy(r,["unmount","static"]),l=r.ref!==void 0?{[o]:r.ref}:{},u=typeof i=="function"?i(e):i;s.className&&typeof s.className=="function"&&(s.className=s.className(e));let c={};if(e){let f=!1,h=[];for(let[v,d]of Object.entries(e))typeof d=="boolean"&&(f=!0),d===!0&&h.push(v);f&&(c["data-headlessui-state"]=h.join(" "))}if(a===R.Fragment&&Object.keys(Uy(s)).length>0){if(!R.isValidElement(u)||Array.isArray(u)&&u.length>1)throw new Error(['Passing props on "Fragment"!',"",`The current component <${n} /> is rendering a "Fragment".`,"However we need to passthrough the following props:",Object.keys(s).map(f=>` - ${f}`).join(`
|
|
14
|
+
`),"","You can apply a few solutions:",['Add an `as="..."` prop, to ensure that we render an actual element instead of a "Fragment".',"Render a single element as the child so that we can forward the props onto that element."].map(f=>` - ${f}`).join(`
|
|
15
|
+
`)].join(`
|
|
16
|
+
`));return R.cloneElement(u,Object.assign({},XD(u.props,Uy(Yy(s,["ref"]))),c,l,K5(u.ref,l.ref)))}return R.createElement(a,Object.assign({},Yy(s,["ref"]),a!==R.Fragment&&l,a!==R.Fragment&&c),u)}function K5(...r){return{ref:r.every(e=>e==null)?void 0:e=>{for(let t of r)t!=null&&(typeof t=="function"?t(e):t.current=e)}}}function XD(...r){if(r.length===0)return{};if(r.length===1)return r[0];let e={},t={};for(let n of r)for(let a in n)a.startsWith("on")&&typeof n[a]=="function"?(t[a]!=null||(t[a]=[]),t[a].push(n[a])):e[a]=n[a];if(e.disabled||e["aria-disabled"])return Object.assign(e,Object.fromEntries(Object.keys(t).map(n=>[n,void 0])));for(let n in t)Object.assign(e,{[n](a,...i){let o=t[n];for(let s of o){if((a instanceof Event||(a==null?void 0:a.nativeEvent)instanceof Event)&&a.defaultPrevented)return;s(a,...i)}}});return e}function ii(r){var e;return Object.assign(R.forwardRef(r),{displayName:(e=r.displayName)!=null?e:r.name})}function Uy(r){let e=Object.assign({},r);for(let t in e)e[t]===void 0&&delete e[t];return e}function Yy(r,e=[]){let t=Object.assign({},r);for(let n of e)n in t&&delete t[n];return t}function eB(r){let e=r.parentElement,t=null;for(;e&&!(e instanceof HTMLFieldSetElement);)e instanceof HTMLLegendElement&&(t=e),e=e.parentElement;let n=(e==null?void 0:e.getAttribute("disabled"))==="";return n&&tB(t)?!1:n}function tB(r){if(!r)return!1;let e=r.previousElementSibling;for(;e!==null;){if(e instanceof HTMLLegendElement)return!1;e=e.previousElementSibling}return!0}function JD(r={},e=null,t=[]){for(let[n,a]of Object.entries(r))eS(t,KD(e,n),a);return t}function KD(r,e){return r?r+"["+e+"]":e}function eS(r,e,t){if(Array.isArray(t))for(let[n,a]of t.entries())eS(r,KD(e,n.toString()),a);else t instanceof Date?r.push([e,t.toISOString()]):typeof t=="boolean"?r.push([e,t?"1":"0"]):typeof t=="string"?r.push([e,t]):typeof t=="number"?r.push([e,`${t}`]):t==null?r.push([e,""]):JD(t,e,r)}let rB="div";var tS=(r=>(r[r.None=1]="None",r[r.Focusable=2]="Focusable",r[r.Hidden=4]="Hidden",r))(tS||{});let nB=ii(function(r,e){let{features:t=1,...n}=r,a={ref:e,"aria-hidden":(t&2)===2?!0:void 0,style:{position:"fixed",top:1,left:1,width:1,height:0,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0",...(t&4)===4&&(t&2)!==2&&{display:"none"}}};return Hi({ourProps:a,theirProps:n,slot:{},defaultTag:rB,name:"Hidden"})}),Qy=R.createContext(null);Qy.displayName="OpenClosedContext";var Wi=(r=>(r[r.Open=0]="Open",r[r.Closed=1]="Closed",r))(Wi||{});function Zy(){return R.useContext(Qy)}function rS({value:r,children:e}){return pe.default.createElement(Qy.Provider,{value:r},e)}var hr=(r=>(r.Space=" ",r.Enter="Enter",r.Escape="Escape",r.Backspace="Backspace",r.Delete="Delete",r.ArrowLeft="ArrowLeft",r.ArrowUp="ArrowUp",r.ArrowRight="ArrowRight",r.ArrowDown="ArrowDown",r.Home="Home",r.End="End",r.PageUp="PageUp",r.PageDown="PageDown",r.Tab="Tab",r))(hr||{});function aB(r,e,t){let[n,a]=R.useState(t),i=r!==void 0;return[i?r:n,nr(o=>(i||a(o),e==null?void 0:e(o)))]}function nS(){let r=R.useRef(!1);return Lr(()=>(r.current=!0,()=>{r.current=!1}),[]),r}var iB=(r=>(r[r.Open=0]="Open",r[r.Closed=1]="Closed",r))(iB||{}),oB=(r=>(r[r.Single=0]="Single",r[r.Multi=1]="Multi",r))(oB||{}),sB=(r=>(r[r.Pointer=0]="Pointer",r[r.Other=1]="Other",r))(sB||{}),lB=(r=>(r[r.OpenListbox=0]="OpenListbox",r[r.CloseListbox=1]="CloseListbox",r[r.SetDisabled=2]="SetDisabled",r[r.SetOrientation=3]="SetOrientation",r[r.GoToOption=4]="GoToOption",r[r.Search=5]="Search",r[r.ClearSearch=6]="ClearSearch",r[r.RegisterOption=7]="RegisterOption",r[r.UnregisterOption=8]="UnregisterOption",r))(lB||{});function qy(r,e=t=>t){let t=r.activeOptionIndex!==null?r.options[r.activeOptionIndex]:null,n=Y5(e(r.options.slice()),i=>i.dataRef.current.domRef.current),a=t?n.indexOf(t):null;return a===-1&&(a=null),{options:n,activeOptionIndex:a}}let uB={[1](r){return r.disabled||r.listboxState===1?r:{...r,activeOptionIndex:null,listboxState:1}},[0](r){if(r.disabled||r.listboxState===0)return r;let e=r.activeOptionIndex,{value:t,mode:n,compare:a}=r.propsRef.current,i=r.options.findIndex(o=>{let s=o.dataRef.current.value;return $t(n,{[1]:()=>t.some(l=>a(l,s)),[0]:()=>a(t,s)})});return i!==-1&&(e=i),{...r,listboxState:0,activeOptionIndex:e}},[2](r,e){return r.disabled===e.disabled?r:{...r,disabled:e.disabled}},[3](r,e){return r.orientation===e.orientation?r:{...r,orientation:e.orientation}},[4](r,e){var t;if(r.disabled||r.listboxState===1)return r;let n=qy(r),a=J5(e,{resolveItems:()=>n.options,resolveActiveIndex:()=>n.activeOptionIndex,resolveId:i=>i.id,resolveDisabled:i=>i.dataRef.current.disabled});return{...r,...n,searchQuery:"",activeOptionIndex:a,activationTrigger:(t=e.trigger)!=null?t:1}},[5]:(r,e)=>{if(r.disabled||r.listboxState===1)return r;let t=r.searchQuery!==""?0:1,n=r.searchQuery+e.value.toLowerCase(),a=(r.activeOptionIndex!==null?r.options.slice(r.activeOptionIndex+t).concat(r.options.slice(0,r.activeOptionIndex+t)):r.options).find(o=>{var s;return!o.dataRef.current.disabled&&((s=o.dataRef.current.textValue)==null?void 0:s.startsWith(n))}),i=a?r.options.indexOf(a):-1;return i===-1||i===r.activeOptionIndex?{...r,searchQuery:n}:{...r,searchQuery:n,activeOptionIndex:i,activationTrigger:1}},[6](r){return r.disabled||r.listboxState===1||r.searchQuery===""?r:{...r,searchQuery:""}},[7]:(r,e)=>{let t={id:e.id,dataRef:e.dataRef},n=qy(r,a=>[...a,t]);if(r.activeOptionIndex===null){let{value:a,mode:i,compare:o}=r.propsRef.current,s=e.dataRef.current.value;$t(i,{[1]:()=>a.some(l=>o(l,s)),[0]:()=>o(a,s)})&&(n.activeOptionIndex=n.options.indexOf(t))}return{...r,...n}},[8]:(r,e)=>{let t=qy(r,n=>{let a=n.findIndex(i=>i.id===e.id);return a!==-1&&n.splice(a,1),n});return{...r,...t,activationTrigger:1}}},Xy=R.createContext(null);Xy.displayName="ListboxContext";function uc(r){let e=R.useContext(Xy);if(e===null){let t=new Error(`<${r} /> is missing a parent <Listbox /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(t,uc),t}return e}function cB(r,e){return $t(e.type,uB,r,e)}let fB=R.Fragment,hB=ii(function(r,e){let{value:t,defaultValue:n,name:a,onChange:i,by:o=(w,D)=>w===D,disabled:s=!1,horizontal:l=!1,multiple:u=!1,...c}=r;const f=l?"horizontal":"vertical";let h=Wo(e),[v,d]=aB(t,i,n),p=R.useReducer(cB,{listboxState:1,propsRef:{current:{value:v,onChange:d,mode:u?1:0,compare:nr(typeof o=="string"?(w,D)=>{let T=o;return(w==null?void 0:w[T])===(D==null?void 0:D[T])}:o)}},labelRef:R.createRef(),buttonRef:R.createRef(),optionsRef:R.createRef(),disabled:s,orientation:f,options:[],searchQuery:"",activeOptionIndex:null,activationTrigger:1}),[{listboxState:g,propsRef:y,optionsRef:m,buttonRef:_},b]=p;y.current.value=v,y.current.mode=u?1:0,Lr(()=>{y.current.onChange=w=>$t(y.current.mode,{[0](){return d(w)},[1](){let D=y.current.value.slice(),{compare:T}=y.current,I=D.findIndex(A=>T(A,w));return I===-1?D.push(w):D.splice(I,1),d(D)}})},[d,y]),Lr(()=>b({type:2,disabled:s}),[s]),Lr(()=>b({type:3,orientation:f}),[f]),Q5([_,m],(w,D)=>{var T;b({type:1}),ZD(D,Gy.Loose)||(w.preventDefault(),(T=_.current)==null||T.focus())},g===0);let x=R.useMemo(()=>({open:g===0,disabled:s,value:v}),[g,s,v]),M={ref:h};return pe.default.createElement(Xy.Provider,{value:p},pe.default.createElement(rS,{value:$t(g,{[0]:Wi.Open,[1]:Wi.Closed})},a!=null&&v!=null&&JD({[a]:v}).map(([w,D])=>pe.default.createElement(nB,{features:tS.Hidden,...Uy({key:w,as:"input",type:"hidden",hidden:!0,readOnly:!0,name:w,value:D})})),Hi({ourProps:M,theirProps:c,slot:x,defaultTag:fB,name:"Listbox"})))}),vB="button",dB=ii(function(r,e){var t;let[n,a]=uc("Listbox.Button"),i=Wo(n.buttonRef,e),o=`headlessui-listbox-button-${lv()}`,s=lc(),l=nr(p=>{switch(p.key){case hr.Space:case hr.Enter:case hr.ArrowDown:p.preventDefault(),a({type:0}),s.nextFrame(()=>{n.propsRef.current.value||a({type:4,focus:sa.First})});break;case hr.ArrowUp:p.preventDefault(),a({type:0}),s.nextFrame(()=>{n.propsRef.current.value||a({type:4,focus:sa.Last})});break}}),u=nr(p=>{switch(p.key){case hr.Space:p.preventDefault();break}}),c=nr(p=>{if(eB(p.currentTarget))return p.preventDefault();n.listboxState===0?(a({type:1}),s.nextFrame(()=>{var g;return(g=n.buttonRef.current)==null?void 0:g.focus({preventScroll:!0})})):(p.preventDefault(),a({type:0}))}),f=GD(()=>{if(n.labelRef.current)return[n.labelRef.current.id,o].join(" ")},[n.labelRef.current,o]),h=R.useMemo(()=>({open:n.listboxState===0,disabled:n.disabled,value:n.propsRef.current.value}),[n]),v=r,d={ref:i,id:o,type:Z5(r,n.buttonRef),"aria-haspopup":!0,"aria-controls":(t=n.optionsRef.current)==null?void 0:t.id,"aria-expanded":n.disabled?void 0:n.listboxState===0,"aria-labelledby":f,disabled:n.disabled,onKeyDown:l,onKeyUp:u,onClick:c};return Hi({ourProps:d,theirProps:v,slot:h,defaultTag:vB,name:"Listbox.Button"})}),pB="label",gB=ii(function(r,e){let[t]=uc("Listbox.Label"),n=`headlessui-listbox-label-${lv()}`,a=Wo(t.labelRef,e),i=nr(()=>{var s;return(s=t.buttonRef.current)==null?void 0:s.focus({preventScroll:!0})}),o=R.useMemo(()=>({open:t.listboxState===0,disabled:t.disabled}),[t]);return Hi({ourProps:{ref:a,id:n,onClick:i},theirProps:r,slot:o,defaultTag:pB,name:"Listbox.Label"})}),yB="ul",mB=uv.RenderStrategy|uv.Static,_B=ii(function(r,e){var t;let[n,a]=uc("Listbox.Options"),i=Wo(n.optionsRef,e),o=`headlessui-listbox-options-${lv()}`,s=lc(),l=lc(),u=Zy(),c=(()=>u!==null?u===Wi.Open:n.listboxState===0)();R.useEffect(()=>{var g;let y=n.optionsRef.current;!y||n.listboxState===0&&y!==((g=YD(y))==null?void 0:g.activeElement)&&y.focus({preventScroll:!0})},[n.listboxState,n.optionsRef]);let f=nr(g=>{switch(l.dispose(),g.key){case hr.Space:if(n.searchQuery!=="")return g.preventDefault(),g.stopPropagation(),a({type:5,value:g.key});case hr.Enter:if(g.preventDefault(),g.stopPropagation(),n.activeOptionIndex!==null){let{dataRef:y}=n.options[n.activeOptionIndex];n.propsRef.current.onChange(y.current.value)}n.propsRef.current.mode===0&&(a({type:1}),Ho().nextFrame(()=>{var y;return(y=n.buttonRef.current)==null?void 0:y.focus({preventScroll:!0})}));break;case $t(n.orientation,{vertical:hr.ArrowDown,horizontal:hr.ArrowRight}):return g.preventDefault(),g.stopPropagation(),a({type:4,focus:sa.Next});case $t(n.orientation,{vertical:hr.ArrowUp,horizontal:hr.ArrowLeft}):return g.preventDefault(),g.stopPropagation(),a({type:4,focus:sa.Previous});case hr.Home:case hr.PageUp:return g.preventDefault(),g.stopPropagation(),a({type:4,focus:sa.First});case hr.End:case hr.PageDown:return g.preventDefault(),g.stopPropagation(),a({type:4,focus:sa.Last});case hr.Escape:return g.preventDefault(),g.stopPropagation(),a({type:1}),s.nextFrame(()=>{var y;return(y=n.buttonRef.current)==null?void 0:y.focus({preventScroll:!0})});case hr.Tab:g.preventDefault(),g.stopPropagation();break;default:g.key.length===1&&(a({type:5,value:g.key}),l.setTimeout(()=>a({type:6}),350));break}}),h=GD(()=>{var g,y,m;return(m=(g=n.labelRef.current)==null?void 0:g.id)!=null?m:(y=n.buttonRef.current)==null?void 0:y.id},[n.labelRef.current,n.buttonRef.current]),v=R.useMemo(()=>({open:n.listboxState===0}),[n]),d=r,p={"aria-activedescendant":n.activeOptionIndex===null||(t=n.options[n.activeOptionIndex])==null?void 0:t.id,"aria-multiselectable":n.propsRef.current.mode===1?!0:void 0,"aria-labelledby":h,"aria-orientation":n.orientation,id:o,onKeyDown:f,role:"listbox",tabIndex:0,ref:i};return Hi({ourProps:p,theirProps:d,slot:v,defaultTag:yB,features:mB,visible:c,name:"Listbox.Options"})}),bB="li",MB=ii(function(r,e){let{disabled:t=!1,value:n,...a}=r,[i,o]=uc("Listbox.Option"),s=`headlessui-listbox-option-${lv()}`,l=i.activeOptionIndex!==null?i.options[i.activeOptionIndex].id===s:!1,{value:u,compare:c}=i.propsRef.current,f=$t(i.propsRef.current.mode,{[1]:()=>u.some(x=>c(x,n)),[0]:()=>c(u,n)}),h=R.useRef(null),v=Wo(e,h);Lr(()=>{if(i.listboxState!==0||!l||i.activationTrigger===0)return;let x=Ho();return x.requestAnimationFrame(()=>{var M,w;(w=(M=h.current)==null?void 0:M.scrollIntoView)==null||w.call(M,{block:"nearest"})}),x.dispose},[h,l,i.listboxState,i.activationTrigger,i.activeOptionIndex]);let d=R.useRef({disabled:t,value:n,domRef:h});Lr(()=>{d.current.disabled=t},[d,t]),Lr(()=>{d.current.value=n},[d,n]),Lr(()=>{var x,M;d.current.textValue=(M=(x=h.current)==null?void 0:x.textContent)==null?void 0:M.toLowerCase()},[d,h]);let p=nr(()=>i.propsRef.current.onChange(n));Lr(()=>(o({type:7,id:s,dataRef:d}),()=>o({type:8,id:s})),[d,s]);let g=nr(x=>{if(t)return x.preventDefault();p(),i.propsRef.current.mode===0&&(o({type:1}),Ho().nextFrame(()=>{var M;return(M=i.buttonRef.current)==null?void 0:M.focus({preventScroll:!0})}))}),y=nr(()=>{if(t)return o({type:4,focus:sa.Nothing});o({type:4,focus:sa.Specific,id:s})}),m=nr(()=>{t||l||o({type:4,focus:sa.Specific,id:s,trigger:0})}),_=nr(()=>{t||!l||o({type:4,focus:sa.Nothing})}),b=R.useMemo(()=>({active:l,selected:f,disabled:t}),[l,f,t]);return Hi({ourProps:{id:s,ref:v,role:"option",tabIndex:t===!0?void 0:-1,"aria-disabled":t===!0?!0:void 0,"aria-selected":f,disabled:void 0,onClick:g,onFocus:y,onPointerMove:m,onMouseMove:m,onPointerLeave:_,onMouseLeave:_},theirProps:a,slot:b,defaultTag:bB,name:"Listbox.Option"})}),Gr=Object.assign(hB,{Button:dB,Label:gB,Options:_B,Option:MB});function xB(r){let e={called:!1};return(...t)=>{if(!e.called)return e.called=!0,r(...t)}}function Jy(r,...e){r&&e.length>0&&r.classList.add(...e)}function Ky(r,...e){r&&e.length>0&&r.classList.remove(...e)}var em=(r=>(r.Ended="ended",r.Cancelled="cancelled",r))(em||{});function wB(r,e){let t=Ho();if(!r)return t.dispose;let{transitionDuration:n,transitionDelay:a}=getComputedStyle(r),[i,o]=[n,a].map(s=>{let[l=0]=s.split(",").filter(Boolean).map(u=>u.includes("ms")?parseFloat(u):parseFloat(u)*1e3).sort((u,c)=>c-u);return l});if(i+o!==0){let s=[];s.push(t.addEventListener(r,"transitionrun",l=>{l.target===l.currentTarget&&(s.splice(0).forEach(u=>u()),s.push(t.addEventListener(r,"transitionend",u=>{u.target===u.currentTarget&&(e("ended"),s.splice(0).forEach(c=>c()))}),t.addEventListener(r,"transitioncancel",u=>{u.target===u.currentTarget&&(e("cancelled"),s.splice(0).forEach(c=>c()))})))}))}else e("ended");return t.add(()=>e("cancelled")),t.dispose}function DB(r,e,t,n){let a=t?"enter":"leave",i=Ho(),o=n!==void 0?xB(n):()=>{};a==="enter"&&(r.removeAttribute("hidden"),r.style.display="");let s=$t(a,{enter:()=>e.enter,leave:()=>e.leave}),l=$t(a,{enter:()=>e.enterTo,leave:()=>e.leaveTo}),u=$t(a,{enter:()=>e.enterFrom,leave:()=>e.leaveFrom});return Ky(r,...e.enter,...e.enterTo,...e.enterFrom,...e.leave,...e.leaveFrom,...e.leaveTo,...e.entered),Jy(r,...s,...u),i.nextFrame(()=>{Ky(r,...u),Jy(r,...l),wB(r,c=>(c==="ended"&&(Ky(r,...s),Jy(r,...e.entered)),o(c)))}),i.dispose}function SB({container:r,direction:e,classes:t,onStart:n,onStop:a}){let i=nS(),o=lc(),s=Vi(e);Lr(()=>{let l=Ho();o.add(l.dispose);let u=r.current;if(!!u&&s.current!=="idle"&&!!i.current)return l.dispose(),n.current(s.current),l.add(DB(u,t.current,s.current==="enter",c=>{l.dispose(),$t(c,{[em.Ended](){a.current(s.current)},[em.Cancelled]:()=>{}})})),l.dispose},[e])}function Go(r=""){return r.split(" ").filter(e=>e.trim().length>1)}let fv=R.createContext(null);fv.displayName="TransitionContext";var IB=(r=>(r.Visible="visible",r.Hidden="hidden",r))(IB||{});function TB(){let r=R.useContext(fv);if(r===null)throw new Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return r}function AB(){let r=R.useContext(hv);if(r===null)throw new Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return r}let hv=R.createContext(null);hv.displayName="NestingContext";function vv(r){return"children"in r?vv(r.children):r.current.filter(({el:e})=>e.current!==null).filter(({state:e})=>e==="visible").length>0}function aS(r,e){let t=Vi(r),n=R.useRef([]),a=nS(),i=lc(),o=nr((v,d=ai.Hidden)=>{let p=n.current.findIndex(({el:g})=>g===v);p!==-1&&($t(d,{[ai.Unmount](){n.current.splice(p,1)},[ai.Hidden](){n.current[p].state="hidden"}}),i.microTask(()=>{var g;!vv(n)&&a.current&&((g=t.current)==null||g.call(t))}))}),s=nr(v=>{let d=n.current.find(({el:p})=>p===v);return d?d.state!=="visible"&&(d.state="visible"):n.current.push({el:v,state:"visible"}),()=>o(v,ai.Unmount)}),l=R.useRef([]),u=R.useRef(Promise.resolve()),c=R.useRef({enter:[],leave:[],idle:[]}),f=nr((v,d,p)=>{l.current.splice(0),e&&(e.chains.current[d]=e.chains.current[d].filter(([g])=>g!==v)),e==null||e.chains.current[d].push([v,new Promise(g=>{l.current.push(g)})]),e==null||e.chains.current[d].push([v,new Promise(g=>{Promise.all(c.current[d].map(([y,m])=>m)).then(()=>g())})]),d==="enter"?u.current=u.current.then(()=>e==null?void 0:e.wait.current).then(()=>p(d)):p(d)}),h=nr((v,d,p)=>{Promise.all(c.current[d].splice(0).map(([g,y])=>y)).then(()=>{var g;(g=l.current.shift())==null||g()}).then(()=>p(d))});return R.useMemo(()=>({children:n,register:s,unregister:o,onStart:f,onStop:h,wait:u,chains:c}),[s,o,n,f,h,c,u])}function CB(){}let NB=["beforeEnter","afterEnter","beforeLeave","afterLeave"];function iS(r){var e;let t={};for(let n of NB)t[n]=(e=r[n])!=null?e:CB;return t}function LB(r){let e=R.useRef(iS(r));return R.useEffect(()=>{e.current=iS(r)},[r]),e}let EB="div",oS=uv.RenderStrategy,sS=ii(function(r,e){let{beforeEnter:t,afterEnter:n,beforeLeave:a,afterLeave:i,enter:o,enterFrom:s,enterTo:l,entered:u,leave:c,leaveFrom:f,leaveTo:h,...v}=r,d=R.useRef(null),p=Wo(d,e),g=v.unmount?ai.Unmount:ai.Hidden,{show:y,appear:m,initial:_}=TB(),[b,x]=R.useState(y?"visible":"hidden"),M=AB(),{register:w,unregister:D}=M,T=R.useRef(null);R.useEffect(()=>w(d),[w,d]),R.useEffect(()=>{if(g===ai.Hidden&&!!d.current){if(y&&b!=="visible"){x("visible");return}return $t(b,{hidden:()=>D(d),visible:()=>w(d)})}},[b,d,w,D,y,g]);let I=Vi({enter:Go(o),enterFrom:Go(s),enterTo:Go(l),entered:Go(u),leave:Go(c),leaveFrom:Go(f),leaveTo:Go(h)}),A=LB({beforeEnter:t,afterEnter:n,beforeLeave:a,afterLeave:i}),N=Wy();R.useEffect(()=>{if(N&&b==="visible"&&d.current===null)throw new Error("Did you forget to passthrough the `ref` to the actual DOM node?")},[d,b,N]);let L=_&&!m,E=(()=>!N||L||T.current===y?"idle":y?"enter":"leave")(),O=nr(Z=>$t(Z,{enter:()=>A.current.beforeEnter(),leave:()=>A.current.beforeLeave(),idle:()=>{}})),P=nr(Z=>$t(Z,{enter:()=>A.current.afterEnter(),leave:()=>A.current.afterLeave(),idle:()=>{}})),H=aS(()=>{x("hidden"),D(d)},M);SB({container:d,classes:I,direction:E,onStart:Vi(Z=>{H.onStart(d,Z,O)}),onStop:Vi(Z=>{H.onStop(d,Z,P),Z==="leave"&&!vv(H)&&(x("hidden"),D(d))})}),R.useEffect(()=>{!L||(g===ai.Hidden?T.current=null:T.current=y)},[y,L,b]);let F=v,G={ref:p};return pe.default.createElement(hv.Provider,{value:H},pe.default.createElement(rS,{value:$t(b,{visible:Wi.Open,hidden:Wi.Closed})},Hi({ourProps:G,theirProps:F,defaultTag:EB,features:oS,visible:b==="visible",name:"Transition.Child"})))}),tm=ii(function(r,e){let{show:t,appear:n=!1,unmount:a,...i}=r,o=R.useRef(null),s=Wo(o,e);Wy();let l=Zy();if(t===void 0&&l!==null&&(t=$t(l,{[Wi.Open]:!0,[Wi.Closed]:!1})),![!0,!1].includes(t))throw new Error("A <Transition /> is used but it is missing a `show={true | false}` prop.");let[u,c]=R.useState(t?"visible":"hidden"),f=aS(()=>{c("hidden")}),[h,v]=R.useState(!0),d=R.useRef([t]);Lr(()=>{h!==!1&&d.current[d.current.length-1]!==t&&(d.current.push(t),v(!1))},[d,t]);let p=R.useMemo(()=>({show:t,appear:n,initial:h}),[t,n,h]);R.useEffect(()=>{if(t)c("visible");else if(!vv(f))c("hidden");else{let y=o.current;if(!y)return;let m=y.getBoundingClientRect();m.x===0&&m.y===0&&m.width===0&&m.height===0&&c("hidden")}},[t,f]);let g={unmount:a};return pe.default.createElement(hv.Provider,{value:f},pe.default.createElement(fv.Provider,{value:p},Hi({ourProps:{...g,as:R.Fragment,children:pe.default.createElement(sS,{ref:s,...g,...i})},theirProps:{},defaultTag:R.Fragment,features:oS,visible:u==="visible",name:"Transition"})))}),OB=ii(function(r,e){let t=R.useContext(fv)!==null,n=Zy()!==null;return pe.default.createElement(pe.default.Fragment,null,!t&&n?pe.default.createElement(tm,{ref:e,...r}):pe.default.createElement(sS,{ref:e,...r}))}),dv=Object.assign(tm,{Child:OB,Root:tm});var Se={"listBox-label":"_listBox-label_1mdwz_1","listBoxButton-container":"_listBoxButton-container_1mdwz_5",listBoxButton:"_listBoxButton_1mdwz_5","listBox-option":"_listBox-option_1mdwz_13",selectedOptionText:"_selectedOptionText_1mdwz_17",transitionDiv:"_transitionDiv_1mdwz_21",listboxButtonWrapper:"_listboxButtonWrapper_1mdwz_25",arrowicon:"_arrowicon_1mdwz_28",leave:"_leave_1mdwz_31",leaveFrom:"_leaveFrom_1mdwz_34",leaveTo:"_leaveTo_1mdwz_37",notAvailable:"_notAvailable_1mdwz_40",option:"_option_1mdwz_43",activeOption:"_activeOption_1mdwz_46",optionSelected:"_optionSelected_1mdwz_49",inactiveOption:"_inactiveOption_1mdwz_52",optionLabel:"_optionLabel_1mdwz_55",optionSubLabel:"_optionSubLabel_1mdwz_58",selectedLabel:"_selectedLabel_1mdwz_61",nonselectedLabel:"_nonselectedLabel_1mdwz_64",check:"_check_1mdwz_67",checkActive:"_checkActive_1mdwz_70",checkInactive:"_checkInactive_1mdwz_73",checkIcon:"_checkIcon_1mdwz_76",checkIconSelected:"_checkIconSelected_1mdwz_79",checkIconUnselected:"_checkIconUnselected_1mdwz_82",loadMore:"_loadMore_1mdwz_85",selectedList:"_selectedList_1mdwz_88",selectedListItem:"_selectedListItem_1mdwz_91"},PB={primary:"_primary_18yak_1",secondary:"_secondary_18yak_5",tertiary:"_tertiary_18yak_10","font-18":"_font-18_18yak_14","font-20":"_font-20_18yak_18","font-14":"_font-14_18yak_22","font-14a":"_font-14a_18yak_26","font-14b":"_font-14b_18yak_30","font-14c":"_font-14c_18yak_34","font-14d":"_font-14d_18yak_38","font-15":"_font-15_18yak_42","font-34":"_font-34_18yak_45"};const zB={h1:"h1",h2:"h2",h3:"h3",h4:"h4",h5:"h5",h6:"h6",p:"p",span:"span"},de=({className:r,variant:e,styleClass:t="primary",children:n,onClick:a,style:i})=>{const o=zB[e];return S(o,{className:Na(t==="custom"?null:`${PB[t]}`,r),onClick:a,style:i,children:n})};var rm={"searchTab-container":"_searchTab-container_1klck_1","searchTab-input":"_searchTab-input_1klck_5",search:"_search_1klck_1"};const kB=r=>S("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",...r,children:S("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.5,d:"M15.5 15.5L19 19M5 11a6 6 0 1 0 12 0a6 6 0 0 0-12 0Z"})}),cc=({setSearchKeyword:r,className:e=""})=>{const{register:t,watch:n}=Vy(),a=n("searchKeyword");return R.useEffect(()=>{r(a==null?void 0:a.toLowerCase())},[r,n,a]),B("div",{className:`${rm["searchTab-container"]} ${e}`,children:[S("input",{placeholder:"Search",...t("searchKeyword"),className:rm["searchTab-input"]}),S("div",{className:rm.search,children:S(kB,{color:"#C7C7C7",width:"30px",height:"30px"})})]})},lS=r=>S("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",...r,children:S("path",{fill:"currentColor",d:"M21 7L9 19l-5.5-5.5l1.41-1.41L9 16.17L19.59 5.59L21 7Z"})}),nm=r=>S("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",...r,children:S("path",{fill:"currentColor",d:"M7.41 8.58L12 13.17l4.59-4.59L18 10l-6 6l-6-6l1.41-1.42Z"})}),RB=r=>S("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",...r,children:S("path",{fill:"currentColor",d:"m10 13.6l5.9-5.9q.275-.275.7-.275q.425 0 .7.275q.275.275.275.7q0 .425-.275.7l-6.6 6.6q-.3.3-.7.3q-.4 0-.7-.3l-2.6-2.6q-.275-.275-.275-.7q0-.425.275-.7q.275-.275.7-.275q.425 0 .7.275Z"})}),Jt=({label:r,options:e,onChange:t,value:n,defaultValue:a,children:i,placeHolder:o,className:s="",containerClass:l="",isSearchEnabled:u,textSize:c})=>{const[f,h]=R.useState(""),[v,d]=R.useState(20),p=n||a?e==null?void 0:e.find(y=>y.value===n||y.value===a):{label:o||"Select an option"},g={fontSize:c};return S(Gr,{value:n,onChange:t,as:"div",className:l,children:({open:y})=>B(we,{children:[r?S(Gr.Label,{className:Se["listBox-label"],children:r}):null,B("div",{className:`${Se.listboxButtonWrapper} ${s}`,children:[B(Gr.Button,{className:Se["listBoxButton-container"],children:[S("span",{className:Se.selectedOptionText,children:p==null?void 0:p.label}),S("span",{className:Se.listBoxButton,children:S(nm,{className:Se.arrowicon,"aria-hidden":"true"})})]}),S(dv,{show:y,as:R.Fragment,leave:Se.leave,leaveFrom:Se.leaveFrom,leaveTo:Se.leaveTo,children:S(Gr.Options,{className:Se["listBox-option"],children:B(we,{children:[u&&S(cc,{setSearchKeyword:h}),e!=null&&e.length?(f?e.filter(m=>m.value.toLowerCase().includes(f.toLowerCase())):e.slice(0,v)).map(m=>S(Gr.Option,{className:({selected:_,active:b})=>Na(_||b?Se.activeOption:Se.inactiveOption,Se.option),value:m.value,children:({selected:_})=>B(we,{children:[S("span",{className:Se.optionLabel,style:g,children:m.label}),_?S("span",{className:Se.check,children:S(lS,{className:Se.checkIcon,"aria-hidden":"true"})}):null]})},m.value)):S("div",{className:Se.notAvailable,children:"Not Available."}),e&&v<=e.length&&S(Ce,{variant:"secondary",type:"button",onClick:()=>d(v+30),className:Se.loadMore,children:"Load More"}),i]})})})]})]})})},uS=({control:r,name:e,options:t,label:n,defaultValue:a})=>S(Ny,{control:r,name:e,render:({field:{onChange:i,value:o}})=>S(Jt,{onChange:i,value:o,label:n,options:t,defaultValue:a})}),cS=({label:r,options:e,onChange:t,value:n,defaultValue:a})=>{const i=n?e==null?void 0:e.find(o=>o.value.value===n):{label:a};return S(Gr,{value:n,onChange:t,children:({open:o})=>B(we,{children:[S(Gr.Label,{className:Se["listBox-label"],children:r}),B("div",{className:Se.listboxButtonWrapper,children:[B(Gr.Button,{className:Se["listBoxButton-container"],children:[S("span",{className:Se.selectedOptionText,children:i==null?void 0:i.label}),S("span",{className:Se.listBoxButton,children:S(nm,{className:Se.arrowicon,"aria-hidden":"true"})})]}),S(dv,{show:o,as:R.Fragment,leave:Se.leave,leaveFrom:Se.leaveFrom,leaveTo:Se.leaveTo,children:S(Gr.Options,{className:Se["listBox-option"],children:e==null?void 0:e.map(s=>S(Gr.Option,{className:({active:l})=>Na(l?Se.activeOption:Se.inactiveOption,Se.option),value:s.value.value,children:({selected:l,active:u})=>B(we,{children:[S("span",{className:Na(l?Se.selectedLabel:Se.nonselectedLabel,Se.optionLabel),children:s.label}),S("span",{className:Na(l?Se.selectedLabel:Se.nonselectedLabel,Se.optionLabel,Se.optionSubLabel),children:s.value.subValue}),l?S("span",{className:Na(u?Se.checkActive:Se.checkInactive,Se.check),children:S(lS,{className:Se.checkIcon,"aria-hidden":"true"})}):null]})},`${s.value.value}_${s.value.subValue}`))})})]})]})})},jB=({control:r,name:e,options:t,label:n,defaultValue:a})=>S(Ny,{control:r,name:e,render:({field:{onChange:i,value:o}})=>S(cS,{onChange:i,options:t,value:o,label:n,defaultValue:a})}),fc=({options:r,defaultValue:e,value:t,onChange:n,label:a,name:i,className:o="",children:s,placeHolder:l,onClick:u,isSearchEnabled:c,containerClass:f=""})=>{const[h,v]=R.useState(""),[d,p]=R.useState(20);return B(we,{children:[B(Gr,{value:t,onChange:n,defaultValue:e,multiple:!0,name:i,as:"div",className:f,children:[a?S(Gr.Label,{className:Se["listBox-label"],children:a}):null,B("div",{className:Se.listboxButtonWrapper,children:[B(Gr.Button,{className:`${Se["listBoxButton-container"]} ${o}`,onClick:u,children:[S("span",{className:Se.selectedOptionText,children:l||"Choose charts from list"}),S("span",{className:Se.listBoxButton,children:S(nm,{className:Se.arrowicon,"aria-hidden":"true"})})]}),S(dv,{as:"div",leave:Se.leave,leaveFrom:Se.leaveFrom,leaveTo:Se.leaveTo,className:Se.transitionDiv,children:B(Gr.Options,{className:Se["listBox-option"],children:[c&&S(cc,{setSearchKeyword:v}),r.length===0?S("div",{className:Se.notAvailable,children:"Not Available."}):(h?r.filter(g=>g.value.toLowerCase().includes(h.toLowerCase())):r.slice(0,d)).map(g=>S(Gr.Option,{className:({selected:y,active:m})=>`${Se.option} ${y||m?Se.optionSelected:""}`,value:g.value,children:({selected:y})=>B(we,{children:[S("span",{className:`${Se.optionLabel}`,children:g.label}),S("span",{className:Se.check,children:y?S("div",{className:Se.checkIconSelected,children:S(RB,{color:"white"})}):S("div",{className:Se.checkIconUnselected})})]})},g.value)),d<=r.length&&S(Ce,{variant:"secondary",type:"button",onClick:()=>p(d+30),className:Se.loadMore,children:"Load More"}),s]})})]})]}),t!=null&&t.length?S("div",{className:Se.selectedList,children:t.map(g=>{var y;return S(de,{styleClass:"font-14c",variant:"p",className:Se.selectedListItem,children:(y=r.find(m=>m.value===g))==null?void 0:y.label})})}):null]})},BB=({control:r,name:e,...t})=>S(we,{children:S(Ny,{control:r,name:e,render:({field:{onChange:n,value:a}})=>S(fc,{...t,name:e,value:a,onChange:n})})}),pv=({value:r,options:e,control:t})=>{const[n,a]=R.useState("");return S(uS,{control:t,label:"",options:e,onChange:a,name:n||r})};var it={chartOptions:"_chartOptions_yt3j5_1",chartOption:"_chartOption_yt3j5_1",chartOptionBtn:"_chartOptionBtn_yt3j5_13",chartOptionText:"_chartOptionText_yt3j5_19",container:"_container_yt3j5_25",field:"_field_yt3j5_31",fieldText:"_fieldText_yt3j5_37",doneBtn:"_doneBtn_yt3j5_43",measureText:"_measureText_yt3j5_49",singleValueMeasure:"_singleValueMeasure_yt3j5_55",plus:"_plus_yt3j5_61",plusIcon:"_plusIcon_yt3j5_67",form:"_form_yt3j5_73",chartType:"_chartType_yt3j5_79"};const am="something went wrong, please try again",At={line:"line",stepped:"stepped",bar:"bar",stack:"stack",histogram:"histogram",bubble:"bubble",scatter:"scatter",row:"row",area:"area",combo:"combo",pie:"pie",doughnut:"doughnut",waterfall:"waterfall",funnel:"funnel",gauge:"gauge",sankey:"sankey",singleValue:"single value",boxplot:"boxplot",table:"table"},FB="STATUS_TAB",VB="STREAM_TAB",HB="client_id_variable",WB={"is equal to":"=","is not equal to":"!=","is greater than":">","is less than":"<","is greater than or equal to":">=","is less than or equal to":"<="},gv="CHART_TAB",hc="TABLE_TAB",GB="QUERY_TAB",vc="INPUT_TABLE",Il="OUTPUT_TABLE",im="doughnut",om="pie",fS="sankey",hS="boxplot",$B="table",$o="general",Tl="configuration",sm={Snowflake:"Snowflake",Redshift:"Redshift",BigQuery:"BigQuery",Postges:"Postgres"},lm=r=>S("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",...r,children:B("g",{fill:"none",stroke:"currentColor",strokeWidth:2,children:[S("path",{strokeLinecap:"round",d:"M12 8v4m0 0v4m0-4h4m-4 0H8"}),S("circle",{cx:12,cy:12,r:10})]})}),vS=({data:r,setXAxis:e,xAxis:t,setYAxisList:n,chartType:a,setStep:i,setMeasure:o,step:s,measure:l,setSankeyValues:u,setSettingsShow:c,singleValue:f,setSingleValue:h})=>{const v=r?Object.keys(r[0]).map(O=>({value:O,label:O})):[];v.push({value:"NONE",label:"NONE"});const[d,p]=R.useState([v==null?void 0:v[0]]),[g,y]=R.useState(""),[m,_]=R.useState(""),[b,x]=R.useState(""),[M,w]=R.useState(1),[D,T]=R.useState("show"),I=()=>{if(M<(v==null?void 0:v.length)){const O=[...d,v[M]];p(O),M===v.length-1&&T("hidden")}w(M+1)},{handleSubmit:A,control:N}=Vy(),L=O=>{const P=Object.values(O);n(P.filter(H=>H!==void 0&&H!=="NONE")),c(!1)},E=()=>{u([g,m,b])};return a===fS?B("div",{className:it.container,children:[B("div",{className:it.field,children:[S(de,{styleClass:"font-14",className:it.fieldText,variant:"h4",children:"Source"}),S(Jt,{label:"",options:v,onChange:y,value:g})]}),B("div",{className:it.field,children:[S(de,{styleClass:"font-14",className:it.fieldText,variant:"h4",children:"Target"}),S(Jt,{label:"",options:v,onChange:_,value:m})]}),B("div",{children:[S(de,{styleClass:"font-14",className:it.fieldText,variant:"h4",children:"Value"}),S(Jt,{label:"",options:v,onChange:x,value:b})]}),S(Ce,{type:"submit",variant:"primary",size:"default",className:it.doneBtn,onClick:()=>{E(),c(!1)},children:"Done"})]}):a===im?S(we,{children:!!(a===im||om)&&B("div",{className:it.container,children:[S(de,{styleClass:"font-14",className:it.field,variant:"h4",children:"Dimension"}),S(Jt,{label:"",options:v,onChange:e,value:t}),S(de,{styleClass:"font-14",className:it.measureText,variant:"h4",children:"Measure"}),S("div",{className:it.plus,children:S(lm,{className:`${it.plusIcon} ${D}`,onClick:()=>I()})}),B("form",{onSubmit:A(L),className:it.form,children:[d.map(O=>S(pv,{value:O.value,options:v,control:N},O.value)),S(Ce,{type:"submit",variant:"primary",size:"default",className:it.doneBtn,children:"Done"})]})]})}):a===om?B(we,{children:["(",B("div",{className:it.container,children:[S(de,{styleClass:"font-14",className:it.field,variant:"h4",children:"Dimension"}),S(Jt,{label:"",options:v,onChange:e,value:t}),S(de,{styleClass:"font-14",className:it.measureText,variant:"h4",children:"Measure"}),S("div",{className:it.plus,children:S(lm,{className:`${it.plusIcon} ${D}`,onClick:()=>I()})}),B("form",{onSubmit:A(L),className:it.form,children:[d.map(O=>S(pv,{value:O.value,options:v,control:N},O.value)),S(Ce,{type:"submit",variant:"primary",size:"default",className:it.doneBtn,children:"Done"})]})]}),")"]}):a==="single value"?B(we,{children:[S(de,{styleClass:"font-14",className:`${it.singleValueMeasure}`,variant:"h4",children:"Measure"}),S(Jt,{label:"",options:v,onChange:h,value:f}),S(Ce,{type:"button",variant:"primary",size:"default",className:it.doneBtn,onClick:()=>c(!1),children:"Done"})]}):S(we,{children:B("div",{className:it.container,children:[a!=="gauge"&&a!==hS&&a!=="table"&&B(we,{children:[B(de,{styleClass:"font-14",className:it.field,variant:"h4",children:[a!=="funnel"&&a!=="row"&&"X-axis",a==="funnel"&&"Step",a==="row"&&"Y-axis"]}),a==="funnel"?S(Jt,{label:"",options:v,onChange:i,value:s}):S(Jt,{label:"",options:v,onChange:e,value:t})]}),B("div",{className:`${it.chartType}
|
|
17
|
+
${a!=="gauge"?it.measureText:""}`,children:[B(de,{styleClass:"font-14",variant:"h1",className:it.field,children:[a!=="funnel"&&a!=="gauge"&&a!=="row"&&a!=="boxplot"&&a!=="table"&&"Y-axis",(a==="funnel"||a==="gauge"||a==="boxplot"||a==="table")&&"Measure",a==="row"&&"X-axis"]}),a!=="funnel"&&a!=="gauge"&&S(lm,{className:`${it.plusIcon} ${D}`,onClick:()=>I()})]}),B("form",{onSubmit:A(L),className:it.form,children:[a==="funnel"||a==="gauge"?S(Jt,{label:"",options:v,onChange:o,value:l}):d.map(O=>S(pv,{value:O.value,options:v,control:N},O.value)),S(Ce,{type:"submit",variant:"primary",size:"default",className:it.doneBtn,children:"Done"})]})]})})},UB=r=>S("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",...r,children:S("path",{fill:"currentColor",d:"m3.5 18.5l6-6l4 4L22 6.92L20.59 5.5l-7.09 8l-4-4L2 17l1.5 1.5Z"})}),YB=r=>S("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",...r,children:S("path",{fill:"currentColor",d:"M3 22V8h4v14H3m7 0V2h4v20h-4m7 0v-8h4v8h-4Z"})}),QB=r=>B("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",...r,children:[S("path",{fill:"currentColor",d:"M4 21h17v-2H5V3H3v17a1 1 0 0 0 1 1z"}),S("circle",{cx:10,cy:8,r:2,fill:"currentColor"}),S("circle",{cx:18,cy:12,r:2,fill:"currentColor"}),S("circle",{cx:11.5,cy:13.5,r:1.5,fill:"currentColor"}),S("circle",{cx:16.5,cy:6.5,r:1.5,fill:"currentColor"})]}),ZB=r=>S("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",...r,children:S("path",{fill:"currentColor",d:"M4 22H2V2h2v20Zm11-1H5v-3h10v3Zm3-5H5v-3h13v3Zm3-5H5V8h16v3Zm-8-5H5V3h8v3Z"})}),qB=r=>S("svg",{viewBox:"0 0 1024 1024",width:"1.2em",height:"1.2em",...r,children:S("path",{fill:"currentColor",d:"M888 792H200V168c0-4.4-3.6-8-8-8h-56c-4.4 0-8 3.6-8 8v688c0 4.4 3.6 8 8 8h752c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zm-616-64h536c4.4 0 8-3.6 8-8V284c0-7.2-8.7-10.7-13.7-5.7L592 488.6l-125.4-124a8.03 8.03 0 0 0-11.3 0l-189 189.6a7.87 7.87 0 0 0-2.3 5.6V720c0 4.4 3.6 8 8 8z"})}),XB=r=>B("svg",{viewBox:"0 0 32 32",width:"1.2em",height:"1.2em",...r,children:[S("path",{fill:"currentColor",d:"M27 28V16h-8v12h-4V12H7v16H4V2H2v26a2 2 0 0 0 2 2h26v-2Zm-14 0H9V14h4Zm12 0h-4V18h4Z"}),S("path",{fill:"currentColor",d:"M22.786 14a1.988 1.988 0 0 1-1.18-.387L11.205 5.987L8.242 10L6.637 8.806l2.982-4a1.998 1.998 0 0 1 2.749-.446L22.789 12l3.604-4.86L28 8.33l-3.604 4.862a2.001 2.001 0 0 1-1.61.808Z"})]}),JB=r=>S("svg",{viewBox:"0 0 16 16",width:"1.2em",height:"1.2em",...r,children:S("path",{fill:"currentColor",d:"M7.5 1.018a7 7 0 0 0-4.79 11.566L7.5 7.793V1.018zm1 0V7.5h6.482A7.001 7.001 0 0 0 8.5 1.018zM14.982 8.5H8.207l-4.79 4.79A7 7 0 0 0 14.982 8.5zM0 8a8 8 0 1 1 16 0A8 8 0 0 1 0 8z"})}),KB=r=>S("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",...r,children:S("path",{fill:"currentColor",d:"M12.051 21.949a10 10 0 0 1-1-19.949v4.04a5.994 5.994 0 1 0 6.91 6.909H22a10.015 10.015 0 0 1-9.95 9Zm9.95-11h-4.04a5.993 5.993 0 0 0-4.91-4.909V2a10.022 10.022 0 0 1 8.95 8.948v.001Z"})}),eF=r=>S("svg",{viewBox:"0 0 16 16",width:"1.2em",height:"1.2em",...r,children:S("path",{fill:"currentColor",d:"M1.5 1.5A.5.5 0 0 1 2 1h12a.5.5 0 0 1 .5.5v2a.5.5 0 0 1-.128.334L10 8.692V13.5a.5.5 0 0 1-.342.474l-3 1A.5.5 0 0 1 6 14.5V8.692L1.628 3.834A.5.5 0 0 1 1.5 3.5v-2zm1 .5v1.308l4.372 4.858A.5.5 0 0 1 7 8.5v5.306l2-.666V8.5a.5.5 0 0 1 .128-.334L13.5 3.308V2h-11z"})}),tF=r=>B("svg",{viewBox:"0 0 32 32",width:"1.2em",height:"1.2em",...r,children:[S("path",{fill:"currentColor",d:"M28 28V18h-2v10h-4V4h-2v24H10V14H8v14H4V2H2v26a2.002 2.002 0 0 0 2 2h26v-2Z"}),S("path",{fill:"currentColor",d:"M14 4h2v14h-2z"})]}),rF=r=>B("svg",{viewBox:"0 0 32 32",width:"1.2em",height:"1.2em",...r,children:[S("path",{fill:"currentColor",d:"M30 30H4a2 2 0 0 1-2-2V2h2v26h26Z"}),S("path",{fill:"currentColor",d:"M10 16a2 2 0 1 1-2 2a2 2 0 0 1 2-2m0-2a4 4 0 1 0 4 4a4 4 0 0 0-4-4zm11-8a4 4 0 1 1-4 4a4 4 0 0 1 4-4m0-2a6 6 0 1 0 6 6a6 6 0 0 0-6-6zm3.5 17a1.5 1.5 0 1 1-1.5 1.5a1.5 1.5 0 0 1 1.5-1.5m0-2a3.5 3.5 0 1 0 3.5 3.5a3.5 3.5 0 0 0-3.5-3.5z"})]}),nF=r=>S("svg",{viewBox:"0 0 32 32",width:"1.2em",height:"1.2em",...r,children:S("path",{fill:"currentColor",d:"M22 10V6H10v6H4V2H2v26a2.002 2.002 0 0 0 2 2h26V10Zm-10 4V8h8v4h8v10h-6v-6H12v6H4v-8ZM4 28v-4h10v-6h6v6h8v4Z"})}),aF=r=>S("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",...r,children:S("path",{fill:"currentColor",d:"M3 4h1v9h3V7h5v4h4v4h4v6H3V4m13 12v4h3v-4h-3m-4-4v8h3v-8h-3M8 8v12h3V8H8m-4 6v6h3v-6H4Z"})}),iF=r=>S("svg",{viewBox:"0 0 20 20",width:"1.2em",height:"1.2em",...r,children:S("path",{fill:"currentColor",d:"M8.127 13.6c-.689 1.197-.225 2.18.732 2.732c.956.553 2.041.465 2.732-.732c.689-1.195 5.047-11.865 4.668-12.084c-.379-.219-7.442 8.888-8.132 10.084zM10 6c.438 0 .864.037 1.281.109c.438-.549.928-1.154 1.405-1.728A9.664 9.664 0 0 0 10 4C4.393 4 0 8.729 0 14.766c0 .371.016.742.049 1.103c.049.551.54.955 1.084.908c.551-.051.957-.535.908-1.086A10.462 10.462 0 0 1 2 14.766C2 9.85 5.514 6 10 6zm7.219 1.25c-.279.75-.574 1.514-.834 2.174C17.4 10.894 18 12.738 18 14.766c0 .316-.015.635-.043.943a1.001 1.001 0 0 0 1.992.182c.033-.37.051-.748.051-1.125c0-2.954-1.053-5.59-2.781-7.516z"})}),oF=r=>S("svg",{viewBox:"0 0 32 32",width:"1.2em",height:"1.2em",...r,children:S("path",{fill:"currentColor",d:"M30 2H2v14h6.111a7.036 7.036 0 0 1 3.13.74L15.764 19l-4.522 2.26a7.036 7.036 0 0 1-3.13.74H2v8h7.223a9.045 9.045 0 0 0 4.025-.95l8.622-4.31A7.036 7.036 0 0 1 25 24h5V14h-5a7.036 7.036 0 0 1-3.13-.74L15.348 10H30ZM8 4h16v4H8ZM4 4h2v10H4Zm0 20h2v4H4Zm16.975-1.05l-8.622 4.31a7.036 7.036 0 0 1-3.13.74H8v-4h.111a9.045 9.045 0 0 0 4.025-.95L18 20.118l1.864.932a9.045 9.045 0 0 0 4.025.95H24v.058a9.052 9.052 0 0 0-3.025.892ZM28 22h-2v-6h2ZM12.354 10.74l8.621 4.31a9.052 9.052 0 0 0 3.025.89V20h-.111a7.036 7.036 0 0 1-3.13-.74l-8.622-4.31A9.045 9.045 0 0 0 8.11 14H8v-4h1.223a7.036 7.036 0 0 1 3.13.74ZM28 8h-2V4h2Z"})}),sF=r=>S("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",...r,children:S("path",{fill:"currentColor",d:"M22 21H2V3h2v16h2v-2h4v2h2v-3h4v3h2v-2h4v4m-4-7h4v2h-4v-2m-6-8h4v3h-4V6m4 9h-4v-5h4v5M6 10h4v2H6v-2m4 6H6v-3h4v3Z"})}),lF=r=>S("svg",{viewBox:"0 0 16 16",width:"1.2em",height:"1.2em",...r,children:S("path",{fill:"currentColor",d:"M2.873 11.297V4.142H1.699L0 5.379v1.137l1.64-1.18h.06v5.961h1.174Zm3.213-5.09v-.063c0-.618.44-1.169 1.196-1.169c.676 0 1.174.44 1.174 1.106c0 .624-.42 1.101-.807 1.526L4.99 10.553v.744h4.78v-.99H6.643v-.069L8.41 8.252c.65-.724 1.237-1.332 1.237-2.27C9.646 4.849 8.723 4 7.308 4c-1.573 0-2.36 1.064-2.36 2.15v.057h1.138Zm6.559 1.883h.786c.823 0 1.374.481 1.379 1.179c.01.707-.55 1.216-1.421 1.21c-.77-.005-1.326-.419-1.379-.953h-1.095c.042 1.053.938 1.918 2.464 1.918c1.478 0 2.642-.839 2.62-2.144c-.02-1.143-.922-1.651-1.551-1.714v-.063c.535-.09 1.347-.66 1.326-1.678c-.026-1.053-.933-1.855-2.359-1.845c-1.5.005-2.317.88-2.348 1.898h1.116c.032-.498.498-.944 1.206-.944c.703 0 1.206.435 1.206 1.07c.005.64-.504 1.106-1.2 1.106h-.75v.96Z"})}),uF=r=>B("svg",{viewBox:"0 0 32 32",width:"1.2em",height:"1.2em",...r,children:[S("path",{fill:"currentColor",d:"M22 6V4H12v2h4v2h-4v12h4v2h-4v2h10v-2h-4v-2h4V8h-4V6Zm-8 12v-3h6v3Zm6-5h-6v-3h6Z"}),S("path",{fill:"currentColor",d:"M30 30H4a2 2 0 0 1-2-2V2h2v26h26Z"})]}),cF=r=>S("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",...r,children:S("path",{fill:"currentColor",d:"M8 16h5v-5H8v5Zm0-7h12V4H8Zm7 7h5v-5h-5Zm-7 2q-.825 0-1.412-.587Q6 16.825 6 16V4q0-.825.588-1.413Q7.175 2 8 2h12q.825 0 1.413.587Q22 3.175 22 4v12q0 .825-.587 1.413Q20.825 18 20 18Zm-4 4q-.825 0-1.412-.587Q2 20.825 2 20V6h2v14h14v2Z"})}),dS=({setChartType:r})=>{const e=[{name:"Line",icon:UB},{name:"Bar",icon:YB},{name:"Combo",icon:XB},{name:"Scatter",icon:QB},{name:"Row",icon:ZB},{name:"Area",icon:qB},{name:"Pie",icon:JB},{name:"Waterfall",icon:tF},{name:"Funnel",icon:eF},{name:"Bubble",icon:rF},{name:"Doughnut",icon:KB},{name:"Stepped",icon:nF},{name:"Histogram",icon:aF},{name:"Gauge",icon:iF},{name:"Sankey",icon:oF},{name:"Stack",icon:sF},{name:"Single value",icon:lF},{name:"BoxPlot",icon:uF},{name:"Table",icon:cF}];return S("div",{className:it.chartOptions,children:e.map(t=>B("div",{className:it.chartOption,children:[S(Ce,{type:"button",variant:"custom",className:it.chartOptionBtn,onClick:()=>{r(t.name.toLowerCase())},children:S(t.icon,{style:{color:"blue",width:"20px",height:"20px"}})},t.name),S(de,{variant:"p",styleClass:"tertiary",className:it.chartOptionText,children:t.name})]},t.name))})},yv=[{value:"=",label:"Equal to (=)"},{value:"<>",label:"Not equal to (!=)"},{value:"<",label:"Less than (<)"},{value:"<=",label:"Less or equal (<=)"},{value:">",label:"Greater than (>)"},{value:">=",label:"Greater or equal (>=)"},{value:"IN",label:"In"},{value:"NOT IN",label:"Not in"},{value:"LIKE (case sensitive)",label:"Like (case sensitive)"},{value:"REGEX",label:"Regex"},{value:"IS NOT NULL",label:"Is not null"},{value:"IS NULL",label:"Is null"}],pS=[{value:"100",label:"100"},{value:"500",label:"500"},{value:"1000",label:"1000"},{value:"2000",label:"2000"},{value:"5000",label:"5000"}],um=[{value:"AVG",label:"AVG"},{value:"SUM",label:"SUM"},{value:"COUNT",label:"COUNT"},{value:"COUNT_DISTINCT",label:"COUNT_DISTINCT"},{value:"MAX",label:"MAX"},{value:"MIN",label:"MIN"}],cm=["fixed","real","int","bigint","float","number","integer","int64","float64","double precision","smallint"],fm=["varchar","text","char","text","character(36)","string"],hm=["timestamp_ltz","date","timestamp","timestamp without time zone","timestamp with time zone","datetime"],gS=["array","text[]"],vm=["boolean","bool"];var fF="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMCIgaGVpZ2h0PSIwIiBjbGFzcz0iaGlkZGVuIj4NCiAgPHN5bWJvbCBmaWxsPSJub25lIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyNCAyNCIgaWQ9InNxbC1xdWVyeS1pY29uIj4NCiAgICA8cGF0aCBkPSJNMTcgMTdMMjIgMTJMMTcgN003IDdMMiAxMkw3IDE3TTE0IDNMMTAgMjEiIHN0cm9rZT0iY3VycmVudENvbG9yIiBzdHJva2Utd2lkdGg9IjEuNSIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIj48L3BhdGg+DQogIDwvc3ltYm9sPg0KICA8c3ltYm9sIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgdmlld0JveD0iMCAwIDI0IDI0IiBpZD0idmlzdWFsaXphdGlvbi1pY29uIj4NCiAgICA8cGF0aCBkPSJNMTIgMTZWMjFNMTIgMTZMMTggMjFNMTIgMTZMNiAyMU0yMSAzVjExLjJDMjEgMTIuODgwMiAyMSAxMy43MjAyIDIwLjY3MyAxNC4zNjJDMjAuMzg1NCAxNC45MjY1IDE5LjkyNjUgMTUuMzg1NCAxOS4zNjIgMTUuNjczQzE4LjcyMDIgMTYgMTcuODgwMiAxNiAxNi4yIDE2SDcuOEM2LjExOTg0IDE2IDUuMjc5NzYgMTYgNC42MzgwMyAxNS42NzNDNC4wNzM1NCAxNS4zODU0IDMuNjE0NiAxNC45MjY1IDMuMzI2OTggMTQuMzYyQzMgMTMuNzIwMiAzIDEyLjg4MDIgMyAxMS4yVjNNOCA5VjEyTTEyIDdWMTJNMTYgMTFWMTJNMjIgM0gyIiBzdHJva2U9ImN1cnJlbnRDb2xvciIgc3Ryb2tlLXdpZHRoPSIxLjUiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCI+PC9wYXRoPg0KICA8L3N5bWJvbD4NCiAgPHN5bWJvbCBmaWxsPSJub25lIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyNCAyNCIgaWQ9ImFycm93LWJhY2staWNvbiI+DQogICAgPHBhdGggZD0iTTIwIDEySDRNNCAxMkwxMCAxOE00IDEyTDEwIDYiIHN0cm9rZT0iY3VycmVudENvbG9yIiBzdHJva2Utd2lkdGg9IjEuNSIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIj48L3BhdGg+DQogIDwvc3ltYm9sPg0KICA8c3ltYm9sIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgdmlld0JveD0iMCAwIDI0IDI0IiBpZD0ibG9nb3V0LWljb24iPg0KICAgIDxwYXRoIGQ9Ik0xNiAxN0wyMSAxMk0yMSAxMkwxNiA3TTIxIDEySDlNOSAzSDcuOEM2LjExOTg0IDMgNS4yNzk3NiAzIDQuNjM4MDMgMy4zMjY5OEM0LjA3MzU0IDMuNjE0NiAzLjYxNDYgNC4wNzM1NCAzLjMyNjk4IDQuNjM4MDNDMyA1LjI3OTc2IDMgNi4xMTk4NCAzIDcuOFYxNi4yQzMgMTcuODgwMiAzIDE4LjcyMDIgMy4zMjY5OCAxOS4zNjJDMy42MTQ2IDE5LjkyNjUgNC4wNzM1NCAyMC4zODU0IDQuNjM4MDMgMjAuNjczQzUuMjc5NzYgMjEgNi4xMTk4NCAyMSA3LjggMjFIOSIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgPC9zeW1ib2w+DQogIDxzeW1ib2wgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgMjQgMjQiIGlkPSJtb3JlLWljb24iPg0KICAgIDxwYXRoIGQ9Ik0xMiAxM0MxMi41NTIzIDEzIDEzIDEyLjU1MjMgMTMgMTJDMTMgMTEuNDQ3NyAxMi41NTIzIDExIDEyIDExQzExLjQ0NzcgMTEgMTEgMTEuNDQ3NyAxMSAxMkMxMSAxMi41NTIzIDExLjQ0NzcgMTMgMTIgMTNaIiBzdHJva2U9ImN1cnJlbnRDb2xvciIgc3Ryb2tlLXdpZHRoPSIxLjUiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCI+PC9wYXRoPg0KICAgIDxwYXRoIGQ9Ik0xMiA2QzEyLjU1MjMgNiAxMyA1LjU1MjI4IDEzIDVDMTMgNC40NDc3MiAxMi41NTIzIDQgMTIgNEMxMS40NDc3IDQgMTEgNC40NDc3MiAxMSA1QzExIDUuNTUyMjggMTEuNDQ3NyA2IDEyIDZaIiBzdHJva2U9ImN1cnJlbnRDb2xvciIgc3Ryb2tlLXdpZHRoPSIxLjUiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCI+PC9wYXRoPg0KICAgIDxwYXRoIGQ9Ik0xMiAyMEMxMi41NTIzIDIwIDEzIDE5LjU1MjMgMTMgMTlDMTMgMTguNDQ3NyAxMi41NTIzIDE4IDEyIDE4QzExLjQ0NzcgMTggMTEgMTguNDQ3NyAxMSAxOUMxMSAxOS41NTIzIDExLjQ0NzcgMjAgMTIgMjBaIiBzdHJva2U9ImN1cnJlbnRDb2xvciIgc3Ryb2tlLXdpZHRoPSIxLjUiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCI+PC9wYXRoPg0KICA8L3N5bWJvbD4NCiAgPHN5bWJvbCBmaWxsPSJub25lIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyNCAyNCIgaWQ9InNhdmUtaWNvbiI+DQogICAgPHBhdGggZD0iTTcgM1Y2LjRDNyA2Ljk2MDA1IDcgNy4yNDAwOCA3LjEwODk5IDcuNDUzOTlDNy4yMDQ4NyA3LjY0MjE1IDcuMzU3ODUgNy43OTUxMyA3LjU0NjAxIDcuODkxMDFDNy43NTk5MiA4IDguMDM5OTUgOCA4LjYgOEgxNS40QzE1Ljk2MDEgOCAxNi4yNDAxIDggMTYuNDU0IDcuODkxMDFDMTYuNjQyMiA3Ljc5NTEzIDE2Ljc5NTEgNy42NDIxNSAxNi44OTEgNy40NTM5OUMxNyA3LjI0MDA4IDE3IDYuOTYwMDUgMTcgNi40VjRNMTcgMjFWMTQuNkMxNyAxNC4wMzk5IDE3IDEzLjc1OTkgMTYuODkxIDEzLjU0NkMxNi43OTUxIDEzLjM1NzggMTYuNjQyMiAxMy4yMDQ5IDE2LjQ1NCAxMy4xMDlDMTYuMjQwMSAxMyAxNS45NjAxIDEzIDE1LjQgMTNIOC42QzguMDM5OTUgMTMgNy43NTk5MiAxMyA3LjU0NjAxIDEzLjEwOUM3LjM1Nzg1IDEzLjIwNDkgNy4yMDQ4NyAxMy4zNTc4IDcuMTA4OTkgMTMuNTQ2QzcgMTMuNzU5OSA3IDE0LjAzOTkgNyAxNC42VjIxTTIxIDkuMzI1NDhWMTYuMkMyMSAxNy44ODAyIDIxIDE4LjcyMDIgMjAuNjczIDE5LjM2MkMyMC4zODU0IDE5LjkyNjUgMTkuOTI2NSAyMC4zODU0IDE5LjM2MiAyMC42NzNDMTguNzIwMiAyMSAxNy44ODAyIDIxIDE2LjIgMjFINy44QzYuMTE5ODQgMjEgNS4yNzk3NiAyMSA0LjYzODAzIDIwLjY3M0M0LjA3MzU0IDIwLjM4NTQgMy42MTQ2IDE5LjkyNjUgMy4zMjY5OCAxOS4zNjJDMyAxOC43MjAyIDMgMTcuODgwMiAzIDE2LjJWNy44QzMgNi4xMTk4NCAzIDUuMjc5NzYgMy4zMjY5OCA0LjYzODAzQzMuNjE0NiA0LjA3MzU0IDQuMDczNTQgMy42MTQ2IDQuNjM4MDMgMy4zMjY5OEM1LjI3OTc2IDMgNi4xMTk4NCAzIDcuOCAzSDE0LjY3NDVDMTUuMTYzNyAzIDE1LjQwODMgMyAxNS42Mzg1IDMuMDU1MjZDMTUuODQyNSAzLjEwNDI1IDE2LjAzNzYgMy4xODUwNiAxNi4yMTY2IDMuMjk0NzJDMTYuNDE4NCAzLjQxODQgMTYuNTkxNCAzLjU5MTM1IDE2LjkzNzMgMy45MzcyNkwyMC4wNjI3IDcuMDYyNzRDMjAuNDA4NiA3LjQwODY1IDIwLjU4MTYgNy41ODE2IDIwLjcwNTMgNy43ODM0M0MyMC44MTQ5IDcuOTYyMzcgMjAuODk1NyA4LjE1NzQ2IDIwLjk0NDcgOC4zNjE1NEMyMSA4LjU5MTcxIDIxIDguODM2MyAyMSA5LjMyNTQ4WiIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgPC9zeW1ib2w+DQogIDxzeW1ib2wgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgMjQgMjQiIGlkPSJjb3B5LWljb24iPg0KICAgIDxwYXRoIGQ9Ik0xMC41IDIuMDAyOEM5LjgyNDk1IDIuMDExOTQgOS40MTk3IDIuMDUxMDMgOS4wOTIwMiAyLjIxNzk5QzguNzE1NjkgMi40MDk3MyA4LjQwOTczIDIuNzE1NjkgOC4yMTc5OSAzLjA5MjAyQzguMDUxMDMgMy40MTk3IDguMDExOTQgMy44MjQ5NSA4LjAwMjggNC41TTE5LjUgMi4wMDI4QzIwLjE3NTEgMi4wMTE5NCAyMC41ODAzIDIuMDUxMDMgMjAuOTA4IDIuMjE3OTlDMjEuMjg0MyAyLjQwOTczIDIxLjU5MDMgMi43MTU2OSAyMS43ODIgMy4wOTIwMkMyMS45NDkgMy40MTk3IDIxLjk4ODEgMy44MjQ5NCAyMS45OTcyIDQuNDk5OTlNMjEuOTk3MiAxMy41QzIxLjk4ODEgMTQuMTc1IDIxLjk0OSAxNC41ODAzIDIxLjc4MiAxNC45MDhDMjEuNTkwMyAxNS4yODQzIDIxLjI4NDMgMTUuNTkwMyAyMC45MDggMTUuNzgyQzIwLjU4MDMgMTUuOTQ5IDIwLjE3NTEgMTUuOTg4MSAxOS41IDE1Ljk5NzJNMjIgNy45OTk5OVY5Ljk5OTk5TTE0LjAwMDEgMkgxNk01LjIgMjJIMTIuOEMxMy45MjAxIDIyIDE0LjQ4MDIgMjIgMTQuOTA4IDIxLjc4MkMxNS4yODQzIDIxLjU5MDMgMTUuNTkwMyAyMS4yODQzIDE1Ljc4MiAyMC45MDhDMTYgMjAuNDgwMiAxNiAxOS45MjAxIDE2IDE4LjhWMTEuMkMxNiAxMC4wNzk5IDE2IDkuNTE5ODQgMTUuNzgyIDkuMDkyMDJDMTUuNTkwMyA4LjcxNTY5IDE1LjI4NDMgOC40MDk3MyAxNC45MDggOC4yMTc5OUMxNC40ODAyIDggMTMuOTIwMSA4IDEyLjggOEg1LjJDNC4wNzk5IDggMy41MTk4NCA4IDMuMDkyMDIgOC4yMTc5OUMyLjcxNTY5IDguNDA5NzMgMi40MDk3MyA4LjcxNTY5IDIuMjE3OTkgOS4wOTIwMkMyIDkuNTE5ODQgMiAxMC4wNzk5IDIgMTEuMlYxOC44QzIgMTkuOTIwMSAyIDIwLjQ4MDIgMi4yMTc5OSAyMC45MDhDMi40MDk3MyAyMS4yODQzIDIuNzE1NjkgMjEuNTkwMyAzLjA5MjAyIDIxLjc4MkMzLjUxOTg0IDIyIDQuMDc5ODkgMjIgNS4yIDIyWiIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgPC9zeW1ib2w+DQogIDxzeW1ib2wgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgMjQgMjQiIGlkPSJkYXRhc2V0LWljb24iPg0KICAgIDxwYXRoIGQ9Ik0yMSA1QzIxIDYuNjU2ODUgMTYuOTcwNiA4IDEyIDhDNy4wMjk0NCA4IDMgNi42NTY4NSAzIDVNMjEgNUMyMSAzLjM0MzE1IDE2Ljk3MDYgMiAxMiAyQzcuMDI5NDQgMiAzIDMuMzQzMTUgMyA1TTIxIDVWMTlDMjEgMjAuNjYgMTcgMjIgMTIgMjJDNyAyMiAzIDIwLjY2IDMgMTlWNU0yMSAxMkMyMSAxMy42NiAxNyAxNSAxMiAxNUM3IDE1IDMgMTMuNjYgMyAxMiIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgPC9zeW1ib2w+DQogIDxzeW1ib2wgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgMjQgMjQiIGlkPSJmaWx0ZXItaWNvbiI+DQogICAgPHBhdGggZD0iTTIgNC42QzIgNC4wMzk5NSAyIDMuNzU5OTIgMi4xMDg5OSAzLjU0NjAxQzIuMjA0ODcgMy4zNTc4NSAyLjM1Nzg1IDMuMjA0ODcgMi41NDYwMSAzLjEwODk5QzIuNzU5OTIgMyAzLjAzOTk1IDMgMy42IDNIMjAuNEMyMC45NjAxIDMgMjEuMjQwMSAzIDIxLjQ1NCAzLjEwODk5QzIxLjY0MjIgMy4yMDQ4NyAyMS43OTUxIDMuMzU3ODUgMjEuODkxIDMuNTQ2MDFDMjIgMy43NTk5MiAyMiA0LjAzOTk1IDIyIDQuNlY1LjI2OTM5QzIyIDUuNTM4MTkgMjIgNS42NzI1OSAyMS45NjcyIDUuNzk3NTZDMjEuOTM4IDUuOTA4MzEgMjEuODkwMSA2LjAxMzIzIDIxLjgyNTUgNi4xMDc3NkMyMS43NTI2IDYuMjE0NDMgMjEuNjUxIDYuMzAyNDUgMjEuNDQ3OSA2LjQ3ODVMMTUuMDUyMSAxMi4wMjE1QzE0Ljg0OSAxMi4xOTc1IDE0Ljc0NzQgMTIuMjg1NiAxNC42NzQ1IDEyLjM5MjJDMTQuNjA5OSAxMi40ODY4IDE0LjU2MiAxMi41OTE3IDE0LjUzMjggMTIuNzAyNEMxNC41IDEyLjgyNzQgMTQuNSAxMi45NjE4IDE0LjUgMTMuMjMwNlYxOC40NTg0QzE0LjUgMTguNjUzOSAxNC41IDE4Ljc1MTcgMTQuNDY4NSAxOC44MzYzQzE0LjQ0MDYgMTguOTExIDE0LjM5NTMgMTguOTc3OSAxNC4zMzYzIDE5LjAzMTVDMTQuMjY5NSAxOS4wOTIyIDE0LjE3ODcgMTkuMTI4NSAxMy45OTcxIDE5LjIwMTJMMTAuNTk3MSAyMC41NjEyQzEwLjIyOTYgMjAuNzA4MiAxMC4wNDU4IDIwLjc4MTcgOS44OTgyNyAyMC43NTFDOS43NjkyNyAyMC43MjQyIDkuNjU2MDUgMjAuNjQ3NiA5LjU4MzI1IDIwLjUzNzdDOS41IDIwLjQxMjIgOS41IDIwLjIxNDIgOS41IDE5LjgxODRWMTMuMjMwNkM5LjUgMTIuOTYxOCA5LjUgMTIuODI3NCA5LjQ2NzE1IDEyLjcwMjRDOS40MzgwNSAxMi41OTE3IDkuMzkwMTQgMTIuNDg2OCA5LjMyNTUxIDEyLjM5MjJDOS4yNTI1OCAxMi4yODU2IDkuMTUxMDIgMTIuMTk3NSA4Ljk0Nzg5IDEyLjAyMTVMMi41NTIxMSA2LjQ3ODVDMi4zNDg5OCA2LjMwMjQ1IDIuMjQ3NDIgNi4yMTQ0MyAyLjE3NDQ5IDYuMTA3NzZDMi4xMDk4NiA2LjAxMzIzIDIuMDYxOTUgNS45MDgzMSAyLjAzMjg1IDUuNzk3NTZDMiA1LjY3MjU5IDIgNS41MzgxOSAyIDUuMjY5MzlWNC42WiIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgPC9zeW1ib2w+DQogIDxzeW1ib2wgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgMjQgMjQiIGlkPSJzZXR0aW5ncy1pY29uIj4NCiAgICA8cGF0aCBkPSJNMTIgMTVDMTMuNjU2OSAxNSAxNSAxMy42NTY5IDE1IDEyQzE1IDEwLjM0MzEgMTMuNjU2OSA5IDEyIDlDMTAuMzQzMSA5IDkgMTAuMzQzMSA5IDEyQzkgMTMuNjU2OSAxMC4zNDMxIDE1IDEyIDE1WiIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgICA8cGF0aCBkPSJNMTguNzI3MyAxNC43MjczQzE4LjYwNjMgMTUuMDAxNSAxOC41NzAyIDE1LjMwNTYgMTguNjIzNiAxNS42MDA1QzE4LjY3NzEgMTUuODk1NCAxOC44MTc3IDE2LjE2NzYgMTkuMDI3MyAxNi4zODE4TDE5LjA4MTggMTYuNDM2NEMxOS4yNTA5IDE2LjYwNTIgMTkuMzg1IDE2LjgwNTcgMTkuNDc2NSAxNy4wMjY1QzE5LjU2OCAxNy4yNDcyIDE5LjYxNTEgMTcuNDgzOCAxOS42MTUxIDE3LjcyMjdDMTkuNjE1MSAxNy45NjE3IDE5LjU2OCAxOC4xOTgzIDE5LjQ3NjUgMTguNDE5QzE5LjM4NSAxOC42Mzk3IDE5LjI1MDkgMTguODQwMiAxOS4wODE4IDE5LjAwOTFDMTguOTEzIDE5LjE3ODEgMTguNzEyNCAxOS4zMTIyIDE4LjQ5MTcgMTkuNDAzN0MxOC4yNzEgMTkuNDk1MiAxOC4wMzQ0IDE5LjU0MjMgMTcuNzk1NSAxOS41NDIzQzE3LjU1NjUgMTkuNTQyMyAxNy4zMTk5IDE5LjQ5NTIgMTcuMDk5MiAxOS40MDM3QzE2Ljg3ODUgMTkuMzEyMiAxNi42NzggMTkuMTc4MSAxNi41MDkxIDE5LjAwOTFMMTYuNDU0NSAxOC45NTQ1QzE2LjI0MDMgMTguNzQ1IDE1Ljk2ODIgMTguNjA0NCAxNS42NzMzIDE4LjU1MDlDMTUuMzc4NCAxOC40OTc0IDE1LjA3NDIgMTguNTMzNSAxNC44IDE4LjY1NDVDMTQuNTMxMSAxOC43Njk4IDE0LjMwMTggMTguOTYxMSAxNC4xNDAzIDE5LjIwNUMxMy45Nzg4IDE5LjQ0ODkgMTMuODkyMSAxOS43MzQ3IDEzLjg5MDkgMjAuMDI3M1YyMC4xODE4QzEzLjg5MDkgMjAuNjY0IDEzLjY5OTQgMjEuMTI2NSAxMy4zNTg0IDIxLjQ2NzVDMTMuMDE3NCAyMS44MDg0IDEyLjU1NDkgMjIgMTIuMDcyNyAyMkMxMS41OTA1IDIyIDExLjEyODEgMjEuODA4NCAxMC43ODcxIDIxLjQ2NzVDMTAuNDQ2MSAyMS4xMjY1IDEwLjI1NDUgMjAuNjY0IDEwLjI1NDUgMjAuMTgxOFYyMC4xQzEwLjI0NzUgMTkuNzk5MSAxMC4xNTAxIDE5LjUwNzMgOS45NzUwMSAxOS4yNjI1QzkuNzk5OTEgMTkuMDE3NiA5LjU1NTIxIDE4LjgzMTIgOS4yNzI3MyAxOC43MjczQzguOTk4NTMgMTguNjA2MyA4LjY5NDM3IDE4LjU3MDIgOC4zOTk0NyAxOC42MjM2QzguMTA0NTYgMTguNjc3MSA3LjgzMjQ0IDE4LjgxNzcgNy42MTgxOCAxOS4wMjczTDcuNTYzNjQgMTkuMDgxOEM3LjM5NDc4IDE5LjI1MDkgNy4xOTQyNSAxOS4zODUgNi45NzM1MyAxOS40NzY1QzYuNzUyOCAxOS41NjggNi41MTYyMSAxOS42MTUxIDYuMjc3MjcgMTkuNjE1MUM2LjAzODM0IDE5LjYxNTEgNS44MDE3NCAxOS41NjggNS41ODEwMiAxOS40NzY1QzUuMzYwMjkgMTkuMzg1IDUuMTU5NzcgMTkuMjUwOSA0Ljk5MDkxIDE5LjA4MThDNC44MjE4NiAxOC45MTMgNC42ODc3NSAxOC43MTI0IDQuNTk2MjYgMTguNDkxN0M0LjUwNDc2IDE4LjI3MSA0LjQ1NzY2IDE4LjAzNDQgNC40NTc2NiAxNy43OTU1QzQuNDU3NjYgMTcuNTU2NSA0LjUwNDc2IDE3LjMxOTkgNC41OTYyNiAxNy4wOTkyQzQuNjg3NzUgMTYuODc4NSA0LjgyMTg2IDE2LjY3OCA0Ljk5MDkxIDE2LjUwOTFMNS4wNDU0NSAxNi40NTQ1QzUuMjU1MDMgMTYuMjQwMyA1LjM5NTYyIDE1Ljk2ODIgNS40NDkxIDE1LjY3MzNDNS41MDI1NyAxNS4zNzg0IDUuNDY2NDcgMTUuMDc0MiA1LjM0NTQ1IDE0LjhDNS4yMzAyMiAxNC41MzExIDUuMDM4ODcgMTQuMzAxOCA0Ljc5NDk3IDE0LjE0MDNDNC41NTEwNyAxMy45Nzg4IDQuMjY1MjYgMTMuODkyMSAzLjk3MjczIDEzLjg5MDlIMy44MTgxOEMzLjMzNTk3IDEzLjg5MDkgMi44NzM1MSAxMy42OTk0IDIuNTMyNTMgMTMuMzU4NEMyLjE5MTU2IDEzLjAxNzQgMiAxMi41NTQ5IDIgMTIuMDcyN0MyIDExLjU5MDUgMi4xOTE1NiAxMS4xMjgxIDIuNTMyNTMgMTAuNzg3MUMyLjg3MzUxIDEwLjQ0NjEgMy4zMzU5NyAxMC4yNTQ1IDMuODE4MTggMTAuMjU0NUgzLjlDNC4yMDA5IDEwLjI0NzUgNC40OTI3MyAxMC4xNTAxIDQuNzM3NTQgOS45NzUwMUM0Ljk4MjM2IDkuNzk5OTEgNS4xNjg4MyA5LjU1NTIxIDUuMjcyNzMgOS4yNzI3M0M1LjM5Mzc0IDguOTk4NTMgNS40Mjk4NCA4LjY5NDM3IDUuMzc2MzcgOC4zOTk0N0M1LjMyMjkgOC4xMDQ1NiA1LjE4MjMxIDcuODMyNDQgNC45NzI3MyA3LjYxODE4TDQuOTE4MTggNy41NjM2NEM0Ljc0OTEzIDcuMzk0NzggNC42MTUwMyA3LjE5NDI1IDQuNTIzNTMgNi45NzM1M0M0LjQzMjAzIDYuNzUyOCA0LjM4NDkzIDYuNTE2MjEgNC4zODQ5MyA2LjI3NzI3QzQuMzg0OTMgNi4wMzgzNCA0LjQzMjAzIDUuODAxNzQgNC41MjM1MyA1LjU4MTAyQzQuNjE1MDMgNS4zNjAyOSA0Ljc0OTEzIDUuMTU5NzcgNC45MTgxOCA0Ljk5MDkxQzUuMDg3MDQgNC44MjE4NiA1LjI4NzU3IDQuNjg3NzUgNS41MDgyOSA0LjU5NjI2QzUuNzI5MDEgNC41MDQ3NiA1Ljk2NTYxIDQuNDU3NjYgNi4yMDQ1NSA0LjQ1NzY2QzYuNDQzNDggNC40NTc2NiA2LjY4MDA4IDQuNTA0NzYgNi45MDA4IDQuNTk2MjZDNy4xMjE1MiA0LjY4Nzc1IDcuMzIyMDUgNC44MjE4NiA3LjQ5MDkxIDQuOTkwOTFMNy41NDU0NSA1LjA0NTQ1QzcuNzU5NzEgNS4yNTUwMyA4LjAzMTgzIDUuMzk1NjIgOC4zMjY3NCA1LjQ0OTFDOC42MjE2NCA1LjUwMjU3IDguOTI1OCA1LjQ2NjQ3IDkuMiA1LjM0NTQ1SDkuMjcyNzNDOS41NDE2MSA1LjIzMDIyIDkuNzcwOTMgNS4wMzg4NyA5LjkzMjQ1IDQuNzk0OTdDMTAuMDk0IDQuNTUxMDcgMTAuMTgwNyA0LjI2NTI2IDEwLjE4MTggMy45NzI3M1YzLjgxODE4QzEwLjE4MTggMy4zMzU5NyAxMC4zNzM0IDIuODczNTEgMTAuNzE0NCAyLjUzMjUzQzExLjA1NTMgMi4xOTE1NiAxMS41MTc4IDIgMTIgMkMxMi40ODIyIDIgMTIuOTQ0NyAyLjE5MTU2IDEzLjI4NTYgMi41MzI1M0MxMy42MjY2IDIuODczNTEgMTMuODE4MiAzLjMzNTk3IDEzLjgxODIgMy44MTgxOFYzLjlDMTMuODE5MyA0LjE5MjUzIDEzLjkwNiA0LjQ3ODM0IDE0LjA2NzYgNC43MjIyNEMxNC4yMjkxIDQuOTY2MTQgMTQuNDU4NCA1LjE1NzQ5IDE0LjcyNzMgNS4yNzI3M0MxNS4wMDE1IDUuMzkzNzQgMTUuMzA1NiA1LjQyOTg0IDE1LjYwMDUgNS4zNzYzN0MxNS44OTU0IDUuMzIyOSAxNi4xNjc2IDUuMTgyMzEgMTYuMzgxOCA0Ljk3MjczTDE2LjQzNjQgNC45MTgxOEMxNi42MDUyIDQuNzQ5MTMgMTYuODA1NyA0LjYxNTAzIDE3LjAyNjUgNC41MjM1M0MxNy4yNDcyIDQuNDMyMDMgMTcuNDgzOCA0LjM4NDkzIDE3LjcyMjcgNC4zODQ5M0MxNy45NjE3IDQuMzg0OTMgMTguMTk4MyA0LjQzMjAzIDE4LjQxOSA0LjUyMzUzQzE4LjYzOTcgNC42MTUwMyAxOC44NDAyIDQuNzQ5MTMgMTkuMDA5MSA0LjkxODE4QzE5LjE3ODEgNS4wODcwNCAxOS4zMTIyIDUuMjg3NTcgMTkuNDAzNyA1LjUwODI5QzE5LjQ5NTIgNS43MjkwMSAxOS41NDIzIDUuOTY1NjEgMTkuNTQyMyA2LjIwNDU1QzE5LjU0MjMgNi40NDM0OCAxOS40OTUyIDYuNjgwMDggMTkuNDAzNyA2LjkwMDhDMTkuMzEyMiA3LjEyMTUyIDE5LjE3ODEgNy4zMjIwNSAxOS4wMDkxIDcuNDkwOTFMMTguOTU0NSA3LjU0NTQ1QzE4Ljc0NSA3Ljc1OTcxIDE4LjYwNDQgOC4wMzE4MyAxOC41NTA5IDguMzI2NzRDMTguNDk3NCA4LjYyMTY0IDE4LjUzMzUgOC45MjU4IDE4LjY1NDUgOS4yVjkuMjcyNzNDMTguNzY5OCA5LjU0MTYxIDE4Ljk2MTEgOS43NzA5MyAxOS4yMDUgOS45MzI0NUMxOS40NDg5IDEwLjA5NCAxOS43MzQ3IDEwLjE4MDcgMjAuMDI3MyAxMC4xODE4SDIwLjE4MThDMjAuNjY0IDEwLjE4MTggMjEuMTI2NSAxMC4zNzM0IDIxLjQ2NzUgMTAuNzE0NEMyMS44MDg0IDExLjA1NTMgMjIgMTEuNTE3OCAyMiAxMkMyMiAxMi40ODIyIDIxLjgwODQgMTIuOTQ0NyAyMS40Njc1IDEzLjI4NTZDMjEuMTI2NSAxMy42MjY2IDIwLjY2NCAxMy44MTgyIDIwLjE4MTggMTMuODE4MkgyMC4xQzE5LjgwNzUgMTMuODE5MyAxOS41MjE3IDEzLjkwNiAxOS4yNzc4IDE0LjA2NzZDMTkuMDMzOSAxNC4yMjkxIDE4Ljg0MjUgMTQuNDU4NCAxOC43MjczIDE0LjcyNzNaIiBzdHJva2U9ImN1cnJlbnRDb2xvciIgc3Ryb2tlLXdpZHRoPSIxLjUiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCI+PC9wYXRoPg0KICA8L3N5bWJvbD4NCiAgPHN5bWJvbCBmaWxsPSJub25lIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyNCAyNCIgaWQ9ImluZm8taWNvbiI+DQogICAgPHBhdGggZD0iTTEyIDE2VjEyTTEyIDhIMTIuMDFNMjIgMTJDMjIgMTcuNTIyOCAxNy41MjI4IDIyIDEyIDIyQzYuNDc3MTUgMjIgMiAxNy41MjI4IDIgMTJDMiA2LjQ3NzE1IDYuNDc3MTUgMiAxMiAyQzE3LjUyMjggMiAyMiA2LjQ3NzE1IDIyIDEyWiIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgPC9zeW1ib2w+DQogIDxzeW1ib2wgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgMjQgMjQiIGlkPSJzY2hlbWEtaWNvbiI+DQogICAgPHBhdGggZD0iTTEyIDRWMTUuMkMxMiAxNi44ODAyIDEyIDE3LjcyMDIgMTIuMzI3IDE4LjM2MkMxMi42MTQ2IDE4LjkyNjUgMTMuMDczNSAxOS4zODU0IDEzLjYzOCAxOS42NzNDMTQuMjc5OCAyMCAxNS4xMTk4IDIwIDE2LjggMjBIMTdNMTcgMjBDMTcgMjEuMTA0NiAxNy44OTU0IDIyIDE5IDIyQzIwLjEwNDYgMjIgMjEgMjEuMTA0NiAyMSAyMEMyMSAxOC44OTU0IDIwLjEwNDYgMTggMTkgMThDMTcuODk1NCAxOCAxNyAxOC44OTU0IDE3IDIwWk03IDRMMTcgNE03IDRDNyA1LjEwNDU3IDYuMTA0NTcgNiA1IDZDMy44OTU0MyA2IDMgNS4xMDQ1NyAzIDRDMyAyLjg5NTQzIDMuODk1NDMgMiA1IDJDNi4xMDQ1NyAyIDcgMi44OTU0MyA3IDRaTTE3IDRDMTcgNS4xMDQ1NyAxNy44OTU0IDYgMTkgNkMyMC4xMDQ2IDYgMjEgNS4xMDQ1NyAyMSA0QzIxIDIuODk1NDMgMjAuMTA0NiAyIDE5IDJDMTcuODk1NCAyIDE3IDIuODk1NDMgMTcgNFpNMTIgMTJIMTdNMTcgMTJDMTcgMTMuMTA0NiAxNy44OTU0IDE0IDE5IDE0QzIwLjEwNDYgMTQgMjEgMTMuMTA0NiAyMSAxMkMyMSAxMC44OTU0IDIwLjEwNDYgMTAgMTkgMTBDMTcuODk1NCAxMCAxNyAxMC44OTU0IDE3IDEyWiIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgPC9zeW1ib2w+DQogIDxzeW1ib2wgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgMjQgMjQiIGlkPSJmdWxsc2NyZWVuLWljb24iPg0KICAgIDxwYXRoIGQ9Ik0xNCAxMEwyMSAzTTIxIDNIMTVNMjEgM1Y5TTEwIDE0TDMgMjFNMyAyMUg5TTMgMjFMMyAxNSIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgPC9zeW1ib2w+DQogIDxzeW1ib2wgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgMjQgMjQiIGlkPSJ0YWJsZS1pY29uIj4NCiAgICA8cGF0aCBkPSJNMyA5TDIxIDlNOSAzTDkgMjFNNy44IDNIMTYuMkMxNy44ODAyIDMgMTguNzIwMiAzIDE5LjM2MiAzLjMyNjk4QzE5LjkyNjUgMy42MTQ2IDIwLjM4NTQgNC4wNzM1NCAyMC42NzMgNC42MzgwM0MyMSA1LjI3OTc2IDIxIDYuMTE5ODQgMjEgNy44VjE2LjJDMjEgMTcuODgwMiAyMSAxOC43MjAyIDIwLjY3MyAxOS4zNjJDMjAuMzg1NCAxOS45MjY1IDE5LjkyNjUgMjAuMzg1NCAxOS4zNjIgMjAuNjczQzE4LjcyMDIgMjEgMTcuODgwMiAyMSAxNi4yIDIxSDcuOEM2LjExOTg0IDIxIDUuMjc5NzYgMjEgNC42MzgwMyAyMC42NzNDNC4wNzM1NCAyMC4zODU0IDMuNjE0NiAxOS45MjY1IDMuMzI2OTggMTkuMzYyQzMgMTguNzIwMiAzIDE3Ljg4MDIgMyAxNi4yVjcuOEMzIDYuMTE5ODQgMyA1LjI3OTc2IDMuMzI2OTggNC42MzgwM0MzLjYxNDYgNC4wNzM1NCA0LjA3MzU0IDMuNjE0NiA0LjYzODAzIDMuMzI2OThDNS4yNzk3NiAzIDYuMTE5ODQgMyA3LjggM1oiIHN0cm9rZT0iY3VycmVudENvbG9yIiBzdHJva2Utd2lkdGg9IjEuNSIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIj48L3BhdGg+DQogIDwvc3ltYm9sPg0KICA8c3ltYm9sIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgdmlld0JveD0iMCAwIDI0IDI0IiBpZD0idGltZS10YWtlbi1pY29uIj4NCiAgICA8cGF0aCBkPSJNMTIgMTJMNy43MjcxMSA4LjQzOTI2QzcuMDkyMjYgNy45MTAyMiA2Ljc3NDg0IDcuNjQ1NyA2LjU0NjY0IDcuMzIxNDRDNi4zNDQ0NCA3LjAzNDEzIDYuMTk0MjkgNi43MTM1NCA2LjEwMzAxIDYuMzc0MjhDNiA1Ljk5MTM5IDYgNS41NzgxOSA2IDQuNzUxOFYyTTEyIDEyTDE2LjI3MjkgOC40MzkyNkMxNi45MDc3IDcuOTEwMjIgMTcuMjI1MiA3LjY0NTcgMTcuNDUzNCA3LjMyMTQ0QzE3LjY1NTYgNy4wMzQxMyAxNy44MDU3IDYuNzEzNTQgMTcuODk3IDYuMzc0MjhDMTggNS45OTEzOSAxOCA1LjU3ODE5IDE4IDQuNzUxOFYyTTEyIDEyTDcuNzI3MTEgMTUuNTYwN0M3LjA5MjI2IDE2LjA4OTggNi43NzQ4NCAxNi4zNTQzIDYuNTQ2NjQgMTYuNjc4NkM2LjM0NDQ0IDE2Ljk2NTkgNi4xOTQyOSAxNy4yODY1IDYuMTAzMDEgMTcuNjI1N0M2IDE4LjAwODYgNiAxOC40MjE4IDYgMTkuMjQ4MlYyMk0xMiAxMkwxNi4yNzI5IDE1LjU2MDdDMTYuOTA3NyAxNi4wODk4IDE3LjIyNTIgMTYuMzU0MyAxNy40NTM0IDE2LjY3ODZDMTcuNjU1NiAxNi45NjU5IDE3LjgwNTcgMTcuMjg2NSAxNy44OTcgMTcuNjI1N0MxOCAxOC4wMDg2IDE4IDE4LjQyMTggMTggMTkuMjQ4MlYyMk00IDJIMjBNNCAyMkgyMCIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgPC9zeW1ib2w+DQogIDxzeW1ib2wgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgMjQgMjQiIGlkPSJzZXR1cC1pY29uIj4NCiAgICA8cGF0aCBkPSJNNSAyMUw1IDE1TTUgMTVDNi4xMDQ1NyAxNSA3IDE0LjEwNDYgNyAxM0M3IDExLjg5NTQgNi4xMDQ1NyAxMSA1IDExQzMuODk1NDMgMTEgMyAxMS44OTU0IDMgMTNDMyAxNC4xMDQ2IDMuODk1NDMgMTUgNSAxNVpNNSA3VjNNMTIgMjFWMTVNMTIgN1YzTTEyIDdDMTAuODk1NCA3IDEwIDcuODk1NDMgMTAgOUMxMCAxMC4xMDQ2IDEwLjg5NTQgMTEgMTIgMTFDMTMuMTA0NiAxMSAxNCAxMC4xMDQ2IDE0IDlDMTQgNy44OTU0MyAxMy4xMDQ2IDcgMTIgN1pNMTkgMjFWMTdNMTkgMTdDMjAuMTA0NiAxNyAyMSAxNi4xMDQ2IDIxIDE1QzIxIDEzLjg5NTQgMjAuMTA0NiAxMyAxOSAxM0MxNy44OTU0IDEzIDE3IDEzLjg5NTQgMTcgMTVDMTcgMTYuMTA0NiAxNy44OTU0IDE3IDE5IDE3Wk0xOSA5VjMiIHN0cm9rZT0iY3VycmVudENvbG9yIiBzdHJva2Utd2lkdGg9IjEuNSIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIj48L3BhdGg+DQogIDwvc3ltYm9sPg0KICA8c3ltYm9sIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgdmlld0JveD0iMCAwIDI0IDI0IiBpZD0iZGF0YS1tb2RlbC1pY29uIj4NCiAgICA8cGF0aCBkPSJNNCAxOFYxNy44QzQgMTYuMTE5OCA0IDE1LjI3OTggNC4zMjY5OCAxNC42MzhDNC42MTQ2IDE0LjA3MzUgNS4wNzM1NCAxMy42MTQ2IDUuNjM4MDMgMTMuMzI3QzYuMjc5NzYgMTMgNy4xMTk4NCAxMyA4LjggMTNIMTUuMkMxNi44ODAyIDEzIDE3LjcyMDIgMTMgMTguMzYyIDEzLjMyN0MxOC45MjY1IDEzLjYxNDYgMTkuMzg1NCAxNC4wNzM1IDE5LjY3MyAxNC42MzhDMjAgMTUuMjc5OCAyMCAxNi4xMTk4IDIwIDE3LjhWMThNNCAxOEMyLjg5NTQzIDE4IDIgMTguODk1NCAyIDIwQzIgMjEuMTA0NiAyLjg5NTQzIDIyIDQgMjJDNS4xMDQ1NyAyMiA2IDIxLjEwNDYgNiAyMEM2IDE4Ljg5NTQgNS4xMDQ1NyAxOCA0IDE4Wk0yMCAxOEMxOC44OTU0IDE4IDE4IDE4Ljg5NTQgMTggMjBDMTggMjEuMTA0NiAxOC44OTU0IDIyIDIwIDIyQzIxLjEwNDYgMjIgMjIgMjEuMTA0NiAyMiAyMEMyMiAxOC44OTU0IDIxLjEwNDYgMTggMjAgMThaTTEyIDE4QzEwLjg5NTQgMTggMTAgMTguODk1NCAxMCAyMEMxMCAyMS4xMDQ2IDEwLjg5NTQgMjIgMTIgMjJDMTMuMTA0NiAyMiAxNCAyMS4xMDQ2IDE0IDIwQzE0IDE4Ljg5NTQgMTMuMTA0NiAxOCAxMiAxOFpNMTIgMThWOE02IDhIMThDMTguOTMxOSA4IDE5LjM5NzggOCAxOS43NjU0IDcuODQ3NzZDMjAuMjU1NCA3LjY0NDc3IDIwLjY0NDggNy4yNTU0MiAyMC44NDc4IDYuNzY1MzdDMjEgNi4zOTc4MiAyMSA1LjkzMTg4IDIxIDVDMjEgNC4wNjgxMiAyMSAzLjYwMjE4IDIwLjg0NzggMy4yMzQ2M0MyMC42NDQ4IDIuNzQ0NTggMjAuMjU1NCAyLjM1NTIzIDE5Ljc2NTQgMi4xNTIyNEMxOS4zOTc4IDIgMTguOTMxOSAyIDE4IDJINkM1LjA2ODEyIDIgNC42MDIxOCAyIDQuMjM0NjMgMi4xNTIyNEMzLjc0NDU4IDIuMzU1MjMgMy4zNTUyMyAyLjc0NDU4IDMuMTUyMjQgMy4yMzQ2M0MzIDMuNjAyMTggMyA0LjA2ODEyIDMgNUMzIDUuOTMxODggMyA2LjM5NzgyIDMuMTUyMjQgNi43NjUzN0MzLjM1NTIzIDcuMjU1NDIgMy43NDQ1OCA3LjY0NDc3IDQuMjM0NjMgNy44NDc3NkM0LjYwMjE4IDggNS4wNjgxMiA4IDYgOFoiIHN0cm9rZT0iY3VycmVudENvbG9yIiBzdHJva2Utd2lkdGg9IjEuNSIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIj48L3BhdGg+DQogIDwvc3ltYm9sPg0KICA8c3ltYm9sIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgdmlld0JveD0iMCAwIDI0IDI0IiBpZD0iaW50ZWdyYXRpb24taWNvbiI+DQogICAgPHBhdGggZD0iTTkgMTdIN0M0LjIzODU4IDE3IDIgMTQuNzYxNCAyIDEyQzIgOS4yMzg1OCA0LjIzODU4IDcgNyA3SDlNMTUgMTdIMTdDMTkuNzYxNCAxNyAyMiAxNC43NjE0IDIyIDEyQzIyIDkuMjM4NTggMTkuNzYxNCA3IDE3IDdIMTVNNyAxMkwxNyAxMiIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgPC9zeW1ib2w+DQogIDxzeW1ib2wgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgMjQgMjQiIGlkPSJleHRlcm5hbC1kYXNoYm9hcmQtaWNvbiI+DQogICAgPHBhdGggZD0iTTEyIDNIMTYuMkMxNy44ODAyIDMgMTguNzIwMiAzIDE5LjM2MiAzLjMyNjk4QzE5LjkyNjUgMy42MTQ2IDIwLjM4NTQgNC4wNzM1NCAyMC42NzMgNC42MzgwM0MyMSA1LjI3OTc2IDIxIDYuMTE5ODQgMjEgNy44VjE2LjJDMjEgMTcuODgwMiAyMSAxOC43MjAyIDIwLjY3MyAxOS4zNjJDMjAuMzg1NCAxOS45MjY1IDE5LjkyNjUgMjAuMzg1NCAxOS4zNjIgMjAuNjczQzE4LjcyMDIgMjEgMTcuODgwMiAyMSAxNi4yIDIxSDcuOEM2LjExOTg0IDIxIDUuMjc5NzYgMjEgNC42MzgwMyAyMC42NzNDNC4wNzM1NCAyMC4zODU0IDMuNjE0NiAxOS45MjY1IDMuMzI2OTggMTkuMzYyQzMgMTguNzIwMiAzIDE3Ljg4MDIgMyAxNi4yVjEyTTggMTNWMTdNMTYgMTFWMTdNMTIgN1YxN001IDhWMk0yIDVIOCIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgPC9zeW1ib2w+DQogIDxzeW1ib2wgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgMjQgMjQiIGlkPSJjc3YtaWNvbiI+DQogICAgPHBhdGggZD0iTTIwIDEyLjVWNi44QzIwIDUuMTE5ODQgMjAgNC4yNzk3NiAxOS42NzMgMy42MzgwM0MxOS4zODU0IDMuMDczNTQgMTguOTI2NSAyLjYxNDYgMTguMzYyIDIuMzI2OThDMTcuNzIwMiAyIDE2Ljg4MDIgMiAxNS4yIDJIOC44QzcuMTE5ODQgMiA2LjI3OTc2IDIgNS42MzgwMyAyLjMyNjk4QzUuMDczNTQgMi42MTQ2IDQuNjE0NiAzLjA3MzU0IDQuMzI2OTggMy42MzgwM0M0IDQuMjc5NzYgNCA1LjExOTg0IDQgNi44VjE3LjJDNCAxOC44ODAyIDQgMTkuNzIwMiA0LjMyNjk4IDIwLjM2MkM0LjYxNDYgMjAuOTI2NSA1LjA3MzU0IDIxLjM4NTQgNS42MzgwMyAyMS42NzNDNi4yNzk3NiAyMiA3LjExOTggMjIgOC43OTk4NiAyMkgxMi41TTE0IDExSDhNMTAgMTVIOE0xNiA3SDhNMTUgMTlMMTggMjJNMTggMjJMMjEgMTlNMTggMjJWMTYiIHN0cm9rZT0iY3VycmVudENvbG9yIiBzdHJva2Utd2lkdGg9IjEuNSIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIj48L3BhdGg+DQogIDwvc3ltYm9sPg0KICA8c3ltYm9sIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgdmlld0JveD0iMCAwIDI0IDI0IiBpZD0iaWZyYW1lLWljb24iPg0KICAgIDxwYXRoIGQ9Ik0yMiA5SDJNMTQgMTcuNUwxNi41IDE1TDE0IDEyLjVNMTAgMTIuNUw3LjUgMTVMMTAgMTcuNU0yIDcuOEwyIDE2LjJDMiAxNy44ODAyIDIgMTguNzIwMiAyLjMyNjk4IDE5LjM2MkMyLjYxNDYgMTkuOTI2NSAzLjA3MzU0IDIwLjM4NTQgMy42MzgwMyAyMC42NzNDNC4yNzk3NiAyMSA1LjExOTg0IDIxIDYuOCAyMUgxNy4yQzE4Ljg4MDIgMjEgMTkuNzIwMiAyMSAyMC4zNjIgMjAuNjczQzIwLjkyNjUgMjAuMzg1NCAyMS4zODU0IDE5LjkyNjUgMjEuNjczIDE5LjM2MkMyMiAxOC43MjAyIDIyIDE3Ljg4MDIgMjIgMTYuMlY3LjhDMjIgNi4xMTk4NCAyMiA1LjI3OTc3IDIxLjY3MyA0LjYzODAzQzIxLjM4NTQgNC4wNzM1NCAyMC45MjY1IDMuNjE0NiAyMC4zNjIgMy4zMjY5OEMxOS43MjAyIDMgMTguODgwMiAzIDE3LjIgM0w2LjggM0M1LjExOTg0IDMgNC4yNzk3NiAzIDMuNjM4MDMgMy4zMjY5OEMzLjA3MzU0IDMuNjE0NiAyLjYxNDYgNC4wNzM1NCAyLjMyNjk4IDQuNjM4MDNDMiA1LjI3OTc2IDIgNi4xMTk4NCAyIDcuOFoiIHN0cm9rZT0iY3VycmVudENvbG9yIiBzdHJva2Utd2lkdGg9IjEuNSIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIj48L3BhdGg+DQogIDwvc3ltYm9sPg0KICA8c3ltYm9sIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgdmlld0JveD0iMCAwIDI0IDI0IiBpZD0iZGFzaGJvYXJkLWljb24iPg0KICAgIDxwYXRoIGQ9Ik04IDEzVjE3TTE2IDExVjE3TTEyIDdWMTdNNy44IDIxSDE2LjJDMTcuODgwMiAyMSAxOC43MjAyIDIxIDE5LjM2MiAyMC42NzNDMTkuOTI2NSAyMC4zODU0IDIwLjM4NTQgMTkuOTI2NSAyMC42NzMgMTkuMzYyQzIxIDE4LjcyMDIgMjEgMTcuODgwMiAyMSAxNi4yVjcuOEMyMSA2LjExOTg0IDIxIDUuMjc5NzYgMjAuNjczIDQuNjM4MDNDMjAuMzg1NCA0LjA3MzU0IDE5LjkyNjUgMy42MTQ2IDE5LjM2MiAzLjMyNjk4QzE4LjcyMDIgMyAxNy44ODAyIDMgMTYuMiAzSDcuOEM2LjExOTg0IDMgNS4yNzk3NiAzIDQuNjM4MDMgMy4zMjY5OEM0LjA3MzU0IDMuNjE0NiAzLjYxNDYgNC4wNzM1NCAzLjMyNjk4IDQuNjM4MDNDMyA1LjI3OTc2IDMgNi4xMTk4NCAzIDcuOFYxNi4yQzMgMTcuODgwMiAzIDE4LjcyMDIgMy4zMjY5OCAxOS4zNjJDMy42MTQ2IDE5LjkyNjUgNC4wNzM1NCAyMC4zODU0IDQuNjM4MDMgMjAuNjczQzUuMjc5NzYgMjEgNi4xMTk4NCAyMSA3LjggMjFaIiBzdHJva2U9ImN1cnJlbnRDb2xvciIgc3Ryb2tlLXdpZHRoPSIxLjUiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCI+PC9wYXRoPg0KICA8L3N5bWJvbD4NCiAgPHN5bWJvbCB2aWV3Qm94PSIwIDAgMjQgMjQiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgaWQ9ImRhdGEtZXhwbG9yYXRpb24taWNvbiI+DQogICAgPHBhdGggZD0iTTIzLjQxMDEgNi44NzU0OUg1LjU5OTk5QzQuNTg5MDUgNi44NzU0OSAzLjc2OTUzIDcuNjk1MDEgMy43Njk1MyA4LjcwNTk0VjIwLjc5NjFDMy43Njk1MyAyMS44MDcgNC41ODkwNSAyMi42MjY2IDUuNTk5OTkgMjIuNjI2NkgyMy40MTAxQzI0LjQyMSAyMi42MjY2IDI1LjI0MDUgMjEuODA3IDI1LjI0MDUgMjAuNzk2MVY4LjcwNTk0QzI1LjI0MDUgNy42OTUwMSAyNC40MjEgNi44NzU0OSAyMy40MTAxIDYuODc1NDlaIiBzdHJva2U9ImN1cnJlbnRDb2xvciIgc3Ryb2tlLXdpZHRoPSIxLjUiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCIvPg0KICAgIDxwYXRoIGQ9Ik0xNC41IDQuNDcwN1Y2LjgzNjE3IiBzdHJva2U9ImN1cnJlbnRDb2xvciIgc3Ryb2tlLXdpZHRoPSIxLjUiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCIvPg0KICAgIDxwYXRoIGQ9Ik0xNC40OTkgNC40MTk5QzE1LjQ0MzQgNC40MTk5IDE2LjIwOSAzLjY1NDMzIDE2LjIwOSAyLjcwOTk1QzE2LjIwOSAxLjc2NTU3IDE1LjQ0MzQgMSAxNC40OTkgMUMxMy41NTQ2IDEgMTIuNzg5MSAxLjc2NTU3IDEyLjc4OTEgMi43MDk5NUMxMi43ODkxIDMuNjU0MzMgMTMuNTU0NiA0LjQxOTkgMTQuNDk5IDQuNDE5OVoiIHN0cm9rZT0iY3VycmVudENvbG9yIiBzdHJva2Utd2lkdGg9IjEuNSIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIi8+DQogICAgPHBhdGggZD0iTTI1LjI0NjEgMTEuMzc3OUgyNy4wNjgyQzI3LjU4NDUgMTEuMzc3OSAyOC4wMDMyIDExLjc5NjYgMjguMDAzMiAxMi4zMTI5VjE3LjE4OTNDMjguMDAzMiAxNy43MDU2IDI3LjU4NDUgMTguMTI0MiAyNy4wNjgyIDE4LjEyNDJIMjUuMjUyMyIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiLz4NCiAgICA8cGF0aCBkPSJNMy43NTcxMSAxOC4xMjQySDEuOTM0OTdDMS40MTg2NiAxOC4xMjQyIDEgMTcuNzA1NiAxIDE3LjE4OTNWMTIuMzEyOUMxIDExLjc5NjYgMS40MTg2NiAxMS4zNzc5IDEuOTM0OTcgMTEuMzc3OUgzLjc1NzExIiBzdHJva2U9ImN1cnJlbnRDb2xvciIgc3Ryb2tlLXdpZHRoPSIxLjUiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCIvPg0KICAgIDxwYXRoIGQ9Ik05LjM2MzI4IDEzLjg1NzJDOS4zNjMyOCAxMi45NDYxIDEwLjEwMTkgMTIuMjA4NSAxMS4wMTE5IDEyLjIwODVDMTEuOTIyIDEyLjIwODUgMTIuNjYwNiAxMi45NDcxIDEyLjY2MDYgMTMuODU3MkMxMi42NjA2IDEzLjkwMzkgMTIuNjU4NSAxMy45NDk2IDEyLjY1NDQgMTMuOTk1MyIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiLz4NCiAgICA8cGF0aCBkPSJNMTYuNTc4MSAxMy44NTcyQzE2LjU3ODEgMTIuOTQ2MSAxNy4zMTY3IDEyLjIwODUgMTguMjI2OCAxMi4yMDg1QzE5LjEzNjggMTIuMjA4NSAxOS44NzU0IDEyLjk0NzEgMTkuODc1NCAxMy44NTcyQzE5Ljg3NTQgMTMuOTAzOSAxOS44NzM0IDEzLjk0OTYgMTkuODY5MiAxMy45OTUzIiBzdHJva2U9ImN1cnJlbnRDb2xvciIgc3Ryb2tlLXdpZHRoPSIxLjUiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCIvPg0KICAgIDxwYXRoIGQ9Ik0xOC4wMzA3IDE4LjQwMzhDMTcuMzg0NiAxOC44OTEgMTYuMDI3OCAxOS4yMjU1IDE0LjQ2MDIgMTkuMjI1NUMxMy4wNTc4IDE5LjIyNTUgMTEuODI0NiAxOC45NTc1IDExLjExNzIgMTguNTUyNCIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiLz4NCjwvc3ltYm9sPg0KICA8c3ltYm9sIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgdmlld0JveD0iMCAwIDI0IDI0IiBpZD0icGx1cy1pY29uIj4NCiAgICA8cGF0aCBkPSJNMTIgOFYxNk04IDEySDE2TTcuOCAyMUgxNi4yQzE3Ljg4MDIgMjEgMTguNzIwMiAyMSAxOS4zNjIgMjAuNjczQzE5LjkyNjUgMjAuMzg1NCAyMC4zODU0IDE5LjkyNjUgMjAuNjczIDE5LjM2MkMyMSAxOC43MjAyIDIxIDE3Ljg4MDIgMjEgMTYuMlY3LjhDMjEgNi4xMTk4NCAyMSA1LjI3OTc2IDIwLjY3MyA0LjYzODAzQzIwLjM4NTQgNC4wNzM1NCAxOS45MjY1IDMuNjE0NiAxOS4zNjIgMy4zMjY5OEMxOC43MjAyIDMgMTcuODgwMiAzIDE2LjIgM0g3LjhDNi4xMTk4NCAzIDUuMjc5NzYgMyA0LjYzODAzIDMuMzI2OThDNC4wNzM1NCAzLjYxNDYgMy42MTQ2IDQuMDczNTQgMy4zMjY5OCA0LjYzODAzQzMgNS4yNzk3NiAzIDYuMTE5ODQgMyA3LjhWMTYuMkMzIDE3Ljg4MDIgMyAxOC43MjAyIDMuMzI2OTggMTkuMzYyQzMuNjE0NiAxOS45MjY1IDQuMDczNTQgMjAuMzg1NCA0LjYzODAzIDIwLjY3M0M1LjI3OTc2IDIxIDYuMTE5ODQgMjEgNy44IDIxWiIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgPC9zeW1ib2w+DQogIDxzeW1ib2wgZmlsbD0ibm9uZSIgaWQ9InNxYXVyZS1pY29uIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyNCAyNCI+DQogICAgPHBhdGggZD0ibTcuOCwyMWg4LjRjMS42OCwwLDIuNTIsMCwzLjE2LS4zMy41Ni0uMjksMS4wMi0uNzUsMS4zMS0xLjMxLjMzLS42NC4zMy0xLjQ4LjMzLTMuMTZWNy44YzAtMS42OCwwLTIuNTItLjMzLTMuMTYtLjI5LS41Ni0uNzUtMS4wMi0xLjMxLTEuMzEtLjY0LS4zMy0xLjQ4LS4zMy0zLjE2LS4zM0g3LjhjLTEuNjgsMC0yLjUyLDAtMy4xNi4zMy0uNTYuMjktMS4wMi43NS0xLjMxLDEuMzEtLjMzLjY0LS4zMywxLjQ4LS4zMywzLjE2djguNGMwLDEuNjgsMCwyLjUyLjMzLDMuMTYuMjkuNTYuNzUsMS4wMiwxLjMxLDEuMzEuNjQuMzMsMS40OC4zMywzLjE2LjMzWiI+PC9wYXRoPg0KICA8L3N5bWJvbD4NCiAgPHN5bWJvbCBmaWxsPSJub25lIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyNCAyNCIgaWQ9ImNsb25lLWljb24iPg0KICAgIDxwYXRoIGQ9Ik0xMC41IDIuMDAyOEM5LjgyNDk1IDIuMDExOTQgOS40MTk3IDIuMDUxMDMgOS4wOTIwMiAyLjIxNzk5QzguNzE1NjkgMi40MDk3MyA4LjQwOTczIDIuNzE1NjkgOC4yMTc5OSAzLjA5MjAyQzguMDUxMDMgMy40MTk3IDguMDExOTQgMy44MjQ5NSA4LjAwMjggNC41TTE5LjUgMi4wMDI4QzIwLjE3NTEgMi4wMTE5NCAyMC41ODAzIDIuMDUxMDMgMjAuOTA4IDIuMjE3OTlDMjEuMjg0MyAyLjQwOTczIDIxLjU5MDMgMi43MTU2OSAyMS43ODIgMy4wOTIwMkMyMS45NDkgMy40MTk3IDIxLjk4ODEgMy44MjQ5NCAyMS45OTcyIDQuNDk5OTlNMjEuOTk3MiAxMy41QzIxLjk4ODEgMTQuMTc1IDIxLjk0OSAxNC41ODAzIDIxLjc4MiAxNC45MDhDMjEuNTkwMyAxNS4yODQzIDIxLjI4NDMgMTUuNTkwMyAyMC45MDggMTUuNzgyQzIwLjU4MDMgMTUuOTQ5IDIwLjE3NTEgMTUuOTg4MSAxOS41IDE1Ljk5NzJNMjIgNy45OTk5OVY5Ljk5OTk5TTE0LjAwMDEgMkgxNk01LjIgMjJIMTIuOEMxMy45MjAxIDIyIDE0LjQ4MDIgMjIgMTQuOTA4IDIxLjc4MkMxNS4yODQzIDIxLjU5MDMgMTUuNTkwMyAyMS4yODQzIDE1Ljc4MiAyMC45MDhDMTYgMjAuNDgwMiAxNiAxOS45MjAxIDE2IDE4LjhWMTEuMkMxNiAxMC4wNzk5IDE2IDkuNTE5ODQgMTUuNzgyIDkuMDkyMDJDMTUuNTkwMyA4LjcxNTY5IDE1LjI4NDMgOC40MDk3MyAxNC45MDggOC4yMTc5OUMxNC40ODAyIDggMTMuOTIwMSA4IDEyLjggOEg1LjJDNC4wNzk5IDggMy41MTk4NCA4IDMuMDkyMDIgOC4yMTc5OUMyLjcxNTY5IDguNDA5NzMgMi40MDk3MyA4LjcxNTY5IDIuMjE3OTkgOS4wOTIwMkMyIDkuNTE5ODQgMiAxMC4wNzk5IDIgMTEuMlYxOC44QzIgMTkuOTIwMSAyIDIwLjQ4MDIgMi4yMTc5OSAyMC45MDhDMi40MDk3MyAyMS4yODQzIDIuNzE1NjkgMjEuNTkwMyAzLjA5MjAyIDIxLjc4MkMzLjUxOTg0IDIyIDQuMDc5ODkgMjIgNS4yIDIyWiIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgPC9zeW1ib2w+DQogIDxzeW1ib2wgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgMjQgMjQiIGlkPSJjbG9zZS1pY29uIj4NCiAgICA8cGF0aCBkPSJNMTggNkw2IDE4TTYgNkwxOCAxOCIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgPC9zeW1ib2w+DQogIDxzeW1ib2wgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgMjQgMjQiIGlkPSJkb3VibGUtYXJyb3ctbGVmdC1pY29uIj4NCiAgICA8cGF0aCBkPSJNMTggMTdMMTMgMTJMMTggN00xMSAxN0w2IDEyTDExIDciIHN0cm9rZT0iY3VycmVudENvbG9yIiBzdHJva2Utd2lkdGg9IjEuNSIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIj48L3BhdGg+DQogIDwvc3ltYm9sPg0KICA8c3ltYm9sIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgdmlld0JveD0iMCAwIDI0IDI0IiBpZD0iZG91YmxlLWFycm93LXJpZ2h0LWljb24iPg0KICAgIDxwYXRoIGQ9Ik02IDE3TDExIDEyTDYgN00xMyAxN0wxOCAxMkwxMyA3IiBzdHJva2U9ImN1cnJlbnRDb2xvciIgc3Ryb2tlLXdpZHRoPSIxLjUiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCI+PC9wYXRoPg0KICA8L3N5bWJvbD4NCiAgPHN5bWJvbCBmaWxsPSJub25lIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyNCAyNCIgaWQ9Im1ldHJpYy1zdG9yZS1pY29uIj4NCiAgICA8cGF0aCBkPSJNMTQgMTFIOE0xMCAxNUg4TTE2IDdIOE0yMCAxMC41VjYuOEMyMCA1LjExOTg0IDIwIDQuMjc5NzYgMTkuNjczIDMuNjM4MDNDMTkuMzg1NCAzLjA3MzU0IDE4LjkyNjUgMi42MTQ2IDE4LjM2MiAyLjMyNjk4QzE3LjcyMDIgMiAxNi44ODAyIDIgMTUuMiAySDguOEM3LjExOTg0IDIgNi4yNzk3NiAyIDUuNjM4MDMgMi4zMjY5OEM1LjA3MzU0IDIuNjE0NiA0LjYxNDYgMy4wNzM1NCA0LjMyNjk4IDMuNjM4MDNDNCA0LjI3OTc2IDQgNS4xMTk4NCA0IDYuOFYxNy4yQzQgMTguODgwMiA0IDE5LjcyMDIgNC4zMjY5OCAyMC4zNjJDNC42MTQ2IDIwLjkyNjUgNS4wNzM1NCAyMS4zODU0IDUuNjM4MDMgMjEuNjczQzYuMjc5NzYgMjIgNy4xMTk4NCAyMiA4LjggMjJIMTEuNU0yMiAyMkwyMC41IDIwLjVNMjEuNSAxOEMyMS41IDE5LjkzMyAxOS45MzMgMjEuNSAxOCAyMS41QzE2LjA2NyAyMS41IDE0LjUgMTkuOTMzIDE0LjUgMThDMTQuNSAxNi4wNjcgMTYuMDY3IDE0LjUgMTggMTQuNUMxOS45MzMgMTQuNSAyMS41IDE2LjA2NyAyMS41IDE4WiIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgPC9zeW1ib2w+DQogIDxzeW1ib2wgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgMjQgMjQiIGlkPSJyZXNldC1pY29uIj4NCiAgICA8cGF0aCBkPSJNMiAxMEMyIDEwIDIuMTIxMzIgOS4xNTA3NiA1LjYzNjA0IDUuNjM2MDRDOS4xNTA3NiAyLjEyMTMyIDE0Ljg0OTIgMi4xMjEzMiAxOC4zNjQgNS42MzYwNEMxOS42MDkyIDYuODgxMzEgMjAuNDEzMyA4LjQwMDcyIDIwLjc3NjIgMTBNMiAxMFY0TTIgMTBIOE0yMiAxNEMyMiAxNCAyMS44Nzg3IDE0Ljg0OTIgMTguMzY0IDE4LjM2NEMxNC44NDkyIDIxLjg3ODcgOS4xNTA3NiAyMS44Nzg3IDUuNjM2MDQgMTguMzY0QzQuMzkwNzYgMTcuMTE4NyAzLjU4NjY5IDE1LjU5OTMgMy4yMjM4MyAxNE0yMiAxNFYyME0yMiAxNEgxNiIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgPC9zeW1ib2w+DQogIDxzeW1ib2wgaWQ9InRhYmxlLXRhYi1pY29uIiB2aWV3Qm94PSIwIDAgMjQgMjQiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+DQogICAgPHBhdGggZD0iTTE3IDFIM0MxLjg5NTQzIDEgMSAxLjg5NTQzIDEgM1YxN0MxIDE4LjEwNDYgMS44OTU0MyAxOSAzIDE5SDE3QzE4LjEwNDYgMTkgMTkgMTguMTA0NiAxOSAxN1YzQzE5IDEuODk1NDMgMTguMTA0NiAxIDE3IDFaIiBzdHJva2U9ImN1cnJlbnRDb2xvciIgc3Ryb2tlLXdpZHRoPSIxLjUiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCIvPg0KICAgIDxwYXRoIGQ9Ik0xIDdIMTkiIHN0cm9rZT0iY3VycmVudENvbG9yIiBzdHJva2Utd2lkdGg9IjEuNSIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIi8+DQogICAgPHBhdGggZD0iTTQgMTBINiIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiLz4NCiAgICA8cGF0aCBkPSJNNCAxM0g2IiBzdHJva2U9ImN1cnJlbnRDb2xvciIgc3Ryb2tlLXdpZHRoPSIxLjUiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCIvPg0KICAgIDxwYXRoIGQ9Ik00IDE2SDYiIHN0cm9rZT0iY3VycmVudENvbG9yIiBzdHJva2Utd2lkdGg9IjEuNSIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIi8+DQogICAgPHBhdGggZD0iTTkgMTBIMTEiIHN0cm9rZT0iY3VycmVudENvbG9yIiBzdHJva2Utd2lkdGg9IjEuNSIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIi8+DQogICAgPHBhdGggZD0iTTkgMTNIMTEiIHN0cm9rZT0iY3VycmVudENvbG9yIiBzdHJva2Utd2lkdGg9IjEuNSIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIi8+DQogICAgPHBhdGggZD0iTTkgMTZIMTEiIHN0cm9rZT0iY3VycmVudENvbG9yIiBzdHJva2Utd2lkdGg9IjEuNSIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIi8+DQogICAgPHBhdGggZD0iTTE0IDEwSDE2IiBzdHJva2U9ImN1cnJlbnRDb2xvciIgc3Ryb2tlLXdpZHRoPSIxLjUiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCIvPg0KICAgIDxwYXRoIGQ9Ik0xNCAxM0gxNiIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiLz4NCiAgICA8cGF0aCBkPSJNMTQgMTZIMTYiIHN0cm9rZT0iY3VycmVudENvbG9yIiBzdHJva2Utd2lkdGg9IjEuNSIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIi8+DQogIDwvc3ltYm9sPg0KICA8c3ltYm9sIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgdmlld0JveD0iMCAwIDI0IDI0IiBpZD0icGxheS1pY29uIj4NCiAgICA8cGF0aCBkPSJNMTIgMjJDMTcuNTIyOCAyMiAyMiAxNy41MjI4IDIyIDEyQzIyIDYuNDc3MTUgMTcuNTIyOCAyIDEyIDJDNi40NzcxNSAyIDIgNi40NzcxNSAyIDEyQzIgMTcuNTIyOCA2LjQ3NzE1IDIyIDEyIDIyWiIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgICA8cGF0aCBkPSJNOS41IDguOTY1MzNDOS41IDguNDg4MDUgOS41IDguMjQ5NDEgOS41OTk3NCA4LjExNjE4QzkuNjg2NjYgOC4wMDAwNyA5LjgxOTcxIDcuOTI3NDQgOS45NjQzOCA3LjkxNzFDMTAuMTMwNCA3LjkwNTI1IDEwLjMzMTEgOC4wMzQyOSAxMC43MzI2IDguMjkyMzlMMTUuNDUzMiAxMS4zMjcxQzE1LjgwMTYgMTEuNTUxIDE1Ljk3NTggMTEuNjYzIDE2LjAzNTkgMTEuODA1NEMxNi4wODg1IDExLjkyOTggMTYuMDg4NSAxMi4wNzAyIDE2LjAzNTkgMTIuMTk0NkMxNS45NzU4IDEyLjMzNyAxNS44MDE2IDEyLjQ0OSAxNS40NTMyIDEyLjY3MjlMMTAuNzMyNiAxNS43MDc2QzEwLjMzMTEgMTUuOTY1NyAxMC4xMzA0IDE2LjA5NDggOS45NjQzOCAxNi4wODI5QzkuODE5NzEgMTYuMDcyNiA5LjY4NjY2IDE1Ljk5OTkgOS41OTk3NCAxNS44ODM4QzkuNSAxNS43NTA2IDkuNSAxNS41MTIgOS41IDE1LjAzNDdWOC45NjUzM1oiIHN0cm9rZT0iY3VycmVudENvbG9yIiBzdHJva2Utd2lkdGg9IjEuNSIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIj48L3BhdGg+DQogIDwvc3ltYm9sPg0KICA8c3ltYm9sIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgdmlld0JveD0iMCAwIDI0IDI0IiBpZD0idGljay1pY29uIj4NCiAgICA8cGF0aCBkPSJNMjAgNkw5IDE3TDQgMTIiIHN0cm9rZT0iY3VycmVudENvbG9yIiBzdHJva2Utd2lkdGg9IjEuNSIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIj48L3BhdGg+DQogIDwvc3ltYm9sPg0KICA8c3ltYm9sIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgdmlld0JveD0iMCAwIDI0IDI0IiBpZD0idGV4dC1pY29uIj4NCiAgICA8cGF0aCBkPSJNNCA3QzQgNi4wNjgxMiA0IDUuNjAyMTggNC4xNTIyNCA1LjIzNDYzQzQuMzU1MjMgNC43NDQ1OCA0Ljc0NDU4IDQuMzU1MjMgNS4yMzQ2MyA0LjE1MjI0QzUuNjAyMTggNCA2LjA2ODEyIDQgNyA0SDE3QzE3LjkzMTkgNCAxOC4zOTc4IDQgMTguNzY1NCA0LjE1MjI0QzE5LjI1NTQgNC4zNTUyMyAxOS42NDQ4IDQuNzQ0NTggMTkuODQ3OCA1LjIzNDYzQzIwIDUuNjAyMTggMjAgNi4wNjgxMiAyMCA3TTkgMjBIMTVNMTIgNFYyMCIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgPC9zeW1ib2w+DQogIDxzeW1ib2wgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgMjQgMjQiIGlkPSJ0aW1lLWljb24iPg0KICAgIDxwYXRoIGQ9Ik0xMiA2VjEyTDE2IDE0TTIyIDEyQzIyIDE3LjUyMjggMTcuNTIyOCAyMiAxMiAyMkM2LjQ3NzE1IDIyIDIgMTcuNTIyOCAyIDEyQzIgNi40NzcxNSA2LjQ3NzE1IDIgMTIgMkMxNy41MjI4IDIgMjIgNi40NzcxNSAyMiAxMloiIHN0cm9rZT0iY3VycmVudENvbG9yIiBzdHJva2Utd2lkdGg9IjEuNSIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIj48L3BhdGg+DQogIDwvc3ltYm9sPg0KICA8c3ltYm9sIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgdmlld0JveD0iMCAwIDI0IDI0IiBpZD0idW5rbm93bi1pY29uIj4NCiAgICA8cGF0aCBkPSJNMTAgOC4wMDIyNEMxMC4xNzYyIDcuNTAxMzYgMTAuNTI0IDcuMDc5MDEgMTAuOTgxNyA2LjgwOTk4QzExLjQzOTUgNi41NDA5NSAxMS45Nzc3IDYuNDQyNiAxMi41MDEgNi41MzIzN0MxMy4wMjQzIDYuNjIyMTMgMTMuNDk5IDYuODk0MjEgMTMuODQwOSA3LjMwMDQxQzE0LjE4MjkgNy43MDY2MSAxNC4zNyA4LjIyMDcyIDE0LjM2OTIgOC43NTE2OEMxNC4zNjkyIDEwLjI1MDYgMTIuMTIwOSAxMSAxMi4xMjA5IDExTTEyLjE0OTkgMTRIMTIuMTU5OU03IDE4VjIwLjMzNTVDNyAyMC44Njg0IDcgMjEuMTM0OCA3LjEwOTIzIDIxLjI3MTZDNy4yMDQyMiAyMS4zOTA2IDcuMzQ4MjcgMjEuNDU5OSA3LjUwMDU0IDIxLjQ1OTdDNy42NzU2MyAyMS40NTk1IDcuODgzNjcgMjEuMjkzMSA4LjI5OTc2IDIwLjk2MDJMMTAuNjg1MiAxOS4wNTE4QzExLjE3MjUgMTguNjYyIDExLjQxNjIgMTguNDY3MSAxMS42ODc1IDE4LjMyODVDMTEuOTI4MiAxOC4yMDU1IDEyLjE4NDQgMTguMTE1NiAxMi40NDkyIDE4LjA2MTNDMTIuNzQ3NyAxOCAxMy4wNTk3IDE4IDEzLjY4MzcgMThIMTYuMkMxNy44ODAyIDE4IDE4LjcyMDIgMTggMTkuMzYyIDE3LjY3M0MxOS45MjY1IDE3LjM4NTQgMjAuMzg1NCAxNi45MjY1IDIwLjY3MyAxNi4zNjJDMjEgMTUuNzIwMiAyMSAxNC44ODAyIDIxIDEzLjJWNy44QzIxIDYuMTE5ODQgMjEgNS4yNzk3NiAyMC42NzMgNC42MzgwM0MyMC4zODU0IDQuMDczNTQgMTkuOTI2NSAzLjYxNDYgMTkuMzYyIDMuMzI2OThDMTguNzIwMiAzIDE3Ljg4MDIgMyAxNi4yIDNINy44QzYuMTE5ODQgMyA1LjI3OTc2IDMgNC42MzgwMyAzLjMyNjk4QzQuMDczNTQgMy42MTQ2IDMuNjE0NiA0LjA3MzU0IDMuMzI2OTggNC42MzgwM0MzIDUuMjc5NzYgMyA2LjExOTg0IDMgNy44VjE0QzMgMTQuOTMgMyAxNS4zOTUgMy4xMDIyMiAxNS43NzY1QzMuMzc5NjIgMTYuODExNyA0LjE4ODI3IDE3LjYyMDQgNS4yMjM1NCAxNy44OTc4QzUuNjA1MDQgMTggNi4wNzAwMyAxOCA3IDE4WiIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgPC9zeW1ib2w+DQogIDxzeW1ib2wgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgMjQgMjQiIGlkPSJhcnJheS1pY29uIj4NCiAgICA8cGF0aCBkPSJNMTIgNkMxMi41NTIzIDYgMTMgNS41NTIyOCAxMyA1QzEzIDQuNDQ3NzIgMTIuNTUyMyA0IDEyIDRDMTEuNDQ3NyA0IDExIDQuNDQ3NzIgMTEgNUMxMSA1LjU1MjI4IDExLjQ0NzcgNiAxMiA2WiIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgICA8cGF0aCBkPSJNMTIgMTNDMTIuNTUyMyAxMyAxMyAxMi41NTIzIDEzIDEyQzEzIDExLjQ0NzcgMTIuNTUyMyAxMSAxMiAxMUMxMS40NDc3IDExIDExIDExLjQ0NzcgMTEgMTJDMTEgMTIuNTUyMyAxMS40NDc3IDEzIDEyIDEzWiIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgICA8cGF0aCBkPSJNMTIgMjBDMTIuNTUyMyAyMCAxMyAxOS41NTIzIDEzIDE5QzEzIDE4LjQ0NzcgMTIuNTUyMyAxOCAxMiAxOEMxMS40NDc3IDE4IDExIDE4LjQ0NzcgMTEgMTlDMTEgMTkuNTUyMyAxMS40NDc3IDIwIDEyIDIwWiIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgICA8cGF0aCBkPSJNMTkgNkMxOS41NTIzIDYgMjAgNS41NTIyOCAyMCA1QzIwIDQuNDQ3NzIgMTkuNTUyMyA0IDE5IDRDMTguNDQ3NyA0IDE4IDQuNDQ3NzIgMTggNUMxOCA1LjU1MjI4IDE4LjQ0NzcgNiAxOSA2WiIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgICA8cGF0aCBkPSJNMTkgMTNDMTkuNTUyMyAxMyAyMCAxMi41NTIzIDIwIDEyQzIwIDExLjQ0NzcgMTkuNTUyMyAxMSAxOSAxMUMxOC40NDc3IDExIDE4IDExLjQ0NzcgMTggMTJDMTggMTIuNTUyMyAxOC40NDc3IDEzIDE5IDEzWiIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgICA8cGF0aCBkPSJNMTkgMjBDMTkuNTUyMyAyMCAyMCAxOS41NTIzIDIwIDE5QzIwIDE4LjQ0NzcgMTkuNTUyMyAxOCAxOSAxOEMxOC40NDc3IDE4IDE4IDE4LjQ0NzcgMTggMTlDMTggMTkuNTUyMyAxOC40NDc3IDIwIDE5IDIwWiIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgICA8cGF0aCBkPSJNNSA2QzUuNTUyMjggNiA2IDUuNTUyMjggNiA1QzYgNC40NDc3MiA1LjU1MjI4IDQgNSA0QzQuNDQ3NzIgNCA0IDQuNDQ3NzIgNCA1QzQgNS41NTIyOCA0LjQ0NzcyIDYgNSA2WiIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgICA8cGF0aCBkPSJNNSAxM0M1LjU1MjI4IDEzIDYgMTIuNTUyMyA2IDEyQzYgMTEuNDQ3NyA1LjU1MjI4IDExIDUgMTFDNC40NDc3MiAxMSA0IDExLjQ0NzcgNCAxMkM0IDEyLjU1MjMgNC40NDc3MiAxMyA1IDEzWiIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgICA8cGF0aCBkPSJNNSAyMEM1LjU1MjI4IDIwIDYgMTkuNTUyMyA2IDE5QzYgMTguNDQ3NyA1LjU1MjI4IDE4IDUgMThDNC40NDc3MiAxOCA0IDE4LjQ0NzcgNCAxOUM0IDE5LjU1MjMgNC40NDc3MiAyMCA1IDIwWiIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgPC9zeW1ib2w+DQogIDxzeW1ib2wgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgMjQgMjQiIGlkPSJkYXRlLWljb24iPg0KICAgIDxwYXRoIGQ9Ik0yMSAxMEgzTTE2IDJWNk04IDJWNk03LjggMjJIMTYuMkMxNy44ODAyIDIyIDE4LjcyMDIgMjIgMTkuMzYyIDIxLjY3M0MxOS45MjY1IDIxLjM4NTQgMjAuMzg1NCAyMC45MjY1IDIwLjY3MyAyMC4zNjJDMjEgMTkuNzIwMiAyMSAxOC44ODAyIDIxIDE3LjJWOC44QzIxIDcuMTE5ODQgMjEgNi4yNzk3NiAyMC42NzMgNS42MzgwM0MyMC4zODU0IDUuMDczNTQgMTkuOTI2NSA0LjYxNDYgMTkuMzYyIDQuMzI2OThDMTguNzIwMiA0IDE3Ljg4MDIgNCAxNi4yIDRINy44QzYuMTE5ODQgNCA1LjI3OTc2IDQgNC42MzgwMyA0LjMyNjk4QzQuMDczNTQgNC42MTQ2IDMuNjE0NiA1LjA3MzU0IDMuMzI2OTggNS42MzgwM0MzIDYuMjc5NzYgMyA3LjExOTg0IDMgOC44VjE3LjJDMyAxOC44ODAyIDMgMTkuNzIwMiAzLjMyNjk4IDIwLjM2MkMzLjYxNDYgMjAuOTI2NSA0LjA3MzU0IDIxLjM4NTQgNC42MzgwMyAyMS42NzNDNS4yNzk3NiAyMiA2LjExOTg0IDIyIDcuOCAyMloiIHN0cm9rZT0iY3VycmVudENvbG9yIiBzdHJva2Utd2lkdGg9IjEuNSIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIj48L3BhdGg+DQogIDwvc3ltYm9sPg0KICA8c3ltYm9sIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgdmlld0JveD0iMCAwIDI0IDI0IiBpZD0iYm9vbGVhbi1pY29uIj4NCiAgICA8cGF0aCBkPSJNMTUuMDUwNSA5SDUuNUM0LjExOTI5IDkgMyA3Ljg4MDcxIDMgNi41QzMgNS4xMTkyOSA0LjExOTI5IDQgNS41IDRIMTUuMDUwNU04Ljk0OTQ5IDIwSDE4LjVDMTkuODgwNyAyMCAyMSAxOC44ODA3IDIxIDE3LjVDMjEgMTYuMTE5MyAxOS44ODA3IDE1IDE4LjUgMTVIOC45NDk0OU0zIDE3LjVDMyAxOS40MzMgNC41NjcgMjEgNi41IDIxQzguNDMzIDIxIDEwIDE5LjQzMyAxMCAxNy41QzEwIDE1LjU2NyA4LjQzMyAxNCA2LjUgMTRDNC41NjcgMTQgMyAxNS41NjcgMyAxNy41Wk0yMSA2LjVDMjEgOC40MzMgMTkuNDMzIDEwIDE3LjUgMTBDMTUuNTY3IDEwIDE0IDguNDMzIDE0IDYuNUMxNCA0LjU2NyAxNS41NjcgMyAxNy41IDNDMTkuNDMzIDMgMjEgNC41NjcgMjEgNi41WiIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgPC9zeW1ib2w+DQogIDxzeW1ib2wgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgMjQgMjQiIGlkPSJpZC1pY29uIj4NCiAgICA8cGF0aCBkPSJNOS40OTk5OSAzTDYuNDk5OTkgMjFNMTcuNSAzTDE0LjUgMjFNMjAuNSA4SDMuNU0xOS41IDE2SDIuNSIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgPC9zeW1ib2w+DQogIDxzeW1ib2wgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgMjQgMjQiIGlkPSJudW1iZXItaWNvbiI+DQogICAgPHBhdGggZD0iTTE5LjkwNjEgMjFDMjEuMjQ2NCAxOC4yODg4IDIyIDE1LjIzMjkgMjIgMTJDMjIgOC43NjcxMSAyMS4yNDY0IDUuNzExMTYgMTkuOTA2MSAzTTQuMDkzOTMgM0MyLjc1MzYzIDUuNzExMTYgMiA4Ljc2NzExIDIgMTJDMiAxNS4yMzI5IDIuNzUzNjMgMTguMjg4OCA0LjA5MzkzIDIxTTE2LjU0ODYgOC42MjVIMTYuNDU5QzE1LjgwNTYgOC42MjUgMTUuMTg0OCA4LjkxMjAyIDE0Ljc1OTYgOS40MTA3Mkw5LjM4NDcxIDE1LjcxNDNDOC45NTk0OCAxNi4yMTMgOC4zMzg3MSAxNi41IDcuNjg1MyAxNi41SDcuNTk1NjNNOC43MTQ4MyA4LjYyNUgxMC4xMDg5QzEwLjYwODYgOC42MjUgMTEuMDQ3NyA4Ljk1Nzk3IDExLjE4NSA5LjQ0MDk0TDEyLjk1OTQgMTUuNjg0MUMxMy4wOTY3IDE2LjE2NyAxMy41MzU4IDE2LjUgMTQuMDM1NSAxNi41SDE1LjQyOTYiIHN0cm9rZT0iY3VycmVudENvbG9yIiBzdHJva2Utd2lkdGg9IjEuNSIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIj48L3BhdGg+DQogIDwvc3ltYm9sPg0KICA8c3ltYm9sIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgdmlld0JveD0iMCAwIDI0IDI0IiBpZD0ib2JqZWN0LWljb24iPg0KICAgIDxwYXRoIGQ9Ik0xNyAxN0wyMiAxMkwxNyA3TTcgN0wyIDEyTDcgMTdNMTQgM0wxMCAyMSIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIHN0cm9rZS13aWR0aD0iMS41IiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjwvcGF0aD4NCiAgPC9zeW1ib2w+DQo8L3N2Zz4=",hF={icons:"_icons_1u812_1"};const lt=({name:r,className:e})=>S("svg",{className:e!=null?e:hF.icons,children:S("use",{href:`${fF}#${r}`})}),dm=({datatype:r="unknown",className:e})=>cm.includes(r.toLowerCase())?S(lt,{name:"number-icon",className:e}):fm.includes(r.toLowerCase())||r.toLowerCase().includes("char")?S(lt,{name:"text-icon",className:e}):gS.includes(r.toLowerCase())?S(lt,{name:"array-icon",className:e}):hm.includes(r.toLowerCase())?S(lt,{name:"date-icon",className:e}):vm.includes(r.toLowerCase())?S(lt,{name:"boolean-icon",className:e}):S(lt,{name:"unknown-icon"});var vF={error:"_error_1csa7_1"};const pm=({message:r=""})=>S(de,{variant:"p",styleClass:"custom",className:vF.error,children:r});var yS={container:"_container_7vfcn_1",windowIcon:"_windowIcon_7vfcn_7"};const dF=r=>S("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",...r,children:B("g",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeWidth:1.5,children:[S("path",{d:"M15 21H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2v10"}),S("path",{strokeLinejoin:"round",d:"M2 7h20M5 5.01l.01-.011M8 5.01l.01-.011M11 5.01l.01-.011M18 22.243l2.121-2.122m0 0L22.243 18m-2.122 2.121L18 18m2.121 2.121l2.122 2.122"})]})}),mS=()=>B("div",{role:"alert",className:yS.container,children:[S(dF,{className:yS.windowIcon}),S(de,{variant:"p",styleClass:"font-20",children:"Something went wrong!"}),S(Ce,{variant:"primary",size:"large",type:"button",onClick:()=>location.reload(),children:"Try again"})]});var oi={form:"_form_qtwuf_1",container:"_container_qtwuf_7",field:"_field_qtwuf_13",fieldLabel:"_fieldLabel_qtwuf_19",save:"_save_qtwuf_25",cancel:"_cancel_qtwuf_31",error:"_error_qtwuf_37"},Gi={label:"_label_wdxiv_1",floatingLabel:"_floatingLabel_wdxiv_7","inputField-container":"_inputField-container_wdxiv_13",checkboxLabel:"_checkboxLabel_wdxiv_19",input:"_input_wdxiv_13",floatingInput:"_floatingInput_wdxiv_31",checkboxField:"_checkboxField_wdxiv_37",inputWrapper:"_inputWrapper_wdxiv_43"};const Ct=({type:r="text",register:e,error:t,icon:n,label:a,isDisabled:i,labelClass:o,inputClass:s,className:l,labelVariant:u="static",id:c,...f})=>["checkbox","radio"].includes(r)?B("div",{className:`${Gi.checkboxField} ${l!=null?l:""}`,children:[S("input",{...f,type:r,id:c,className:s,...e,disabled:i}),a?B("label",{htmlFor:c,className:`${Gi.checkboxLabel} ${o}`,children:[n," ",a]}):null]}):B("div",{className:`${Gi["inputField-container"]} ${l!=null?l:""}`,children:[a?S("label",{htmlFor:c,className:`${Gi.label} ${u==="floating"?Gi.floatingLabel:""} ${o}`,children:a}):null,B("div",{className:Gi.inputWrapper,children:[S("input",{...f,id:c,type:r,className:`${Gi.input} ${u==="floating"?Gi.floatingInput:""} ${s}`,...e,disabled:i}),n]}),t&&S(pm,{message:t.message})]});var gm={label:"_label_1vo1x_1",textarea:"_textarea_1vo1x_9",resizable:"_resizable_1vo1x_17"};const _S=({id:r,label:e,placeholder:t,rows:n,cols:a,resizable:i=!0,register:o,error:s,defaultValue:l,value:u,onFocus:c,onBlur:f,className:h})=>B("div",{className:h,children:[S("label",{htmlFor:r,className:gm.label,children:e}),S("textarea",{id:r,name:r,rows:n,cols:a,placeholder:t,className:Na(gm.textarea,`${i?null:gm.resizable}`),defaultValue:l,...o,value:u,onFocus:c,onBlur:f}),s&&S(pm,{message:s.message})]});var si={group:"_group_13otg_1",button:"_button_13otg_9",checkbox:"_checkbox_13otg_17",switch:"_switch_13otg_25",enabled:"_enabled_13otg_43",notenabled:"_notenabled_13otg_59",label:"_label_13otg_75",labelActive:"_labelActive_13otg_83",labelInactive:"_labelInactive_13otg_91"};const ym=({enabled:r,onChange:e,label:t,className:n="",placeholder:a,labelClassName:i,defaultEnabled:o})=>B("div",{className:`${si.group} ${n}`,children:[t?S(de,{styleClass:"font-14",variant:"p",className:i,children:t}):null,S("input",{type:"checkbox",id:"toggle",checked:o,onChange:({target:s})=>e==null?void 0:e(s.checked),className:si.checkbox}),B("label",{htmlFor:"toggle",className:si.button,children:[S("span",{className:`${si.switch} ${r?si.enabled:si.notenabled}`}),a?S("span",{className:`
|
|
18
|
+
${si.label}
|
|
19
|
+
${r?si.labelActive:si.labelInactive}
|
|
20
|
+
`,children:a}):null]})]});var Al={modal:"_modal_ul4ir_1",popup:"_popup_ul4ir_9",header:"_header_ul4ir_17",headerTitle:"_headerTitle_ul4ir_25",content:"_content_ul4ir_33",footer:"_footer_ul4ir_41"};const li=({children:r,isOpen:e,onClose:t,headerTitle:n,customHeader:a,icon:i})=>{const[o,s]=R.useState();return R.useEffect(()=>{const l=document.getElementById("databrain-root-portal")||document.createElement("div");l.setAttribute("id","databrain-root-portal"),document.body.appendChild(l),s(l)},[]),e?Fh.default.createPortal(S("div",{className:Al.modal,onClick:t,children:B("div",{className:Al.popup,onClick:l=>{l.stopPropagation()},children:[S("section",{className:Al.header,children:a||B(we,{children:[B("span",{className:Al.headerTitle,children:[i,n]}),S(Ce,{variant:"custom",type:"button",onClick:t,children:S(lt,{name:"close-icon"})})]})}),S("section",{className:Al.content,children:r})]})}),o):null},Cl=({children:r,className:e})=>S("section",{className:`${Al.footer} ${e}`,children:r}),gn=(r,e,t)=>async()=>{const a=await(await fetch("https://backend.usedatabrain.com/v1/graphql",{method:"POST",headers:{"Content-Type":"application/json","X-Hasura-Role":"anonymous",...t},body:JSON.stringify({query:r,variables:e})})).json();if(a.errors){const{message:i}=a.errors[0];throw new Error(i)}return a.data},pF=`
|
|
21
|
+
mutation CreateExternalMetric($chartOptions: jsonb = "", $companyId: uuid = "", $companyIntegrationId: uuid = "", $description: String = "", $inputFields: jsonb = "", $integrationName: String = "", $metricId: String = "", $metricQuery: String = "", $name: String = "", $outputColumns: String = "", $query: String = "", $isLive: Boolean, $clientId: String = "", $isCreatedByClient: Boolean = false, $createdBy: String = "", $timeGrain: String = "", $externalDashboardIds: [externalDashboardMetrics_insert_input!] = {}, $selectedGroupBy: jsonb = [], $isEnableGroupBy: Boolean = false, $groupBy: jsonb = {}) {
|
|
22
|
+
insert_externalMetrics_one(
|
|
23
|
+
object: {chartOptions: $chartOptions, companyId: $companyId, companyIntegrationId: $companyIntegrationId, description: $description, inputFields: $inputFields, integrationName: $integrationName, metricId: $metricId, metricQuery: $metricQuery, name: $name, outputColumns: $outputColumns, query: $query, isLive: $isLive, clientId: $clientId, isCreatedByClient: $isCreatedByClient, createdBy: $createdBy, timeGrain: $timeGrain, externalDashboardMetrics: {data: $externalDashboardIds}, selectedGroupBy: $selectedGroupBy, isEnableGroupBy: $isEnableGroupBy, groupBy: $groupBy}
|
|
24
|
+
) {
|
|
25
|
+
id
|
|
26
|
+
externalDashboardMetrics {
|
|
27
|
+
externalDashboardId
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
`,gF=r=>xl(["CreateExternalMetric"],e=>gn(pF,e)(),r),yF=`
|
|
32
|
+
mutation FetchColumnData($companyId: String = "", $tableName: String = "", $columnName: String = "") {
|
|
33
|
+
fetchColumnData(
|
|
34
|
+
input: {columnName: $columnName, companyId: $companyId, tableName: $tableName}
|
|
35
|
+
) {
|
|
36
|
+
data {
|
|
37
|
+
label
|
|
38
|
+
value
|
|
39
|
+
}
|
|
40
|
+
error {
|
|
41
|
+
message
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
`,mF=r=>xl(["FetchColumnData"],e=>gn(yF,e)(),r),_F=`
|
|
46
|
+
mutation GenerateDatasetMetrics($companyId: String = "", $userInputs: json = "") {
|
|
47
|
+
generateDatasetMetrics(input: {companyId: $companyId, userInputs: $userInputs}) {
|
|
48
|
+
error
|
|
49
|
+
query
|
|
50
|
+
result
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
`,bF=r=>xl(["GenerateDatasetMetrics"],e=>gn(_F,e)(),r),MF=`
|
|
54
|
+
mutation GenerateEmbeddedMetic($clientId: String = "", $companyId: String = "", $queryPrompt: String = "", $timeGrain: String = "") {
|
|
55
|
+
generateEmbeddedMetic(
|
|
56
|
+
input: {clientId: $clientId, companyId: $companyId, queryPrompt: $queryPrompt, timeGrain: $timeGrain}
|
|
57
|
+
) {
|
|
58
|
+
query
|
|
59
|
+
result
|
|
60
|
+
error {
|
|
61
|
+
message
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
`,xF=r=>xl(["GenerateEmbeddedMetic"],e=>gn(MF,e)(),r),wF=`
|
|
66
|
+
mutation CompanySubsetTableData($clientId: String = "", $companyId: String = "") {
|
|
67
|
+
companySubsetTableData(input: {clientId: $clientId, companyId: $companyId}) {
|
|
68
|
+
companyIntegrationId
|
|
69
|
+
dbName
|
|
70
|
+
error {
|
|
71
|
+
message
|
|
72
|
+
}
|
|
73
|
+
tableList {
|
|
74
|
+
tableName
|
|
75
|
+
columns {
|
|
76
|
+
datatype
|
|
77
|
+
name
|
|
78
|
+
as
|
|
79
|
+
}
|
|
80
|
+
clientColumn
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
`,DF=r=>xl(["CompanySubsetTableData"],e=>gn(wF,e)(),r),SF=`
|
|
85
|
+
query EmbeddedDashboardMetrics($where: externalDashboardMetrics_bool_exp) {
|
|
86
|
+
externalDashboardMetrics(where: $where) {
|
|
87
|
+
externalMetricId
|
|
88
|
+
externalDashboardId
|
|
89
|
+
externalMetric {
|
|
90
|
+
chartOptions
|
|
91
|
+
clientId
|
|
92
|
+
companyId
|
|
93
|
+
companyIntegrationId
|
|
94
|
+
createdAt
|
|
95
|
+
createdBy
|
|
96
|
+
description
|
|
97
|
+
id
|
|
98
|
+
inputFields
|
|
99
|
+
integrationName
|
|
100
|
+
isCreatedByClient
|
|
101
|
+
isLive
|
|
102
|
+
metricId
|
|
103
|
+
metricQuery
|
|
104
|
+
name
|
|
105
|
+
outputColumns
|
|
106
|
+
query
|
|
107
|
+
resizeAttributes
|
|
108
|
+
timeGrain
|
|
109
|
+
updatedAt
|
|
110
|
+
selectedGroupBy
|
|
111
|
+
isEnableGroupBy
|
|
112
|
+
groupBy
|
|
113
|
+
rlsConditions
|
|
114
|
+
companyIntegration {
|
|
115
|
+
name
|
|
116
|
+
}
|
|
117
|
+
clickActions
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
`,IF=(r,e)=>Fo(r===void 0?["EmbeddedDashboardMetrics"]:["EmbeddedDashboardMetrics",r],gn(SF,r),e),TF=`
|
|
122
|
+
query GetExternalDashboardId($externalDashboardId: String = "") {
|
|
123
|
+
externalDashboards(where: {externalDashboardId: {_eq: $externalDashboardId}}) {
|
|
124
|
+
id
|
|
125
|
+
filters
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
`,AF=(r,e)=>Fo(r===void 0?["GetExternalDashboardId"]:["GetExternalDashboardId",r],gn(TF,r),e),CF=`
|
|
129
|
+
query ExternalDashboardList($companyId: uuid = "") {
|
|
130
|
+
externalDashboards(where: {companyId: {_eq: $companyId}}) {
|
|
131
|
+
externalDashboardId
|
|
132
|
+
name
|
|
133
|
+
id
|
|
134
|
+
}
|
|
135
|
+
}
|
|
136
|
+
`,NF=(r,e)=>Fo(r===void 0?["ExternalDashboardList"]:["ExternalDashboardList",r],gn(CF,r),e),LF=`
|
|
137
|
+
query GuestTokenParams($id: uuid = "") {
|
|
138
|
+
guestTokens_by_pk(id: $id) {
|
|
139
|
+
clientId
|
|
140
|
+
companyId
|
|
141
|
+
id
|
|
142
|
+
params
|
|
143
|
+
}
|
|
144
|
+
}
|
|
145
|
+
`,EF=(r,e)=>Fo(r===void 0?["GuestTokenParams"]:["GuestTokenParams",r],gn(LF,r),e),OF=`
|
|
146
|
+
query MetricCreationAccess($companyId: uuid = "") {
|
|
147
|
+
companySubsetTables(where: {companyId: {_eq: $companyId}}) {
|
|
148
|
+
isAllowMetricCreation
|
|
149
|
+
}
|
|
150
|
+
}
|
|
151
|
+
`,PF=(r,e)=>Fo(r===void 0?["MetricCreationAccess"]:["MetricCreationAccess",r],gn(OF,r),e),zF=`
|
|
152
|
+
query GetThemes($companyId: uuid! = "") {
|
|
153
|
+
themes(where: {companyId: {_eq: $companyId}}) {
|
|
154
|
+
id
|
|
155
|
+
companyId
|
|
156
|
+
general
|
|
157
|
+
dashboard
|
|
158
|
+
cardTitle
|
|
159
|
+
cardDescription
|
|
160
|
+
chart
|
|
161
|
+
}
|
|
162
|
+
}
|
|
163
|
+
`,kF=(r,e)=>Fo(r===void 0?["GetThemes"]:["GetThemes",r],gn(zF,r),e),RF=`
|
|
164
|
+
mutation PreviewTable($companyId: String = "", $tableName: String = "", $limit: Int = 10) {
|
|
165
|
+
previewTable(
|
|
166
|
+
input: {companyId: $companyId, tableName: $tableName, limit: $limit}
|
|
167
|
+
) {
|
|
168
|
+
data {
|
|
169
|
+
data
|
|
170
|
+
isError
|
|
171
|
+
name
|
|
172
|
+
}
|
|
173
|
+
error {
|
|
174
|
+
message
|
|
175
|
+
}
|
|
176
|
+
}
|
|
177
|
+
}
|
|
178
|
+
`,jF=r=>xl(["PreviewTable"],e=>gn(RF,e)(),r),BF=`
|
|
179
|
+
query QueryExternalMetric($id: String = "", $clientId: String = "", $globalFilters: json = "", $rlsConditions: json = [], $filterValues: json = "", $tenancyLevel: String = "") {
|
|
180
|
+
externalMetricQuery(
|
|
181
|
+
input: {externalMetricId: $id, clientId: $clientId, globalFilters: $globalFilters, rlsConditions: $rlsConditions, filterValues: $filterValues, tenancyLevel: $tenancyLevel}
|
|
182
|
+
) {
|
|
183
|
+
data
|
|
184
|
+
timeTaken
|
|
185
|
+
}
|
|
186
|
+
}
|
|
187
|
+
`,bS=(r,e)=>Fo(r===void 0?["QueryExternalMetric"]:["QueryExternalMetric",r],gn(BF,r),e),MS=({onSubmit:r,defaultValues:e,onCancel:t,isEmbedded:n=!0,dashboardIds:a,onDashboardChange:i,companyId:o,error:s})=>{var g,y,m;const{register:l,handleSubmit:u}=Vy(),[c,f]=R.useState((g=e==null?void 0:e.isLive)!=null?g:!1),h=u(_=>{r({..._,isLive:c})}),{data:v}=NF({companyId:o}),d=v==null?void 0:v.externalDashboards,p=n?(y=d==null?void 0:d.filter(_=>_.id===a[0]).map(_=>({value:_.id,label:_.name})))!=null?y:[]:(m=d==null?void 0:d.map(_=>({value:_.id,label:_.name})))!=null?m:[];return B("form",{className:oi.form,onSubmit:h,children:[B("div",{className:oi.container,children:[S("div",{className:oi.field,children:S(fc,{label:"Dashboards",options:p,name:"dashboards",value:a,onChange:i})}),S(Ct,{name:"name",type:"text",placeholder:"What is the name of metric?",label:"Metric Name",register:l("name",{required:!0}),defaultValue:e==null?void 0:e.name}),S(Ct,{name:"name",type:"text",placeholder:"Unique Id to identify metric",label:"Metric ID",register:l("metricId",{required:!0,disabled:!!(e!=null&&e.metricId)}),defaultValue:e==null?void 0:e.metricId}),S(_S,{className:oi.field,id:"desc",placeholder:"What is the name of metric?",label:"Description",rows:5,register:l("description"),defaultValue:e==null?void 0:e.description}),!n&&S(ym,{className:oi.field,labelClassName:oi.fieldLabel,enabled:c,onChange:f,label:"Publish Type",placeholder:c?"LIVE MODE":"TEST MODE",defaultEnabled:e==null?void 0:e.isLive})]}),!!s&&S(de,{variant:"p",styleClass:"font-14",className:oi.error,children:s}),B(Cl,{children:[S(Ce,{type:"reset",variant:"secondary",className:oi.cancel,onClick:t,size:"default",children:"Cancel"}),S(Ce,{type:"submit",variant:"primary",size:"small",className:oi.save,isDisabled:!p.length||!a.length,children:"Save"})]})]})};var Bt={container:"_container_q0qrl_1",wrapper:"_wrapper_q0qrl_5",label:"_label_q0qrl_9",floatingLabel:"_floatingLabel_q0qrl_13",clientText:"_clientText_q0qrl_17",normalText:"_normalText_q0qrl_21",dropdown:"_dropdown_q0qrl_25",options:"_options_q0qrl_29",checkedOption:"_checkedOption_q0qrl_33",option:"_option_q0qrl_29",icon:"_icon_q0qrl_41",text:"_text_q0qrl_45",floatingText:"_floatingText_q0qrl_49",search:"_search_q0qrl_53",loadMore:"_loadMore_q0qrl_57",loadMoreIcon:"_loadMoreIcon_q0qrl_61"};const xS=r=>{var b,x;const{data:e,isLoading:t}=EF({id:r},{enabled:!!r}),n=e==null?void 0:e.guestTokens_by_pk,a=n!=null&&n.params?JSON.parse(n.params):{},i=(b=a.dashboard)==null?void 0:b.id,o=n==null?void 0:n.companyId,s=n==null?void 0:n.clientId,l=(x=a==null?void 0:a.dashboard)==null?void 0:x.isLive,u=a==null?void 0:a.rlsSettings,c=a==null?void 0:a.companyTenancyType,f=a==null?void 0:a.isTestKey,{data:h,isLoading:v}=IF({where:{externalDashboard:{externalDashboardId:{_eq:i}}}},{enabled:!!i}),{data:d,isLoading:p}=AF({externalDashboardId:i}),g=h==null?void 0:h.externalDashboardMetrics,{data:y,isLoading:m}=PF({companyId:o}),_=y!=null&&y.companySubsetTables.length?y.companySubsetTables[0].isAllowMetricCreation&&!f:!1;return{isLoading:t||v||p||m,data:{clientId:s,companyId:o,mode:l,externalDashboardMetrics:g,externalDashboard:d==null?void 0:d.externalDashboards[0],rlsSettings:u,companyTenancyType:c||"TABLE",isAllowedToCreateMetrics:_}}},FF=({xAxis:r,yAxisList:e,chartType:t,step:n,measure:a,sankeyValues:i,singleValue:o,margins:s,legendSettings:l,labelSettings:u,axisSettings:c,customSettings:f,backGroundColor:h})=>t===At.funnel?{xAxis:"",yAxisList:[],chartType:t,step:n,measure:a,sankeyValues:[],singleValue:"",margins:s,legendSettings:l,labelSettings:u,axisSettings:c,customSettings:f}:t===At.gauge?{xAxis:"",yAxisList:[],chartType:t,step:"",measure:a,sankeyValues:[],singleValue:"",margins:s,legendSettings:l,labelSettings:u,axisSettings:c,customSettings:f}:t===At.singleValue?{xAxis:"",yAxisList:[],chartType:t,step:"",measure:"",sankeyValues:[],singleValue:o,margins:s,legendSettings:l,labelSettings:u,axisSettings:c,customSettings:f}:t===At.sankey?{xAxis:"",yAxisList:[],chartType:t,step:"",measure:"",sankeyValues:i,singleValue:"",margins:s,legendSettings:l,labelSettings:u,axisSettings:c,backGroundColor:h,customSettings:f}:{xAxis:r,yAxisList:e,chartType:t,step:"",measure:"",sankeyValues:[],singleValue:"",margins:s,legendSettings:l,labelSettings:u,axisSettings:c,backGroundColor:h,customSettings:f},wS=({companyIntegrationId:r,selectedColumns:e,query:t,metricQuery:n,integrationName:a,outputColumns:i,xAxis:o,yAxisList:s,chartType:l,step:u,measure:c,sankeyValues:f,singleValue:h,margins:v,legendSettings:d,labelSettings:p,axisSettings:g,customSettings:y,backGroundColor:m,clientId:_,companyId:b,mode:x,timeGrain:M,dashboardIds:w,isEnableGroupBy:D,groupBy:T,selectedGroupBy:I})=>{const[A,N]=R.useState(""),L=gF();return{createExternalMetric:O=>{N(""),L.mutate({companyId:b,companyIntegrationId:r,description:O.description,inputFields:e,metricId:O.metricId,name:O.name,query:t,metricQuery:n,integrationName:a,outputColumns:i,createdBy:"external user",isLive:x||O.isLive,chartOptions:FF({xAxis:o,yAxisList:s,chartType:l,step:u,measure:c,sankeyValues:f,singleValue:h,margins:v,legendSettings:d,labelSettings:p,axisSettings:g,customSettings:y,backGroundColor:m}),clientId:_||null,isCreatedByClient:!!_,timeGrain:M||null,externalDashboardIds:w.map(P=>({externalDashboardId:P})),isEnableGroupBy:D,groupBy:T!=null?T:{},selectedGroupBy:I},{onSuccess:P=>{var H;(H=P.insert_externalMetrics_one)!=null&&H.id&&window.location.reload()},onError:()=>{N&&N("Metric Id already exists")}})},error:A}},mv=()=>{const{mutate:r,isLoading:e,error:t}=bF(),{mutate:n}=mF();return{generateDatasetMetric:r,isGeneratingDataset:e,generateError:t,fetchColumnValues:n}},VF=({clientId:r,companyId:e,setData:t,setError:n,setLoading:a,setQuery:i,setMetricQuery:o})=>{const s=xF();return{generateEmbeddedMetric:u=>{a(!0),i(""),n(""),t(void 0),s.mutate({clientId:r,companyId:e,queryPrompt:u.queryPrompt,timeGrain:u.timeGrain},{onSuccess:c=>{var f,h,v;(f=c.generateEmbeddedMetic)!=null&&f.error?(a(!1),i(""),t(void 0),n(c.generateEmbeddedMetic.error.message)):(o(u.queryPrompt),n(""),a(!1),i(((h=c.generateEmbeddedMetic)==null?void 0:h.query)||""),t((v=c.generateEmbeddedMetic)==null?void 0:v.result))},onError:()=>{a(!1),i(""),t(void 0),n(am)}})}}},_v=({onOutsideClick:r,wrapRef:e})=>{R.useEffect(()=>{const t=n=>{e.current&&!e.current.contains(n.target)&&r()};return document.addEventListener("mousedown",t),()=>{document.removeEventListener("mousedown",t)}},[e,r])};var HF=Object.freeze(Object.defineProperty({__proto__:null,useEmbeddedDashboard:xS,useExternalMetric:wS,useGenerateDatasetMetrics:mv,useGenerateEmbeddedMetric:VF,useOutsideAlerter:_v},Symbol.toStringTag,{value:"Module"}));const bv=r=>S("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",...r,children:S("path",{fill:"currentColor",d:"m12 15.4l-6-6L7.4 8l4.6 4.6L16.6 8L18 9.4Z"})}),WF=r=>S("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",...r,children:S("path",{fill:"currentColor",d:"m10.6 16.2l7.05-7.05l-1.4-1.4l-5.65 5.65l-2.85-2.85l-1.4 1.4ZM5 21q-.825 0-1.413-.587Q3 19.825 3 19V5q0-.825.587-1.413Q4.175 3 5 3h14q.825 0 1.413.587Q21 4.175 21 5v14q0 .825-.587 1.413Q19.825 21 19 21Z"})}),mm=r=>S("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",...r,children:S("path",{fill:"currentColor",d:"M5 21q-.825 0-1.413-.587Q3 19.825 3 19V5q0-.825.587-1.413Q4.175 3 5 3h14q.825 0 1.413.587Q21 4.175 21 5v14q0 .825-.587 1.413Q19.825 21 19 21Zm0-2h14V5H5v14Z"})}),br=({label:r,labelVariant:e="floating",selectedOption:t,onChange:n,className:a,options:i,isDisabled:o,children:s,icon:l,isSearchEnabled:u,closeControl:c})=>{const[f,h]=R.useState(!1),v=R.useRef(null),[d,p]=R.useState(""),[g,y]=R.useState(20);return _v({wrapRef:v,onOutsideClick:()=>h(!1)}),R.useEffect(()=>{!(c!=null&&c.close)||h(!1)},[c==null?void 0:c.close]),B("div",{className:Na(Bt.container,a),ref:v,children:[r?S(de,{variant:"span",styleClass:e==="floating"?"custom":"font-14",className:`${Bt.label} ${e==="floating"?Bt.floatingLabel:""} ${r==="client"?Bt.clientText:Bt.normalText} `,children:r}):null,B(Ce,{type:"button",variant:"custom",isDisabled:o,className:Bt.wrapper,onClick:()=>h(!f),children:[B(de,{variant:"p",styleClass:"font-14",className:`${Bt.text} ${e==="floating"?Bt.floatingText:""}`,children:[l,t.label||"Select An Option"]}),S(bv,{})]}),f&&!o&&B("div",{className:Bt.dropdown,children:[u&&S(cc,{className:Bt.search,setSearchKeyword:p}),B("div",{className:Bt.options,children:[(d?i.filter(m=>m.label.toLowerCase().includes(d)):i.slice(0,g)).map(m=>{const _=m.value===t.value;return S(Ce,{type:"button",variant:"custom",className:_?Bt.checkedOption:Bt.option,onClick:()=>{n(m),h(!1)},children:m.label},m.key||m.value)}),g<=i.length&&B(Ce,{variant:"secondary",type:"button",onClick:()=>y(m=>m+20),className:Bt.loadMore,children:["Load More"," ",S(lt,{name:"double-arrow-left-icon",className:Bt.loadMoreIcon})]})]}),s]})]})},DS=pe.default.memo(({label:r,labelVariant:e="floating",selectedOptions:t,onChange:n,className:a,options:i,isDisabled:o,children:s,isSearchEnabled:l})=>{const[u,c]=R.useState(!1),f=R.useRef(null),[h,v]=R.useState(""),[d,p]=R.useState(20);return _v({wrapRef:f,onOutsideClick:()=>c(!1)}),B("div",{className:Na(Bt.container,a),ref:f,children:[r?S(de,{variant:"span",styleClass:e==="floating"?"custom":"font-14",className:`${Bt.label} ${e==="floating"?"absolute left-2 top-1 text-xs":""}`,children:r}):null,B(Ce,{type:"button",variant:"custom",isDisabled:o,className:Bt.wrapper,onClick:()=>c(!u),children:[S(de,{variant:"p",styleClass:"font-14",className:e==="floating"?"mt-2.5":"",children:"Select 1 or more option"}),S(bv,{})]}),u&&!o&&B("div",{className:Bt.dropdown,children:[l&&S(cc,{className:"p-2 mb-3",setSearchKeyword:v}),B("div",{className:Bt.options,children:[(h?i.filter(g=>g.label.toLowerCase().includes(h)):i.slice(0,d)).map(g=>{const y=!!t.find(m=>m.value===g.value);return B(Ce,{type:"button",variant:"custom",className:y?Bt.checkedOption:Bt.option,onClick:()=>{const m=y?t.filter(_=>_.value!==g.value):[...t,g];n(m)},children:[y?S(WF,{}):S(mm,{}),g.label]},g.key||g.value)}),d<=i.length&&S(Ce,{variant:"secondary",type:"button",onClick:()=>p(g=>g+20),className:"w-full text-blue-700 text-center",children:"Load More"})]}),s]})]})}),SS=({companyId:r,filter:e,onChange:t,selectedOption:n,autoSelected:a=!0,...i})=>{const[o,s]=R.useState([]),{fetchColumnValues:l}=mv();return R.useEffect(()=>{l({companyId:r,tableName:e.tableName,columnName:e.columnName},{onSuccess:u=>{var f;if(!((f=u.fetchColumnData)!=null&&f.data))return;const c=[];u.fetchColumnData.data.forEach(h=>{h&&c.push({label:h.label,value:h.value})}),s(c)}})},[e.tableName,e.columnName,r]),R.useEffect(()=>{o.length&&o[0]&&a&&t(o[0])},[o.length,o[0],a,e.columnName]),S(br,{onChange:t,selectedOption:e.defaultValue?{label:e.defaultValue,value:e.defaultValue}:n,isDisabled:!!e.defaultValue,options:o,label:e.columnName,...i})},IS=pe.default.memo(({filter:r,companyId:e,autoSelected:t,onChange:n,selectedOptions:a,...i})=>{const[o,s]=R.useState([]),{fetchColumnValues:l}=mv();return R.useEffect(()=>{l({companyId:e,tableName:r.tableName,columnName:r.columnName},{onSuccess:u=>{var f;if(!((f=u.fetchColumnData)!=null&&f.data))return;const c=[];u.fetchColumnData.data.forEach(h=>{h&&c.push({label:h.label,value:h.value})}),s(c)}})},[r.tableName,r.columnName,e]),R.useEffect(()=>{o.length&&o[0]&&t&&n([o[0]])},[o.length,o[0],t,r.columnName]),S(DS,{onChange:n,selectedOptions:r.defaultValue?[{label:r.defaultValue,value:r.defaultValue}]:a,isDisabled:!!r.defaultValue,options:o,label:r.columnName,...i})});var GF={fullscreen:"_fullscreen_1wo1t_1"},TS={csvlink:"_csvlink_azd6y_1",noChart:"_noChart_azd6y_7"};const AS=r=>{const e=document.documentElement;r.colors&&Object.entries(r.colors).forEach(([t,n])=>{e.style.setProperty(`--databrainhq-plugin-color-${t}`,`${n}`)}),r.border&&Object.entries(r.border).forEach(([t,n])=>{e.style.setProperty(`--databrainhq-plugin-border-${t}`,`${n}`)}),r.shadow&&Object.entries(r.shadow).forEach(([t,n])=>{e.style.setProperty(`--databrainhq-plugin-shadow-${t}`,`${n}`)}),r.typography&&Object.entries(r.typography).forEach(([t,n])=>{e.style.setProperty(`--databrainhq-plugin-typography-${t}`,`${n}`)}),r.breakpoint&&Object.entries(r.breakpoint).forEach(([t,n])=>{e.style.setProperty(`--databrainhq-plugin-breakpoint-${t}`,`${n}`)})},CS=["rgb(56, 72, 211)","rgb(251, 208, 98)","rgb(234 88 12)","rgb(245 158 11)","rgb(234 179 8)","rgb(34 197 94)","rgb(4 120 87)","rgb(15 118 110)","rgb(8 145 178)","rgb(219 234 254)","rgb(30 58 138)","rgb(139 92 246)"],_m=({data:r,measure:e,sankeyValues:t,singleValue:n,step:a,xAxis:i,yAxisList:o})=>{const s=Array.isArray(r)?r.map(h=>i&&h[i]):[],l=o==null?void 0:o.map((h,v)=>({label:h,data:Array.isArray(r)?r.map(d=>d[o[v]]):[],borderColor:CS[v]})),u=Array.isArray(r)?r.map(h=>e&&a&&{value:h[e],name:h[a]}):[],c=t==null?void 0:t.map((h,v)=>Array.isArray(r)?r.map(d=>d[t[v]]):[]),f=Array.isArray(r)?r.map(h=>n&&{value:h[n],label:n}):[];return{labels:s,datasets:l,funnelData:u,sankeyData:c,singleValueData:f}},NS=r=>cm.includes(r.toLowerCase())?"number":fm.includes(r.toLowerCase())||r.toLowerCase().includes("char")?"text":vm.includes(r.toLowerCase())?"boolean":"text",LS=r=>{const e="data:text/csv;charset=utf-8,";if(!r.length)return e;const t=[],n=r[0],a=Object.keys(n);t.push(`S.NO,${a.join(",").toUpperCase()}`),r.forEach((s,l)=>{const u=Object.values(s).map(c=>{if(typeof c=="number")return c;try{if(c!=null&&c.includes(","))return`"${c}"`}catch{return c}return c});t.push(`${l+1},${u.join(",")}`)});const i=t.join(`
|
|
188
|
+
`);return encodeURI(e+i)};var $F=Object.freeze(Object.defineProperty({__proto__:null,applyTheme:AS,getChartAttributes:_m,colors:CS,getFormattedDataType:NS,objectArrayToCsvString:LS},Symbol.toStringTag,{value:"Module"}));const ES=({data:r=[],fileName:e="export",className:t,iconClass:n,text:a=""})=>B("a",{href:LS(r),download:`${e}.csv`,className:t!=null?t:TS.csvlink,target:"_self",children:[S(lt,{name:"csv-icon",className:n}),a]});var bm=function(r,e){return bm=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,n){t.__proto__=n}||function(t,n){for(var a in n)Object.prototype.hasOwnProperty.call(n,a)&&(t[a]=n[a])},bm(r,e)};function OS(r,e){if(typeof e!="function"&&e!==null)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");bm(r,e);function t(){this.constructor=r}r.prototype=e===null?Object.create(e):(t.prototype=e.prototype,new t)}var Mm=function(){return Mm=Object.assign||function(e){for(var t,n=1,a=arguments.length;n<a;n++){t=arguments[n];for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i])}return e},Mm.apply(this,arguments)};/*! *****************************************************************************
|
|
189
|
+
Copyright (c) Microsoft Corporation.
|
|
190
|
+
|
|
191
|
+
Permission to use, copy, modify, and/or distribute this software for any
|
|
192
|
+
purpose with or without fee is hereby granted.
|
|
193
|
+
|
|
194
|
+
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
195
|
+
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|
196
|
+
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
197
|
+
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
198
|
+
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
199
|
+
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
200
|
+
PERFORMANCE OF THIS SOFTWARE.
|
|
201
|
+
***************************************************************************** */var xm=function(r,e){return xm=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,n){t.__proto__=n}||function(t,n){for(var a in n)Object.prototype.hasOwnProperty.call(n,a)&&(t[a]=n[a])},xm(r,e)};function U(r,e){if(typeof e!="function"&&e!==null)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");xm(r,e);function t(){this.constructor=r}r.prototype=e===null?Object.create(e):(t.prototype=e.prototype,new t)}var UF=function(){function r(){this.firefox=!1,this.ie=!1,this.edge=!1,this.newEdge=!1,this.weChat=!1}return r}(),YF=function(){function r(){this.browser=new UF,this.node=!1,this.wxa=!1,this.worker=!1,this.svgSupported=!1,this.touchEventsSupported=!1,this.pointerEventsSupported=!1,this.domSupported=!1,this.transformSupported=!1,this.transform3dSupported=!1,this.hasGlobalWindow=typeof window!="undefined"}return r}(),Uo=new YF;typeof wx=="object"&&typeof wx.getSystemInfoSync=="function"?(Uo.wxa=!0,Uo.touchEventsSupported=!0):typeof document=="undefined"&&typeof self!="undefined"?Uo.worker=!0:typeof navigator=="undefined"?(Uo.node=!0,Uo.svgSupported=!0):QF(navigator.userAgent,Uo);function QF(r,e){var t=e.browser,n=r.match(/Firefox\/([\d.]+)/),a=r.match(/MSIE\s([\d.]+)/)||r.match(/Trident\/.+?rv:(([\d.]+))/),i=r.match(/Edge?\/([\d.]+)/),o=/micromessenger/i.test(r);n&&(t.firefox=!0,t.version=n[1]),a&&(t.ie=!0,t.version=a[1]),i&&(t.edge=!0,t.version=i[1],t.newEdge=+i[1].split(".")[0]>18),o&&(t.weChat=!0),e.svgSupported=typeof SVGRect!="undefined",e.touchEventsSupported="ontouchstart"in window&&!t.ie&&!t.edge,e.pointerEventsSupported="onpointerdown"in window&&(t.edge||t.ie&&+t.version>=11),e.domSupported=typeof document!="undefined";var s=document.documentElement.style;e.transform3dSupported=(t.ie&&"transition"in s||t.edge||"WebKitCSSMatrix"in window&&"m11"in new WebKitCSSMatrix||"MozPerspective"in s)&&!("OTransition"in s),e.transformSupported=e.transform3dSupported||t.ie&&+t.version>=9}var $e=Uo,wm=12,PS="sans-serif",$i=wm+"px "+PS,ZF=20,qF=100,XF="007LLmW'55;N0500LLLLLLLLLL00NNNLzWW\\\\WQb\\0FWLg\\bWb\\WQ\\WrWWQ000CL5LLFLL0LL**F*gLLLL5F0LF\\FFF5.5N";function JF(r){var e={};if(typeof JSON=="undefined")return e;for(var t=0;t<r.length;t++){var n=String.fromCharCode(t+32),a=(r.charCodeAt(t)-ZF)/qF;e[n]=a}return e}var KF=JF(XF),la={createCanvas:function(){return typeof document!="undefined"&&document.createElement("canvas")},measureText:function(){var r,e;return function(t,n){if(!r){var a=la.createCanvas();r=a&&a.getContext("2d")}if(r)return e!==n&&(e=r.font=n||$i),r.measureText(t);t=t||"",n=n||$i;var i=/(\d+)px/.exec(n),o=i&&+i[1]||wm,s=0;if(n.indexOf("mono")>=0)s=o*t.length;else for(var l=0;l<t.length;l++){var u=KF[t[l]];s+=u==null?o:u*o}return{width:s}}}(),loadImage:function(r,e,t){var n=new Image;return n.onload=e,n.onerror=t,n.src=r,n}};function zS(r){for(var e in la)r[e]&&(la[e]=r[e])}var kS=On(["Function","RegExp","Date","Error","CanvasGradient","CanvasPattern","Image","Canvas"],function(r,e){return r["[object "+e+"]"]=!0,r},{}),RS=On(["Int8","Uint8","Uint8Clamped","Int16","Uint16","Int32","Uint32","Float32","Float64"],function(r,e){return r["[object "+e+"Array]"]=!0,r},{}),Nl=Object.prototype.toString,Mv=Array.prototype,eV=Mv.forEach,tV=Mv.filter,Dm=Mv.slice,rV=Mv.map,jS=function(){}.constructor,xv=jS?jS.prototype:null,Sm="__proto__",nV=2311;function Im(){return nV++}function wv(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];typeof console!="undefined"&&console.error.apply(console,r)}function Me(r){if(r==null||typeof r!="object")return r;var e=r,t=Nl.call(r);if(t==="[object Array]"){if(!Ol(r)){e=[];for(var n=0,a=r.length;n<a;n++)e[n]=Me(r[n])}}else if(RS[t]){if(!Ol(r)){var i=r.constructor;if(i.from)e=i.from(r);else{e=new i(r.length);for(var n=0,a=r.length;n<a;n++)e[n]=r[n]}}}else if(!kS[t]&&!Ol(r)&&!Ll(r)){e={};for(var o in r)r.hasOwnProperty(o)&&o!==Sm&&(e[o]=Me(r[o]))}return e}function Ne(r,e,t){if(!_e(e)||!_e(r))return t?Me(e):r;for(var n in e)if(e.hasOwnProperty(n)&&n!==Sm){var a=r[n],i=e[n];_e(i)&&_e(a)&&!J(i)&&!J(a)&&!Ll(i)&&!Ll(a)&&!Am(i)&&!Am(a)&&!Ol(i)&&!Ol(a)?Ne(a,i,t):(t||!(n in r))&&(r[n]=Me(e[n]))}return r}function Dv(r,e){for(var t=r[0],n=1,a=r.length;n<a;n++)t=Ne(t,r[n],e);return t}function X(r,e){if(Object.assign)Object.assign(r,e);else for(var t in e)e.hasOwnProperty(t)&&t!==Sm&&(r[t]=e[t]);return r}function me(r,e,t){for(var n=Fe(e),a=0;a<n.length;a++){var i=n[a];(t?e[i]!=null:r[i]==null)&&(r[i]=e[i])}return r}var aV=la.createCanvas;function ze(r,e){if(r){if(r.indexOf)return r.indexOf(e);for(var t=0,n=r.length;t<n;t++)if(r[t]===e)return t}return-1}function Tm(r,e){var t=r.prototype;function n(){}n.prototype=e.prototype,r.prototype=new n;for(var a in t)t.hasOwnProperty(a)&&(r.prototype[a]=t[a]);r.prototype.constructor=r,r.superClass=e}function Et(r,e,t){if(r="prototype"in r?r.prototype:r,e="prototype"in e?e.prototype:e,Object.getOwnPropertyNames)for(var n=Object.getOwnPropertyNames(e),a=0;a<n.length;a++){var i=n[a];i!=="constructor"&&(t?e[i]!=null:r[i]==null)&&(r[i]=e[i])}else me(r,e,t)}function Mr(r){return!r||typeof r=="string"?!1:typeof r.length=="number"}function C(r,e,t){if(!!(r&&e))if(r.forEach&&r.forEach===eV)r.forEach(e,t);else if(r.length===+r.length)for(var n=0,a=r.length;n<a;n++)e.call(t,r[n],n,r);else for(var i in r)r.hasOwnProperty(i)&&e.call(t,r[i],i,r)}function K(r,e,t){if(!r)return[];if(!e)return Iv(r);if(r.map&&r.map===rV)return r.map(e,t);for(var n=[],a=0,i=r.length;a<i;a++)n.push(e.call(t,r[a],a,r));return n}function On(r,e,t,n){if(!!(r&&e)){for(var a=0,i=r.length;a<i;a++)t=e.call(n,t,r[a],a,r);return t}}function ot(r,e,t){if(!r)return[];if(!e)return Iv(r);if(r.filter&&r.filter===tV)return r.filter(e,t);for(var n=[],a=0,i=r.length;a<i;a++)e.call(t,r[a],a,r)&&n.push(r[a]);return n}function BS(r,e,t){if(!!(r&&e)){for(var n=0,a=r.length;n<a;n++)if(e.call(t,r[n],n,r))return r[n]}}function Fe(r){if(!r)return[];if(Object.keys)return Object.keys(r);var e=[];for(var t in r)r.hasOwnProperty(t)&&e.push(t);return e}function iV(r,e){for(var t=[],n=2;n<arguments.length;n++)t[n-2]=arguments[n];return function(){return r.apply(e,t.concat(Dm.call(arguments)))}}var fe=xv&&ye(xv.bind)?xv.call.bind(xv.bind):iV;function Ae(r){for(var e=[],t=1;t<arguments.length;t++)e[t-1]=arguments[t];return function(){return r.apply(this,e.concat(Dm.call(arguments)))}}function J(r){return Array.isArray?Array.isArray(r):Nl.call(r)==="[object Array]"}function ye(r){return typeof r=="function"}function ce(r){return typeof r=="string"}function Sv(r){return Nl.call(r)==="[object String]"}function Ue(r){return typeof r=="number"}function _e(r){var e=typeof r;return e==="function"||!!r&&e==="object"}function Am(r){return!!kS[Nl.call(r)]}function an(r){return!!RS[Nl.call(r)]}function Ll(r){return typeof r=="object"&&typeof r.nodeType=="number"&&typeof r.ownerDocument=="object"}function dc(r){return r.colorStops!=null}function FS(r){return r.image!=null}function VS(r){return Nl.call(r)==="[object RegExp]"}function El(r){return r!==r}function ar(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];for(var t=0,n=r.length;t<n;t++)if(r[t]!=null)return r[t]}function Ee(r,e){return r!=null?r:e}function Ea(r,e,t){return r!=null?r:e!=null?e:t}function Iv(r){for(var e=[],t=1;t<arguments.length;t++)e[t-1]=arguments[t];return Dm.apply(r,e)}function Tv(r){if(typeof r=="number")return[r,r,r,r];var e=r.length;return e===2?[r[0],r[1],r[0],r[1]]:e===3?[r[0],r[1],r[2],r[1]]:r}function Er(r,e){if(!r)throw new Error(e)}function Pn(r){return r==null?null:typeof r.trim=="function"?r.trim():r.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")}var HS="__ec_primitive__";function pc(r){r[HS]=!0}function Ol(r){return r[HS]}var oV=function(){function r(){this.data={}}return r.prototype.delete=function(e){var t=this.has(e);return t&&delete this.data[e],t},r.prototype.has=function(e){return this.data.hasOwnProperty(e)},r.prototype.get=function(e){return this.data[e]},r.prototype.set=function(e,t){return this.data[e]=t,this},r.prototype.keys=function(){return Fe(this.data)},r.prototype.forEach=function(e){var t=this.data;for(var n in t)t.hasOwnProperty(n)&&e(t[n],n)},r}(),WS=typeof Map=="function";function sV(){return WS?new Map:new oV}var GS=function(){function r(e){var t=J(e);this.data=sV();var n=this;e instanceof r?e.each(a):e&&C(e,a);function a(i,o){t?n.set(i,o):n.set(o,i)}}return r.prototype.hasKey=function(e){return this.data.has(e)},r.prototype.get=function(e){return this.data.get(e)},r.prototype.set=function(e,t){return this.data.set(e,t),t},r.prototype.each=function(e,t){this.data.forEach(function(n,a){e.call(t,n,a)})},r.prototype.keys=function(){var e=this.data.keys();return WS?Array.from(e):e},r.prototype.removeKey=function(e){this.data.delete(e)},r}();function ge(r){return new GS(r)}function gc(r,e){for(var t=new r.constructor(r.length+e.length),n=0;n<r.length;n++)t[n]=r[n];for(var a=r.length,n=0;n<e.length;n++)t[n+a]=e[n];return t}function yc(r,e){var t;if(Object.create)t=Object.create(r);else{var n=function(){};n.prototype=r,t=new n}return e&&X(t,e),t}function Cm(r){var e=r.style;e.webkitUserSelect="none",e.userSelect="none",e.webkitTapHighlightColor="rgba(0,0,0,0)",e["-webkit-touch-callout"]="none"}function ve(r,e){return r.hasOwnProperty(e)}function Ot(){}var mc=180/Math.PI,lV=Object.freeze(Object.defineProperty({__proto__:null,guid:Im,logError:wv,clone:Me,merge:Ne,mergeAll:Dv,extend:X,defaults:me,createCanvas:aV,indexOf:ze,inherits:Tm,mixin:Et,isArrayLike:Mr,each:C,map:K,reduce:On,filter:ot,find:BS,keys:Fe,bind:fe,curry:Ae,isArray:J,isFunction:ye,isString:ce,isStringSafe:Sv,isNumber:Ue,isObject:_e,isBuiltInObject:Am,isTypedArray:an,isDom:Ll,isGradientObject:dc,isImagePatternObject:FS,isRegExp:VS,eqNaN:El,retrieve:ar,retrieve2:Ee,retrieve3:Ea,slice:Iv,normalizeCssArray:Tv,assert:Er,trim:Pn,setAsPrimitive:pc,isPrimitive:Ol,HashMap:GS,createHashMap:ge,concatArray:gc,createObject:yc,disableUserSelect:Cm,hasOwn:ve,noop:Ot,RADIAN_TO_DEGREE:mc},Symbol.toStringTag,{value:"Module"}));/*! *****************************************************************************
|
|
202
|
+
Copyright (c) Microsoft Corporation.
|
|
203
|
+
|
|
204
|
+
Permission to use, copy, modify, and/or distribute this software for any
|
|
205
|
+
purpose with or without fee is hereby granted.
|
|
206
|
+
|
|
207
|
+
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
208
|
+
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|
209
|
+
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
210
|
+
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
211
|
+
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
212
|
+
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
213
|
+
PERFORMANCE OF THIS SOFTWARE.
|
|
214
|
+
***************************************************************************** */var Nm=function(r,e){return Nm=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,n){t.__proto__=n}||function(t,n){for(var a in n)Object.prototype.hasOwnProperty.call(n,a)&&(t[a]=n[a])},Nm(r,e)};function xt(r,e){if(typeof e!="function"&&e!==null)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");Nm(r,e);function t(){this.constructor=r}r.prototype=e===null?Object.create(e):(t.prototype=e.prototype,new t)}function Ui(r,e){return r==null&&(r=0),e==null&&(e=0),[r,e]}function Or(r,e){return r[0]=e[0],r[1]=e[1],r}function Oa(r){return[r[0],r[1]]}function $S(r,e,t){return r[0]=e,r[1]=t,r}function Lm(r,e,t){return r[0]=e[0]+t[0],r[1]=e[1]+t[1],r}function Av(r,e,t,n){return r[0]=e[0]+t[0]*n,r[1]=e[1]+t[1]*n,r}function Yi(r,e,t){return r[0]=e[0]-t[0],r[1]=e[1]-t[1],r}function _c(r){return Math.sqrt(Em(r))}var uV=_c;function Em(r){return r[0]*r[0]+r[1]*r[1]}var cV=Em;function fV(r,e,t){return r[0]=e[0]*t[0],r[1]=e[1]*t[1],r}function hV(r,e,t){return r[0]=e[0]/t[0],r[1]=e[1]/t[1],r}function vV(r,e){return r[0]*e[0]+r[1]*e[1]}function bc(r,e,t){return r[0]=e[0]*t,r[1]=e[1]*t,r}function Yo(r,e){var t=_c(e);return t===0?(r[0]=0,r[1]=0):(r[0]=e[0]/t,r[1]=e[1]/t),r}function Cv(r,e){return Math.sqrt((r[0]-e[0])*(r[0]-e[0])+(r[1]-e[1])*(r[1]-e[1]))}var ui=Cv;function US(r,e){return(r[0]-e[0])*(r[0]-e[0])+(r[1]-e[1])*(r[1]-e[1])}var Qi=US;function dV(r,e){return r[0]=-e[0],r[1]=-e[1],r}function Mc(r,e,t,n){return r[0]=e[0]+n*(t[0]-e[0]),r[1]=e[1]+n*(t[1]-e[1]),r}function vr(r,e,t){var n=e[0],a=e[1];return r[0]=t[0]*n+t[2]*a+t[4],r[1]=t[1]*n+t[3]*a+t[5],r}function ci(r,e,t){return r[0]=Math.min(e[0],t[0]),r[1]=Math.min(e[1],t[1]),r}function fi(r,e,t){return r[0]=Math.max(e[0],t[0]),r[1]=Math.max(e[1],t[1]),r}var pV=Object.freeze(Object.defineProperty({__proto__:null,create:Ui,copy:Or,clone:Oa,set:$S,add:Lm,scaleAndAdd:Av,sub:Yi,len:_c,length:uV,lenSquare:Em,lengthSquare:cV,mul:fV,div:hV,dot:vV,scale:bc,normalize:Yo,distance:Cv,dist:ui,distanceSquare:US,distSquare:Qi,negate:dV,lerp:Mc,applyTransform:vr,min:ci,max:fi},Symbol.toStringTag,{value:"Module"})),Pl=function(){function r(e,t){this.target=e,this.topTarget=t&&t.topTarget}return r}(),gV=function(){function r(e){this.handler=e,e.on("mousedown",this._dragStart,this),e.on("mousemove",this._drag,this),e.on("mouseup",this._dragEnd,this)}return r.prototype._dragStart=function(e){for(var t=e.target;t&&!t.draggable;)t=t.parent||t.__hostTarget;t&&(this._draggingTarget=t,t.dragging=!0,this._x=e.offsetX,this._y=e.offsetY,this.handler.dispatchToElement(new Pl(t,e),"dragstart",e.event))},r.prototype._drag=function(e){var t=this._draggingTarget;if(t){var n=e.offsetX,a=e.offsetY,i=n-this._x,o=a-this._y;this._x=n,this._y=a,t.drift(i,o,e),this.handler.dispatchToElement(new Pl(t,e),"drag",e.event);var s=this.handler.findHover(n,a,t).target,l=this._dropTarget;this._dropTarget=s,t!==s&&(l&&s!==l&&this.handler.dispatchToElement(new Pl(l,e),"dragleave",e.event),s&&s!==l&&this.handler.dispatchToElement(new Pl(s,e),"dragenter",e.event))}},r.prototype._dragEnd=function(e){var t=this._draggingTarget;t&&(t.dragging=!1),this.handler.dispatchToElement(new Pl(t,e),"dragend",e.event),this._dropTarget&&this.handler.dispatchToElement(new Pl(this._dropTarget,e),"drop",e.event),this._draggingTarget=null,this._dropTarget=null},r}(),yV=gV,mV=function(){function r(e){e&&(this._$eventProcessor=e)}return r.prototype.on=function(e,t,n,a){this._$handlers||(this._$handlers={});var i=this._$handlers;if(typeof t=="function"&&(a=n,n=t,t=null),!n||!e)return this;var o=this._$eventProcessor;t!=null&&o&&o.normalizeQuery&&(t=o.normalizeQuery(t)),i[e]||(i[e]=[]);for(var s=0;s<i[e].length;s++)if(i[e][s].h===n)return this;var l={h:n,query:t,ctx:a||this,callAtLast:n.zrEventfulCallAtLast},u=i[e].length-1,c=i[e][u];return c&&c.callAtLast?i[e].splice(u,0,l):i[e].push(l),this},r.prototype.isSilent=function(e){var t=this._$handlers;return!t||!t[e]||!t[e].length},r.prototype.off=function(e,t){var n=this._$handlers;if(!n)return this;if(!e)return this._$handlers={},this;if(t){if(n[e]){for(var a=[],i=0,o=n[e].length;i<o;i++)n[e][i].h!==t&&a.push(n[e][i]);n[e]=a}n[e]&&n[e].length===0&&delete n[e]}else delete n[e];return this},r.prototype.trigger=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];if(!this._$handlers)return this;var a=this._$handlers[e],i=this._$eventProcessor;if(a)for(var o=t.length,s=a.length,l=0;l<s;l++){var u=a[l];if(!(i&&i.filter&&u.query!=null&&!i.filter(e,u.query)))switch(o){case 0:u.h.call(u.ctx);break;case 1:u.h.call(u.ctx,t[0]);break;case 2:u.h.call(u.ctx,t[0],t[1]);break;default:u.h.apply(u.ctx,t);break}}return i&&i.afterTrigger&&i.afterTrigger(e),this},r.prototype.triggerWithContext=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];if(!this._$handlers)return this;var a=this._$handlers[e],i=this._$eventProcessor;if(a)for(var o=t.length,s=t[o-1],l=a.length,u=0;u<l;u++){var c=a[u];if(!(i&&i.filter&&c.query!=null&&!i.filter(e,c.query)))switch(o){case 0:c.h.call(s);break;case 1:c.h.call(s,t[0]);break;case 2:c.h.call(s,t[0],t[1]);break;default:c.h.apply(s,t.slice(1,o-1));break}}return i&&i.afterTrigger&&i.afterTrigger(e),this},r}(),zn=mV,_V=Math.log(2);function Om(r,e,t,n,a,i){var o=n+"-"+a,s=r.length;if(i.hasOwnProperty(o))return i[o];if(e===1){var l=Math.round(Math.log((1<<s)-1&~a)/_V);return r[t][l]}for(var u=n|1<<t,c=t+1;n&1<<c;)c++;for(var f=0,h=0,v=0;h<s;h++){var d=1<<h;d&a||(f+=(v%2?-1:1)*r[t][h]*Om(r,e-1,c,u,a|d,i),v++)}return i[o]=f,f}function YS(r,e){var t=[[r[0],r[1],1,0,0,0,-e[0]*r[0],-e[0]*r[1]],[0,0,0,r[0],r[1],1,-e[1]*r[0],-e[1]*r[1]],[r[2],r[3],1,0,0,0,-e[2]*r[2],-e[2]*r[3]],[0,0,0,r[2],r[3],1,-e[3]*r[2],-e[3]*r[3]],[r[4],r[5],1,0,0,0,-e[4]*r[4],-e[4]*r[5]],[0,0,0,r[4],r[5],1,-e[5]*r[4],-e[5]*r[5]],[r[6],r[7],1,0,0,0,-e[6]*r[6],-e[6]*r[7]],[0,0,0,r[6],r[7],1,-e[7]*r[6],-e[7]*r[7]]],n={},a=Om(t,8,0,0,0,n);if(a!==0){for(var i=[],o=0;o<8;o++)for(var s=0;s<8;s++)i[s]==null&&(i[s]=0),i[s]+=((o+s)%2?-1:1)*Om(t,7,o===0?1:0,1<<o,1<<s,n)/a*e[o];return function(l,u,c){var f=u*i[6]+c*i[7]+1;l[0]=(u*i[0]+c*i[1]+i[2])/f,l[1]=(u*i[3]+c*i[4]+i[5])/f}}}var QS="___zrEVENTSAVED",Pm=[];function bV(r,e,t,n,a){return zm(Pm,e,n,a,!0)&&zm(r,t,Pm[0],Pm[1])}function zm(r,e,t,n,a){if(e.getBoundingClientRect&&$e.domSupported&&!ZS(e)){var i=e[QS]||(e[QS]={}),o=MV(e,i),s=xV(o,i,a);if(s)return s(r,t,n),!0}return!1}function MV(r,e){var t=e.markers;if(t)return t;t=e.markers=[];for(var n=["left","right"],a=["top","bottom"],i=0;i<4;i++){var o=document.createElement("div"),s=o.style,l=i%2,u=(i>>1)%2;s.cssText=["position: absolute","visibility: hidden","padding: 0","margin: 0","border-width: 0","user-select: none","width:0","height:0",n[l]+":0",a[u]+":0",n[1-l]+":auto",a[1-u]+":auto",""].join("!important;"),r.appendChild(o),t.push(o)}return t}function xV(r,e,t){for(var n=t?"invTrans":"trans",a=e[n],i=e.srcCoords,o=[],s=[],l=!0,u=0;u<4;u++){var c=r[u].getBoundingClientRect(),f=2*u,h=c.left,v=c.top;o.push(h,v),l=l&&i&&h===i[f]&&v===i[f+1],s.push(r[u].offsetLeft,r[u].offsetTop)}return l&&a?a:(e.srcCoords=o,e[n]=t?YS(s,o):YS(o,s))}function ZS(r){return r.nodeName.toUpperCase()==="CANVAS"}var wV=/([&<>"'])/g,DV={"&":"&","<":"<",">":">",'"':""","'":"'"};function $r(r){return r==null?"":(r+"").replace(wV,function(e,t){return DV[t]})}var SV=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,km=[],IV=$e.browser.firefox&&+$e.browser.version.split(".")[0]<39;function Rm(r,e,t,n){return t=t||{},n?qS(r,e,t):IV&&e.layerX!=null&&e.layerX!==e.offsetX?(t.zrX=e.layerX,t.zrY=e.layerY):e.offsetX!=null?(t.zrX=e.offsetX,t.zrY=e.offsetY):qS(r,e,t),t}function qS(r,e,t){if($e.domSupported&&r.getBoundingClientRect){var n=e.clientX,a=e.clientY;if(ZS(r)){var i=r.getBoundingClientRect();t.zrX=n-i.left,t.zrY=a-i.top;return}else if(zm(km,r,n,a)){t.zrX=km[0],t.zrY=km[1];return}}t.zrX=t.zrY=0}function jm(r){return r||window.event}function kn(r,e,t){if(e=jm(e),e.zrX!=null)return e;var n=e.type,a=n&&n.indexOf("touch")>=0;if(a){var o=n!=="touchend"?e.targetTouches[0]:e.changedTouches[0];o&&Rm(r,o,e,t)}else{Rm(r,e,e,t);var i=TV(e);e.zrDelta=i?i/120:-(e.detail||0)/3}var s=e.button;return e.which==null&&s!==void 0&&SV.test(e.type)&&(e.which=s&1?1:s&2?3:s&4?2:0),e}function TV(r){var e=r.wheelDelta;if(e)return e;var t=r.deltaX,n=r.deltaY;if(t==null||n==null)return e;var a=Math.abs(n!==0?n:t),i=n>0?-1:n<0?1:t>0?-1:1;return 3*a*i}function Bm(r,e,t,n){r.addEventListener(e,t,n)}function AV(r,e,t,n){r.removeEventListener(e,t,n)}var hi=function(r){r.preventDefault(),r.stopPropagation(),r.cancelBubble=!0};function XS(r){return r.which===2||r.which===3}var CV=function(){function r(){this._track=[]}return r.prototype.recognize=function(e,t,n){return this._doTrack(e,t,n),this._recognize(e)},r.prototype.clear=function(){return this._track.length=0,this},r.prototype._doTrack=function(e,t,n){var a=e.touches;if(!!a){for(var i={points:[],touches:[],target:t,event:e},o=0,s=a.length;o<s;o++){var l=a[o],u=Rm(n,l,{});i.points.push([u.zrX,u.zrY]),i.touches.push(l)}this._track.push(i)}},r.prototype._recognize=function(e){for(var t in Fm)if(Fm.hasOwnProperty(t)){var n=Fm[t](this._track,e);if(n)return n}},r}();function JS(r){var e=r[1][0]-r[0][0],t=r[1][1]-r[0][1];return Math.sqrt(e*e+t*t)}function NV(r){return[(r[0][0]+r[1][0])/2,(r[0][1]+r[1][1])/2]}var Fm={pinch:function(r,e){var t=r.length;if(!!t){var n=(r[t-1]||{}).points,a=(r[t-2]||{}).points||n;if(a&&a.length>1&&n&&n.length>1){var i=JS(n)/JS(a);!isFinite(i)&&(i=1),e.pinchScale=i;var o=NV(n);return e.pinchX=o[0],e.pinchY=o[1],{type:"pinch",target:r[0].target,event:e}}}}};function yn(){return[1,0,0,1,0,0]}function xc(r){return r[0]=1,r[1]=0,r[2]=0,r[3]=1,r[4]=0,r[5]=0,r}function Nv(r,e){return r[0]=e[0],r[1]=e[1],r[2]=e[2],r[3]=e[3],r[4]=e[4],r[5]=e[5],r}function Pa(r,e,t){var n=e[0]*t[0]+e[2]*t[1],a=e[1]*t[0]+e[3]*t[1],i=e[0]*t[2]+e[2]*t[3],o=e[1]*t[2]+e[3]*t[3],s=e[0]*t[4]+e[2]*t[5]+e[4],l=e[1]*t[4]+e[3]*t[5]+e[5];return r[0]=n,r[1]=a,r[2]=i,r[3]=o,r[4]=s,r[5]=l,r}function ua(r,e,t){return r[0]=e[0],r[1]=e[1],r[2]=e[2],r[3]=e[3],r[4]=e[4]+t[0],r[5]=e[5]+t[1],r}function Zi(r,e,t){var n=e[0],a=e[2],i=e[4],o=e[1],s=e[3],l=e[5],u=Math.sin(t),c=Math.cos(t);return r[0]=n*c+o*u,r[1]=-n*u+o*c,r[2]=a*c+s*u,r[3]=-a*u+c*s,r[4]=c*i+u*l,r[5]=c*l-u*i,r}function Lv(r,e,t){var n=t[0],a=t[1];return r[0]=e[0]*n,r[1]=e[1]*a,r[2]=e[2]*n,r[3]=e[3]*a,r[4]=e[4]*n,r[5]=e[5]*a,r}function Qo(r,e){var t=e[0],n=e[2],a=e[4],i=e[1],o=e[3],s=e[5],l=t*o-i*n;return l?(l=1/l,r[0]=o*l,r[1]=-i*l,r[2]=-n*l,r[3]=t*l,r[4]=(n*s-o*a)*l,r[5]=(i*a-t*s)*l,r):null}function KS(r){var e=yn();return Nv(e,r),e}var LV=Object.freeze(Object.defineProperty({__proto__:null,create:yn,identity:xc,copy:Nv,mul:Pa,translate:ua,rotate:Zi,scale:Lv,invert:Qo,clone:KS},Symbol.toStringTag,{value:"Module"})),EV=function(){function r(e,t){this.x=e||0,this.y=t||0}return r.prototype.copy=function(e){return this.x=e.x,this.y=e.y,this},r.prototype.clone=function(){return new r(this.x,this.y)},r.prototype.set=function(e,t){return this.x=e,this.y=t,this},r.prototype.equal=function(e){return e.x===this.x&&e.y===this.y},r.prototype.add=function(e){return this.x+=e.x,this.y+=e.y,this},r.prototype.scale=function(e){this.x*=e,this.y*=e},r.prototype.scaleAndAdd=function(e,t){this.x+=e.x*t,this.y+=e.y*t},r.prototype.sub=function(e){return this.x-=e.x,this.y-=e.y,this},r.prototype.dot=function(e){return this.x*e.x+this.y*e.y},r.prototype.len=function(){return Math.sqrt(this.x*this.x+this.y*this.y)},r.prototype.lenSquare=function(){return this.x*this.x+this.y*this.y},r.prototype.normalize=function(){var e=this.len();return this.x/=e,this.y/=e,this},r.prototype.distance=function(e){var t=this.x-e.x,n=this.y-e.y;return Math.sqrt(t*t+n*n)},r.prototype.distanceSquare=function(e){var t=this.x-e.x,n=this.y-e.y;return t*t+n*n},r.prototype.negate=function(){return this.x=-this.x,this.y=-this.y,this},r.prototype.transform=function(e){if(!!e){var t=this.x,n=this.y;return this.x=e[0]*t+e[2]*n+e[4],this.y=e[1]*t+e[3]*n+e[5],this}},r.prototype.toArray=function(e){return e[0]=this.x,e[1]=this.y,e},r.prototype.fromArray=function(e){this.x=e[0],this.y=e[1]},r.set=function(e,t,n){e.x=t,e.y=n},r.copy=function(e,t){e.x=t.x,e.y=t.y},r.len=function(e){return Math.sqrt(e.x*e.x+e.y*e.y)},r.lenSquare=function(e){return e.x*e.x+e.y*e.y},r.dot=function(e,t){return e.x*t.x+e.y*t.y},r.add=function(e,t,n){e.x=t.x+n.x,e.y=t.y+n.y},r.sub=function(e,t,n){e.x=t.x-n.x,e.y=t.y-n.y},r.scale=function(e,t,n){e.x=t.x*n,e.y=t.y*n},r.scaleAndAdd=function(e,t,n,a){e.x=t.x+n.x*a,e.y=t.y+n.y*a},r.lerp=function(e,t,n,a){var i=1-a;e.x=i*t.x+a*n.x,e.y=i*t.y+a*n.y},r}(),Oe=EV,Ev=Math.min,Ov=Math.max,Zo=new Oe,qo=new Oe,Xo=new Oe,Jo=new Oe,wc=new Oe,Dc=new Oe,OV=function(){function r(e,t,n,a){n<0&&(e=e+n,n=-n),a<0&&(t=t+a,a=-a),this.x=e,this.y=t,this.width=n,this.height=a}return r.prototype.union=function(e){var t=Ev(e.x,this.x),n=Ev(e.y,this.y);isFinite(this.x)&&isFinite(this.width)?this.width=Ov(e.x+e.width,this.x+this.width)-t:this.width=e.width,isFinite(this.y)&&isFinite(this.height)?this.height=Ov(e.y+e.height,this.y+this.height)-n:this.height=e.height,this.x=t,this.y=n},r.prototype.applyTransform=function(e){r.applyTransform(this,this,e)},r.prototype.calculateTransform=function(e){var t=this,n=e.width/t.width,a=e.height/t.height,i=yn();return ua(i,i,[-t.x,-t.y]),Lv(i,i,[n,a]),ua(i,i,[e.x,e.y]),i},r.prototype.intersect=function(e,t){if(!e)return!1;e instanceof r||(e=r.create(e));var n=this,a=n.x,i=n.x+n.width,o=n.y,s=n.y+n.height,l=e.x,u=e.x+e.width,c=e.y,f=e.y+e.height,h=!(i<l||u<a||s<c||f<o);if(t){var v=1/0,d=0,p=Math.abs(i-l),g=Math.abs(u-a),y=Math.abs(s-c),m=Math.abs(f-o),_=Math.min(p,g),b=Math.min(y,m);i<l||u<a?_>d&&(d=_,p<g?Oe.set(Dc,-p,0):Oe.set(Dc,g,0)):_<v&&(v=_,p<g?Oe.set(wc,p,0):Oe.set(wc,-g,0)),s<c||f<o?b>d&&(d=b,y<m?Oe.set(Dc,0,-y):Oe.set(Dc,0,m)):_<v&&(v=_,y<m?Oe.set(wc,0,y):Oe.set(wc,0,-m))}return t&&Oe.copy(t,h?wc:Dc),h},r.prototype.contain=function(e,t){var n=this;return e>=n.x&&e<=n.x+n.width&&t>=n.y&&t<=n.y+n.height},r.prototype.clone=function(){return new r(this.x,this.y,this.width,this.height)},r.prototype.copy=function(e){r.copy(this,e)},r.prototype.plain=function(){return{x:this.x,y:this.y,width:this.width,height:this.height}},r.prototype.isFinite=function(){return isFinite(this.x)&&isFinite(this.y)&&isFinite(this.width)&&isFinite(this.height)},r.prototype.isZero=function(){return this.width===0||this.height===0},r.create=function(e){return new r(e.x,e.y,e.width,e.height)},r.copy=function(e,t){e.x=t.x,e.y=t.y,e.width=t.width,e.height=t.height},r.applyTransform=function(e,t,n){if(!n){e!==t&&r.copy(e,t);return}if(n[1]<1e-5&&n[1]>-1e-5&&n[2]<1e-5&&n[2]>-1e-5){var a=n[0],i=n[3],o=n[4],s=n[5];e.x=t.x*a+o,e.y=t.y*i+s,e.width=t.width*a,e.height=t.height*i,e.width<0&&(e.x+=e.width,e.width=-e.width),e.height<0&&(e.y+=e.height,e.height=-e.height);return}Zo.x=Xo.x=t.x,Zo.y=Jo.y=t.y,qo.x=Jo.x=t.x+t.width,qo.y=Xo.y=t.y+t.height,Zo.transform(n),Jo.transform(n),qo.transform(n),Xo.transform(n),e.x=Ev(Zo.x,qo.x,Xo.x,Jo.x),e.y=Ev(Zo.y,qo.y,Xo.y,Jo.y);var l=Ov(Zo.x,qo.x,Xo.x,Jo.x),u=Ov(Zo.y,qo.y,Xo.y,Jo.y);e.width=l-e.x,e.height=u-e.y},r}(),Pe=OV,eI="silent";function PV(r,e,t){return{type:r,event:t,target:e.target,topTarget:e.topTarget,cancelBubble:!1,offsetX:t.zrX,offsetY:t.zrY,gestureEvent:t.gestureEvent,pinchX:t.pinchX,pinchY:t.pinchY,pinchScale:t.pinchScale,wheelDelta:t.zrDelta,zrByTouch:t.zrByTouch,which:t.which,stop:zV}}function zV(){hi(this.event)}var kV=function(r){xt(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.handler=null,t}return e.prototype.dispose=function(){},e.prototype.setCursor=function(){},e}(zn),Sc=function(){function r(e,t){this.x=e,this.y=t}return r}(),RV=["click","dblclick","mousewheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],Vm=new Pe(0,0,0,0),tI=function(r){xt(e,r);function e(t,n,a,i,o){var s=r.call(this)||this;return s._hovered=new Sc(0,0),s.storage=t,s.painter=n,s.painterRoot=i,s._pointerSize=o,a=a||new kV,s.proxy=null,s.setHandlerProxy(a),s._draggingMgr=new yV(s),s}return e.prototype.setHandlerProxy=function(t){this.proxy&&this.proxy.dispose(),t&&(C(RV,function(n){t.on&&t.on(n,this[n],this)},this),t.handler=this),this.proxy=t},e.prototype.mousemove=function(t){var n=t.zrX,a=t.zrY,i=nI(this,n,a),o=this._hovered,s=o.target;s&&!s.__zr&&(o=this.findHover(o.x,o.y),s=o.target);var l=this._hovered=i?new Sc(n,a):this.findHover(n,a),u=l.target,c=this.proxy;c.setCursor&&c.setCursor(u?u.cursor:"default"),s&&u!==s&&this.dispatchToElement(o,"mouseout",t),this.dispatchToElement(l,"mousemove",t),u&&u!==s&&this.dispatchToElement(l,"mouseover",t)},e.prototype.mouseout=function(t){var n=t.zrEventControl;n!=="only_globalout"&&this.dispatchToElement(this._hovered,"mouseout",t),n!=="no_globalout"&&this.trigger("globalout",{type:"globalout",event:t})},e.prototype.resize=function(){this._hovered=new Sc(0,0)},e.prototype.dispatch=function(t,n){var a=this[t];a&&a.call(this,n)},e.prototype.dispose=function(){this.proxy.dispose(),this.storage=null,this.proxy=null,this.painter=null},e.prototype.setCursorStyle=function(t){var n=this.proxy;n.setCursor&&n.setCursor(t)},e.prototype.dispatchToElement=function(t,n,a){t=t||{};var i=t.target;if(!(i&&i.silent)){for(var o="on"+n,s=PV(n,t,a);i&&(i[o]&&(s.cancelBubble=!!i[o].call(i,s)),i.trigger(n,s),i=i.__hostTarget?i.__hostTarget:i.parent,!s.cancelBubble););s.cancelBubble||(this.trigger(n,s),this.painter&&this.painter.eachOtherLayer&&this.painter.eachOtherLayer(function(l){typeof l[o]=="function"&&l[o].call(l,s),l.trigger&&l.trigger(n,s)}))}},e.prototype.findHover=function(t,n,a){var i=this.storage.getDisplayList(),o=new Sc(t,n);if(rI(i,o,t,n,a),this._pointerSize&&!o.target){for(var s=[],l=this._pointerSize,u=l/2,c=new Pe(t-u,n-u,l,l),f=i.length-1;f>=0;f--){var h=i[f];h!==a&&!h.ignore&&!h.ignoreCoarsePointer&&(!h.parent||!h.parent.ignoreCoarsePointer)&&(Vm.copy(h.getBoundingRect()),h.transform&&Vm.applyTransform(h.transform),Vm.intersect(c)&&s.push(h))}if(s.length)for(var v=4,d=Math.PI/12,p=Math.PI*2,g=0;g<u;g+=v)for(var y=0;y<p;y+=d){var m=t+g*Math.cos(y),_=n+g*Math.sin(y);if(rI(s,o,m,_,a),o.target)return o}}return o},e.prototype.processGesture=function(t,n){this._gestureMgr||(this._gestureMgr=new CV);var a=this._gestureMgr;n==="start"&&a.clear();var i=a.recognize(t,this.findHover(t.zrX,t.zrY,null).target,this.proxy.dom);if(n==="end"&&a.clear(),i){var o=i.type;t.gestureEvent=o;var s=new Sc;s.target=i.target,this.dispatchToElement(s,o,i.event)}},e}(zn);C(["click","mousedown","mouseup","mousewheel","dblclick","contextmenu"],function(r){tI.prototype[r]=function(e){var t=e.zrX,n=e.zrY,a=nI(this,t,n),i,o;if((r!=="mouseup"||!a)&&(i=this.findHover(t,n),o=i.target),r==="mousedown")this._downEl=o,this._downPoint=[e.zrX,e.zrY],this._upEl=o;else if(r==="mouseup")this._upEl=o;else if(r==="click"){if(this._downEl!==this._upEl||!this._downPoint||ui(this._downPoint,[e.zrX,e.zrY])>4)return;this._downPoint=null}this.dispatchToElement(i,r,e)}});function jV(r,e,t){if(r[r.rectHover?"rectContain":"contain"](e,t)){for(var n=r,a=void 0,i=!1;n;){if(n.ignoreClip&&(i=!0),!i){var o=n.getClipPath();if(o&&!o.contain(e,t))return!1;n.silent&&(a=!0)}var s=n.__hostTarget;n=s||n.parent}return a?eI:!0}return!1}function rI(r,e,t,n,a){for(var i=r.length-1;i>=0;i--){var o=r[i],s=void 0;if(o!==a&&!o.ignore&&(s=jV(o,t,n))&&(!e.topTarget&&(e.topTarget=o),s!==eI)){e.target=o;break}}}function nI(r,e,t){var n=r.painter;return e<0||e>n.getWidth()||t<0||t>n.getHeight()}var BV=tI,aI=32,Ic=7;function FV(r){for(var e=0;r>=aI;)e|=r&1,r>>=1;return r+e}function iI(r,e,t,n){var a=e+1;if(a===t)return 1;if(n(r[a++],r[e])<0){for(;a<t&&n(r[a],r[a-1])<0;)a++;VV(r,e,a)}else for(;a<t&&n(r[a],r[a-1])>=0;)a++;return a-e}function VV(r,e,t){for(t--;e<t;){var n=r[e];r[e++]=r[t],r[t--]=n}}function oI(r,e,t,n,a){for(n===e&&n++;n<t;n++){for(var i=r[n],o=e,s=n,l;o<s;)l=o+s>>>1,a(i,r[l])<0?s=l:o=l+1;var u=n-o;switch(u){case 3:r[o+3]=r[o+2];case 2:r[o+2]=r[o+1];case 1:r[o+1]=r[o];break;default:for(;u>0;)r[o+u]=r[o+u-1],u--}r[o]=i}}function Hm(r,e,t,n,a,i){var o=0,s=0,l=1;if(i(r,e[t+a])>0){for(s=n-a;l<s&&i(r,e[t+a+l])>0;)o=l,l=(l<<1)+1,l<=0&&(l=s);l>s&&(l=s),o+=a,l+=a}else{for(s=a+1;l<s&&i(r,e[t+a-l])<=0;)o=l,l=(l<<1)+1,l<=0&&(l=s);l>s&&(l=s);var u=o;o=a-l,l=a-u}for(o++;o<l;){var c=o+(l-o>>>1);i(r,e[t+c])>0?o=c+1:l=c}return l}function Wm(r,e,t,n,a,i){var o=0,s=0,l=1;if(i(r,e[t+a])<0){for(s=a+1;l<s&&i(r,e[t+a-l])<0;)o=l,l=(l<<1)+1,l<=0&&(l=s);l>s&&(l=s);var u=o;o=a-l,l=a-u}else{for(s=n-a;l<s&&i(r,e[t+a+l])>=0;)o=l,l=(l<<1)+1,l<=0&&(l=s);l>s&&(l=s),o+=a,l+=a}for(o++;o<l;){var c=o+(l-o>>>1);i(r,e[t+c])<0?l=c:o=c+1}return l}function HV(r,e){var t=Ic,n,a,i=0;r.length;var o=[];n=[],a=[];function s(v,d){n[i]=v,a[i]=d,i+=1}function l(){for(;i>1;){var v=i-2;if(v>=1&&a[v-1]<=a[v]+a[v+1]||v>=2&&a[v-2]<=a[v]+a[v-1])a[v-1]<a[v+1]&&v--;else if(a[v]>a[v+1])break;c(v)}}function u(){for(;i>1;){var v=i-2;v>0&&a[v-1]<a[v+1]&&v--,c(v)}}function c(v){var d=n[v],p=a[v],g=n[v+1],y=a[v+1];a[v]=p+y,v===i-3&&(n[v+1]=n[v+2],a[v+1]=a[v+2]),i--;var m=Wm(r[g],r,d,p,0,e);d+=m,p-=m,p!==0&&(y=Hm(r[d+p-1],r,g,y,y-1,e),y!==0&&(p<=y?f(d,p,g,y):h(d,p,g,y)))}function f(v,d,p,g){var y=0;for(y=0;y<d;y++)o[y]=r[v+y];var m=0,_=p,b=v;if(r[b++]=r[_++],--g===0){for(y=0;y<d;y++)r[b+y]=o[m+y];return}if(d===1){for(y=0;y<g;y++)r[b+y]=r[_+y];r[b+g]=o[m];return}for(var x=t,M,w,D;;){M=0,w=0,D=!1;do if(e(r[_],o[m])<0){if(r[b++]=r[_++],w++,M=0,--g===0){D=!0;break}}else if(r[b++]=o[m++],M++,w=0,--d===1){D=!0;break}while((M|w)<x);if(D)break;do{if(M=Wm(r[_],o,m,d,0,e),M!==0){for(y=0;y<M;y++)r[b+y]=o[m+y];if(b+=M,m+=M,d-=M,d<=1){D=!0;break}}if(r[b++]=r[_++],--g===0){D=!0;break}if(w=Hm(o[m],r,_,g,0,e),w!==0){for(y=0;y<w;y++)r[b+y]=r[_+y];if(b+=w,_+=w,g-=w,g===0){D=!0;break}}if(r[b++]=o[m++],--d===1){D=!0;break}x--}while(M>=Ic||w>=Ic);if(D)break;x<0&&(x=0),x+=2}if(t=x,t<1&&(t=1),d===1){for(y=0;y<g;y++)r[b+y]=r[_+y];r[b+g]=o[m]}else{if(d===0)throw new Error;for(y=0;y<d;y++)r[b+y]=o[m+y]}}function h(v,d,p,g){var y=0;for(y=0;y<g;y++)o[y]=r[p+y];var m=v+d-1,_=g-1,b=p+g-1,x=0,M=0;if(r[b--]=r[m--],--d===0){for(x=b-(g-1),y=0;y<g;y++)r[x+y]=o[y];return}if(g===1){for(b-=d,m-=d,M=b+1,x=m+1,y=d-1;y>=0;y--)r[M+y]=r[x+y];r[b]=o[_];return}for(var w=t;;){var D=0,T=0,I=!1;do if(e(o[_],r[m])<0){if(r[b--]=r[m--],D++,T=0,--d===0){I=!0;break}}else if(r[b--]=o[_--],T++,D=0,--g===1){I=!0;break}while((D|T)<w);if(I)break;do{if(D=d-Wm(o[_],r,v,d,d-1,e),D!==0){for(b-=D,m-=D,d-=D,M=b+1,x=m+1,y=D-1;y>=0;y--)r[M+y]=r[x+y];if(d===0){I=!0;break}}if(r[b--]=o[_--],--g===1){I=!0;break}if(T=g-Hm(r[m],o,0,g,g-1,e),T!==0){for(b-=T,_-=T,g-=T,M=b+1,x=_+1,y=0;y<T;y++)r[M+y]=o[x+y];if(g<=1){I=!0;break}}if(r[b--]=r[m--],--d===0){I=!0;break}w--}while(D>=Ic||T>=Ic);if(I)break;w<0&&(w=0),w+=2}if(t=w,t<1&&(t=1),g===1){for(b-=d,m-=d,M=b+1,x=m+1,y=d-1;y>=0;y--)r[M+y]=r[x+y];r[b]=o[_]}else{if(g===0)throw new Error;for(x=b-(g-1),y=0;y<g;y++)r[x+y]=o[y]}}return{mergeRuns:l,forceMergeRuns:u,pushRun:s}}function Pv(r,e,t,n){t||(t=0),n||(n=r.length);var a=n-t;if(!(a<2)){var i=0;if(a<aI){i=iI(r,t,n,e),oI(r,t,n,t+i,e);return}var o=HV(r,e),s=FV(a);do{if(i=iI(r,t,n,e),i<s){var l=a;l>s&&(l=s),oI(r,t,t+l,t+i,e),i=l}o.pushRun(t,i),o.mergeRuns(),a-=i,t+=i}while(a!==0);o.forceMergeRuns()}}var mn=1,Tc=2,zl=4,sI=!1;function Gm(){sI||(sI=!0,console.warn("z / z2 / zlevel of displayable is invalid, which may cause unexpected errors"))}function lI(r,e){return r.zlevel===e.zlevel?r.z===e.z?r.z2-e.z2:r.z-e.z:r.zlevel-e.zlevel}var WV=function(){function r(){this._roots=[],this._displayList=[],this._displayListLen=0,this.displayableSortFunc=lI}return r.prototype.traverse=function(e,t){for(var n=0;n<this._roots.length;n++)this._roots[n].traverse(e,t)},r.prototype.getDisplayList=function(e,t){t=t||!1;var n=this._displayList;return(e||!n.length)&&this.updateDisplayList(t),n},r.prototype.updateDisplayList=function(e){this._displayListLen=0;for(var t=this._roots,n=this._displayList,a=0,i=t.length;a<i;a++)this._updateAndAddDisplayable(t[a],null,e);n.length=this._displayListLen,Pv(n,lI)},r.prototype._updateAndAddDisplayable=function(e,t,n){if(!(e.ignore&&!n)){e.beforeUpdate(),e.update(),e.afterUpdate();var a=e.getClipPath();if(e.ignoreClip)t=null;else if(a){t?t=t.slice():t=[];for(var i=a,o=e;i;)i.parent=o,i.updateTransform(),t.push(i),o=i,i=i.getClipPath()}if(e.childrenRef){for(var s=e.childrenRef(),l=0;l<s.length;l++){var u=s[l];e.__dirty&&(u.__dirty|=mn),this._updateAndAddDisplayable(u,t,n)}e.__dirty=0}else{var c=e;t&&t.length?c.__clipPaths=t:c.__clipPaths&&c.__clipPaths.length>0&&(c.__clipPaths=[]),isNaN(c.z)&&(Gm(),c.z=0),isNaN(c.z2)&&(Gm(),c.z2=0),isNaN(c.zlevel)&&(Gm(),c.zlevel=0),this._displayList[this._displayListLen++]=c}var f=e.getDecalElement&&e.getDecalElement();f&&this._updateAndAddDisplayable(f,t,n);var h=e.getTextGuideLine();h&&this._updateAndAddDisplayable(h,t,n);var v=e.getTextContent();v&&this._updateAndAddDisplayable(v,t,n)}},r.prototype.addRoot=function(e){e.__zr&&e.__zr.storage===this||this._roots.push(e)},r.prototype.delRoot=function(e){if(e instanceof Array){for(var t=0,n=e.length;t<n;t++)this.delRoot(e[t]);return}var a=ze(this._roots,e);a>=0&&this._roots.splice(a,1)},r.prototype.delAllRoots=function(){this._roots=[],this._displayList=[],this._displayListLen=0},r.prototype.getRoots=function(){return this._roots},r.prototype.dispose=function(){this._displayList=null,this._roots=null},r}(),GV=WV,uI;uI=$e.hasGlobalWindow&&(window.requestAnimationFrame&&window.requestAnimationFrame.bind(window)||window.msRequestAnimationFrame&&window.msRequestAnimationFrame.bind(window)||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame)||function(r){return setTimeout(r,16)};var $m=uI,zv={linear:function(r){return r},quadraticIn:function(r){return r*r},quadraticOut:function(r){return r*(2-r)},quadraticInOut:function(r){return(r*=2)<1?.5*r*r:-.5*(--r*(r-2)-1)},cubicIn:function(r){return r*r*r},cubicOut:function(r){return--r*r*r+1},cubicInOut:function(r){return(r*=2)<1?.5*r*r*r:.5*((r-=2)*r*r+2)},quarticIn:function(r){return r*r*r*r},quarticOut:function(r){return 1- --r*r*r*r},quarticInOut:function(r){return(r*=2)<1?.5*r*r*r*r:-.5*((r-=2)*r*r*r-2)},quinticIn:function(r){return r*r*r*r*r},quinticOut:function(r){return--r*r*r*r*r+1},quinticInOut:function(r){return(r*=2)<1?.5*r*r*r*r*r:.5*((r-=2)*r*r*r*r+2)},sinusoidalIn:function(r){return 1-Math.cos(r*Math.PI/2)},sinusoidalOut:function(r){return Math.sin(r*Math.PI/2)},sinusoidalInOut:function(r){return .5*(1-Math.cos(Math.PI*r))},exponentialIn:function(r){return r===0?0:Math.pow(1024,r-1)},exponentialOut:function(r){return r===1?1:1-Math.pow(2,-10*r)},exponentialInOut:function(r){return r===0?0:r===1?1:(r*=2)<1?.5*Math.pow(1024,r-1):.5*(-Math.pow(2,-10*(r-1))+2)},circularIn:function(r){return 1-Math.sqrt(1-r*r)},circularOut:function(r){return Math.sqrt(1- --r*r)},circularInOut:function(r){return(r*=2)<1?-.5*(Math.sqrt(1-r*r)-1):.5*(Math.sqrt(1-(r-=2)*r)+1)},elasticIn:function(r){var e,t=.1,n=.4;return r===0?0:r===1?1:(!t||t<1?(t=1,e=n/4):e=n*Math.asin(1/t)/(2*Math.PI),-(t*Math.pow(2,10*(r-=1))*Math.sin((r-e)*(2*Math.PI)/n)))},elasticOut:function(r){var e,t=.1,n=.4;return r===0?0:r===1?1:(!t||t<1?(t=1,e=n/4):e=n*Math.asin(1/t)/(2*Math.PI),t*Math.pow(2,-10*r)*Math.sin((r-e)*(2*Math.PI)/n)+1)},elasticInOut:function(r){var e,t=.1,n=.4;return r===0?0:r===1?1:(!t||t<1?(t=1,e=n/4):e=n*Math.asin(1/t)/(2*Math.PI),(r*=2)<1?-.5*(t*Math.pow(2,10*(r-=1))*Math.sin((r-e)*(2*Math.PI)/n)):t*Math.pow(2,-10*(r-=1))*Math.sin((r-e)*(2*Math.PI)/n)*.5+1)},backIn:function(r){var e=1.70158;return r*r*((e+1)*r-e)},backOut:function(r){var e=1.70158;return--r*r*((e+1)*r+e)+1},backInOut:function(r){var e=2.5949095;return(r*=2)<1?.5*(r*r*((e+1)*r-e)):.5*((r-=2)*r*((e+1)*r+e)+2)},bounceIn:function(r){return 1-zv.bounceOut(1-r)},bounceOut:function(r){return r<1/2.75?7.5625*r*r:r<2/2.75?7.5625*(r-=1.5/2.75)*r+.75:r<2.5/2.75?7.5625*(r-=2.25/2.75)*r+.9375:7.5625*(r-=2.625/2.75)*r+.984375},bounceInOut:function(r){return r<.5?zv.bounceIn(r*2)*.5:zv.bounceOut(r*2-1)*.5+.5}},cI=zv,kv=Math.pow,qi=Math.sqrt,Rv=1e-8,fI=1e-4,hI=qi(3),jv=1/3,za=Ui(),Rn=Ui(),kl=Ui();function Xi(r){return r>-Rv&&r<Rv}function vI(r){return r>Rv||r<-Rv}function ir(r,e,t,n,a){var i=1-a;return i*i*(i*r+3*a*e)+a*a*(a*n+3*i*t)}function dI(r,e,t,n,a){var i=1-a;return 3*(((e-r)*i+2*(t-e)*a)*i+(n-t)*a*a)}function Bv(r,e,t,n,a,i){var o=n+3*(e-t)-r,s=3*(t-e*2+r),l=3*(e-r),u=r-a,c=s*s-3*o*l,f=s*l-9*o*u,h=l*l-3*s*u,v=0;if(Xi(c)&&Xi(f))if(Xi(s))i[0]=0;else{var d=-l/s;d>=0&&d<=1&&(i[v++]=d)}else{var p=f*f-4*c*h;if(Xi(p)){var g=f/c,d=-s/o+g,y=-g/2;d>=0&&d<=1&&(i[v++]=d),y>=0&&y<=1&&(i[v++]=y)}else if(p>0){var m=qi(p),_=c*s+1.5*o*(-f+m),b=c*s+1.5*o*(-f-m);_<0?_=-kv(-_,jv):_=kv(_,jv),b<0?b=-kv(-b,jv):b=kv(b,jv);var d=(-s-(_+b))/(3*o);d>=0&&d<=1&&(i[v++]=d)}else{var x=(2*c*s-3*o*f)/(2*qi(c*c*c)),M=Math.acos(x)/3,w=qi(c),D=Math.cos(M),d=(-s-2*w*D)/(3*o),y=(-s+w*(D+hI*Math.sin(M)))/(3*o),T=(-s+w*(D-hI*Math.sin(M)))/(3*o);d>=0&&d<=1&&(i[v++]=d),y>=0&&y<=1&&(i[v++]=y),T>=0&&T<=1&&(i[v++]=T)}}return v}function pI(r,e,t,n,a){var i=6*t-12*e+6*r,o=9*e+3*n-3*r-9*t,s=3*e-3*r,l=0;if(Xi(o)){if(vI(i)){var u=-s/i;u>=0&&u<=1&&(a[l++]=u)}}else{var c=i*i-4*o*s;if(Xi(c))a[0]=-i/(2*o);else if(c>0){var f=qi(c),u=(-i+f)/(2*o),h=(-i-f)/(2*o);u>=0&&u<=1&&(a[l++]=u),h>=0&&h<=1&&(a[l++]=h)}}return l}function Ji(r,e,t,n,a,i){var o=(e-r)*a+r,s=(t-e)*a+e,l=(n-t)*a+t,u=(s-o)*a+o,c=(l-s)*a+s,f=(c-u)*a+u;i[0]=r,i[1]=o,i[2]=u,i[3]=f,i[4]=f,i[5]=c,i[6]=l,i[7]=n}function gI(r,e,t,n,a,i,o,s,l,u,c){var f,h=.005,v=1/0,d,p,g,y;za[0]=l,za[1]=u;for(var m=0;m<1;m+=.05)Rn[0]=ir(r,t,a,o,m),Rn[1]=ir(e,n,i,s,m),g=Qi(za,Rn),g<v&&(f=m,v=g);v=1/0;for(var _=0;_<32&&!(h<fI);_++)d=f-h,p=f+h,Rn[0]=ir(r,t,a,o,d),Rn[1]=ir(e,n,i,s,d),g=Qi(Rn,za),d>=0&&g<v?(f=d,v=g):(kl[0]=ir(r,t,a,o,p),kl[1]=ir(e,n,i,s,p),y=Qi(kl,za),p<=1&&y<v?(f=p,v=y):h*=.5);return c&&(c[0]=ir(r,t,a,o,f),c[1]=ir(e,n,i,s,f)),qi(v)}function $V(r,e,t,n,a,i,o,s,l){for(var u=r,c=e,f=0,h=1/l,v=1;v<=l;v++){var d=v*h,p=ir(r,t,a,o,d),g=ir(e,n,i,s,d),y=p-u,m=g-c;f+=Math.sqrt(y*y+m*m),u=p,c=g}return f}function dr(r,e,t,n){var a=1-n;return a*(a*r+2*n*e)+n*n*t}function Um(r,e,t,n){return 2*((1-n)*(e-r)+n*(t-e))}function UV(r,e,t,n,a){var i=r-2*e+t,o=2*(e-r),s=r-n,l=0;if(Xi(i)){if(vI(o)){var u=-s/o;u>=0&&u<=1&&(a[l++]=u)}}else{var c=o*o-4*i*s;if(Xi(c)){var u=-o/(2*i);u>=0&&u<=1&&(a[l++]=u)}else if(c>0){var f=qi(c),u=(-o+f)/(2*i),h=(-o-f)/(2*i);u>=0&&u<=1&&(a[l++]=u),h>=0&&h<=1&&(a[l++]=h)}}return l}function yI(r,e,t){var n=r+t-2*e;return n===0?.5:(r-e)/n}function Ac(r,e,t,n,a){var i=(e-r)*n+r,o=(t-e)*n+e,s=(o-i)*n+i;a[0]=r,a[1]=i,a[2]=s,a[3]=s,a[4]=o,a[5]=t}function mI(r,e,t,n,a,i,o,s,l){var u,c=.005,f=1/0;za[0]=o,za[1]=s;for(var h=0;h<1;h+=.05){Rn[0]=dr(r,t,a,h),Rn[1]=dr(e,n,i,h);var v=Qi(za,Rn);v<f&&(u=h,f=v)}f=1/0;for(var d=0;d<32&&!(c<fI);d++){var p=u-c,g=u+c;Rn[0]=dr(r,t,a,p),Rn[1]=dr(e,n,i,p);var v=Qi(Rn,za);if(p>=0&&v<f)u=p,f=v;else{kl[0]=dr(r,t,a,g),kl[1]=dr(e,n,i,g);var y=Qi(kl,za);g<=1&&y<f?(u=g,f=y):c*=.5}}return l&&(l[0]=dr(r,t,a,u),l[1]=dr(e,n,i,u)),qi(f)}function YV(r,e,t,n,a,i,o){for(var s=r,l=e,u=0,c=1/o,f=1;f<=o;f++){var h=f*c,v=dr(r,t,a,h),d=dr(e,n,i,h),p=v-s,g=d-l;u+=Math.sqrt(p*p+g*g),s=v,l=d}return u}var QV=/cubic-bezier\(([0-9,\.e ]+)\)/;function Ym(r){var e=r&&QV.exec(r);if(e){var t=e[1].split(","),n=+Pn(t[0]),a=+Pn(t[1]),i=+Pn(t[2]),o=+Pn(t[3]);if(isNaN(n+a+i+o))return;var s=[];return function(l){return l<=0?0:l>=1?1:Bv(0,n,i,1,l,s)&&ir(0,a,o,1,s[0])}}}var ZV=function(){function r(e){this._inited=!1,this._startTime=0,this._pausedTime=0,this._paused=!1,this._life=e.life||1e3,this._delay=e.delay||0,this.loop=e.loop||!1,this.onframe=e.onframe||Ot,this.ondestroy=e.ondestroy||Ot,this.onrestart=e.onrestart||Ot,e.easing&&this.setEasing(e.easing)}return r.prototype.step=function(e,t){if(this._inited||(this._startTime=e+this._delay,this._inited=!0),this._paused){this._pausedTime+=t;return}var n=this._life,a=e-this._startTime-this._pausedTime,i=a/n;i<0&&(i=0),i=Math.min(i,1);var o=this.easingFunc,s=o?o(i):i;if(this.onframe(s),i===1)if(this.loop){var l=a%n;this._startTime=e-l,this._pausedTime=0,this.onrestart()}else return!0;return!1},r.prototype.pause=function(){this._paused=!0},r.prototype.resume=function(){this._paused=!1},r.prototype.setEasing=function(e){this.easing=e,this.easingFunc=ye(e)?e:cI[e]||Ym(e)},r}(),qV=ZV,_I=function(){function r(e){this.value=e}return r}(),XV=function(){function r(){this._len=0}return r.prototype.insert=function(e){var t=new _I(e);return this.insertEntry(t),t},r.prototype.insertEntry=function(e){this.head?(this.tail.next=e,e.prev=this.tail,e.next=null,this.tail=e):this.head=this.tail=e,this._len++},r.prototype.remove=function(e){var t=e.prev,n=e.next;t?t.next=n:this.head=n,n?n.prev=t:this.tail=t,e.next=e.prev=null,this._len--},r.prototype.len=function(){return this._len},r.prototype.clear=function(){this.head=this.tail=null,this._len=0},r}(),JV=function(){function r(e){this._list=new XV,this._maxSize=10,this._map={},this._maxSize=e}return r.prototype.put=function(e,t){var n=this._list,a=this._map,i=null;if(a[e]==null){var o=n.len(),s=this._lastRemovedEntry;if(o>=this._maxSize&&o>0){var l=n.head;n.remove(l),delete a[l.key],i=l.value,this._lastRemovedEntry=l}s?s.value=t:s=new _I(t),s.key=e,n.insertEntry(s),a[e]=s}return i},r.prototype.get=function(e){var t=this._map[e],n=this._list;if(t!=null)return t!==n.tail&&(n.remove(t),n.insertEntry(t)),t.value},r.prototype.clear=function(){this._list.clear(),this._map={}},r.prototype.len=function(){return this._list.len()},r}(),Cc=JV,bI={transparent:[0,0,0,0],aliceblue:[240,248,255,1],antiquewhite:[250,235,215,1],aqua:[0,255,255,1],aquamarine:[127,255,212,1],azure:[240,255,255,1],beige:[245,245,220,1],bisque:[255,228,196,1],black:[0,0,0,1],blanchedalmond:[255,235,205,1],blue:[0,0,255,1],blueviolet:[138,43,226,1],brown:[165,42,42,1],burlywood:[222,184,135,1],cadetblue:[95,158,160,1],chartreuse:[127,255,0,1],chocolate:[210,105,30,1],coral:[255,127,80,1],cornflowerblue:[100,149,237,1],cornsilk:[255,248,220,1],crimson:[220,20,60,1],cyan:[0,255,255,1],darkblue:[0,0,139,1],darkcyan:[0,139,139,1],darkgoldenrod:[184,134,11,1],darkgray:[169,169,169,1],darkgreen:[0,100,0,1],darkgrey:[169,169,169,1],darkkhaki:[189,183,107,1],darkmagenta:[139,0,139,1],darkolivegreen:[85,107,47,1],darkorange:[255,140,0,1],darkorchid:[153,50,204,1],darkred:[139,0,0,1],darksalmon:[233,150,122,1],darkseagreen:[143,188,143,1],darkslateblue:[72,61,139,1],darkslategray:[47,79,79,1],darkslategrey:[47,79,79,1],darkturquoise:[0,206,209,1],darkviolet:[148,0,211,1],deeppink:[255,20,147,1],deepskyblue:[0,191,255,1],dimgray:[105,105,105,1],dimgrey:[105,105,105,1],dodgerblue:[30,144,255,1],firebrick:[178,34,34,1],floralwhite:[255,250,240,1],forestgreen:[34,139,34,1],fuchsia:[255,0,255,1],gainsboro:[220,220,220,1],ghostwhite:[248,248,255,1],gold:[255,215,0,1],goldenrod:[218,165,32,1],gray:[128,128,128,1],green:[0,128,0,1],greenyellow:[173,255,47,1],grey:[128,128,128,1],honeydew:[240,255,240,1],hotpink:[255,105,180,1],indianred:[205,92,92,1],indigo:[75,0,130,1],ivory:[255,255,240,1],khaki:[240,230,140,1],lavender:[230,230,250,1],lavenderblush:[255,240,245,1],lawngreen:[124,252,0,1],lemonchiffon:[255,250,205,1],lightblue:[173,216,230,1],lightcoral:[240,128,128,1],lightcyan:[224,255,255,1],lightgoldenrodyellow:[250,250,210,1],lightgray:[211,211,211,1],lightgreen:[144,238,144,1],lightgrey:[211,211,211,1],lightpink:[255,182,193,1],lightsalmon:[255,160,122,1],lightseagreen:[32,178,170,1],lightskyblue:[135,206,250,1],lightslategray:[119,136,153,1],lightslategrey:[119,136,153,1],lightsteelblue:[176,196,222,1],lightyellow:[255,255,224,1],lime:[0,255,0,1],limegreen:[50,205,50,1],linen:[250,240,230,1],magenta:[255,0,255,1],maroon:[128,0,0,1],mediumaquamarine:[102,205,170,1],mediumblue:[0,0,205,1],mediumorchid:[186,85,211,1],mediumpurple:[147,112,219,1],mediumseagreen:[60,179,113,1],mediumslateblue:[123,104,238,1],mediumspringgreen:[0,250,154,1],mediumturquoise:[72,209,204,1],mediumvioletred:[199,21,133,1],midnightblue:[25,25,112,1],mintcream:[245,255,250,1],mistyrose:[255,228,225,1],moccasin:[255,228,181,1],navajowhite:[255,222,173,1],navy:[0,0,128,1],oldlace:[253,245,230,1],olive:[128,128,0,1],olivedrab:[107,142,35,1],orange:[255,165,0,1],orangered:[255,69,0,1],orchid:[218,112,214,1],palegoldenrod:[238,232,170,1],palegreen:[152,251,152,1],paleturquoise:[175,238,238,1],palevioletred:[219,112,147,1],papayawhip:[255,239,213,1],peachpuff:[255,218,185,1],peru:[205,133,63,1],pink:[255,192,203,1],plum:[221,160,221,1],powderblue:[176,224,230,1],purple:[128,0,128,1],red:[255,0,0,1],rosybrown:[188,143,143,1],royalblue:[65,105,225,1],saddlebrown:[139,69,19,1],salmon:[250,128,114,1],sandybrown:[244,164,96,1],seagreen:[46,139,87,1],seashell:[255,245,238,1],sienna:[160,82,45,1],silver:[192,192,192,1],skyblue:[135,206,235,1],slateblue:[106,90,205,1],slategray:[112,128,144,1],slategrey:[112,128,144,1],snow:[255,250,250,1],springgreen:[0,255,127,1],steelblue:[70,130,180,1],tan:[210,180,140,1],teal:[0,128,128,1],thistle:[216,191,216,1],tomato:[255,99,71,1],turquoise:[64,224,208,1],violet:[238,130,238,1],wheat:[245,222,179,1],white:[255,255,255,1],whitesmoke:[245,245,245,1],yellow:[255,255,0,1],yellowgreen:[154,205,50,1]};function ca(r){return r=Math.round(r),r<0?0:r>255?255:r}function KV(r){return r=Math.round(r),r<0?0:r>360?360:r}function Nc(r){return r<0?0:r>1?1:r}function Qm(r){var e=r;return e.length&&e.charAt(e.length-1)==="%"?ca(parseFloat(e)/100*255):ca(parseInt(e,10))}function Ko(r){var e=r;return e.length&&e.charAt(e.length-1)==="%"?Nc(parseFloat(e)/100):Nc(parseFloat(e))}function Zm(r,e,t){return t<0?t+=1:t>1&&(t-=1),t*6<1?r+(e-r)*t*6:t*2<1?e:t*3<2?r+(e-r)*(2/3-t)*6:r}function Ki(r,e,t){return r+(e-r)*t}function jn(r,e,t,n,a){return r[0]=e,r[1]=t,r[2]=n,r[3]=a,r}function qm(r,e){return r[0]=e[0],r[1]=e[1],r[2]=e[2],r[3]=e[3],r}var MI=new Cc(20),Fv=null;function Rl(r,e){Fv&&qm(Fv,e),Fv=MI.put(r,Fv||e.slice())}function Ur(r,e){if(!!r){e=e||[];var t=MI.get(r);if(t)return qm(e,t);r=r+"";var n=r.replace(/ /g,"").toLowerCase();if(n in bI)return qm(e,bI[n]),Rl(r,e),e;var a=n.length;if(n.charAt(0)==="#"){if(a===4||a===5){var i=parseInt(n.slice(1,4),16);if(!(i>=0&&i<=4095)){jn(e,0,0,0,1);return}return jn(e,(i&3840)>>4|(i&3840)>>8,i&240|(i&240)>>4,i&15|(i&15)<<4,a===5?parseInt(n.slice(4),16)/15:1),Rl(r,e),e}else if(a===7||a===9){var i=parseInt(n.slice(1,7),16);if(!(i>=0&&i<=16777215)){jn(e,0,0,0,1);return}return jn(e,(i&16711680)>>16,(i&65280)>>8,i&255,a===9?parseInt(n.slice(7),16)/255:1),Rl(r,e),e}return}var o=n.indexOf("("),s=n.indexOf(")");if(o!==-1&&s+1===a){var l=n.substr(0,o),u=n.substr(o+1,s-(o+1)).split(","),c=1;switch(l){case"rgba":if(u.length!==4)return u.length===3?jn(e,+u[0],+u[1],+u[2],1):jn(e,0,0,0,1);c=Ko(u.pop());case"rgb":if(u.length>=3)return jn(e,Qm(u[0]),Qm(u[1]),Qm(u[2]),u.length===3?c:Ko(u[3])),Rl(r,e),e;jn(e,0,0,0,1);return;case"hsla":if(u.length!==4){jn(e,0,0,0,1);return}return u[3]=Ko(u[3]),Xm(u,e),Rl(r,e),e;case"hsl":if(u.length!==3){jn(e,0,0,0,1);return}return Xm(u,e),Rl(r,e),e;default:return}}jn(e,0,0,0,1)}}function Xm(r,e){var t=(parseFloat(r[0])%360+360)%360/360,n=Ko(r[1]),a=Ko(r[2]),i=a<=.5?a*(n+1):a+n-a*n,o=a*2-i;return e=e||[],jn(e,ca(Zm(o,i,t+1/3)*255),ca(Zm(o,i,t)*255),ca(Zm(o,i,t-1/3)*255),1),r.length===4&&(e[3]=r[3]),e}function eH(r){if(!!r){var e=r[0]/255,t=r[1]/255,n=r[2]/255,a=Math.min(e,t,n),i=Math.max(e,t,n),o=i-a,s=(i+a)/2,l,u;if(o===0)l=0,u=0;else{s<.5?u=o/(i+a):u=o/(2-i-a);var c=((i-e)/6+o/2)/o,f=((i-t)/6+o/2)/o,h=((i-n)/6+o/2)/o;e===i?l=h-f:t===i?l=1/3+c-h:n===i&&(l=2/3+f-c),l<0&&(l+=1),l>1&&(l-=1)}var v=[l*360,u,s];return r[3]!=null&&v.push(r[3]),v}}function Vv(r,e){var t=Ur(r);if(t){for(var n=0;n<3;n++)e<0?t[n]=t[n]*(1-e)|0:t[n]=(255-t[n])*e+t[n]|0,t[n]>255?t[n]=255:t[n]<0&&(t[n]=0);return fa(t,t.length===4?"rgba":"rgb")}}function tH(r){var e=Ur(r);if(e)return((1<<24)+(e[0]<<16)+(e[1]<<8)+ +e[2]).toString(16).slice(1)}function Lc(r,e,t){if(!(!(e&&e.length)||!(r>=0&&r<=1))){t=t||[];var n=r*(e.length-1),a=Math.floor(n),i=Math.ceil(n),o=e[a],s=e[i],l=n-a;return t[0]=ca(Ki(o[0],s[0],l)),t[1]=ca(Ki(o[1],s[1],l)),t[2]=ca(Ki(o[2],s[2],l)),t[3]=Nc(Ki(o[3],s[3],l)),t}}var rH=Lc;function Jm(r,e,t){if(!(!(e&&e.length)||!(r>=0&&r<=1))){var n=r*(e.length-1),a=Math.floor(n),i=Math.ceil(n),o=Ur(e[a]),s=Ur(e[i]),l=n-a,u=fa([ca(Ki(o[0],s[0],l)),ca(Ki(o[1],s[1],l)),ca(Ki(o[2],s[2],l)),Nc(Ki(o[3],s[3],l))],"rgba");return t?{color:u,leftIndex:a,rightIndex:i,value:n}:u}}var nH=Jm;function jl(r,e,t,n){var a=Ur(r);if(r)return a=eH(a),e!=null&&(a[0]=KV(e)),t!=null&&(a[1]=Ko(t)),n!=null&&(a[2]=Ko(n)),fa(Xm(a),"rgba")}function Ec(r,e){var t=Ur(r);if(t&&e!=null)return t[3]=Nc(e),fa(t,"rgba")}function fa(r,e){if(!(!r||!r.length)){var t=r[0]+","+r[1]+","+r[2];return(e==="rgba"||e==="hsva"||e==="hsla")&&(t+=","+r[3]),e+"("+t+")"}}function Oc(r,e){var t=Ur(r);return t?(.299*t[0]+.587*t[1]+.114*t[2])*t[3]/255+(1-t[3])*e:0}function aH(){return fa([Math.round(Math.random()*255),Math.round(Math.random()*255),Math.round(Math.random()*255)],"rgb")}var iH=Object.freeze(Object.defineProperty({__proto__:null,parse:Ur,lift:Vv,toHex:tH,fastLerp:Lc,fastMapToColor:rH,lerp:Jm,mapToColor:nH,modifyHSL:jl,modifyAlpha:Ec,stringify:fa,lum:Oc,random:aH},Symbol.toStringTag,{value:"Module"})),Hv=Math.round;function Pc(r){var e;if(!r||r==="transparent")r="none";else if(typeof r=="string"&&r.indexOf("rgba")>-1){var t=Ur(r);t&&(r="rgb("+t[0]+","+t[1]+","+t[2]+")",e=t[3])}return{color:r,opacity:e==null?1:e}}var xI=1e-4;function eo(r){return r<xI&&r>-xI}function Wv(r){return Hv(r*1e3)/1e3}function Km(r){return Hv(r*1e4)/1e4}function oH(r){return"matrix("+Wv(r[0])+","+Wv(r[1])+","+Wv(r[2])+","+Wv(r[3])+","+Km(r[4])+","+Km(r[5])+")"}var sH={left:"start",right:"end",center:"middle",middle:"middle"};function lH(r,e,t){return t==="top"?r+=e/2:t==="bottom"&&(r-=e/2),r}function uH(r){return r&&(r.shadowBlur||r.shadowOffsetX||r.shadowOffsetY)}function cH(r){var e=r.style,t=r.getGlobalScale();return[e.shadowColor,(e.shadowBlur||0).toFixed(2),(e.shadowOffsetX||0).toFixed(2),(e.shadowOffsetY||0).toFixed(2),t[0],t[1]].join(",")}function wI(r){return r&&!!r.image}function fH(r){return r&&!!r.svgElement}function e0(r){return wI(r)||fH(r)}function DI(r){return r.type==="linear"}function SI(r){return r.type==="radial"}function II(r){return r&&(r.type==="linear"||r.type==="radial")}function Gv(r){return"url(#"+r+")"}function TI(r){var e=r.getGlobalScale(),t=Math.max(e[0],e[1]);return Math.max(Math.ceil(Math.log(t)/Math.log(10)),1)}function AI(r){var e=r.x||0,t=r.y||0,n=(r.rotation||0)*mc,a=Ee(r.scaleX,1),i=Ee(r.scaleY,1),o=r.skewX||0,s=r.skewY||0,l=[];return(e||t)&&l.push("translate("+e+"px,"+t+"px)"),n&&l.push("rotate("+n+")"),(a!==1||i!==1)&&l.push("scale("+a+","+i+")"),(o||s)&&l.push("skew("+Hv(o*mc)+"deg, "+Hv(s*mc)+"deg)"),l.join(" ")}var hH=function(){return $e.hasGlobalWindow&&ye(window.btoa)?function(r){return window.btoa(unescape(encodeURIComponent(r)))}:typeof Buffer!="undefined"?function(r){return Buffer.from(r).toString("base64")}:function(r){return null}}(),t0=Array.prototype.slice;function vi(r,e,t){return(e-r)*t+r}function r0(r,e,t,n){for(var a=e.length,i=0;i<a;i++)r[i]=vi(e[i],t[i],n);return r}function vH(r,e,t,n){for(var a=e.length,i=a&&e[0].length,o=0;o<a;o++){r[o]||(r[o]=[]);for(var s=0;s<i;s++)r[o][s]=vi(e[o][s],t[o][s],n)}return r}function $v(r,e,t,n){for(var a=e.length,i=0;i<a;i++)r[i]=e[i]+t[i]*n;return r}function CI(r,e,t,n){for(var a=e.length,i=a&&e[0].length,o=0;o<a;o++){r[o]||(r[o]=[]);for(var s=0;s<i;s++)r[o][s]=e[o][s]+t[o][s]*n}return r}function dH(r,e){for(var t=r.length,n=e.length,a=t>n?e:r,i=Math.min(t,n),o=a[i-1]||{color:[0,0,0,0],offset:0},s=i;s<Math.max(t,n);s++)a.push({offset:o.offset,color:o.color.slice()})}function pH(r,e,t){var n=r,a=e;if(!(!n.push||!a.push)){var i=n.length,o=a.length;if(i!==o){var s=i>o;if(s)n.length=o;else for(var l=i;l<o;l++)n.push(t===1?a[l]:t0.call(a[l]))}for(var u=n[0]&&n[0].length,l=0;l<n.length;l++)if(t===1)isNaN(n[l])&&(n[l]=a[l]);else for(var c=0;c<u;c++)isNaN(n[l][c])&&(n[l][c]=a[l][c])}}function zc(r){if(Mr(r)){var e=r.length;if(Mr(r[0])){for(var t=[],n=0;n<e;n++)t.push(t0.call(r[n]));return t}return t0.call(r)}return r}function Uv(r){return r[0]=Math.floor(r[0])||0,r[1]=Math.floor(r[1])||0,r[2]=Math.floor(r[2])||0,r[3]=r[3]==null?1:r[3],"rgba("+r.join(",")+")"}function gH(r){return Mr(r&&r[0])?2:1}var Yv=0,Qv=1,NI=2,kc=3,n0=4,a0=5,LI=6;function EI(r){return r===n0||r===a0}function Zv(r){return r===Qv||r===NI}var Rc=[0,0,0,0],yH=function(){function r(e){this.keyframes=[],this.discrete=!1,this._invalid=!1,this._needsSort=!1,this._lastFr=0,this._lastFrP=0,this.propName=e}return r.prototype.isFinished=function(){return this._finished},r.prototype.setFinished=function(){this._finished=!0,this._additiveTrack&&this._additiveTrack.setFinished()},r.prototype.needsAnimate=function(){return this.keyframes.length>=1},r.prototype.getAdditiveTrack=function(){return this._additiveTrack},r.prototype.addKeyframe=function(e,t,n){this._needsSort=!0;var a=this.keyframes,i=a.length,o=!1,s=LI,l=t;if(Mr(t)){var u=gH(t);s=u,(u===1&&!Ue(t[0])||u===2&&!Ue(t[0][0]))&&(o=!0)}else if(Ue(t)&&!El(t))s=Yv;else if(ce(t))if(!isNaN(+t))s=Yv;else{var c=Ur(t);c&&(l=c,s=kc)}else if(dc(t)){var f=X({},l);f.colorStops=K(t.colorStops,function(v){return{offset:v.offset,color:Ur(v.color)}}),DI(t)?s=n0:SI(t)&&(s=a0),l=f}i===0?this.valType=s:(s!==this.valType||s===LI)&&(o=!0),this.discrete=this.discrete||o;var h={time:e,value:l,rawValue:t,percent:0};return n&&(h.easing=n,h.easingFunc=ye(n)?n:cI[n]||Ym(n)),a.push(h),h},r.prototype.prepare=function(e,t){var n=this.keyframes;this._needsSort&&n.sort(function(p,g){return p.time-g.time});for(var a=this.valType,i=n.length,o=n[i-1],s=this.discrete,l=Zv(a),u=EI(a),c=0;c<i;c++){var f=n[c],h=f.value,v=o.value;f.percent=f.time/e,s||(l&&c!==i-1?pH(h,v,a):u&&dH(h.colorStops,v.colorStops))}if(!s&&a!==a0&&t&&this.needsAnimate()&&t.needsAnimate()&&a===t.valType&&!t._finished){this._additiveTrack=t;for(var d=n[0].value,c=0;c<i;c++)a===Yv?n[c].additiveValue=n[c].value-d:a===kc?n[c].additiveValue=$v([],n[c].value,d,-1):Zv(a)&&(n[c].additiveValue=a===Qv?$v([],n[c].value,d,-1):CI([],n[c].value,d,-1))}},r.prototype.step=function(e,t){if(!this._finished){this._additiveTrack&&this._additiveTrack._finished&&(this._additiveTrack=null);var n=this._additiveTrack!=null,a=n?"additiveValue":"value",i=this.valType,o=this.keyframes,s=o.length,l=this.propName,u=i===kc,c,f=this._lastFr,h=Math.min,v,d;if(s===1)v=d=o[0];else{if(t<0)c=0;else if(t<this._lastFrP){var p=h(f+1,s-1);for(c=p;c>=0&&!(o[c].percent<=t);c--);c=h(c,s-2)}else{for(c=f;c<s&&!(o[c].percent>t);c++);c=h(c-1,s-2)}d=o[c+1],v=o[c]}if(!!(v&&d)){this._lastFr=c,this._lastFrP=t;var g=d.percent-v.percent,y=g===0?1:h((t-v.percent)/g,1);d.easingFunc&&(y=d.easingFunc(y));var m=n?this._additiveValue:u?Rc:e[l];if((Zv(i)||u)&&!m&&(m=this._additiveValue=[]),this.discrete)e[l]=y<1?v.rawValue:d.rawValue;else if(Zv(i))i===Qv?r0(m,v[a],d[a],y):vH(m,v[a],d[a],y);else if(EI(i)){var _=v[a],b=d[a],x=i===n0;e[l]={type:x?"linear":"radial",x:vi(_.x,b.x,y),y:vi(_.y,b.y,y),colorStops:K(_.colorStops,function(w,D){var T=b.colorStops[D];return{offset:vi(w.offset,T.offset,y),color:Uv(r0([],w.color,T.color,y))}}),global:b.global},x?(e[l].x2=vi(_.x2,b.x2,y),e[l].y2=vi(_.y2,b.y2,y)):e[l].r=vi(_.r,b.r,y)}else if(u)r0(m,v[a],d[a],y),n||(e[l]=Uv(m));else{var M=vi(v[a],d[a],y);n?this._additiveValue=M:e[l]=M}n&&this._addToTarget(e)}}},r.prototype._addToTarget=function(e){var t=this.valType,n=this.propName,a=this._additiveValue;t===Yv?e[n]=e[n]+a:t===kc?(Ur(e[n],Rc),$v(Rc,Rc,a,1),e[n]=Uv(Rc)):t===Qv?$v(e[n],e[n],a,1):t===NI&&CI(e[n],e[n],a,1)},r}(),mH=function(){function r(e,t,n,a){if(this._tracks={},this._trackKeys=[],this._maxTime=0,this._started=0,this._clip=null,this._target=e,this._loop=t,t&&a){wv("Can' use additive animation on looped animation.");return}this._additiveAnimators=a,this._allowDiscrete=n}return r.prototype.getMaxTime=function(){return this._maxTime},r.prototype.getDelay=function(){return this._delay},r.prototype.getLoop=function(){return this._loop},r.prototype.getTarget=function(){return this._target},r.prototype.changeTarget=function(e){this._target=e},r.prototype.when=function(e,t,n){return this.whenWithKeys(e,t,Fe(t),n)},r.prototype.whenWithKeys=function(e,t,n,a){for(var i=this._tracks,o=0;o<n.length;o++){var s=n[o],l=i[s];if(!l){l=i[s]=new yH(s);var u=void 0,c=this._getAdditiveTrack(s);if(c){var f=c.keyframes,h=f[f.length-1];u=h&&h.value,c.valType===kc&&u&&(u=Uv(u))}else u=this._target[s];if(u==null)continue;e>0&&l.addKeyframe(0,zc(u),a),this._trackKeys.push(s)}l.addKeyframe(e,zc(t[s]),a)}return this._maxTime=Math.max(this._maxTime,e),this},r.prototype.pause=function(){this._clip.pause(),this._paused=!0},r.prototype.resume=function(){this._clip.resume(),this._paused=!1},r.prototype.isPaused=function(){return!!this._paused},r.prototype.duration=function(e){return this._maxTime=e,this._force=!0,this},r.prototype._doneCallback=function(){this._setTracksFinished(),this._clip=null;var e=this._doneCbs;if(e)for(var t=e.length,n=0;n<t;n++)e[n].call(this)},r.prototype._abortedCallback=function(){this._setTracksFinished();var e=this.animation,t=this._abortedCbs;if(e&&e.removeClip(this._clip),this._clip=null,t)for(var n=0;n<t.length;n++)t[n].call(this)},r.prototype._setTracksFinished=function(){for(var e=this._tracks,t=this._trackKeys,n=0;n<t.length;n++)e[t[n]].setFinished()},r.prototype._getAdditiveTrack=function(e){var t,n=this._additiveAnimators;if(n)for(var a=0;a<n.length;a++){var i=n[a].getTrack(e);i&&(t=i)}return t},r.prototype.start=function(e){if(!(this._started>0)){this._started=1;for(var t=this,n=[],a=this._maxTime||0,i=0;i<this._trackKeys.length;i++){var o=this._trackKeys[i],s=this._tracks[o],l=this._getAdditiveTrack(o),u=s.keyframes,c=u.length;if(s.prepare(a,l),s.needsAnimate())if(!this._allowDiscrete&&s.discrete){var f=u[c-1];f&&(t._target[s.propName]=f.rawValue),s.setFinished()}else n.push(s)}if(n.length||this._force){var h=new qV({life:a,loop:this._loop,delay:this._delay||0,onframe:function(v){t._started=2;var d=t._additiveAnimators;if(d){for(var p=!1,g=0;g<d.length;g++)if(d[g]._clip){p=!0;break}p||(t._additiveAnimators=null)}for(var g=0;g<n.length;g++)n[g].step(t._target,v);var y=t._onframeCbs;if(y)for(var g=0;g<y.length;g++)y[g](t._target,v)},ondestroy:function(){t._doneCallback()}});this._clip=h,this.animation&&this.animation.addClip(h),e&&h.setEasing(e)}else this._doneCallback();return this}},r.prototype.stop=function(e){if(!!this._clip){var t=this._clip;e&&t.onframe(1),this._abortedCallback()}},r.prototype.delay=function(e){return this._delay=e,this},r.prototype.during=function(e){return e&&(this._onframeCbs||(this._onframeCbs=[]),this._onframeCbs.push(e)),this},r.prototype.done=function(e){return e&&(this._doneCbs||(this._doneCbs=[]),this._doneCbs.push(e)),this},r.prototype.aborted=function(e){return e&&(this._abortedCbs||(this._abortedCbs=[]),this._abortedCbs.push(e)),this},r.prototype.getClip=function(){return this._clip},r.prototype.getTrack=function(e){return this._tracks[e]},r.prototype.getTracks=function(){var e=this;return K(this._trackKeys,function(t){return e._tracks[t]})},r.prototype.stopTracks=function(e,t){if(!e.length||!this._clip)return!0;for(var n=this._tracks,a=this._trackKeys,i=0;i<e.length;i++){var o=n[e[i]];o&&!o.isFinished()&&(t?o.step(this._target,1):this._started===1&&o.step(this._target,0),o.setFinished())}for(var s=!0,i=0;i<a.length;i++)if(!n[a[i]].isFinished()){s=!1;break}return s&&this._abortedCallback(),s},r.prototype.saveTo=function(e,t,n){if(!!e){t=t||this._trackKeys;for(var a=0;a<t.length;a++){var i=t[a],o=this._tracks[i];if(!(!o||o.isFinished())){var s=o.keyframes,l=s[n?0:s.length-1];l&&(e[i]=zc(l.rawValue))}}}},r.prototype.__changeFinalValue=function(e,t){t=t||Fe(e);for(var n=0;n<t.length;n++){var a=t[n],i=this._tracks[a];if(!!i){var o=i.keyframes;if(o.length>1){var s=o.pop();i.addKeyframe(s.time,e[a]),i.prepare(this._maxTime,i.getAdditiveTrack())}}}},r}(),i0=mH;function Bl(){return new Date().getTime()}var _H=function(r){xt(e,r);function e(t){var n=r.call(this)||this;return n._running=!1,n._time=0,n._pausedTime=0,n._pauseStart=0,n._paused=!1,t=t||{},n.stage=t.stage||{},n}return e.prototype.addClip=function(t){t.animation&&this.removeClip(t),this._head?(this._tail.next=t,t.prev=this._tail,t.next=null,this._tail=t):this._head=this._tail=t,t.animation=this},e.prototype.addAnimator=function(t){t.animation=this;var n=t.getClip();n&&this.addClip(n)},e.prototype.removeClip=function(t){if(!!t.animation){var n=t.prev,a=t.next;n?n.next=a:this._head=a,a?a.prev=n:this._tail=n,t.next=t.prev=t.animation=null}},e.prototype.removeAnimator=function(t){var n=t.getClip();n&&this.removeClip(n),t.animation=null},e.prototype.update=function(t){for(var n=Bl()-this._pausedTime,a=n-this._time,i=this._head;i;){var o=i.next,s=i.step(n,a);s&&(i.ondestroy(),this.removeClip(i)),i=o}this._time=n,t||(this.trigger("frame",a),this.stage.update&&this.stage.update())},e.prototype._startLoop=function(){var t=this;this._running=!0;function n(){t._running&&($m(n),!t._paused&&t.update())}$m(n)},e.prototype.start=function(){this._running||(this._time=Bl(),this._pausedTime=0,this._startLoop())},e.prototype.stop=function(){this._running=!1},e.prototype.pause=function(){this._paused||(this._pauseStart=Bl(),this._paused=!0)},e.prototype.resume=function(){this._paused&&(this._pausedTime+=Bl()-this._pauseStart,this._paused=!1)},e.prototype.clear=function(){for(var t=this._head;t;){var n=t.next;t.prev=t.next=t.animation=null,t=n}this._head=this._tail=null},e.prototype.isFinished=function(){return this._head==null},e.prototype.animate=function(t,n){n=n||{},this.start();var a=new i0(t,n.loop);return this.addAnimator(a),a},e}(zn),bH=_H,MH=300,o0=$e.domSupported,s0=function(){var r=["click","dblclick","mousewheel","wheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],e=["touchstart","touchend","touchmove"],t={pointerdown:1,pointerup:1,pointermove:1,pointerout:1},n=K(r,function(a){var i=a.replace("mouse","pointer");return t.hasOwnProperty(i)?i:a});return{mouse:r,touch:e,pointer:n}}(),OI={mouse:["mousemove","mouseup"],pointer:["pointermove","pointerup"]},PI=!1;function l0(r){var e=r.pointerType;return e==="pen"||e==="touch"}function xH(r){r.touching=!0,r.touchTimer!=null&&(clearTimeout(r.touchTimer),r.touchTimer=null),r.touchTimer=setTimeout(function(){r.touching=!1,r.touchTimer=null},700)}function u0(r){r&&(r.zrByTouch=!0)}function wH(r,e){return kn(r.dom,new DH(r,e),!0)}function zI(r,e){for(var t=e,n=!1;t&&t.nodeType!==9&&!(n=t.domBelongToZr||t!==e&&t===r.painterRoot);)t=t.parentNode;return n}var DH=function(){function r(e,t){this.stopPropagation=Ot,this.stopImmediatePropagation=Ot,this.preventDefault=Ot,this.type=t.type,this.target=this.currentTarget=e.dom,this.pointerType=t.pointerType,this.clientX=t.clientX,this.clientY=t.clientY}return r}(),ha={mousedown:function(r){r=kn(this.dom,r),this.__mayPointerCapture=[r.zrX,r.zrY],this.trigger("mousedown",r)},mousemove:function(r){r=kn(this.dom,r);var e=this.__mayPointerCapture;e&&(r.zrX!==e[0]||r.zrY!==e[1])&&this.__togglePointerCapture(!0),this.trigger("mousemove",r)},mouseup:function(r){r=kn(this.dom,r),this.__togglePointerCapture(!1),this.trigger("mouseup",r)},mouseout:function(r){r=kn(this.dom,r);var e=r.toElement||r.relatedTarget;zI(this,e)||(this.__pointerCapturing&&(r.zrEventControl="no_globalout"),this.trigger("mouseout",r))},wheel:function(r){PI=!0,r=kn(this.dom,r),this.trigger("mousewheel",r)},mousewheel:function(r){PI||(r=kn(this.dom,r),this.trigger("mousewheel",r))},touchstart:function(r){r=kn(this.dom,r),u0(r),this.__lastTouchMoment=new Date,this.handler.processGesture(r,"start"),ha.mousemove.call(this,r),ha.mousedown.call(this,r)},touchmove:function(r){r=kn(this.dom,r),u0(r),this.handler.processGesture(r,"change"),ha.mousemove.call(this,r)},touchend:function(r){r=kn(this.dom,r),u0(r),this.handler.processGesture(r,"end"),ha.mouseup.call(this,r),+new Date-+this.__lastTouchMoment<MH&&ha.click.call(this,r)},pointerdown:function(r){ha.mousedown.call(this,r)},pointermove:function(r){l0(r)||ha.mousemove.call(this,r)},pointerup:function(r){ha.mouseup.call(this,r)},pointerout:function(r){l0(r)||ha.mouseout.call(this,r)}};C(["click","dblclick","contextmenu"],function(r){ha[r]=function(e){e=kn(this.dom,e),this.trigger(r,e)}});var c0={pointermove:function(r){l0(r)||c0.mousemove.call(this,r)},pointerup:function(r){c0.mouseup.call(this,r)},mousemove:function(r){this.trigger("mousemove",r)},mouseup:function(r){var e=this.__pointerCapturing;this.__togglePointerCapture(!1),this.trigger("mouseup",r),e&&(r.zrEventControl="only_globalout",this.trigger("mouseout",r))}};function SH(r,e){var t=e.domHandlers;$e.pointerEventsSupported?C(s0.pointer,function(n){qv(e,n,function(a){t[n].call(r,a)})}):($e.touchEventsSupported&&C(s0.touch,function(n){qv(e,n,function(a){t[n].call(r,a),xH(e)})}),C(s0.mouse,function(n){qv(e,n,function(a){a=jm(a),e.touching||t[n].call(r,a)})}))}function IH(r,e){$e.pointerEventsSupported?C(OI.pointer,t):$e.touchEventsSupported||C(OI.mouse,t);function t(n){function a(i){i=jm(i),zI(r,i.target)||(i=wH(r,i),e.domHandlers[n].call(r,i))}qv(e,n,a,{capture:!0})}}function qv(r,e,t,n){r.mounted[e]=t,r.listenerOpts[e]=n,Bm(r.domTarget,e,t,n)}function f0(r){var e=r.mounted;for(var t in e)e.hasOwnProperty(t)&&AV(r.domTarget,t,e[t],r.listenerOpts[t]);r.mounted={}}var kI=function(){function r(e,t){this.mounted={},this.listenerOpts={},this.touching=!1,this.domTarget=e,this.domHandlers=t}return r}(),TH=function(r){xt(e,r);function e(t,n){var a=r.call(this)||this;return a.__pointerCapturing=!1,a.dom=t,a.painterRoot=n,a._localHandlerScope=new kI(t,ha),o0&&(a._globalHandlerScope=new kI(document,c0)),SH(a,a._localHandlerScope),a}return e.prototype.dispose=function(){f0(this._localHandlerScope),o0&&f0(this._globalHandlerScope)},e.prototype.setCursor=function(t){this.dom.style&&(this.dom.style.cursor=t||"default")},e.prototype.__togglePointerCapture=function(t){if(this.__mayPointerCapture=null,o0&&+this.__pointerCapturing^+t){this.__pointerCapturing=t;var n=this._globalHandlerScope;t?IH(this,n):f0(n)}},e}(zn),AH=TH,RI=1;$e.hasGlobalWindow&&(RI=Math.max(window.devicePixelRatio||window.screen&&window.screen.deviceXDPI/window.screen.logicalXDPI||1,1));var Xv=RI,h0=.4,v0="#333",d0="#ccc",CH="#eee",jI=xc,BI=5e-5;function es(r){return r>BI||r<-BI}var ts=[],Fl=[],p0=yn(),g0=Math.abs,NH=function(){function r(){}return r.prototype.getLocalTransform=function(e){return r.getLocalTransform(this,e)},r.prototype.setPosition=function(e){this.x=e[0],this.y=e[1]},r.prototype.setScale=function(e){this.scaleX=e[0],this.scaleY=e[1]},r.prototype.setSkew=function(e){this.skewX=e[0],this.skewY=e[1]},r.prototype.setOrigin=function(e){this.originX=e[0],this.originY=e[1]},r.prototype.needLocalTransform=function(){return es(this.rotation)||es(this.x)||es(this.y)||es(this.scaleX-1)||es(this.scaleY-1)||es(this.skewX)||es(this.skewY)},r.prototype.updateTransform=function(){var e=this.parent&&this.parent.transform,t=this.needLocalTransform(),n=this.transform;if(!(t||e)){n&&jI(n);return}n=n||yn(),t?this.getLocalTransform(n):jI(n),e&&(t?Pa(n,e,n):Nv(n,e)),this.transform=n,this._resolveGlobalScaleRatio(n)},r.prototype._resolveGlobalScaleRatio=function(e){var t=this.globalScaleRatio;if(t!=null&&t!==1){this.getGlobalScale(ts);var n=ts[0]<0?-1:1,a=ts[1]<0?-1:1,i=((ts[0]-n)*t+n)/ts[0]||0,o=((ts[1]-a)*t+a)/ts[1]||0;e[0]*=i,e[1]*=i,e[2]*=o,e[3]*=o}this.invTransform=this.invTransform||yn(),Qo(this.invTransform,e)},r.prototype.getComputedTransform=function(){for(var e=this,t=[];e;)t.push(e),e=e.parent;for(;e=t.pop();)e.updateTransform();return this.transform},r.prototype.setLocalTransform=function(e){if(!!e){var t=e[0]*e[0]+e[1]*e[1],n=e[2]*e[2]+e[3]*e[3],a=Math.atan2(e[1],e[0]),i=Math.PI/2+a-Math.atan2(e[3],e[2]);n=Math.sqrt(n)*Math.cos(i),t=Math.sqrt(t),this.skewX=i,this.skewY=0,this.rotation=-a,this.x=+e[4],this.y=+e[5],this.scaleX=t,this.scaleY=n,this.originX=0,this.originY=0}},r.prototype.decomposeTransform=function(){if(!!this.transform){var e=this.parent,t=this.transform;e&&e.transform&&(Pa(Fl,e.invTransform,t),t=Fl);var n=this.originX,a=this.originY;(n||a)&&(p0[4]=n,p0[5]=a,Pa(Fl,t,p0),Fl[4]-=n,Fl[5]-=a,t=Fl),this.setLocalTransform(t)}},r.prototype.getGlobalScale=function(e){var t=this.transform;return e=e||[],t?(e[0]=Math.sqrt(t[0]*t[0]+t[1]*t[1]),e[1]=Math.sqrt(t[2]*t[2]+t[3]*t[3]),t[0]<0&&(e[0]=-e[0]),t[3]<0&&(e[1]=-e[1]),e):(e[0]=1,e[1]=1,e)},r.prototype.transformCoordToLocal=function(e,t){var n=[e,t],a=this.invTransform;return a&&vr(n,n,a),n},r.prototype.transformCoordToGlobal=function(e,t){var n=[e,t],a=this.transform;return a&&vr(n,n,a),n},r.prototype.getLineScale=function(){var e=this.transform;return e&&g0(e[0]-1)>1e-10&&g0(e[3]-1)>1e-10?Math.sqrt(g0(e[0]*e[3]-e[2]*e[1])):1},r.prototype.copyTransform=function(e){FI(this,e)},r.getLocalTransform=function(e,t){t=t||[];var n=e.originX||0,a=e.originY||0,i=e.scaleX,o=e.scaleY,s=e.anchorX,l=e.anchorY,u=e.rotation||0,c=e.x,f=e.y,h=e.skewX?Math.tan(e.skewX):0,v=e.skewY?Math.tan(-e.skewY):0;if(n||a||s||l){var d=n+s,p=a+l;t[4]=-d*i-h*p*o,t[5]=-p*o-v*d*i}else t[4]=t[5]=0;return t[0]=i,t[3]=o,t[1]=v*i,t[2]=h*o,u&&Zi(t,t,u),t[4]+=n+c,t[5]+=a+f,t},r.initDefaultProps=function(){var e=r.prototype;e.scaleX=e.scaleY=e.globalScaleRatio=1,e.x=e.y=e.originX=e.originY=e.skewX=e.skewY=e.rotation=e.anchorX=e.anchorY=0}(),r}(),ka=["x","y","originX","originY","anchorX","anchorY","rotation","scaleX","scaleY","skewX","skewY"];function FI(r,e){for(var t=0;t<ka.length;t++){var n=ka[t];r[n]=e[n]}}var di=NH,VI={};function _n(r,e){e=e||$i;var t=VI[e];t||(t=VI[e]=new Cc(500));var n=t.get(r);return n==null&&(n=la.measureText(r,e).width,t.put(r,n)),n}function HI(r,e,t,n){var a=_n(r,e),i=Jv(e),o=Bc(0,a,t),s=Vl(0,i,n),l=new Pe(o,s,a,i);return l}function jc(r,e,t,n){var a=((r||"")+"").split(`
|
|
215
|
+
`),i=a.length;if(i===1)return HI(a[0],e,t,n);for(var o=new Pe(0,0,0,0),s=0;s<a.length;s++){var l=HI(a[s],e,t,n);s===0?o.copy(l):o.union(l)}return o}function Bc(r,e,t){return t==="right"?r-=e:t==="center"&&(r-=e/2),r}function Vl(r,e,t){return t==="middle"?r-=e/2:t==="bottom"&&(r-=e),r}function Jv(r){return _n("\u56FD",r)}function va(r,e){return typeof r=="string"?r.lastIndexOf("%")>=0?parseFloat(r)/100*e:parseFloat(r):r}function Kv(r,e,t){var n=e.position||"inside",a=e.distance!=null?e.distance:5,i=t.height,o=t.width,s=i/2,l=t.x,u=t.y,c="left",f="top";if(n instanceof Array)l+=va(n[0],t.width),u+=va(n[1],t.height),c=null,f=null;else switch(n){case"left":l-=a,u+=s,c="right",f="middle";break;case"right":l+=a+o,u+=s,f="middle";break;case"top":l+=o/2,u-=a,c="center",f="bottom";break;case"bottom":l+=o/2,u+=i+a,c="center";break;case"inside":l+=o/2,u+=s,c="center",f="middle";break;case"insideLeft":l+=a,u+=s,f="middle";break;case"insideRight":l+=o-a,u+=s,c="right",f="middle";break;case"insideTop":l+=o/2,u+=a,c="center";break;case"insideBottom":l+=o/2,u+=i-a,c="center",f="bottom";break;case"insideTopLeft":l+=a,u+=a;break;case"insideTopRight":l+=o-a,u+=a,c="right";break;case"insideBottomLeft":l+=a,u+=i-a,f="bottom";break;case"insideBottomRight":l+=o-a,u+=i-a,c="right",f="bottom";break}return r=r||{},r.x=l,r.y=u,r.align=c,r.verticalAlign=f,r}var y0="__zr_normal__",m0=ka.concat(["ignore"]),LH=On(ka,function(r,e){return r[e]=!0,r},{ignore:!1}),Hl={},EH=new Pe(0,0,0,0),_0=function(){function r(e){this.id=Im(),this.animators=[],this.currentStates=[],this.states={},this._init(e)}return r.prototype._init=function(e){this.attr(e)},r.prototype.drift=function(e,t,n){switch(this.draggable){case"horizontal":t=0;break;case"vertical":e=0;break}var a=this.transform;a||(a=this.transform=[1,0,0,1,0,0]),a[4]+=e,a[5]+=t,this.decomposeTransform(),this.markRedraw()},r.prototype.beforeUpdate=function(){},r.prototype.afterUpdate=function(){},r.prototype.update=function(){this.updateTransform(),this.__dirty&&this.updateInnerText()},r.prototype.updateInnerText=function(e){var t=this._textContent;if(t&&(!t.ignore||e)){this.textConfig||(this.textConfig={});var n=this.textConfig,a=n.local,i=t.innerTransformable,o=void 0,s=void 0,l=!1;i.parent=a?this:null;var u=!1;if(i.copyTransform(t),n.position!=null){var c=EH;n.layoutRect?c.copy(n.layoutRect):c.copy(this.getBoundingRect()),a||c.applyTransform(this.transform),this.calculateTextPosition?this.calculateTextPosition(Hl,n,c):Kv(Hl,n,c),i.x=Hl.x,i.y=Hl.y,o=Hl.align,s=Hl.verticalAlign;var f=n.origin;if(f&&n.rotation!=null){var h=void 0,v=void 0;f==="center"?(h=c.width*.5,v=c.height*.5):(h=va(f[0],c.width),v=va(f[1],c.height)),u=!0,i.originX=-i.x+h+(a?0:c.x),i.originY=-i.y+v+(a?0:c.y)}}n.rotation!=null&&(i.rotation=n.rotation);var d=n.offset;d&&(i.x+=d[0],i.y+=d[1],u||(i.originX=-d[0],i.originY=-d[1]));var p=n.inside==null?typeof n.position=="string"&&n.position.indexOf("inside")>=0:n.inside,g=this._innerTextDefaultStyle||(this._innerTextDefaultStyle={}),y=void 0,m=void 0,_=void 0;p&&this.canBeInsideText()?(y=n.insideFill,m=n.insideStroke,(y==null||y==="auto")&&(y=this.getInsideTextFill()),(m==null||m==="auto")&&(m=this.getInsideTextStroke(y),_=!0)):(y=n.outsideFill,m=n.outsideStroke,(y==null||y==="auto")&&(y=this.getOutsideFill()),(m==null||m==="auto")&&(m=this.getOutsideStroke(y),_=!0)),y=y||"#000",(y!==g.fill||m!==g.stroke||_!==g.autoStroke||o!==g.align||s!==g.verticalAlign)&&(l=!0,g.fill=y,g.stroke=m,g.autoStroke=_,g.align=o,g.verticalAlign=s,t.setDefaultTextStyle(g)),t.__dirty|=mn,l&&t.dirtyStyle(!0)}},r.prototype.canBeInsideText=function(){return!0},r.prototype.getInsideTextFill=function(){return"#fff"},r.prototype.getInsideTextStroke=function(e){return"#000"},r.prototype.getOutsideFill=function(){return this.__zr&&this.__zr.isDarkMode()?d0:v0},r.prototype.getOutsideStroke=function(e){var t=this.__zr&&this.__zr.getBackgroundColor(),n=typeof t=="string"&&Ur(t);n||(n=[255,255,255,1]);for(var a=n[3],i=this.__zr.isDarkMode(),o=0;o<3;o++)n[o]=n[o]*a+(i?0:255)*(1-a);return n[3]=1,fa(n,"rgba")},r.prototype.traverse=function(e,t){},r.prototype.attrKV=function(e,t){e==="textConfig"?this.setTextConfig(t):e==="textContent"?this.setTextContent(t):e==="clipPath"?this.setClipPath(t):e==="extra"?(this.extra=this.extra||{},X(this.extra,t)):this[e]=t},r.prototype.hide=function(){this.ignore=!0,this.markRedraw()},r.prototype.show=function(){this.ignore=!1,this.markRedraw()},r.prototype.attr=function(e,t){if(typeof e=="string")this.attrKV(e,t);else if(_e(e))for(var n=e,a=Fe(n),i=0;i<a.length;i++){var o=a[i];this.attrKV(o,e[o])}return this.markRedraw(),this},r.prototype.saveCurrentToNormalState=function(e){this._innerSaveToNormal(e);for(var t=this._normalState,n=0;n<this.animators.length;n++){var a=this.animators[n],i=a.__fromStateTransition;if(!(a.getLoop()||i&&i!==y0)){var o=a.targetName,s=o?t[o]:t;a.saveTo(s)}}},r.prototype._innerSaveToNormal=function(e){var t=this._normalState;t||(t=this._normalState={}),e.textConfig&&!t.textConfig&&(t.textConfig=this.textConfig),this._savePrimaryToNormal(e,t,m0)},r.prototype._savePrimaryToNormal=function(e,t,n){for(var a=0;a<n.length;a++){var i=n[a];e[i]!=null&&!(i in t)&&(t[i]=this[i])}},r.prototype.hasState=function(){return this.currentStates.length>0},r.prototype.getState=function(e){return this.states[e]},r.prototype.ensureState=function(e){var t=this.states;return t[e]||(t[e]={}),t[e]},r.prototype.clearStates=function(e){this.useState(y0,!1,e)},r.prototype.useState=function(e,t,n,a){var i=e===y0,o=this.hasState();if(!(!o&&i)){var s=this.currentStates,l=this.stateTransition;if(!(ze(s,e)>=0&&(t||s.length===1))){var u;if(this.stateProxy&&!i&&(u=this.stateProxy(e)),u||(u=this.states&&this.states[e]),!u&&!i){wv("State "+e+" not exists.");return}i||this.saveCurrentToNormalState(u);var c=!!(u&&u.hoverLayer||a);c&&this._toggleHoverLayerFlag(!0),this._applyStateObj(e,u,this._normalState,t,!n&&!this.__inHover&&l&&l.duration>0,l);var f=this._textContent,h=this._textGuide;return f&&f.useState(e,t,n,c),h&&h.useState(e,t,n,c),i?(this.currentStates=[],this._normalState={}):t?this.currentStates.push(e):this.currentStates=[e],this._updateAnimationTargets(),this.markRedraw(),!c&&this.__inHover&&(this._toggleHoverLayerFlag(!1),this.__dirty&=~mn),u}}},r.prototype.useStates=function(e,t,n){if(!e.length)this.clearStates();else{var a=[],i=this.currentStates,o=e.length,s=o===i.length;if(s){for(var l=0;l<o;l++)if(e[l]!==i[l]){s=!1;break}}if(s)return;for(var l=0;l<o;l++){var u=e[l],c=void 0;this.stateProxy&&(c=this.stateProxy(u,e)),c||(c=this.states[u]),c&&a.push(c)}var f=a[o-1],h=!!(f&&f.hoverLayer||n);h&&this._toggleHoverLayerFlag(!0);var v=this._mergeStates(a),d=this.stateTransition;this.saveCurrentToNormalState(v),this._applyStateObj(e.join(","),v,this._normalState,!1,!t&&!this.__inHover&&d&&d.duration>0,d);var p=this._textContent,g=this._textGuide;p&&p.useStates(e,t,h),g&&g.useStates(e,t,h),this._updateAnimationTargets(),this.currentStates=e.slice(),this.markRedraw(),!h&&this.__inHover&&(this._toggleHoverLayerFlag(!1),this.__dirty&=~mn)}},r.prototype._updateAnimationTargets=function(){for(var e=0;e<this.animators.length;e++){var t=this.animators[e];t.targetName&&t.changeTarget(this[t.targetName])}},r.prototype.removeState=function(e){var t=ze(this.currentStates,e);if(t>=0){var n=this.currentStates.slice();n.splice(t,1),this.useStates(n)}},r.prototype.replaceState=function(e,t,n){var a=this.currentStates.slice(),i=ze(a,e),o=ze(a,t)>=0;i>=0?o?a.splice(i,1):a[i]=t:n&&!o&&a.push(t),this.useStates(a)},r.prototype.toggleState=function(e,t){t?this.useState(e,!0):this.removeState(e)},r.prototype._mergeStates=function(e){for(var t={},n,a=0;a<e.length;a++){var i=e[a];X(t,i),i.textConfig&&(n=n||{},X(n,i.textConfig))}return n&&(t.textConfig=n),t},r.prototype._applyStateObj=function(e,t,n,a,i,o){var s=!(t&&a);t&&t.textConfig?(this.textConfig=X({},a?this.textConfig:n.textConfig),X(this.textConfig,t.textConfig)):s&&n.textConfig&&(this.textConfig=n.textConfig);for(var l={},u=!1,c=0;c<m0.length;c++){var f=m0[c],h=i&&LH[f];t&&t[f]!=null?h?(u=!0,l[f]=t[f]):this[f]=t[f]:s&&n[f]!=null&&(h?(u=!0,l[f]=n[f]):this[f]=n[f])}if(!i)for(var c=0;c<this.animators.length;c++){var v=this.animators[c],d=v.targetName;v.getLoop()||v.__changeFinalValue(d?(t||n)[d]:t||n)}u&&this._transitionState(e,l,o)},r.prototype._attachComponent=function(e){if(!(e.__zr&&!e.__hostTarget)&&e!==this){var t=this.__zr;t&&e.addSelfToZr(t),e.__zr=t,e.__hostTarget=this}},r.prototype._detachComponent=function(e){e.__zr&&e.removeSelfFromZr(e.__zr),e.__zr=null,e.__hostTarget=null},r.prototype.getClipPath=function(){return this._clipPath},r.prototype.setClipPath=function(e){this._clipPath&&this._clipPath!==e&&this.removeClipPath(),this._attachComponent(e),this._clipPath=e,this.markRedraw()},r.prototype.removeClipPath=function(){var e=this._clipPath;e&&(this._detachComponent(e),this._clipPath=null,this.markRedraw())},r.prototype.getTextContent=function(){return this._textContent},r.prototype.setTextContent=function(e){var t=this._textContent;t!==e&&(t&&t!==e&&this.removeTextContent(),e.innerTransformable=new di,this._attachComponent(e),this._textContent=e,this.markRedraw())},r.prototype.setTextConfig=function(e){this.textConfig||(this.textConfig={}),X(this.textConfig,e),this.markRedraw()},r.prototype.removeTextConfig=function(){this.textConfig=null,this.markRedraw()},r.prototype.removeTextContent=function(){var e=this._textContent;e&&(e.innerTransformable=null,this._detachComponent(e),this._textContent=null,this._innerTextDefaultStyle=null,this.markRedraw())},r.prototype.getTextGuideLine=function(){return this._textGuide},r.prototype.setTextGuideLine=function(e){this._textGuide&&this._textGuide!==e&&this.removeTextGuideLine(),this._attachComponent(e),this._textGuide=e,this.markRedraw()},r.prototype.removeTextGuideLine=function(){var e=this._textGuide;e&&(this._detachComponent(e),this._textGuide=null,this.markRedraw())},r.prototype.markRedraw=function(){this.__dirty|=mn;var e=this.__zr;e&&(this.__inHover?e.refreshHover():e.refresh()),this.__hostTarget&&this.__hostTarget.markRedraw()},r.prototype.dirty=function(){this.markRedraw()},r.prototype._toggleHoverLayerFlag=function(e){this.__inHover=e;var t=this._textContent,n=this._textGuide;t&&(t.__inHover=e),n&&(n.__inHover=e)},r.prototype.addSelfToZr=function(e){if(this.__zr!==e){this.__zr=e;var t=this.animators;if(t)for(var n=0;n<t.length;n++)e.animation.addAnimator(t[n]);this._clipPath&&this._clipPath.addSelfToZr(e),this._textContent&&this._textContent.addSelfToZr(e),this._textGuide&&this._textGuide.addSelfToZr(e)}},r.prototype.removeSelfFromZr=function(e){if(!!this.__zr){this.__zr=null;var t=this.animators;if(t)for(var n=0;n<t.length;n++)e.animation.removeAnimator(t[n]);this._clipPath&&this._clipPath.removeSelfFromZr(e),this._textContent&&this._textContent.removeSelfFromZr(e),this._textGuide&&this._textGuide.removeSelfFromZr(e)}},r.prototype.animate=function(e,t,n){var a=e?this[e]:this,i=new i0(a,t,n);return e&&(i.targetName=e),this.addAnimator(i,e),i},r.prototype.addAnimator=function(e,t){var n=this.__zr,a=this;e.during(function(){a.updateDuringAnimation(t)}).done(function(){var i=a.animators,o=ze(i,e);o>=0&&i.splice(o,1)}),this.animators.push(e),n&&n.animation.addAnimator(e),n&&n.wakeUp()},r.prototype.updateDuringAnimation=function(e){this.markRedraw()},r.prototype.stopAnimation=function(e,t){for(var n=this.animators,a=n.length,i=[],o=0;o<a;o++){var s=n[o];!e||e===s.scope?s.stop(t):i.push(s)}return this.animators=i,this},r.prototype.animateTo=function(e,t,n){b0(this,e,t,n)},r.prototype.animateFrom=function(e,t,n){b0(this,e,t,n,!0)},r.prototype._transitionState=function(e,t,n,a){for(var i=b0(this,t,n,a),o=0;o<i.length;o++)i[o].__fromStateTransition=e},r.prototype.getBoundingRect=function(){return null},r.prototype.getPaintRect=function(){return null},r.initDefaultProps=function(){var e=r.prototype;e.type="element",e.name="",e.ignore=e.silent=e.isGroup=e.draggable=e.dragging=e.ignoreClip=e.__inHover=!1,e.__dirty=mn;function t(n,a,i,o){Object.defineProperty(e,n,{get:function(){if(!this[a]){var l=this[a]=[];s(this,l)}return this[a]},set:function(l){this[i]=l[0],this[o]=l[1],this[a]=l,s(this,l)}});function s(l,u){Object.defineProperty(u,0,{get:function(){return l[i]},set:function(c){l[i]=c}}),Object.defineProperty(u,1,{get:function(){return l[o]},set:function(c){l[o]=c}})}}Object.defineProperty&&(t("position","_legacyPos","x","y"),t("scale","_legacyScale","scaleX","scaleY"),t("origin","_legacyOrigin","originX","originY"))}(),r}();Et(_0,zn),Et(_0,di);function b0(r,e,t,n,a){t=t||{};var i=[];WI(r,"",r,e,t,n,i,a);var o=i.length,s=!1,l=t.done,u=t.aborted,c=function(){s=!0,o--,o<=0&&(s?l&&l():u&&u())},f=function(){o--,o<=0&&(s?l&&l():u&&u())};o||l&&l(),i.length>0&&t.during&&i[0].during(function(d,p){t.during(p)});for(var h=0;h<i.length;h++){var v=i[h];c&&v.done(c),f&&v.aborted(f),t.force&&v.duration(t.duration),v.start(t.easing)}return i}function M0(r,e,t){for(var n=0;n<t;n++)r[n]=e[n]}function OH(r){return Mr(r[0])}function PH(r,e,t){if(Mr(e[t]))if(Mr(r[t])||(r[t]=[]),an(e[t])){var n=e[t].length;r[t].length!==n&&(r[t]=new e[t].constructor(n),M0(r[t],e[t],n))}else{var a=e[t],i=r[t],o=a.length;if(OH(a))for(var s=a[0].length,l=0;l<o;l++)i[l]?M0(i[l],a[l],s):i[l]=Array.prototype.slice.call(a[l]);else M0(i,a,o);i.length=a.length}else r[t]=e[t]}function zH(r,e){return r===e||Mr(r)&&Mr(e)&&kH(r,e)}function kH(r,e){var t=r.length;if(t!==e.length)return!1;for(var n=0;n<t;n++)if(r[n]!==e[n])return!1;return!0}function WI(r,e,t,n,a,i,o,s){for(var l=Fe(n),u=a.duration,c=a.delay,f=a.additive,h=a.setToFinal,v=!_e(i),d=r.animators,p=[],g=0;g<l.length;g++){var y=l[g],m=n[y];if(m!=null&&t[y]!=null&&(v||i[y]))if(_e(m)&&!Mr(m)&&!dc(m)){if(e){s||(t[y]=m,r.updateDuringAnimation(e));continue}WI(r,y,t[y],m,a,i&&i[y],o,s)}else p.push(y);else s||(t[y]=m,r.updateDuringAnimation(e),p.push(y))}var _=p.length;if(!f&&_)for(var b=0;b<d.length;b++){var x=d[b];if(x.targetName===e){var M=x.stopTracks(p);if(M){var w=ze(d,x);d.splice(w,1)}}}if(a.force||(p=ot(p,function(A){return!zH(n[A],t[A])}),_=p.length),_>0||a.force&&!o.length){var D=void 0,T=void 0,I=void 0;if(s){T={},h&&(D={});for(var b=0;b<_;b++){var y=p[b];T[y]=t[y],h?D[y]=n[y]:t[y]=n[y]}}else if(h){I={};for(var b=0;b<_;b++){var y=p[b];I[y]=zc(t[y]),PH(t,n,y)}}var x=new i0(t,!1,!1,f?ot(d,function(N){return N.targetName===e}):null);x.targetName=e,a.scope&&(x.scope=a.scope),h&&D&&x.whenWithKeys(0,D,p),I&&x.whenWithKeys(0,I,p),x.whenWithKeys(u==null?500:u,s?T:n,p).delay(c||0),r.addAnimator(x,e),o.push(x)}}var GI=_0,$I=function(r){xt(e,r);function e(t){var n=r.call(this)||this;return n.isGroup=!0,n._children=[],n.attr(t),n}return e.prototype.childrenRef=function(){return this._children},e.prototype.children=function(){return this._children.slice()},e.prototype.childAt=function(t){return this._children[t]},e.prototype.childOfName=function(t){for(var n=this._children,a=0;a<n.length;a++)if(n[a].name===t)return n[a]},e.prototype.childCount=function(){return this._children.length},e.prototype.add=function(t){return t&&t!==this&&t.parent!==this&&(this._children.push(t),this._doAdd(t)),this},e.prototype.addBefore=function(t,n){if(t&&t!==this&&t.parent!==this&&n&&n.parent===this){var a=this._children,i=a.indexOf(n);i>=0&&(a.splice(i,0,t),this._doAdd(t))}return this},e.prototype.replace=function(t,n){var a=ze(this._children,t);return a>=0&&this.replaceAt(n,a),this},e.prototype.replaceAt=function(t,n){var a=this._children,i=a[n];if(t&&t!==this&&t.parent!==this&&t!==i){a[n]=t,i.parent=null;var o=this.__zr;o&&i.removeSelfFromZr(o),this._doAdd(t)}return this},e.prototype._doAdd=function(t){t.parent&&t.parent.remove(t),t.parent=this;var n=this.__zr;n&&n!==t.__zr&&t.addSelfToZr(n),n&&n.refresh()},e.prototype.remove=function(t){var n=this.__zr,a=this._children,i=ze(a,t);return i<0?this:(a.splice(i,1),t.parent=null,n&&t.removeSelfFromZr(n),n&&n.refresh(),this)},e.prototype.removeAll=function(){for(var t=this._children,n=this.__zr,a=0;a<t.length;a++){var i=t[a];n&&i.removeSelfFromZr(n),i.parent=null}return t.length=0,this},e.prototype.eachChild=function(t,n){for(var a=this._children,i=0;i<a.length;i++){var o=a[i];t.call(n,o,i)}return this},e.prototype.traverse=function(t,n){for(var a=0;a<this._children.length;a++){var i=this._children[a],o=t.call(n,i);i.isGroup&&!o&&i.traverse(t,n)}return this},e.prototype.addSelfToZr=function(t){r.prototype.addSelfToZr.call(this,t);for(var n=0;n<this._children.length;n++){var a=this._children[n];a.addSelfToZr(t)}},e.prototype.removeSelfFromZr=function(t){r.prototype.removeSelfFromZr.call(this,t);for(var n=0;n<this._children.length;n++){var a=this._children[n];a.removeSelfFromZr(t)}},e.prototype.getBoundingRect=function(t){for(var n=new Pe(0,0,0,0),a=t||this._children,i=[],o=null,s=0;s<a.length;s++){var l=a[s];if(!(l.ignore||l.invisible)){var u=l.getBoundingRect(),c=l.getLocalTransform(i);c?(Pe.applyTransform(n,u,c),o=o||n.clone(),o.union(n)):(o=o||u.clone(),o.union(u))}}return o||n},e}(GI);$I.prototype.type="group";var De=$I;/*!
|
|
216
|
+
* ZRender, a high performance 2d drawing library.
|
|
217
|
+
*
|
|
218
|
+
* Copyright (c) 2013, Baidu Inc.
|
|
219
|
+
* All rights reserved.
|
|
220
|
+
*
|
|
221
|
+
* LICENSE
|
|
222
|
+
* https://github.com/ecomfe/zrender/blob/master/LICENSE.txt
|
|
223
|
+
*/var ed={},rs={};function RH(r){delete rs[r]}function jH(r){if(!r)return!1;if(typeof r=="string")return Oc(r,1)<h0;if(r.colorStops){for(var e=r.colorStops,t=0,n=e.length,a=0;a<n;a++)t+=Oc(e[a].color,1);return t/=n,t<h0}return!1}var BH=function(){function r(e,t,n){var a=this;this._sleepAfterStill=10,this._stillFrameAccum=0,this._needsRefresh=!0,this._needsRefreshHover=!0,this._darkMode=!1,n=n||{},this.dom=t,this.id=e;var i=new GV,o=n.renderer||"canvas";ed[o]||(o=Fe(ed)[0]),n.useDirtyRect=n.useDirtyRect==null?!1:n.useDirtyRect;var s=new ed[o](t,i,n,e),l=n.ssr||s.ssrOnly;this.storage=i,this.painter=s;var u=!$e.node&&!$e.worker&&!l?new AH(s.getViewportRoot(),s.root):null,c=n.useCoarsePointer,f=c==null||c==="auto"?$e.touchEventsSupported:!!c,h=44,v;f&&(v=Ee(n.pointerSize,h)),this.handler=new BV(i,s,u,s.root,v),this.animation=new bH({stage:{update:l?null:function(){return a._flush(!0)}}}),l||this.animation.start()}return r.prototype.add=function(e){!e||(this.storage.addRoot(e),e.addSelfToZr(this),this.refresh())},r.prototype.remove=function(e){!e||(this.storage.delRoot(e),e.removeSelfFromZr(this),this.refresh())},r.prototype.configLayer=function(e,t){this.painter.configLayer&&this.painter.configLayer(e,t),this.refresh()},r.prototype.setBackgroundColor=function(e){this.painter.setBackgroundColor&&this.painter.setBackgroundColor(e),this.refresh(),this._backgroundColor=e,this._darkMode=jH(e)},r.prototype.getBackgroundColor=function(){return this._backgroundColor},r.prototype.setDarkMode=function(e){this._darkMode=e},r.prototype.isDarkMode=function(){return this._darkMode},r.prototype.refreshImmediately=function(e){e||this.animation.update(!0),this._needsRefresh=!1,this.painter.refresh(),this._needsRefresh=!1},r.prototype.refresh=function(){this._needsRefresh=!0,this.animation.start()},r.prototype.flush=function(){this._flush(!1)},r.prototype._flush=function(e){var t,n=Bl();this._needsRefresh&&(t=!0,this.refreshImmediately(e)),this._needsRefreshHover&&(t=!0,this.refreshHoverImmediately());var a=Bl();t?(this._stillFrameAccum=0,this.trigger("rendered",{elapsedTime:a-n})):this._sleepAfterStill>0&&(this._stillFrameAccum++,this._stillFrameAccum>this._sleepAfterStill&&this.animation.stop())},r.prototype.setSleepAfterStill=function(e){this._sleepAfterStill=e},r.prototype.wakeUp=function(){this.animation.start(),this._stillFrameAccum=0},r.prototype.refreshHover=function(){this._needsRefreshHover=!0},r.prototype.refreshHoverImmediately=function(){this._needsRefreshHover=!1,this.painter.refreshHover&&this.painter.getType()==="canvas"&&this.painter.refreshHover()},r.prototype.resize=function(e){e=e||{},this.painter.resize(e.width,e.height),this.handler.resize()},r.prototype.clearAnimation=function(){this.animation.clear()},r.prototype.getWidth=function(){return this.painter.getWidth()},r.prototype.getHeight=function(){return this.painter.getHeight()},r.prototype.setCursorStyle=function(e){this.handler.setCursorStyle(e)},r.prototype.findHover=function(e,t){return this.handler.findHover(e,t)},r.prototype.on=function(e,t,n){return this.handler.on(e,t,n),this},r.prototype.off=function(e,t){this.handler.off(e,t)},r.prototype.trigger=function(e,t){this.handler.trigger(e,t)},r.prototype.clear=function(){for(var e=this.storage.getRoots(),t=0;t<e.length;t++)e[t]instanceof De&&e[t].removeSelfFromZr(this);this.storage.delAllRoots(),this.painter.clear()},r.prototype.dispose=function(){this.animation.stop(),this.clear(),this.storage.dispose(),this.painter.dispose(),this.handler.dispose(),this.animation=this.storage=this.painter=this.handler=null,RH(this.id)},r}();function x0(r,e){var t=new BH(Im(),r,e);return rs[t.id]=t,t}function FH(r){r.dispose()}function VH(){for(var r in rs)rs.hasOwnProperty(r)&&rs[r].dispose();rs={}}function HH(r){return rs[r]}function UI(r,e){ed[r]=e}var WH="5.4.1",GH=Object.freeze(Object.defineProperty({__proto__:null,init:x0,dispose:FH,disposeAll:VH,getInstance:HH,registerPainter:UI,version:WH},Symbol.toStringTag,{value:"Module"})),YI=1e-4,QI=20;function $H(r){return r.replace(/^\s+|\s+$/g,"")}function st(r,e,t,n){var a=e[0],i=e[1],o=t[0],s=t[1],l=i-a,u=s-o;if(l===0)return u===0?o:(o+s)/2;if(n)if(l>0){if(r<=a)return o;if(r>=i)return s}else{if(r>=a)return o;if(r<=i)return s}else{if(r===a)return o;if(r===i)return s}return(r-a)/l*u+o}function ue(r,e){switch(r){case"center":case"middle":r="50%";break;case"left":case"top":r="0%";break;case"right":case"bottom":r="100%";break}return ce(r)?$H(r).match(/%$/)?parseFloat(r)/100*e:parseFloat(r):r==null?NaN:+r}function Nt(r,e,t){return e==null&&(e=10),e=Math.min(Math.max(0,e),QI),r=(+r).toFixed(e),t?r:+r}function bn(r){return r.sort(function(e,t){return e-t}),r}function da(r){if(r=+r,isNaN(r))return 0;if(r>1e-14){for(var e=1,t=0;t<15;t++,e*=10)if(Math.round(r*e)/e===r)return t}return ZI(r)}function ZI(r){var e=r.toString().toLowerCase(),t=e.indexOf("e"),n=t>0?+e.slice(t+1):0,a=t>0?t:e.length,i=e.indexOf("."),o=i<0?0:a-1-i;return Math.max(0,o-n)}function w0(r,e){var t=Math.log,n=Math.LN10,a=Math.floor(t(r[1]-r[0])/n),i=Math.round(t(Math.abs(e[1]-e[0]))/n),o=Math.min(Math.max(-a+i,0),20);return isFinite(o)?o:20}function UH(r,e,t){if(!r[e])return 0;var n=qI(r,t);return n[e]||0}function qI(r,e){var t=On(r,function(v,d){return v+(isNaN(d)?0:d)},0);if(t===0)return[];for(var n=Math.pow(10,e),a=K(r,function(v){return(isNaN(v)?0:v)/t*n*100}),i=n*100,o=K(a,function(v){return Math.floor(v)}),s=On(o,function(v,d){return v+d},0),l=K(a,function(v,d){return v-o[d]});s<i;){for(var u=Number.NEGATIVE_INFINITY,c=null,f=0,h=l.length;f<h;++f)l[f]>u&&(u=l[f],c=f);++o[c],l[c]=0,++s}return K(o,function(v){return v/n})}function YH(r,e){var t=Math.max(da(r),da(e)),n=r+e;return t>QI?n:Nt(n,t)}var D0=9007199254740991;function S0(r){var e=Math.PI*2;return(r%e+e)%e}function Fc(r){return r>-YI&&r<YI}var QH=/^(?:(\d{4})(?:[-\/](\d{1,2})(?:[-\/](\d{1,2})(?:[T ](\d{1,2})(?::(\d{1,2})(?::(\d{1,2})(?:[.,](\d+))?)?)?(Z|[\+\-]\d\d:?\d\d)?)?)?)?)?$/;function Mn(r){if(r instanceof Date)return r;if(ce(r)){var e=QH.exec(r);if(!e)return new Date(NaN);if(e[8]){var t=+e[4]||0;return e[8].toUpperCase()!=="Z"&&(t-=+e[8].slice(0,3)),new Date(Date.UTC(+e[1],+(e[2]||1)-1,+e[3]||1,t,+(e[5]||0),+e[6]||0,e[7]?+e[7].substring(0,3):0))}else return new Date(+e[1],+(e[2]||1)-1,+e[3]||1,+e[4]||0,+(e[5]||0),+e[6]||0,e[7]?+e[7].substring(0,3):0)}else if(r==null)return new Date(NaN);return new Date(Math.round(r))}function XI(r){return Math.pow(10,td(r))}function td(r){if(r===0)return 0;var e=Math.floor(Math.log(r)/Math.LN10);return r/Math.pow(10,e)>=10&&e++,e}function I0(r,e){var t=td(r),n=Math.pow(10,t),a=r/n,i;return e?a<1.5?i=1:a<2.5?i=2:a<4?i=3:a<7?i=5:i=10:a<1?i=1:a<2?i=2:a<3?i=3:a<5?i=5:i=10,r=i*n,t>=-20?+r.toFixed(t<0?-t:0):r}function rd(r,e){var t=(r.length-1)*e+1,n=Math.floor(t),a=+r[n-1],i=t-n;return i?a+i*(r[n]-a):a}function T0(r){r.sort(function(l,u){return s(l,u,0)?-1:1});for(var e=-1/0,t=1,n=0;n<r.length;){for(var a=r[n].interval,i=r[n].close,o=0;o<2;o++)a[o]<=e&&(a[o]=e,i[o]=o?1:1-t),e=a[o],t=i[o];a[0]===a[1]&&i[0]*i[1]!==1?r.splice(n,1):n++}return r;function s(l,u,c){return l.interval[c]<u.interval[c]||l.interval[c]===u.interval[c]&&(l.close[c]-u.close[c]===(c?-1:1)||!c&&s(l,u,1))}}function Ra(r){var e=parseFloat(r);return e==r&&(e!==0||!ce(r)||r.indexOf("x")<=0)?e:NaN}function A0(r){return!isNaN(Ra(r))}function JI(){return Math.round(Math.random()*9)}function KI(r,e){return e===0?r:KI(e,r%e)}function eT(r,e){return r==null?e:e==null?r:r*e/KI(r,e)}var ZH="[ECharts] ",tT={},qH=typeof console!="undefined"&&console.warn&&console.log;function XH(r,e,t){if(qH){if(t){if(tT[e])return;tT[e]=!0}console[r](ZH+e)}}function Cpe(r,e){XH("warn",r,e)}function at(r){throw new Error(r)}function rT(r,e,t){return(e-r)*t+r}var nT="series\0",aT="\0_ec_\0";function ct(r){return r instanceof Array?r:r==null?[]:[r]}function ns(r,e,t){if(r){r[e]=r[e]||{},r.emphasis=r.emphasis||{},r.emphasis[e]=r.emphasis[e]||{};for(var n=0,a=t.length;n<a;n++){var i=t[n];!r.emphasis[e].hasOwnProperty(i)&&r[e].hasOwnProperty(i)&&(r.emphasis[e][i]=r[e][i])}}}var iT=["fontStyle","fontWeight","fontSize","fontFamily","rich","tag","color","textBorderColor","textBorderWidth","width","height","lineHeight","align","verticalAlign","baseline","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY","textShadowColor","textShadowBlur","textShadowOffsetX","textShadowOffsetY","backgroundColor","borderColor","borderWidth","borderRadius","padding"];function Wl(r){return _e(r)&&!J(r)&&!(r instanceof Date)?r.value:r}function JH(r){return _e(r)&&!(r instanceof Array)}function oT(r,e,t){var n=t==="normalMerge",a=t==="replaceMerge",i=t==="replaceAll";r=r||[],e=(e||[]).slice();var o=ge();C(e,function(l,u){if(!_e(l)){e[u]=null;return}});var s=KH(r,o,t);return(n||a)&&eW(s,r,o,e),n&&tW(s,e),n||a?rW(s,e,a):i&&nW(s,e),aW(s),s}function KH(r,e,t){var n=[];if(t==="replaceAll")return n;for(var a=0;a<r.length;a++){var i=r[a];i&&i.id!=null&&e.set(i.id,a),n.push({existing:t==="replaceMerge"||Hc(i)?null:i,newOption:null,keyInfo:null,brandNew:null})}return n}function eW(r,e,t,n){C(n,function(a,i){if(!(!a||a.id==null)){var o=Vc(a.id),s=t.get(o);if(s!=null){var l=r[s];Er(!l.newOption,'Duplicated option on id "'+o+'".'),l.newOption=a,l.existing=e[s],n[i]=null}}})}function tW(r,e){C(e,function(t,n){if(!(!t||t.name==null))for(var a=0;a<r.length;a++){var i=r[a].existing;if(!r[a].newOption&&i&&(i.id==null||t.id==null)&&!Hc(t)&&!Hc(i)&&sT("name",i,t)){r[a].newOption=t,e[n]=null;return}}})}function rW(r,e,t){C(e,function(n){if(!!n){for(var a,i=0;(a=r[i])&&(a.newOption||Hc(a.existing)||a.existing&&n.id!=null&&!sT("id",n,a.existing));)i++;a?(a.newOption=n,a.brandNew=t):r.push({newOption:n,brandNew:t,existing:null,keyInfo:null}),i++}})}function nW(r,e){C(e,function(t){r.push({newOption:t,brandNew:!0,existing:null,keyInfo:null})})}function aW(r){var e=ge();C(r,function(t){var n=t.existing;n&&e.set(n.id,t)}),C(r,function(t){var n=t.newOption;Er(!n||n.id==null||!e.get(n.id)||e.get(n.id)===t,"id duplicates: "+(n&&n.id)),n&&n.id!=null&&e.set(n.id,t),!t.keyInfo&&(t.keyInfo={})}),C(r,function(t,n){var a=t.existing,i=t.newOption,o=t.keyInfo;if(!!_e(i)){if(o.name=i.name!=null?Vc(i.name):a?a.name:nT+n,a)o.id=Vc(a.id);else if(i.id!=null)o.id=Vc(i.id);else{var s=0;do o.id="\0"+o.name+"\0"+s++;while(e.get(o.id))}e.set(o.id,t)}})}function sT(r,e,t){var n=Kt(e[r],null),a=Kt(t[r],null);return n!=null&&a!=null&&n===a}function Vc(r){return Kt(r,"")}function Kt(r,e){return r==null?e:ce(r)?r:Ue(r)||Sv(r)?r+"":e}function C0(r){var e=r.name;return!!(e&&e.indexOf(nT))}function Hc(r){return r&&r.id!=null&&Vc(r.id).indexOf(aT)===0}function iW(r){return aT+r}function oW(r,e,t){C(r,function(n){var a=n.newOption;_e(a)&&(n.keyInfo.mainType=e,n.keyInfo.subType=sW(e,a,n.existing,t))})}function sW(r,e,t,n){var a=e.type?e.type:t?t.subType:n.determineSubType(r,e);return a}function lW(r,e){var t={},n={};return a(r||[],t),a(e||[],n,t),[i(t),i(n)];function a(o,s,l){for(var u=0,c=o.length;u<c;u++){var f=Kt(o[u].seriesId,null);if(f==null)return;for(var h=ct(o[u].dataIndex),v=l&&l[f],d=0,p=h.length;d<p;d++){var g=h[d];v&&v[g]?v[g]=null:(s[f]||(s[f]={}))[g]=1}}}function i(o,s){var l=[];for(var u in o)if(o.hasOwnProperty(u)&&o[u]!=null)if(s)l.push(+u);else{var c=i(o[u],!0);c.length&&l.push({seriesId:u,dataIndex:c})}return l}}function as(r,e){if(e.dataIndexInside!=null)return e.dataIndexInside;if(e.dataIndex!=null)return J(e.dataIndex)?K(e.dataIndex,function(t){return r.indexOfRawIndex(t)}):r.indexOfRawIndex(e.dataIndex);if(e.name!=null)return J(e.name)?K(e.name,function(t){return r.indexOfName(t)}):r.indexOfName(e.name)}function Ye(){var r="__ec_inner_"+uW++;return function(e){return e[r]||(e[r]={})}}var uW=JI();function Wc(r,e,t){var n=N0(e,t),a=n.mainTypeSpecified,i=n.queryOptionMap,o=n.others,s=o,l=t?t.defaultMainType:null;return!a&&l&&i.set(l,{}),i.each(function(u,c){var f=Gc(r,c,u,{useDefault:l===c,enableAll:t&&t.enableAll!=null?t.enableAll:!0,enableNone:t&&t.enableNone!=null?t.enableNone:!0});s[c+"Models"]=f.models,s[c+"Model"]=f.models[0]}),s}function N0(r,e){var t;if(ce(r)){var n={};n[r+"Index"]=0,t=n}else t=r;var a=ge(),i={},o=!1;return C(t,function(s,l){if(l==="dataIndex"||l==="dataIndexInside"){i[l]=s;return}var u=l.match(/^(\w+)(Index|Id|Name)$/)||[],c=u[1],f=(u[2]||"").toLowerCase();if(!(!c||!f||e&&e.includeMainTypes&&ze(e.includeMainTypes,c)<0)){o=o||!!c;var h=a.get(c)||a.set(c,{});h[f]=s}}),{mainTypeSpecified:o,queryOptionMap:a,others:i}}var Ut={useDefault:!0,enableAll:!1,enableNone:!1},cW={useDefault:!1,enableAll:!0,enableNone:!0};function Gc(r,e,t,n){n=n||Ut;var a=t.index,i=t.id,o=t.name,s={models:null,specified:a!=null||i!=null||o!=null};if(!s.specified){var l=void 0;return s.models=n.useDefault&&(l=r.getComponent(e))?[l]:[],s}return a==="none"||a===!1?(Er(n.enableNone,'`"none"` or `false` is not a valid value on index option.'),s.models=[],s):(a==="all"&&(Er(n.enableAll,'`"all"` is not a valid value on index option.'),a=i=o=null),s.models=r.queryComponents({mainType:e,index:a,id:i,name:o}),s)}function lT(r,e,t){r.setAttribute?r.setAttribute(e,t):r[e]=t}function fW(r,e){return r.getAttribute?r.getAttribute(e):r[e]}function hW(r){return r==="auto"?$e.domSupported?"html":"richText":r||"html"}function L0(r,e){var t=ge(),n=[];return C(r,function(a){var i=e(a);(t.get(i)||(n.push(i),t.set(i,[]))).push(a)}),{keys:n,buckets:t}}function uT(r,e,t,n,a){var i=e==null||e==="auto";if(n==null)return n;if(Ue(n)){var o=rT(t||0,n,a);return Nt(o,i?Math.max(da(t||0),da(n)):e)}else{if(ce(n))return a<1?t:n;for(var s=[],l=t,u=n,c=Math.max(l?l.length:0,u.length),f=0;f<c;++f){var h=r.getDimensionInfo(f);if(h&&h.type==="ordinal")s[f]=(a<1&&l?l:u)[f];else{var v=l&&l[f]?l[f]:0,d=u[f],o=rT(v,d,a);s[f]=Nt(o,i?Math.max(da(v),da(d)):e)}}return s}}var vW=".",is="___EC__COMPONENT__CONTAINER___",cT="___EC__EXTENDED_CLASS___";function ja(r){var e={main:"",sub:""};if(r){var t=r.split(vW);e.main=t[0]||"",e.sub=t[1]||""}return e}function dW(r){Er(/^[a-zA-Z0-9_]+([.][a-zA-Z0-9_]+)?$/.test(r),'componentType "'+r+'" illegal')}function pW(r){return!!(r&&r[cT])}function E0(r,e){r.$constructor=r,r.extend=function(t){var n=this,a;return gW(n)?a=function(i){U(o,i);function o(){return i.apply(this,arguments)||this}return o}(n):(a=function(){(t.$constructor||n).apply(this,arguments)},Tm(a,this)),X(a.prototype,t),a[cT]=!0,a.extend=this.extend,a.superCall=_W,a.superApply=bW,a.superClass=n,a}}function gW(r){return ye(r)&&/^class\s/.test(Function.prototype.toString.call(r))}function fT(r,e){r.extend=e.extend}var yW=Math.round(Math.random()*10);function mW(r){var e=["__\0is_clz",yW++].join("_");r.prototype[e]=!0,r.isInstance=function(t){return!!(t&&t[e])}}function _W(r,e){for(var t=[],n=2;n<arguments.length;n++)t[n-2]=arguments[n];return this.superClass.prototype[e].apply(r,t)}function bW(r,e,t){return this.superClass.prototype[e].apply(r,t)}function nd(r){var e={};r.registerClass=function(n){var a=n.type||n.prototype.type;if(a){dW(a),n.prototype.type=a;var i=ja(a);if(!i.sub)e[i.main]=n;else if(i.sub!==is){var o=t(i);o[i.sub]=n}}return n},r.getClass=function(n,a,i){var o=e[n];if(o&&o[is]&&(o=a?o[a]:null),i&&!o)throw new Error(a?"Component "+n+"."+(a||"")+" is used but not imported.":n+".type should be specified.");return o},r.getClassesByMainType=function(n){var a=ja(n),i=[],o=e[a.main];return o&&o[is]?C(o,function(s,l){l!==is&&i.push(s)}):i.push(o),i},r.hasClass=function(n){var a=ja(n);return!!e[a.main]},r.getAllClassMainTypes=function(){var n=[];return C(e,function(a,i){n.push(i)}),n},r.hasSubTypes=function(n){var a=ja(n),i=e[a.main];return i&&i[is]};function t(n){var a=e[n.main];return(!a||!a[is])&&(a=e[n.main]={},a[is]=!0),a}}function os(r,e){for(var t=0;t<r.length;t++)r[t][1]||(r[t][1]=r[t][0]);return e=e||!1,function(n,a,i){for(var o={},s=0;s<r.length;s++){var l=r[s][1];if(!(a&&ze(a,l)>=0||i&&ze(i,l)<0)){var u=n.getShallow(l,e);u!=null&&(o[r[s][0]]=u)}}return o}}var MW=[["fill","color"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["opacity"],["shadowColor"]],xW=os(MW),wW=function(){function r(){}return r.prototype.getAreaStyle=function(e,t){return xW(this,e,t)},r}(),O0=new Cc(50);function DW(r){if(typeof r=="string"){var e=O0.get(r);return e&&e.image}else return r}function P0(r,e,t,n,a){if(r)if(typeof r=="string"){if(e&&e.__zrImageSrc===r||!t)return e;var i=O0.get(r),o={hostEl:t,cb:n,cbPayload:a};return i?(e=i.image,!ad(e)&&i.pending.push(o)):(e=la.loadImage(r,hT,hT),e.__zrImageSrc=r,O0.put(r,e.__cachedImgObj={image:e,pending:[o]})),e}else return r;else return e}function hT(){var r=this.__cachedImgObj;this.onload=this.onerror=this.__cachedImgObj=null;for(var e=0;e<r.pending.length;e++){var t=r.pending[e],n=t.cb;n&&n(this,t.cbPayload),t.hostEl.dirty()}r.pending.length=0}function ad(r){return r&&r.width&&r.height}var z0=/\{([a-zA-Z0-9_]+)\|([^}]*)\}/g;function vT(r,e,t,n,a){if(!e)return"";var i=(r+"").split(`
|
|
224
|
+
`);a=dT(e,t,n,a);for(var o=0,s=i.length;o<s;o++)i[o]=pT(i[o],a);return i.join(`
|
|
225
|
+
`)}function dT(r,e,t,n){n=n||{};var a=X({},n);a.font=e,t=Ee(t,"..."),a.maxIterations=Ee(n.maxIterations,2);var i=a.minChar=Ee(n.minChar,0);a.cnCharWidth=_n("\u56FD",e);var o=a.ascCharWidth=_n("a",e);a.placeholder=Ee(n.placeholder,"");for(var s=r=Math.max(0,r-1),l=0;l<i&&s>=o;l++)s-=o;var u=_n(t,e);return u>s&&(t="",u=0),s=r-u,a.ellipsis=t,a.ellipsisWidth=u,a.contentWidth=s,a.containerWidth=r,a}function pT(r,e){var t=e.containerWidth,n=e.font,a=e.contentWidth;if(!t)return"";var i=_n(r,n);if(i<=t)return r;for(var o=0;;o++){if(i<=a||o>=e.maxIterations){r+=e.ellipsis;break}var s=o===0?SW(r,a,e.ascCharWidth,e.cnCharWidth):i>0?Math.floor(r.length*a/i):0;r=r.substr(0,s),i=_n(r,n)}return r===""&&(r=e.placeholder),r}function SW(r,e,t,n){for(var a=0,i=0,o=r.length;i<o&&a<e;i++){var s=r.charCodeAt(i);a+=0<=s&&s<=127?t:n}return i}function IW(r,e){r!=null&&(r+="");var t=e.overflow,n=e.padding,a=e.font,i=t==="truncate",o=Jv(a),s=Ee(e.lineHeight,o),l=!!e.backgroundColor,u=e.lineOverflow==="truncate",c=e.width,f;c!=null&&(t==="break"||t==="breakAll")?f=r?yT(r,e.font,c,t==="breakAll",0).lines:[]:f=r?r.split(`
|
|
226
|
+
`):[];var h=f.length*s,v=Ee(e.height,h);if(h>v&&u){var d=Math.floor(v/s);f=f.slice(0,d)}if(r&&i&&c!=null)for(var p=dT(c,a,e.ellipsis,{minChar:e.truncateMinChar,placeholder:e.placeholder}),g=0;g<f.length;g++)f[g]=pT(f[g],p);for(var y=v,m=0,g=0;g<f.length;g++)m=Math.max(_n(f[g],a),m);c==null&&(c=m);var _=m;return n&&(y+=n[0]+n[2],_+=n[1]+n[3],c+=n[1]+n[3]),l&&(_=c),{lines:f,height:v,outerWidth:_,outerHeight:y,lineHeight:s,calculatedLineHeight:o,contentWidth:m,contentHeight:h,width:c}}var TW=function(){function r(){}return r}(),gT=function(){function r(e){this.tokens=[],e&&(this.tokens=e)}return r}(),AW=function(){function r(){this.width=0,this.height=0,this.contentWidth=0,this.contentHeight=0,this.outerWidth=0,this.outerHeight=0,this.lines=[]}return r}();function CW(r,e){var t=new AW;if(r!=null&&(r+=""),!r)return t;for(var n=e.width,a=e.height,i=e.overflow,o=(i==="break"||i==="breakAll")&&n!=null?{width:n,accumWidth:0,breakAll:i==="breakAll"}:null,s=z0.lastIndex=0,l;(l=z0.exec(r))!=null;){var u=l.index;u>s&&k0(t,r.substring(s,u),e,o),k0(t,l[2],e,o,l[1]),s=z0.lastIndex}s<r.length&&k0(t,r.substring(s,r.length),e,o);var c=[],f=0,h=0,v=e.padding,d=i==="truncate",p=e.lineOverflow==="truncate";function g(F,G,Z){F.width=G,F.lineHeight=Z,f+=Z,h=Math.max(h,G)}e:for(var y=0;y<t.lines.length;y++){for(var m=t.lines[y],_=0,b=0,x=0;x<m.tokens.length;x++){var M=m.tokens[x],w=M.styleName&&e.rich[M.styleName]||{},D=M.textPadding=w.padding,T=D?D[1]+D[3]:0,I=M.font=w.font||e.font;M.contentHeight=Jv(I);var A=Ee(w.height,M.contentHeight);if(M.innerHeight=A,D&&(A+=D[0]+D[2]),M.height=A,M.lineHeight=Ea(w.lineHeight,e.lineHeight,A),M.align=w&&w.align||e.align,M.verticalAlign=w&&w.verticalAlign||"middle",p&&a!=null&&f+M.lineHeight>a){x>0?(m.tokens=m.tokens.slice(0,x),g(m,b,_),t.lines=t.lines.slice(0,y+1)):t.lines=t.lines.slice(0,y);break e}var N=w.width,L=N==null||N==="auto";if(typeof N=="string"&&N.charAt(N.length-1)==="%")M.percentWidth=N,c.push(M),M.contentWidth=_n(M.text,I);else{if(L){var E=w.backgroundColor,O=E&&E.image;O&&(O=DW(O),ad(O)&&(M.width=Math.max(M.width,O.width*A/O.height)))}var P=d&&n!=null?n-b:null;P!=null&&P<M.width?!L||P<T?(M.text="",M.width=M.contentWidth=0):(M.text=vT(M.text,P-T,I,e.ellipsis,{minChar:e.truncateMinChar}),M.width=M.contentWidth=_n(M.text,I)):M.contentWidth=_n(M.text,I)}M.width+=T,b+=M.width,w&&(_=Math.max(_,M.lineHeight))}g(m,b,_)}t.outerWidth=t.width=Ee(n,h),t.outerHeight=t.height=Ee(a,f),t.contentHeight=f,t.contentWidth=h,v&&(t.outerWidth+=v[1]+v[3],t.outerHeight+=v[0]+v[2]);for(var y=0;y<c.length;y++){var M=c[y],H=M.percentWidth;M.width=parseInt(H,10)/100*t.width}return t}function k0(r,e,t,n,a){var i=e==="",o=a&&t.rich[a]||{},s=r.lines,l=o.font||t.font,u=!1,c,f;if(n){var h=o.padding,v=h?h[1]+h[3]:0;if(o.width!=null&&o.width!=="auto"){var d=va(o.width,n.width)+v;s.length>0&&d+n.accumWidth>n.width&&(c=e.split(`
|
|
227
|
+
`),u=!0),n.accumWidth=d}else{var p=yT(e,l,n.width,n.breakAll,n.accumWidth);n.accumWidth=p.accumWidth+v,f=p.linesWidths,c=p.lines}}else c=e.split(`
|
|
228
|
+
`);for(var g=0;g<c.length;g++){var y=c[g],m=new TW;if(m.styleName=a,m.text=y,m.isLineHolder=!y&&!i,typeof o.width=="number"?m.width=o.width:m.width=f?f[g]:_n(y,l),!g&&!u){var _=(s[s.length-1]||(s[0]=new gT)).tokens,b=_.length;b===1&&_[0].isLineHolder?_[0]=m:(y||!b||i)&&_.push(m)}else s.push(new gT([m]))}}function NW(r){var e=r.charCodeAt(0);return e>=33&&e<=383}var LW=On(",&?/;] ".split(""),function(r,e){return r[e]=!0,r},{});function EW(r){return NW(r)?!!LW[r]:!0}function yT(r,e,t,n,a){for(var i=[],o=[],s="",l="",u=0,c=0,f=0;f<r.length;f++){var h=r.charAt(f);if(h===`
|
|
229
|
+
`){l&&(s+=l,c+=u),i.push(s),o.push(c),s="",l="",u=0,c=0;continue}var v=_n(h,e),d=n?!1:!EW(h);if(i.length?c+v>t:a+c+v>t){c?(s||l)&&(d?(s||(s=l,l="",u=0,c=u),i.push(s),o.push(c-u),l+=h,u+=v,s="",c=u):(l&&(s+=l,l="",u=0),i.push(s),o.push(c),s=h,c=v)):d?(i.push(l),o.push(u),l=h,u=v):(i.push(h),o.push(v));continue}c+=v,d?(l+=h,u+=v):(l&&(s+=l,l="",u=0),s+=h)}return!i.length&&!s&&(s=r,l="",u=0),l&&(s+=l),s&&(i.push(s),o.push(c)),i.length===1&&(c+=a),{accumWidth:c,lines:i,linesWidths:o}}var R0="__zr_style_"+Math.round(Math.random()*10),ss={shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,shadowColor:"#000",opacity:1,blend:"source-over"},id={style:{shadowBlur:!0,shadowOffsetX:!0,shadowOffsetY:!0,shadowColor:!0,opacity:!0}};ss[R0]=!0;var mT=["z","z2","invisible"],OW=["invisible"],PW=function(r){xt(e,r);function e(t){return r.call(this,t)||this}return e.prototype._init=function(t){for(var n=Fe(t),a=0;a<n.length;a++){var i=n[a];i==="style"?this.useStyle(t[i]):r.prototype.attrKV.call(this,i,t[i])}this.style||this.useStyle({})},e.prototype.beforeBrush=function(){},e.prototype.afterBrush=function(){},e.prototype.innerBeforeBrush=function(){},e.prototype.innerAfterBrush=function(){},e.prototype.shouldBePainted=function(t,n,a,i){var o=this.transform;if(this.ignore||this.invisible||this.style.opacity===0||this.culling&&zW(this,t,n)||o&&!o[0]&&!o[3])return!1;if(a&&this.__clipPaths){for(var s=0;s<this.__clipPaths.length;++s)if(this.__clipPaths[s].isZeroArea())return!1}if(i&&this.parent)for(var l=this.parent;l;){if(l.ignore)return!1;l=l.parent}return!0},e.prototype.contain=function(t,n){return this.rectContain(t,n)},e.prototype.traverse=function(t,n){t.call(n,this)},e.prototype.rectContain=function(t,n){var a=this.transformCoordToLocal(t,n),i=this.getBoundingRect();return i.contain(a[0],a[1])},e.prototype.getPaintRect=function(){var t=this._paintRect;if(!this._paintRect||this.__dirty){var n=this.transform,a=this.getBoundingRect(),i=this.style,o=i.shadowBlur||0,s=i.shadowOffsetX||0,l=i.shadowOffsetY||0;t=this._paintRect||(this._paintRect=new Pe(0,0,0,0)),n?Pe.applyTransform(t,a,n):t.copy(a),(o||s||l)&&(t.width+=o*2+Math.abs(s),t.height+=o*2+Math.abs(l),t.x=Math.min(t.x,t.x+s-o),t.y=Math.min(t.y,t.y+l-o));var u=this.dirtyRectTolerance;t.isZero()||(t.x=Math.floor(t.x-u),t.y=Math.floor(t.y-u),t.width=Math.ceil(t.width+1+u*2),t.height=Math.ceil(t.height+1+u*2))}return t},e.prototype.setPrevPaintRect=function(t){t?(this._prevPaintRect=this._prevPaintRect||new Pe(0,0,0,0),this._prevPaintRect.copy(t)):this._prevPaintRect=null},e.prototype.getPrevPaintRect=function(){return this._prevPaintRect},e.prototype.animateStyle=function(t){return this.animate("style",t)},e.prototype.updateDuringAnimation=function(t){t==="style"?this.dirtyStyle():this.markRedraw()},e.prototype.attrKV=function(t,n){t!=="style"?r.prototype.attrKV.call(this,t,n):this.style?this.setStyle(n):this.useStyle(n)},e.prototype.setStyle=function(t,n){return typeof t=="string"?this.style[t]=n:X(this.style,t),this.dirtyStyle(),this},e.prototype.dirtyStyle=function(t){t||this.markRedraw(),this.__dirty|=Tc,this._rect&&(this._rect=null)},e.prototype.dirty=function(){this.dirtyStyle()},e.prototype.styleChanged=function(){return!!(this.__dirty&Tc)},e.prototype.styleUpdated=function(){this.__dirty&=~Tc},e.prototype.createStyle=function(t){return yc(ss,t)},e.prototype.useStyle=function(t){t[R0]||(t=this.createStyle(t)),this.__inHover?this.__hoverStyle=t:this.style=t,this.dirtyStyle()},e.prototype.isStyleObject=function(t){return t[R0]},e.prototype._innerSaveToNormal=function(t){r.prototype._innerSaveToNormal.call(this,t);var n=this._normalState;t.style&&!n.style&&(n.style=this._mergeStyle(this.createStyle(),this.style)),this._savePrimaryToNormal(t,n,mT)},e.prototype._applyStateObj=function(t,n,a,i,o,s){r.prototype._applyStateObj.call(this,t,n,a,i,o,s);var l=!(n&&i),u;if(n&&n.style?o?i?u=n.style:(u=this._mergeStyle(this.createStyle(),a.style),this._mergeStyle(u,n.style)):(u=this._mergeStyle(this.createStyle(),i?this.style:a.style),this._mergeStyle(u,n.style)):l&&(u=a.style),u)if(o){var c=this.style;if(this.style=this.createStyle(l?{}:c),l)for(var f=Fe(c),h=0;h<f.length;h++){var v=f[h];v in u&&(u[v]=u[v],this.style[v]=c[v])}for(var d=Fe(u),h=0;h<d.length;h++){var v=d[h];this.style[v]=this.style[v]}this._transitionState(t,{style:u},s,this.getAnimationStyleProps())}else this.useStyle(u);for(var p=this.__inHover?OW:mT,h=0;h<p.length;h++){var v=p[h];n&&n[v]!=null?this[v]=n[v]:l&&a[v]!=null&&(this[v]=a[v])}},e.prototype._mergeStates=function(t){for(var n=r.prototype._mergeStates.call(this,t),a,i=0;i<t.length;i++){var o=t[i];o.style&&(a=a||{},this._mergeStyle(a,o.style))}return a&&(n.style=a),n},e.prototype._mergeStyle=function(t,n){return X(t,n),t},e.prototype.getAnimationStyleProps=function(){return id},e.initDefaultProps=function(){var t=e.prototype;t.type="displayable",t.invisible=!1,t.z=0,t.z2=0,t.zlevel=0,t.culling=!1,t.cursor="pointer",t.rectHover=!1,t.incremental=!1,t._rect=null,t.dirtyRectTolerance=0,t.__dirty=mn|Tc}(),e}(GI),j0=new Pe(0,0,0,0),B0=new Pe(0,0,0,0);function zW(r,e,t){return j0.copy(r.getBoundingRect()),r.transform&&j0.applyTransform(r.transform),B0.width=e,B0.height=t,!j0.intersect(B0)}var Bn=PW,on=Math.min,sn=Math.max,F0=Math.sin,V0=Math.cos,ls=Math.PI*2,od=Ui(),sd=Ui(),ld=Ui();function ud(r,e,t){if(r.length!==0){for(var n=r[0],a=n[0],i=n[0],o=n[1],s=n[1],l=1;l<r.length;l++)n=r[l],a=on(a,n[0]),i=sn(i,n[0]),o=on(o,n[1]),s=sn(s,n[1]);e[0]=a,e[1]=o,t[0]=i,t[1]=s}}function _T(r,e,t,n,a,i){a[0]=on(r,t),a[1]=on(e,n),i[0]=sn(r,t),i[1]=sn(e,n)}var bT=[],MT=[];function kW(r,e,t,n,a,i,o,s,l,u){var c=pI,f=ir,h=c(r,t,a,o,bT);l[0]=1/0,l[1]=1/0,u[0]=-1/0,u[1]=-1/0;for(var v=0;v<h;v++){var d=f(r,t,a,o,bT[v]);l[0]=on(d,l[0]),u[0]=sn(d,u[0])}h=c(e,n,i,s,MT);for(var v=0;v<h;v++){var p=f(e,n,i,s,MT[v]);l[1]=on(p,l[1]),u[1]=sn(p,u[1])}l[0]=on(r,l[0]),u[0]=sn(r,u[0]),l[0]=on(o,l[0]),u[0]=sn(o,u[0]),l[1]=on(e,l[1]),u[1]=sn(e,u[1]),l[1]=on(s,l[1]),u[1]=sn(s,u[1])}function RW(r,e,t,n,a,i,o,s){var l=yI,u=dr,c=sn(on(l(r,t,a),1),0),f=sn(on(l(e,n,i),1),0),h=u(r,t,a,c),v=u(e,n,i,f);o[0]=on(r,a,h),o[1]=on(e,i,v),s[0]=sn(r,a,h),s[1]=sn(e,i,v)}function jW(r,e,t,n,a,i,o,s,l){var u=ci,c=fi,f=Math.abs(a-i);if(f%ls<1e-4&&f>1e-4){s[0]=r-t,s[1]=e-n,l[0]=r+t,l[1]=e+n;return}if(od[0]=V0(a)*t+r,od[1]=F0(a)*n+e,sd[0]=V0(i)*t+r,sd[1]=F0(i)*n+e,u(s,od,sd),c(l,od,sd),a=a%ls,a<0&&(a=a+ls),i=i%ls,i<0&&(i=i+ls),a>i&&!o?i+=ls:a<i&&o&&(a+=ls),o){var h=i;i=a,a=h}for(var v=0;v<i;v+=Math.PI/2)v>a&&(ld[0]=V0(v)*t+r,ld[1]=F0(v)*n+e,u(s,ld,s),c(l,ld,l))}var gt={M:1,L:2,C:3,Q:4,A:5,Z:6,R:7},us=[],cs=[],Ba=[],to=[],Fa=[],Va=[],H0=Math.min,W0=Math.max,fs=Math.cos,hs=Math.sin,pi=Math.abs,G0=Math.PI,ro=G0*2,$0=typeof Float32Array!="undefined",$c=[];function U0(r){var e=Math.round(r/G0*1e8)/1e8;return e%2*G0}function xT(r,e){var t=U0(r[0]);t<0&&(t+=ro);var n=t-r[0],a=r[1];a+=n,!e&&a-t>=ro?a=t+ro:e&&t-a>=ro?a=t-ro:!e&&t>a?a=t+(ro-U0(t-a)):e&&t<a&&(a=t-(ro-U0(a-t))),r[0]=t,r[1]=a}var BW=function(){function r(e){this.dpr=1,this._xi=0,this._yi=0,this._x0=0,this._y0=0,this._len=0,e&&(this._saveData=!1),this._saveData&&(this.data=[])}return r.prototype.increaseVersion=function(){this._version++},r.prototype.getVersion=function(){return this._version},r.prototype.setScale=function(e,t,n){n=n||0,n>0&&(this._ux=pi(n/Xv/e)||0,this._uy=pi(n/Xv/t)||0)},r.prototype.setDPR=function(e){this.dpr=e},r.prototype.setContext=function(e){this._ctx=e},r.prototype.getContext=function(){return this._ctx},r.prototype.beginPath=function(){return this._ctx&&this._ctx.beginPath(),this.reset(),this},r.prototype.reset=function(){this._saveData&&(this._len=0),this._pathSegLen&&(this._pathSegLen=null,this._pathLen=0),this._version++},r.prototype.moveTo=function(e,t){return this._drawPendingPt(),this.addData(gt.M,e,t),this._ctx&&this._ctx.moveTo(e,t),this._x0=e,this._y0=t,this._xi=e,this._yi=t,this},r.prototype.lineTo=function(e,t){var n=pi(e-this._xi),a=pi(t-this._yi),i=n>this._ux||a>this._uy;if(this.addData(gt.L,e,t),this._ctx&&i&&this._ctx.lineTo(e,t),i)this._xi=e,this._yi=t,this._pendingPtDist=0;else{var o=n*n+a*a;o>this._pendingPtDist&&(this._pendingPtX=e,this._pendingPtY=t,this._pendingPtDist=o)}return this},r.prototype.bezierCurveTo=function(e,t,n,a,i,o){return this._drawPendingPt(),this.addData(gt.C,e,t,n,a,i,o),this._ctx&&this._ctx.bezierCurveTo(e,t,n,a,i,o),this._xi=i,this._yi=o,this},r.prototype.quadraticCurveTo=function(e,t,n,a){return this._drawPendingPt(),this.addData(gt.Q,e,t,n,a),this._ctx&&this._ctx.quadraticCurveTo(e,t,n,a),this._xi=n,this._yi=a,this},r.prototype.arc=function(e,t,n,a,i,o){this._drawPendingPt(),$c[0]=a,$c[1]=i,xT($c,o),a=$c[0],i=$c[1];var s=i-a;return this.addData(gt.A,e,t,n,n,a,s,0,o?0:1),this._ctx&&this._ctx.arc(e,t,n,a,i,o),this._xi=fs(i)*n+e,this._yi=hs(i)*n+t,this},r.prototype.arcTo=function(e,t,n,a,i){return this._drawPendingPt(),this._ctx&&this._ctx.arcTo(e,t,n,a,i),this},r.prototype.rect=function(e,t,n,a){return this._drawPendingPt(),this._ctx&&this._ctx.rect(e,t,n,a),this.addData(gt.R,e,t,n,a),this},r.prototype.closePath=function(){this._drawPendingPt(),this.addData(gt.Z);var e=this._ctx,t=this._x0,n=this._y0;return e&&e.closePath(),this._xi=t,this._yi=n,this},r.prototype.fill=function(e){e&&e.fill(),this.toStatic()},r.prototype.stroke=function(e){e&&e.stroke(),this.toStatic()},r.prototype.len=function(){return this._len},r.prototype.setData=function(e){var t=e.length;!(this.data&&this.data.length===t)&&$0&&(this.data=new Float32Array(t));for(var n=0;n<t;n++)this.data[n]=e[n];this._len=t},r.prototype.appendPath=function(e){e instanceof Array||(e=[e]);for(var t=e.length,n=0,a=this._len,i=0;i<t;i++)n+=e[i].len();$0&&this.data instanceof Float32Array&&(this.data=new Float32Array(a+n));for(var i=0;i<t;i++)for(var o=e[i].data,s=0;s<o.length;s++)this.data[a++]=o[s];this._len=a},r.prototype.addData=function(e,t,n,a,i,o,s,l,u){if(!!this._saveData){var c=this.data;this._len+arguments.length>c.length&&(this._expandData(),c=this.data);for(var f=0;f<arguments.length;f++)c[this._len++]=arguments[f]}},r.prototype._drawPendingPt=function(){this._pendingPtDist>0&&(this._ctx&&this._ctx.lineTo(this._pendingPtX,this._pendingPtY),this._pendingPtDist=0)},r.prototype._expandData=function(){if(!(this.data instanceof Array)){for(var e=[],t=0;t<this._len;t++)e[t]=this.data[t];this.data=e}},r.prototype.toStatic=function(){if(!!this._saveData){this._drawPendingPt();var e=this.data;e instanceof Array&&(e.length=this._len,$0&&this._len>11&&(this.data=new Float32Array(e)))}},r.prototype.getBoundingRect=function(){Ba[0]=Ba[1]=Fa[0]=Fa[1]=Number.MAX_VALUE,to[0]=to[1]=Va[0]=Va[1]=-Number.MAX_VALUE;var e=this.data,t=0,n=0,a=0,i=0,o;for(o=0;o<this._len;){var s=e[o++],l=o===1;switch(l&&(t=e[o],n=e[o+1],a=t,i=n),s){case gt.M:t=a=e[o++],n=i=e[o++],Fa[0]=a,Fa[1]=i,Va[0]=a,Va[1]=i;break;case gt.L:_T(t,n,e[o],e[o+1],Fa,Va),t=e[o++],n=e[o++];break;case gt.C:kW(t,n,e[o++],e[o++],e[o++],e[o++],e[o],e[o+1],Fa,Va),t=e[o++],n=e[o++];break;case gt.Q:RW(t,n,e[o++],e[o++],e[o],e[o+1],Fa,Va),t=e[o++],n=e[o++];break;case gt.A:var u=e[o++],c=e[o++],f=e[o++],h=e[o++],v=e[o++],d=e[o++]+v;o+=1;var p=!e[o++];l&&(a=fs(v)*f+u,i=hs(v)*h+c),jW(u,c,f,h,v,d,p,Fa,Va),t=fs(d)*f+u,n=hs(d)*h+c;break;case gt.R:a=t=e[o++],i=n=e[o++];var g=e[o++],y=e[o++];_T(a,i,a+g,i+y,Fa,Va);break;case gt.Z:t=a,n=i;break}ci(Ba,Ba,Fa),fi(to,to,Va)}return o===0&&(Ba[0]=Ba[1]=to[0]=to[1]=0),new Pe(Ba[0],Ba[1],to[0]-Ba[0],to[1]-Ba[1])},r.prototype._calculateLength=function(){var e=this.data,t=this._len,n=this._ux,a=this._uy,i=0,o=0,s=0,l=0;this._pathSegLen||(this._pathSegLen=[]);for(var u=this._pathSegLen,c=0,f=0,h=0;h<t;){var v=e[h++],d=h===1;d&&(i=e[h],o=e[h+1],s=i,l=o);var p=-1;switch(v){case gt.M:i=s=e[h++],o=l=e[h++];break;case gt.L:{var g=e[h++],y=e[h++],m=g-i,_=y-o;(pi(m)>n||pi(_)>a||h===t-1)&&(p=Math.sqrt(m*m+_*_),i=g,o=y);break}case gt.C:{var b=e[h++],x=e[h++],g=e[h++],y=e[h++],M=e[h++],w=e[h++];p=$V(i,o,b,x,g,y,M,w,10),i=M,o=w;break}case gt.Q:{var b=e[h++],x=e[h++],g=e[h++],y=e[h++];p=YV(i,o,b,x,g,y,10),i=g,o=y;break}case gt.A:var D=e[h++],T=e[h++],I=e[h++],A=e[h++],N=e[h++],L=e[h++],E=L+N;h+=1,e[h++],d&&(s=fs(N)*I+D,l=hs(N)*A+T),p=W0(I,A)*H0(ro,Math.abs(L)),i=fs(E)*I+D,o=hs(E)*A+T;break;case gt.R:{s=i=e[h++],l=o=e[h++];var O=e[h++],P=e[h++];p=O*2+P*2;break}case gt.Z:{var m=s-i,_=l-o;p=Math.sqrt(m*m+_*_),i=s,o=l;break}}p>=0&&(u[f++]=p,c+=p)}return this._pathLen=c,c},r.prototype.rebuildPath=function(e,t){var n=this.data,a=this._ux,i=this._uy,o=this._len,s,l,u,c,f,h,v=t<1,d,p,g=0,y=0,m,_=0,b,x;if(v&&(this._pathSegLen||this._calculateLength(),d=this._pathSegLen,p=this._pathLen,m=t*p,!m))return;e:for(var M=0;M<o;){var w=n[M++],D=M===1;switch(D&&(u=n[M],c=n[M+1],s=u,l=c),w!==gt.L&&_>0&&(e.lineTo(b,x),_=0),w){case gt.M:s=u=n[M++],l=c=n[M++],e.moveTo(u,c);break;case gt.L:{f=n[M++],h=n[M++];var T=pi(f-u),I=pi(h-c);if(T>a||I>i){if(v){var A=d[y++];if(g+A>m){var N=(m-g)/A;e.lineTo(u*(1-N)+f*N,c*(1-N)+h*N);break e}g+=A}e.lineTo(f,h),u=f,c=h,_=0}else{var L=T*T+I*I;L>_&&(b=f,x=h,_=L)}break}case gt.C:{var E=n[M++],O=n[M++],P=n[M++],H=n[M++],F=n[M++],G=n[M++];if(v){var A=d[y++];if(g+A>m){var N=(m-g)/A;Ji(u,E,P,F,N,us),Ji(c,O,H,G,N,cs),e.bezierCurveTo(us[1],cs[1],us[2],cs[2],us[3],cs[3]);break e}g+=A}e.bezierCurveTo(E,O,P,H,F,G),u=F,c=G;break}case gt.Q:{var E=n[M++],O=n[M++],P=n[M++],H=n[M++];if(v){var A=d[y++];if(g+A>m){var N=(m-g)/A;Ac(u,E,P,N,us),Ac(c,O,H,N,cs),e.quadraticCurveTo(us[1],cs[1],us[2],cs[2]);break e}g+=A}e.quadraticCurveTo(E,O,P,H),u=P,c=H;break}case gt.A:var Z=n[M++],te=n[M++],V=n[M++],Y=n[M++],q=n[M++],Q=n[M++],ne=n[M++],oe=!n[M++],ie=V>Y?V:Y,he=pi(V-Y)>.001,k=q+Q,j=!1;if(v){var A=d[y++];g+A>m&&(k=q+Q*(m-g)/A,j=!0),g+=A}if(he&&e.ellipse?e.ellipse(Z,te,V,Y,ne,q,k,oe):e.arc(Z,te,ie,q,k,oe),j)break e;D&&(s=fs(q)*V+Z,l=hs(q)*Y+te),u=fs(k)*V+Z,c=hs(k)*Y+te;break;case gt.R:s=u=n[M],l=c=n[M+1],f=n[M++],h=n[M++];var W=n[M++],ae=n[M++];if(v){var A=d[y++];if(g+A>m){var re=m-g;e.moveTo(f,h),e.lineTo(f+H0(re,W),h),re-=W,re>0&&e.lineTo(f+W,h+H0(re,ae)),re-=ae,re>0&&e.lineTo(f+W0(W-re,0),h+ae),re-=W,re>0&&e.lineTo(f,h+W0(ae-re,0));break e}g+=A}e.rect(f,h,W,ae);break;case gt.Z:if(v){var A=d[y++];if(g+A>m){var N=(m-g)/A;e.lineTo(u*(1-N)+s*N,c*(1-N)+l*N);break e}g+=A}e.closePath(),u=s,c=l}}},r.prototype.clone=function(){var e=new r,t=this.data;return e.data=t.slice?t.slice():Array.prototype.slice.call(t),e._len=this._len,e},r.CMD=gt,r.initDefaultProps=function(){var e=r.prototype;e._saveData=!0,e._ux=0,e._uy=0,e._pendingPtDist=0,e._version=0}(),r}(),Ha=BW;function no(r,e,t,n,a,i,o){if(a===0)return!1;var s=a,l=0,u=r;if(o>e+s&&o>n+s||o<e-s&&o<n-s||i>r+s&&i>t+s||i<r-s&&i<t-s)return!1;if(r!==t)l=(e-n)/(r-t),u=(r*n-t*e)/(r-t);else return Math.abs(i-r)<=s/2;var c=l*i-o+u,f=c*c/(l*l+1);return f<=s/2*s/2}function FW(r,e,t,n,a,i,o,s,l,u,c){if(l===0)return!1;var f=l;if(c>e+f&&c>n+f&&c>i+f&&c>s+f||c<e-f&&c<n-f&&c<i-f&&c<s-f||u>r+f&&u>t+f&&u>a+f&&u>o+f||u<r-f&&u<t-f&&u<a-f&&u<o-f)return!1;var h=gI(r,e,t,n,a,i,o,s,u,c,null);return h<=f/2}function wT(r,e,t,n,a,i,o,s,l){if(o===0)return!1;var u=o;if(l>e+u&&l>n+u&&l>i+u||l<e-u&&l<n-u&&l<i-u||s>r+u&&s>t+u&&s>a+u||s<r-u&&s<t-u&&s<a-u)return!1;var c=mI(r,e,t,n,a,i,s,l,null);return c<=u/2}var DT=Math.PI*2;function ao(r){return r%=DT,r<0&&(r+=DT),r}var Uc=Math.PI*2;function VW(r,e,t,n,a,i,o,s,l){if(o===0)return!1;var u=o;s-=r,l-=e;var c=Math.sqrt(s*s+l*l);if(c-u>t||c+u<t)return!1;if(Math.abs(n-a)%Uc<1e-4)return!0;if(i){var f=n;n=ao(a),a=ao(f)}else n=ao(n),a=ao(a);n>a&&(a+=Uc);var h=Math.atan2(l,s);return h<0&&(h+=Uc),h>=n&&h<=a||h+Uc>=n&&h+Uc<=a}function gi(r,e,t,n,a,i){if(i>e&&i>n||i<e&&i<n||n===e)return 0;var o=(i-e)/(n-e),s=n<e?1:-1;(o===1||o===0)&&(s=n<e?.5:-.5);var l=o*(t-r)+r;return l===a?1/0:l>a?s:0}var io=Ha.CMD,vs=Math.PI*2,HW=1e-4;function WW(r,e){return Math.abs(r-e)<HW}var Yr=[-1,-1,-1],Fn=[-1,-1];function GW(){var r=Fn[0];Fn[0]=Fn[1],Fn[1]=r}function $W(r,e,t,n,a,i,o,s,l,u){if(u>e&&u>n&&u>i&&u>s||u<e&&u<n&&u<i&&u<s)return 0;var c=Bv(e,n,i,s,u,Yr);if(c===0)return 0;for(var f=0,h=-1,v=void 0,d=void 0,p=0;p<c;p++){var g=Yr[p],y=g===0||g===1?.5:1,m=ir(r,t,a,o,g);m<l||(h<0&&(h=pI(e,n,i,s,Fn),Fn[1]<Fn[0]&&h>1&&GW(),v=ir(e,n,i,s,Fn[0]),h>1&&(d=ir(e,n,i,s,Fn[1]))),h===2?g<Fn[0]?f+=v<e?y:-y:g<Fn[1]?f+=d<v?y:-y:f+=s<d?y:-y:g<Fn[0]?f+=v<e?y:-y:f+=s<v?y:-y)}return f}function UW(r,e,t,n,a,i,o,s){if(s>e&&s>n&&s>i||s<e&&s<n&&s<i)return 0;var l=UV(e,n,i,s,Yr);if(l===0)return 0;var u=yI(e,n,i);if(u>=0&&u<=1){for(var c=0,f=dr(e,n,i,u),h=0;h<l;h++){var v=Yr[h]===0||Yr[h]===1?.5:1,d=dr(r,t,a,Yr[h]);d<o||(Yr[h]<u?c+=f<e?v:-v:c+=i<f?v:-v)}return c}else{var v=Yr[0]===0||Yr[0]===1?.5:1,d=dr(r,t,a,Yr[0]);return d<o?0:i<e?v:-v}}function YW(r,e,t,n,a,i,o,s){if(s-=e,s>t||s<-t)return 0;var l=Math.sqrt(t*t-s*s);Yr[0]=-l,Yr[1]=l;var u=Math.abs(n-a);if(u<1e-4)return 0;if(u>=vs-1e-4){n=0,a=vs;var c=i?1:-1;return o>=Yr[0]+r&&o<=Yr[1]+r?c:0}if(n>a){var f=n;n=a,a=f}n<0&&(n+=vs,a+=vs);for(var h=0,v=0;v<2;v++){var d=Yr[v];if(d+r>o){var p=Math.atan2(s,d),c=i?1:-1;p<0&&(p=vs+p),(p>=n&&p<=a||p+vs>=n&&p+vs<=a)&&(p>Math.PI/2&&p<Math.PI*1.5&&(c=-c),h+=c)}}return h}function ST(r,e,t,n,a){for(var i=r.data,o=r.len(),s=0,l=0,u=0,c=0,f=0,h,v,d=0;d<o;){var p=i[d++],g=d===1;switch(p===io.M&&d>1&&(t||(s+=gi(l,u,c,f,n,a))),g&&(l=i[d],u=i[d+1],c=l,f=u),p){case io.M:c=i[d++],f=i[d++],l=c,u=f;break;case io.L:if(t){if(no(l,u,i[d],i[d+1],e,n,a))return!0}else s+=gi(l,u,i[d],i[d+1],n,a)||0;l=i[d++],u=i[d++];break;case io.C:if(t){if(FW(l,u,i[d++],i[d++],i[d++],i[d++],i[d],i[d+1],e,n,a))return!0}else s+=$W(l,u,i[d++],i[d++],i[d++],i[d++],i[d],i[d+1],n,a)||0;l=i[d++],u=i[d++];break;case io.Q:if(t){if(wT(l,u,i[d++],i[d++],i[d],i[d+1],e,n,a))return!0}else s+=UW(l,u,i[d++],i[d++],i[d],i[d+1],n,a)||0;l=i[d++],u=i[d++];break;case io.A:var y=i[d++],m=i[d++],_=i[d++],b=i[d++],x=i[d++],M=i[d++];d+=1;var w=!!(1-i[d++]);h=Math.cos(x)*_+y,v=Math.sin(x)*b+m,g?(c=h,f=v):s+=gi(l,u,h,v,n,a);var D=(n-y)*b/_+y;if(t){if(VW(y,m,b,x,x+M,w,e,D,a))return!0}else s+=YW(y,m,b,x,x+M,w,D,a);l=Math.cos(x+M)*_+y,u=Math.sin(x+M)*b+m;break;case io.R:c=l=i[d++],f=u=i[d++];var T=i[d++],I=i[d++];if(h=c+T,v=f+I,t){if(no(c,f,h,f,e,n,a)||no(h,f,h,v,e,n,a)||no(h,v,c,v,e,n,a)||no(c,v,c,f,e,n,a))return!0}else s+=gi(h,f,h,v,n,a),s+=gi(c,v,c,f,n,a);break;case io.Z:if(t){if(no(l,u,c,f,e,n,a))return!0}else s+=gi(l,u,c,f,n,a);l=c,u=f;break}}return!t&&!WW(u,f)&&(s+=gi(l,u,c,f,n,a)||0),s!==0}function QW(r,e,t){return ST(r,0,!1,e,t)}function ZW(r,e,t,n){return ST(r,e,!0,t,n)}var cd=me({fill:"#000",stroke:null,strokePercent:1,fillOpacity:1,strokeOpacity:1,lineDashOffset:0,lineWidth:1,lineCap:"butt",miterLimit:10,strokeNoScale:!1,strokeFirst:!1},ss),qW={style:me({fill:!0,stroke:!0,strokePercent:!0,fillOpacity:!0,strokeOpacity:!0,lineDashOffset:!0,lineWidth:!0,miterLimit:!0},id.style)},Y0=ka.concat(["invisible","culling","z","z2","zlevel","parent"]),XW=function(r){xt(e,r);function e(t){return r.call(this,t)||this}return e.prototype.update=function(){var t=this;r.prototype.update.call(this);var n=this.style;if(n.decal){var a=this._decalEl=this._decalEl||new e;a.buildPath===e.prototype.buildPath&&(a.buildPath=function(l){t.buildPath(l,t.shape)}),a.silent=!0;var i=a.style;for(var o in n)i[o]!==n[o]&&(i[o]=n[o]);i.fill=n.fill?n.decal:null,i.decal=null,i.shadowColor=null,n.strokeFirst&&(i.stroke=null);for(var s=0;s<Y0.length;++s)a[Y0[s]]=this[Y0[s]];a.__dirty|=mn}else this._decalEl&&(this._decalEl=null)},e.prototype.getDecalElement=function(){return this._decalEl},e.prototype._init=function(t){var n=Fe(t);this.shape=this.getDefaultShape();var a=this.getDefaultStyle();a&&this.useStyle(a);for(var i=0;i<n.length;i++){var o=n[i],s=t[o];o==="style"?this.style?X(this.style,s):this.useStyle(s):o==="shape"?X(this.shape,s):r.prototype.attrKV.call(this,o,s)}this.style||this.useStyle({})},e.prototype.getDefaultStyle=function(){return null},e.prototype.getDefaultShape=function(){return{}},e.prototype.canBeInsideText=function(){return this.hasFill()},e.prototype.getInsideTextFill=function(){var t=this.style.fill;if(t!=="none"){if(ce(t)){var n=Oc(t,0);return n>.5?v0:n>.2?CH:d0}else if(t)return d0}return v0},e.prototype.getInsideTextStroke=function(t){var n=this.style.fill;if(ce(n)){var a=this.__zr,i=!!(a&&a.isDarkMode()),o=Oc(t,0)<h0;if(i===o)return n}},e.prototype.buildPath=function(t,n,a){},e.prototype.pathUpdated=function(){this.__dirty&=~zl},e.prototype.getUpdatedPathProxy=function(t){return!this.path&&this.createPathProxy(),this.path.beginPath(),this.buildPath(this.path,this.shape,t),this.path},e.prototype.createPathProxy=function(){this.path=new Ha(!1)},e.prototype.hasStroke=function(){var t=this.style,n=t.stroke;return!(n==null||n==="none"||!(t.lineWidth>0))},e.prototype.hasFill=function(){var t=this.style,n=t.fill;return n!=null&&n!=="none"},e.prototype.getBoundingRect=function(){var t=this._rect,n=this.style,a=!t;if(a){var i=!1;this.path||(i=!0,this.createPathProxy());var o=this.path;(i||this.__dirty&zl)&&(o.beginPath(),this.buildPath(o,this.shape,!1),this.pathUpdated()),t=o.getBoundingRect()}if(this._rect=t,this.hasStroke()&&this.path&&this.path.len()>0){var s=this._rectStroke||(this._rectStroke=t.clone());if(this.__dirty||a){s.copy(t);var l=n.strokeNoScale?this.getLineScale():1,u=n.lineWidth;if(!this.hasFill()){var c=this.strokeContainThreshold;u=Math.max(u,c==null?4:c)}l>1e-10&&(s.width+=u/l,s.height+=u/l,s.x-=u/l/2,s.y-=u/l/2)}return s}return t},e.prototype.contain=function(t,n){var a=this.transformCoordToLocal(t,n),i=this.getBoundingRect(),o=this.style;if(t=a[0],n=a[1],i.contain(t,n)){var s=this.path;if(this.hasStroke()){var l=o.lineWidth,u=o.strokeNoScale?this.getLineScale():1;if(u>1e-10&&(this.hasFill()||(l=Math.max(l,this.strokeContainThreshold)),ZW(s,l/u,t,n)))return!0}if(this.hasFill())return QW(s,t,n)}return!1},e.prototype.dirtyShape=function(){this.__dirty|=zl,this._rect&&(this._rect=null),this._decalEl&&this._decalEl.dirtyShape(),this.markRedraw()},e.prototype.dirty=function(){this.dirtyStyle(),this.dirtyShape()},e.prototype.animateShape=function(t){return this.animate("shape",t)},e.prototype.updateDuringAnimation=function(t){t==="style"?this.dirtyStyle():t==="shape"?this.dirtyShape():this.markRedraw()},e.prototype.attrKV=function(t,n){t==="shape"?this.setShape(n):r.prototype.attrKV.call(this,t,n)},e.prototype.setShape=function(t,n){var a=this.shape;return a||(a=this.shape={}),typeof t=="string"?a[t]=n:X(a,t),this.dirtyShape(),this},e.prototype.shapeChanged=function(){return!!(this.__dirty&zl)},e.prototype.createStyle=function(t){return yc(cd,t)},e.prototype._innerSaveToNormal=function(t){r.prototype._innerSaveToNormal.call(this,t);var n=this._normalState;t.shape&&!n.shape&&(n.shape=X({},this.shape))},e.prototype._applyStateObj=function(t,n,a,i,o,s){r.prototype._applyStateObj.call(this,t,n,a,i,o,s);var l=!(n&&i),u;if(n&&n.shape?o?i?u=n.shape:(u=X({},a.shape),X(u,n.shape)):(u=X({},i?this.shape:a.shape),X(u,n.shape)):l&&(u=a.shape),u)if(o){this.shape=X({},this.shape);for(var c={},f=Fe(u),h=0;h<f.length;h++){var v=f[h];typeof u[v]=="object"?this.shape[v]=u[v]:c[v]=u[v]}this._transitionState(t,{shape:c},s)}else this.shape=u,this.dirtyShape()},e.prototype._mergeStates=function(t){for(var n=r.prototype._mergeStates.call(this,t),a,i=0;i<t.length;i++){var o=t[i];o.shape&&(a=a||{},this._mergeStyle(a,o.shape))}return a&&(n.shape=a),n},e.prototype.getAnimationStyleProps=function(){return qW},e.prototype.isZeroArea=function(){return!1},e.extend=function(t){var n=function(i){xt(o,i);function o(s){var l=i.call(this,s)||this;return t.init&&t.init.call(l,s),l}return o.prototype.getDefaultStyle=function(){return Me(t.style)},o.prototype.getDefaultShape=function(){return Me(t.shape)},o}(e);for(var a in t)typeof t[a]=="function"&&(n.prototype[a]=t[a]);return n},e.initDefaultProps=function(){var t=e.prototype;t.type="path",t.strokeContainThreshold=5,t.segmentIgnoreThreshold=0,t.subPixelOptimize=!1,t.autoBatch=!1,t.__dirty=mn|Tc|zl}(),e}(Bn),je=XW,JW=me({strokeFirst:!0,font:$i,x:0,y:0,textAlign:"left",textBaseline:"top",miterLimit:2},cd),IT=function(r){xt(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.hasStroke=function(){var t=this.style,n=t.stroke;return n!=null&&n!=="none"&&t.lineWidth>0},e.prototype.hasFill=function(){var t=this.style,n=t.fill;return n!=null&&n!=="none"},e.prototype.createStyle=function(t){return yc(JW,t)},e.prototype.setBoundingRect=function(t){this._rect=t},e.prototype.getBoundingRect=function(){var t=this.style;if(!this._rect){var n=t.text;n!=null?n+="":n="";var a=jc(n,t.font,t.textAlign,t.textBaseline);if(a.x+=t.x||0,a.y+=t.y||0,this.hasStroke()){var i=t.lineWidth;a.x-=i/2,a.y-=i/2,a.width+=i,a.height+=i}this._rect=a}return this._rect},e.initDefaultProps=function(){var t=e.prototype;t.dirtyRectTolerance=10}(),e}(Bn);IT.prototype.type="tspan";var Yc=IT,KW=me({x:0,y:0},ss),eG={style:me({x:!0,y:!0,width:!0,height:!0,sx:!0,sy:!0,sWidth:!0,sHeight:!0},id.style)};function tG(r){return!!(r&&typeof r!="string"&&r.width&&r.height)}var TT=function(r){xt(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.createStyle=function(t){return yc(KW,t)},e.prototype._getSize=function(t){var n=this.style,a=n[t];if(a!=null)return a;var i=tG(n.image)?n.image:this.__image;if(!i)return 0;var o=t==="width"?"height":"width",s=n[o];return s==null?i[t]:i[t]/i[o]*s},e.prototype.getWidth=function(){return this._getSize("width")},e.prototype.getHeight=function(){return this._getSize("height")},e.prototype.getAnimationStyleProps=function(){return eG},e.prototype.getBoundingRect=function(){var t=this.style;return this._rect||(this._rect=new Pe(t.x||0,t.y||0,this.getWidth(),this.getHeight())),this._rect},e}(Bn);TT.prototype.type="image";var pr=TT;function rG(r,e){var t=e.x,n=e.y,a=e.width,i=e.height,o=e.r,s,l,u,c;a<0&&(t=t+a,a=-a),i<0&&(n=n+i,i=-i),typeof o=="number"?s=l=u=c=o:o instanceof Array?o.length===1?s=l=u=c=o[0]:o.length===2?(s=u=o[0],l=c=o[1]):o.length===3?(s=o[0],l=c=o[1],u=o[2]):(s=o[0],l=o[1],u=o[2],c=o[3]):s=l=u=c=0;var f;s+l>a&&(f=s+l,s*=a/f,l*=a/f),u+c>a&&(f=u+c,u*=a/f,c*=a/f),l+u>i&&(f=l+u,l*=i/f,u*=i/f),s+c>i&&(f=s+c,s*=i/f,c*=i/f),r.moveTo(t+s,n),r.lineTo(t+a-l,n),l!==0&&r.arc(t+a-l,n+l,l,-Math.PI/2,0),r.lineTo(t+a,n+i-u),u!==0&&r.arc(t+a-u,n+i-u,u,0,Math.PI/2),r.lineTo(t+c,n+i),c!==0&&r.arc(t+c,n+i-c,c,Math.PI/2,Math.PI),r.lineTo(t,n+s),s!==0&&r.arc(t+s,n+s,s,Math.PI,Math.PI*1.5)}var Gl=Math.round;function AT(r,e,t){if(!!e){var n=e.x1,a=e.x2,i=e.y1,o=e.y2;r.x1=n,r.x2=a,r.y1=i,r.y2=o;var s=t&&t.lineWidth;return s&&(Gl(n*2)===Gl(a*2)&&(r.x1=r.x2=ds(n,s,!0)),Gl(i*2)===Gl(o*2)&&(r.y1=r.y2=ds(i,s,!0))),r}}function CT(r,e,t){if(!!e){var n=e.x,a=e.y,i=e.width,o=e.height;r.x=n,r.y=a,r.width=i,r.height=o;var s=t&&t.lineWidth;return s&&(r.x=ds(n,s,!0),r.y=ds(a,s,!0),r.width=Math.max(ds(n+i,s,!1)-r.x,i===0?0:1),r.height=Math.max(ds(a+o,s,!1)-r.y,o===0?0:1)),r}}function ds(r,e,t){if(!e)return r;var n=Gl(r*2);return(n+Gl(e))%2===0?n/2:(n+(t?1:-1))/2}var nG=function(){function r(){this.x=0,this.y=0,this.width=0,this.height=0}return r}(),aG={},NT=function(r){xt(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultShape=function(){return new nG},e.prototype.buildPath=function(t,n){var a,i,o,s;if(this.subPixelOptimize){var l=CT(aG,n,this.style);a=l.x,i=l.y,o=l.width,s=l.height,l.r=n.r,n=l}else a=n.x,i=n.y,o=n.width,s=n.height;n.r?rG(t,n):t.rect(a,i,o,s)},e.prototype.isZeroArea=function(){return!this.shape.width||!this.shape.height},e}(je);NT.prototype.type="rect";var We=NT,LT={fill:"#000"},ET=2,iG={style:me({fill:!0,stroke:!0,fillOpacity:!0,strokeOpacity:!0,lineWidth:!0,fontSize:!0,lineHeight:!0,width:!0,height:!0,textShadowColor:!0,textShadowBlur:!0,textShadowOffsetX:!0,textShadowOffsetY:!0,backgroundColor:!0,padding:!0,borderColor:!0,borderWidth:!0,borderRadius:!0},id.style)},OT=function(r){xt(e,r);function e(t){var n=r.call(this)||this;return n.type="text",n._children=[],n._defaultStyle=LT,n.attr(t),n}return e.prototype.childrenRef=function(){return this._children},e.prototype.update=function(){r.prototype.update.call(this),this.styleChanged()&&this._updateSubTexts();for(var t=0;t<this._children.length;t++){var n=this._children[t];n.zlevel=this.zlevel,n.z=this.z,n.z2=this.z2,n.culling=this.culling,n.cursor=this.cursor,n.invisible=this.invisible}},e.prototype.updateTransform=function(){var t=this.innerTransformable;t?(t.updateTransform(),t.transform&&(this.transform=t.transform)):r.prototype.updateTransform.call(this)},e.prototype.getLocalTransform=function(t){var n=this.innerTransformable;return n?n.getLocalTransform(t):r.prototype.getLocalTransform.call(this,t)},e.prototype.getComputedTransform=function(){return this.__hostTarget&&(this.__hostTarget.getComputedTransform(),this.__hostTarget.updateInnerText(!0)),r.prototype.getComputedTransform.call(this)},e.prototype._updateSubTexts=function(){this._childCursor=0,lG(this.style),this.style.rich?this._updateRichTexts():this._updatePlainTexts(),this._children.length=this._childCursor,this.styleUpdated()},e.prototype.addSelfToZr=function(t){r.prototype.addSelfToZr.call(this,t);for(var n=0;n<this._children.length;n++)this._children[n].__zr=t},e.prototype.removeSelfFromZr=function(t){r.prototype.removeSelfFromZr.call(this,t);for(var n=0;n<this._children.length;n++)this._children[n].__zr=null},e.prototype.getBoundingRect=function(){if(this.styleChanged()&&this._updateSubTexts(),!this._rect){for(var t=new Pe(0,0,0,0),n=this._children,a=[],i=null,o=0;o<n.length;o++){var s=n[o],l=s.getBoundingRect(),u=s.getLocalTransform(a);u?(t.copy(l),t.applyTransform(u),i=i||t.clone(),i.union(t)):(i=i||l.clone(),i.union(l))}this._rect=i||t}return this._rect},e.prototype.setDefaultTextStyle=function(t){this._defaultStyle=t||LT},e.prototype.setTextContent=function(t){},e.prototype._mergeStyle=function(t,n){if(!n)return t;var a=n.rich,i=t.rich||a&&{};return X(t,n),a&&i?(this._mergeRich(i,a),t.rich=i):i&&(t.rich=i),t},e.prototype._mergeRich=function(t,n){for(var a=Fe(n),i=0;i<a.length;i++){var o=a[i];t[o]=t[o]||{},X(t[o],n[o])}},e.prototype.getAnimationStyleProps=function(){return iG},e.prototype._getOrCreateChild=function(t){var n=this._children[this._childCursor];return(!n||!(n instanceof t))&&(n=new t),this._children[this._childCursor++]=n,n.__zr=this.__zr,n.parent=this,n},e.prototype._updatePlainTexts=function(){var t=this.style,n=t.font||$i,a=t.padding,i=HT(t),o=IW(i,t),s=Q0(t),l=!!t.backgroundColor,u=o.outerHeight,c=o.outerWidth,f=o.contentWidth,h=o.lines,v=o.lineHeight,d=this._defaultStyle,p=t.x||0,g=t.y||0,y=t.align||d.align||"left",m=t.verticalAlign||d.verticalAlign||"top",_=p,b=Vl(g,o.contentHeight,m);if(s||a){var x=Bc(p,c,y),M=Vl(g,u,m);s&&this._renderBackground(t,t,x,M,c,u)}b+=v/2,a&&(_=VT(p,y,a),m==="top"?b+=a[0]:m==="bottom"&&(b-=a[2]));for(var w=0,D=!1,T=FT("fill"in t?t.fill:(D=!0,d.fill)),I=BT("stroke"in t?t.stroke:!l&&(!d.autoStroke||D)?(w=ET,d.stroke):null),A=t.textShadowBlur>0,N=t.width!=null&&(t.overflow==="truncate"||t.overflow==="break"||t.overflow==="breakAll"),L=o.calculatedLineHeight,E=0;E<h.length;E++){var O=this._getOrCreateChild(Yc),P=O.createStyle();O.useStyle(P),P.text=h[E],P.x=_,P.y=b,y&&(P.textAlign=y),P.textBaseline="middle",P.opacity=t.opacity,P.strokeFirst=!0,A&&(P.shadowBlur=t.textShadowBlur||0,P.shadowColor=t.textShadowColor||"transparent",P.shadowOffsetX=t.textShadowOffsetX||0,P.shadowOffsetY=t.textShadowOffsetY||0),P.stroke=I,P.fill=T,I&&(P.lineWidth=t.lineWidth||w,P.lineDash=t.lineDash,P.lineDashOffset=t.lineDashOffset||0),P.font=n,kT(P,t),b+=v,N&&O.setBoundingRect(new Pe(Bc(P.x,t.width,P.textAlign),Vl(P.y,L,P.textBaseline),f,L))}},e.prototype._updateRichTexts=function(){var t=this.style,n=HT(t),a=CW(n,t),i=a.width,o=a.outerWidth,s=a.outerHeight,l=t.padding,u=t.x||0,c=t.y||0,f=this._defaultStyle,h=t.align||f.align,v=t.verticalAlign||f.verticalAlign,d=Bc(u,o,h),p=Vl(c,s,v),g=d,y=p;l&&(g+=l[3],y+=l[0]);var m=g+i;Q0(t)&&this._renderBackground(t,t,d,p,o,s);for(var _=!!t.backgroundColor,b=0;b<a.lines.length;b++){for(var x=a.lines[b],M=x.tokens,w=M.length,D=x.lineHeight,T=x.width,I=0,A=g,N=m,L=w-1,E=void 0;I<w&&(E=M[I],!E.align||E.align==="left");)this._placeToken(E,t,D,y,A,"left",_),T-=E.width,A+=E.width,I++;for(;L>=0&&(E=M[L],E.align==="right");)this._placeToken(E,t,D,y,N,"right",_),T-=E.width,N-=E.width,L--;for(A+=(i-(A-g)-(m-N)-T)/2;I<=L;)E=M[I],this._placeToken(E,t,D,y,A+E.width/2,"center",_),A+=E.width,I++;y+=D}},e.prototype._placeToken=function(t,n,a,i,o,s,l){var u=n.rich[t.styleName]||{};u.text=t.text;var c=t.verticalAlign,f=i+a/2;c==="top"?f=i+t.height/2:c==="bottom"&&(f=i+a-t.height/2);var h=!t.isLineHolder&&Q0(u);h&&this._renderBackground(u,n,s==="right"?o-t.width:s==="center"?o-t.width/2:o,f-t.height/2,t.width,t.height);var v=!!u.backgroundColor,d=t.textPadding;d&&(o=VT(o,s,d),f-=t.height/2-d[0]-t.innerHeight/2);var p=this._getOrCreateChild(Yc),g=p.createStyle();p.useStyle(g);var y=this._defaultStyle,m=!1,_=0,b=FT("fill"in u?u.fill:"fill"in n?n.fill:(m=!0,y.fill)),x=BT("stroke"in u?u.stroke:"stroke"in n?n.stroke:!v&&!l&&(!y.autoStroke||m)?(_=ET,y.stroke):null),M=u.textShadowBlur>0||n.textShadowBlur>0;g.text=t.text,g.x=o,g.y=f,M&&(g.shadowBlur=u.textShadowBlur||n.textShadowBlur||0,g.shadowColor=u.textShadowColor||n.textShadowColor||"transparent",g.shadowOffsetX=u.textShadowOffsetX||n.textShadowOffsetX||0,g.shadowOffsetY=u.textShadowOffsetY||n.textShadowOffsetY||0),g.textAlign=s,g.textBaseline="middle",g.font=t.font||$i,g.opacity=Ea(u.opacity,n.opacity,1),kT(g,u),x&&(g.lineWidth=Ea(u.lineWidth,n.lineWidth,_),g.lineDash=Ee(u.lineDash,n.lineDash),g.lineDashOffset=n.lineDashOffset||0,g.stroke=x),b&&(g.fill=b);var w=t.contentWidth,D=t.contentHeight;p.setBoundingRect(new Pe(Bc(g.x,w,g.textAlign),Vl(g.y,D,g.textBaseline),w,D))},e.prototype._renderBackground=function(t,n,a,i,o,s){var l=t.backgroundColor,u=t.borderWidth,c=t.borderColor,f=l&&l.image,h=l&&!f,v=t.borderRadius,d=this,p,g;if(h||t.lineHeight||u&&c){p=this._getOrCreateChild(We),p.useStyle(p.createStyle()),p.style.fill=null;var y=p.shape;y.x=a,y.y=i,y.width=o,y.height=s,y.r=v,p.dirtyShape()}if(h){var m=p.style;m.fill=l||null,m.fillOpacity=Ee(t.fillOpacity,1)}else if(f){g=this._getOrCreateChild(pr),g.onload=function(){d.dirtyStyle()};var _=g.style;_.image=l.image,_.x=a,_.y=i,_.width=o,_.height=s}if(u&&c){var m=p.style;m.lineWidth=u,m.stroke=c,m.strokeOpacity=Ee(t.strokeOpacity,1),m.lineDash=t.borderDash,m.lineDashOffset=t.borderDashOffset||0,p.strokeContainThreshold=0,p.hasFill()&&p.hasStroke()&&(m.strokeFirst=!0,m.lineWidth*=2)}var b=(p||g).style;b.shadowBlur=t.shadowBlur||0,b.shadowColor=t.shadowColor||"transparent",b.shadowOffsetX=t.shadowOffsetX||0,b.shadowOffsetY=t.shadowOffsetY||0,b.opacity=Ea(t.opacity,n.opacity,1)},e.makeFont=function(t){var n="";return RT(t)&&(n=[t.fontStyle,t.fontWeight,zT(t.fontSize),t.fontFamily||"sans-serif"].join(" ")),n&&Pn(n)||t.textFont||t.font},e}(Bn),oG={left:!0,right:1,center:1},sG={top:1,bottom:1,middle:1},PT=["fontStyle","fontWeight","fontSize","fontFamily"];function zT(r){return typeof r=="string"&&(r.indexOf("px")!==-1||r.indexOf("rem")!==-1||r.indexOf("em")!==-1)?r:isNaN(+r)?wm+"px":r+"px"}function kT(r,e){for(var t=0;t<PT.length;t++){var n=PT[t],a=e[n];a!=null&&(r[n]=a)}}function RT(r){return r.fontSize!=null||r.fontFamily||r.fontWeight}function lG(r){return jT(r),C(r.rich,jT),r}function jT(r){if(r){r.font=OT.makeFont(r);var e=r.align;e==="middle"&&(e="center"),r.align=e==null||oG[e]?e:"left";var t=r.verticalAlign;t==="center"&&(t="middle"),r.verticalAlign=t==null||sG[t]?t:"top";var n=r.padding;n&&(r.padding=Tv(r.padding))}}function BT(r,e){return r==null||e<=0||r==="transparent"||r==="none"?null:r.image||r.colorStops?"#000":r}function FT(r){return r==null||r==="none"?null:r.image||r.colorStops?"#000":r}function VT(r,e,t){return e==="right"?r-t[1]:e==="center"?r+t[3]/2-t[1]/2:r+t[3]}function HT(r){var e=r.text;return e!=null&&(e+=""),e}function Q0(r){return!!(r.backgroundColor||r.lineHeight||r.borderWidth&&r.borderColor)}var Ge=OT,Te=Ye(),Z0=function(r,e,t,n){if(n){var a=Te(n);a.dataIndex=t,a.dataType=e,a.seriesIndex=r,n.type==="group"&&n.traverse(function(i){var o=Te(i);o.seriesIndex=r,o.dataIndex=t,o.dataType=e})}},WT=1,GT={},$T=Ye(),q0=Ye(),X0=0,Qc=1,fd=2,Qr=["emphasis","blur","select"],Zc=["normal","emphasis","blur","select"],$l=10,uG=9,ps="highlight",hd="downplay",qc="select",vd="unselect",Xc="toggleSelect";function Ul(r){return r!=null&&r!=="none"}var UT=new Cc(100);function YT(r){if(ce(r)){var e=UT.get(r);return e||(e=Vv(r,-.1),UT.put(r,e)),e}else if(dc(r)){var t=X({},r);return t.colorStops=K(r.colorStops,function(n){return{offset:n.offset,color:Vv(n.color,-.1)}}),t}return r}function dd(r,e,t){r.onHoverStateChange&&(r.hoverState||0)!==t&&r.onHoverStateChange(e),r.hoverState=t}function QT(r){dd(r,"emphasis",fd)}function ZT(r){r.hoverState===fd&&dd(r,"normal",X0)}function J0(r){dd(r,"blur",Qc)}function qT(r){r.hoverState===Qc&&dd(r,"normal",X0)}function cG(r){r.selected=!0}function fG(r){r.selected=!1}function XT(r,e,t){e(r,t)}function yi(r,e,t){XT(r,e,t),r.isGroup&&r.traverse(function(n){XT(n,e,t)})}function pd(r,e){switch(e){case"emphasis":r.hoverState=fd;break;case"normal":r.hoverState=X0;break;case"blur":r.hoverState=Qc;break;case"select":r.selected=!0}}function hG(r,e,t,n){for(var a=r.style,i={},o=0;o<e.length;o++){var s=e[o],l=a[s];i[s]=l==null?n&&n[s]:l}for(var o=0;o<r.animators.length;o++){var u=r.animators[o];u.__fromStateTransition&&u.__fromStateTransition.indexOf(t)<0&&u.targetName==="style"&&u.saveTo(i,e)}return i}function vG(r,e,t,n){var a=t&&ze(t,"select")>=0,i=!1;if(r instanceof je){var o=$T(r),s=a&&o.selectFill||o.normalFill,l=a&&o.selectStroke||o.normalStroke;if(Ul(s)||Ul(l)){n=n||{};var u=n.style||{};u.fill==="inherit"?(i=!0,n=X({},n),u=X({},u),u.fill=s):!Ul(u.fill)&&Ul(s)?(i=!0,n=X({},n),u=X({},u),u.fill=YT(s)):!Ul(u.stroke)&&Ul(l)&&(i||(n=X({},n),u=X({},u)),u.stroke=YT(l)),n.style=u}}if(n&&n.z2==null){i||(n=X({},n));var c=r.z2EmphasisLift;n.z2=r.z2+(c!=null?c:$l)}return n}function dG(r,e,t){if(t&&t.z2==null){t=X({},t);var n=r.z2SelectLift;t.z2=r.z2+(n!=null?n:uG)}return t}function pG(r,e,t){var n=ze(r.currentStates,e)>=0,a=r.style.opacity,i=n?null:hG(r,["opacity"],e,{opacity:1});t=t||{};var o=t.style||{};return o.opacity==null&&(t=X({},t),o=X({opacity:n?a:i.opacity*.1},o),t.style=o),t}function K0(r,e){var t=this.states[r];if(this.style){if(r==="emphasis")return vG(this,r,e,t);if(r==="blur")return pG(this,r,t);if(r==="select")return dG(this,r,t)}return t}function gs(r){r.stateProxy=K0;var e=r.getTextContent(),t=r.getTextGuideLine();e&&(e.stateProxy=K0),t&&(t.stateProxy=K0)}function JT(r,e){!nA(r,e)&&!r.__highByOuter&&yi(r,QT)}function KT(r,e){!nA(r,e)&&!r.__highByOuter&&yi(r,ZT)}function mi(r,e){r.__highByOuter|=1<<(e||0),yi(r,QT)}function _i(r,e){!(r.__highByOuter&=~(1<<(e||0)))&&yi(r,ZT)}function eA(r){yi(r,J0)}function e1(r){yi(r,qT)}function tA(r){yi(r,cG)}function rA(r){yi(r,fG)}function nA(r,e){return r.__highDownSilentOnTouch&&e.zrByTouch}function aA(r){var e=r.getModel(),t=[],n=[];e.eachComponent(function(a,i){var o=q0(i),s=a==="series",l=s?r.getViewOfSeriesModel(i):r.getViewOfComponentModel(i);!s&&n.push(l),o.isBlured&&(l.group.traverse(function(u){qT(u)}),s&&t.push(i)),o.isBlured=!1}),C(n,function(a){a&&a.toggleBlurSeries&&a.toggleBlurSeries(t,!1,e)})}function t1(r,e,t,n){var a=n.getModel();t=t||"coordinateSystem";function i(u,c){for(var f=0;f<c.length;f++){var h=u.getItemGraphicEl(c[f]);h&&e1(h)}}if(r!=null&&!(!e||e==="none")){var o=a.getSeriesByIndex(r),s=o.coordinateSystem;s&&s.master&&(s=s.master);var l=[];a.eachSeries(function(u){var c=o===u,f=u.coordinateSystem;f&&f.master&&(f=f.master);var h=f&&s?f===s:c;if(!(t==="series"&&!c||t==="coordinateSystem"&&!h||e==="series"&&c)){var v=n.getViewOfSeriesModel(u);if(v.group.traverse(function(g){J0(g)}),Mr(e))i(u.getData(),e);else if(_e(e))for(var d=Fe(e),p=0;p<d.length;p++)i(u.getData(d[p]),e[d[p]]);l.push(u),q0(u).isBlured=!0}}),a.eachComponent(function(u,c){if(u!=="series"){var f=n.getViewOfComponentModel(c);f&&f.toggleBlurSeries&&f.toggleBlurSeries(l,!0,a)}})}}function r1(r,e,t){if(!(r==null||e==null)){var n=t.getModel().getComponent(r,e);if(!!n){q0(n).isBlured=!0;var a=t.getViewOfComponentModel(n);!a||!a.focusBlurEnabled||a.group.traverse(function(i){J0(i)})}}}function gG(r,e,t){var n=r.seriesIndex,a=r.getData(e.dataType);if(!!a){var i=as(a,e);i=(J(i)?i[0]:i)||0;var o=a.getItemGraphicEl(i);if(!o)for(var s=a.count(),l=0;!o&&l<s;)o=a.getItemGraphicEl(l++);if(o){var u=Te(o);t1(n,u.focus,u.blurScope,t)}else{var c=r.get(["emphasis","focus"]),f=r.get(["emphasis","blurScope"]);c!=null&&t1(n,c,f,t)}}}function n1(r,e,t,n){var a={focusSelf:!1,dispatchers:null};if(r==null||r==="series"||e==null||t==null)return a;var i=n.getModel().getComponent(r,e);if(!i)return a;var o=n.getViewOfComponentModel(i);if(!o||!o.findHighDownDispatchers)return a;for(var s=o.findHighDownDispatchers(t),l,u=0;u<s.length;u++)if(Te(s[u]).focus==="self"){l=!0;break}return{focusSelf:l,dispatchers:s}}function yG(r,e,t){var n=Te(r),a=n1(n.componentMainType,n.componentIndex,n.componentHighDownName,t),i=a.dispatchers,o=a.focusSelf;i?(o&&r1(n.componentMainType,n.componentIndex,t),C(i,function(s){return JT(s,e)})):(t1(n.seriesIndex,n.focus,n.blurScope,t),n.focus==="self"&&r1(n.componentMainType,n.componentIndex,t),JT(r,e))}function mG(r,e,t){aA(t);var n=Te(r),a=n1(n.componentMainType,n.componentIndex,n.componentHighDownName,t).dispatchers;a?C(a,function(i){return KT(i,e)}):KT(r,e)}function _G(r,e,t){if(!!i1(e)){var n=e.dataType,a=r.getData(n),i=as(a,e);J(i)||(i=[i]),r[e.type===Xc?"toggleSelect":e.type===qc?"select":"unselect"](i,n)}}function iA(r){var e=r.getAllData();C(e,function(t){var n=t.data,a=t.type;n.eachItemGraphicEl(function(i,o){r.isSelected(o,a)?tA(i):rA(i)})})}function bG(r){var e=[];return r.eachSeries(function(t){var n=t.getAllData();C(n,function(a){a.data;var i=a.type,o=t.getSelectedDataIndices();if(o.length>0){var s={dataIndex:o,seriesIndex:t.seriesIndex};i!=null&&(s.dataType=i),e.push(s)}})}),e}function oo(r,e,t){ys(r,!0),yi(r,gs),a1(r,e,t)}function MG(r){ys(r,!1)}function Lt(r,e,t,n){n?MG(r):oo(r,e,t)}function a1(r,e,t){var n=Te(r);e!=null?(n.focus=e,n.blurScope=t):n.focus&&(n.focus=null)}var oA=["emphasis","blur","select"],xG={itemStyle:"getItemStyle",lineStyle:"getLineStyle",areaStyle:"getAreaStyle"};function xr(r,e,t,n){t=t||"itemStyle";for(var a=0;a<oA.length;a++){var i=oA[a],o=e.getModel([i,t]),s=r.ensureState(i);s.style=n?n(o):o[xG[t]]()}}function ys(r,e){var t=e===!1,n=r;r.highDownSilentOnTouch&&(n.__highDownSilentOnTouch=r.highDownSilentOnTouch),(!t||n.__highDownDispatcher)&&(n.__highByOuter=n.__highByOuter||0,n.__highDownDispatcher=!t)}function Jc(r){return!!(r&&r.__highDownDispatcher)}function wG(r,e,t){var n=Te(r);n.componentMainType=e.mainType,n.componentIndex=e.componentIndex,n.componentHighDownName=t}function DG(r){var e=GT[r];return e==null&&WT<=32&&(e=GT[r]=WT++),e}function i1(r){var e=r.type;return e===qc||e===vd||e===Xc}function sA(r){var e=r.type;return e===ps||e===hd}function SG(r){var e=$T(r);e.normalFill=r.style.fill,e.normalStroke=r.style.stroke;var t=r.states.select||{};e.selectFill=t.style&&t.style.fill||null,e.selectStroke=t.style&&t.style.stroke||null}var Yl=Ha.CMD,IG=[[],[],[]],lA=Math.sqrt,TG=Math.atan2;function uA(r,e){if(!!e){var t=r.data,n=r.len(),a,i,o,s,l,u,c=Yl.M,f=Yl.C,h=Yl.L,v=Yl.R,d=Yl.A,p=Yl.Q;for(o=0,s=0;o<n;){switch(a=t[o++],s=o,i=0,a){case c:i=1;break;case h:i=1;break;case f:i=3;break;case p:i=2;break;case d:var g=e[4],y=e[5],m=lA(e[0]*e[0]+e[1]*e[1]),_=lA(e[2]*e[2]+e[3]*e[3]),b=TG(-e[1]/_,e[0]/m);t[o]*=m,t[o++]+=g,t[o]*=_,t[o++]+=y,t[o++]*=m,t[o++]*=_,t[o++]+=b,t[o++]+=b,o+=2,s=o;break;case v:u[0]=t[o++],u[1]=t[o++],vr(u,u,e),t[s++]=u[0],t[s++]=u[1],u[0]+=t[o++],u[1]+=t[o++],vr(u,u,e),t[s++]=u[0],t[s++]=u[1]}for(l=0;l<i;l++){var x=IG[l];x[0]=t[o++],x[1]=t[o++],vr(x,x,e),t[s++]=x[0],t[s++]=x[1]}}r.increaseVersion()}}var o1=Math.sqrt,gd=Math.sin,yd=Math.cos,Kc=Math.PI;function cA(r){return Math.sqrt(r[0]*r[0]+r[1]*r[1])}function s1(r,e){return(r[0]*e[0]+r[1]*e[1])/(cA(r)*cA(e))}function fA(r,e){return(r[0]*e[1]<r[1]*e[0]?-1:1)*Math.acos(s1(r,e))}function hA(r,e,t,n,a,i,o,s,l,u,c){var f=l*(Kc/180),h=yd(f)*(r-t)/2+gd(f)*(e-n)/2,v=-1*gd(f)*(r-t)/2+yd(f)*(e-n)/2,d=h*h/(o*o)+v*v/(s*s);d>1&&(o*=o1(d),s*=o1(d));var p=(a===i?-1:1)*o1((o*o*(s*s)-o*o*(v*v)-s*s*(h*h))/(o*o*(v*v)+s*s*(h*h)))||0,g=p*o*v/s,y=p*-s*h/o,m=(r+t)/2+yd(f)*g-gd(f)*y,_=(e+n)/2+gd(f)*g+yd(f)*y,b=fA([1,0],[(h-g)/o,(v-y)/s]),x=[(h-g)/o,(v-y)/s],M=[(-1*h-g)/o,(-1*v-y)/s],w=fA(x,M);if(s1(x,M)<=-1&&(w=Kc),s1(x,M)>=1&&(w=0),w<0){var D=Math.round(w/Kc*1e6)/1e6;w=Kc*2+D%2*Kc}c.addData(u,m,_,o,s,b,w,f,i)}var AG=/([mlvhzcqtsa])([^mlvhzcqtsa]*)/ig,CG=/-?([0-9]*\.)?[0-9]+([eE]-?[0-9]+)?/g;function NG(r){var e=new Ha;if(!r)return e;var t=0,n=0,a=t,i=n,o,s=Ha.CMD,l=r.match(AG);if(!l)return e;for(var u=0;u<l.length;u++){for(var c=l[u],f=c.charAt(0),h=void 0,v=c.match(CG)||[],d=v.length,p=0;p<d;p++)v[p]=parseFloat(v[p]);for(var g=0;g<d;){var y=void 0,m=void 0,_=void 0,b=void 0,x=void 0,M=void 0,w=void 0,D=t,T=n,I=void 0,A=void 0;switch(f){case"l":t+=v[g++],n+=v[g++],h=s.L,e.addData(h,t,n);break;case"L":t=v[g++],n=v[g++],h=s.L,e.addData(h,t,n);break;case"m":t+=v[g++],n+=v[g++],h=s.M,e.addData(h,t,n),a=t,i=n,f="l";break;case"M":t=v[g++],n=v[g++],h=s.M,e.addData(h,t,n),a=t,i=n,f="L";break;case"h":t+=v[g++],h=s.L,e.addData(h,t,n);break;case"H":t=v[g++],h=s.L,e.addData(h,t,n);break;case"v":n+=v[g++],h=s.L,e.addData(h,t,n);break;case"V":n=v[g++],h=s.L,e.addData(h,t,n);break;case"C":h=s.C,e.addData(h,v[g++],v[g++],v[g++],v[g++],v[g++],v[g++]),t=v[g-2],n=v[g-1];break;case"c":h=s.C,e.addData(h,v[g++]+t,v[g++]+n,v[g++]+t,v[g++]+n,v[g++]+t,v[g++]+n),t+=v[g-2],n+=v[g-1];break;case"S":y=t,m=n,I=e.len(),A=e.data,o===s.C&&(y+=t-A[I-4],m+=n-A[I-3]),h=s.C,D=v[g++],T=v[g++],t=v[g++],n=v[g++],e.addData(h,y,m,D,T,t,n);break;case"s":y=t,m=n,I=e.len(),A=e.data,o===s.C&&(y+=t-A[I-4],m+=n-A[I-3]),h=s.C,D=t+v[g++],T=n+v[g++],t+=v[g++],n+=v[g++],e.addData(h,y,m,D,T,t,n);break;case"Q":D=v[g++],T=v[g++],t=v[g++],n=v[g++],h=s.Q,e.addData(h,D,T,t,n);break;case"q":D=v[g++]+t,T=v[g++]+n,t+=v[g++],n+=v[g++],h=s.Q,e.addData(h,D,T,t,n);break;case"T":y=t,m=n,I=e.len(),A=e.data,o===s.Q&&(y+=t-A[I-4],m+=n-A[I-3]),t=v[g++],n=v[g++],h=s.Q,e.addData(h,y,m,t,n);break;case"t":y=t,m=n,I=e.len(),A=e.data,o===s.Q&&(y+=t-A[I-4],m+=n-A[I-3]),t+=v[g++],n+=v[g++],h=s.Q,e.addData(h,y,m,t,n);break;case"A":_=v[g++],b=v[g++],x=v[g++],M=v[g++],w=v[g++],D=t,T=n,t=v[g++],n=v[g++],h=s.A,hA(D,T,t,n,M,w,_,b,x,h,e);break;case"a":_=v[g++],b=v[g++],x=v[g++],M=v[g++],w=v[g++],D=t,T=n,t+=v[g++],n+=v[g++],h=s.A,hA(D,T,t,n,M,w,_,b,x,h,e);break}}(f==="z"||f==="Z")&&(h=s.Z,e.addData(h),t=a,n=i),o=h}return e.toStatic(),e}var vA=function(r){xt(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.applyTransform=function(t){},e}(je);function dA(r){return r.setData!=null}function pA(r,e){var t=NG(r),n=X({},e);return n.buildPath=function(a){if(dA(a)){a.setData(t.data);var i=a.getContext();i&&a.rebuildPath(i,1)}else{var i=a;t.rebuildPath(i,1)}},n.applyTransform=function(a){uA(t,a),this.dirtyShape()},n}function gA(r,e){return new vA(pA(r,e))}function LG(r,e){var t=pA(r,e),n=function(a){xt(i,a);function i(o){var s=a.call(this,o)||this;return s.applyTransform=t.applyTransform,s.buildPath=t.buildPath,s}return i}(vA);return n}function EG(r,e){for(var t=[],n=r.length,a=0;a<n;a++){var i=r[a];t.push(i.getUpdatedPathProxy(!0))}var o=new je(e);return o.createPathProxy(),o.buildPath=function(s){if(dA(s)){s.appendPath(t);var l=s.getContext();l&&s.rebuildPath(l,1)}},o}function l1(r,e){e=e||{};var t=new je;return r.shape&&t.setShape(r.shape),t.setStyle(r.style),e.bakeTransform?uA(t.path,r.getComputedTransform()):e.toLocal?t.setLocalTransform(r.getComputedTransform()):t.copyTransform(r),t.buildPath=r.buildPath,t.applyTransform=t.applyTransform,t.z=r.z,t.z2=r.z2,t.zlevel=r.zlevel,t}var OG=function(){function r(){this.cx=0,this.cy=0,this.r=0}return r}(),yA=function(r){xt(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultShape=function(){return new OG},e.prototype.buildPath=function(t,n){t.moveTo(n.cx+n.r,n.cy),t.arc(n.cx,n.cy,n.r,0,Math.PI*2)},e}(je);yA.prototype.type="circle";var pa=yA,PG=function(){function r(){this.cx=0,this.cy=0,this.rx=0,this.ry=0}return r}(),mA=function(r){xt(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultShape=function(){return new PG},e.prototype.buildPath=function(t,n){var a=.5522848,i=n.cx,o=n.cy,s=n.rx,l=n.ry,u=s*a,c=l*a;t.moveTo(i-s,o),t.bezierCurveTo(i-s,o-c,i-u,o-l,i,o-l),t.bezierCurveTo(i+u,o-l,i+s,o-c,i+s,o),t.bezierCurveTo(i+s,o+c,i+u,o+l,i,o+l),t.bezierCurveTo(i-u,o+l,i-s,o+c,i-s,o),t.closePath()},e}(je);mA.prototype.type="ellipse";var md=mA,_A=Math.PI,u1=_A*2,ms=Math.sin,Ql=Math.cos,zG=Math.acos,Pr=Math.atan2,bA=Math.abs,ef=Math.sqrt,tf=Math.max,Wa=Math.min,ga=1e-4;function kG(r,e,t,n,a,i,o,s){var l=t-r,u=n-e,c=o-a,f=s-i,h=f*l-c*u;if(!(h*h<ga))return h=(c*(e-i)-f*(r-a))/h,[r+h*l,e+h*u]}function _d(r,e,t,n,a,i,o){var s=r-t,l=e-n,u=(o?i:-i)/ef(s*s+l*l),c=u*l,f=-u*s,h=r+c,v=e+f,d=t+c,p=n+f,g=(h+d)/2,y=(v+p)/2,m=d-h,_=p-v,b=m*m+_*_,x=a-i,M=h*p-d*v,w=(_<0?-1:1)*ef(tf(0,x*x*b-M*M)),D=(M*_-m*w)/b,T=(-M*m-_*w)/b,I=(M*_+m*w)/b,A=(-M*m+_*w)/b,N=D-g,L=T-y,E=I-g,O=A-y;return N*N+L*L>E*E+O*O&&(D=I,T=A),{cx:D,cy:T,x0:-c,y0:-f,x1:D*(a/x-1),y1:T*(a/x-1)}}function RG(r){var e;if(J(r)){var t=r.length;if(!t)return r;t===1?e=[r[0],r[0],0,0]:t===2?e=[r[0],r[0],r[1],r[1]]:t===3?e=r.concat(r[2]):e=r}else e=[r,r,r,r];return e}function jG(r,e){var t,n=tf(e.r,0),a=tf(e.r0||0,0),i=n>0,o=a>0;if(!(!i&&!o)){if(i||(n=a,a=0),a>n){var s=n;n=a,a=s}var l=e.startAngle,u=e.endAngle;if(!(isNaN(l)||isNaN(u))){var c=e.cx,f=e.cy,h=!!e.clockwise,v=bA(u-l),d=v>u1&&v%u1;if(d>ga&&(v=d),!(n>ga))r.moveTo(c,f);else if(v>u1-ga)r.moveTo(c+n*Ql(l),f+n*ms(l)),r.arc(c,f,n,l,u,!h),a>ga&&(r.moveTo(c+a*Ql(u),f+a*ms(u)),r.arc(c,f,a,u,l,h));else{var p=void 0,g=void 0,y=void 0,m=void 0,_=void 0,b=void 0,x=void 0,M=void 0,w=void 0,D=void 0,T=void 0,I=void 0,A=void 0,N=void 0,L=void 0,E=void 0,O=n*Ql(l),P=n*ms(l),H=a*Ql(u),F=a*ms(u),G=v>ga;if(G){var Z=e.cornerRadius;Z&&(t=RG(Z),p=t[0],g=t[1],y=t[2],m=t[3]);var te=bA(n-a)/2;if(_=Wa(te,y),b=Wa(te,m),x=Wa(te,p),M=Wa(te,g),T=w=tf(_,b),I=D=tf(x,M),(w>ga||D>ga)&&(A=n*Ql(u),N=n*ms(u),L=a*Ql(l),E=a*ms(l),v<_A)){var V=kG(O,P,L,E,A,N,H,F);if(V){var Y=O-V[0],q=P-V[1],Q=A-V[0],ne=N-V[1],oe=1/ms(zG((Y*Q+q*ne)/(ef(Y*Y+q*q)*ef(Q*Q+ne*ne)))/2),ie=ef(V[0]*V[0]+V[1]*V[1]);T=Wa(w,(n-ie)/(oe+1)),I=Wa(D,(a-ie)/(oe-1))}}}if(!G)r.moveTo(c+O,f+P);else if(T>ga){var he=Wa(y,T),k=Wa(m,T),j=_d(L,E,O,P,n,he,h),W=_d(A,N,H,F,n,k,h);r.moveTo(c+j.cx+j.x0,f+j.cy+j.y0),T<w&&he===k?r.arc(c+j.cx,f+j.cy,T,Pr(j.y0,j.x0),Pr(W.y0,W.x0),!h):(he>0&&r.arc(c+j.cx,f+j.cy,he,Pr(j.y0,j.x0),Pr(j.y1,j.x1),!h),r.arc(c,f,n,Pr(j.cy+j.y1,j.cx+j.x1),Pr(W.cy+W.y1,W.cx+W.x1),!h),k>0&&r.arc(c+W.cx,f+W.cy,k,Pr(W.y1,W.x1),Pr(W.y0,W.x0),!h))}else r.moveTo(c+O,f+P),r.arc(c,f,n,l,u,!h);if(!(a>ga)||!G)r.lineTo(c+H,f+F);else if(I>ga){var he=Wa(p,I),k=Wa(g,I),j=_d(H,F,A,N,a,-k,h),W=_d(O,P,L,E,a,-he,h);r.lineTo(c+j.cx+j.x0,f+j.cy+j.y0),I<D&&he===k?r.arc(c+j.cx,f+j.cy,I,Pr(j.y0,j.x0),Pr(W.y0,W.x0),!h):(k>0&&r.arc(c+j.cx,f+j.cy,k,Pr(j.y0,j.x0),Pr(j.y1,j.x1),!h),r.arc(c,f,a,Pr(j.cy+j.y1,j.cx+j.x1),Pr(W.cy+W.y1,W.cx+W.x1),h),he>0&&r.arc(c+W.cx,f+W.cy,he,Pr(W.y1,W.x1),Pr(W.y0,W.x0),!h))}else r.lineTo(c+H,f+F),r.arc(c,f,a,u,l,h)}r.closePath()}}}var BG=function(){function r(){this.cx=0,this.cy=0,this.r0=0,this.r=0,this.startAngle=0,this.endAngle=Math.PI*2,this.clockwise=!0,this.cornerRadius=0}return r}(),MA=function(r){xt(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultShape=function(){return new BG},e.prototype.buildPath=function(t,n){jG(t,n)},e.prototype.isZeroArea=function(){return this.shape.startAngle===this.shape.endAngle||this.shape.r===this.shape.r0},e}(je);MA.prototype.type="sector";var Zr=MA,FG=function(){function r(){this.cx=0,this.cy=0,this.r=0,this.r0=0}return r}(),xA=function(r){xt(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultShape=function(){return new FG},e.prototype.buildPath=function(t,n){var a=n.cx,i=n.cy,o=Math.PI*2;t.moveTo(a+n.r,i),t.arc(a,i,n.r,0,o,!1),t.moveTo(a+n.r0,i),t.arc(a,i,n.r0,0,o,!0)},e}(je);xA.prototype.type="ring";var rf=xA;function VG(r,e,t,n){var a=[],i=[],o=[],s=[],l,u,c,f;if(n){c=[1/0,1/0],f=[-1/0,-1/0];for(var h=0,v=r.length;h<v;h++)ci(c,c,r[h]),fi(f,f,r[h]);ci(c,c,n[0]),fi(f,f,n[1])}for(var h=0,v=r.length;h<v;h++){var d=r[h];if(t)l=r[h?h-1:v-1],u=r[(h+1)%v];else if(h===0||h===v-1){a.push(Oa(r[h]));continue}else l=r[h-1],u=r[h+1];Yi(i,u,l),bc(i,i,e);var p=Cv(d,l),g=Cv(d,u),y=p+g;y!==0&&(p/=y,g/=y),bc(o,i,-p),bc(s,i,g);var m=Lm([],d,o),_=Lm([],d,s);n&&(fi(m,m,c),ci(m,m,f),fi(_,_,c),ci(_,_,f)),a.push(m),a.push(_)}return t&&a.push(a.shift()),a}function wA(r,e,t){var n=e.smooth,a=e.points;if(a&&a.length>=2){if(n){var i=VG(a,n,t,e.smoothConstraint);r.moveTo(a[0][0],a[0][1]);for(var o=a.length,s=0;s<(t?o:o-1);s++){var l=i[s*2],u=i[s*2+1],c=a[(s+1)%o];r.bezierCurveTo(l[0],l[1],u[0],u[1],c[0],c[1])}}else{r.moveTo(a[0][0],a[0][1]);for(var s=1,f=a.length;s<f;s++)r.lineTo(a[s][0],a[s][1])}t&&r.closePath()}}var HG=function(){function r(){this.points=null,this.smooth=0,this.smoothConstraint=null}return r}(),DA=function(r){xt(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultShape=function(){return new HG},e.prototype.buildPath=function(t,n){wA(t,n,!0)},e}(je);DA.prototype.type="polygon";var qr=DA,WG=function(){function r(){this.points=null,this.percent=1,this.smooth=0,this.smoothConstraint=null}return r}(),SA=function(r){xt(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new WG},e.prototype.buildPath=function(t,n){wA(t,n,!1)},e}(je);SA.prototype.type="polyline";var Xr=SA,GG={},$G=function(){function r(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.percent=1}return r}(),IA=function(r){xt(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new $G},e.prototype.buildPath=function(t,n){var a,i,o,s;if(this.subPixelOptimize){var l=AT(GG,n,this.style);a=l.x1,i=l.y1,o=l.x2,s=l.y2}else a=n.x1,i=n.y1,o=n.x2,s=n.y2;var u=n.percent;u!==0&&(t.moveTo(a,i),u<1&&(o=a*(1-u)+o*u,s=i*(1-u)+s*u),t.lineTo(o,s))},e.prototype.pointAt=function(t){var n=this.shape;return[n.x1*(1-t)+n.x2*t,n.y1*(1-t)+n.y2*t]},e}(je);IA.prototype.type="line";var or=IA,ln=[],UG=function(){function r(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.cpx1=0,this.cpy1=0,this.percent=1}return r}();function TA(r,e,t){var n=r.cpx2,a=r.cpy2;return n!=null||a!=null?[(t?dI:ir)(r.x1,r.cpx1,r.cpx2,r.x2,e),(t?dI:ir)(r.y1,r.cpy1,r.cpy2,r.y2,e)]:[(t?Um:dr)(r.x1,r.cpx1,r.x2,e),(t?Um:dr)(r.y1,r.cpy1,r.y2,e)]}var AA=function(r){xt(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new UG},e.prototype.buildPath=function(t,n){var a=n.x1,i=n.y1,o=n.x2,s=n.y2,l=n.cpx1,u=n.cpy1,c=n.cpx2,f=n.cpy2,h=n.percent;h!==0&&(t.moveTo(a,i),c==null||f==null?(h<1&&(Ac(a,l,o,h,ln),l=ln[1],o=ln[2],Ac(i,u,s,h,ln),u=ln[1],s=ln[2]),t.quadraticCurveTo(l,u,o,s)):(h<1&&(Ji(a,l,c,o,h,ln),l=ln[1],c=ln[2],o=ln[3],Ji(i,u,f,s,h,ln),u=ln[1],f=ln[2],s=ln[3]),t.bezierCurveTo(l,u,c,f,o,s)))},e.prototype.pointAt=function(t){return TA(this.shape,t,!1)},e.prototype.tangentAt=function(t){var n=TA(this.shape,t,!0);return Yo(n,n)},e}(je);AA.prototype.type="bezier-curve";var nf=AA,YG=function(){function r(){this.cx=0,this.cy=0,this.r=0,this.startAngle=0,this.endAngle=Math.PI*2,this.clockwise=!0}return r}(),CA=function(r){xt(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new YG},e.prototype.buildPath=function(t,n){var a=n.cx,i=n.cy,o=Math.max(n.r,0),s=n.startAngle,l=n.endAngle,u=n.clockwise,c=Math.cos(s),f=Math.sin(s);t.moveTo(c*o+a,f*o+i),t.arc(a,i,o,s,l,!u)},e}(je);CA.prototype.type="arc";var bd=CA,QG=function(r){xt(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="compound",t}return e.prototype._updatePathDirty=function(){for(var t=this.shape.paths,n=this.shapeChanged(),a=0;a<t.length;a++)n=n||t[a].shapeChanged();n&&this.dirtyShape()},e.prototype.beforeBrush=function(){this._updatePathDirty();for(var t=this.shape.paths||[],n=this.getGlobalScale(),a=0;a<t.length;a++)t[a].path||t[a].createPathProxy(),t[a].path.setScale(n[0],n[1],t[a].segmentIgnoreThreshold)},e.prototype.buildPath=function(t,n){for(var a=n.paths||[],i=0;i<a.length;i++)a[i].buildPath(t,a[i].shape,!0)},e.prototype.afterBrush=function(){for(var t=this.shape.paths||[],n=0;n<t.length;n++)t[n].pathUpdated()},e.prototype.getBoundingRect=function(){return this._updatePathDirty.call(this),je.prototype.getBoundingRect.call(this)},e}(je),Md=QG,ZG=function(){function r(e){this.colorStops=e||[]}return r.prototype.addColorStop=function(e,t){this.colorStops.push({offset:e,color:t})},r}(),NA=ZG,qG=function(r){xt(e,r);function e(t,n,a,i,o,s){var l=r.call(this,o)||this;return l.x=t==null?0:t,l.y=n==null?0:n,l.x2=a==null?1:a,l.y2=i==null?0:i,l.type="linear",l.global=s||!1,l}return e}(NA),Zl=qG,XG=function(r){xt(e,r);function e(t,n,a,i,o){var s=r.call(this,i)||this;return s.x=t==null?.5:t,s.y=n==null?.5:n,s.r=a==null?.5:a,s.type="radial",s.global=o||!1,s}return e}(NA),c1=XG,_s=[0,0],bs=[0,0],xd=new Oe,wd=new Oe,JG=function(){function r(e,t){this._corners=[],this._axes=[],this._origin=[0,0];for(var n=0;n<4;n++)this._corners[n]=new Oe;for(var n=0;n<2;n++)this._axes[n]=new Oe;e&&this.fromBoundingRect(e,t)}return r.prototype.fromBoundingRect=function(e,t){var n=this._corners,a=this._axes,i=e.x,o=e.y,s=i+e.width,l=o+e.height;if(n[0].set(i,o),n[1].set(s,o),n[2].set(s,l),n[3].set(i,l),t)for(var u=0;u<4;u++)n[u].transform(t);Oe.sub(a[0],n[1],n[0]),Oe.sub(a[1],n[3],n[0]),a[0].normalize(),a[1].normalize();for(var u=0;u<2;u++)this._origin[u]=a[u].dot(n[0])},r.prototype.intersect=function(e,t){var n=!0,a=!t;return xd.set(1/0,1/0),wd.set(0,0),!this._intersectCheckOneSide(this,e,xd,wd,a,1)&&(n=!1,a)||!this._intersectCheckOneSide(e,this,xd,wd,a,-1)&&(n=!1,a)||a||Oe.copy(t,n?xd:wd),n},r.prototype._intersectCheckOneSide=function(e,t,n,a,i,o){for(var s=!0,l=0;l<2;l++){var u=this._axes[l];if(this._getProjMinMaxOnAxis(l,e._corners,_s),this._getProjMinMaxOnAxis(l,t._corners,bs),_s[1]<bs[0]||_s[0]>bs[1]){if(s=!1,i)return s;var c=Math.abs(bs[0]-_s[1]),f=Math.abs(_s[0]-bs[1]);Math.min(c,f)>a.len()&&(c<f?Oe.scale(a,u,-c*o):Oe.scale(a,u,f*o))}else if(n){var c=Math.abs(bs[0]-_s[1]),f=Math.abs(_s[0]-bs[1]);Math.min(c,f)<n.len()&&(c<f?Oe.scale(n,u,c*o):Oe.scale(n,u,-f*o))}}return s},r.prototype._getProjMinMaxOnAxis=function(e,t,n){for(var a=this._axes[e],i=this._origin,o=t[0].dot(a)+i[e],s=o,l=o,u=1;u<t.length;u++){var c=t[u].dot(a)+i[e];s=Math.min(c,s),l=Math.max(c,l)}n[0]=s,n[1]=l},r}(),Dd=JG,KG=[],e$=function(r){xt(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.notClear=!0,t.incremental=!0,t._displayables=[],t._temporaryDisplayables=[],t._cursor=0,t}return e.prototype.traverse=function(t,n){t.call(n,this)},e.prototype.useStyle=function(){this.style={}},e.prototype.getCursor=function(){return this._cursor},e.prototype.innerAfterBrush=function(){this._cursor=this._displayables.length},e.prototype.clearDisplaybles=function(){this._displayables=[],this._temporaryDisplayables=[],this._cursor=0,this.markRedraw(),this.notClear=!1},e.prototype.clearTemporalDisplayables=function(){this._temporaryDisplayables=[]},e.prototype.addDisplayable=function(t,n){n?this._temporaryDisplayables.push(t):this._displayables.push(t),this.markRedraw()},e.prototype.addDisplayables=function(t,n){n=n||!1;for(var a=0;a<t.length;a++)this.addDisplayable(t[a],n)},e.prototype.getDisplayables=function(){return this._displayables},e.prototype.getTemporalDisplayables=function(){return this._temporaryDisplayables},e.prototype.eachPendingDisplayable=function(t){for(var n=this._cursor;n<this._displayables.length;n++)t&&t(this._displayables[n]);for(var n=0;n<this._temporaryDisplayables.length;n++)t&&t(this._temporaryDisplayables[n])},e.prototype.update=function(){this.updateTransform();for(var t=this._cursor;t<this._displayables.length;t++){var n=this._displayables[t];n.parent=this,n.update(),n.parent=null}for(var t=0;t<this._temporaryDisplayables.length;t++){var n=this._temporaryDisplayables[t];n.parent=this,n.update(),n.parent=null}},e.prototype.getBoundingRect=function(){if(!this._rect){for(var t=new Pe(1/0,1/0,-1/0,-1/0),n=0;n<this._displayables.length;n++){var a=this._displayables[n],i=a.getBoundingRect().clone();a.needLocalTransform()&&i.applyTransform(a.getLocalTransform(KG)),t.union(i)}this._rect=t}return this._rect},e.prototype.contain=function(t,n){var a=this.transformCoordToLocal(t,n),i=this.getBoundingRect();if(i.contain(a[0],a[1]))for(var o=0;o<this._displayables.length;o++){var s=this._displayables[o];if(s.contain(t,n))return!0}return!1},e}(Bn),LA=e$,EA=Ye();function ql(r,e,t,n,a){var i;if(e&&e.ecModel){var o=e.ecModel.getUpdatePayload();i=o&&o.animation}var s=e&&e.isAnimationEnabled(),l=r==="update";if(s){var u=void 0,c=void 0,f=void 0;n?(u=Ee(n.duration,200),c=Ee(n.easing,"cubicOut"),f=0):(u=e.getShallow(l?"animationDurationUpdate":"animationDuration"),c=e.getShallow(l?"animationEasingUpdate":"animationEasing"),f=e.getShallow(l?"animationDelayUpdate":"animationDelay")),i&&(i.duration!=null&&(u=i.duration),i.easing!=null&&(c=i.easing),i.delay!=null&&(f=i.delay)),ye(f)&&(f=f(t,a)),ye(u)&&(u=u(t));var h={duration:u||0,delay:f,easing:c};return h}else return null}function f1(r,e,t,n,a,i,o){var s=!1,l;ye(a)?(o=i,i=a,a=null):_e(a)&&(i=a.cb,o=a.during,s=a.isFrom,l=a.removeOpt,a=a.dataIndex);var u=r==="leave";u||e.stopAnimation("leave");var c=ql(r,n,a,u?l||{}:null,n&&n.getAnimationDelayParams?n.getAnimationDelayParams(e,a):null);if(c&&c.duration>0){var f=c.duration,h=c.delay,v=c.easing,d={duration:f,delay:h||0,easing:v,done:i,force:!!i||!!o,setToFinal:!u,scope:r,during:o};s?e.animateFrom(t,d):e.animateTo(t,d)}else e.stopAnimation(),!s&&e.attr(t),o&&o(1),i&&i()}function Qe(r,e,t,n,a,i){f1("update",r,e,t,n,a,i)}function Dt(r,e,t,n,a,i){f1("enter",r,e,t,n,a,i)}function Xl(r){if(!r.__zr)return!0;for(var e=0;e<r.animators.length;e++){var t=r.animators[e];if(t.scope==="leave")return!0}return!1}function so(r,e,t,n,a,i){Xl(r)||f1("leave",r,e,t,n,a,i)}function OA(r,e,t,n){r.removeTextContent(),r.removeTextGuideLine(),so(r,{style:{opacity:0}},e,t,n)}function af(r,e,t){function n(){r.parent&&r.parent.remove(r)}r.isGroup?r.traverse(function(a){a.isGroup||OA(a,e,t,n)}):OA(r,e,t,n)}function ya(r){EA(r).oldStyle=r.style}function t$(r){return EA(r).oldStyle}var Sd=Math.max,Id=Math.min,h1={};function PA(r){return je.extend(r)}var r$=LG;function zA(r,e){return r$(r,e)}function Vn(r,e){h1[r]=e}function Td(r){if(h1.hasOwnProperty(r))return h1[r]}function of(r,e,t,n){var a=gA(r,e);return t&&(n==="center"&&(t=kA(t,a.getBoundingRect())),d1(a,t)),a}function v1(r,e,t){var n=new pr({style:{image:r,x:e.x,y:e.y,width:e.width,height:e.height},onload:function(a){if(t==="center"){var i={width:a.width,height:a.height};n.setStyle(kA(e,i))}}});return n}function kA(r,e){var t=e.width/e.height,n=r.height*t,a;n<=r.width?a=r.height:(n=r.width,a=n/t);var i=r.x+r.width/2,o=r.y+r.height/2;return{x:i-n/2,y:o-a/2,width:n,height:a}}var xn=EG;function d1(r,e){if(!!r.applyTransform){var t=r.getBoundingRect(),n=t.calculateTransform(e);r.applyTransform(n)}}function Jl(r,e){return AT(r,r,{lineWidth:e}),r}function n$(r){return CT(r.shape,r.shape,r.style),r}var Ad=ds;function lo(r,e){for(var t=xc([]);r&&r!==e;)Pa(t,r.getLocalTransform(),t),r=r.parent;return t}function ma(r,e,t){return e&&!Mr(e)&&(e=di.getLocalTransform(e)),t&&(e=Qo([],e)),vr([],r,e)}function Cd(r,e,t){var n=e[4]===0||e[5]===0||e[0]===0?1:Math.abs(2*e[4]/e[0]),a=e[4]===0||e[5]===0||e[2]===0?1:Math.abs(2*e[4]/e[2]),i=[r==="left"?-n:r==="right"?n:0,r==="top"?-a:r==="bottom"?a:0];return i=ma(i,e,t),Math.abs(i[0])>Math.abs(i[1])?i[0]>0?"right":"left":i[1]>0?"bottom":"top"}function RA(r){return!r.isGroup}function a$(r){return r.shape!=null}function sf(r,e,t){if(!r||!e)return;function n(o){var s={};return o.traverse(function(l){RA(l)&&l.anid&&(s[l.anid]=l)}),s}function a(o){var s={x:o.x,y:o.y,rotation:o.rotation};return a$(o)&&(s.shape=X({},o.shape)),s}var i=n(r);e.traverse(function(o){if(RA(o)&&o.anid){var s=i[o.anid];if(s){var l=a(o);o.attr(a(s)),Qe(o,l,t,Te(o).dataIndex)}}})}function p1(r,e){return K(r,function(t){var n=t[0];n=Sd(n,e.x),n=Id(n,e.x+e.width);var a=t[1];return a=Sd(a,e.y),a=Id(a,e.y+e.height),[n,a]})}function jA(r,e){var t=Sd(r.x,e.x),n=Id(r.x+r.width,e.x+e.width),a=Sd(r.y,e.y),i=Id(r.y+r.height,e.y+e.height);if(n>=t&&i>=a)return{x:t,y:a,width:n-t,height:i-a}}function Kl(r,e,t){var n=X({rectHover:!0},e),a=n.style={strokeNoScale:!0};if(t=t||{x:-1,y:-1,width:2,height:2},r)return r.indexOf("image://")===0?(a.image=r.slice(8),me(a,t),new pr(n)):of(r.replace("path://",""),n,t,"center")}function lf(r,e,t,n,a){for(var i=0,o=a[a.length-1];i<a.length;i++){var s=a[i];if(BA(r,e,t,n,s[0],s[1],o[0],o[1]))return!0;o=s}}function BA(r,e,t,n,a,i,o,s){var l=t-r,u=n-e,c=o-a,f=s-i,h=g1(c,f,l,u);if(i$(h))return!1;var v=r-a,d=e-i,p=g1(v,d,l,u)/h;if(p<0||p>1)return!1;var g=g1(v,d,c,f)/h;return!(g<0||g>1)}function g1(r,e,t,n){return r*n-t*e}function i$(r){return r<=1e-6&&r>=-1e-6}function eu(r){var e=r.itemTooltipOption,t=r.componentModel,n=r.itemName,a=ce(e)?{formatter:e}:e,i=t.mainType,o=t.componentIndex,s={componentType:i,name:n,$vars:["name"]};s[i+"Index"]=o;var l=r.formatterParamsExtra;l&&C(Fe(l),function(c){ve(s,c)||(s[c]=l[c],s.$vars.push(c))});var u=Te(r.el);u.componentMainType=i,u.componentIndex=o,u.tooltipConfig={name:n,option:me({content:n,formatterParams:s},a)}}function FA(r,e){var t;r.isGroup&&(t=e(r)),t||r.traverse(e)}function uo(r,e){if(r)if(J(r))for(var t=0;t<r.length;t++)FA(r[t],e);else FA(r,e)}Vn("circle",pa),Vn("ellipse",md),Vn("sector",Zr),Vn("ring",rf),Vn("polygon",qr),Vn("polyline",Xr),Vn("rect",We),Vn("line",or),Vn("bezierCurve",nf),Vn("arc",bd);var uf=Object.freeze(Object.defineProperty({__proto__:null,updateProps:Qe,initProps:Dt,removeElement:so,removeElementWithFadeOut:af,isElementRemoved:Xl,extendShape:PA,extendPath:zA,registerShape:Vn,getShapeClass:Td,makePath:of,makeImage:v1,mergePath:xn,resizePath:d1,subPixelOptimizeLine:Jl,subPixelOptimizeRect:n$,subPixelOptimize:Ad,getTransform:lo,applyTransform:ma,transformDirection:Cd,groupTransition:sf,clipPointsByRect:p1,clipRectByRect:jA,createIcon:Kl,linePolygonIntersect:lf,lineLineIntersect:BA,setTooltipConfig:eu,traverseElements:uo,Group:De,Image:pr,Text:Ge,Circle:pa,Ellipse:md,Sector:Zr,Ring:rf,Polygon:qr,Polyline:Xr,Rect:We,Line:or,BezierCurve:nf,Arc:bd,IncrementalDisplayable:LA,CompoundPath:Md,LinearGradient:Zl,RadialGradient:c1,BoundingRect:Pe,OrientedBoundingRect:Dd,Point:Oe,Path:je},Symbol.toStringTag,{value:"Module"})),Nd={};function VA(r,e){for(var t=0;t<Qr.length;t++){var n=Qr[t],a=e[n],i=r.ensureState(n);i.style=i.style||{},i.style.text=a}var o=r.currentStates.slice();r.clearStates(!0),r.setStyle({text:e.normal}),r.useStates(o,!0)}function y1(r,e,t){var n=r.labelFetcher,a=r.labelDataIndex,i=r.labelDimIndex,o=e.normal,s;n&&(s=n.getFormattedLabel(a,"normal",null,i,o&&o.get("formatter"),t!=null?{interpolatedValue:t}:null)),s==null&&(s=ye(r.defaultText)?r.defaultText(a,r,t):r.defaultText);for(var l={normal:s},u=0;u<Qr.length;u++){var c=Qr[u],f=e[c];l[c]=Ee(n?n.getFormattedLabel(a,c,null,i,f&&f.get("formatter")):null,s)}return l}function wr(r,e,t,n){t=t||Nd;for(var a=r instanceof Ge,i=!1,o=0;o<Zc.length;o++){var s=e[Zc[o]];if(s&&s.getShallow("show")){i=!0;break}}var l=a?r:r.getTextContent();if(i){a||(l||(l=new Ge,r.setTextContent(l)),r.stateProxy&&(l.stateProxy=r.stateProxy));var u=y1(t,e),c=e.normal,f=!!c.getShallow("show"),h=yt(c,n&&n.normal,t,!1,!a);h.text=u.normal,a||r.setTextConfig(Ld(c,t,!1));for(var o=0;o<Qr.length;o++){var v=Qr[o],s=e[v];if(s){var d=l.ensureState(v),p=!!Ee(s.getShallow("show"),f);if(p!==f&&(d.ignore=!p),d.style=yt(s,n&&n[v],t,!0,!a),d.style.text=u[v],!a){var g=r.ensureState(v);g.textConfig=Ld(s,t,!0)}}}l.silent=!!c.getShallow("silent"),l.style.x!=null&&(h.x=l.style.x),l.style.y!=null&&(h.y=l.style.y),l.ignore=!f,l.useStyle(h),l.dirty(),t.enableTextSetter&&(tu(l).setLabelText=function(y){var m=y1(t,e,y);VA(l,m)})}else l&&(l.ignore=!0);r.dirty()}function sr(r,e){e=e||"label";for(var t={normal:r.getModel(e)},n=0;n<Qr.length;n++){var a=Qr[n];t[a]=r.getModel([a,e])}return t}function yt(r,e,t,n,a){var i={};return o$(i,r,t,n,a),e&&X(i,e),i}function Ld(r,e,t){e=e||{};var n={},a,i=r.getShallow("rotate"),o=Ee(r.getShallow("distance"),t?null:5),s=r.getShallow("offset");return a=r.getShallow("position")||(t?null:"inside"),a==="outside"&&(a=e.defaultOutsidePosition||"top"),a!=null&&(n.position=a),s!=null&&(n.offset=s),i!=null&&(i*=Math.PI/180,n.rotation=i),o!=null&&(n.distance=o),n.outsideFill=r.get("color")==="inherit"?e.inheritColor||null:"auto",n}function o$(r,e,t,n,a){t=t||Nd;var i=e.ecModel,o=i&&i.option.textStyle,s=s$(e),l;if(s){l={};for(var u in s)if(s.hasOwnProperty(u)){var c=e.getModel(["rich",u]);$A(l[u]={},c,o,t,n,a,!1,!0)}}l&&(r.rich=l);var f=e.get("overflow");f&&(r.overflow=f);var h=e.get("minMargin");h!=null&&(r.margin=h),$A(r,e,o,t,n,a,!0,!1)}function s$(r){for(var e;r&&r!==r.ecModel;){var t=(r.option||Nd).rich;if(t){e=e||{};for(var n=Fe(t),a=0;a<n.length;a++){var i=n[a];e[i]=1}}r=r.parentModel}return e}var HA=["fontStyle","fontWeight","fontSize","fontFamily","textShadowColor","textShadowBlur","textShadowOffsetX","textShadowOffsetY"],WA=["align","lineHeight","width","height","tag","verticalAlign"],GA=["padding","borderWidth","borderRadius","borderDashOffset","backgroundColor","borderColor","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"];function $A(r,e,t,n,a,i,o,s){t=!a&&t||Nd;var l=n&&n.inheritColor,u=e.getShallow("color"),c=e.getShallow("textBorderColor"),f=Ee(e.getShallow("opacity"),t.opacity);(u==="inherit"||u==="auto")&&(l?u=l:u=null),(c==="inherit"||c==="auto")&&(l?c=l:c=null),i||(u=u||t.color,c=c||t.textBorderColor),u!=null&&(r.fill=u),c!=null&&(r.stroke=c);var h=Ee(e.getShallow("textBorderWidth"),t.textBorderWidth);h!=null&&(r.lineWidth=h);var v=Ee(e.getShallow("textBorderType"),t.textBorderType);v!=null&&(r.lineDash=v);var d=Ee(e.getShallow("textBorderDashOffset"),t.textBorderDashOffset);d!=null&&(r.lineDashOffset=d),!a&&f==null&&!s&&(f=n&&n.defaultOpacity),f!=null&&(r.opacity=f),!a&&!i&&r.fill==null&&n.inheritColor&&(r.fill=n.inheritColor);for(var p=0;p<HA.length;p++){var g=HA[p],y=Ee(e.getShallow(g),t[g]);y!=null&&(r[g]=y)}for(var p=0;p<WA.length;p++){var g=WA[p],y=e.getShallow(g);y!=null&&(r[g]=y)}if(r.verticalAlign==null){var m=e.getShallow("baseline");m!=null&&(r.verticalAlign=m)}if(!o||!n.disableBox){for(var p=0;p<GA.length;p++){var g=GA[p],y=e.getShallow(g);y!=null&&(r[g]=y)}var _=e.getShallow("borderType");_!=null&&(r.borderDash=_),(r.backgroundColor==="auto"||r.backgroundColor==="inherit")&&l&&(r.backgroundColor=l),(r.borderColor==="auto"||r.borderColor==="inherit")&&l&&(r.borderColor=l)}}function UA(r,e){var t=e&&e.getModel("textStyle");return Pn([r.fontStyle||t&&t.getShallow("fontStyle")||"",r.fontWeight||t&&t.getShallow("fontWeight")||"",(r.fontSize||t&&t.getShallow("fontSize")||12)+"px",r.fontFamily||t&&t.getShallow("fontFamily")||"sans-serif"].join(" "))}var tu=Ye();function YA(r,e,t,n){if(!!r){var a=tu(r);a.prevValue=a.value,a.value=t;var i=e.normal;a.valueAnimation=i.get("valueAnimation"),a.valueAnimation&&(a.precision=i.get("precision"),a.defaultInterpolatedText=n,a.statesModels=e)}}function QA(r,e,t,n,a){var i=tu(r);if(!i.valueAnimation||i.prevValue===i.value)return;var o=i.defaultInterpolatedText,s=Ee(i.interpolatedValue,i.prevValue),l=i.value;function u(c){var f=uT(t,i.precision,s,l,c);i.interpolatedValue=c===1?null:f;var h=y1({labelDataIndex:e,labelFetcher:a,defaultText:o?o(f):f+""},i.statesModels,f);VA(r,h)}r.percent=0,(i.prevValue==null?Dt:Qe)(r,{percent:1},n,e,null,u)}var l$=["textStyle","color"],m1=["fontStyle","fontWeight","fontSize","fontFamily","padding","lineHeight","rich","width","height","overflow"],_1=new Ge,u$=function(){function r(){}return r.prototype.getTextColor=function(e){var t=this.ecModel;return this.getShallow("color")||(!e&&t?t.get(l$):null)},r.prototype.getFont=function(){return UA({fontStyle:this.getShallow("fontStyle"),fontWeight:this.getShallow("fontWeight"),fontSize:this.getShallow("fontSize"),fontFamily:this.getShallow("fontFamily")},this.ecModel)},r.prototype.getTextRect=function(e){for(var t={text:e,verticalAlign:this.getShallow("verticalAlign")||this.getShallow("baseline")},n=0;n<m1.length;n++)t[m1[n]]=this.getShallow(m1[n]);return _1.useStyle(t),_1.update(),_1.getBoundingRect()},r}(),c$=u$,ZA=[["lineWidth","width"],["stroke","color"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"],["lineDash","type"],["lineDashOffset","dashOffset"],["lineCap","cap"],["lineJoin","join"],["miterLimit"]],f$=os(ZA),h$=function(){function r(){}return r.prototype.getLineStyle=function(e){return f$(this,e)},r}(),qA=[["fill","color"],["stroke","borderColor"],["lineWidth","borderWidth"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"],["lineDash","borderType"],["lineDashOffset","borderDashOffset"],["lineCap","borderCap"],["lineJoin","borderJoin"],["miterLimit","borderMiterLimit"]],v$=os(qA),d$=function(){function r(){}return r.prototype.getItemStyle=function(e,t){return v$(this,e,t)},r}(),Ms=function(){function r(e,t,n){this.parentModel=t,this.ecModel=n,this.option=e}return r.prototype.init=function(e,t,n){},r.prototype.mergeOption=function(e,t){Ne(this.option,e,!0)},r.prototype.get=function(e,t){return e==null?this.option:this._doGet(this.parsePath(e),!t&&this.parentModel)},r.prototype.getShallow=function(e,t){var n=this.option,a=n==null?n:n[e];if(a==null&&!t){var i=this.parentModel;i&&(a=i.getShallow(e))}return a},r.prototype.getModel=function(e,t){var n=e!=null,a=n?this.parsePath(e):null,i=n?this._doGet(a):this.option;return t=t||this.parentModel&&this.parentModel.getModel(this.resolveParentPath(a)),new r(i,t,this.ecModel)},r.prototype.isEmpty=function(){return this.option==null},r.prototype.restoreData=function(){},r.prototype.clone=function(){var e=this.constructor;return new e(Me(this.option))},r.prototype.parsePath=function(e){return typeof e=="string"?e.split("."):e},r.prototype.resolveParentPath=function(e){return e},r.prototype.isAnimationEnabled=function(){if(!$e.node&&this.option){if(this.option.animation!=null)return!!this.option.animation;if(this.parentModel)return this.parentModel.isAnimationEnabled()}},r.prototype._doGet=function(e,t){var n=this.option;if(!e)return n;for(var a=0;a<e.length&&!(!!e[a]&&(n=n&&typeof n=="object"?n[e[a]]:null,n==null));a++);return n==null&&t&&(n=t._doGet(this.resolveParentPath(e),t.parentModel)),n},r}();E0(Ms),mW(Ms),Et(Ms,h$),Et(Ms,d$),Et(Ms,wW),Et(Ms,c$);var ft=Ms,p$=Math.round(Math.random()*10);function ru(r){return[r||"",p$++].join("_")}function g$(r){var e={};r.registerSubTypeDefaulter=function(t,n){var a=ja(t);e[a.main]=n},r.determineSubType=function(t,n){var a=n.type;if(!a){var i=ja(t).main;r.hasSubTypes(t)&&e[i]&&(a=e[i](n))}return a}}function y$(r,e){r.topologicalTravel=function(i,o,s,l){if(!i.length)return;var u=t(o),c=u.graph,f=u.noEntryList,h={};for(C(i,function(m){h[m]=!0});f.length;){var v=f.pop(),d=c[v],p=!!h[v];p&&(s.call(l,v,d.originalDeps.slice()),delete h[v]),C(d.successor,p?y:g)}C(h,function(){var m="";throw new Error(m)});function g(m){c[m].entryCount--,c[m].entryCount===0&&f.push(m)}function y(m){h[m]=!0,g(m)}};function t(i){var o={},s=[];return C(i,function(l){var u=n(o,l),c=u.originalDeps=e(l),f=a(c,i);u.entryCount=f.length,u.entryCount===0&&s.push(l),C(f,function(h){ze(u.predecessor,h)<0&&u.predecessor.push(h);var v=n(o,h);ze(v.successor,h)<0&&v.successor.push(l)})}),{graph:o,noEntryList:s}}function n(i,o){return i[o]||(i[o]={predecessor:[],successor:[]}),i[o]}function a(i,o){var s=[];return C(i,function(l){ze(o,l)>=0&&s.push(l)}),s}}function co(r,e){return Ne(Ne({},r,!0),e,!0)}var m$={time:{month:["January","February","March","April","May","June","July","August","September","October","November","December"],monthAbbr:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],dayOfWeek:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayOfWeekAbbr:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"]},legend:{selector:{all:"All",inverse:"Inv"}},toolbox:{brush:{title:{rect:"Box Select",polygon:"Lasso Select",lineX:"Horizontally Select",lineY:"Vertically Select",keep:"Keep Selections",clear:"Clear Selections"}},dataView:{title:"Data View",lang:["Data View","Close","Refresh"]},dataZoom:{title:{zoom:"Zoom",back:"Zoom Reset"}},magicType:{title:{line:"Switch to Line Chart",bar:"Switch to Bar Chart",stack:"Stack",tiled:"Tile"}},restore:{title:"Restore"},saveAsImage:{title:"Save as Image",lang:["Right Click to Save Image"]}},series:{typeNames:{pie:"Pie chart",bar:"Bar chart",line:"Line chart",scatter:"Scatter plot",effectScatter:"Ripple scatter plot",radar:"Radar chart",tree:"Tree",treemap:"Treemap",boxplot:"Boxplot",candlestick:"Candlestick",k:"K line chart",heatmap:"Heat map",map:"Map",parallel:"Parallel coordinate map",lines:"Line graph",graph:"Relationship graph",sankey:"Sankey diagram",funnel:"Funnel chart",gauge:"Gauge",pictorialBar:"Pictorial bar",themeRiver:"Theme River Map",sunburst:"Sunburst"}},aria:{general:{withTitle:'This is a chart about "{title}"',withoutTitle:"This is a chart"},series:{single:{prefix:"",withName:" with type {seriesType} named {seriesName}.",withoutName:" with type {seriesType}."},multiple:{prefix:". It consists of {seriesCount} series count.",withName:" The {seriesId} series is a {seriesType} representing {seriesName}.",withoutName:" The {seriesId} series is a {seriesType}.",separator:{middle:"",end:""}}},data:{allData:"The data is as follows: ",partialData:"The first {displayCnt} items are: ",withName:"the data for {name} is {value}",withoutName:"{value}",separator:{middle:", ",end:". "}}}},_$={time:{month:["\u4E00\u6708","\u4E8C\u6708","\u4E09\u6708","\u56DB\u6708","\u4E94\u6708","\u516D\u6708","\u4E03\u6708","\u516B\u6708","\u4E5D\u6708","\u5341\u6708","\u5341\u4E00\u6708","\u5341\u4E8C\u6708"],monthAbbr:["1\u6708","2\u6708","3\u6708","4\u6708","5\u6708","6\u6708","7\u6708","8\u6708","9\u6708","10\u6708","11\u6708","12\u6708"],dayOfWeek:["\u661F\u671F\u65E5","\u661F\u671F\u4E00","\u661F\u671F\u4E8C","\u661F\u671F\u4E09","\u661F\u671F\u56DB","\u661F\u671F\u4E94","\u661F\u671F\u516D"],dayOfWeekAbbr:["\u65E5","\u4E00","\u4E8C","\u4E09","\u56DB","\u4E94","\u516D"]},legend:{selector:{all:"\u5168\u9009",inverse:"\u53CD\u9009"}},toolbox:{brush:{title:{rect:"\u77E9\u5F62\u9009\u62E9",polygon:"\u5708\u9009",lineX:"\u6A2A\u5411\u9009\u62E9",lineY:"\u7EB5\u5411\u9009\u62E9",keep:"\u4FDD\u6301\u9009\u62E9",clear:"\u6E05\u9664\u9009\u62E9"}},dataView:{title:"\u6570\u636E\u89C6\u56FE",lang:["\u6570\u636E\u89C6\u56FE","\u5173\u95ED","\u5237\u65B0"]},dataZoom:{title:{zoom:"\u533A\u57DF\u7F29\u653E",back:"\u533A\u57DF\u7F29\u653E\u8FD8\u539F"}},magicType:{title:{line:"\u5207\u6362\u4E3A\u6298\u7EBF\u56FE",bar:"\u5207\u6362\u4E3A\u67F1\u72B6\u56FE",stack:"\u5207\u6362\u4E3A\u5806\u53E0",tiled:"\u5207\u6362\u4E3A\u5E73\u94FA"}},restore:{title:"\u8FD8\u539F"},saveAsImage:{title:"\u4FDD\u5B58\u4E3A\u56FE\u7247",lang:["\u53F3\u952E\u53E6\u5B58\u4E3A\u56FE\u7247"]}},series:{typeNames:{pie:"\u997C\u56FE",bar:"\u67F1\u72B6\u56FE",line:"\u6298\u7EBF\u56FE",scatter:"\u6563\u70B9\u56FE",effectScatter:"\u6D9F\u6F2A\u6563\u70B9\u56FE",radar:"\u96F7\u8FBE\u56FE",tree:"\u6811\u56FE",treemap:"\u77E9\u5F62\u6811\u56FE",boxplot:"\u7BB1\u578B\u56FE",candlestick:"K\u7EBF\u56FE",k:"K\u7EBF\u56FE",heatmap:"\u70ED\u529B\u56FE",map:"\u5730\u56FE",parallel:"\u5E73\u884C\u5750\u6807\u56FE",lines:"\u7EBF\u56FE",graph:"\u5173\u7CFB\u56FE",sankey:"\u6851\u57FA\u56FE",funnel:"\u6F0F\u6597\u56FE",gauge:"\u4EEA\u8868\u76D8\u56FE",pictorialBar:"\u8C61\u5F62\u67F1\u56FE",themeRiver:"\u4E3B\u9898\u6CB3\u6D41\u56FE",sunburst:"\u65ED\u65E5\u56FE"}},aria:{general:{withTitle:"\u8FD9\u662F\u4E00\u4E2A\u5173\u4E8E\u201C{title}\u201D\u7684\u56FE\u8868\u3002",withoutTitle:"\u8FD9\u662F\u4E00\u4E2A\u56FE\u8868\uFF0C"},series:{single:{prefix:"",withName:"\u56FE\u8868\u7C7B\u578B\u662F{seriesType}\uFF0C\u8868\u793A{seriesName}\u3002",withoutName:"\u56FE\u8868\u7C7B\u578B\u662F{seriesType}\u3002"},multiple:{prefix:"\u5B83\u7531{seriesCount}\u4E2A\u56FE\u8868\u7CFB\u5217\u7EC4\u6210\u3002",withName:"\u7B2C{seriesId}\u4E2A\u7CFB\u5217\u662F\u4E00\u4E2A\u8868\u793A{seriesName}\u7684{seriesType}\uFF0C",withoutName:"\u7B2C{seriesId}\u4E2A\u7CFB\u5217\u662F\u4E00\u4E2A{seriesType}\uFF0C",separator:{middle:"\uFF1B",end:"\u3002"}}},data:{allData:"\u5176\u6570\u636E\u662F\u2014\u2014",partialData:"\u5176\u4E2D\uFF0C\u524D{displayCnt}\u9879\u662F\u2014\u2014",withName:"{name}\u7684\u6570\u636E\u662F{value}",withoutName:"{value}",separator:{middle:"\uFF0C",end:""}}}},Ed="ZH",b1="EN",cf=b1,Od={},M1={},XA=$e.domSupported?function(){var r=(document.documentElement.lang||navigator.language||navigator.browserLanguage).toUpperCase();return r.indexOf(Ed)>-1?Ed:cf}():cf;function x1(r,e){r=r.toUpperCase(),M1[r]=new ft(e),Od[r]=e}function b$(r){if(ce(r)){var e=Od[r.toUpperCase()]||{};return r===Ed||r===b1?Me(e):Ne(Me(e),Me(Od[cf]),!1)}else return Ne(Me(r),Me(Od[cf]),!1)}function w1(r){return M1[r]}function M$(){return M1[cf]}x1(b1,m$),x1(Ed,_$);var D1=1e3,S1=D1*60,ff=S1*60,Hn=ff*24,JA=Hn*365,hf={year:"{yyyy}",month:"{MMM}",day:"{d}",hour:"{HH}:{mm}",minute:"{HH}:{mm}",second:"{HH}:{mm}:{ss}",millisecond:"{HH}:{mm}:{ss} {SSS}",none:"{yyyy}-{MM}-{dd} {HH}:{mm}:{ss} {SSS}"},Pd="{yyyy}-{MM}-{dd}",KA={year:"{yyyy}",month:"{yyyy}-{MM}",day:Pd,hour:Pd+" "+hf.hour,minute:Pd+" "+hf.minute,second:Pd+" "+hf.second,millisecond:hf.none},I1=["year","month","day","hour","minute","second","millisecond"],eC=["year","half-year","quarter","month","week","half-week","day","half-day","quarter-day","hour","minute","second","millisecond"];function un(r,e){return r+="","0000".substr(0,e-r.length)+r}function nu(r){switch(r){case"half-year":case"quarter":return"month";case"week":case"half-week":return"day";case"half-day":case"quarter-day":return"hour";default:return r}}function x$(r){return r===nu(r)}function w$(r){switch(r){case"year":case"month":return"day";case"millisecond":return"millisecond";default:return"second"}}function vf(r,e,t,n){var a=Mn(r),i=a[T1(t)](),o=a[au(t)]()+1,s=Math.floor((o-1)/3)+1,l=a[zd(t)](),u=a["get"+(t?"UTC":"")+"Day"](),c=a[df(t)](),f=(c-1)%12+1,h=a[kd(t)](),v=a[Rd(t)](),d=a[jd(t)](),p=n instanceof ft?n:w1(n||XA)||M$(),g=p.getModel("time"),y=g.get("month"),m=g.get("monthAbbr"),_=g.get("dayOfWeek"),b=g.get("dayOfWeekAbbr");return(e||"").replace(/{yyyy}/g,i+"").replace(/{yy}/g,i%100+"").replace(/{Q}/g,s+"").replace(/{MMMM}/g,y[o-1]).replace(/{MMM}/g,m[o-1]).replace(/{MM}/g,un(o,2)).replace(/{M}/g,o+"").replace(/{dd}/g,un(l,2)).replace(/{d}/g,l+"").replace(/{eeee}/g,_[u]).replace(/{ee}/g,b[u]).replace(/{e}/g,u+"").replace(/{HH}/g,un(c,2)).replace(/{H}/g,c+"").replace(/{hh}/g,un(f+"",2)).replace(/{h}/g,f+"").replace(/{mm}/g,un(h,2)).replace(/{m}/g,h+"").replace(/{ss}/g,un(v,2)).replace(/{s}/g,v+"").replace(/{SSS}/g,un(d,3)).replace(/{S}/g,d+"")}function D$(r,e,t,n,a){var i=null;if(ce(t))i=t;else if(ye(t))i=t(r.value,e,{level:r.level});else{var o=X({},hf);if(r.level>0)for(var s=0;s<I1.length;++s)o[I1[s]]="{primary|"+o[I1[s]]+"}";var l=t?t.inherit===!1?t:me(t,o):o,u=tC(r.value,a);if(l[u])i=l[u];else if(l.inherit){for(var c=eC.indexOf(u),s=c-1;s>=0;--s)if(l[u]){i=l[u];break}i=i||o.none}if(J(i)){var f=r.level==null?0:r.level>=0?r.level:i.length+r.level;f=Math.min(f,i.length-1),i=i[f]}}return vf(new Date(r.value),i,a,n)}function tC(r,e){var t=Mn(r),n=t[au(e)]()+1,a=t[zd(e)](),i=t[df(e)](),o=t[kd(e)](),s=t[Rd(e)](),l=t[jd(e)](),u=l===0,c=u&&s===0,f=c&&o===0,h=f&&i===0,v=h&&a===1,d=v&&n===1;return d?"year":v?"month":h?"day":f?"hour":c?"minute":u?"second":"millisecond"}function rC(r,e,t){var n=Ue(r)?Mn(r):r;switch(e=e||tC(r,t),e){case"year":return n[T1(t)]();case"half-year":return n[au(t)]()>=6?1:0;case"quarter":return Math.floor((n[au(t)]()+1)/4);case"month":return n[au(t)]();case"day":return n[zd(t)]();case"half-day":return n[df(t)]()/24;case"hour":return n[df(t)]();case"minute":return n[kd(t)]();case"second":return n[Rd(t)]();case"millisecond":return n[jd(t)]()}}function T1(r){return r?"getUTCFullYear":"getFullYear"}function au(r){return r?"getUTCMonth":"getMonth"}function zd(r){return r?"getUTCDate":"getDate"}function df(r){return r?"getUTCHours":"getHours"}function kd(r){return r?"getUTCMinutes":"getMinutes"}function Rd(r){return r?"getUTCSeconds":"getSeconds"}function jd(r){return r?"getUTCMilliseconds":"getMilliseconds"}function S$(r){return r?"setUTCFullYear":"setFullYear"}function nC(r){return r?"setUTCMonth":"setMonth"}function aC(r){return r?"setUTCDate":"setDate"}function iC(r){return r?"setUTCHours":"setHours"}function oC(r){return r?"setUTCMinutes":"setMinutes"}function sC(r){return r?"setUTCSeconds":"setSeconds"}function lC(r){return r?"setUTCMilliseconds":"setMilliseconds"}function I$(r,e,t,n,a,i,o,s){var l=new Ge({style:{text:r,font:e,align:t,verticalAlign:n,padding:a,rich:i,overflow:o?"truncate":null,lineHeight:s}});return l.getBoundingRect()}function A1(r){if(!A0(r))return ce(r)?r:"-";var e=(r+"").split(".");return e[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g,"$1,")+(e.length>1?"."+e[1]:"")}function C1(r,e){return r=(r||"").toLowerCase().replace(/-(.)/g,function(t,n){return n.toUpperCase()}),e&&r&&(r=r.charAt(0).toUpperCase()+r.slice(1)),r}var xs=Tv;function N1(r,e,t){var n="{yyyy}-{MM}-{dd} {HH}:{mm}:{ss}";function a(c){return c&&Pn(c)?c:"-"}function i(c){return!!(c!=null&&!isNaN(c)&&isFinite(c))}var o=e==="time",s=r instanceof Date;if(o||s){var l=o?Mn(r):r;if(isNaN(+l)){if(s)return"-"}else return vf(l,n,t)}if(e==="ordinal")return Sv(r)?a(r):Ue(r)&&i(r)?r+"":"-";var u=Ra(r);return i(u)?A1(u):Sv(r)?a(r):typeof r=="boolean"?r+"":"-"}var uC=["a","b","c","d","e","f","g"],L1=function(r,e){return"{"+r+(e==null?"":e)+"}"};function E1(r,e,t){J(e)||(e=[e]);var n=e.length;if(!n)return"";for(var a=e[0].$vars||[],i=0;i<a.length;i++){var o=uC[i];r=r.replace(L1(o),L1(o,0))}for(var s=0;s<n;s++)for(var l=0;l<a.length;l++){var u=e[s][a[l]];r=r.replace(L1(uC[l],s),t?$r(u):u)}return r}function T$(r,e,t){return C(e,function(n,a){r=r.replace("{"+a+"}",t?$r(n):n)}),r}function cC(r,e){var t=ce(r)?{color:r,extraCssText:e}:r||{},n=t.color,a=t.type;e=t.extraCssText;var i=t.renderMode||"html";if(!n)return"";if(i==="html")return a==="subItem"?'<span style="display:inline-block;vertical-align:middle;margin-right:8px;margin-left:3px;border-radius:4px;width:4px;height:4px;background-color:'+$r(n)+";"+(e||"")+'"></span>':'<span style="display:inline-block;margin-right:4px;border-radius:10px;width:10px;height:10px;background-color:'+$r(n)+";"+(e||"")+'"></span>';var o=t.markerId||"markerX";return{renderMode:i,content:"{"+o+"|} ",style:a==="subItem"?{width:4,height:4,borderRadius:2,backgroundColor:n}:{width:10,height:10,borderRadius:5,backgroundColor:n}}}function A$(r,e,t){(r==="week"||r==="month"||r==="quarter"||r==="half-year"||r==="year")&&(r=`MM-dd
|
|
230
|
+
yyyy`);var n=Mn(e),a=t?"getUTC":"get",i=n[a+"FullYear"](),o=n[a+"Month"]()+1,s=n[a+"Date"](),l=n[a+"Hours"](),u=n[a+"Minutes"](),c=n[a+"Seconds"](),f=n[a+"Milliseconds"]();return r=r.replace("MM",un(o,2)).replace("M",o).replace("yyyy",i).replace("yy",un(i%100+"",2)).replace("dd",un(s,2)).replace("d",s).replace("hh",un(l,2)).replace("h",l).replace("mm",un(u,2)).replace("m",u).replace("ss",un(c,2)).replace("s",c).replace("SSS",un(f,3)),r}function C$(r){return r&&r.charAt(0).toUpperCase()+r.substr(1)}function ws(r,e){return e=e||"transparent",ce(r)?r:_e(r)&&r.colorStops&&(r.colorStops[0]||{}).color||e}function Bd(r,e){if(e==="_blank"||e==="blank"){var t=window.open();t.opener=null,t.location.href=r}else window.open(r,e)}var Fd=C,fC=["left","right","top","bottom","width","height"],Ds=[["width","left","right"],["height","top","bottom"]];function O1(r,e,t,n,a){var i=0,o=0;n==null&&(n=1/0),a==null&&(a=1/0);var s=0;e.eachChild(function(l,u){var c=l.getBoundingRect(),f=e.childAt(u+1),h=f&&f.getBoundingRect(),v,d;if(r==="horizontal"){var p=c.width+(h?-h.x+c.x:0);v=i+p,v>n||l.newline?(i=0,v=p,o+=s+t,s=c.height):s=Math.max(s,c.height)}else{var g=c.height+(h?-h.y+c.y:0);d=o+g,d>a||l.newline?(i+=s+t,o=0,d=g,s=c.width):s=Math.max(s,c.width)}l.newline||(l.x=i,l.y=o,l.markRedraw(),r==="horizontal"?i=v+t:o=d+t)})}var Ss=O1;Ae(O1,"vertical"),Ae(O1,"horizontal");function N$(r,e,t){var n=e.width,a=e.height,i=ue(r.left,n),o=ue(r.top,a),s=ue(r.right,n),l=ue(r.bottom,a);return(isNaN(i)||isNaN(parseFloat(r.left)))&&(i=0),(isNaN(s)||isNaN(parseFloat(r.right)))&&(s=n),(isNaN(o)||isNaN(parseFloat(r.top)))&&(o=0),(isNaN(l)||isNaN(parseFloat(r.bottom)))&&(l=a),t=xs(t||0),{width:Math.max(s-i-t[1]-t[3],0),height:Math.max(l-o-t[0]-t[2],0)}}function Yt(r,e,t){t=xs(t||0);var n=e.width,a=e.height,i=ue(r.left,n),o=ue(r.top,a),s=ue(r.right,n),l=ue(r.bottom,a),u=ue(r.width,n),c=ue(r.height,a),f=t[2]+t[0],h=t[1]+t[3],v=r.aspect;switch(isNaN(u)&&(u=n-s-h-i),isNaN(c)&&(c=a-l-f-o),v!=null&&(isNaN(u)&&isNaN(c)&&(v>n/a?u=n*.8:c=a*.8),isNaN(u)&&(u=v*c),isNaN(c)&&(c=u/v)),isNaN(i)&&(i=n-s-u-h),isNaN(o)&&(o=a-l-c-f),r.left||r.right){case"center":i=n/2-u/2-t[3];break;case"right":i=n-u-h;break}switch(r.top||r.bottom){case"middle":case"center":o=a/2-c/2-t[0];break;case"bottom":o=a-c-f;break}i=i||0,o=o||0,isNaN(u)&&(u=n-h-i-(s||0)),isNaN(c)&&(c=a-f-o-(l||0));var d=new Pe(i+t[3],o+t[0],u,c);return d.margin=t,d}function Vd(r,e,t,n,a,i){var o=!a||!a.hv||a.hv[0],s=!a||!a.hv||a.hv[1],l=a&&a.boundingMode||"all";if(i=i||r,i.x=r.x,i.y=r.y,!o&&!s)return!1;var u;if(l==="raw")u=r.type==="group"?new Pe(0,0,+e.width||0,+e.height||0):r.getBoundingRect();else if(u=r.getBoundingRect(),r.needLocalTransform()){var c=r.getLocalTransform();u=u.clone(),u.applyTransform(c)}var f=Yt(me({width:u.width,height:u.height},e),t,n),h=o?f.x-u.x:0,v=s?f.y-u.y:0;return l==="raw"?(i.x=h,i.y=v):(i.x+=h,i.y+=v),i===r&&r.markRedraw(),!0}function L$(r,e){return r[Ds[e][0]]!=null||r[Ds[e][1]]!=null&&r[Ds[e][2]]!=null}function pf(r){var e=r.layoutMode||r.constructor.layoutMode;return _e(e)?e:e?{type:e}:null}function fo(r,e,t){var n=t&&t.ignoreSize;!J(n)&&(n=[n,n]);var a=o(Ds[0],0),i=o(Ds[1],1);u(Ds[0],r,a),u(Ds[1],r,i);function o(c,f){var h={},v=0,d={},p=0,g=2;if(Fd(c,function(_){d[_]=r[_]}),Fd(c,function(_){s(e,_)&&(h[_]=d[_]=e[_]),l(h,_)&&v++,l(d,_)&&p++}),n[f])return l(e,c[1])?d[c[2]]=null:l(e,c[2])&&(d[c[1]]=null),d;if(p===g||!v)return d;if(v>=g)return h;for(var y=0;y<c.length;y++){var m=c[y];if(!s(h,m)&&s(r,m)){h[m]=r[m];break}}return h}function s(c,f){return c.hasOwnProperty(f)}function l(c,f){return c[f]!=null&&c[f]!=="auto"}function u(c,f,h){Fd(c,function(v){f[v]=h[v]})}}function iu(r){return hC({},r)}function hC(r,e){return e&&r&&Fd(fC,function(t){e.hasOwnProperty(t)&&(r[t]=e[t])}),r}var E$=Ye(),ou=function(r){U(e,r);function e(t,n,a){var i=r.call(this,t,n,a)||this;return i.uid=ru("ec_cpt_model"),i}return e.prototype.init=function(t,n,a){this.mergeDefaultAndTheme(t,a)},e.prototype.mergeDefaultAndTheme=function(t,n){var a=pf(this),i=a?iu(t):{},o=n.getTheme();Ne(t,o.get(this.mainType)),Ne(t,this.getDefaultOption()),a&&fo(t,i,a)},e.prototype.mergeOption=function(t,n){Ne(this.option,t,!0);var a=pf(this);a&&fo(this.option,t,a)},e.prototype.optionUpdated=function(t,n){},e.prototype.getDefaultOption=function(){var t=this.constructor;if(!pW(t))return t.defaultOption;var n=E$(this);if(!n.defaultOption){for(var a=[],i=t;i;){var o=i.prototype.defaultOption;o&&a.push(o),i=i.superClass}for(var s={},l=a.length-1;l>=0;l--)s=Ne(s,a[l],!0);n.defaultOption=s}return n.defaultOption},e.prototype.getReferringComponents=function(t,n){var a=t+"Index",i=t+"Id";return Gc(this.ecModel,t,{index:this.get(a,!0),id:this.get(i,!0)},n)},e.prototype.getBoxLayoutParams=function(){var t=this;return{left:t.get("left"),top:t.get("top"),right:t.get("right"),bottom:t.get("bottom"),width:t.get("width"),height:t.get("height")}},e.prototype.getZLevelKey=function(){return""},e.prototype.setZLevel=function(t){this.option.zlevel=t},e.protoInitialize=function(){var t=e.prototype;t.type="component",t.id="",t.name="",t.mainType="",t.subType="",t.componentIndex=0}(),e}(ft);fT(ou,ft),nd(ou),g$(ou),y$(ou,O$);function O$(r){var e=[];return C(ou.getClassesByMainType(r),function(t){e=e.concat(t.dependencies||t.prototype.dependencies||[])}),e=K(e,function(t){return ja(t).main}),r!=="dataset"&&ze(e,"dataset")<=0&&e.unshift("dataset"),e}var He=ou,vC="";typeof navigator!="undefined"&&(vC=navigator.platform||"");var su="rgba(0, 0, 0, 0.2)",P$={darkMode:"auto",colorBy:"series",color:["#5470c6","#91cc75","#fac858","#ee6666","#73c0de","#3ba272","#fc8452","#9a60b4","#ea7ccc"],gradientColor:["#f6efa6","#d88273","#bf444c"],aria:{decal:{decals:[{color:su,dashArrayX:[1,0],dashArrayY:[2,5],symbolSize:1,rotation:Math.PI/6},{color:su,symbol:"circle",dashArrayX:[[8,8],[0,8,8,0]],dashArrayY:[6,0],symbolSize:.8},{color:su,dashArrayX:[1,0],dashArrayY:[4,3],rotation:-Math.PI/4},{color:su,dashArrayX:[[6,6],[0,6,6,0]],dashArrayY:[6,0]},{color:su,dashArrayX:[[1,0],[1,6]],dashArrayY:[1,0,6,0],rotation:Math.PI/4},{color:su,symbol:"triangle",dashArrayX:[[9,9],[0,9,9,0]],dashArrayY:[7,2],symbolSize:.75}]}},textStyle:{fontFamily:vC.match(/^Win/)?"Microsoft YaHei":"sans-serif",fontSize:12,fontStyle:"normal",fontWeight:"normal"},blendMode:null,stateAnimation:{duration:300,easing:"cubicOut"},animation:"auto",animationDuration:1e3,animationDurationUpdate:500,animationEasing:"cubicInOut",animationEasingUpdate:"cubicInOut",animationThreshold:2e3,progressiveThreshold:3e3,progressive:400,hoverLayerThreshold:3e3,useUTC:!1},dC=ge(["tooltip","label","itemName","itemId","itemGroupId","seriesName"]),Wn="original",zr="arrayRows",Gn="objectRows",Ga="keyedColumns",ho="typedArray",pC="unknown",$a="column",lu="row",Dr={Must:1,Might:2,Not:3},gC=Ye();function z$(r){gC(r).datasetMap=ge()}function yC(r,e,t){var n={},a=z1(e);if(!a||!r)return n;var i=[],o=[],s=e.ecModel,l=gC(s).datasetMap,u=a.uid+"_"+t.seriesLayoutBy,c,f;r=r.slice(),C(r,function(p,g){var y=_e(p)?p:r[g]={name:p};y.type==="ordinal"&&c==null&&(c=g,f=d(y)),n[y.name]=[]});var h=l.get(u)||l.set(u,{categoryWayDim:f,valueWayDim:0});C(r,function(p,g){var y=p.name,m=d(p);if(c==null){var _=h.valueWayDim;v(n[y],_,m),v(o,_,m),h.valueWayDim+=m}else if(c===g)v(n[y],0,m),v(i,0,m);else{var _=h.categoryWayDim;v(n[y],_,m),v(o,_,m),h.categoryWayDim+=m}});function v(p,g,y){for(var m=0;m<y;m++)p.push(g+m)}function d(p){var g=p.dimsDef;return g?g.length:1}return i.length&&(n.itemName=i),o.length&&(n.seriesName=o),n}function P1(r,e,t){var n={},a=z1(r);if(!a)return n;var i=e.sourceFormat,o=e.dimensionsDefine,s;(i===Gn||i===Ga)&&C(o,function(c,f){(_e(c)?c.name:c)==="name"&&(s=f)});var l=function(){for(var c={},f={},h=[],v=0,d=Math.min(5,t);v<d;v++){var p=_C(e.data,i,e.seriesLayoutBy,o,e.startIndex,v);h.push(p);var g=p===Dr.Not;if(g&&c.v==null&&v!==s&&(c.v=v),(c.n==null||c.n===c.v||!g&&h[c.n]===Dr.Not)&&(c.n=v),y(c)&&h[c.n]!==Dr.Not)return c;g||(p===Dr.Might&&f.v==null&&v!==s&&(f.v=v),(f.n==null||f.n===f.v)&&(f.n=v))}function y(m){return m.v!=null&&m.n!=null}return y(c)?c:y(f)?f:null}();if(l){n.value=[l.v];var u=s!=null?s:l.n;n.itemName=[u],n.seriesName=[u]}return n}function z1(r){var e=r.get("data",!0);if(!e)return Gc(r.ecModel,"dataset",{index:r.get("datasetIndex",!0),id:r.get("datasetId",!0)},Ut).models[0]}function k$(r){return!r.get("transform",!0)&&!r.get("fromTransformResult",!0)?[]:Gc(r.ecModel,"dataset",{index:r.get("fromDatasetIndex",!0),id:r.get("fromDatasetId",!0)},Ut).models}function mC(r,e){return _C(r.data,r.sourceFormat,r.seriesLayoutBy,r.dimensionsDefine,r.startIndex,e)}function _C(r,e,t,n,a,i){var o,s=5;if(an(r))return Dr.Not;var l,u;if(n){var c=n[i];_e(c)?(l=c.name,u=c.type):ce(c)&&(l=c)}if(u!=null)return u==="ordinal"?Dr.Must:Dr.Not;if(e===zr){var f=r;if(t===lu){for(var h=f[i],v=0;v<(h||[]).length&&v<s;v++)if((o=b(h[a+v]))!=null)return o}else for(var v=0;v<f.length&&v<s;v++){var d=f[a+v];if(d&&(o=b(d[i]))!=null)return o}}else if(e===Gn){var p=r;if(!l)return Dr.Not;for(var v=0;v<p.length&&v<s;v++){var g=p[v];if(g&&(o=b(g[l]))!=null)return o}}else if(e===Ga){var y=r;if(!l)return Dr.Not;var h=y[l];if(!h||an(h))return Dr.Not;for(var v=0;v<h.length&&v<s;v++)if((o=b(h[v]))!=null)return o}else if(e===Wn)for(var m=r,v=0;v<m.length&&v<s;v++){var g=m[v],_=Wl(g);if(!J(_))return Dr.Not;if((o=b(_[i]))!=null)return o}function b(x){var M=ce(x);if(x!=null&&isFinite(x)&&x!=="")return M?Dr.Might:Dr.Not;if(M&&x!=="-")return Dr.Must}return Dr.Not}var k1=ge();function R$(r,e){Er(k1.get(r)==null&&e),k1.set(r,e)}function j$(r,e,t){var n=k1.get(e);if(!n)return t;var a=n(r);return a?t.concat(a):t}var bC=Ye(),B$=Ye(),R1=function(){function r(){}return r.prototype.getColorFromPalette=function(e,t,n){var a=ct(this.get("color",!0)),i=this.get("colorLayer",!0);return MC(this,bC,a,i,e,t,n)},r.prototype.clearColorPalette=function(){V$(this,bC)},r}();function j1(r,e,t,n){var a=ct(r.get(["aria","decal","decals"]));return MC(r,B$,a,null,e,t,n)}function F$(r,e){for(var t=r.length,n=0;n<t;n++)if(r[n].length>e)return r[n];return r[t-1]}function MC(r,e,t,n,a,i,o){i=i||r;var s=e(i),l=s.paletteIdx||0,u=s.paletteNameMap=s.paletteNameMap||{};if(u.hasOwnProperty(a))return u[a];var c=o==null||!n?t:F$(n,o);if(c=c||t,!(!c||!c.length)){var f=c[l];return a&&(u[a]=f),s.paletteIdx=(l+1)%c.length,f}}function V$(r,e){e(r).paletteIdx=0,e(r).paletteNameMap={}}var Hd,gf,xC,wC="\0_ec_inner",H$=1,DC=function(r){U(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.init=function(t,n,a,i,o,s){i=i||{},this.option=null,this._theme=new ft(i),this._locale=new ft(o),this._optionManager=s},e.prototype.setOption=function(t,n,a){var i=TC(n);this._optionManager.setOption(t,a,i),this._resetOption(null,i)},e.prototype.resetOption=function(t,n){return this._resetOption(t,TC(n))},e.prototype._resetOption=function(t,n){var a=!1,i=this._optionManager;if(!t||t==="recreate"){var o=i.mountOption(t==="recreate");!this.option||t==="recreate"?xC(this,o):(this.restoreData(),this._mergeOption(o,n)),a=!0}if((t==="timeline"||t==="media")&&this.restoreData(),!t||t==="recreate"||t==="timeline"){var s=i.getTimelineOption(this);s&&(a=!0,this._mergeOption(s,n))}if(!t||t==="recreate"||t==="media"){var l=i.getMediaOption(this);l.length&&C(l,function(u){a=!0,this._mergeOption(u,n)},this)}return a},e.prototype.mergeOption=function(t){this._mergeOption(t,null)},e.prototype._mergeOption=function(t,n){var a=this.option,i=this._componentsMap,o=this._componentsCount,s=[],l=ge(),u=n&&n.replaceMergeMainTypeMap;z$(this),C(t,function(f,h){f!=null&&(He.hasClass(h)?h&&(s.push(h),l.set(h,!0)):a[h]=a[h]==null?Me(f):Ne(a[h],f,!0))}),u&&u.each(function(f,h){He.hasClass(h)&&!l.get(h)&&(s.push(h),l.set(h,!0))}),He.topologicalTravel(s,He.getAllClassMainTypes(),c,this);function c(f){var h=j$(this,f,ct(t[f])),v=i.get(f),d=v?u&&u.get(f)?"replaceMerge":"normalMerge":"replaceAll",p=oT(v,h,d);oW(p,f,He),a[f]=null,i.set(f,null),o.set(f,0);var g=[],y=[],m=0,_;C(p,function(b,x){var M=b.existing,w=b.newOption;if(!w)M&&(M.mergeOption({},this),M.optionUpdated({},!1));else{var D=f==="series",T=He.getClass(f,b.keyInfo.subType,!D);if(!T)return;if(f==="tooltip"){if(_)return;_=!0}if(M&&M.constructor===T)M.name=b.keyInfo.name,M.mergeOption(w,this),M.optionUpdated(w,!1);else{var I=X({componentIndex:x},b.keyInfo);M=new T(w,this,this,I),X(M,I),b.brandNew&&(M.__requireNewView=!0),M.init(w,this,this),M.optionUpdated(null,!0)}}M?(g.push(M.option),y.push(M),m++):(g.push(void 0),y.push(void 0))},this),a[f]=g,i.set(f,y),o.set(f,m),f==="series"&&Hd(this)}this._seriesIndices||Hd(this)},e.prototype.getOption=function(){var t=Me(this.option);return C(t,function(n,a){if(He.hasClass(a)){for(var i=ct(n),o=i.length,s=!1,l=o-1;l>=0;l--)i[l]&&!Hc(i[l])?s=!0:(i[l]=null,!s&&o--);i.length=o,t[a]=i}}),delete t[wC],t},e.prototype.getTheme=function(){return this._theme},e.prototype.getLocaleModel=function(){return this._locale},e.prototype.setUpdatePayload=function(t){this._payload=t},e.prototype.getUpdatePayload=function(){return this._payload},e.prototype.getComponent=function(t,n){var a=this._componentsMap.get(t);if(a){var i=a[n||0];if(i)return i;if(n==null){for(var o=0;o<a.length;o++)if(a[o])return a[o]}}},e.prototype.queryComponents=function(t){var n=t.mainType;if(!n)return[];var a=t.index,i=t.id,o=t.name,s=this._componentsMap.get(n);if(!s||!s.length)return[];var l;return a!=null?(l=[],C(ct(a),function(u){s[u]&&l.push(s[u])})):i!=null?l=SC("id",i,s):o!=null?l=SC("name",o,s):l=ot(s,function(u){return!!u}),IC(l,t)},e.prototype.findComponents=function(t){var n=t.query,a=t.mainType,i=s(n),o=i?this.queryComponents(i):ot(this._componentsMap.get(a),function(u){return!!u});return l(IC(o,t));function s(u){var c=a+"Index",f=a+"Id",h=a+"Name";return u&&(u[c]!=null||u[f]!=null||u[h]!=null)?{mainType:a,index:u[c],id:u[f],name:u[h]}:null}function l(u){return t.filter?ot(u,t.filter):u}},e.prototype.eachComponent=function(t,n,a){var i=this._componentsMap;if(ye(t)){var o=n,s=t;i.each(function(f,h){for(var v=0;f&&v<f.length;v++){var d=f[v];d&&s.call(o,h,d,d.componentIndex)}})}else for(var l=ce(t)?i.get(t):_e(t)?this.findComponents(t):null,u=0;l&&u<l.length;u++){var c=l[u];c&&n.call(a,c,c.componentIndex)}},e.prototype.getSeriesByName=function(t){var n=Kt(t,null);return ot(this._componentsMap.get("series"),function(a){return!!a&&n!=null&&a.name===n})},e.prototype.getSeriesByIndex=function(t){return this._componentsMap.get("series")[t]},e.prototype.getSeriesByType=function(t){return ot(this._componentsMap.get("series"),function(n){return!!n&&n.subType===t})},e.prototype.getSeries=function(){return ot(this._componentsMap.get("series"),function(t){return!!t})},e.prototype.getSeriesCount=function(){return this._componentsCount.get("series")},e.prototype.eachSeries=function(t,n){gf(this),C(this._seriesIndices,function(a){var i=this._componentsMap.get("series")[a];t.call(n,i,a)},this)},e.prototype.eachRawSeries=function(t,n){C(this._componentsMap.get("series"),function(a){a&&t.call(n,a,a.componentIndex)})},e.prototype.eachSeriesByType=function(t,n,a){gf(this),C(this._seriesIndices,function(i){var o=this._componentsMap.get("series")[i];o.subType===t&&n.call(a,o,i)},this)},e.prototype.eachRawSeriesByType=function(t,n,a){return C(this.getSeriesByType(t),n,a)},e.prototype.isSeriesFiltered=function(t){return gf(this),this._seriesIndicesMap.get(t.componentIndex)==null},e.prototype.getCurrentSeriesIndices=function(){return(this._seriesIndices||[]).slice()},e.prototype.filterSeries=function(t,n){gf(this);var a=[];C(this._seriesIndices,function(i){var o=this._componentsMap.get("series")[i];t.call(n,o,i)&&a.push(i)},this),this._seriesIndices=a,this._seriesIndicesMap=ge(a)},e.prototype.restoreData=function(t){Hd(this);var n=this._componentsMap,a=[];n.each(function(i,o){He.hasClass(o)&&a.push(o)}),He.topologicalTravel(a,He.getAllClassMainTypes(),function(i){C(n.get(i),function(o){o&&(i!=="series"||!W$(o,t))&&o.restoreData()})})},e.internalField=function(){Hd=function(t){var n=t._seriesIndices=[];C(t._componentsMap.get("series"),function(a){a&&n.push(a.componentIndex)}),t._seriesIndicesMap=ge(n)},gf=function(t){},xC=function(t,n){t.option={},t.option[wC]=H$,t._componentsMap=ge({series:[]}),t._componentsCount=ge();var a=n.aria;_e(a)&&a.enabled==null&&(a.enabled=!0),G$(n,t._theme.option),Ne(n,P$,!1),t._mergeOption(n,null)}}(),e}(ft);function W$(r,e){if(e){var t=e.seriesIndex,n=e.seriesId,a=e.seriesName;return t!=null&&r.componentIndex!==t||n!=null&&r.id!==n||a!=null&&r.name!==a}}function G$(r,e){var t=r.color&&!r.colorLayer;C(e,function(n,a){a==="colorLayer"&&t||He.hasClass(a)||(typeof n=="object"?r[a]=r[a]?Ne(r[a],n,!1):Me(n):r[a]==null&&(r[a]=n))})}function SC(r,e,t){if(J(e)){var n=ge();return C(e,function(i){if(i!=null){var o=Kt(i,null);o!=null&&n.set(i,!0)}}),ot(t,function(i){return i&&n.get(i[r])})}else{var a=Kt(e,null);return ot(t,function(i){return i&&a!=null&&i[r]===a})}}function IC(r,e){return e.hasOwnProperty("subType")?ot(r,function(t){return t&&t.subType===e.subType}):r}function TC(r){var e=ge();return r&&C(ct(r.replaceMerge),function(t){e.set(t,!0)}),{replaceMergeMainTypeMap:e}}Et(DC,R1);var AC=DC,$$=["getDom","getZr","getWidth","getHeight","getDevicePixelRatio","dispatchAction","isSSR","isDisposed","on","off","getDataURL","getConnectedDataURL","getOption","getId","updateLabelLayout"],U$=function(){function r(e){C($$,function(t){this[t]=fe(e[t],e)},this)}return r}(),CC=U$,B1={},Y$=function(){function r(){this._coordinateSystems=[]}return r.prototype.create=function(e,t){var n=[];C(B1,function(a,i){var o=a.create(e,t);n=n.concat(o||[])}),this._coordinateSystems=n},r.prototype.update=function(e,t){C(this._coordinateSystems,function(n){n.update&&n.update(e,t)})},r.prototype.getCoordinateSystems=function(){return this._coordinateSystems.slice()},r.register=function(e,t){B1[e]=t},r.get=function(e){return B1[e]},r}(),uu=Y$,Q$=/^(min|max)?(.+)$/,Z$=function(){function r(e){this._timelineOptions=[],this._mediaList=[],this._currentMediaIndices=[],this._api=e}return r.prototype.setOption=function(e,t,n){e&&(C(ct(e.series),function(o){o&&o.data&&an(o.data)&&pc(o.data)}),C(ct(e.dataset),function(o){o&&o.source&&an(o.source)&&pc(o.source)})),e=Me(e);var a=this._optionBackup,i=q$(e,t,!a);this._newBaseOption=i.baseOption,a?(i.timelineOptions.length&&(a.timelineOptions=i.timelineOptions),i.mediaList.length&&(a.mediaList=i.mediaList),i.mediaDefault&&(a.mediaDefault=i.mediaDefault)):this._optionBackup=i},r.prototype.mountOption=function(e){var t=this._optionBackup;return this._timelineOptions=t.timelineOptions,this._mediaList=t.mediaList,this._mediaDefault=t.mediaDefault,this._currentMediaIndices=[],Me(e?t.baseOption:this._newBaseOption)},r.prototype.getTimelineOption=function(e){var t,n=this._timelineOptions;if(n.length){var a=e.getComponent("timeline");a&&(t=Me(n[a.getCurrentIndex()]))}return t},r.prototype.getMediaOption=function(e){var t=this._api.getWidth(),n=this._api.getHeight(),a=this._mediaList,i=this._mediaDefault,o=[],s=[];if(!a.length&&!i)return s;for(var l=0,u=a.length;l<u;l++)X$(a[l].query,t,n)&&o.push(l);return!o.length&&i&&(o=[-1]),o.length&&!K$(o,this._currentMediaIndices)&&(s=K(o,function(c){return Me(c===-1?i.option:a[c].option)})),this._currentMediaIndices=o,s},r}();function q$(r,e,t){var n=[],a,i,o=r.baseOption,s=r.timeline,l=r.options,u=r.media,c=!!r.media,f=!!(l||s||o&&o.timeline);o?(i=o,i.timeline||(i.timeline=s)):((f||c)&&(r.options=r.media=null),i=r),c&&J(u)&&C(u,function(v){v&&v.option&&(v.query?n.push(v):a||(a=v))}),h(i),C(l,function(v){return h(v)}),C(n,function(v){return h(v.option)});function h(v){C(e,function(d){d(v,t)})}return{baseOption:i,timelineOptions:l||[],mediaDefault:a,mediaList:n}}function X$(r,e,t){var n={width:e,height:t,aspectratio:e/t},a=!0;return C(r,function(i,o){var s=o.match(Q$);if(!(!s||!s[1]||!s[2])){var l=s[1],u=s[2].toLowerCase();J$(n[u],i,l)||(a=!1)}}),a}function J$(r,e,t){return t==="min"?r>=e:t==="max"?r<=e:r===e}function K$(r,e){return r.join(",")===e.join(",")}var eU=Z$,_a=C,yf=_e,NC=["areaStyle","lineStyle","nodeStyle","linkStyle","chordStyle","label","labelLine"];function F1(r){var e=r&&r.itemStyle;if(!!e)for(var t=0,n=NC.length;t<n;t++){var a=NC[t],i=e.normal,o=e.emphasis;i&&i[a]&&(r[a]=r[a]||{},r[a].normal?Ne(r[a].normal,i[a]):r[a].normal=i[a],i[a]=null),o&&o[a]&&(r[a]=r[a]||{},r[a].emphasis?Ne(r[a].emphasis,o[a]):r[a].emphasis=o[a],o[a]=null)}}function kr(r,e,t){if(r&&r[e]&&(r[e].normal||r[e].emphasis)){var n=r[e].normal,a=r[e].emphasis;n&&(t?(r[e].normal=r[e].emphasis=null,me(r[e],n)):r[e]=n),a&&(r.emphasis=r.emphasis||{},r.emphasis[e]=a,a.focus&&(r.emphasis.focus=a.focus),a.blurScope&&(r.emphasis.blurScope=a.blurScope))}}function mf(r){kr(r,"itemStyle"),kr(r,"lineStyle"),kr(r,"areaStyle"),kr(r,"label"),kr(r,"labelLine"),kr(r,"upperLabel"),kr(r,"edgeLabel")}function Qt(r,e){var t=yf(r)&&r[e],n=yf(t)&&t.textStyle;if(n)for(var a=0,i=iT.length;a<i;a++){var o=iT[a];n.hasOwnProperty(o)&&(t[o]=n[o])}}function $n(r){r&&(mf(r),Qt(r,"label"),r.emphasis&&Qt(r.emphasis,"label"))}function tU(r){if(!!yf(r)){F1(r),mf(r),Qt(r,"label"),Qt(r,"upperLabel"),Qt(r,"edgeLabel"),r.emphasis&&(Qt(r.emphasis,"label"),Qt(r.emphasis,"upperLabel"),Qt(r.emphasis,"edgeLabel"));var e=r.markPoint;e&&(F1(e),$n(e));var t=r.markLine;t&&(F1(t),$n(t));var n=r.markArea;n&&$n(n);var a=r.data;if(r.type==="graph"){a=a||r.nodes;var i=r.links||r.edges;if(i&&!an(i))for(var o=0;o<i.length;o++)$n(i[o]);C(r.categories,function(u){mf(u)})}if(a&&!an(a))for(var o=0;o<a.length;o++)$n(a[o]);if(e=r.markPoint,e&&e.data)for(var s=e.data,o=0;o<s.length;o++)$n(s[o]);if(t=r.markLine,t&&t.data)for(var l=t.data,o=0;o<l.length;o++)J(l[o])?($n(l[o][0]),$n(l[o][1])):$n(l[o]);r.type==="gauge"?(Qt(r,"axisLabel"),Qt(r,"title"),Qt(r,"detail")):r.type==="treemap"?(kr(r.breadcrumb,"itemStyle"),C(r.levels,function(u){mf(u)})):r.type==="tree"&&mf(r.leaves)}}function bi(r){return J(r)?r:r?[r]:[]}function LC(r){return(J(r)?r[0]:r)||{}}function rU(r,e){_a(bi(r.series),function(n){yf(n)&&tU(n)});var t=["xAxis","yAxis","radiusAxis","angleAxis","singleAxis","parallelAxis","radar"];e&&t.push("valueAxis","categoryAxis","logAxis","timeAxis"),_a(t,function(n){_a(bi(r[n]),function(a){a&&(Qt(a,"axisLabel"),Qt(a.axisPointer,"label"))})}),_a(bi(r.parallel),function(n){var a=n&&n.parallelAxisDefault;Qt(a,"axisLabel"),Qt(a&&a.axisPointer,"label")}),_a(bi(r.calendar),function(n){kr(n,"itemStyle"),Qt(n,"dayLabel"),Qt(n,"monthLabel"),Qt(n,"yearLabel")}),_a(bi(r.radar),function(n){Qt(n,"name"),n.name&&n.axisName==null&&(n.axisName=n.name,delete n.name),n.nameGap!=null&&n.axisNameGap==null&&(n.axisNameGap=n.nameGap,delete n.nameGap)}),_a(bi(r.geo),function(n){yf(n)&&($n(n),_a(bi(n.regions),function(a){$n(a)}))}),_a(bi(r.timeline),function(n){$n(n),kr(n,"label"),kr(n,"itemStyle"),kr(n,"controlStyle",!0);var a=n.data;J(a)&&C(a,function(i){_e(i)&&(kr(i,"label"),kr(i,"itemStyle"))})}),_a(bi(r.toolbox),function(n){kr(n,"iconStyle"),_a(n.feature,function(a){kr(a,"iconStyle")})}),Qt(LC(r.axisPointer),"label"),Qt(LC(r.tooltip).axisPointer,"label")}function nU(r,e){for(var t=e.split(","),n=r,a=0;a<t.length&&(n=n&&n[t[a]],n!=null);a++);return n}function aU(r,e,t,n){for(var a=e.split(","),i=r,o,s=0;s<a.length-1;s++)o=a[s],i[o]==null&&(i[o]={}),i=i[o];(n||i[a[s]]==null)&&(i[a[s]]=t)}function EC(r){r&&C(iU,function(e){e[0]in r&&!(e[1]in r)&&(r[e[1]]=r[e[0]])})}var iU=[["x","left"],["y","top"],["x2","right"],["y2","bottom"]],oU=["grid","geo","parallel","legend","toolbox","title","visualMap","dataZoom","timeline"],V1=[["borderRadius","barBorderRadius"],["borderColor","barBorderColor"],["borderWidth","barBorderWidth"]];function _f(r){var e=r&&r.itemStyle;if(e)for(var t=0;t<V1.length;t++){var n=V1[t][1],a=V1[t][0];e[n]!=null&&(e[a]=e[n])}}function OC(r){!r||r.alignTo==="edge"&&r.margin!=null&&r.edgeDistance==null&&(r.edgeDistance=r.margin)}function PC(r){!r||r.downplay&&!r.blur&&(r.blur=r.downplay)}function sU(r){!r||r.focusNodeAdjacency!=null&&(r.emphasis=r.emphasis||{},r.emphasis.focus==null&&(r.emphasis.focus="adjacency"))}function zC(r,e){if(r)for(var t=0;t<r.length;t++)e(r[t]),r[t]&&zC(r[t].children,e)}function kC(r,e){rU(r,e),r.series=ct(r.series),C(r.series,function(t){if(!!_e(t)){var n=t.type;if(n==="line")t.clipOverflow!=null&&(t.clip=t.clipOverflow);else if(n==="pie"||n==="gauge"){t.clockWise!=null&&(t.clockwise=t.clockWise),OC(t.label);var a=t.data;if(a&&!an(a))for(var i=0;i<a.length;i++)OC(a[i]);t.hoverOffset!=null&&(t.emphasis=t.emphasis||{},(t.emphasis.scaleSize=null)&&(t.emphasis.scaleSize=t.hoverOffset))}else if(n==="gauge"){var o=nU(t,"pointer.color");o!=null&&aU(t,"itemStyle.color",o)}else if(n==="bar"){_f(t),_f(t.backgroundStyle),_f(t.emphasis);var a=t.data;if(a&&!an(a))for(var i=0;i<a.length;i++)typeof a[i]=="object"&&(_f(a[i]),_f(a[i]&&a[i].emphasis))}else if(n==="sunburst"){var s=t.highlightPolicy;s&&(t.emphasis=t.emphasis||{},t.emphasis.focus||(t.emphasis.focus=s)),PC(t),zC(t.data,PC)}else n==="graph"||n==="sankey"?sU(t):n==="map"&&(t.mapType&&!t.map&&(t.map=t.mapType),t.mapLocation&&me(t,t.mapLocation));t.hoverAnimation!=null&&(t.emphasis=t.emphasis||{},t.emphasis&&t.emphasis.scale==null&&(t.emphasis.scale=t.hoverAnimation)),EC(t)}}),r.dataRange&&(r.visualMap=r.dataRange),C(oU,function(t){var n=r[t];n&&(J(n)||(n=[n]),C(n,function(a){EC(a)}))})}function lU(r){var e=ge();r.eachSeries(function(t){var n=t.get("stack");if(n){var a=e.get(n)||e.set(n,[]),i=t.getData(),o={stackResultDimension:i.getCalculationInfo("stackResultDimension"),stackedOverDimension:i.getCalculationInfo("stackedOverDimension"),stackedDimension:i.getCalculationInfo("stackedDimension"),stackedByDimension:i.getCalculationInfo("stackedByDimension"),isStackedByIndex:i.getCalculationInfo("isStackedByIndex"),data:i,seriesModel:t};if(!o.stackedDimension||!(o.isStackedByIndex||o.stackedByDimension))return;a.length&&i.setCalculationInfo("stackedOnSeries",a[a.length-1].seriesModel),a.push(o)}}),e.each(uU)}function uU(r){C(r,function(e,t){var n=[],a=[NaN,NaN],i=[e.stackResultDimension,e.stackedOverDimension],o=e.data,s=e.isStackedByIndex,l=e.seriesModel.get("stackStrategy")||"samesign";o.modify(i,function(u,c,f){var h=o.get(e.stackedDimension,f);if(isNaN(h))return a;var v,d;s?d=o.getRawIndex(f):v=o.get(e.stackedByDimension,f);for(var p=NaN,g=t-1;g>=0;g--){var y=r[g];if(s||(d=y.data.rawIndexOf(y.stackedByDimension,v)),d>=0){var m=y.data.getByRawIndex(y.stackResultDimension,d);if(l==="all"||l==="positive"&&m>0||l==="negative"&&m<0||l==="samesign"&&h>=0&&m>0||l==="samesign"&&h<=0&&m<0){h=YH(h,m),p=m;break}}}return n[0]=h,n[1]=p,n})})}var Wd=function(){function r(e){this.data=e.data||(e.sourceFormat===Ga?{}:[]),this.sourceFormat=e.sourceFormat||pC,this.seriesLayoutBy=e.seriesLayoutBy||$a,this.startIndex=e.startIndex||0,this.dimensionsDetectedCount=e.dimensionsDetectedCount,this.metaRawOption=e.metaRawOption;var t=this.dimensionsDefine=e.dimensionsDefine;if(t)for(var n=0;n<t.length;n++){var a=t[n];a.type==null&&mC(this,n)===Dr.Must&&(a.type="ordinal")}}return r}();function H1(r){return r instanceof Wd}function W1(r,e,t){t=t||RC(r);var n=e.seriesLayoutBy,a=fU(r,t,n,e.sourceHeader,e.dimensions),i=new Wd({data:r,sourceFormat:t,seriesLayoutBy:n,dimensionsDefine:a.dimensionsDefine,startIndex:a.startIndex,dimensionsDetectedCount:a.dimensionsDetectedCount,metaRawOption:Me(e)});return i}function G1(r){return new Wd({data:r,sourceFormat:an(r)?ho:Wn})}function cU(r){return new Wd({data:r.data,sourceFormat:r.sourceFormat,seriesLayoutBy:r.seriesLayoutBy,dimensionsDefine:Me(r.dimensionsDefine),startIndex:r.startIndex,dimensionsDetectedCount:r.dimensionsDetectedCount})}function RC(r){var e=pC;if(an(r))e=ho;else if(J(r)){r.length===0&&(e=zr);for(var t=0,n=r.length;t<n;t++){var a=r[t];if(a!=null){if(J(a)){e=zr;break}else if(_e(a)){e=Gn;break}}}}else if(_e(r)){for(var i in r)if(ve(r,i)&&Mr(r[i])){e=Ga;break}}return e}function fU(r,e,t,n,a){var i,o;if(!r)return{dimensionsDefine:jC(a),startIndex:o,dimensionsDetectedCount:i};if(e===zr){var s=r;n==="auto"||n==null?BC(function(u){u!=null&&u!=="-"&&(ce(u)?o==null&&(o=1):o=0)},t,s,10):o=Ue(n)?n:n?1:0,!a&&o===1&&(a=[],BC(function(u,c){a[c]=u!=null?u+"":""},t,s,1/0)),i=a?a.length:t===lu?s.length:s[0]?s[0].length:null}else if(e===Gn)a||(a=hU(r));else if(e===Ga)a||(a=[],C(r,function(u,c){a.push(c)}));else if(e===Wn){var l=Wl(r[0]);i=J(l)&&l.length||1}return{startIndex:o,dimensionsDefine:jC(a),dimensionsDetectedCount:i}}function hU(r){for(var e=0,t;e<r.length&&!(t=r[e++]););if(t){var n=[];return C(t,function(a,i){n.push(i)}),n}}function jC(r){if(!!r){var e=ge();return K(r,function(t,n){t=_e(t)?t:{name:t};var a={name:t.name,displayName:t.displayName,type:t.type};if(a.name==null)return a;a.name+="",a.displayName==null&&(a.displayName=a.name);var i=e.get(a.name);return i?a.name+="-"+i.count++:e.set(a.name,{count:1}),a})}}function BC(r,e,t,n){if(e===lu)for(var a=0;a<t.length&&a<n;a++)r(t[a]?t[a][0]:null,a);else for(var i=t[0]||[],a=0;a<i.length&&a<n;a++)r(i[a],a)}function FC(r){var e=r.sourceFormat;return e===Gn||e===Ga}var Is,Ts,As,VC,HC,WC=function(){function r(e,t){var n=H1(e)?e:G1(e);this._source=n;var a=this._data=n.data;n.sourceFormat===ho&&(this._offset=0,this._dimSize=t,this._data=a),HC(this,a,n)}return r.prototype.getSource=function(){return this._source},r.prototype.count=function(){return 0},r.prototype.getItem=function(e,t){},r.prototype.appendData=function(e){},r.prototype.clean=function(){},r.protoInitialize=function(){var e=r.prototype;e.pure=!1,e.persistent=!0}(),r.internalField=function(){var e;HC=function(o,s,l){var u=l.sourceFormat,c=l.seriesLayoutBy,f=l.startIndex,h=l.dimensionsDefine,v=VC[U1(u,c)];if(X(o,v),u===ho)o.getItem=t,o.count=a,o.fillStorage=n;else{var d=$C(u,c);o.getItem=fe(d,null,s,f,h);var p=YC(u,c);o.count=fe(p,null,s,f,h)}};var t=function(o,s){o=o-this._offset,s=s||[];for(var l=this._data,u=this._dimSize,c=u*o,f=0;f<u;f++)s[f]=l[c+f];return s},n=function(o,s,l,u){for(var c=this._data,f=this._dimSize,h=0;h<f;h++){for(var v=u[h],d=v[0]==null?1/0:v[0],p=v[1]==null?-1/0:v[1],g=s-o,y=l[h],m=0;m<g;m++){var _=c[m*f+h];y[o+m]=_,_<d&&(d=_),_>p&&(p=_)}v[0]=d,v[1]=p}},a=function(){return this._data?this._data.length/this._dimSize:0};VC=(e={},e[zr+"_"+$a]={pure:!0,appendData:i},e[zr+"_"+lu]={pure:!0,appendData:function(){throw new Error('Do not support appendData when set seriesLayoutBy: "row".')}},e[Gn]={pure:!0,appendData:i},e[Ga]={pure:!0,appendData:function(o){var s=this._data;C(o,function(l,u){for(var c=s[u]||(s[u]=[]),f=0;f<(l||[]).length;f++)c.push(l[f])})}},e[Wn]={appendData:i},e[ho]={persistent:!1,pure:!0,appendData:function(o){this._data=o},clean:function(){this._offset+=this.count(),this._data=null}},e);function i(o){for(var s=0;s<o.length;s++)this._data.push(o[s])}}(),r}(),GC=function(r,e,t,n){return r[n]},vU=(Is={},Is[zr+"_"+$a]=function(r,e,t,n){return r[n+e]},Is[zr+"_"+lu]=function(r,e,t,n,a){n+=e;for(var i=a||[],o=r,s=0;s<o.length;s++){var l=o[s];i[s]=l?l[n]:null}return i},Is[Gn]=GC,Is[Ga]=function(r,e,t,n,a){for(var i=a||[],o=0;o<t.length;o++){var s=t[o].name,l=r[s];i[o]=l?l[n]:null}return i},Is[Wn]=GC,Is);function $C(r,e){var t=vU[U1(r,e)];return t}var UC=function(r,e,t){return r.length},dU=(Ts={},Ts[zr+"_"+$a]=function(r,e,t){return Math.max(0,r.length-e)},Ts[zr+"_"+lu]=function(r,e,t){var n=r[0];return n?Math.max(0,n.length-e):0},Ts[Gn]=UC,Ts[Ga]=function(r,e,t){var n=t[0].name,a=r[n];return a?a.length:0},Ts[Wn]=UC,Ts);function YC(r,e){var t=dU[U1(r,e)];return t}var $1=function(r,e,t){return r[e]},pU=(As={},As[zr]=$1,As[Gn]=function(r,e,t){return r[t]},As[Ga]=$1,As[Wn]=function(r,e,t){var n=Wl(r);return n instanceof Array?n[e]:n},As[ho]=$1,As);function QC(r){var e=pU[r];return e}function U1(r,e){return r===zr?r+"_"+e:r}function cu(r,e,t){if(!!r){var n=r.getRawDataItem(e);if(n!=null){var a=r.getStore(),i=a.getSource().sourceFormat;if(t!=null){var o=r.getDimensionIndex(t),s=a.getDimensionProperty(o);return QC(i)(n,o,s)}else{var l=n;return i===Wn&&(l=Wl(n)),l}}}}var gU=/\{@(.+?)\}/g,Y1=function(){function r(){}return r.prototype.getDataParams=function(e,t){var n=this.getData(t),a=this.getRawValue(e,t),i=n.getRawIndex(e),o=n.getName(e),s=n.getRawDataItem(e),l=n.getItemVisual(e,"style"),u=l&&l[n.getItemVisual(e,"drawType")||"fill"],c=l&&l.stroke,f=this.mainType,h=f==="series",v=n.userOutput&&n.userOutput.get();return{componentType:f,componentSubType:this.subType,componentIndex:this.componentIndex,seriesType:h?this.subType:null,seriesIndex:this.seriesIndex,seriesId:h?this.id:null,seriesName:h?this.name:null,name:o,dataIndex:i,data:s,dataType:t,value:a,color:u,borderColor:c,dimensionNames:v?v.fullDimensions:null,encode:v?v.encode:null,$vars:["seriesName","name","value"]}},r.prototype.getFormattedLabel=function(e,t,n,a,i,o){t=t||"normal";var s=this.getData(n),l=this.getDataParams(e,n);if(o&&(l.value=o.interpolatedValue),a!=null&&J(l.value)&&(l.value=l.value[a]),!i){var u=s.getItemModel(e);i=u.get(t==="normal"?["label","formatter"]:[t,"label","formatter"])}if(ye(i))return l.status=t,l.dimensionIndex=a,i(l);if(ce(i)){var c=E1(i,l);return c.replace(gU,function(f,h){var v=h.length,d=h;d.charAt(0)==="["&&d.charAt(v-1)==="]"&&(d=+d.slice(1,v-1));var p=cu(s,e,d);if(o&&J(o.interpolatedValue)){var g=s.getDimensionIndex(d);g>=0&&(p=o.interpolatedValue[g])}return p!=null?p+"":""})}},r.prototype.getRawValue=function(e,t){return cu(this.getData(t),e)},r.prototype.formatTooltip=function(e,t,n){},r}();function ZC(r){var e,t;return _e(r)?r.type&&(t=r):e=r,{text:e,frag:t}}function bf(r){return new yU(r)}var yU=function(){function r(e){e=e||{},this._reset=e.reset,this._plan=e.plan,this._count=e.count,this._onDirty=e.onDirty,this._dirty=!0}return r.prototype.perform=function(e){var t=this._upstream,n=e&&e.skip;if(this._dirty&&t){var a=this.context;a.data=a.outputData=t.context.outputData}this.__pipeline&&(this.__pipeline.currentTask=this);var i;this._plan&&!n&&(i=this._plan(this.context));var o=c(this._modBy),s=this._modDataCount||0,l=c(e&&e.modBy),u=e&&e.modDataCount||0;(o!==l||s!==u)&&(i="reset");function c(m){return!(m>=1)&&(m=1),m}var f;(this._dirty||i==="reset")&&(this._dirty=!1,f=this._doReset(n)),this._modBy=l,this._modDataCount=u;var h=e&&e.step;if(t?this._dueEnd=t._outputDueEnd:this._dueEnd=this._count?this._count(this.context):1/0,this._progress){var v=this._dueIndex,d=Math.min(h!=null?this._dueIndex+h:1/0,this._dueEnd);if(!n&&(f||v<d)){var p=this._progress;if(J(p))for(var g=0;g<p.length;g++)this._doProgress(p[g],v,d,l,u);else this._doProgress(p,v,d,l,u)}this._dueIndex=d;var y=this._settedOutputEnd!=null?this._settedOutputEnd:d;this._outputDueEnd=y}else this._dueIndex=this._outputDueEnd=this._settedOutputEnd!=null?this._settedOutputEnd:this._dueEnd;return this.unfinished()},r.prototype.dirty=function(){this._dirty=!0,this._onDirty&&this._onDirty(this.context)},r.prototype._doProgress=function(e,t,n,a,i){qC.reset(t,n,a,i),this._callingProgress=e,this._callingProgress({start:t,end:n,count:n-t,next:qC.next},this.context)},r.prototype._doReset=function(e){this._dueIndex=this._outputDueEnd=this._dueEnd=0,this._settedOutputEnd=null;var t,n;!e&&this._reset&&(t=this._reset(this.context),t&&t.progress&&(n=t.forceFirstProgress,t=t.progress),J(t)&&!t.length&&(t=null)),this._progress=t,this._modBy=this._modDataCount=null;var a=this._downstream;return a&&a.dirty(),n},r.prototype.unfinished=function(){return this._progress&&this._dueIndex<this._dueEnd},r.prototype.pipe=function(e){(this._downstream!==e||this._dirty)&&(this._downstream=e,e._upstream=this,e.dirty())},r.prototype.dispose=function(){this._disposed||(this._upstream&&(this._upstream._downstream=null),this._downstream&&(this._downstream._upstream=null),this._dirty=!1,this._disposed=!0)},r.prototype.getUpstream=function(){return this._upstream},r.prototype.getDownstream=function(){return this._downstream},r.prototype.setOutputEnd=function(e){this._outputDueEnd=this._settedOutputEnd=e},r}(),qC=function(){var r,e,t,n,a,i={reset:function(l,u,c,f){e=l,r=u,t=c,n=f,a=Math.ceil(n/t),i.next=t>1&&n>0?s:o}};return i;function o(){return e<r?e++:null}function s(){var l=e%a*t+Math.ceil(e/a),u=e>=r?null:l<n?l:e;return e++,u}}();function vo(r,e){var t=e&&e.type;return t==="ordinal"?r:(t==="time"&&!Ue(r)&&r!=null&&r!=="-"&&(r=+Mn(r)),r==null||r===""?NaN:+r)}var mU=ge({number:function(r){return parseFloat(r)},time:function(r){return+Mn(r)},trim:function(r){return ce(r)?Pn(r):r}});function XC(r){return mU.get(r)}var JC={lt:function(r,e){return r<e},lte:function(r,e){return r<=e},gt:function(r,e){return r>e},gte:function(r,e){return r>=e}},_U=function(){function r(e,t){if(!Ue(t)){var n="";at(n)}this._opFn=JC[e],this._rvalFloat=Ra(t)}return r.prototype.evaluate=function(e){return Ue(e)?this._opFn(e,this._rvalFloat):this._opFn(Ra(e),this._rvalFloat)},r}(),KC=function(){function r(e,t){var n=e==="desc";this._resultLT=n?1:-1,t==null&&(t=n?"min":"max"),this._incomparable=t==="min"?-1/0:1/0}return r.prototype.evaluate=function(e,t){var n=Ue(e)?e:Ra(e),a=Ue(t)?t:Ra(t),i=isNaN(n),o=isNaN(a);if(i&&(n=this._incomparable),o&&(a=this._incomparable),i&&o){var s=ce(e),l=ce(t);s&&(n=l?e:0),l&&(a=s?t:0)}return n<a?this._resultLT:n>a?-this._resultLT:0},r}(),bU=function(){function r(e,t){this._rval=t,this._isEQ=e,this._rvalTypeof=typeof t,this._rvalFloat=Ra(t)}return r.prototype.evaluate=function(e){var t=e===this._rval;if(!t){var n=typeof e;n!==this._rvalTypeof&&(n==="number"||this._rvalTypeof==="number")&&(t=Ra(e)===this._rvalFloat)}return this._isEQ?t:!t},r}();function MU(r,e){return r==="eq"||r==="ne"?new bU(r==="eq",e):ve(JC,r)?new _U(r,e):null}var xU=function(){function r(){}return r.prototype.getRawData=function(){throw new Error("not supported")},r.prototype.getRawDataItem=function(e){throw new Error("not supported")},r.prototype.cloneRawData=function(){},r.prototype.getDimensionInfo=function(e){},r.prototype.cloneAllDimensionInfo=function(){},r.prototype.count=function(){},r.prototype.retrieveValue=function(e,t){},r.prototype.retrieveValueFromItem=function(e,t){},r.prototype.convertValue=function(e,t){return vo(e,t)},r}();function wU(r,e){var t=new xU,n=r.data,a=t.sourceFormat=r.sourceFormat,i=r.startIndex,o="";r.seriesLayoutBy!==$a&&at(o);var s=[],l={},u=r.dimensionsDefine;if(u)C(u,function(p,g){var y=p.name,m={index:g,name:y,displayName:p.displayName};if(s.push(m),y!=null){var _="";ve(l,y)&&at(_),l[y]=m}});else for(var c=0;c<r.dimensionsDetectedCount;c++)s.push({index:c});var f=$C(a,$a);e.__isBuiltIn&&(t.getRawDataItem=function(p){return f(n,i,s,p)},t.getRawData=fe(DU,null,r)),t.cloneRawData=fe(SU,null,r);var h=YC(a,$a);t.count=fe(h,null,n,i,s);var v=QC(a);t.retrieveValue=function(p,g){var y=f(n,i,s,p);return d(y,g)};var d=t.retrieveValueFromItem=function(p,g){if(p!=null){var y=s[g];if(y)return v(p,g,y.name)}};return t.getDimensionInfo=fe(IU,null,s,l),t.cloneAllDimensionInfo=fe(TU,null,s),t}function DU(r){var e=r.sourceFormat;if(!Q1(e)){var t="";at(t)}return r.data}function SU(r){var e=r.sourceFormat,t=r.data;if(!Q1(e)){var n="";at(n)}if(e===zr){for(var a=[],i=0,o=t.length;i<o;i++)a.push(t[i].slice());return a}else if(e===Gn){for(var a=[],i=0,o=t.length;i<o;i++)a.push(X({},t[i]));return a}}function IU(r,e,t){if(t!=null){if(Ue(t)||!isNaN(t)&&!ve(e,t))return r[t];if(ve(e,t))return e[t]}}function TU(r){return Me(r)}var eN=ge();function AU(r){r=Me(r);var e=r.type,t="";e||at(t);var n=e.split(":");n.length!==2&&at(t);var a=!1;n[0]==="echarts"&&(e=n[1],a=!0),r.__isBuiltIn=a,eN.set(e,r)}function CU(r,e,t){var n=ct(r),a=n.length,i="";a||at(i);for(var o=0,s=a;o<s;o++){var l=n[o];e=NU(l,e),o!==s-1&&(e.length=Math.max(e.length,1))}return e}function NU(r,e,t,n){var a="";e.length||at(a),_e(r)||at(a);var i=r.type,o=eN.get(i);o||at(a);var s=K(e,function(u){return wU(u,o)}),l=ct(o.transform({upstream:s[0],upstreamList:s,config:Me(r.config)}));return K(l,function(u,c){var f="";_e(u)||at(f),u.data||at(f);var h=RC(u.data);Q1(h)||at(f);var v,d=e[0];if(d&&c===0&&!u.dimensions){var p=d.startIndex;p&&(u.data=d.data.slice(0,p).concat(u.data)),v={seriesLayoutBy:$a,sourceHeader:p,dimensions:d.metaRawOption.dimensions}}else v={seriesLayoutBy:$a,sourceHeader:0,dimensions:u.dimensions};return W1(u.data,v,null)})}function Q1(r){return r===zr||r===Gn}var Gd="undefined",LU=typeof Uint32Array===Gd?Array:Uint32Array,EU=typeof Uint16Array===Gd?Array:Uint16Array,tN=typeof Int32Array===Gd?Array:Int32Array,rN=typeof Float64Array===Gd?Array:Float64Array,nN={float:rN,int:tN,ordinal:Array,number:Array,time:rN},Z1;function Mf(r){return r>65535?LU:EU}function fu(){return[1/0,-1/0]}function OU(r){var e=r.constructor;return e===Array?r.slice():new e(r)}function aN(r,e,t,n,a){var i=nN[t||"float"];if(a){var o=r[e],s=o&&o.length;if(s!==n){for(var l=new i(n),u=0;u<s;u++)l[u]=o[u];r[e]=l}}else r[e]=new i(n)}var PU=function(){function r(){this._chunks=[],this._rawExtent=[],this._extent=[],this._count=0,this._rawCount=0,this._calcDimNameToIdx=ge()}return r.prototype.initData=function(e,t,n){this._provider=e,this._chunks=[],this._indices=null,this.getRawIndex=this._getRawIdxIdentity;var a=e.getSource(),i=this.defaultDimValueGetter=Z1[a.sourceFormat];this._dimValueGetter=n||i,this._rawExtent=[],FC(a),this._dimensions=K(t,function(o){return{type:o.type,property:o.property}}),this._initDataFromProvider(0,e.count())},r.prototype.getProvider=function(){return this._provider},r.prototype.getSource=function(){return this._provider.getSource()},r.prototype.ensureCalculationDimension=function(e,t){var n=this._calcDimNameToIdx,a=this._dimensions,i=n.get(e);if(i!=null){if(a[i].type===t)return i}else i=a.length;return a[i]={type:t},n.set(e,i),this._chunks[i]=new nN[t||"float"](this._rawCount),this._rawExtent[i]=fu(),i},r.prototype.collectOrdinalMeta=function(e,t){var n=this._chunks[e],a=this._dimensions[e],i=this._rawExtent,o=a.ordinalOffset||0,s=n.length;o===0&&(i[e]=fu());for(var l=i[e],u=o;u<s;u++){var c=n[u]=t.parseAndCollect(n[u]);isNaN(c)||(l[0]=Math.min(c,l[0]),l[1]=Math.max(c,l[1]))}a.ordinalMeta=t,a.ordinalOffset=s,a.type="ordinal"},r.prototype.getOrdinalMeta=function(e){var t=this._dimensions[e],n=t.ordinalMeta;return n},r.prototype.getDimensionProperty=function(e){var t=this._dimensions[e];return t&&t.property},r.prototype.appendData=function(e){var t=this._provider,n=this.count();t.appendData(e);var a=t.count();return t.persistent||(a+=n),n<a&&this._initDataFromProvider(n,a,!0),[n,a]},r.prototype.appendValues=function(e,t){for(var n=this._chunks,a=this._dimensions,i=a.length,o=this._rawExtent,s=this.count(),l=s+Math.max(e.length,t||0),u=0;u<i;u++){var c=a[u];aN(n,u,c.type,l,!0)}for(var f=[],h=s;h<l;h++)for(var v=h-s,d=0;d<i;d++){var c=a[d],p=Z1.arrayRows.call(this,e[v]||f,c.property,v,d);n[d][h]=p;var g=o[d];p<g[0]&&(g[0]=p),p>g[1]&&(g[1]=p)}return this._rawCount=this._count=l,{start:s,end:l}},r.prototype._initDataFromProvider=function(e,t,n){for(var a=this._provider,i=this._chunks,o=this._dimensions,s=o.length,l=this._rawExtent,u=K(o,function(m){return m.property}),c=0;c<s;c++){var f=o[c];l[c]||(l[c]=fu()),aN(i,c,f.type,t,n)}if(a.fillStorage)a.fillStorage(e,t,i,l);else for(var h=[],v=e;v<t;v++){h=a.getItem(v,h);for(var d=0;d<s;d++){var p=i[d],g=this._dimValueGetter(h,u[d],v,d);p[v]=g;var y=l[d];g<y[0]&&(y[0]=g),g>y[1]&&(y[1]=g)}}!a.persistent&&a.clean&&a.clean(),this._rawCount=this._count=t,this._extent=[]},r.prototype.count=function(){return this._count},r.prototype.get=function(e,t){if(!(t>=0&&t<this._count))return NaN;var n=this._chunks[e];return n?n[this.getRawIndex(t)]:NaN},r.prototype.getValues=function(e,t){var n=[],a=[];if(t==null){t=e,e=[];for(var i=0;i<this._dimensions.length;i++)a.push(i)}else a=e;for(var i=0,o=a.length;i<o;i++)n.push(this.get(a[i],t));return n},r.prototype.getByRawIndex=function(e,t){if(!(t>=0&&t<this._rawCount))return NaN;var n=this._chunks[e];return n?n[t]:NaN},r.prototype.getSum=function(e){var t=this._chunks[e],n=0;if(t)for(var a=0,i=this.count();a<i;a++){var o=this.get(e,a);isNaN(o)||(n+=o)}return n},r.prototype.getMedian=function(e){var t=[];this.each([e],function(i){isNaN(i)||t.push(i)});var n=t.sort(function(i,o){return i-o}),a=this.count();return a===0?0:a%2===1?n[(a-1)/2]:(n[a/2]+n[a/2-1])/2},r.prototype.indexOfRawIndex=function(e){if(e>=this._rawCount||e<0)return-1;if(!this._indices)return e;var t=this._indices,n=t[e];if(n!=null&&n<this._count&&n===e)return e;for(var a=0,i=this._count-1;a<=i;){var o=(a+i)/2|0;if(t[o]<e)a=o+1;else if(t[o]>e)i=o-1;else return o}return-1},r.prototype.indicesOfNearest=function(e,t,n){var a=this._chunks,i=a[e],o=[];if(!i)return o;n==null&&(n=1/0);for(var s=1/0,l=-1,u=0,c=0,f=this.count();c<f;c++){var h=this.getRawIndex(c),v=t-i[h],d=Math.abs(v);d<=n&&((d<s||d===s&&v>=0&&l<0)&&(s=d,l=v,u=0),v===l&&(o[u++]=c))}return o.length=u,o},r.prototype.getIndices=function(){var e,t=this._indices;if(t){var n=t.constructor,a=this._count;if(n===Array){e=new n(a);for(var i=0;i<a;i++)e[i]=t[i]}else e=new n(t.buffer,0,a)}else{var n=Mf(this._rawCount);e=new n(this.count());for(var i=0;i<e.length;i++)e[i]=i}return e},r.prototype.filter=function(e,t){if(!this._count)return this;for(var n=this.clone(),a=n.count(),i=Mf(n._rawCount),o=new i(a),s=[],l=e.length,u=0,c=e[0],f=n._chunks,h=0;h<a;h++){var v=void 0,d=n.getRawIndex(h);if(l===0)v=t(h);else if(l===1){var p=f[c][d];v=t(p,h)}else{for(var g=0;g<l;g++)s[g]=f[e[g]][d];s[g]=h,v=t.apply(null,s)}v&&(o[u++]=d)}return u<a&&(n._indices=o),n._count=u,n._extent=[],n._updateGetRawIdx(),n},r.prototype.selectRange=function(e){var t=this.clone(),n=t._count;if(!n)return this;var a=Fe(e),i=a.length;if(!i)return this;var o=t.count(),s=Mf(t._rawCount),l=new s(o),u=0,c=a[0],f=e[c][0],h=e[c][1],v=t._chunks,d=!1;if(!t._indices){var p=0;if(i===1){for(var g=v[a[0]],y=0;y<n;y++){var m=g[y];(m>=f&&m<=h||isNaN(m))&&(l[u++]=p),p++}d=!0}else if(i===2){for(var g=v[a[0]],_=v[a[1]],b=e[a[1]][0],x=e[a[1]][1],y=0;y<n;y++){var m=g[y],M=_[y];(m>=f&&m<=h||isNaN(m))&&(M>=b&&M<=x||isNaN(M))&&(l[u++]=p),p++}d=!0}}if(!d)if(i===1)for(var y=0;y<o;y++){var w=t.getRawIndex(y),m=v[a[0]][w];(m>=f&&m<=h||isNaN(m))&&(l[u++]=w)}else for(var y=0;y<o;y++){for(var D=!0,w=t.getRawIndex(y),T=0;T<i;T++){var I=a[T],m=v[I][w];(m<e[I][0]||m>e[I][1])&&(D=!1)}D&&(l[u++]=t.getRawIndex(y))}return u<o&&(t._indices=l),t._count=u,t._extent=[],t._updateGetRawIdx(),t},r.prototype.map=function(e,t){var n=this.clone(e);return this._updateDims(n,e,t),n},r.prototype.modify=function(e,t){this._updateDims(this,e,t)},r.prototype._updateDims=function(e,t,n){for(var a=e._chunks,i=[],o=t.length,s=e.count(),l=[],u=e._rawExtent,c=0;c<t.length;c++)u[t[c]]=fu();for(var f=0;f<s;f++){for(var h=e.getRawIndex(f),v=0;v<o;v++)l[v]=a[t[v]][h];l[o]=f;var d=n&&n.apply(null,l);if(d!=null){typeof d!="object"&&(i[0]=d,d=i);for(var c=0;c<d.length;c++){var p=t[c],g=d[c],y=u[p],m=a[p];m&&(m[h]=g),g<y[0]&&(y[0]=g),g>y[1]&&(y[1]=g)}}}},r.prototype.lttbDownSample=function(e,t){var n=this.clone([e],!0),a=n._chunks,i=a[e],o=this.count(),s=0,l=Math.floor(1/t),u=this.getRawIndex(0),c,f,h,v=new(Mf(this._rawCount))(Math.min((Math.ceil(o/l)+2)*2,o));v[s++]=u;for(var d=1;d<o-1;d+=l){for(var p=Math.min(d+l,o-1),g=Math.min(d+l*2,o),y=(g+p)/2,m=0,_=p;_<g;_++){var b=this.getRawIndex(_),x=i[b];isNaN(x)||(m+=x)}m/=g-p;var M=d,w=Math.min(d+l,o),D=d-1,T=i[u];c=-1,h=M;for(var I=-1,A=0,_=M;_<w;_++){var b=this.getRawIndex(_),x=i[b];if(isNaN(x)){A++,I<0&&(I=b);continue}f=Math.abs((D-y)*(x-T)-(D-_)*(m-T)),f>c&&(c=f,h=b)}A>0&&A<w-M&&(v[s++]=Math.min(I,h),h=Math.max(I,h)),v[s++]=h,u=h}return v[s++]=this.getRawIndex(o-1),n._count=s,n._indices=v,n.getRawIndex=this._getRawIdx,n},r.prototype.downSample=function(e,t,n,a){for(var i=this.clone([e],!0),o=i._chunks,s=[],l=Math.floor(1/t),u=o[e],c=this.count(),f=i._rawExtent[e]=fu(),h=new(Mf(this._rawCount))(Math.ceil(c/l)),v=0,d=0;d<c;d+=l){l>c-d&&(l=c-d,s.length=l);for(var p=0;p<l;p++){var g=this.getRawIndex(d+p);s[p]=u[g]}var y=n(s),m=this.getRawIndex(Math.min(d+a(s,y)||0,c-1));u[m]=y,y<f[0]&&(f[0]=y),y>f[1]&&(f[1]=y),h[v++]=m}return i._count=v,i._indices=h,i._updateGetRawIdx(),i},r.prototype.each=function(e,t){if(!!this._count)for(var n=e.length,a=this._chunks,i=0,o=this.count();i<o;i++){var s=this.getRawIndex(i);switch(n){case 0:t(i);break;case 1:t(a[e[0]][s],i);break;case 2:t(a[e[0]][s],a[e[1]][s],i);break;default:for(var l=0,u=[];l<n;l++)u[l]=a[e[l]][s];u[l]=i,t.apply(null,u)}}},r.prototype.getDataExtent=function(e){var t=this._chunks[e],n=fu();if(!t)return n;var a=this.count(),i=!this._indices,o;if(i)return this._rawExtent[e].slice();if(o=this._extent[e],o)return o.slice();o=n;for(var s=o[0],l=o[1],u=0;u<a;u++){var c=this.getRawIndex(u),f=t[c];f<s&&(s=f),f>l&&(l=f)}return o=[s,l],this._extent[e]=o,o},r.prototype.getRawDataItem=function(e){var t=this.getRawIndex(e);if(this._provider.persistent)return this._provider.getItem(t);for(var n=[],a=this._chunks,i=0;i<a.length;i++)n.push(a[i][t]);return n},r.prototype.clone=function(e,t){var n=new r,a=this._chunks,i=e&&On(e,function(s,l){return s[l]=!0,s},{});if(i)for(var o=0;o<a.length;o++)n._chunks[o]=i[o]?OU(a[o]):a[o];else n._chunks=a;return this._copyCommonProps(n),t||(n._indices=this._cloneIndices()),n._updateGetRawIdx(),n},r.prototype._copyCommonProps=function(e){e._count=this._count,e._rawCount=this._rawCount,e._provider=this._provider,e._dimensions=this._dimensions,e._extent=Me(this._extent),e._rawExtent=Me(this._rawExtent)},r.prototype._cloneIndices=function(){if(this._indices){var e=this._indices.constructor,t=void 0;if(e===Array){var n=this._indices.length;t=new e(n);for(var a=0;a<n;a++)t[a]=this._indices[a]}else t=new e(this._indices);return t}return null},r.prototype._getRawIdxIdentity=function(e){return e},r.prototype._getRawIdx=function(e){return e<this._count&&e>=0?this._indices[e]:-1},r.prototype._updateGetRawIdx=function(){this.getRawIndex=this._indices?this._getRawIdx:this._getRawIdxIdentity},r.internalField=function(){function e(t,n,a,i){return vo(t[i],this._dimensions[i])}Z1={arrayRows:e,objectRows:function(t,n,a,i){return vo(t[n],this._dimensions[i])},keyedColumns:e,original:function(t,n,a,i){var o=t&&(t.value==null?t:t.value);return vo(o instanceof Array?o[i]:o,this._dimensions[i])},typedArray:function(t,n,a,i){return t[i]}}}(),r}(),q1=PU,iN=function(){function r(e){this._sourceList=[],this._storeList=[],this._upstreamSignList=[],this._versionSignBase=0,this._dirty=!0,this._sourceHost=e}return r.prototype.dirty=function(){this._setLocalSource([],[]),this._storeList=[],this._dirty=!0},r.prototype._setLocalSource=function(e,t){this._sourceList=e,this._upstreamSignList=t,this._versionSignBase++,this._versionSignBase>9e10&&(this._versionSignBase=0)},r.prototype._getVersionSign=function(){return this._sourceHost.uid+"_"+this._versionSignBase},r.prototype.prepareSource=function(){this._isDirty()&&(this._createSource(),this._dirty=!1)},r.prototype._createSource=function(){this._setLocalSource([],[]);var e=this._sourceHost,t=this._getUpstreamSourceManagers(),n=!!t.length,a,i;if($d(e)){var o=e,s=void 0,l=void 0,u=void 0;if(n){var c=t[0];c.prepareSource(),u=c.getSource(),s=u.data,l=u.sourceFormat,i=[c._getVersionSign()]}else s=o.get("data",!0),l=an(s)?ho:Wn,i=[];var f=this._getSourceMetaRawOption()||{},h=u&&u.metaRawOption||{},v=Ee(f.seriesLayoutBy,h.seriesLayoutBy)||null,d=Ee(f.sourceHeader,h.sourceHeader),p=Ee(f.dimensions,h.dimensions),g=v!==h.seriesLayoutBy||!!d!=!!h.sourceHeader||p;a=g?[W1(s,{seriesLayoutBy:v,sourceHeader:d,dimensions:p},l)]:[]}else{var y=e;if(n){var m=this._applyTransform(t);a=m.sourceList,i=m.upstreamSignList}else{var _=y.get("source",!0);a=[W1(_,this._getSourceMetaRawOption(),null)],i=[]}}this._setLocalSource(a,i)},r.prototype._applyTransform=function(e){var t=this._sourceHost,n=t.get("transform",!0),a=t.get("fromTransformResult",!0);if(a!=null){var i="";e.length!==1&&sN(i)}var o,s=[],l=[];return C(e,function(u){u.prepareSource();var c=u.getSource(a||0),f="";a!=null&&!c&&sN(f),s.push(c),l.push(u._getVersionSign())}),n?o=CU(n,s,{datasetIndex:t.componentIndex}):a!=null&&(o=[cU(s[0])]),{sourceList:o,upstreamSignList:l}},r.prototype._isDirty=function(){if(this._dirty)return!0;for(var e=this._getUpstreamSourceManagers(),t=0;t<e.length;t++){var n=e[t];if(n._isDirty()||this._upstreamSignList[t]!==n._getVersionSign())return!0}},r.prototype.getSource=function(e){e=e||0;var t=this._sourceList[e];if(!t){var n=this._getUpstreamSourceManagers();return n[0]&&n[0].getSource(e)}return t},r.prototype.getSharedDataStore=function(e){var t=e.makeStoreSchema();return this._innerGetDataStore(t.dimensions,e.source,t.hash)},r.prototype._innerGetDataStore=function(e,t,n){var a=0,i=this._storeList,o=i[a];o||(o=i[a]={});var s=o[n];if(!s){var l=this._getUpstreamSourceManagers()[0];$d(this._sourceHost)&&l?s=l._innerGetDataStore(e,t,n):(s=new q1,s.initData(new WC(t,e.length),e)),o[n]=s}return s},r.prototype._getUpstreamSourceManagers=function(){var e=this._sourceHost;if($d(e)){var t=z1(e);return t?[t.getSourceManager()]:[]}else return K(k$(e),function(n){return n.getSourceManager()})},r.prototype._getSourceMetaRawOption=function(){var e=this._sourceHost,t,n,a;if($d(e))t=e.get("seriesLayoutBy",!0),n=e.get("sourceHeader",!0),a=e.get("dimensions",!0);else if(!this._getUpstreamSourceManagers().length){var i=e;t=i.get("seriesLayoutBy",!0),n=i.get("sourceHeader",!0),a=i.get("dimensions",!0)}return{seriesLayoutBy:t,sourceHeader:n,dimensions:a}},r}();function oN(r){var e=r.option.transform;e&&pc(r.option.transform)}function $d(r){return r.mainType==="series"}function sN(r){throw new Error(r)}var lN="line-height:1";function uN(r,e){var t=r.color||"#6e7079",n=r.fontSize||12,a=r.fontWeight||"400",i=r.color||"#464646",o=r.fontSize||14,s=r.fontWeight||"900";return e==="html"?{nameStyle:"font-size:"+$r(n+"")+"px;color:"+$r(t)+";font-weight:"+$r(a+""),valueStyle:"font-size:"+$r(o+"")+"px;color:"+$r(i)+";font-weight:"+$r(s+"")}:{nameStyle:{fontSize:n,fill:t,fontWeight:a},valueStyle:{fontSize:o,fill:i,fontWeight:s}}}var zU=[0,10,20,30],kU=["",`
|
|
231
|
+
`,`
|
|
232
|
+
|
|
233
|
+
`,`
|
|
234
|
+
|
|
235
|
+
|
|
236
|
+
`];function lr(r,e){return e.type=r,e}function X1(r){return r.type==="section"}function cN(r){return X1(r)?RU:jU}function fN(r){if(X1(r)){var e=0,t=r.blocks.length,n=t>1||t>0&&!r.noHeader;return C(r.blocks,function(a){var i=fN(a);i>=e&&(e=i+ +(n&&(!i||X1(a)&&!a.noHeader)))}),e}return 0}function RU(r,e,t,n){var a=e.noHeader,i=BU(fN(e)),o=[],s=e.blocks||[];Er(!s||J(s)),s=s||[];var l=r.orderMode;if(e.sortBlocks&&l){s=s.slice();var u={valueAsc:"asc",valueDesc:"desc"};if(ve(u,l)){var c=new KC(u[l],null);s.sort(function(d,p){return c.evaluate(d.sortParam,p.sortParam)})}else l==="seriesDesc"&&s.reverse()}C(s,function(d,p){var g=e.valueFormatter,y=cN(d)(g?X(X({},r),{valueFormatter:g}):r,d,p>0?i.html:0,n);y!=null&&o.push(y)});var f=r.renderMode==="richText"?o.join(i.richText):J1(o.join(""),a?t:i.html);if(a)return f;var h=N1(e.header,"ordinal",r.useUTC),v=uN(n,r.renderMode).nameStyle;return r.renderMode==="richText"?vN(r,h,v)+i.richText+f:J1('<div style="'+v+";"+lN+';">'+$r(h)+"</div>"+f,t)}function jU(r,e,t,n){var a=r.renderMode,i=e.noName,o=e.noValue,s=!e.markerType,l=e.name,u=r.useUTC,c=e.valueFormatter||r.valueFormatter||function(b){return b=J(b)?b:[b],K(b,function(x,M){return N1(x,J(v)?v[M]:v,u)})};if(!(i&&o)){var f=s?"":r.markupStyleCreator.makeTooltipMarker(e.markerType,e.markerColor||"#333",a),h=i?"":N1(l,"ordinal",u),v=e.valueType,d=o?[]:c(e.value),p=!s||!i,g=!s&&i,y=uN(n,a),m=y.nameStyle,_=y.valueStyle;return a==="richText"?(s?"":f)+(i?"":vN(r,h,m))+(o?"":HU(r,d,p,g,_)):J1((s?"":f)+(i?"":FU(h,!s,m))+(o?"":VU(d,p,g,_)),t)}}function hN(r,e,t,n,a,i){if(!!r){var o=cN(r),s={useUTC:a,renderMode:t,orderMode:n,markupStyleCreator:e,valueFormatter:r.valueFormatter};return o(s,r,0,i)}}function BU(r){return{html:zU[r],richText:kU[r]}}function J1(r,e){var t='<div style="clear:both"></div>',n="margin: "+e+"px 0 0";return'<div style="'+n+";"+lN+';">'+r+t+"</div>"}function FU(r,e,t){var n=e?"margin-left:2px":"";return'<span style="'+t+";"+n+'">'+$r(r)+"</span>"}function VU(r,e,t,n){var a=t?"10px":"20px",i=e?"float:right;margin-left:"+a:"";return r=J(r)?r:[r],'<span style="'+i+";"+n+'">'+K(r,function(o){return $r(o)}).join(" ")+"</span>"}function vN(r,e,t){return r.markupStyleCreator.wrapRichTextStyle(e,t)}function HU(r,e,t,n,a){var i=[a],o=n?10:20;return t&&i.push({padding:[0,0,0,o],align:"right"}),r.markupStyleCreator.wrapRichTextStyle(J(e)?e.join(" "):e,i)}function dN(r,e){var t=r.getData().getItemVisual(e,"style"),n=t[r.visualDrawType];return ws(n)}function pN(r,e){var t=r.get("padding");return t!=null?t:e==="richText"?[8,10]:10}var K1=function(){function r(){this.richTextStyles={},this._nextStyleNameId=JI()}return r.prototype._generateStyleName=function(){return"__EC_aUTo_"+this._nextStyleNameId++},r.prototype.makeTooltipMarker=function(e,t,n){var a=n==="richText"?this._generateStyleName():null,i=cC({color:t,type:e,renderMode:n,markerId:a});return ce(i)?i:(this.richTextStyles[a]=i.style,i.content)},r.prototype.wrapRichTextStyle=function(e,t){var n={};J(t)?C(t,function(i){return X(n,i)}):X(n,t);var a=this._generateStyleName();return this.richTextStyles[a]=n,"{"+a+"|"+e+"}"},r}();function gN(r){var e=r.series,t=r.dataIndex,n=r.multipleSeries,a=e.getData(),i=a.mapDimensionsAll("defaultedTooltip"),o=i.length,s=e.getRawValue(t),l=J(s),u=dN(e,t),c,f,h,v;if(o>1||l&&!o){var d=WU(s,e,t,i,u);c=d.inlineValues,f=d.inlineValueTypes,h=d.blocks,v=d.inlineValues[0]}else if(o){var p=a.getDimensionInfo(i[0]);v=c=cu(a,t,i[0]),f=p.type}else v=c=l?s[0]:s;var g=C0(e),y=g&&e.name||"",m=a.getName(t),_=n?y:m;return lr("section",{header:y,noHeader:n||!g,sortParam:v,blocks:[lr("nameValue",{markerType:"item",markerColor:u,name:_,noName:!Pn(_),value:c,valueType:f})].concat(h||[])})}function WU(r,e,t,n,a){var i=e.getData(),o=On(r,function(f,h,v){var d=i.getDimensionInfo(v);return f=f||d&&d.tooltip!==!1&&d.displayName!=null},!1),s=[],l=[],u=[];n.length?C(n,function(f){c(cu(i,t,f),f)}):C(r,c);function c(f,h){var v=i.getDimensionInfo(h);!v||v.otherDims.tooltip===!1||(o?u.push(lr("nameValue",{markerType:"subItem",markerColor:a,name:v.displayName,value:f,valueType:v.type})):(s.push(f),l.push(v.type)))}return{inlineValues:s,inlineValueTypes:l,blocks:u}}var po=Ye();function Ud(r,e){return r.getName(e)||r.getId(e)}var Yd="__universalTransitionEnabled",Qd=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t._selectedDataIndicesMap={},t}return e.prototype.init=function(t,n,a){this.seriesIndex=this.componentIndex,this.dataTask=bf({count:$U,reset:UU}),this.dataTask.context={model:this},this.mergeDefaultAndTheme(t,a);var i=po(this).sourceManager=new iN(this);i.prepareSource();var o=this.getInitialData(t,a);mN(o,this),this.dataTask.context.data=o,po(this).dataBeforeProcessed=o,yN(this),this._initSelectedMapFromData(o)},e.prototype.mergeDefaultAndTheme=function(t,n){var a=pf(this),i=a?iu(t):{},o=this.subType;He.hasClass(o)&&(o+="Series"),Ne(t,n.getTheme().get(this.subType)),Ne(t,this.getDefaultOption()),ns(t,"label",["show"]),this.fillDataTextStyle(t.data),a&&fo(t,i,a)},e.prototype.mergeOption=function(t,n){t=Ne(this.option,t,!0),this.fillDataTextStyle(t.data);var a=pf(this);a&&fo(this.option,t,a);var i=po(this).sourceManager;i.dirty(),i.prepareSource();var o=this.getInitialData(t,n);mN(o,this),this.dataTask.dirty(),this.dataTask.context.data=o,po(this).dataBeforeProcessed=o,yN(this),this._initSelectedMapFromData(o)},e.prototype.fillDataTextStyle=function(t){if(t&&!an(t))for(var n=["show"],a=0;a<t.length;a++)t[a]&&t[a].label&&ns(t[a],"label",n)},e.prototype.getInitialData=function(t,n){},e.prototype.appendData=function(t){var n=this.getRawData();n.appendData(t.data)},e.prototype.getData=function(t){var n=e_(this);if(n){var a=n.context.data;return t==null?a:a.getLinkedData(t)}else return po(this).data},e.prototype.getAllData=function(){var t=this.getData();return t&&t.getLinkedDataAll?t.getLinkedDataAll():[{data:t}]},e.prototype.setData=function(t){var n=e_(this);if(n){var a=n.context;a.outputData=t,n!==this.dataTask&&(a.data=t)}po(this).data=t},e.prototype.getEncode=function(){var t=this.get("encode",!0);if(t)return ge(t)},e.prototype.getSourceManager=function(){return po(this).sourceManager},e.prototype.getSource=function(){return this.getSourceManager().getSource()},e.prototype.getRawData=function(){return po(this).dataBeforeProcessed},e.prototype.getColorBy=function(){var t=this.get("colorBy");return t||"series"},e.prototype.isColorBySeries=function(){return this.getColorBy()==="series"},e.prototype.getBaseAxis=function(){var t=this.coordinateSystem;return t&&t.getBaseAxis&&t.getBaseAxis()},e.prototype.formatTooltip=function(t,n,a){return gN({series:this,dataIndex:t,multipleSeries:n})},e.prototype.isAnimationEnabled=function(){var t=this.ecModel;if($e.node&&!(t&&t.ssr))return!1;var n=this.getShallow("animation");return n&&this.getData().count()>this.getShallow("animationThreshold")&&(n=!1),!!n},e.prototype.restoreData=function(){this.dataTask.dirty()},e.prototype.getColorFromPalette=function(t,n,a){var i=this.ecModel,o=R1.prototype.getColorFromPalette.call(this,t,n,a);return o||(o=i.getColorFromPalette(t,n,a)),o},e.prototype.coordDimToDataDim=function(t){return this.getRawData().mapDimensionsAll(t)},e.prototype.getProgressive=function(){return this.get("progressive")},e.prototype.getProgressiveThreshold=function(){return this.get("progressiveThreshold")},e.prototype.select=function(t,n){this._innerSelect(this.getData(n),t)},e.prototype.unselect=function(t,n){var a=this.option.selectedMap;if(!!a){var i=this.option.selectedMode,o=this.getData(n);if(i==="series"||a==="all"){this.option.selectedMap={},this._selectedDataIndicesMap={};return}for(var s=0;s<t.length;s++){var l=t[s],u=Ud(o,l);a[u]=!1,this._selectedDataIndicesMap[u]=-1}}},e.prototype.toggleSelect=function(t,n){for(var a=[],i=0;i<t.length;i++)a[0]=t[i],this.isSelected(t[i],n)?this.unselect(a,n):this.select(a,n)},e.prototype.getSelectedDataIndices=function(){if(this.option.selectedMap==="all")return[].slice.call(this.getData().getIndices());for(var t=this._selectedDataIndicesMap,n=Fe(t),a=[],i=0;i<n.length;i++){var o=t[n[i]];o>=0&&a.push(o)}return a},e.prototype.isSelected=function(t,n){var a=this.option.selectedMap;if(!a)return!1;var i=this.getData(n);return(a==="all"||a[Ud(i,t)])&&!i.getItemModel(t).get(["select","disabled"])},e.prototype.isUniversalTransitionEnabled=function(){if(this[Yd])return!0;var t=this.option.universalTransition;return t?t===!0?!0:t&&t.enabled:!1},e.prototype._innerSelect=function(t,n){var a,i,o=this.option,s=o.selectedMode,l=n.length;if(!(!s||!l)){if(s==="series")o.selectedMap="all";else if(s==="multiple"){_e(o.selectedMap)||(o.selectedMap={});for(var u=o.selectedMap,c=0;c<l;c++){var f=n[c],h=Ud(t,f);u[h]=!0,this._selectedDataIndicesMap[h]=t.getRawIndex(f)}}else if(s==="single"||s===!0){var v=n[l-1],h=Ud(t,v);o.selectedMap=(a={},a[h]=!0,a),this._selectedDataIndicesMap=(i={},i[h]=t.getRawIndex(v),i)}}},e.prototype._initSelectedMapFromData=function(t){if(!this.option.selectedMap){var n=[];t.hasItemOption&&t.each(function(a){var i=t.getRawDataItem(a);i&&i.selected&&n.push(a)}),n.length>0&&this._innerSelect(t,n)}},e.registerClass=function(t){return He.registerClass(t)},e.protoInitialize=function(){var t=e.prototype;t.type="series.__base__",t.seriesIndex=0,t.ignoreStyleOnData=!1,t.hasSymbolVisual=!1,t.defaultSymbol="circle",t.visualStyleAccessPath="itemStyle",t.visualDrawType="fill"}(),e}(He);Et(Qd,Y1),Et(Qd,R1),fT(Qd,He);function yN(r){var e=r.name;C0(r)||(r.name=GU(r)||e)}function GU(r){var e=r.getRawData(),t=e.mapDimensionsAll("seriesName"),n=[];return C(t,function(a){var i=e.getDimensionInfo(a);i.displayName&&n.push(i.displayName)}),n.join(" ")}function $U(r){return r.model.getRawData().count()}function UU(r){var e=r.model;return e.setData(e.getRawData().cloneShallow()),YU}function YU(r,e){e.outputData&&r.end>e.outputData.count()&&e.model.getRawData().cloneShallow(e.outputData)}function mN(r,e){C(gc(r.CHANGABLE_METHODS,r.DOWNSAMPLE_METHODS),function(t){r.wrapMethod(t,Ae(QU,e))})}function QU(r,e){var t=e_(r);return t&&t.setOutputEnd((e||this).count()),e}function e_(r){var e=(r.ecModel||{}).scheduler,t=e&&e.getPipeline(r.uid);if(t){var n=t.currentTask;if(n){var a=n.agentStubMap;a&&(n=a.get(r.uid))}return n}}var bt=Qd,t_=function(){function r(){this.group=new De,this.uid=ru("viewComponent")}return r.prototype.init=function(e,t){},r.prototype.render=function(e,t,n,a){},r.prototype.dispose=function(e,t){},r.prototype.updateView=function(e,t,n,a){},r.prototype.updateLayout=function(e,t,n,a){},r.prototype.updateVisual=function(e,t,n,a){},r.prototype.toggleBlurSeries=function(e,t,n){},r.prototype.eachRendered=function(e){var t=this.group;t&&t.traverse(e)},r}();E0(t_),nd(t_);var St=t_;function hu(){var r=Ye();return function(e){var t=r(e),n=e.pipelineContext,a=!!t.large,i=!!t.progressiveRender,o=t.large=!!(n&&n.large),s=t.progressiveRender=!!(n&&n.progressiveRender);return(a!==o||i!==s)&&"reset"}}var _N=Ye(),ZU=hu(),r_=function(){function r(){this.group=new De,this.uid=ru("viewChart"),this.renderTask=bf({plan:qU,reset:XU}),this.renderTask.context={view:this}}return r.prototype.init=function(e,t){},r.prototype.render=function(e,t,n,a){},r.prototype.highlight=function(e,t,n,a){var i=e.getData(a&&a.dataType);!i||MN(i,a,"emphasis")},r.prototype.downplay=function(e,t,n,a){var i=e.getData(a&&a.dataType);!i||MN(i,a,"normal")},r.prototype.remove=function(e,t){this.group.removeAll()},r.prototype.dispose=function(e,t){},r.prototype.updateView=function(e,t,n,a){this.render(e,t,n,a)},r.prototype.updateLayout=function(e,t,n,a){this.render(e,t,n,a)},r.prototype.updateVisual=function(e,t,n,a){this.render(e,t,n,a)},r.prototype.eachRendered=function(e){uo(this.group,e)},r.markUpdateMethod=function(e,t){_N(e).updateMethod=t},r.protoInitialize=function(){var e=r.prototype;e.type="chart"}(),r}();function bN(r,e,t){r&&Jc(r)&&(e==="emphasis"?mi:_i)(r,t)}function MN(r,e,t){var n=as(r,e),a=e&&e.highlightKey!=null?DG(e.highlightKey):null;n!=null?C(ct(n),function(i){bN(r.getItemGraphicEl(i),t,a)}):r.eachItemGraphicEl(function(i){bN(i,t,a)})}E0(r_),nd(r_);function qU(r){return ZU(r.model)}function XU(r){var e=r.model,t=r.ecModel,n=r.api,a=r.payload,i=e.pipelineContext.progressiveRender,o=r.view,s=a&&_N(a).updateMethod,l=i?"incrementalPrepareRender":s&&o[s]?s:"render";return l!=="render"&&o[l](e,t,n,a),JU[l]}var JU={incrementalPrepareRender:{progress:function(r,e){e.view.incrementalRender(r,e.model,e.ecModel,e.api,e.payload)}},render:{forceFirstProgress:!0,progress:function(r,e){e.view.render(e.model,e.ecModel,e.api,e.payload)}}},ht=r_,Zd="\0__throttleOriginMethod",xN="\0__throttleRate",wN="\0__throttleType";function qd(r,e,t){var n,a=0,i=0,o=null,s,l,u,c;e=e||0;function f(){i=new Date().getTime(),o=null,r.apply(l,u||[])}var h=function(){for(var v=[],d=0;d<arguments.length;d++)v[d]=arguments[d];n=new Date().getTime(),l=this,u=v;var p=c||e,g=c||t;c=null,s=n-(g?a:i)-p,clearTimeout(o),g?o=setTimeout(f,p):s>=0?f():o=setTimeout(f,-s),a=n};return h.clear=function(){o&&(clearTimeout(o),o=null)},h.debounceNextCall=function(v){c=v},h}function vu(r,e,t,n){var a=r[e];if(!!a){var i=a[Zd]||a,o=a[wN],s=a[xN];if(s!==t||o!==n){if(t==null||!n)return r[e]=i;a=r[e]=qd(i,t,n==="debounce"),a[Zd]=i,a[wN]=n,a[xN]=t}return a}}function xf(r,e){var t=r[e];t&&t[Zd]&&(t.clear&&t.clear(),r[e]=t[Zd])}var DN=Ye(),SN={itemStyle:os(qA,!0),lineStyle:os(ZA,!0)},KU={lineStyle:"stroke",itemStyle:"fill"};function IN(r,e){var t=r.visualStyleMapper||SN[e];return t||(console.warn("Unknown style type '"+e+"'."),SN.itemStyle)}function TN(r,e){var t=r.visualDrawType||KU[e];return t||(console.warn("Unknown style type '"+e+"'."),"fill")}var e9={createOnAllSeries:!0,performRawSeries:!0,reset:function(r,e){var t=r.getData(),n=r.visualStyleAccessPath||"itemStyle",a=r.getModel(n),i=IN(r,n),o=i(a),s=a.getShallow("decal");s&&(t.setVisual("decal",s),s.dirty=!0);var l=TN(r,n),u=o[l],c=ye(u)?u:null,f=o.fill==="auto"||o.stroke==="auto";if(!o[l]||c||f){var h=r.getColorFromPalette(r.name,null,e.getSeriesCount());o[l]||(o[l]=h,t.setVisual("colorFromPalette",!0)),o.fill=o.fill==="auto"||ye(o.fill)?h:o.fill,o.stroke=o.stroke==="auto"||ye(o.stroke)?h:o.stroke}if(t.setVisual("style",o),t.setVisual("drawType",l),!e.isSeriesFiltered(r)&&c)return t.setVisual("colorFromPalette",!1),{dataEach:function(v,d){var p=r.getDataParams(d),g=X({},o);g[l]=c(p),v.setItemVisual(d,"style",g)}}}},wf=new ft,t9={createOnAllSeries:!0,performRawSeries:!0,reset:function(r,e){if(!(r.ignoreStyleOnData||e.isSeriesFiltered(r))){var t=r.getData(),n=r.visualStyleAccessPath||"itemStyle",a=IN(r,n),i=t.getVisual("drawType");return{dataEach:t.hasItemOption?function(o,s){var l=o.getRawDataItem(s);if(l&&l[n]){wf.option=l[n];var u=a(wf),c=o.ensureUniqueItemVisual(s,"style");X(c,u),wf.option.decal&&(o.setItemVisual(s,"decal",wf.option.decal),wf.option.decal.dirty=!0),i in u&&o.setItemVisual(s,"colorFromPalette",!1)}}:null}}}},r9={performRawSeries:!0,overallReset:function(r){var e=ge();r.eachSeries(function(t){var n=t.getColorBy();if(!t.isColorBySeries()){var a=t.type+"-"+n,i=e.get(a);i||(i={},e.set(a,i)),DN(t).scope=i}}),r.eachSeries(function(t){if(!(t.isColorBySeries()||r.isSeriesFiltered(t))){var n=t.getRawData(),a={},i=t.getData(),o=DN(t).scope,s=t.visualStyleAccessPath||"itemStyle",l=TN(t,s);i.each(function(u){var c=i.getRawIndex(u);a[c]=u}),n.each(function(u){var c=a[u],f=i.getItemVisual(c,"colorFromPalette");if(f){var h=i.ensureUniqueItemVisual(c,"style"),v=n.getName(u)||u+"",d=n.count();h[l]=t.getColorFromPalette(v,o,d)}})}})}},Xd=Math.PI;function n9(r,e){e=e||{},me(e,{text:"loading",textColor:"#000",fontSize:12,fontWeight:"normal",fontStyle:"normal",fontFamily:"sans-serif",maskColor:"rgba(255, 255, 255, 0.8)",showSpinner:!0,color:"#5470c6",spinnerRadius:10,lineWidth:5,zlevel:0});var t=new De,n=new We({style:{fill:e.maskColor},zlevel:e.zlevel,z:1e4});t.add(n);var a=new Ge({style:{text:e.text,fill:e.textColor,fontSize:e.fontSize,fontWeight:e.fontWeight,fontStyle:e.fontStyle,fontFamily:e.fontFamily},zlevel:e.zlevel,z:10001}),i=new We({style:{fill:"none"},textContent:a,textConfig:{position:"right",distance:10},zlevel:e.zlevel,z:10001});t.add(i);var o;return e.showSpinner&&(o=new bd({shape:{startAngle:-Xd/2,endAngle:-Xd/2+.1,r:e.spinnerRadius},style:{stroke:e.color,lineCap:"round",lineWidth:e.lineWidth},zlevel:e.zlevel,z:10001}),o.animateShape(!0).when(1e3,{endAngle:Xd*3/2}).start("circularInOut"),o.animateShape(!0).when(1e3,{startAngle:Xd*3/2}).delay(300).start("circularInOut"),t.add(o)),t.resize=function(){var s=a.getBoundingRect().width,l=e.showSpinner?e.spinnerRadius:0,u=(r.getWidth()-l*2-(e.showSpinner&&s?10:0)-s)/2-(e.showSpinner&&s?0:5+s/2)+(e.showSpinner?0:s/2)+(s?0:l),c=r.getHeight()/2;e.showSpinner&&o.setShape({cx:u,cy:c}),i.setShape({x:u-l,y:c-l,width:l*2,height:l*2}),n.setShape({x:0,y:0,width:r.getWidth(),height:r.getHeight()})},t.resize(),t}var a9=function(){function r(e,t,n,a){this._stageTaskMap=ge(),this.ecInstance=e,this.api=t,n=this._dataProcessorHandlers=n.slice(),a=this._visualHandlers=a.slice(),this._allHandlers=n.concat(a)}return r.prototype.restoreData=function(e,t){e.restoreData(t),this._stageTaskMap.each(function(n){var a=n.overallTask;a&&a.dirty()})},r.prototype.getPerformArgs=function(e,t){if(!!e.__pipeline){var n=this._pipelineMap.get(e.__pipeline.id),a=n.context,i=!t&&n.progressiveEnabled&&(!a||a.progressiveRender)&&e.__idxInPipeline>n.blockIndex,o=i?n.step:null,s=a&&a.modDataCount,l=s!=null?Math.ceil(s/o):null;return{step:o,modBy:l,modDataCount:s}}},r.prototype.getPipeline=function(e){return this._pipelineMap.get(e)},r.prototype.updateStreamModes=function(e,t){var n=this._pipelineMap.get(e.uid),a=e.getData(),i=a.count(),o=n.progressiveEnabled&&t.incrementalPrepareRender&&i>=n.threshold,s=e.get("large")&&i>=e.get("largeThreshold"),l=e.get("progressiveChunkMode")==="mod"?i:null;e.pipelineContext=n.context={progressiveRender:o,modDataCount:l,large:s}},r.prototype.restorePipelines=function(e){var t=this,n=t._pipelineMap=ge();e.eachSeries(function(a){var i=a.getProgressive(),o=a.uid;n.set(o,{id:o,head:null,tail:null,threshold:a.getProgressiveThreshold(),progressiveEnabled:i&&!(a.preventIncremental&&a.preventIncremental()),blockIndex:-1,step:Math.round(i||700),count:0}),t._pipe(a,a.dataTask)})},r.prototype.prepareStageTasks=function(){var e=this._stageTaskMap,t=this.api.getModel(),n=this.api;C(this._allHandlers,function(a){var i=e.get(a.uid)||e.set(a.uid,{}),o="";Er(!(a.reset&&a.overallReset),o),a.reset&&this._createSeriesStageTask(a,i,t,n),a.overallReset&&this._createOverallStageTask(a,i,t,n)},this)},r.prototype.prepareView=function(e,t,n,a){var i=e.renderTask,o=i.context;o.model=t,o.ecModel=n,o.api=a,i.__block=!e.incrementalPrepareRender,this._pipe(t,i)},r.prototype.performDataProcessorTasks=function(e,t){this._performStageTasks(this._dataProcessorHandlers,e,t,{block:!0})},r.prototype.performVisualTasks=function(e,t,n){this._performStageTasks(this._visualHandlers,e,t,n)},r.prototype._performStageTasks=function(e,t,n,a){a=a||{};var i=!1,o=this;C(e,function(l,u){if(!(a.visualType&&a.visualType!==l.visualType)){var c=o._stageTaskMap.get(l.uid),f=c.seriesTaskMap,h=c.overallTask;if(h){var v,d=h.agentStubMap;d.each(function(g){s(a,g)&&(g.dirty(),v=!0)}),v&&h.dirty(),o.updatePayload(h,n);var p=o.getPerformArgs(h,a.block);d.each(function(g){g.perform(p)}),h.perform(p)&&(i=!0)}else f&&f.each(function(g,y){s(a,g)&&g.dirty();var m=o.getPerformArgs(g,a.block);m.skip=!l.performRawSeries&&t.isSeriesFiltered(g.context.model),o.updatePayload(g,n),g.perform(m)&&(i=!0)})}});function s(l,u){return l.setDirty&&(!l.dirtyMap||l.dirtyMap.get(u.__pipeline.id))}this.unfinished=i||this.unfinished},r.prototype.performSeriesTasks=function(e){var t;e.eachSeries(function(n){t=n.dataTask.perform()||t}),this.unfinished=t||this.unfinished},r.prototype.plan=function(){this._pipelineMap.each(function(e){var t=e.tail;do{if(t.__block){e.blockIndex=t.__idxInPipeline;break}t=t.getUpstream()}while(t)})},r.prototype.updatePayload=function(e,t){t!=="remain"&&(e.context.payload=t)},r.prototype._createSeriesStageTask=function(e,t,n,a){var i=this,o=t.seriesTaskMap,s=t.seriesTaskMap=ge(),l=e.seriesType,u=e.getTargetSeries;e.createOnAllSeries?n.eachRawSeries(c):l?n.eachRawSeriesByType(l,c):u&&u(n,a).each(c);function c(f){var h=f.uid,v=s.set(h,o&&o.get(h)||bf({plan:u9,reset:c9,count:h9}));v.context={model:f,ecModel:n,api:a,useClearVisual:e.isVisual&&!e.isLayout,plan:e.plan,reset:e.reset,scheduler:i},i._pipe(f,v)}},r.prototype._createOverallStageTask=function(e,t,n,a){var i=this,o=t.overallTask=t.overallTask||bf({reset:i9});o.context={ecModel:n,api:a,overallReset:e.overallReset,scheduler:i};var s=o.agentStubMap,l=o.agentStubMap=ge(),u=e.seriesType,c=e.getTargetSeries,f=!0,h=!1,v="";Er(!e.createOnAllSeries,v),u?n.eachRawSeriesByType(u,d):c?c(n,a).each(d):(f=!1,C(n.getSeries(),d));function d(p){var g=p.uid,y=l.set(g,s&&s.get(g)||(h=!0,bf({reset:o9,onDirty:l9})));y.context={model:p,overallProgress:f},y.agent=o,y.__block=f,i._pipe(p,y)}h&&o.dirty()},r.prototype._pipe=function(e,t){var n=e.uid,a=this._pipelineMap.get(n);!a.head&&(a.head=t),a.tail&&a.tail.pipe(t),a.tail=t,t.__idxInPipeline=a.count++,t.__pipeline=a},r.wrapStageHandler=function(e,t){return ye(e)&&(e={overallReset:e,seriesType:v9(e)}),e.uid=ru("stageHandler"),t&&(e.visualType=t),e},r}();function i9(r){r.overallReset(r.ecModel,r.api,r.payload)}function o9(r){return r.overallProgress&&s9}function s9(){this.agent.dirty(),this.getDownstream().dirty()}function l9(){this.agent&&this.agent.dirty()}function u9(r){return r.plan?r.plan(r.model,r.ecModel,r.api,r.payload):null}function c9(r){r.useClearVisual&&r.data.clearAllVisual();var e=r.resetDefines=ct(r.reset(r.model,r.ecModel,r.api,r.payload));return e.length>1?K(e,function(t,n){return AN(n)}):f9}var f9=AN(0);function AN(r){return function(e,t){var n=t.data,a=t.resetDefines[r];if(a&&a.dataEach)for(var i=e.start;i<e.end;i++)a.dataEach(n,i);else a&&a.progress&&a.progress(e,n)}}function h9(r){return r.data.count()}function v9(r){Jd=null;try{r(Df,CN)}catch{}return Jd}var Df={},CN={},Jd;NN(Df,AC),NN(CN,CC),Df.eachSeriesByType=Df.eachRawSeriesByType=function(r){Jd=r},Df.eachComponent=function(r){r.mainType==="series"&&r.subType&&(Jd=r.subType)};function NN(r,e){for(var t in e.prototype)r[t]=Ot}var LN=a9,EN=["#37A2DA","#32C5E9","#67E0E3","#9FE6B8","#FFDB5C","#ff9f7f","#fb7293","#E062AE","#E690D1","#e7bcf3","#9d96f5","#8378EA","#96BFFF"],d9={color:EN,colorLayer:[["#37A2DA","#ffd85c","#fd7b5f"],["#37A2DA","#67E0E3","#FFDB5C","#ff9f7f","#E062AE","#9d96f5"],["#37A2DA","#32C5E9","#9FE6B8","#FFDB5C","#ff9f7f","#fb7293","#e7bcf3","#8378EA","#96BFFF"],EN]},Jr="#B9B8CE",ON="#100C2A",Kd=function(){return{axisLine:{lineStyle:{color:Jr}},splitLine:{lineStyle:{color:"#484753"}},splitArea:{areaStyle:{color:["rgba(255,255,255,0.02)","rgba(255,255,255,0.05)"]}},minorSplitLine:{lineStyle:{color:"#20203B"}}}},PN=["#4992ff","#7cffb2","#fddd60","#ff6e76","#58d9f9","#05c091","#ff8a45","#8d48e3","#dd79ff"],zN={darkMode:!0,color:PN,backgroundColor:ON,axisPointer:{lineStyle:{color:"#817f91"},crossStyle:{color:"#817f91"},label:{color:"#fff"}},legend:{textStyle:{color:Jr}},textStyle:{color:Jr},title:{textStyle:{color:"#EEF1FA"},subtextStyle:{color:"#B9B8CE"}},toolbox:{iconStyle:{borderColor:Jr}},dataZoom:{borderColor:"#71708A",textStyle:{color:Jr},brushStyle:{color:"rgba(135,163,206,0.3)"},handleStyle:{color:"#353450",borderColor:"#C5CBE3"},moveHandleStyle:{color:"#B0B6C3",opacity:.3},fillerColor:"rgba(135,163,206,0.2)",emphasis:{handleStyle:{borderColor:"#91B7F2",color:"#4D587D"},moveHandleStyle:{color:"#636D9A",opacity:.7}},dataBackground:{lineStyle:{color:"#71708A",width:1},areaStyle:{color:"#71708A"}},selectedDataBackground:{lineStyle:{color:"#87A3CE"},areaStyle:{color:"#87A3CE"}}},visualMap:{textStyle:{color:Jr}},timeline:{lineStyle:{color:Jr},label:{color:Jr},controlStyle:{color:Jr,borderColor:Jr}},calendar:{itemStyle:{color:ON},dayLabel:{color:Jr},monthLabel:{color:Jr},yearLabel:{color:Jr}},timeAxis:Kd(),logAxis:Kd(),valueAxis:Kd(),categoryAxis:Kd(),line:{symbol:"circle"},graph:{color:PN},gauge:{title:{color:Jr},axisLine:{lineStyle:{color:[[1,"rgba(207,212,219,0.2)"]]}},axisLabel:{color:Jr},detail:{color:"#EEF1FA"}},candlestick:{itemStyle:{color:"#f64e56",color0:"#54ea92",borderColor:"#f64e56",borderColor0:"#54ea92"}}};zN.categoryAxis.splitLine.show=!1;var p9=zN,g9=function(){function r(){}return r.prototype.normalizeQuery=function(e){var t={},n={},a={};if(ce(e)){var i=ja(e);t.mainType=i.main||null,t.subType=i.sub||null}else{var o=["Index","Name","Id"],s={name:1,dataIndex:1,dataType:1};C(e,function(l,u){for(var c=!1,f=0;f<o.length;f++){var h=o[f],v=u.lastIndexOf(h);if(v>0&&v===u.length-h.length){var d=u.slice(0,v);d!=="data"&&(t.mainType=d,t[h.toLowerCase()]=l,c=!0)}}s.hasOwnProperty(u)&&(n[u]=l,c=!0),c||(a[u]=l)})}return{cptQuery:t,dataQuery:n,otherQuery:a}},r.prototype.filter=function(e,t){var n=this.eventInfo;if(!n)return!0;var a=n.targetEl,i=n.packedEvent,o=n.model,s=n.view;if(!o||!s)return!0;var l=t.cptQuery,u=t.dataQuery;return c(l,o,"mainType")&&c(l,o,"subType")&&c(l,o,"index","componentIndex")&&c(l,o,"name")&&c(l,o,"id")&&c(u,i,"name")&&c(u,i,"dataIndex")&&c(u,i,"dataType")&&(!s.filterForExposedEvent||s.filterForExposedEvent(e,t.otherQuery,a,i));function c(f,h,v,d){return f[v]==null||h[d||v]===f[v]}},r.prototype.afterTrigger=function(){this.eventInfo=null},r}(),n_=["symbol","symbolSize","symbolRotate","symbolOffset"],kN=n_.concat(["symbolKeepAspect"]),y9={createOnAllSeries:!0,performRawSeries:!0,reset:function(r,e){var t=r.getData();if(r.legendIcon&&t.setVisual("legendIcon",r.legendIcon),!r.hasSymbolVisual)return;for(var n={},a={},i=!1,o=0;o<n_.length;o++){var s=n_[o],l=r.get(s);ye(l)?(i=!0,a[s]=l):n[s]=l}if(n.symbol=n.symbol||r.defaultSymbol,t.setVisual(X({legendIcon:r.legendIcon||n.symbol,symbolKeepAspect:r.get("symbolKeepAspect")},n)),e.isSeriesFiltered(r))return;var u=Fe(a);function c(f,h){for(var v=r.getRawValue(h),d=r.getDataParams(h),p=0;p<u.length;p++){var g=u[p];f.setItemVisual(h,g,a[g](v,d))}}return{dataEach:i?c:null}}},m9={createOnAllSeries:!0,performRawSeries:!0,reset:function(r,e){if(!r.hasSymbolVisual||e.isSeriesFiltered(r))return;var t=r.getData();function n(a,i){for(var o=a.getItemModel(i),s=0;s<kN.length;s++){var l=kN[s],u=o.getShallow(l,!0);u!=null&&a.setItemVisual(i,l,u)}}return{dataEach:t.hasItemOption?n:null}}};function a_(r,e,t){switch(t){case"color":var n=r.getItemVisual(e,"style");return n[r.getVisual("drawType")];case"opacity":return r.getItemVisual(e,"style").opacity;case"symbol":case"symbolSize":case"liftZ":return r.getItemVisual(e,t)}}function Sf(r,e){switch(e){case"color":var t=r.getVisual("style");return t[r.getVisual("drawType")];case"opacity":return r.getVisual("style").opacity;case"symbol":case"symbolSize":case"liftZ":return r.getVisual(e)}}function RN(r,e,t,n){switch(t){case"color":var a=r.ensureUniqueItemVisual(e,"style");a[r.getVisual("drawType")]=n,r.setItemVisual(e,"colorFromPalette",!1);break;case"opacity":r.ensureUniqueItemVisual(e,"style").opacity=n;break;case"symbol":case"symbolSize":case"liftZ":r.setItemVisual(e,t,n);break}}function jN(r,e){function t(n,a){var i=[];return n.eachComponent({mainType:"series",subType:r,query:a},function(o){i.push(o.seriesIndex)}),i}C([[r+"ToggleSelect","toggleSelect"],[r+"Select","select"],[r+"UnSelect","unselect"]],function(n){e(n[0],function(a,i,o){a=X({},a),o.dispatchAction(X(a,{type:n[1],seriesIndex:t(i,a)}))})})}function du(r,e,t,n,a){var i=r+e;t.isSilent(i)||n.eachComponent({mainType:"series",subType:"pie"},function(o){for(var s=o.seriesIndex,l=o.option.selectedMap,u=a.selected,c=0;c<u.length;c++)if(u[c].seriesIndex===s){var f=o.getData(),h=as(f,a.fromActionPayload);t.trigger(i,{type:i,seriesId:o.id,name:J(h)?f.getName(h[0]):f.getName(h),selected:ce(l)?l:X({},l)})}})}function _9(r,e,t){r.on("selectchanged",function(n){var a=t.getModel();n.isFromClick?(du("map","selectchanged",e,a,n),du("pie","selectchanged",e,a,n)):n.fromAction==="select"?(du("map","selected",e,a,n),du("pie","selected",e,a,n)):n.fromAction==="unselect"&&(du("map","unselected",e,a,n),du("pie","unselected",e,a,n))})}function Cs(r,e,t){for(var n;r&&!(e(r)&&(n=r,t));)r=r.__hostTarget||r.parent;return n}var b9=Math.round(Math.random()*9),M9=typeof Object.defineProperty=="function",x9=function(){function r(){this._id="__ec_inner_"+b9++}return r.prototype.get=function(e){return this._guard(e)[this._id]},r.prototype.set=function(e,t){var n=this._guard(e);return M9?Object.defineProperty(n,this._id,{value:t,enumerable:!1,configurable:!0}):n[this._id]=t,this},r.prototype.delete=function(e){return this.has(e)?(delete this._guard(e)[this._id],!0):!1},r.prototype.has=function(e){return!!this._guard(e)[this._id]},r.prototype._guard=function(e){if(e!==Object(e))throw TypeError("Value of WeakMap is not a non-null object.");return e},r}(),w9=x9,D9=je.extend({type:"triangle",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(r,e){var t=e.cx,n=e.cy,a=e.width/2,i=e.height/2;r.moveTo(t,n-i),r.lineTo(t+a,n+i),r.lineTo(t-a,n+i),r.closePath()}}),S9=je.extend({type:"diamond",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(r,e){var t=e.cx,n=e.cy,a=e.width/2,i=e.height/2;r.moveTo(t,n-i),r.lineTo(t+a,n),r.lineTo(t,n+i),r.lineTo(t-a,n),r.closePath()}}),I9=je.extend({type:"pin",shape:{x:0,y:0,width:0,height:0},buildPath:function(r,e){var t=e.x,n=e.y,a=e.width/5*3,i=Math.max(a,e.height),o=a/2,s=o*o/(i-o),l=n-i+o+s,u=Math.asin(s/o),c=Math.cos(u)*o,f=Math.sin(u),h=Math.cos(u),v=o*.6,d=o*.7;r.moveTo(t-c,l+s),r.arc(t,l,o,Math.PI-u,Math.PI*2+u),r.bezierCurveTo(t+c-f*v,l+s+h*v,t,n-d,t,n),r.bezierCurveTo(t,n-d,t-c+f*v,l+s+h*v,t-c,l+s),r.closePath()}}),T9=je.extend({type:"arrow",shape:{x:0,y:0,width:0,height:0},buildPath:function(r,e){var t=e.height,n=e.width,a=e.x,i=e.y,o=n/3*2;r.moveTo(a,i),r.lineTo(a+o,i+t),r.lineTo(a,i+t/4*3),r.lineTo(a-o,i+t),r.lineTo(a,i),r.closePath()}}),A9={line:or,rect:We,roundRect:We,square:We,circle:pa,diamond:S9,pin:I9,arrow:T9,triangle:D9},C9={line:function(r,e,t,n,a){a.x1=r,a.y1=e+n/2,a.x2=r+t,a.y2=e+n/2},rect:function(r,e,t,n,a){a.x=r,a.y=e,a.width=t,a.height=n},roundRect:function(r,e,t,n,a){a.x=r,a.y=e,a.width=t,a.height=n,a.r=Math.min(t,n)/4},square:function(r,e,t,n,a){var i=Math.min(t,n);a.x=r,a.y=e,a.width=i,a.height=i},circle:function(r,e,t,n,a){a.cx=r+t/2,a.cy=e+n/2,a.r=Math.min(t,n)/2},diamond:function(r,e,t,n,a){a.cx=r+t/2,a.cy=e+n/2,a.width=t,a.height=n},pin:function(r,e,t,n,a){a.x=r+t/2,a.y=e+n/2,a.width=t,a.height=n},arrow:function(r,e,t,n,a){a.x=r+t/2,a.y=e+n/2,a.width=t,a.height=n},triangle:function(r,e,t,n,a){a.cx=r+t/2,a.cy=e+n/2,a.width=t,a.height=n}},ep={};C(A9,function(r,e){ep[e]=new r});var N9=je.extend({type:"symbol",shape:{symbolType:"",x:0,y:0,width:0,height:0},calculateTextPosition:function(r,e,t){var n=Kv(r,e,t),a=this.shape;return a&&a.symbolType==="pin"&&e.position==="inside"&&(n.y=t.y+t.height*.4),n},buildPath:function(r,e,t){var n=e.symbolType;if(n!=="none"){var a=ep[n];a||(n="rect",a=ep[n]),C9[n](e.x,e.y,e.width,e.height,a.shape),a.buildPath(r,a.shape,t)}}});function L9(r,e){if(this.type!=="image"){var t=this.style;this.__isEmptyBrush?(t.stroke=r,t.fill=e||"#fff",t.lineWidth=2):this.shape.symbolType==="line"?t.stroke=r:t.fill=r,this.markRedraw()}}function Ft(r,e,t,n,a,i,o){var s=r.indexOf("empty")===0;s&&(r=r.substr(5,1).toLowerCase()+r.substr(6));var l;return r.indexOf("image://")===0?l=v1(r.slice(8),new Pe(e,t,n,a),o?"center":"cover"):r.indexOf("path://")===0?l=of(r.slice(7),{},new Pe(e,t,n,a),o?"center":"cover"):l=new N9({shape:{symbolType:r,x:e,y:t,width:n,height:a}}),l.__isEmptyBrush=s,l.setColor=L9,i&&l.setColor(i),l}function If(r){return J(r)||(r=[+r,+r]),[r[0]||0,r[1]||0]}function pu(r,e){if(r!=null)return J(r)||(r=[r,r]),[ue(r[0],e[0])||0,ue(Ee(r[1],r[0]),e[1])||0]}function Ns(r){return isFinite(r)}function E9(r,e,t){var n=e.x==null?0:e.x,a=e.x2==null?1:e.x2,i=e.y==null?0:e.y,o=e.y2==null?0:e.y2;e.global||(n=n*t.width+t.x,a=a*t.width+t.x,i=i*t.height+t.y,o=o*t.height+t.y),n=Ns(n)?n:0,a=Ns(a)?a:1,i=Ns(i)?i:0,o=Ns(o)?o:0;var s=r.createLinearGradient(n,i,a,o);return s}function O9(r,e,t){var n=t.width,a=t.height,i=Math.min(n,a),o=e.x==null?.5:e.x,s=e.y==null?.5:e.y,l=e.r==null?.5:e.r;e.global||(o=o*n+t.x,s=s*a+t.y,l=l*i),o=Ns(o)?o:.5,s=Ns(s)?s:.5,l=l>=0&&Ns(l)?l:.5;var u=r.createRadialGradient(o,s,0,o,s,l);return u}function i_(r,e,t){for(var n=e.type==="radial"?O9(r,e,t):E9(r,e,t),a=e.colorStops,i=0;i<a.length;i++)n.addColorStop(a[i].offset,a[i].color);return n}function P9(r,e){if(r===e||!r&&!e)return!1;if(!r||!e||r.length!==e.length)return!0;for(var t=0;t<r.length;t++)if(r[t]!==e[t])return!0;return!1}function tp(r){return parseInt(r,10)}function gu(r,e,t){var n=["width","height"][e],a=["clientWidth","clientHeight"][e],i=["paddingLeft","paddingTop"][e],o=["paddingRight","paddingBottom"][e];if(t[n]!=null&&t[n]!=="auto")return parseFloat(t[n]);var s=document.defaultView.getComputedStyle(r);return(r[a]||tp(s[n])||tp(r.style[n]))-(tp(s[i])||0)-(tp(s[o])||0)|0}function z9(r,e){return!r||r==="solid"||!(e>0)?null:r==="dashed"?[4*e,2*e]:r==="dotted"?[e]:Ue(r)?[r]:J(r)?r:null}function o_(r){var e=r.style,t=e.lineDash&&e.lineWidth>0&&z9(e.lineDash,e.lineWidth),n=e.lineDashOffset;if(t){var a=e.strokeNoScale&&r.getLineScale?r.getLineScale():1;a&&a!==1&&(t=K(t,function(i){return i/a}),n/=a)}return[t,n]}var k9=new Ha(!0);function rp(r){var e=r.stroke;return!(e==null||e==="none"||!(r.lineWidth>0))}function BN(r){return typeof r=="string"&&r!=="none"}function np(r){var e=r.fill;return e!=null&&e!=="none"}function FN(r,e){if(e.fillOpacity!=null&&e.fillOpacity!==1){var t=r.globalAlpha;r.globalAlpha=e.fillOpacity*e.opacity,r.fill(),r.globalAlpha=t}else r.fill()}function VN(r,e){if(e.strokeOpacity!=null&&e.strokeOpacity!==1){var t=r.globalAlpha;r.globalAlpha=e.strokeOpacity*e.opacity,r.stroke(),r.globalAlpha=t}else r.stroke()}function s_(r,e,t){var n=P0(e.image,e.__image,t);if(ad(n)){var a=r.createPattern(n,e.repeat||"repeat");if(typeof DOMMatrix=="function"&&a&&a.setTransform){var i=new DOMMatrix;i.translateSelf(e.x||0,e.y||0),i.rotateSelf(0,0,(e.rotation||0)*mc),i.scaleSelf(e.scaleX||1,e.scaleY||1),a.setTransform(i)}return a}}function R9(r,e,t,n){var a,i=rp(t),o=np(t),s=t.strokePercent,l=s<1,u=!e.path;(!e.silent||l)&&u&&e.createPathProxy();var c=e.path||k9,f=e.__dirty;if(!n){var h=t.fill,v=t.stroke,d=o&&!!h.colorStops,p=i&&!!v.colorStops,g=o&&!!h.image,y=i&&!!v.image,m=void 0,_=void 0,b=void 0,x=void 0,M=void 0;(d||p)&&(M=e.getBoundingRect()),d&&(m=f?i_(r,h,M):e.__canvasFillGradient,e.__canvasFillGradient=m),p&&(_=f?i_(r,v,M):e.__canvasStrokeGradient,e.__canvasStrokeGradient=_),g&&(b=f||!e.__canvasFillPattern?s_(r,h,e):e.__canvasFillPattern,e.__canvasFillPattern=b),y&&(x=f||!e.__canvasStrokePattern?s_(r,v,e):e.__canvasStrokePattern,e.__canvasStrokePattern=b),d?r.fillStyle=m:g&&(b?r.fillStyle=b:o=!1),p?r.strokeStyle=_:y&&(x?r.strokeStyle=x:i=!1)}var w=e.getGlobalScale();c.setScale(w[0],w[1],e.segmentIgnoreThreshold);var D,T;r.setLineDash&&t.lineDash&&(a=o_(e),D=a[0],T=a[1]);var I=!0;(u||f&zl)&&(c.setDPR(r.dpr),l?c.setContext(null):(c.setContext(r),I=!1),c.reset(),e.buildPath(c,e.shape,n),c.toStatic(),e.pathUpdated()),I&&c.rebuildPath(r,l?s:1),D&&(r.setLineDash(D),r.lineDashOffset=T),n||(t.strokeFirst?(i&&VN(r,t),o&&FN(r,t)):(o&&FN(r,t),i&&VN(r,t))),D&&r.setLineDash([])}function j9(r,e,t){var n=e.__image=P0(t.image,e.__image,e,e.onload);if(!(!n||!ad(n))){var a=t.x||0,i=t.y||0,o=e.getWidth(),s=e.getHeight(),l=n.width/n.height;if(o==null&&s!=null?o=s*l:s==null&&o!=null?s=o/l:o==null&&s==null&&(o=n.width,s=n.height),t.sWidth&&t.sHeight){var u=t.sx||0,c=t.sy||0;r.drawImage(n,u,c,t.sWidth,t.sHeight,a,i,o,s)}else if(t.sx&&t.sy){var u=t.sx,c=t.sy,f=o-u,h=s-c;r.drawImage(n,u,c,f,h,a,i,o,s)}else r.drawImage(n,a,i,o,s)}}function B9(r,e,t){var n,a=t.text;if(a!=null&&(a+=""),a){r.font=t.font||$i,r.textAlign=t.textAlign,r.textBaseline=t.textBaseline;var i=void 0,o=void 0;r.setLineDash&&t.lineDash&&(n=o_(e),i=n[0],o=n[1]),i&&(r.setLineDash(i),r.lineDashOffset=o),t.strokeFirst?(rp(t)&&r.strokeText(a,t.x,t.y),np(t)&&r.fillText(a,t.x,t.y)):(np(t)&&r.fillText(a,t.x,t.y),rp(t)&&r.strokeText(a,t.x,t.y)),i&&r.setLineDash([])}}var HN=["shadowBlur","shadowOffsetX","shadowOffsetY"],WN=[["lineCap","butt"],["lineJoin","miter"],["miterLimit",10]];function GN(r,e,t,n,a){var i=!1;if(!n&&(t=t||{},e===t))return!1;if(n||e.opacity!==t.opacity){cn(r,a),i=!0;var o=Math.max(Math.min(e.opacity,1),0);r.globalAlpha=isNaN(o)?ss.opacity:o}(n||e.blend!==t.blend)&&(i||(cn(r,a),i=!0),r.globalCompositeOperation=e.blend||ss.blend);for(var s=0;s<HN.length;s++){var l=HN[s];(n||e[l]!==t[l])&&(i||(cn(r,a),i=!0),r[l]=r.dpr*(e[l]||0))}return(n||e.shadowColor!==t.shadowColor)&&(i||(cn(r,a),i=!0),r.shadowColor=e.shadowColor||ss.shadowColor),i}function $N(r,e,t,n,a){var i=Tf(e,a.inHover),o=n?null:t&&Tf(t,a.inHover)||{};if(i===o)return!1;var s=GN(r,i,o,n,a);if((n||i.fill!==o.fill)&&(s||(cn(r,a),s=!0),BN(i.fill)&&(r.fillStyle=i.fill)),(n||i.stroke!==o.stroke)&&(s||(cn(r,a),s=!0),BN(i.stroke)&&(r.strokeStyle=i.stroke)),(n||i.opacity!==o.opacity)&&(s||(cn(r,a),s=!0),r.globalAlpha=i.opacity==null?1:i.opacity),e.hasStroke()){var l=i.lineWidth,u=l/(i.strokeNoScale&&e.getLineScale?e.getLineScale():1);r.lineWidth!==u&&(s||(cn(r,a),s=!0),r.lineWidth=u)}for(var c=0;c<WN.length;c++){var f=WN[c],h=f[0];(n||i[h]!==o[h])&&(s||(cn(r,a),s=!0),r[h]=i[h]||f[1])}return s}function F9(r,e,t,n,a){return GN(r,Tf(e,a.inHover),t&&Tf(t,a.inHover),n,a)}function UN(r,e){var t=e.transform,n=r.dpr||1;t?r.setTransform(n*t[0],n*t[1],n*t[2],n*t[3],n*t[4],n*t[5]):r.setTransform(n,0,0,n,0,0)}function V9(r,e,t){for(var n=!1,a=0;a<r.length;a++){var i=r[a];n=n||i.isZeroArea(),UN(e,i),e.beginPath(),i.buildPath(e,i.shape),e.clip()}t.allClipped=n}function H9(r,e){return r&&e?r[0]!==e[0]||r[1]!==e[1]||r[2]!==e[2]||r[3]!==e[3]||r[4]!==e[4]||r[5]!==e[5]:!(!r&&!e)}var YN=1,QN=2,ZN=3,qN=4;function W9(r){var e=np(r),t=rp(r);return!(r.lineDash||!(+e^+t)||e&&typeof r.fill!="string"||t&&typeof r.stroke!="string"||r.strokePercent<1||r.strokeOpacity<1||r.fillOpacity<1)}function cn(r,e){e.batchFill&&r.fill(),e.batchStroke&&r.stroke(),e.batchFill="",e.batchStroke=""}function Tf(r,e){return e&&r.__hoverStyle||r.style}function l_(r,e){Ls(r,e,{inHover:!1,viewWidth:0,viewHeight:0},!0)}function Ls(r,e,t,n){var a=e.transform;if(!e.shouldBePainted(t.viewWidth,t.viewHeight,!1,!1)){e.__dirty&=~mn,e.__isRendered=!1;return}var i=e.__clipPaths,o=t.prevElClipPaths,s=!1,l=!1;if((!o||P9(i,o))&&(o&&o.length&&(cn(r,t),r.restore(),l=s=!0,t.prevElClipPaths=null,t.allClipped=!1,t.prevEl=null),i&&i.length&&(cn(r,t),r.save(),V9(i,r,t),s=!0),t.prevElClipPaths=i),t.allClipped){e.__isRendered=!1;return}e.beforeBrush&&e.beforeBrush(),e.innerBeforeBrush();var u=t.prevEl;u||(l=s=!0);var c=e instanceof je&&e.autoBatch&&W9(e.style);s||H9(a,u.transform)?(cn(r,t),UN(r,e)):c||cn(r,t);var f=Tf(e,t.inHover);e instanceof je?(t.lastDrawType!==YN&&(l=!0,t.lastDrawType=YN),$N(r,e,u,l,t),(!c||!t.batchFill&&!t.batchStroke)&&r.beginPath(),R9(r,e,f,c),c&&(t.batchFill=f.fill||"",t.batchStroke=f.stroke||"")):e instanceof Yc?(t.lastDrawType!==ZN&&(l=!0,t.lastDrawType=ZN),$N(r,e,u,l,t),B9(r,e,f)):e instanceof pr?(t.lastDrawType!==QN&&(l=!0,t.lastDrawType=QN),F9(r,e,u,l,t),j9(r,e,f)):e.getTemporalDisplayables&&(t.lastDrawType!==qN&&(l=!0,t.lastDrawType=qN),G9(r,e,t)),c&&n&&cn(r,t),e.innerAfterBrush(),e.afterBrush&&e.afterBrush(),t.prevEl=e,e.__dirty=0,e.__isRendered=!0}function G9(r,e,t){var n=e.getDisplayables(),a=e.getTemporalDisplayables();r.save();var i={prevElClipPaths:null,prevEl:null,allClipped:!1,viewWidth:t.viewWidth,viewHeight:t.viewHeight,inHover:t.inHover},o,s;for(o=e.getCursor(),s=n.length;o<s;o++){var l=n[o];l.beforeBrush&&l.beforeBrush(),l.innerBeforeBrush(),Ls(r,l,i,o===s-1),l.innerAfterBrush(),l.afterBrush&&l.afterBrush(),i.prevEl=l}for(var u=0,c=a.length;u<c;u++){var l=a[u];l.beforeBrush&&l.beforeBrush(),l.innerBeforeBrush(),Ls(r,l,i,u===c-1),l.innerAfterBrush(),l.afterBrush&&l.afterBrush(),i.prevEl=l}e.clearTemporalDisplayables(),e.notClear=!0,r.restore()}var u_=new w9,XN=new Cc(100),JN=["symbol","symbolSize","symbolKeepAspect","color","backgroundColor","dashArrayX","dashArrayY","maxTileWidth","maxTileHeight"];function yu(r,e){if(r==="none")return null;var t=e.getDevicePixelRatio(),n=e.getZr(),a=n.painter.type==="svg";r.dirty&&u_.delete(r);var i=u_.get(r);if(i)return i;var o=me(r,{symbol:"rect",symbolSize:1,symbolKeepAspect:!0,color:"rgba(0, 0, 0, 0.2)",backgroundColor:null,dashArrayX:5,dashArrayY:5,rotation:0,maxTileWidth:512,maxTileHeight:512});o.backgroundColor==="none"&&(o.backgroundColor=null);var s={repeat:"repeat"};return l(s),s.rotation=o.rotation,s.scaleX=s.scaleY=a?1:1/t,u_.set(r,s),r.dirty=!1,s;function l(u){for(var c=[t],f=!0,h=0;h<JN.length;++h){var v=o[JN[h]];if(v!=null&&!J(v)&&!ce(v)&&!Ue(v)&&typeof v!="boolean"){f=!1;break}c.push(v)}var d;if(f){d=c.join(",")+(a?"-svg":"");var p=XN.get(d);p&&(a?u.svgElement=p:u.image=p)}var g=eL(o.dashArrayX),y=$9(o.dashArrayY),m=KN(o.symbol),_=U9(g),b=tL(y),x=!a&&la.createCanvas(),M=a&&{tag:"g",attrs:{},key:"dcl",children:[]},w=T(),D;x&&(x.width=w.width*t,x.height=w.height*t,D=x.getContext("2d")),I(),f&&XN.put(d,x||M),u.image=x,u.svgElement=M,u.svgWidth=w.width,u.svgHeight=w.height;function T(){for(var A=1,N=0,L=_.length;N<L;++N)A=eT(A,_[N]);for(var E=1,N=0,L=m.length;N<L;++N)E=eT(E,m[N].length);A*=E;var O=b*_.length*m.length;return{width:Math.max(1,Math.min(A,o.maxTileWidth)),height:Math.max(1,Math.min(O,o.maxTileHeight))}}function I(){D&&(D.clearRect(0,0,x.width,x.height),o.backgroundColor&&(D.fillStyle=o.backgroundColor,D.fillRect(0,0,x.width,x.height)));for(var A=0,N=0;N<y.length;++N)A+=y[N];if(A<=0)return;for(var L=-b,E=0,O=0,P=0;L<w.height;){if(E%2===0){for(var H=O/2%m.length,F=0,G=0,Z=0;F<w.width*2;){for(var te=0,N=0;N<g[P].length;++N)te+=g[P][N];if(te<=0)break;if(G%2===0){var V=(1-o.symbolSize)*.5,Y=F+g[P][G]*V,q=L+y[E]*V,Q=g[P][G]*o.symbolSize,ne=y[E]*o.symbolSize,oe=Z/2%m[H].length;ie(Y,q,Q,ne,m[H][oe])}F+=g[P][G],++Z,++G,G===g[P].length&&(G=0)}++P,P===g.length&&(P=0)}L+=y[E],++O,++E,E===y.length&&(E=0)}function ie(he,k,j,W,ae){var re=a?1:t,ee=Ft(ae,he*re,k*re,j*re,W*re,o.color,o.symbolKeepAspect);if(a){var se=n.painter.renderOneToVNode(ee);se&&M.children.push(se)}else l_(D,ee)}}}}function KN(r){if(!r||r.length===0)return[["rect"]];if(ce(r))return[[r]];for(var e=!0,t=0;t<r.length;++t)if(!ce(r[t])){e=!1;break}if(e)return KN([r]);for(var n=[],t=0;t<r.length;++t)ce(r[t])?n.push([r[t]]):n.push(r[t]);return n}function eL(r){if(!r||r.length===0)return[[0,0]];if(Ue(r)){var e=Math.ceil(r);return[[e,e]]}for(var t=!0,n=0;n<r.length;++n)if(!Ue(r[n])){t=!1;break}if(t)return eL([r]);for(var a=[],n=0;n<r.length;++n)if(Ue(r[n])){var e=Math.ceil(r[n]);a.push([e,e])}else{var e=K(r[n],function(s){return Math.ceil(s)});e.length%2===1?a.push(e.concat(e)):a.push(e)}return a}function $9(r){if(!r||typeof r=="object"&&r.length===0)return[0,0];if(Ue(r)){var e=Math.ceil(r);return[e,e]}var t=K(r,function(n){return Math.ceil(n)});return r.length%2?t.concat(t):t}function U9(r){return K(r,function(e){return tL(e)})}function tL(r){for(var e=0,t=0;t<r.length;++t)e+=r[t];return r.length%2===1?e*2:e}function Y9(r,e){r.eachRawSeries(function(t){if(!r.isSeriesFiltered(t)){var n=t.getData();n.hasItemVisual()&&n.each(function(o){var s=n.getItemVisual(o,"decal");if(s){var l=n.ensureUniqueItemVisual(o,"style");l.decal=yu(s,e)}});var a=n.getVisual("decal");if(a){var i=n.getVisual("style");i.decal=yu(a,e)}}})}var Q9=new zn,ba=Q9,rL={};function Z9(r,e){rL[r]=e}function nL(r){return rL[r]}var q9="5.4.1",X9={zrender:"5.4.1"},J9=1,K9=800,eY=900,tY=1e3,rY=2e3,nY=5e3,aL=1e3,aY=1100,c_=2e3,iL=3e3,iY=4e3,ap=4500,oY=4600,sY=5e3,lY=6e3,oL=7e3,sL={PROCESSOR:{FILTER:tY,SERIES_FILTER:K9,STATISTIC:nY},VISUAL:{LAYOUT:aL,PROGRESSIVE_LAYOUT:aY,GLOBAL:c_,CHART:iL,POST_CHART_LAYOUT:oY,COMPONENT:iY,BRUSH:sY,CHART_ITEM:ap,ARIA:lY,DECAL:oL}},Rr="__flagInMainProcess",fn="__pendingUpdate",f_="__needsUpdateStatus",lL=/^[a-zA-Z0-9_]+$/,h_="__connectUpdateStatus",uL=0,uY=1,cY=2;function cL(r){return function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];if(this.isDisposed()){this.id;return}return hL(this,r,e)}}function fL(r){return function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return hL(this,r,e)}}function hL(r,e,t){return t[0]=t[0]&&t[0].toLowerCase(),zn.prototype[e].apply(r,t)}var vL=function(r){U(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e}(zn),dL=vL.prototype;dL.on=fL("on"),dL.off=fL("off");var mu,v_,ip,go,d_,p_,g_,Af,Cf,pL,gL,y_,yL,op,mL,_L,Un,bL,sp=function(r){U(e,r);function e(t,n,a){var i=r.call(this,new g9)||this;i._chartsViews=[],i._chartsMap={},i._componentsViews=[],i._componentsMap={},i._pendingActions=[],a=a||{},ce(n)&&(n=ML[n]),i._dom=t;var o="canvas",s="auto",l=!1,u=i._zr=x0(t,{renderer:a.renderer||o,devicePixelRatio:a.devicePixelRatio,width:a.width,height:a.height,ssr:a.ssr,useDirtyRect:Ee(a.useDirtyRect,l),useCoarsePointer:Ee(a.useCoarsePointer,s),pointerSize:a.pointerSize});i._ssr=a.ssr,i._throttledZrFlush=qd(fe(u.flush,u),17),n=Me(n),n&&kC(n,!0),i._theme=n,i._locale=b$(a.locale||XA),i._coordSysMgr=new uu;var c=i._api=mL(i);function f(h,v){return h.__prio-v.__prio}return Pv(up,f),Pv(__,f),i._scheduler=new LN(i,c,__,up),i._messageCenter=new vL,i._initEvents(),i.resize=fe(i.resize,i),u.animation.on("frame",i._onframe,i),pL(u,i),gL(u,i),pc(i),i}return e.prototype._onframe=function(){if(!this._disposed){bL(this);var t=this._scheduler;if(this[fn]){var n=this[fn].silent;this[Rr]=!0;try{mu(this),go.update.call(this,null,this[fn].updateParams)}catch(l){throw this[Rr]=!1,this[fn]=null,l}this._zr.flush(),this[Rr]=!1,this[fn]=null,Af.call(this,n),Cf.call(this,n)}else if(t.unfinished){var a=J9,i=this._model,o=this._api;t.unfinished=!1;do{var s=+new Date;t.performSeriesTasks(i),t.performDataProcessorTasks(i),p_(this,i),t.performVisualTasks(i),op(this,this._model,o,"remain",{}),a-=+new Date-s}while(a>0&&t.unfinished);t.unfinished||this._zr.flush()}}},e.prototype.getDom=function(){return this._dom},e.prototype.getId=function(){return this.id},e.prototype.getZr=function(){return this._zr},e.prototype.isSSR=function(){return this._ssr},e.prototype.setOption=function(t,n,a){if(!this[Rr]){if(this._disposed){this.id;return}var i,o,s;if(_e(n)&&(a=n.lazyUpdate,i=n.silent,o=n.replaceMerge,s=n.transition,n=n.notMerge),this[Rr]=!0,!this._model||n){var l=new eU(this._api),u=this._theme,c=this._model=new AC;c.scheduler=this._scheduler,c.ssr=this._ssr,c.init(null,null,null,u,this._locale,l)}this._model.setOption(t,{replaceMerge:o},b_);var f={seriesTransition:s,optionChanged:!0};if(a)this[fn]={silent:i,updateParams:f},this[Rr]=!1,this.getZr().wakeUp();else{try{mu(this),go.update.call(this,null,f)}catch(h){throw this[fn]=null,this[Rr]=!1,h}this._ssr||this._zr.flush(),this[fn]=null,this[Rr]=!1,Af.call(this,i),Cf.call(this,i)}}},e.prototype.setTheme=function(){},e.prototype.getModel=function(){return this._model},e.prototype.getOption=function(){return this._model&&this._model.getOption()},e.prototype.getWidth=function(){return this._zr.getWidth()},e.prototype.getHeight=function(){return this._zr.getHeight()},e.prototype.getDevicePixelRatio=function(){return this._zr.painter.dpr||$e.hasGlobalWindow&&window.devicePixelRatio||1},e.prototype.getRenderedCanvas=function(t){return this.renderToCanvas(t)},e.prototype.renderToCanvas=function(t){t=t||{};var n=this._zr.painter;return n.getRenderedCanvas({backgroundColor:t.backgroundColor||this._model.get("backgroundColor"),pixelRatio:t.pixelRatio||this.getDevicePixelRatio()})},e.prototype.renderToSVGString=function(t){t=t||{};var n=this._zr.painter;return n.renderToString({useViewBox:t.useViewBox})},e.prototype.getSvgDataURL=function(){if(!!$e.svgSupported){var t=this._zr,n=t.storage.getDisplayList();return C(n,function(a){a.stopAnimation(null,!0)}),t.painter.toDataURL()}},e.prototype.getDataURL=function(t){if(this._disposed){this.id;return}t=t||{};var n=t.excludeComponents,a=this._model,i=[],o=this;C(n,function(l){a.eachComponent({mainType:l},function(u){var c=o._componentsMap[u.__viewId];c.group.ignore||(i.push(c),c.group.ignore=!0)})});var s=this._zr.painter.getType()==="svg"?this.getSvgDataURL():this.renderToCanvas(t).toDataURL("image/"+(t&&t.type||"png"));return C(i,function(l){l.group.ignore=!1}),s},e.prototype.getConnectedDataURL=function(t){if(this._disposed){this.id;return}var n=t.type==="svg",a=this.group,i=Math.min,o=Math.max,s=1/0;if(cp[a]){var l=s,u=s,c=-s,f=-s,h=[],v=t&&t.pixelRatio||this.getDevicePixelRatio();C(Es,function(_,b){if(_.group===a){var x=n?_.getZr().painter.getSvgDom().innerHTML:_.renderToCanvas(Me(t)),M=_.getDom().getBoundingClientRect();l=i(M.left,l),u=i(M.top,u),c=o(M.right,c),f=o(M.bottom,f),h.push({dom:x,left:M.left,top:M.top})}}),l*=v,u*=v,c*=v,f*=v;var d=c-l,p=f-u,g=la.createCanvas(),y=x0(g,{renderer:n?"svg":"canvas"});if(y.resize({width:d,height:p}),n){var m="";return C(h,function(_){var b=_.left-l,x=_.top-u;m+='<g transform="translate('+b+","+x+')">'+_.dom+"</g>"}),y.painter.getSvgRoot().innerHTML=m,t.connectedBackgroundColor&&y.painter.setBackgroundColor(t.connectedBackgroundColor),y.refreshImmediately(),y.painter.toDataURL()}else return t.connectedBackgroundColor&&y.add(new We({shape:{x:0,y:0,width:d,height:p},style:{fill:t.connectedBackgroundColor}})),C(h,function(_){var b=new pr({style:{x:_.left*v-l,y:_.top*v-u,image:_.dom}});y.add(b)}),y.refreshImmediately(),g.toDataURL("image/"+(t&&t.type||"png"))}else return this.getDataURL(t)},e.prototype.convertToPixel=function(t,n){return d_(this,"convertToPixel",t,n)},e.prototype.convertFromPixel=function(t,n){return d_(this,"convertFromPixel",t,n)},e.prototype.containPixel=function(t,n){if(this._disposed){this.id;return}var a=this._model,i,o=Wc(a,t);return C(o,function(s,l){l.indexOf("Models")>=0&&C(s,function(u){var c=u.coordinateSystem;if(c&&c.containPoint)i=i||!!c.containPoint(n);else if(l==="seriesModels"){var f=this._chartsMap[u.__viewId];f&&f.containPoint&&(i=i||f.containPoint(n,u))}},this)},this),!!i},e.prototype.getVisual=function(t,n){var a=this._model,i=Wc(a,t,{defaultMainType:"series"}),o=i.seriesModel,s=o.getData(),l=i.hasOwnProperty("dataIndexInside")?i.dataIndexInside:i.hasOwnProperty("dataIndex")?s.indexOfRawIndex(i.dataIndex):null;return l!=null?a_(s,l,n):Sf(s,n)},e.prototype.getViewOfComponentModel=function(t){return this._componentsMap[t.__viewId]},e.prototype.getViewOfSeriesModel=function(t){return this._chartsMap[t.__viewId]},e.prototype._initEvents=function(){var t=this;C(fY,function(n){var a=function(i){var o=t.getModel(),s=i.target,l,u=n==="globalout";if(u?l={}:s&&Cs(s,function(d){var p=Te(d);if(p&&p.dataIndex!=null){var g=p.dataModel||o.getSeriesByIndex(p.seriesIndex);return l=g&&g.getDataParams(p.dataIndex,p.dataType)||{},!0}else if(p.eventData)return l=X({},p.eventData),!0},!0),l){var c=l.componentType,f=l.componentIndex;(c==="markLine"||c==="markPoint"||c==="markArea")&&(c="series",f=l.seriesIndex);var h=c&&f!=null&&o.getComponent(c,f),v=h&&t[h.mainType==="series"?"_chartsMap":"_componentsMap"][h.__viewId];l.event=i,l.type=n,t._$eventProcessor.eventInfo={targetEl:s,packedEvent:l,model:h,view:v},t.trigger(n,l)}};a.zrEventfulCallAtLast=!0,t._zr.on(n,a,t)}),C(Nf,function(n,a){t._messageCenter.on(a,function(i){this.trigger(a,i)},t)}),C(["selectchanged"],function(n){t._messageCenter.on(n,function(a){this.trigger(n,a)},t)}),_9(this._messageCenter,this,this._api)},e.prototype.isDisposed=function(){return this._disposed},e.prototype.clear=function(){if(this._disposed){this.id;return}this.setOption({series:[]},!0)},e.prototype.dispose=function(){if(this._disposed){this.id;return}this._disposed=!0;var t=this.getDom();t&&lT(this.getDom(),x_,"");var n=this,a=n._api,i=n._model;C(n._componentsViews,function(o){o.dispose(i,a)}),C(n._chartsViews,function(o){o.dispose(i,a)}),n._zr.dispose(),n._dom=n._model=n._chartsMap=n._componentsMap=n._chartsViews=n._componentsViews=n._scheduler=n._api=n._zr=n._throttledZrFlush=n._theme=n._coordSysMgr=n._messageCenter=null,delete Es[n.id]},e.prototype.resize=function(t){if(!this[Rr]){if(this._disposed){this.id;return}this._zr.resize(t);var n=this._model;if(this._loadingFX&&this._loadingFX.resize(),!!n){var a=n.resetOption("media"),i=t&&t.silent;this[fn]&&(i==null&&(i=this[fn].silent),a=!0,this[fn]=null),this[Rr]=!0;try{a&&mu(this),go.update.call(this,{type:"resize",animation:X({duration:0},t&&t.animation)})}catch(o){throw this[Rr]=!1,o}this[Rr]=!1,Af.call(this,i),Cf.call(this,i)}}},e.prototype.showLoading=function(t,n){if(this._disposed){this.id;return}if(_e(t)&&(n=t,t=""),t=t||"default",this.hideLoading(),!!M_[t]){var a=M_[t](this._api,n),i=this._zr;this._loadingFX=a,i.add(a)}},e.prototype.hideLoading=function(){if(this._disposed){this.id;return}this._loadingFX&&this._zr.remove(this._loadingFX),this._loadingFX=null},e.prototype.makeActionFromEvent=function(t){var n=X({},t);return n.type=Nf[t.type],n},e.prototype.dispatchAction=function(t,n){if(this._disposed){this.id;return}if(_e(n)||(n={silent:!!n}),!!lp[t.type]&&!!this._model){if(this[Rr]){this._pendingActions.push(t);return}var a=n.silent;g_.call(this,t,a);var i=n.flush;i?this._zr.flush():i!==!1&&$e.browser.weChat&&this._throttledZrFlush(),Af.call(this,a),Cf.call(this,a)}},e.prototype.updateLabelLayout=function(){ba.trigger("series:layoutlabels",this._model,this._api,{updatedSeries:[]})},e.prototype.appendData=function(t){if(this._disposed){this.id;return}var n=t.seriesIndex,a=this.getModel(),i=a.getSeriesByIndex(n);i.appendData(t),this._scheduler.unfinished=!0,this.getZr().wakeUp()},e.internalField=function(){mu=function(f){var h=f._scheduler;h.restorePipelines(f._model),h.prepareStageTasks(),v_(f,!0),v_(f,!1),h.plan()},v_=function(f,h){for(var v=f._model,d=f._scheduler,p=h?f._componentsViews:f._chartsViews,g=h?f._componentsMap:f._chartsMap,y=f._zr,m=f._api,_=0;_<p.length;_++)p[_].__alive=!1;h?v.eachComponent(function(M,w){M!=="series"&&b(w)}):v.eachSeries(b);function b(M){var w=M.__requireNewView;M.__requireNewView=!1;var D="_ec_"+M.id+"_"+M.type,T=!w&&g[D];if(!T){var I=ja(M.type),A=h?St.getClass(I.main,I.sub):ht.getClass(I.sub);T=new A,T.init(v,m),g[D]=T,p.push(T),y.add(T.group)}M.__viewId=T.__id=D,T.__alive=!0,T.__model=M,T.group.__ecComponentInfo={mainType:M.mainType,index:M.componentIndex},!h&&d.prepareView(T,M,v,m)}for(var _=0;_<p.length;){var x=p[_];x.__alive?_++:(!h&&x.renderTask.dispose(),y.remove(x.group),x.dispose(v,m),p.splice(_,1),g[x.__id]===x&&delete g[x.__id],x.__id=x.group.__ecComponentInfo=null)}},ip=function(f,h,v,d,p){var g=f._model;if(g.setUpdatePayload(v),!d){C([].concat(f._componentsViews).concat(f._chartsViews),x);return}var y={};y[d+"Id"]=v[d+"Id"],y[d+"Index"]=v[d+"Index"],y[d+"Name"]=v[d+"Name"];var m={mainType:d,query:y};p&&(m.subType=p);var _=v.excludeSeriesId,b;_!=null&&(b=ge(),C(ct(_),function(M){var w=Kt(M,null);w!=null&&b.set(w,!0)})),g&&g.eachComponent(m,function(M){var w=b&&b.get(M.id)!=null;if(!w)if(sA(v))if(M instanceof bt)v.type===ps&&!v.notBlur&&!M.get(["emphasis","disabled"])&&gG(M,v,f._api);else{var D=n1(M.mainType,M.componentIndex,v.name,f._api),T=D.focusSelf,I=D.dispatchers;v.type===ps&&T&&!v.notBlur&&r1(M.mainType,M.componentIndex,f._api),I&&C(I,function(A){v.type===ps?mi(A):_i(A)})}else i1(v)&&M instanceof bt&&(_G(M,v,f._api),iA(M),Un(f))},f),g&&g.eachComponent(m,function(M){var w=b&&b.get(M.id)!=null;w||x(f[d==="series"?"_chartsMap":"_componentsMap"][M.__viewId])},f);function x(M){M&&M.__alive&&M[h]&&M[h](M.__model,g,f._api,v)}},go={prepareAndUpdate:function(f){mu(this),go.update.call(this,f,{optionChanged:f.newOption!=null})},update:function(f,h){var v=this._model,d=this._api,p=this._zr,g=this._coordSysMgr,y=this._scheduler;if(!!v){v.setUpdatePayload(f),y.restoreData(v,f),y.performSeriesTasks(v),g.create(v,d),y.performDataProcessorTasks(v,f),p_(this,v),g.update(v,d),t(v),y.performVisualTasks(v,f),y_(this,v,d,f,h);var m=v.get("backgroundColor")||"transparent",_=v.get("darkMode");p.setBackgroundColor(m),_!=null&&_!=="auto"&&p.setDarkMode(_),ba.trigger("afterupdate",v,d)}},updateTransform:function(f){var h=this,v=this._model,d=this._api;if(!!v){v.setUpdatePayload(f);var p=[];v.eachComponent(function(y,m){if(y!=="series"){var _=h.getViewOfComponentModel(m);if(_&&_.__alive)if(_.updateTransform){var b=_.updateTransform(m,v,d,f);b&&b.update&&p.push(_)}else p.push(_)}});var g=ge();v.eachSeries(function(y){var m=h._chartsMap[y.__viewId];if(m.updateTransform){var _=m.updateTransform(y,v,d,f);_&&_.update&&g.set(y.uid,1)}else g.set(y.uid,1)}),t(v),this._scheduler.performVisualTasks(v,f,{setDirty:!0,dirtyMap:g}),op(this,v,d,f,{},g),ba.trigger("afterupdate",v,d)}},updateView:function(f){var h=this._model;!h||(h.setUpdatePayload(f),ht.markUpdateMethod(f,"updateView"),t(h),this._scheduler.performVisualTasks(h,f,{setDirty:!0}),y_(this,h,this._api,f,{}),ba.trigger("afterupdate",h,this._api))},updateVisual:function(f){var h=this,v=this._model;!v||(v.setUpdatePayload(f),v.eachSeries(function(d){d.getData().clearAllVisual()}),ht.markUpdateMethod(f,"updateVisual"),t(v),this._scheduler.performVisualTasks(v,f,{visualType:"visual",setDirty:!0}),v.eachComponent(function(d,p){if(d!=="series"){var g=h.getViewOfComponentModel(p);g&&g.__alive&&g.updateVisual(p,v,h._api,f)}}),v.eachSeries(function(d){var p=h._chartsMap[d.__viewId];p.updateVisual(d,v,h._api,f)}),ba.trigger("afterupdate",v,this._api))},updateLayout:function(f){go.update.call(this,f)}},d_=function(f,h,v,d){if(f._disposed){f.id;return}for(var p=f._model,g=f._coordSysMgr.getCoordinateSystems(),y,m=Wc(p,v),_=0;_<g.length;_++){var b=g[_];if(b[h]&&(y=b[h](p,m,d))!=null)return y}},p_=function(f,h){var v=f._chartsMap,d=f._scheduler;h.eachSeries(function(p){d.updateStreamModes(p,v[p.__viewId])})},g_=function(f,h){var v=this,d=this.getModel(),p=f.type,g=f.escapeConnect,y=lp[p],m=y.actionInfo,_=(m.update||"update").split(":"),b=_.pop(),x=_[0]!=null&&ja(_[0]);this[Rr]=!0;var M=[f],w=!1;f.batch&&(w=!0,M=K(f.batch,function(E){return E=me(X({},E),f),E.batch=null,E}));var D=[],T,I=i1(f),A=sA(f);if(A&&aA(this._api),C(M,function(E){if(T=y.action(E,v._model,v._api),T=T||X({},E),T.type=m.event||T.type,D.push(T),A){var O=N0(f),P=O.queryOptionMap,H=O.mainTypeSpecified,F=H?P.keys()[0]:"series";ip(v,b,E,F),Un(v)}else I?(ip(v,b,E,"series"),Un(v)):x&&ip(v,b,E,x.main,x.sub)}),b!=="none"&&!A&&!I&&!x)try{this[fn]?(mu(this),go.update.call(this,f),this[fn]=null):go[b].call(this,f)}catch(E){throw this[Rr]=!1,E}if(w?T={type:m.event||p,escapeConnect:g,batch:D}:T=D[0],this[Rr]=!1,!h){var N=this._messageCenter;if(N.trigger(T.type,T),I){var L={type:"selectchanged",escapeConnect:g,selected:bG(d),isFromClick:f.isFromClick||!1,fromAction:f.type,fromActionPayload:f};N.trigger(L.type,L)}}},Af=function(f){for(var h=this._pendingActions;h.length;){var v=h.shift();g_.call(this,v,f)}},Cf=function(f){!f&&this.trigger("updated")},pL=function(f,h){f.on("rendered",function(v){h.trigger("rendered",v),f.animation.isFinished()&&!h[fn]&&!h._scheduler.unfinished&&!h._pendingActions.length&&h.trigger("finished")})},gL=function(f,h){f.on("mouseover",function(v){var d=v.target,p=Cs(d,Jc);p&&(yG(p,v,h._api),Un(h))}).on("mouseout",function(v){var d=v.target,p=Cs(d,Jc);p&&(mG(p,v,h._api),Un(h))}).on("click",function(v){var d=v.target,p=Cs(d,function(m){return Te(m).dataIndex!=null},!0);if(p){var g=p.selected?"unselect":"select",y=Te(p);h._api.dispatchAction({type:g,dataType:y.dataType,dataIndexInside:y.dataIndex,seriesIndex:y.seriesIndex,isFromClick:!0})}})};function t(f){f.clearColorPalette(),f.eachSeries(function(h){h.clearColorPalette()})}function n(f){var h=[],v=[],d=!1;if(f.eachComponent(function(m,_){var b=_.get("zlevel")||0,x=_.get("z")||0,M=_.getZLevelKey();d=d||!!M,(m==="series"?v:h).push({zlevel:b,z:x,idx:_.componentIndex,type:m,key:M})}),d){var p=h.concat(v),g,y;Pv(p,function(m,_){return m.zlevel===_.zlevel?m.z-_.z:m.zlevel-_.zlevel}),C(p,function(m){var _=f.getComponent(m.type,m.idx),b=m.zlevel,x=m.key;g!=null&&(b=Math.max(g,b)),x?(b===g&&x!==y&&b++,y=x):y&&(b===g&&b++,y=""),g=b,_.setZLevel(b)})}}y_=function(f,h,v,d,p){n(h),yL(f,h,v,d,p),C(f._chartsViews,function(g){g.__alive=!1}),op(f,h,v,d,p),C(f._chartsViews,function(g){g.__alive||g.remove(h,v)})},yL=function(f,h,v,d,p,g){C(g||f._componentsViews,function(y){var m=y.__model;u(m,y),y.render(m,h,v,d),s(m,y),c(m,y)})},op=function(f,h,v,d,p,g){var y=f._scheduler;p=X(p||{},{updatedSeries:h.getSeries()}),ba.trigger("series:beforeupdate",h,v,p);var m=!1;h.eachSeries(function(_){var b=f._chartsMap[_.__viewId];b.__alive=!0;var x=b.renderTask;y.updatePayload(x,d),u(_,b),g&&g.get(_.uid)&&x.dirty(),x.perform(y.getPerformArgs(x))&&(m=!0),b.group.silent=!!_.get("silent"),o(_,b),iA(_)}),y.unfinished=m||y.unfinished,ba.trigger("series:layoutlabels",h,v,p),ba.trigger("series:transition",h,v,p),h.eachSeries(function(_){var b=f._chartsMap[_.__viewId];s(_,b),c(_,b)}),i(f,h),ba.trigger("series:afterupdate",h,v,p)},Un=function(f){f[f_]=!0,f.getZr().wakeUp()},bL=function(f){!f[f_]||(f.getZr().storage.traverse(function(h){Xl(h)||a(h)}),f[f_]=!1)};function a(f){for(var h=[],v=f.currentStates,d=0;d<v.length;d++){var p=v[d];p==="emphasis"||p==="blur"||p==="select"||h.push(p)}f.selected&&f.states.select&&h.push("select"),f.hoverState===fd&&f.states.emphasis?h.push("emphasis"):f.hoverState===Qc&&f.states.blur&&h.push("blur"),f.useStates(h)}function i(f,h){var v=f._zr,d=v.storage,p=0;d.traverse(function(g){g.isGroup||p++}),p>h.get("hoverLayerThreshold")&&!$e.node&&!$e.worker&&h.eachSeries(function(g){if(!g.preventUsingHoverLayer){var y=f._chartsMap[g.__viewId];y.__alive&&y.eachRendered(function(m){m.states.emphasis&&(m.states.emphasis.hoverLayer=!0)})}})}function o(f,h){var v=f.get("blendMode")||null;h.eachRendered(function(d){d.isGroup||(d.style.blend=v)})}function s(f,h){if(!f.preventAutoZ){var v=f.get("z")||0,d=f.get("zlevel")||0;h.eachRendered(function(p){return l(p,v,d,-1/0),!0})}}function l(f,h,v,d){var p=f.getTextContent(),g=f.getTextGuideLine(),y=f.isGroup;if(y)for(var m=f.childrenRef(),_=0;_<m.length;_++)d=Math.max(l(m[_],h,v,d),d);else f.z=h,f.zlevel=v,d=Math.max(f.z2,d);if(p&&(p.z=h,p.zlevel=v,isFinite(d)&&(p.z2=d+2)),g){var b=f.textGuideLineConfig;g.z=h,g.zlevel=v,isFinite(d)&&(g.z2=d+(b&&b.showAbove?1:-1))}return d}function u(f,h){h.eachRendered(function(v){if(!Xl(v)){var d=v.getTextContent(),p=v.getTextGuideLine();v.stateTransition&&(v.stateTransition=null),d&&d.stateTransition&&(d.stateTransition=null),p&&p.stateTransition&&(p.stateTransition=null),v.hasState()?(v.prevStates=v.currentStates,v.clearStates()):v.prevStates&&(v.prevStates=null)}})}function c(f,h){var v=f.getModel("stateAnimation"),d=f.isAnimationEnabled(),p=v.get("duration"),g=p>0?{duration:p,delay:v.get("delay"),easing:v.get("easing")}:null;h.eachRendered(function(y){if(y.states&&y.states.emphasis){if(Xl(y))return;if(y instanceof je&&SG(y),y.__dirty){var m=y.prevStates;m&&y.useStates(m)}if(d){y.stateTransition=g;var _=y.getTextContent(),b=y.getTextGuideLine();_&&(_.stateTransition=g),b&&(b.stateTransition=g)}y.__dirty&&a(y)}})}mL=function(f){return new(function(h){U(v,h);function v(){return h!==null&&h.apply(this,arguments)||this}return v.prototype.getCoordinateSystems=function(){return f._coordSysMgr.getCoordinateSystems()},v.prototype.getComponentByElement=function(d){for(;d;){var p=d.__ecComponentInfo;if(p!=null)return f._model.getComponent(p.mainType,p.index);d=d.parent}},v.prototype.enterEmphasis=function(d,p){mi(d,p),Un(f)},v.prototype.leaveEmphasis=function(d,p){_i(d,p),Un(f)},v.prototype.enterBlur=function(d){eA(d),Un(f)},v.prototype.leaveBlur=function(d){e1(d),Un(f)},v.prototype.enterSelect=function(d){tA(d),Un(f)},v.prototype.leaveSelect=function(d){rA(d),Un(f)},v.prototype.getModel=function(){return f.getModel()},v.prototype.getViewOfComponentModel=function(d){return f.getViewOfComponentModel(d)},v.prototype.getViewOfSeriesModel=function(d){return f.getViewOfSeriesModel(d)},v}(CC))(f)},_L=function(f){function h(v,d){for(var p=0;p<v.length;p++){var g=v[p];g[h_]=d}}C(Nf,function(v,d){f._messageCenter.on(d,function(p){if(cp[f.group]&&f[h_]!==uL){if(p&&p.escapeConnect)return;var g=f.makeActionFromEvent(p),y=[];C(Es,function(m){m!==f&&m.group===f.group&&y.push(m)}),h(y,uL),C(y,function(m){m[h_]!==uY&&m.dispatchAction(g)}),h(y,cY)}})})}}(),e}(zn),m_=sp.prototype;m_.on=cL("on"),m_.off=cL("off"),m_.one=function(r,e,t){var n=this;function a(){for(var i=[],o=0;o<arguments.length;o++)i[o]=arguments[o];e&&e.apply&&e.apply(this,i),n.off(r,a)}this.on.call(this,r,a,t)};var fY=["click","dblclick","mouseover","mouseout","mousemove","mousedown","mouseup","globalout","contextmenu"];function Npe(r){}var lp={},Nf={},__=[],b_=[],up=[],ML={},M_={},Es={},cp={},hY=+new Date-0,vY=+new Date-0,x_="_echarts_instance_";function dY(r,e,t){var n=!(t&&t.ssr);if(n){var a=w_(r);if(a)return a}var i=new sp(r,e,t);return i.id="ec_"+hY++,Es[i.id]=i,n&&lT(r,x_,i.id),_L(i),ba.trigger("afterinit",i),i}function pY(r){if(J(r)){var e=r;r=null,C(e,function(t){t.group!=null&&(r=t.group)}),r=r||"g_"+vY++,C(e,function(t){t.group=r})}return cp[r]=!0,r}function xL(r){cp[r]=!1}var gY=xL;function yY(r){ce(r)?r=Es[r]:r instanceof sp||(r=w_(r)),r instanceof sp&&!r.isDisposed()&&r.dispose()}function w_(r){return Es[fW(r,x_)]}function mY(r){return Es[r]}function D_(r,e){ML[r]=e}function S_(r){ze(b_,r)<0&&b_.push(r)}function I_(r,e){T_(__,r,e,rY)}function wL(r){fp("afterinit",r)}function DL(r){fp("afterupdate",r)}function fp(r,e){ba.on(r,e)}function Ma(r,e,t){ye(e)&&(t=e,e="");var n=_e(r)?r.type:[r,r={event:e}][0];r.event=(r.event||n).toLowerCase(),e=r.event,!Nf[e]&&(Er(lL.test(n)&&lL.test(e)),lp[n]||(lp[n]={action:t,actionInfo:r}),Nf[e]=n)}function SL(r,e){uu.register(r,e)}function _Y(r){var e=uu.get(r);if(e)return e.getDimensionsInfo?e.getDimensionsInfo():e.dimensions.slice()}function IL(r,e){T_(up,r,e,aL,"layout")}function yo(r,e){T_(up,r,e,iL,"visual")}var TL=[];function T_(r,e,t,n,a){if((ye(e)||_e(e))&&(t=e,e=n),!(ze(TL,t)>=0)){TL.push(t);var i=LN.wrapStageHandler(t,a);i.__prio=e,i.__raw=t,r.push(i)}}function A_(r,e){M_[r]=e}function bY(r){zS({createCanvas:r})}function AL(r,e,t){var n=nL("registerMap");n&&n(r,e,t)}function MY(r){var e=nL("getMap");return e&&e(r)}var CL=AU;yo(c_,e9),yo(ap,t9),yo(ap,r9),yo(c_,y9),yo(ap,m9),yo(oL,Y9),S_(kC),I_(eY,lU),A_("default",n9),Ma({type:ps,event:ps,update:ps},Ot),Ma({type:hd,event:hd,update:hd},Ot),Ma({type:qc,event:qc,update:qc},Ot),Ma({type:vd,event:vd,update:vd},Ot),Ma({type:Xc,event:Xc,update:Xc},Ot),D_("light",d9),D_("dark",p9);var xY={},NL=[],wY={registerPreprocessor:S_,registerProcessor:I_,registerPostInit:wL,registerPostUpdate:DL,registerUpdateLifecycle:fp,registerAction:Ma,registerCoordinateSystem:SL,registerLayout:IL,registerVisual:yo,registerTransform:CL,registerLoading:A_,registerMap:AL,registerImpl:Z9,PRIORITY:sL,ComponentModel:He,ComponentView:St,SeriesModel:bt,ChartView:ht,registerComponentModel:function(r){He.registerClass(r)},registerComponentView:function(r){St.registerClass(r)},registerSeriesModel:function(r){bt.registerClass(r)},registerChartView:function(r){ht.registerClass(r)},registerSubTypeDefaulter:function(r,e){He.registerSubTypeDefaulter(r,e)},registerPainter:function(r,e){UI(r,e)}};function Re(r){if(J(r)){C(r,function(e){Re(e)});return}ze(NL,r)>=0||(NL.push(r),ye(r)&&(r={install:r}),r.install(wY))}function Lf(r){return r==null?0:r.length||1}function LL(r){return r}var DY=function(){function r(e,t,n,a,i,o){this._old=e,this._new=t,this._oldKeyGetter=n||LL,this._newKeyGetter=a||LL,this.context=i,this._diffModeMultiple=o==="multiple"}return r.prototype.add=function(e){return this._add=e,this},r.prototype.update=function(e){return this._update=e,this},r.prototype.updateManyToOne=function(e){return this._updateManyToOne=e,this},r.prototype.updateOneToMany=function(e){return this._updateOneToMany=e,this},r.prototype.updateManyToMany=function(e){return this._updateManyToMany=e,this},r.prototype.remove=function(e){return this._remove=e,this},r.prototype.execute=function(){this[this._diffModeMultiple?"_executeMultiple":"_executeOneToOne"]()},r.prototype._executeOneToOne=function(){var e=this._old,t=this._new,n={},a=new Array(e.length),i=new Array(t.length);this._initIndexMap(e,null,a,"_oldKeyGetter"),this._initIndexMap(t,n,i,"_newKeyGetter");for(var o=0;o<e.length;o++){var s=a[o],l=n[s],u=Lf(l);if(u>1){var c=l.shift();l.length===1&&(n[s]=l[0]),this._update&&this._update(c,o)}else u===1?(n[s]=null,this._update&&this._update(l,o)):this._remove&&this._remove(o)}this._performRestAdd(i,n)},r.prototype._executeMultiple=function(){var e=this._old,t=this._new,n={},a={},i=[],o=[];this._initIndexMap(e,n,i,"_oldKeyGetter"),this._initIndexMap(t,a,o,"_newKeyGetter");for(var s=0;s<i.length;s++){var l=i[s],u=n[l],c=a[l],f=Lf(u),h=Lf(c);if(f>1&&h===1)this._updateManyToOne&&this._updateManyToOne(c,u),a[l]=null;else if(f===1&&h>1)this._updateOneToMany&&this._updateOneToMany(c,u),a[l]=null;else if(f===1&&h===1)this._update&&this._update(c,u),a[l]=null;else if(f>1&&h>1)this._updateManyToMany&&this._updateManyToMany(c,u),a[l]=null;else if(f>1)for(var v=0;v<f;v++)this._remove&&this._remove(u[v]);else this._remove&&this._remove(u)}this._performRestAdd(o,a)},r.prototype._performRestAdd=function(e,t){for(var n=0;n<e.length;n++){var a=e[n],i=t[a],o=Lf(i);if(o>1)for(var s=0;s<o;s++)this._add&&this._add(i[s]);else o===1&&this._add&&this._add(i);t[a]=null}},r.prototype._initIndexMap=function(e,t,n,a){for(var i=this._diffModeMultiple,o=0;o<e.length;o++){var s="_ec_"+this[a](e[o],o);if(i||(n[o]=s),!!t){var l=t[s],u=Lf(l);u===0?(t[s]=o,i&&n.push(s)):u===1?t[s]=[l,o]:l.push(o)}}},r}(),Mi=DY,SY=function(){function r(e,t){this._encode=e,this._schema=t}return r.prototype.get=function(){return{fullDimensions:this._getFullDimensionNames(),encode:this._encode}},r.prototype._getFullDimensionNames=function(){return this._cachedDimNames||(this._cachedDimNames=this._schema?this._schema.makeOutputDimensionNames():[]),this._cachedDimNames},r}();function IY(r,e){var t={},n=t.encode={},a=ge(),i=[],o=[],s={};C(r.dimensions,function(h){var v=r.getDimensionInfo(h),d=v.coordDim;if(d){var p=v.coordDimIndex;C_(n,d)[p]=h,v.isExtraCoord||(a.set(d,1),TY(v.type)&&(i[0]=h),C_(s,d)[p]=r.getDimensionIndex(v.name)),v.defaultTooltip&&o.push(h)}dC.each(function(g,y){var m=C_(n,y),_=v.otherDims[y];_!=null&&_!==!1&&(m[_]=v.name)})});var l=[],u={};a.each(function(h,v){var d=n[v];u[v]=d[0],l=l.concat(d)}),t.dataDimsOnCoord=l,t.dataDimIndicesOnCoord=K(l,function(h){return r.getDimensionInfo(h).storeDimIndex}),t.encodeFirstDimNotExtra=u;var c=n.label;c&&c.length&&(i=c.slice());var f=n.tooltip;return f&&f.length?o=f.slice():o.length||(o=i.slice()),n.defaultedLabel=i,n.defaultedTooltip=o,t.userOutput=new SY(s,e),t}function C_(r,e){return r.hasOwnProperty(e)||(r[e]=[]),r[e]}function hp(r){return r==="category"?"ordinal":r==="time"?"time":"float"}function TY(r){return!(r==="ordinal"||r==="time")}var AY=function(){function r(e){this.otherDims={},e!=null&&X(this,e)}return r}(),vp=AY,CY=Ye(),NY={float:"f",int:"i",ordinal:"o",number:"n",time:"t"},EL=function(){function r(e){this.dimensions=e.dimensions,this._dimOmitted=e.dimensionOmitted,this.source=e.source,this._fullDimCount=e.fullDimensionCount,this._updateDimOmitted(e.dimensionOmitted)}return r.prototype.isDimensionOmitted=function(){return this._dimOmitted},r.prototype._updateDimOmitted=function(e){this._dimOmitted=e,e&&(this._dimNameMap||(this._dimNameMap=zL(this.source)))},r.prototype.getSourceDimensionIndex=function(e){return Ee(this._dimNameMap.get(e),-1)},r.prototype.getSourceDimension=function(e){var t=this.source.dimensionsDefine;if(t)return t[e]},r.prototype.makeStoreSchema=function(){for(var e=this._fullDimCount,t=FC(this.source),n=!kL(e),a="",i=[],o=0,s=0;o<e;o++){var l=void 0,u=void 0,c=void 0,f=this.dimensions[s];if(f&&f.storeDimIndex===o)l=t?f.name:null,u=f.type,c=f.ordinalMeta,s++;else{var h=this.getSourceDimension(o);h&&(l=t?h.name:null,u=h.type)}i.push({property:l,type:u,ordinalMeta:c}),t&&l!=null&&(!f||!f.isCalculationCoord)&&(a+=n?l.replace(/\`/g,"`1").replace(/\$/g,"`2"):l),a+="$",a+=NY[u]||"f",c&&(a+=c.uid),a+="$"}var v=this.source,d=[v.seriesLayoutBy,v.startIndex,a].join("$$");return{dimensions:i,hash:d}},r.prototype.makeOutputDimensionNames=function(){for(var e=[],t=0,n=0;t<this._fullDimCount;t++){var a=void 0,i=this.dimensions[n];if(i&&i.storeDimIndex===t)i.isCalculationCoord||(a=i.name),n++;else{var o=this.getSourceDimension(t);o&&(a=o.name)}e.push(a)}return e},r.prototype.appendCalculationDimension=function(e){this.dimensions.push(e),e.isCalculationCoord=!0,this._fullDimCount++,this._updateDimOmitted(!0)},r}();function OL(r){return r instanceof EL}function PL(r){for(var e=ge(),t=0;t<(r||[]).length;t++){var n=r[t],a=_e(n)?n.name:n;a!=null&&e.get(a)==null&&e.set(a,t)}return e}function zL(r){var e=CY(r);return e.dimNameMap||(e.dimNameMap=PL(r.dimensionsDefine))}function kL(r){return r>30}var Ef=_e,mo=K,LY=typeof Int32Array=="undefined"?Array:Int32Array,EY="e\0\0",RL=-1,OY=["hasItemOption","_nameList","_idList","_invertedIndicesMap","_dimSummary","userOutput","_rawData","_dimValueGetter","_nameDimIdx","_idDimIdx","_nameRepeatCount"],PY=["_approximateExtent"],jL,dp,Of,Pf,N_,pp,L_,zY=function(){function r(e,t){this.type="list",this._dimOmitted=!1,this._nameList=[],this._idList=[],this._visual={},this._layout={},this._itemVisuals=[],this._itemLayouts=[],this._graphicEls=[],this._approximateExtent={},this._calculationInfo={},this.hasItemOption=!1,this.TRANSFERABLE_METHODS=["cloneShallow","downSample","lttbDownSample","map"],this.CHANGABLE_METHODS=["filterSelf","selectRange"],this.DOWNSAMPLE_METHODS=["downSample","lttbDownSample"];var n,a=!1;OL(e)?(n=e.dimensions,this._dimOmitted=e.isDimensionOmitted(),this._schema=e):(a=!0,n=e),n=n||["x","y"];for(var i={},o=[],s={},l=!1,u={},c=0;c<n.length;c++){var f=n[c],h=ce(f)?new vp({name:f}):f instanceof vp?f:new vp(f),v=h.name;h.type=h.type||"float",h.coordDim||(h.coordDim=v,h.coordDimIndex=0);var d=h.otherDims=h.otherDims||{};o.push(v),i[v]=h,u[v]!=null&&(l=!0),h.createInvertedIndices&&(s[v]=[]),d.itemName===0&&(this._nameDimIdx=c),d.itemId===0&&(this._idDimIdx=c),a&&(h.storeDimIndex=c)}if(this.dimensions=o,this._dimInfos=i,this._initGetDimensionInfo(l),this.hostModel=t,this._invertedIndicesMap=s,this._dimOmitted){var p=this._dimIdxToName=ge();C(o,function(g){p.set(i[g].storeDimIndex,g)})}}return r.prototype.getDimension=function(e){var t=this._recognizeDimIndex(e);if(t==null)return e;if(t=e,!this._dimOmitted)return this.dimensions[t];var n=this._dimIdxToName.get(t);if(n!=null)return n;var a=this._schema.getSourceDimension(t);if(a)return a.name},r.prototype.getDimensionIndex=function(e){var t=this._recognizeDimIndex(e);if(t!=null)return t;if(e==null)return-1;var n=this._getDimInfo(e);return n?n.storeDimIndex:this._dimOmitted?this._schema.getSourceDimensionIndex(e):-1},r.prototype._recognizeDimIndex=function(e){if(Ue(e)||e!=null&&!isNaN(e)&&!this._getDimInfo(e)&&(!this._dimOmitted||this._schema.getSourceDimensionIndex(e)<0))return+e},r.prototype._getStoreDimIndex=function(e){var t=this.getDimensionIndex(e);return t},r.prototype.getDimensionInfo=function(e){return this._getDimInfo(this.getDimension(e))},r.prototype._initGetDimensionInfo=function(e){var t=this._dimInfos;this._getDimInfo=e?function(n){return t.hasOwnProperty(n)?t[n]:void 0}:function(n){return t[n]}},r.prototype.getDimensionsOnCoord=function(){return this._dimSummary.dataDimsOnCoord.slice()},r.prototype.mapDimension=function(e,t){var n=this._dimSummary;if(t==null)return n.encodeFirstDimNotExtra[e];var a=n.encode[e];return a?a[t]:null},r.prototype.mapDimensionsAll=function(e){var t=this._dimSummary,n=t.encode[e];return(n||[]).slice()},r.prototype.getStore=function(){return this._store},r.prototype.initData=function(e,t,n){var a=this,i;if(e instanceof q1&&(i=e),!i){var o=this.dimensions,s=H1(e)||Mr(e)?new WC(e,o.length):e;i=new q1;var l=mo(o,function(u){return{type:a._dimInfos[u].type,property:u}});i.initData(s,l,n)}this._store=i,this._nameList=(t||[]).slice(),this._idList=[],this._nameRepeatCount={},this._doInit(0,i.count()),this._dimSummary=IY(this,this._schema),this.userOutput=this._dimSummary.userOutput},r.prototype.appendData=function(e){var t=this._store.appendData(e);this._doInit(t[0],t[1])},r.prototype.appendValues=function(e,t){var n=this._store.appendValues(e,t.length),a=n.start,i=n.end,o=this._shouldMakeIdFromName();if(this._updateOrdinalMeta(),t)for(var s=a;s<i;s++){var l=s-a;this._nameList[s]=t[l],o&&L_(this,s)}},r.prototype._updateOrdinalMeta=function(){for(var e=this._store,t=this.dimensions,n=0;n<t.length;n++){var a=this._dimInfos[t[n]];a.ordinalMeta&&e.collectOrdinalMeta(a.storeDimIndex,a.ordinalMeta)}},r.prototype._shouldMakeIdFromName=function(){var e=this._store.getProvider();return this._idDimIdx==null&&e.getSource().sourceFormat!==ho&&!e.fillStorage},r.prototype._doInit=function(e,t){if(!(e>=t)){var n=this._store,a=n.getProvider();this._updateOrdinalMeta();var i=this._nameList,o=this._idList,s=a.getSource().sourceFormat,l=s===Wn;if(l&&!a.pure)for(var u=[],c=e;c<t;c++){var f=a.getItem(c,u);if(!this.hasItemOption&&JH(f)&&(this.hasItemOption=!0),f){var h=f.name;i[c]==null&&h!=null&&(i[c]=Kt(h,null));var v=f.id;o[c]==null&&v!=null&&(o[c]=Kt(v,null))}}if(this._shouldMakeIdFromName())for(var c=e;c<t;c++)L_(this,c);jL(this)}},r.prototype.getApproximateExtent=function(e){return this._approximateExtent[e]||this._store.getDataExtent(this._getStoreDimIndex(e))},r.prototype.setApproximateExtent=function(e,t){t=this.getDimension(t),this._approximateExtent[t]=e.slice()},r.prototype.getCalculationInfo=function(e){return this._calculationInfo[e]},r.prototype.setCalculationInfo=function(e,t){Ef(e)?X(this._calculationInfo,e):this._calculationInfo[e]=t},r.prototype.getName=function(e){var t=this.getRawIndex(e),n=this._nameList[t];return n==null&&this._nameDimIdx!=null&&(n=Of(this,this._nameDimIdx,t)),n==null&&(n=""),n},r.prototype._getCategory=function(e,t){var n=this._store.get(e,t),a=this._store.getOrdinalMeta(e);return a?a.categories[n]:n},r.prototype.getId=function(e){return dp(this,this.getRawIndex(e))},r.prototype.count=function(){return this._store.count()},r.prototype.get=function(e,t){var n=this._store,a=this._dimInfos[e];if(a)return n.get(a.storeDimIndex,t)},r.prototype.getByRawIndex=function(e,t){var n=this._store,a=this._dimInfos[e];if(a)return n.getByRawIndex(a.storeDimIndex,t)},r.prototype.getIndices=function(){return this._store.getIndices()},r.prototype.getDataExtent=function(e){return this._store.getDataExtent(this._getStoreDimIndex(e))},r.prototype.getSum=function(e){return this._store.getSum(this._getStoreDimIndex(e))},r.prototype.getMedian=function(e){return this._store.getMedian(this._getStoreDimIndex(e))},r.prototype.getValues=function(e,t){var n=this,a=this._store;return J(e)?a.getValues(mo(e,function(i){return n._getStoreDimIndex(i)}),t):a.getValues(e)},r.prototype.hasValue=function(e){for(var t=this._dimSummary.dataDimIndicesOnCoord,n=0,a=t.length;n<a;n++)if(isNaN(this._store.get(t[n],e)))return!1;return!0},r.prototype.indexOfName=function(e){for(var t=0,n=this._store.count();t<n;t++)if(this.getName(t)===e)return t;return-1},r.prototype.getRawIndex=function(e){return this._store.getRawIndex(e)},r.prototype.indexOfRawIndex=function(e){return this._store.indexOfRawIndex(e)},r.prototype.rawIndexOf=function(e,t){var n=e&&this._invertedIndicesMap[e],a=n[t];return a==null||isNaN(a)?RL:a},r.prototype.indicesOfNearest=function(e,t,n){return this._store.indicesOfNearest(this._getStoreDimIndex(e),t,n)},r.prototype.each=function(e,t,n){ye(e)&&(n=t,t=e,e=[]);var a=n||this,i=mo(Pf(e),this._getStoreDimIndex,this);this._store.each(i,a?fe(t,a):t)},r.prototype.filterSelf=function(e,t,n){ye(e)&&(n=t,t=e,e=[]);var a=n||this,i=mo(Pf(e),this._getStoreDimIndex,this);return this._store=this._store.filter(i,a?fe(t,a):t),this},r.prototype.selectRange=function(e){var t=this,n={},a=Fe(e);return C(a,function(i){var o=t._getStoreDimIndex(i);n[o]=e[i]}),this._store=this._store.selectRange(n),this},r.prototype.mapArray=function(e,t,n){ye(e)&&(n=t,t=e,e=[]),n=n||this;var a=[];return this.each(e,function(){a.push(t&&t.apply(this,arguments))},n),a},r.prototype.map=function(e,t,n,a){var i=n||a||this,o=mo(Pf(e),this._getStoreDimIndex,this),s=pp(this);return s._store=this._store.map(o,i?fe(t,i):t),s},r.prototype.modify=function(e,t,n,a){var i=n||a||this,o=mo(Pf(e),this._getStoreDimIndex,this);this._store.modify(o,i?fe(t,i):t)},r.prototype.downSample=function(e,t,n,a){var i=pp(this);return i._store=this._store.downSample(this._getStoreDimIndex(e),t,n,a),i},r.prototype.lttbDownSample=function(e,t){var n=pp(this);return n._store=this._store.lttbDownSample(this._getStoreDimIndex(e),t),n},r.prototype.getRawDataItem=function(e){return this._store.getRawDataItem(e)},r.prototype.getItemModel=function(e){var t=this.hostModel,n=this.getRawDataItem(e);return new ft(n,t,t&&t.ecModel)},r.prototype.diff=function(e){var t=this;return new Mi(e?e.getStore().getIndices():[],this.getStore().getIndices(),function(n){return dp(e,n)},function(n){return dp(t,n)})},r.prototype.getVisual=function(e){var t=this._visual;return t&&t[e]},r.prototype.setVisual=function(e,t){this._visual=this._visual||{},Ef(e)?X(this._visual,e):this._visual[e]=t},r.prototype.getItemVisual=function(e,t){var n=this._itemVisuals[e],a=n&&n[t];return a==null?this.getVisual(t):a},r.prototype.hasItemVisual=function(){return this._itemVisuals.length>0},r.prototype.ensureUniqueItemVisual=function(e,t){var n=this._itemVisuals,a=n[e];a||(a=n[e]={});var i=a[t];return i==null&&(i=this.getVisual(t),J(i)?i=i.slice():Ef(i)&&(i=X({},i)),a[t]=i),i},r.prototype.setItemVisual=function(e,t,n){var a=this._itemVisuals[e]||{};this._itemVisuals[e]=a,Ef(t)?X(a,t):a[t]=n},r.prototype.clearAllVisual=function(){this._visual={},this._itemVisuals=[]},r.prototype.setLayout=function(e,t){Ef(e)?X(this._layout,e):this._layout[e]=t},r.prototype.getLayout=function(e){return this._layout[e]},r.prototype.getItemLayout=function(e){return this._itemLayouts[e]},r.prototype.setItemLayout=function(e,t,n){this._itemLayouts[e]=n?X(this._itemLayouts[e]||{},t):t},r.prototype.clearItemLayouts=function(){this._itemLayouts.length=0},r.prototype.setItemGraphicEl=function(e,t){var n=this.hostModel&&this.hostModel.seriesIndex;Z0(n,this.dataType,e,t),this._graphicEls[e]=t},r.prototype.getItemGraphicEl=function(e){return this._graphicEls[e]},r.prototype.eachItemGraphicEl=function(e,t){C(this._graphicEls,function(n,a){n&&e&&e.call(t,n,a)})},r.prototype.cloneShallow=function(e){return e||(e=new r(this._schema?this._schema:mo(this.dimensions,this._getDimInfo,this),this.hostModel)),N_(e,this),e._store=this._store,e},r.prototype.wrapMethod=function(e,t){var n=this[e];!ye(n)||(this.__wrappedMethods=this.__wrappedMethods||[],this.__wrappedMethods.push(e),this[e]=function(){var a=n.apply(this,arguments);return t.apply(this,[a].concat(Iv(arguments)))})},r.internalField=function(){jL=function(e){var t=e._invertedIndicesMap;C(t,function(n,a){var i=e._dimInfos[a],o=i.ordinalMeta,s=e._store;if(o){n=t[a]=new LY(o.categories.length);for(var l=0;l<n.length;l++)n[l]=RL;for(var l=0;l<s.count();l++)n[s.get(i.storeDimIndex,l)]=l}})},Of=function(e,t,n){return Kt(e._getCategory(t,n),null)},dp=function(e,t){var n=e._idList[t];return n==null&&e._idDimIdx!=null&&(n=Of(e,e._idDimIdx,t)),n==null&&(n=EY+t),n},Pf=function(e){return J(e)||(e=e!=null?[e]:[]),e},pp=function(e){var t=new r(e._schema?e._schema:mo(e.dimensions,e._getDimInfo,e),e.hostModel);return N_(t,e),t},N_=function(e,t){C(OY.concat(t.__wrappedMethods||[]),function(n){t.hasOwnProperty(n)&&(e[n]=t[n])}),e.__wrappedMethods=t.__wrappedMethods,C(PY,function(n){e[n]=Me(t[n])}),e._calculationInfo=X({},t._calculationInfo)},L_=function(e,t){var n=e._nameList,a=e._idList,i=e._nameDimIdx,o=e._idDimIdx,s=n[t],l=a[t];if(s==null&&i!=null&&(n[t]=s=Of(e,i,t)),l==null&&o!=null&&(a[t]=l=Of(e,o,t)),l==null&&s!=null){var u=e._nameRepeatCount,c=u[s]=(u[s]||0)+1;l=s,c>1&&(l+="__ec__"+c),a[t]=l}}}(),r}(),jr=zY;function kY(r,e){return _u(r,e).dimensions}function _u(r,e){H1(r)||(r=G1(r)),e=e||{};var t=e.coordDimensions||[],n=e.dimensionsDefine||r.dimensionsDefine||[],a=ge(),i=[],o=jY(r,t,n,e.dimensionsCount),s=e.canOmitUnusedDimensions&&kL(o),l=n===r.dimensionsDefine,u=l?zL(r):PL(n),c=e.encodeDefine;!c&&e.encodeDefaulter&&(c=e.encodeDefaulter(r,o));for(var f=ge(c),h=new tN(o),v=0;v<h.length;v++)h[v]=-1;function d(T){var I=h[T];if(I<0){var A=n[T],N=_e(A)?A:{name:A},L=new vp,E=N.name;E!=null&&u.get(E)!=null&&(L.name=L.displayName=E),N.type!=null&&(L.type=N.type),N.displayName!=null&&(L.displayName=N.displayName);var O=i.length;return h[T]=O,L.storeDimIndex=T,i.push(L),L}return i[I]}if(!s)for(var v=0;v<o;v++)d(v);f.each(function(T,I){var A=ct(T).slice();if(A.length===1&&!ce(A[0])&&A[0]<0){f.set(I,!1);return}var N=f.set(I,[]);C(A,function(L,E){var O=ce(L)?u.get(L):L;O!=null&&O<o&&(N[E]=O,g(d(O),I,E))})});var p=0;C(t,function(T){var I,A,N,L;if(ce(T))I=T,L={};else{L=T,I=L.name;var E=L.ordinalMeta;L.ordinalMeta=null,L=X({},L),L.ordinalMeta=E,A=L.dimsDef,N=L.otherDims,L.name=L.coordDim=L.coordDimIndex=L.dimsDef=L.otherDims=null}var O=f.get(I);if(O!==!1){if(O=ct(O),!O.length)for(var P=0;P<(A&&A.length||1);P++){for(;p<o&&d(p).coordDim!=null;)p++;p<o&&O.push(p++)}C(O,function(H,F){var G=d(H);if(l&&L.type!=null&&(G.type=L.type),g(me(G,L),I,F),G.name==null&&A){var Z=A[F];!_e(Z)&&(Z={name:Z}),G.name=G.displayName=Z.name,G.defaultTooltip=Z.defaultTooltip}N&&me(G.otherDims,N)})}});function g(T,I,A){dC.get(I)!=null?T.otherDims[I]=A:(T.coordDim=I,T.coordDimIndex=A,a.set(I,!0))}var y=e.generateCoord,m=e.generateCoordCount,_=m!=null;m=y?m||1:0;var b=y||"value";function x(T){T.name==null&&(T.name=T.coordDim)}if(s)C(i,function(T){x(T)}),i.sort(function(T,I){return T.storeDimIndex-I.storeDimIndex});else for(var M=0;M<o;M++){var w=d(M),D=w.coordDim;D==null&&(w.coordDim=BY(b,a,_),w.coordDimIndex=0,(!y||m<=0)&&(w.isExtraCoord=!0),m--),x(w),w.type==null&&(mC(r,M)===Dr.Must||w.isExtraCoord&&(w.otherDims.itemName!=null||w.otherDims.seriesName!=null))&&(w.type="ordinal")}return RY(i),new EL({source:r,dimensions:i,fullDimensionCount:o,dimensionOmitted:s})}function RY(r){for(var e=ge(),t=0;t<r.length;t++){var n=r[t],a=n.name,i=e.get(a)||0;i>0&&(n.name=a+(i-1)),i++,e.set(a,i)}}function jY(r,e,t,n){var a=Math.max(r.dimensionsDetectedCount||1,e.length,t.length,n||0);return C(e,function(i){var o;_e(i)&&(o=i.dimsDef)&&(a=Math.max(a,o.length))}),a}function BY(r,e,t){if(t||e.hasKey(r)){for(var n=0;e.hasKey(r+n);)n++;r+=n}return e.set(r,!0),r}var FY=function(){function r(e){this.coordSysDims=[],this.axisMap=ge(),this.categoryAxisMap=ge(),this.coordSysName=e}return r}();function VY(r){var e=r.get("coordinateSystem"),t=new FY(e),n=HY[e];if(n)return n(r,t,t.axisMap,t.categoryAxisMap),t}var HY={cartesian2d:function(r,e,t,n){var a=r.getReferringComponents("xAxis",Ut).models[0],i=r.getReferringComponents("yAxis",Ut).models[0];e.coordSysDims=["x","y"],t.set("x",a),t.set("y",i),bu(a)&&(n.set("x",a),e.firstCategoryDimIndex=0),bu(i)&&(n.set("y",i),e.firstCategoryDimIndex==null&&(e.firstCategoryDimIndex=1))},singleAxis:function(r,e,t,n){var a=r.getReferringComponents("singleAxis",Ut).models[0];e.coordSysDims=["single"],t.set("single",a),bu(a)&&(n.set("single",a),e.firstCategoryDimIndex=0)},polar:function(r,e,t,n){var a=r.getReferringComponents("polar",Ut).models[0],i=a.findAxisModel("radiusAxis"),o=a.findAxisModel("angleAxis");e.coordSysDims=["radius","angle"],t.set("radius",i),t.set("angle",o),bu(i)&&(n.set("radius",i),e.firstCategoryDimIndex=0),bu(o)&&(n.set("angle",o),e.firstCategoryDimIndex==null&&(e.firstCategoryDimIndex=1))},geo:function(r,e,t,n){e.coordSysDims=["lng","lat"]},parallel:function(r,e,t,n){var a=r.ecModel,i=a.getComponent("parallel",r.get("parallelIndex")),o=e.coordSysDims=i.dimensions.slice();C(i.parallelAxisIndex,function(s,l){var u=a.getComponent("parallelAxis",s),c=o[l];t.set(c,u),bu(u)&&(n.set(c,u),e.firstCategoryDimIndex==null&&(e.firstCategoryDimIndex=l))})}};function bu(r){return r.get("type")==="category"}function BL(r,e,t){t=t||{};var n=t.byIndex,a=t.stackedCoordDimension,i,o,s;WY(e)?i=e:(o=e.schema,i=o.dimensions,s=e.store);var l=!!(r&&r.get("stack")),u,c,f,h;if(C(i,function(m,_){ce(m)&&(i[_]=m={name:m}),l&&!m.isExtraCoord&&(!n&&!u&&m.ordinalMeta&&(u=m),!c&&m.type!=="ordinal"&&m.type!=="time"&&(!a||a===m.coordDim)&&(c=m))}),c&&!n&&!u&&(n=!0),c){f="__\0ecstackresult_"+r.id,h="__\0ecstackedover_"+r.id,u&&(u.createInvertedIndices=!0);var v=c.coordDim,d=c.type,p=0;C(i,function(m){m.coordDim===v&&p++});var g={name:f,coordDim:v,coordDimIndex:p,type:d,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:i.length},y={name:h,coordDim:h,coordDimIndex:p+1,type:d,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:i.length+1};o?(s&&(g.storeDimIndex=s.ensureCalculationDimension(h,d),y.storeDimIndex=s.ensureCalculationDimension(f,d)),o.appendCalculationDimension(g),o.appendCalculationDimension(y)):(i.push(g),i.push(y))}return{stackedDimension:c&&c.name,stackedByDimension:u&&u.name,isStackedByIndex:n,stackedOverDimension:h,stackResultDimension:f}}function WY(r){return!OL(r.schema)}function xi(r,e){return!!e&&e===r.getCalculationInfo("stackedDimension")}function E_(r,e){return xi(r,e)?r.getCalculationInfo("stackResultDimension"):e}function GY(r,e){var t=r.get("coordinateSystem"),n=uu.get(t),a;return e&&e.coordSysDims&&(a=K(e.coordSysDims,function(i){var o={name:i},s=e.axisMap.get(i);if(s){var l=s.get("type");o.type=hp(l)}return o})),a||(a=n&&(n.getDimensionsInfo?n.getDimensionsInfo():n.dimensions.slice())||["x","y"]),a}function $Y(r,e,t){var n,a;return t&&C(r,function(i,o){var s=i.coordDim,l=t.categoryAxisMap.get(s);l&&(n==null&&(n=o),i.ordinalMeta=l.getOrdinalMeta(),e&&(i.createInvertedIndices=!0)),i.otherDims.itemName!=null&&(a=!0)}),!a&&n!=null&&(r[n].otherDims.itemName=0),n}function Ua(r,e,t){t=t||{};var n=e.getSourceManager(),a,i=!1;r?(i=!0,a=G1(r)):(a=n.getSource(),i=a.sourceFormat===Wn);var o=VY(e),s=GY(e,o),l=t.useEncodeDefaulter,u=ye(l)?l:l?Ae(yC,s,e):null,c={coordDimensions:s,generateCoord:t.generateCoord,encodeDefine:e.getEncode(),encodeDefaulter:u,canOmitUnusedDimensions:!i},f=_u(a,c),h=$Y(f.dimensions,t.createInvertedIndices,o),v=i?null:n.getSharedDataStore(f),d=BL(e,{schema:f,store:v}),p=new jr(f,e);p.setCalculationInfo(d);var g=h!=null&&UY(a)?function(y,m,_,b){return b===h?_:this.defaultDimValueGetter(y,m,_,b)}:null;return p.hasItemOption=!1,p.initData(i?a:v,null,g),p}function UY(r){if(r.sourceFormat===Wn){var e=YY(r.data||[]);return!J(Wl(e))}}function YY(r){for(var e=0;e<r.length&&r[e]==null;)e++;return r[e]}var FL=function(){function r(e){this._setting=e||{},this._extent=[1/0,-1/0]}return r.prototype.getSetting=function(e){return this._setting[e]},r.prototype.unionExtent=function(e){var t=this._extent;e[0]<t[0]&&(t[0]=e[0]),e[1]>t[1]&&(t[1]=e[1])},r.prototype.unionExtentFromData=function(e,t){this.unionExtent(e.getApproximateExtent(t))},r.prototype.getExtent=function(){return this._extent.slice()},r.prototype.setExtent=function(e,t){var n=this._extent;isNaN(e)||(n[0]=e),isNaN(t)||(n[1]=t)},r.prototype.isInExtentRange=function(e){return this._extent[0]<=e&&this._extent[1]>=e},r.prototype.isBlank=function(){return this._isBlank},r.prototype.setBlank=function(e){this._isBlank=e},r}();nd(FL);var wi=FL,QY=0,ZY=function(){function r(e){this.categories=e.categories||[],this._needCollect=e.needCollect,this._deduplication=e.deduplication,this.uid=++QY}return r.createByAxisModel=function(e){var t=e.option,n=t.data,a=n&&K(n,qY);return new r({categories:a,needCollect:!a,deduplication:t.dedplication!==!1})},r.prototype.getOrdinal=function(e){return this._getOrCreateMap().get(e)},r.prototype.parseAndCollect=function(e){var t,n=this._needCollect;if(!ce(e)&&!n)return e;if(n&&!this._deduplication)return t=this.categories.length,this.categories[t]=e,t;var a=this._getOrCreateMap();return t=a.get(e),t==null&&(n?(t=this.categories.length,this.categories[t]=e,a.set(e,t)):t=NaN),t},r.prototype._getOrCreateMap=function(){return this._map||(this._map=ge(this.categories))},r}();function qY(r){return _e(r)&&r.value!=null?r.value:r+""}var O_=ZY;function P_(r){return r.type==="interval"||r.type==="log"}function XY(r,e,t,n){var a={},i=r[1]-r[0],o=a.interval=I0(i/e,!0);t!=null&&o<t&&(o=a.interval=t),n!=null&&o>n&&(o=a.interval=n);var s=a.intervalPrecision=VL(o),l=a.niceTickExtent=[Nt(Math.ceil(r[0]/o)*o,s),Nt(Math.floor(r[1]/o)*o,s)];return JY(l,r),a}function z_(r){var e=Math.pow(10,td(r)),t=r/e;return t?t===2?t=3:t===3?t=5:t*=2:t=1,Nt(t*e)}function VL(r){return da(r)+2}function HL(r,e,t){r[e]=Math.max(Math.min(r[e],t[1]),t[0])}function JY(r,e){!isFinite(r[0])&&(r[0]=e[0]),!isFinite(r[1])&&(r[1]=e[1]),HL(r,0,e),HL(r,1,e),r[0]>r[1]&&(r[0]=r[1])}function gp(r,e){return r>=e[0]&&r<=e[1]}function yp(r,e){return e[1]===e[0]?.5:(r-e[0])/(e[1]-e[0])}function mp(r,e){return r*(e[1]-e[0])+e[0]}var WL=function(r){U(e,r);function e(t){var n=r.call(this,t)||this;n.type="ordinal";var a=n.getSetting("ordinalMeta");return a||(a=new O_({})),J(a)&&(a=new O_({categories:K(a,function(i){return _e(i)?i.value:i})})),n._ordinalMeta=a,n._extent=n.getSetting("extent")||[0,a.categories.length-1],n}return e.prototype.parse=function(t){return t==null?NaN:ce(t)?this._ordinalMeta.getOrdinal(t):Math.round(t)},e.prototype.contain=function(t){return t=this.parse(t),gp(t,this._extent)&&this._ordinalMeta.categories[t]!=null},e.prototype.normalize=function(t){return t=this._getTickNumber(this.parse(t)),yp(t,this._extent)},e.prototype.scale=function(t){return t=Math.round(mp(t,this._extent)),this.getRawOrdinalNumber(t)},e.prototype.getTicks=function(){for(var t=[],n=this._extent,a=n[0];a<=n[1];)t.push({value:a}),a++;return t},e.prototype.getMinorTicks=function(t){},e.prototype.setSortInfo=function(t){if(t==null){this._ordinalNumbersByTick=this._ticksByOrdinalNumber=null;return}for(var n=t.ordinalNumbers,a=this._ordinalNumbersByTick=[],i=this._ticksByOrdinalNumber=[],o=0,s=this._ordinalMeta.categories.length,l=Math.min(s,n.length);o<l;++o){var u=n[o];a[o]=u,i[u]=o}for(var c=0;o<s;++o){for(;i[c]!=null;)c++;a.push(c),i[c]=o}},e.prototype._getTickNumber=function(t){var n=this._ticksByOrdinalNumber;return n&&t>=0&&t<n.length?n[t]:t},e.prototype.getRawOrdinalNumber=function(t){var n=this._ordinalNumbersByTick;return n&&t>=0&&t<n.length?n[t]:t},e.prototype.getLabel=function(t){if(!this.isBlank()){var n=this.getRawOrdinalNumber(t.value),a=this._ordinalMeta.categories[n];return a==null?"":a+""}},e.prototype.count=function(){return this._extent[1]-this._extent[0]+1},e.prototype.unionExtentFromData=function(t,n){this.unionExtent(t.getApproximateExtent(n))},e.prototype.isInExtentRange=function(t){return t=this._getTickNumber(t),this._extent[0]<=t&&this._extent[1]>=t},e.prototype.getOrdinalMeta=function(){return this._ordinalMeta},e.prototype.calcNiceTicks=function(){},e.prototype.calcNiceExtent=function(){},e.type="ordinal",e}(wi);wi.registerClass(WL);var k_=WL,Os=Nt,GL=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="interval",t._interval=0,t._intervalPrecision=2,t}return e.prototype.parse=function(t){return t},e.prototype.contain=function(t){return gp(t,this._extent)},e.prototype.normalize=function(t){return yp(t,this._extent)},e.prototype.scale=function(t){return mp(t,this._extent)},e.prototype.setExtent=function(t,n){var a=this._extent;isNaN(t)||(a[0]=parseFloat(t)),isNaN(n)||(a[1]=parseFloat(n))},e.prototype.unionExtent=function(t){var n=this._extent;t[0]<n[0]&&(n[0]=t[0]),t[1]>n[1]&&(n[1]=t[1]),this.setExtent(n[0],n[1])},e.prototype.getInterval=function(){return this._interval},e.prototype.setInterval=function(t){this._interval=t,this._niceExtent=this._extent.slice(),this._intervalPrecision=VL(t)},e.prototype.getTicks=function(t){var n=this._interval,a=this._extent,i=this._niceExtent,o=this._intervalPrecision,s=[];if(!n)return s;var l=1e4;a[0]<i[0]&&(t?s.push({value:Os(i[0]-n,o)}):s.push({value:a[0]}));for(var u=i[0];u<=i[1]&&(s.push({value:u}),u=Os(u+n,o),u!==s[s.length-1].value);)if(s.length>l)return[];var c=s.length?s[s.length-1].value:i[1];return a[1]>c&&(t?s.push({value:Os(c+n,o)}):s.push({value:a[1]})),s},e.prototype.getMinorTicks=function(t){for(var n=this.getTicks(!0),a=[],i=this.getExtent(),o=1;o<n.length;o++){for(var s=n[o],l=n[o-1],u=0,c=[],f=s.value-l.value,h=f/t;u<t-1;){var v=Os(l.value+(u+1)*h);v>i[0]&&v<i[1]&&c.push(v),u++}a.push(c)}return a},e.prototype.getLabel=function(t,n){if(t==null)return"";var a=n&&n.precision;a==null?a=da(t.value)||0:a==="auto"&&(a=this._intervalPrecision);var i=Os(t.value,a,!0);return A1(i)},e.prototype.calcNiceTicks=function(t,n,a){t=t||5;var i=this._extent,o=i[1]-i[0];if(!!isFinite(o)){o<0&&(o=-o,i.reverse());var s=XY(i,t,n,a);this._intervalPrecision=s.intervalPrecision,this._interval=s.interval,this._niceExtent=s.niceTickExtent}},e.prototype.calcNiceExtent=function(t){var n=this._extent;if(n[0]===n[1])if(n[0]!==0){var a=Math.abs(n[0]);t.fixMax||(n[1]+=a/2),n[0]-=a/2}else n[1]=1;var i=n[1]-n[0];isFinite(i)||(n[0]=0,n[1]=1),this.calcNiceTicks(t.splitNumber,t.minInterval,t.maxInterval);var o=this._interval;t.fixMin||(n[0]=Os(Math.floor(n[0]/o)*o)),t.fixMax||(n[1]=Os(Math.ceil(n[1]/o)*o))},e.prototype.setNiceExtent=function(t,n){this._niceExtent=[t,n]},e.type="interval",e}(wi);wi.registerClass(GL);var _o=GL,$L=typeof Float32Array!="undefined",KY=$L?Float32Array:Array;function Ya(r){return J(r)?$L?new Float32Array(r):r:new KY(r)}var R_="__ec_stack_";function j_(r){return r.get("stack")||R_+r.seriesIndex}function B_(r){return r.dim+r.index}function eQ(r){var e=[],t=r.axis,n="axis0";if(t.type==="category"){for(var a=t.getBandWidth(),i=0;i<r.count;i++)e.push(me({bandWidth:a,axisKey:n,stackId:R_+i},r));for(var o=QL(e),s=[],i=0;i<r.count;i++){var l=o[n][R_+i];l.offsetCenter=l.offset+l.width/2,s.push(l)}return s}}function UL(r,e){var t=[];return e.eachSeriesByType(r,function(n){XL(n)&&t.push(n)}),t}function tQ(r){var e={};C(r,function(l){var u=l.coordinateSystem,c=u.getBaseAxis();if(!(c.type!=="time"&&c.type!=="value"))for(var f=l.getData(),h=c.dim+"_"+c.index,v=f.getDimensionIndex(f.mapDimension(c.dim)),d=f.getStore(),p=0,g=d.count();p<g;++p){var y=d.get(v,p);e[h]?e[h].push(y):e[h]=[y]}});var t={};for(var n in e)if(e.hasOwnProperty(n)){var a=e[n];if(a){a.sort(function(l,u){return l-u});for(var i=null,o=1;o<a.length;++o){var s=a[o]-a[o-1];s>0&&(i=i===null?s:Math.min(i,s))}t[n]=i}}return t}function YL(r){var e=tQ(r),t=[];return C(r,function(n){var a=n.coordinateSystem,i=a.getBaseAxis(),o=i.getExtent(),s;if(i.type==="category")s=i.getBandWidth();else if(i.type==="value"||i.type==="time"){var l=i.dim+"_"+i.index,u=e[l],c=Math.abs(o[1]-o[0]),f=i.scale.getExtent(),h=Math.abs(f[1]-f[0]);s=u?c/h*u:c}else{var v=n.getData();s=Math.abs(o[1]-o[0])/v.count()}var d=ue(n.get("barWidth"),s),p=ue(n.get("barMaxWidth"),s),g=ue(n.get("barMinWidth")||(JL(n)?.5:1),s),y=n.get("barGap"),m=n.get("barCategoryGap");t.push({bandWidth:s,barWidth:d,barMaxWidth:p,barMinWidth:g,barGap:y,barCategoryGap:m,axisKey:B_(i),stackId:j_(n)})}),QL(t)}function QL(r){var e={};C(r,function(n,a){var i=n.axisKey,o=n.bandWidth,s=e[i]||{bandWidth:o,remainedWidth:o,autoWidthCount:0,categoryGap:null,gap:"20%",stacks:{}},l=s.stacks;e[i]=s;var u=n.stackId;l[u]||s.autoWidthCount++,l[u]=l[u]||{width:0,maxWidth:0};var c=n.barWidth;c&&!l[u].width&&(l[u].width=c,c=Math.min(s.remainedWidth,c),s.remainedWidth-=c);var f=n.barMaxWidth;f&&(l[u].maxWidth=f);var h=n.barMinWidth;h&&(l[u].minWidth=h);var v=n.barGap;v!=null&&(s.gap=v);var d=n.barCategoryGap;d!=null&&(s.categoryGap=d)});var t={};return C(e,function(n,a){t[a]={};var i=n.stacks,o=n.bandWidth,s=n.categoryGap;if(s==null){var l=Fe(i).length;s=Math.max(35-l*4,15)+"%"}var u=ue(s,o),c=ue(n.gap,1),f=n.remainedWidth,h=n.autoWidthCount,v=(f-u)/(h+(h-1)*c);v=Math.max(v,0),C(i,function(y){var m=y.maxWidth,_=y.minWidth;if(y.width){var b=y.width;m&&(b=Math.min(b,m)),_&&(b=Math.max(b,_)),y.width=b,f-=b+c*b,h--}else{var b=v;m&&m<b&&(b=Math.min(m,f)),_&&_>b&&(b=_),b!==v&&(y.width=b,f-=b+c*b,h--)}}),v=(f-u)/(h+(h-1)*c),v=Math.max(v,0);var d=0,p;C(i,function(y,m){y.width||(y.width=v),p=y,d+=y.width*(1+c)}),p&&(d-=p.width*c);var g=-d/2;C(i,function(y,m){t[a][m]=t[a][m]||{bandWidth:o,offset:g,width:y.width},g+=y.width*(1+c)})}),t}function rQ(r,e,t){if(r&&e){var n=r[B_(e)];return n!=null&&t!=null?n[j_(t)]:n}}function ZL(r,e){var t=UL(r,e),n=YL(t);C(t,function(a){var i=a.getData(),o=a.coordinateSystem,s=o.getBaseAxis(),l=j_(a),u=n[B_(s)][l],c=u.offset,f=u.width;i.setLayout({bandWidth:u.bandWidth,offset:c,size:f})})}function qL(r){return{seriesType:r,plan:hu(),reset:function(e){if(!!XL(e)){var t=e.getData(),n=e.coordinateSystem,a=n.getBaseAxis(),i=n.getOtherAxis(a),o=t.getDimensionIndex(t.mapDimension(i.dim)),s=t.getDimensionIndex(t.mapDimension(a.dim)),l=e.get("showBackground",!0),u=t.mapDimension(i.dim),c=t.getCalculationInfo("stackResultDimension"),f=xi(t,u)&&!!t.getCalculationInfo("stackedOnSeries"),h=i.isHorizontal(),v=nQ(a,i),d=JL(e),p=e.get("barMinHeight")||0,g=c&&t.getDimensionIndex(c),y=t.getLayout("size"),m=t.getLayout("offset");return{progress:function(_,b){for(var x=_.count,M=d&&Ya(x*3),w=d&&l&&Ya(x*3),D=d&&Ya(x),T=n.master.getRect(),I=h?T.width:T.height,A,N=b.getStore(),L=0;(A=_.next())!=null;){var E=N.get(f?g:o,A),O=N.get(s,A),P=v,H=void 0;f&&(H=+E-N.get(o,A));var F=void 0,G=void 0,Z=void 0,te=void 0;if(h){var V=n.dataToPoint([E,O]);if(f){var Y=n.dataToPoint([H,O]);P=Y[0]}F=P,G=V[1]+m,Z=V[0]-P,te=y,Math.abs(Z)<p&&(Z=(Z<0?-1:1)*p)}else{var V=n.dataToPoint([O,E]);if(f){var Y=n.dataToPoint([O,H]);P=Y[1]}F=V[0]+m,G=P,Z=y,te=V[1]-P,Math.abs(te)<p&&(te=(te<=0?-1:1)*p)}d?(M[L]=F,M[L+1]=G,M[L+2]=h?Z:te,w&&(w[L]=h?T.x:F,w[L+1]=h?G:T.y,w[L+2]=I),D[A]=A):b.setItemLayout(A,{x:F,y:G,width:Z,height:te}),L+=3}d&&b.setLayout({largePoints:M,largeDataIndices:D,largeBackgroundPoints:w,valueAxisHorizontal:h})}}}}}}function XL(r){return r.coordinateSystem&&r.coordinateSystem.type==="cartesian2d"}function JL(r){return r.pipelineContext&&r.pipelineContext.large}function nQ(r,e){return e.toGlobalCoord(e.dataToCoord(e.type==="log"?1:0))}var aQ=function(r,e,t,n){for(;t<n;){var a=t+n>>>1;r[a][1]<e?t=a+1:n=a}return t},KL=function(r){U(e,r);function e(t){var n=r.call(this,t)||this;return n.type="time",n}return e.prototype.getLabel=function(t){var n=this.getSetting("useUTC");return vf(t.value,KA[w$(nu(this._minLevelUnit))]||KA.second,n,this.getSetting("locale"))},e.prototype.getFormattedLabel=function(t,n,a){var i=this.getSetting("useUTC"),o=this.getSetting("locale");return D$(t,n,a,o,i)},e.prototype.getTicks=function(){var t=this._interval,n=this._extent,a=[];if(!t)return a;a.push({value:n[0],level:0});var i=this.getSetting("useUTC"),o=fQ(this._minLevelUnit,this._approxInterval,i,n);return a=a.concat(o),a.push({value:n[1],level:0}),a},e.prototype.calcNiceExtent=function(t){var n=this._extent;if(n[0]===n[1]&&(n[0]-=Hn,n[1]+=Hn),n[1]===-1/0&&n[0]===1/0){var a=new Date;n[1]=+new Date(a.getFullYear(),a.getMonth(),a.getDate()),n[0]=n[1]-Hn}this.calcNiceTicks(t.splitNumber,t.minInterval,t.maxInterval)},e.prototype.calcNiceTicks=function(t,n,a){t=t||10;var i=this._extent,o=i[1]-i[0];this._approxInterval=o/t,n!=null&&this._approxInterval<n&&(this._approxInterval=n),a!=null&&this._approxInterval>a&&(this._approxInterval=a);var s=_p.length,l=Math.min(aQ(_p,this._approxInterval,0,s),s-1);this._interval=_p[l][1],this._minLevelUnit=_p[Math.max(l-1,0)][0]},e.prototype.parse=function(t){return Ue(t)?t:+Mn(t)},e.prototype.contain=function(t){return gp(this.parse(t),this._extent)},e.prototype.normalize=function(t){return yp(this.parse(t),this._extent)},e.prototype.scale=function(t){return mp(t,this._extent)},e.type="time",e}(_o),_p=[["second",D1],["minute",S1],["hour",ff],["quarter-day",ff*6],["half-day",ff*12],["day",Hn*1.2],["half-week",Hn*3.5],["week",Hn*7],["month",Hn*31],["quarter",Hn*95],["half-year",JA/2],["year",JA]];function iQ(r,e,t,n){var a=Mn(e),i=Mn(t),o=function(d){return rC(a,d,n)===rC(i,d,n)},s=function(){return o("year")},l=function(){return s()&&o("month")},u=function(){return l()&&o("day")},c=function(){return u()&&o("hour")},f=function(){return c()&&o("minute")},h=function(){return f()&&o("second")},v=function(){return h()&&o("millisecond")};switch(r){case"year":return s();case"month":return l();case"day":return u();case"hour":return c();case"minute":return f();case"second":return h();case"millisecond":return v()}}function oQ(r,e){return r/=Hn,r>16?16:r>7.5?7:r>3.5?4:r>1.5?2:1}function sQ(r){var e=30*Hn;return r/=e,r>6?6:r>3?3:r>2?2:1}function lQ(r){return r/=ff,r>12?12:r>6?6:r>3.5?4:r>2?2:1}function e2(r,e){return r/=e?S1:D1,r>30?30:r>20?20:r>15?15:r>10?10:r>5?5:r>2?2:1}function uQ(r){return I0(r,!0)}function cQ(r,e,t){var n=new Date(r);switch(nu(e)){case"year":case"month":n[nC(t)](0);case"day":n[aC(t)](1);case"hour":n[iC(t)](0);case"minute":n[oC(t)](0);case"second":n[sC(t)](0),n[lC(t)](0)}return n.getTime()}function fQ(r,e,t,n){var a=1e4,i=eC,o=0;function s(I,A,N,L,E,O,P){for(var H=new Date(A),F=A,G=H[L]();F<N&&F<=n[1];)P.push({value:F}),G+=I,H[E](G),F=H.getTime();P.push({value:F,notAdd:!0})}function l(I,A,N){var L=[],E=!A.length;if(!iQ(nu(I),n[0],n[1],t)){E&&(A=[{value:cQ(new Date(n[0]),I,t)},{value:n[1]}]);for(var O=0;O<A.length-1;O++){var P=A[O].value,H=A[O+1].value;if(P!==H){var F=void 0,G=void 0,Z=void 0,te=!1;switch(I){case"year":F=Math.max(1,Math.round(e/Hn/365)),G=T1(t),Z=S$(t);break;case"half-year":case"quarter":case"month":F=sQ(e),G=au(t),Z=nC(t);break;case"week":case"half-week":case"day":F=oQ(e),G=zd(t),Z=aC(t),te=!0;break;case"half-day":case"quarter-day":case"hour":F=lQ(e),G=df(t),Z=iC(t);break;case"minute":F=e2(e,!0),G=kd(t),Z=oC(t);break;case"second":F=e2(e,!1),G=Rd(t),Z=sC(t);break;case"millisecond":F=uQ(e),G=jd(t),Z=lC(t);break}s(F,P,H,G,Z,te,L),I==="year"&&N.length>1&&O===0&&N.unshift({value:N[0].value-F})}}for(var O=0;O<L.length;O++)N.push(L[O]);return L}}for(var u=[],c=[],f=0,h=0,v=0;v<i.length&&o++<a;++v){var d=nu(i[v]);if(!!x$(i[v])){l(i[v],u[u.length-1]||[],c);var p=i[v+1]?nu(i[v+1]):null;if(d!==p){if(c.length){h=f,c.sort(function(I,A){return I.value-A.value});for(var g=[],y=0;y<c.length;++y){var m=c[y].value;(y===0||c[y-1].value!==m)&&(g.push(c[y]),m>=n[0]&&m<=n[1]&&f++)}var _=(n[1]-n[0])/e;if(f>_*1.5&&h>_/1.5||(u.push(g),f>_||r===i[v]))break}c=[]}}}for(var b=ot(K(u,function(I){return ot(I,function(A){return A.value>=n[0]&&A.value<=n[1]&&!A.notAdd})}),function(I){return I.length>0}),x=[],M=b.length-1,v=0;v<b.length;++v)for(var w=b[v],D=0;D<w.length;++D)x.push({value:w[D].value,level:M-v});x.sort(function(I,A){return I.value-A.value});for(var T=[],v=0;v<x.length;++v)(v===0||x[v].value!==x[v-1].value)&&T.push(x[v]);return T}wi.registerClass(KL);var t2=KL,r2=wi.prototype,zf=_o.prototype,hQ=Nt,vQ=Math.floor,dQ=Math.ceil,bp=Math.pow,xa=Math.log,F_=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="log",t.base=10,t._originalScale=new _o,t._interval=0,t}return e.prototype.getTicks=function(t){var n=this._originalScale,a=this._extent,i=n.getExtent(),o=zf.getTicks.call(this,t);return K(o,function(s){var l=s.value,u=Nt(bp(this.base,l));return u=l===a[0]&&this._fixMin?Mp(u,i[0]):u,u=l===a[1]&&this._fixMax?Mp(u,i[1]):u,{value:u}},this)},e.prototype.setExtent=function(t,n){var a=xa(this.base);t=xa(Math.max(0,t))/a,n=xa(Math.max(0,n))/a,zf.setExtent.call(this,t,n)},e.prototype.getExtent=function(){var t=this.base,n=r2.getExtent.call(this);n[0]=bp(t,n[0]),n[1]=bp(t,n[1]);var a=this._originalScale,i=a.getExtent();return this._fixMin&&(n[0]=Mp(n[0],i[0])),this._fixMax&&(n[1]=Mp(n[1],i[1])),n},e.prototype.unionExtent=function(t){this._originalScale.unionExtent(t);var n=this.base;t[0]=xa(t[0])/xa(n),t[1]=xa(t[1])/xa(n),r2.unionExtent.call(this,t)},e.prototype.unionExtentFromData=function(t,n){this.unionExtent(t.getApproximateExtent(n))},e.prototype.calcNiceTicks=function(t){t=t||10;var n=this._extent,a=n[1]-n[0];if(!(a===1/0||a<=0)){var i=XI(a),o=t/a*i;for(o<=.5&&(i*=10);!isNaN(i)&&Math.abs(i)<1&&Math.abs(i)>0;)i*=10;var s=[Nt(dQ(n[0]/i)*i),Nt(vQ(n[1]/i)*i)];this._interval=i,this._niceExtent=s}},e.prototype.calcNiceExtent=function(t){zf.calcNiceExtent.call(this,t),this._fixMin=t.fixMin,this._fixMax=t.fixMax},e.prototype.parse=function(t){return t},e.prototype.contain=function(t){return t=xa(t)/xa(this.base),gp(t,this._extent)},e.prototype.normalize=function(t){return t=xa(t)/xa(this.base),yp(t,this._extent)},e.prototype.scale=function(t){return t=mp(t,this._extent),bp(this.base,t)},e.type="log",e}(wi),n2=F_.prototype;n2.getMinorTicks=zf.getMinorTicks,n2.getLabel=zf.getLabel;function Mp(r,e){return hQ(r,da(e))}wi.registerClass(F_);var pQ=F_,gQ=function(){function r(e,t,n){this._prepareParams(e,t,n)}return r.prototype._prepareParams=function(e,t,n){n[1]<n[0]&&(n=[NaN,NaN]),this._dataMin=n[0],this._dataMax=n[1];var a=this._isOrdinal=e.type==="ordinal";this._needCrossZero=e.type==="interval"&&t.getNeedCrossZero&&t.getNeedCrossZero();var i=this._modelMinRaw=t.get("min",!0);ye(i)?this._modelMinNum=xp(e,i({min:n[0],max:n[1]})):i!=="dataMin"&&(this._modelMinNum=xp(e,i));var o=this._modelMaxRaw=t.get("max",!0);if(ye(o)?this._modelMaxNum=xp(e,o({min:n[0],max:n[1]})):o!=="dataMax"&&(this._modelMaxNum=xp(e,o)),a)this._axisDataLen=t.getCategories().length;else{var s=t.get("boundaryGap"),l=J(s)?s:[s||0,s||0];typeof l[0]=="boolean"||typeof l[1]=="boolean"?this._boundaryGapInner=[0,0]:this._boundaryGapInner=[va(l[0],1),va(l[1],1)]}},r.prototype.calculate=function(){var e=this._isOrdinal,t=this._dataMin,n=this._dataMax,a=this._axisDataLen,i=this._boundaryGapInner,o=e?null:n-t||Math.abs(t),s=this._modelMinRaw==="dataMin"?t:this._modelMinNum,l=this._modelMaxRaw==="dataMax"?n:this._modelMaxNum,u=s!=null,c=l!=null;s==null&&(s=e?a?0:NaN:t-i[0]*o),l==null&&(l=e?a?a-1:NaN:n+i[1]*o),(s==null||!isFinite(s))&&(s=NaN),(l==null||!isFinite(l))&&(l=NaN);var f=El(s)||El(l)||e&&!a;this._needCrossZero&&(s>0&&l>0&&!u&&(s=0),s<0&&l<0&&!c&&(l=0));var h=this._determinedMin,v=this._determinedMax;return h!=null&&(s=h,u=!0),v!=null&&(l=v,c=!0),{min:s,max:l,minFixed:u,maxFixed:c,isBlank:f}},r.prototype.modifyDataMinMax=function(e,t){this[mQ[e]]=t},r.prototype.setDeterminedMinMax=function(e,t){var n=yQ[e];this[n]=t},r.prototype.freeze=function(){this.frozen=!0},r}(),yQ={min:"_determinedMin",max:"_determinedMax"},mQ={min:"_dataMin",max:"_dataMax"};function a2(r,e,t){var n=r.rawExtentInfo;return n||(n=new gQ(r,e,t),r.rawExtentInfo=n,n)}function xp(r,e){return e==null?null:El(e)?NaN:r.parse(e)}function i2(r,e){var t=r.type,n=a2(r,e,r.getExtent()).calculate();r.setBlank(n.isBlank);var a=n.min,i=n.max,o=e.ecModel;if(o&&t==="time"){var s=UL("bar",o),l=!1;if(C(s,function(f){l=l||f.getBaseAxis()===e.axis}),l){var u=YL(s),c=_Q(a,i,e,u);a=c.min,i=c.max}}return{extent:[a,i],fixMin:n.minFixed,fixMax:n.maxFixed}}function _Q(r,e,t,n){var a=t.axis.getExtent(),i=a[1]-a[0],o=rQ(n,t.axis);if(o===void 0)return{min:r,max:e};var s=1/0;C(o,function(v){s=Math.min(v.offset,s)});var l=-1/0;C(o,function(v){l=Math.max(v.offset+v.width,l)}),s=Math.abs(s),l=Math.abs(l);var u=s+l,c=e-r,f=1-(s+l)/i,h=c/f-c;return e+=h*(l/u),r-=h*(s/u),{min:r,max:e}}function Ps(r,e){var t=e,n=i2(r,t),a=n.extent,i=t.get("splitNumber");r instanceof pQ&&(r.base=t.get("logBase"));var o=r.type,s=t.get("interval"),l=o==="interval"||o==="time";r.setExtent(a[0],a[1]),r.calcNiceExtent({splitNumber:i,fixMin:n.fixMin,fixMax:n.fixMax,minInterval:l?t.get("minInterval"):null,maxInterval:l?t.get("maxInterval"):null}),s!=null&&r.setInterval&&r.setInterval(s)}function kf(r,e){if(e=e||r.get("type"),e)switch(e){case"category":return new k_({ordinalMeta:r.getOrdinalMeta?r.getOrdinalMeta():r.getCategories(),extent:[1/0,-1/0]});case"time":return new t2({locale:r.ecModel.getLocaleModel(),useUTC:r.ecModel.get("useUTC")});default:return new(wi.getClass(e)||_o)}}function bQ(r){var e=r.scale.getExtent(),t=e[0],n=e[1];return!(t>0&&n>0||t<0&&n<0)}function Rf(r){var e=r.getLabelModel().get("formatter"),t=r.type==="category"?r.scale.getExtent()[0]:null;return r.scale.type==="time"?function(n){return function(a,i){return r.scale.getFormattedLabel(a,i,n)}}(e):ce(e)?function(n){return function(a){var i=r.scale.getLabel(a),o=n.replace("{value}",i!=null?i:"");return o}}(e):ye(e)?function(n){return function(a,i){return t!=null&&(i=a.value-t),n(V_(r,a),i,a.level!=null?{level:a.level}:null)}}(e):function(n){return r.scale.getLabel(n)}}function V_(r,e){return r.type==="category"?r.scale.getLabel(e):e.value}function MQ(r){var e=r.model,t=r.scale;if(!(!e.get(["axisLabel","show"])||t.isBlank())){var n,a,i=t.getExtent();t instanceof k_?a=t.count():(n=t.getTicks(),a=n.length);var o=r.getLabelModel(),s=Rf(r),l,u=1;a>40&&(u=Math.ceil(a/40));for(var c=0;c<a;c+=u){var f=n?n[c]:{value:i[0]+c},h=s(f,c),v=o.getTextRect(h),d=xQ(v,o.get("rotate")||0);l?l.union(d):l=d}return l}}function xQ(r,e){var t=e*Math.PI/180,n=r.width,a=r.height,i=n*Math.abs(Math.cos(t))+Math.abs(a*Math.sin(t)),o=n*Math.abs(Math.sin(t))+Math.abs(a*Math.cos(t)),s=new Pe(r.x,r.y,i,o);return s}function H_(r){var e=r.get("interval");return e==null?"auto":e}function o2(r){return r.type==="category"&&H_(r.getLabelModel())===0}function wp(r,e){var t={};return C(r.mapDimensionsAll(e),function(n){t[E_(r,n)]=!0}),Fe(t)}function wQ(r,e,t){e&&C(wp(e,t),function(n){var a=e.getApproximateExtent(n);a[0]<r[0]&&(r[0]=a[0]),a[1]>r[1]&&(r[1]=a[1])})}var Mu=function(){function r(){}return r.prototype.getNeedCrossZero=function(){var e=this.option;return!e.scale},r.prototype.getCoordSysModel=function(){},r}();function DQ(r){return Ua(null,r)}var SQ={isDimensionStacked:xi,enableDataStack:BL,getStackedDimension:E_};function IQ(r,e){var t=e;e instanceof ft||(t=new ft(e));var n=kf(t);return n.setExtent(r[0],r[1]),Ps(n,t),n}function TQ(r){Et(r,Mu)}function AQ(r,e){return e=e||{},yt(r,null,null,e.state!=="normal")}var CQ=Object.freeze(Object.defineProperty({__proto__:null,createList:DQ,getLayoutRect:Yt,dataStack:SQ,createScale:IQ,mixinAxisModelCommonMethods:TQ,getECData:Te,createTextStyle:AQ,createDimensions:kY,createSymbol:Ft,enableHoverEmphasis:oo},Symbol.toStringTag,{value:"Module"})),NQ=1e-8;function s2(r,e){return Math.abs(r-e)<NQ}function zs(r,e,t){var n=0,a=r[0];if(!a)return!1;for(var i=1;i<r.length;i++){var o=r[i];n+=gi(a[0],a[1],o[0],o[1],e,t),a=o}var s=r[0];return(!s2(a[0],s[0])||!s2(a[1],s[1]))&&(n+=gi(a[0],a[1],s[0],s[1],e,t)),n!==0}var LQ=[];function W_(r,e){for(var t=0;t<r.length;t++)vr(r[t],r[t],e)}function l2(r,e,t,n){for(var a=0;a<r.length;a++){var i=r[a];n&&(i=n.project(i)),i&&isFinite(i[0])&&isFinite(i[1])&&(ci(e,e,i),fi(t,t,i))}}function EQ(r){for(var e=0,t=0,n=0,a=r.length,i=r[a-1][0],o=r[a-1][1],s=0;s<a;s++){var l=r[s][0],u=r[s][1],c=i*u-l*o;e+=c,t+=(i+l)*c,n+=(o+u)*c,i=l,o=u}return e?[t/e/3,n/e/3,e]:[r[0][0]||0,r[0][1]||0]}var u2=function(){function r(e){this.name=e}return r.prototype.setCenter=function(e){this._center=e},r.prototype.getCenter=function(){var e=this._center;return e||(e=this._center=this.calcCenter()),e},r}(),c2=function(){function r(e,t){this.type="polygon",this.exterior=e,this.interiors=t}return r}(),f2=function(){function r(e){this.type="linestring",this.points=e}return r}(),h2=function(r){U(e,r);function e(t,n,a){var i=r.call(this,t)||this;return i.type="geoJSON",i.geometries=n,i._center=a&&[a[0],a[1]],i}return e.prototype.calcCenter=function(){for(var t=this.geometries,n,a=0,i=0;i<t.length;i++){var o=t[i],s=o.exterior,l=s&&s.length;l>a&&(n=o,a=l)}if(n)return EQ(n.exterior);var u=this.getBoundingRect();return[u.x+u.width/2,u.y+u.height/2]},e.prototype.getBoundingRect=function(t){var n=this._rect;if(n&&!t)return n;var a=[1/0,1/0],i=[-1/0,-1/0],o=this.geometries;return C(o,function(s){s.type==="polygon"?l2(s.exterior,a,i,t):C(s.points,function(l){l2(l,a,i,t)})}),isFinite(a[0])&&isFinite(a[1])&&isFinite(i[0])&&isFinite(i[1])||(a[0]=a[1]=i[0]=i[1]=0),n=new Pe(a[0],a[1],i[0]-a[0],i[1]-a[1]),t||(this._rect=n),n},e.prototype.contain=function(t){var n=this.getBoundingRect(),a=this.geometries;if(!n.contain(t[0],t[1]))return!1;e:for(var i=0,o=a.length;i<o;i++){var s=a[i];if(s.type==="polygon"){var l=s.exterior,u=s.interiors;if(zs(l,t[0],t[1])){for(var c=0;c<(u?u.length:0);c++)if(zs(u[c],t[0],t[1]))continue e;return!0}}}return!1},e.prototype.transformTo=function(t,n,a,i){var o=this.getBoundingRect(),s=o.width/o.height;a?i||(i=a/s):a=s*i;for(var l=new Pe(t,n,a,i),u=o.calculateTransform(l),c=this.geometries,f=0;f<c.length;f++){var h=c[f];h.type==="polygon"?(W_(h.exterior,u),C(h.interiors,function(v){W_(v,u)})):C(h.points,function(v){W_(v,u)})}o=this._rect,o.copy(l),this._center=[o.x+o.width/2,o.y+o.height/2]},e.prototype.cloneShallow=function(t){t==null&&(t=this.name);var n=new e(t,this.geometries,this._center);return n._rect=this._rect,n.transformTo=null,n},e}(u2),OQ=function(r){U(e,r);function e(t,n){var a=r.call(this,t)||this;return a.type="geoSVG",a._elOnlyForCalculate=n,a}return e.prototype.calcCenter=function(){for(var t=this._elOnlyForCalculate,n=t.getBoundingRect(),a=[n.x+n.width/2,n.y+n.height/2],i=xc(LQ),o=t;o&&!o.isGeoSVGGraphicRoot;)Pa(i,o.getLocalTransform(),i),o=o.parent;return Qo(i,i),vr(a,a,i),a},e}(u2);function PQ(r){if(!r.UTF8Encoding)return r;var e=r,t=e.UTF8Scale;t==null&&(t=1024);var n=e.features;return C(n,function(a){var i=a.geometry,o=i.encodeOffsets,s=i.coordinates;if(!!o)switch(i.type){case"LineString":i.coordinates=v2(s,o,t);break;case"Polygon":G_(s,o,t);break;case"MultiLineString":G_(s,o,t);break;case"MultiPolygon":C(s,function(l,u){return G_(l,o[u],t)})}}),e.UTF8Encoding=!1,e}function G_(r,e,t){for(var n=0;n<r.length;n++)r[n]=v2(r[n],e[n],t)}function v2(r,e,t){for(var n=[],a=e[0],i=e[1],o=0;o<r.length;o+=2){var s=r.charCodeAt(o)-64,l=r.charCodeAt(o+1)-64;s=s>>1^-(s&1),l=l>>1^-(l&1),s+=a,l+=i,a=s,i=l,n.push([s/t,l/t])}return n}function $_(r,e){return r=PQ(r),K(ot(r.features,function(t){return t.geometry&&t.properties&&t.geometry.coordinates.length>0}),function(t){var n=t.properties,a=t.geometry,i=[];switch(a.type){case"Polygon":var o=a.coordinates;i.push(new c2(o[0],o.slice(1)));break;case"MultiPolygon":C(a.coordinates,function(l){l[0]&&i.push(new c2(l[0],l.slice(1)))});break;case"LineString":i.push(new f2([a.coordinates]));break;case"MultiLineString":i.push(new f2(a.coordinates))}var s=new h2(n[e||"name"],i,n.cp);return s.properties=n,s})}var zQ=Object.freeze(Object.defineProperty({__proto__:null,linearMap:st,round:Nt,asc:bn,getPrecision:da,getPrecisionSafe:ZI,getPixelPrecision:w0,getPercentWithPrecision:UH,MAX_SAFE_INTEGER:D0,remRadian:S0,isRadianAroundZero:Fc,parseDate:Mn,quantity:XI,quantityExponent:td,nice:I0,quantile:rd,reformIntervals:T0,isNumeric:A0,numericToNumber:Ra},Symbol.toStringTag,{value:"Module"})),kQ=Object.freeze(Object.defineProperty({__proto__:null,parse:Mn,format:vf},Symbol.toStringTag,{value:"Module"})),RQ=Object.freeze(Object.defineProperty({__proto__:null,extendShape:PA,extendPath:zA,makePath:of,makeImage:v1,mergePath:xn,resizePath:d1,createIcon:Kl,updateProps:Qe,initProps:Dt,getTransform:lo,clipPointsByRect:p1,clipRectByRect:jA,registerShape:Vn,getShapeClass:Td,Group:De,Image:pr,Text:Ge,Circle:pa,Ellipse:md,Sector:Zr,Ring:rf,Polygon:qr,Polyline:Xr,Rect:We,Line:or,BezierCurve:nf,Arc:bd,IncrementalDisplayable:LA,CompoundPath:Md,LinearGradient:Zl,RadialGradient:c1,BoundingRect:Pe},Symbol.toStringTag,{value:"Module"})),jQ=Object.freeze(Object.defineProperty({__proto__:null,addCommas:A1,toCamelCase:C1,normalizeCssArray:xs,encodeHTML:$r,formatTpl:E1,getTooltipMarker:cC,formatTime:A$,capitalFirst:C$,truncateText:vT,getTextRect:I$},Symbol.toStringTag,{value:"Module"})),BQ=Object.freeze(Object.defineProperty({__proto__:null,map:K,each:C,indexOf:ze,inherits:Tm,reduce:On,filter:ot,bind:fe,curry:Ae,isArray:J,isString:ce,isObject:_e,isFunction:ye,extend:X,defaults:me,clone:Me,merge:Ne},Symbol.toStringTag,{value:"Module"})),jf=Ye();function FQ(r){return r.type==="category"?HQ(r):GQ(r)}function VQ(r,e){return r.type==="category"?WQ(r,e):{ticks:K(r.scale.getTicks(),function(t){return t.value})}}function HQ(r){var e=r.getLabelModel(),t=d2(r,e);return!e.get("show")||r.scale.isBlank()?{labels:[],labelCategoryInterval:t.labelCategoryInterval}:t}function d2(r,e){var t=p2(r,"labels"),n=H_(e),a=g2(t,n);if(a)return a;var i,o;return ye(n)?i=_2(r,n):(o=n==="auto"?$Q(r):n,i=m2(r,o)),y2(t,n,{labels:i,labelCategoryInterval:o})}function WQ(r,e){var t=p2(r,"ticks"),n=H_(e),a=g2(t,n);if(a)return a;var i,o;if((!e.get("show")||r.scale.isBlank())&&(i=[]),ye(n))i=_2(r,n,!0);else if(n==="auto"){var s=d2(r,r.getLabelModel());o=s.labelCategoryInterval,i=K(s.labels,function(l){return l.tickValue})}else o=n,i=m2(r,o,!0);return y2(t,n,{ticks:i,tickCategoryInterval:o})}function GQ(r){var e=r.scale.getTicks(),t=Rf(r);return{labels:K(e,function(n,a){return{level:n.level,formattedLabel:t(n,a),rawLabel:r.scale.getLabel(n),tickValue:n.value}})}}function p2(r,e){return jf(r)[e]||(jf(r)[e]=[])}function g2(r,e){for(var t=0;t<r.length;t++)if(r[t].key===e)return r[t].value}function y2(r,e,t){return r.push({key:e,value:t}),t}function $Q(r){var e=jf(r).autoInterval;return e!=null?e:jf(r).autoInterval=r.calculateCategoryInterval()}function UQ(r){var e=YQ(r),t=Rf(r),n=(e.axisRotate-e.labelRotate)/180*Math.PI,a=r.scale,i=a.getExtent(),o=a.count();if(i[1]-i[0]<1)return 0;var s=1;o>40&&(s=Math.max(1,Math.floor(o/40)));for(var l=i[0],u=r.dataToCoord(l+1)-r.dataToCoord(l),c=Math.abs(u*Math.cos(n)),f=Math.abs(u*Math.sin(n)),h=0,v=0;l<=i[1];l+=s){var d=0,p=0,g=jc(t({value:l}),e.font,"center","top");d=g.width*1.3,p=g.height*1.3,h=Math.max(h,d,7),v=Math.max(v,p,7)}var y=h/c,m=v/f;isNaN(y)&&(y=1/0),isNaN(m)&&(m=1/0);var _=Math.max(0,Math.floor(Math.min(y,m))),b=jf(r.model),x=r.getExtent(),M=b.lastAutoInterval,w=b.lastTickCount;return M!=null&&w!=null&&Math.abs(M-_)<=1&&Math.abs(w-o)<=1&&M>_&&b.axisExtent0===x[0]&&b.axisExtent1===x[1]?_=M:(b.lastTickCount=o,b.lastAutoInterval=_,b.axisExtent0=x[0],b.axisExtent1=x[1]),_}function YQ(r){var e=r.getLabelModel();return{axisRotate:r.getRotate?r.getRotate():r.isHorizontal&&!r.isHorizontal()?90:0,labelRotate:e.get("rotate")||0,font:e.getFont()}}function m2(r,e,t){var n=Rf(r),a=r.scale,i=a.getExtent(),o=r.getLabelModel(),s=[],l=Math.max((e||0)+1,1),u=i[0],c=a.count();u!==0&&l>1&&c/l>2&&(u=Math.round(Math.ceil(u/l)*l));var f=o2(r),h=o.get("showMinLabel")||f,v=o.get("showMaxLabel")||f;h&&u!==i[0]&&p(i[0]);for(var d=u;d<=i[1];d+=l)p(d);v&&d-l!==i[1]&&p(i[1]);function p(g){var y={value:g};s.push(t?g:{formattedLabel:n(y),rawLabel:a.getLabel(y),tickValue:g})}return s}function _2(r,e,t){var n=r.scale,a=Rf(r),i=[];return C(n.getTicks(),function(o){var s=n.getLabel(o),l=o.value;e(o.value,s)&&i.push(t?l:{formattedLabel:a(o),rawLabel:s,tickValue:l})}),i}var b2=[0,1],QQ=function(){function r(e,t,n){this.onBand=!1,this.inverse=!1,this.dim=e,this.scale=t,this._extent=n||[0,0]}return r.prototype.contain=function(e){var t=this._extent,n=Math.min(t[0],t[1]),a=Math.max(t[0],t[1]);return e>=n&&e<=a},r.prototype.containData=function(e){return this.scale.contain(e)},r.prototype.getExtent=function(){return this._extent.slice()},r.prototype.getPixelPrecision=function(e){return w0(e||this.scale.getExtent(),this._extent)},r.prototype.setExtent=function(e,t){var n=this._extent;n[0]=e,n[1]=t},r.prototype.dataToCoord=function(e,t){var n=this._extent,a=this.scale;return e=a.normalize(e),this.onBand&&a.type==="ordinal"&&(n=n.slice(),M2(n,a.count())),st(e,b2,n,t)},r.prototype.coordToData=function(e,t){var n=this._extent,a=this.scale;this.onBand&&a.type==="ordinal"&&(n=n.slice(),M2(n,a.count()));var i=st(e,n,b2,t);return this.scale.scale(i)},r.prototype.pointToData=function(e,t){},r.prototype.getTicksCoords=function(e){e=e||{};var t=e.tickModel||this.getTickModel(),n=VQ(this,t),a=n.ticks,i=K(a,function(s){return{coord:this.dataToCoord(this.scale.type==="ordinal"?this.scale.getRawOrdinalNumber(s):s),tickValue:s}},this),o=t.get("alignWithLabel");return ZQ(this,i,o,e.clamp),i},r.prototype.getMinorTicksCoords=function(){if(this.scale.type==="ordinal")return[];var e=this.model.getModel("minorTick"),t=e.get("splitNumber");t>0&&t<100||(t=5);var n=this.scale.getMinorTicks(t),a=K(n,function(i){return K(i,function(o){return{coord:this.dataToCoord(o),tickValue:o}},this)},this);return a},r.prototype.getViewLabels=function(){return FQ(this).labels},r.prototype.getLabelModel=function(){return this.model.getModel("axisLabel")},r.prototype.getTickModel=function(){return this.model.getModel("axisTick")},r.prototype.getBandWidth=function(){var e=this._extent,t=this.scale.getExtent(),n=t[1]-t[0]+(this.onBand?1:0);n===0&&(n=1);var a=Math.abs(e[1]-e[0]);return Math.abs(a)/n},r.prototype.calculateCategoryInterval=function(){return UQ(this)},r}();function M2(r,e){var t=r[1]-r[0],n=e,a=t/n/2;r[0]+=a,r[1]-=a}function ZQ(r,e,t,n){var a=e.length;if(!r.onBand||t||!a)return;var i=r.getExtent(),o,s;if(a===1)e[0].coord=i[0],o=e[1]={coord:i[0]};else{var l=e[a-1].tickValue-e[0].tickValue,u=(e[a-1].coord-e[0].coord)/l;C(e,function(v){v.coord-=u/2});var c=r.scale.getExtent();s=1+c[1]-e[a-1].tickValue,o={coord:e[a-1].coord+u*s},e.push(o)}var f=i[0]>i[1];h(e[0].coord,i[0])&&(n?e[0].coord=i[0]:e.shift()),n&&h(i[0],e[0].coord)&&e.unshift({coord:i[0]}),h(i[1],o.coord)&&(n?o.coord=i[1]:e.pop()),n&&h(o.coord,i[1])&&e.push({coord:i[1]});function h(v,d){return v=Nt(v),d=Nt(d),f?v>d:v<d}}var Yn=QQ;function qQ(r){var e=He.extend(r);return He.registerClass(e),e}function XQ(r){var e=St.extend(r);return St.registerClass(e),e}function JQ(r){var e=bt.extend(r);return bt.registerClass(e),e}function KQ(r){var e=ht.extend(r);return ht.registerClass(e),e}var Bf=Math.PI*2,ks=Ha.CMD,e8=["top","right","bottom","left"];function t8(r,e,t,n,a){var i=t.width,o=t.height;switch(r){case"top":n.set(t.x+i/2,t.y-e),a.set(0,-1);break;case"bottom":n.set(t.x+i/2,t.y+o+e),a.set(0,1);break;case"left":n.set(t.x-e,t.y+o/2),a.set(-1,0);break;case"right":n.set(t.x+i+e,t.y+o/2),a.set(1,0);break}}function r8(r,e,t,n,a,i,o,s,l){o-=r,s-=e;var u=Math.sqrt(o*o+s*s);o/=u,s/=u;var c=o*t+r,f=s*t+e;if(Math.abs(n-a)%Bf<1e-4)return l[0]=c,l[1]=f,u-t;if(i){var h=n;n=ao(a),a=ao(h)}else n=ao(n),a=ao(a);n>a&&(a+=Bf);var v=Math.atan2(s,o);if(v<0&&(v+=Bf),v>=n&&v<=a||v+Bf>=n&&v+Bf<=a)return l[0]=c,l[1]=f,u-t;var d=t*Math.cos(n)+r,p=t*Math.sin(n)+e,g=t*Math.cos(a)+r,y=t*Math.sin(a)+e,m=(d-o)*(d-o)+(p-s)*(p-s),_=(g-o)*(g-o)+(y-s)*(y-s);return m<_?(l[0]=d,l[1]=p,Math.sqrt(m)):(l[0]=g,l[1]=y,Math.sqrt(_))}function Dp(r,e,t,n,a,i,o,s){var l=a-r,u=i-e,c=t-r,f=n-e,h=Math.sqrt(c*c+f*f);c/=h,f/=h;var v=l*c+u*f,d=v/h;s&&(d=Math.min(Math.max(d,0),1)),d*=h;var p=o[0]=r+d*c,g=o[1]=e+d*f;return Math.sqrt((p-a)*(p-a)+(g-i)*(g-i))}function x2(r,e,t,n,a,i,o){t<0&&(r=r+t,t=-t),n<0&&(e=e+n,n=-n);var s=r+t,l=e+n,u=o[0]=Math.min(Math.max(a,r),s),c=o[1]=Math.min(Math.max(i,e),l);return Math.sqrt((u-a)*(u-a)+(c-i)*(c-i))}var wa=[];function n8(r,e,t){var n=x2(e.x,e.y,e.width,e.height,r.x,r.y,wa);return t.set(wa[0],wa[1]),n}function a8(r,e,t){for(var n=0,a=0,i=0,o=0,s,l,u=1/0,c=e.data,f=r.x,h=r.y,v=0;v<c.length;){var d=c[v++];v===1&&(n=c[v],a=c[v+1],i=n,o=a);var p=u;switch(d){case ks.M:i=c[v++],o=c[v++],n=i,a=o;break;case ks.L:p=Dp(n,a,c[v],c[v+1],f,h,wa,!0),n=c[v++],a=c[v++];break;case ks.C:p=gI(n,a,c[v++],c[v++],c[v++],c[v++],c[v],c[v+1],f,h,wa),n=c[v++],a=c[v++];break;case ks.Q:p=mI(n,a,c[v++],c[v++],c[v],c[v+1],f,h,wa),n=c[v++],a=c[v++];break;case ks.A:var g=c[v++],y=c[v++],m=c[v++],_=c[v++],b=c[v++],x=c[v++];v+=1;var M=!!(1-c[v++]);s=Math.cos(b)*m+g,l=Math.sin(b)*_+y,v<=1&&(i=s,o=l);var w=(f-g)*_/m+g;p=r8(g,y,_,b,b+x,M,w,h,wa),n=Math.cos(b+x)*m+g,a=Math.sin(b+x)*_+y;break;case ks.R:i=n=c[v++],o=a=c[v++];var D=c[v++],T=c[v++];p=x2(i,o,D,T,f,h,wa);break;case ks.Z:p=Dp(n,a,i,o,f,h,wa,!0),n=i,a=o;break}p<u&&(u=p,t.set(wa[0],wa[1]))}return u}var Da=new Oe,Mt=new Oe,Vt=new Oe,Qa=new Oe,Za=new Oe;function w2(r,e){if(!!r){var t=r.getTextGuideLine(),n=r.getTextContent();if(!!(n&&t)){var a=r.textGuideLineConfig||{},i=[[0,0],[0,0],[0,0]],o=a.candidates||e8,s=n.getBoundingRect().clone();s.applyTransform(n.getComputedTransform());var l=1/0,u=a.anchor,c=r.getComputedTransform(),f=c&&Qo([],c),h=e.get("length2")||0;u&&Vt.copy(u);for(var v=0;v<o.length;v++){var d=o[v];t8(d,0,s,Da,Qa),Oe.scaleAndAdd(Mt,Da,Qa,h),Mt.transform(f);var p=r.getBoundingRect(),g=u?u.distance(Mt):r instanceof je?a8(Mt,r.path,Vt):n8(Mt,p,Vt);g<l&&(l=g,Mt.transform(c),Vt.transform(c),Vt.toArray(i[0]),Mt.toArray(i[1]),Da.toArray(i[2]))}D2(i,e.get("minTurnAngle")),t.setShape({points:i})}}}var Sp=[],Kr=new Oe;function D2(r,e){if(e<=180&&e>0){e=e/180*Math.PI,Da.fromArray(r[0]),Mt.fromArray(r[1]),Vt.fromArray(r[2]),Oe.sub(Qa,Da,Mt),Oe.sub(Za,Vt,Mt);var t=Qa.len(),n=Za.len();if(!(t<.001||n<.001)){Qa.scale(1/t),Za.scale(1/n);var a=Qa.dot(Za),i=Math.cos(e);if(i<a){var o=Dp(Mt.x,Mt.y,Vt.x,Vt.y,Da.x,Da.y,Sp,!1);Kr.fromArray(Sp),Kr.scaleAndAdd(Za,o/Math.tan(Math.PI-e));var s=Vt.x!==Mt.x?(Kr.x-Mt.x)/(Vt.x-Mt.x):(Kr.y-Mt.y)/(Vt.y-Mt.y);if(isNaN(s))return;s<0?Oe.copy(Kr,Mt):s>1&&Oe.copy(Kr,Vt),Kr.toArray(r[1])}}}}function i8(r,e,t){if(t<=180&&t>0){t=t/180*Math.PI,Da.fromArray(r[0]),Mt.fromArray(r[1]),Vt.fromArray(r[2]),Oe.sub(Qa,Mt,Da),Oe.sub(Za,Vt,Mt);var n=Qa.len(),a=Za.len();if(!(n<.001||a<.001)){Qa.scale(1/n),Za.scale(1/a);var i=Qa.dot(e),o=Math.cos(t);if(i<o){var s=Dp(Mt.x,Mt.y,Vt.x,Vt.y,Da.x,Da.y,Sp,!1);Kr.fromArray(Sp);var l=Math.PI/2,u=Math.acos(Za.dot(e)),c=l+u-t;if(c>=l)Oe.copy(Kr,Vt);else{Kr.scaleAndAdd(Za,s/Math.tan(Math.PI/2-c));var f=Vt.x!==Mt.x?(Kr.x-Mt.x)/(Vt.x-Mt.x):(Kr.y-Mt.y)/(Vt.y-Mt.y);if(isNaN(f))return;f<0?Oe.copy(Kr,Mt):f>1&&Oe.copy(Kr,Vt)}Kr.toArray(r[1])}}}}function S2(r,e,t,n){var a=t==="normal",i=a?r:r.ensureState(t);i.ignore=e;var o=n.get("smooth");o&&o===!0&&(o=.3),i.shape=i.shape||{},o>0&&(i.shape.smooth=o);var s=n.getModel("lineStyle").getLineStyle();a?r.useStyle(s):i.style=s}function o8(r,e){var t=e.smooth,n=e.points;if(!!n)if(r.moveTo(n[0][0],n[0][1]),t>0&&n.length>=3){var a=ui(n[0],n[1]),i=ui(n[1],n[2]);if(!a||!i){r.lineTo(n[1][0],n[1][1]),r.lineTo(n[2][0],n[2][1]);return}var o=Math.min(a,i)*t,s=Mc([],n[1],n[0],o/a),l=Mc([],n[1],n[2],o/i),u=Mc([],s,l,.5);r.bezierCurveTo(s[0],s[1],s[0],s[1],u[0],u[1]),r.bezierCurveTo(l[0],l[1],l[0],l[1],n[2][0],n[2][1])}else for(var c=1;c<n.length;c++)r.lineTo(n[c][0],n[c][1])}function U_(r,e,t){var n=r.getTextGuideLine(),a=r.getTextContent();if(!a){n&&r.removeTextGuideLine();return}for(var i=e.normal,o=i.get("show"),s=a.ignore,l=0;l<Zc.length;l++){var u=Zc[l],c=e[u],f=u==="normal";if(c){var h=c.get("show"),v=f?s:Ee(a.states[u]&&a.states[u].ignore,s);if(v||!Ee(h,o)){var d=f?n:n&&n.states[u];d&&(d.ignore=!0);continue}n||(n=new Xr,r.setTextGuideLine(n),!f&&(s||!o)&&S2(n,!0,"normal",e.normal),r.stateProxy&&(n.stateProxy=r.stateProxy)),S2(n,!1,u,c)}}if(n){me(n.style,t),n.style.fill=null;var p=i.get("showAbove"),g=r.textGuideLineConfig=r.textGuideLineConfig||{};g.showAbove=p||!1,n.buildPath=o8}}function Y_(r,e){e=e||"labelLine";for(var t={normal:r.getModel(e)},n=0;n<Qr.length;n++){var a=Qr[n];t[a]=r.getModel([a,e])}return t}function I2(r){for(var e=[],t=0;t<r.length;t++){var n=r[t];if(!n.defaultAttr.ignore){var a=n.label,i=a.getComputedTransform(),o=a.getBoundingRect(),s=!i||i[1]<1e-5&&i[2]<1e-5,l=a.style.margin||0,u=o.clone();u.applyTransform(i),u.x-=l/2,u.y-=l/2,u.width+=l,u.height+=l;var c=s?new Dd(o,i):null;e.push({label:a,labelLine:n.labelLine,rect:u,localRect:o,obb:c,priority:n.priority,defaultAttr:n.defaultAttr,layoutOption:n.computedLayoutOption,axisAligned:s,transform:i})}}return e}function T2(r,e,t,n,a,i){var o=r.length;if(o<2)return;r.sort(function(D,T){return D.rect[e]-T.rect[e]});for(var s=0,l,u=!1,c=0,f=0;f<o;f++){var h=r[f],v=h.rect;l=v[e]-s,l<0&&(v[e]-=l,h.label[e]-=l,u=!0);var d=Math.max(-l,0);c+=d,s=v[e]+v[t]}c>0&&i&&x(-c/o,0,o);var p=r[0],g=r[o-1],y,m;_(),y<0&&M(-y,.8),m<0&&M(m,.8),_(),b(y,m,1),b(m,y,-1),_(),y<0&&w(-y),m<0&&w(m);function _(){y=p.rect[e]-n,m=a-g.rect[e]-g.rect[t]}function b(D,T,I){if(D<0){var A=Math.min(T,-D);if(A>0){x(A*I,0,o);var N=A+D;N<0&&M(-N*I,1)}else M(-D*I,1)}}function x(D,T,I){D!==0&&(u=!0);for(var A=T;A<I;A++){var N=r[A],L=N.rect;L[e]+=D,N.label[e]+=D}}function M(D,T){for(var I=[],A=0,N=1;N<o;N++){var L=r[N-1].rect,E=Math.max(r[N].rect[e]-L[e]-L[t],0);I.push(E),A+=E}if(!!A){var O=Math.min(Math.abs(D)/A,T);if(D>0)for(var N=0;N<o-1;N++){var P=I[N]*O;x(P,0,N+1)}else for(var N=o-1;N>0;N--){var P=I[N-1]*O;x(-P,N,o)}}}function w(D){var T=D<0?-1:1;D=Math.abs(D);for(var I=Math.ceil(D/(o-1)),A=0;A<o-1;A++)if(T>0?x(I,0,A+1):x(-I,o-A-1,o),D-=I,D<=0)return}return u}function s8(r,e,t,n){return T2(r,"x","width",e,t,n)}function A2(r,e,t,n){return T2(r,"y","height",e,t,n)}function C2(r){var e=[];r.sort(function(p,g){return g.priority-p.priority});var t=new Pe(0,0,0,0);function n(p){if(!p.ignore){var g=p.ensureState("emphasis");g.ignore==null&&(g.ignore=!1)}p.ignore=!0}for(var a=0;a<r.length;a++){var i=r[a],o=i.axisAligned,s=i.localRect,l=i.transform,u=i.label,c=i.labelLine;t.copy(i.rect),t.width-=.1,t.height-=.1,t.x+=.05,t.y+=.05;for(var f=i.obb,h=!1,v=0;v<e.length;v++){var d=e[v];if(!!t.intersect(d.rect)){if(o&&d.axisAligned){h=!0;break}if(d.obb||(d.obb=new Dd(d.localRect,d.transform)),f||(f=new Dd(s,l)),f.intersect(d.obb)){h=!0;break}}}h?(n(u),c&&n(c)):(u.attr("ignore",i.defaultAttr.ignore),c&&c.attr("ignore",i.defaultAttr.labelGuideIgnore),e.push(i))}}function l8(r){if(r){for(var e=[],t=0;t<r.length;t++)e.push(r[t].slice());return e}}function u8(r,e){var t=r.label,n=e&&e.getTextGuideLine();return{dataIndex:r.dataIndex,dataType:r.dataType,seriesIndex:r.seriesModel.seriesIndex,text:r.label.style.text,rect:r.hostRect,labelRect:r.rect,align:t.style.align,verticalAlign:t.style.verticalAlign,labelLinePoints:l8(n&&n.shape.points)}}var N2=["align","verticalAlign","width","height","fontSize"],wn=new di,Q_=Ye(),c8=Ye();function Ip(r,e,t){for(var n=0;n<t.length;n++){var a=t[n];e[a]!=null&&(r[a]=e[a])}}var Tp=["x","y","rotation"],f8=function(){function r(){this._labelList=[],this._chartViewList=[]}return r.prototype.clearLabels=function(){this._labelList=[],this._chartViewList=[]},r.prototype._addLabel=function(e,t,n,a,i){var o=a.style,s=a.__hostTarget,l=s.textConfig||{},u=a.getComputedTransform(),c=a.getBoundingRect().plain();Pe.applyTransform(c,c,u),u?wn.setLocalTransform(u):(wn.x=wn.y=wn.rotation=wn.originX=wn.originY=0,wn.scaleX=wn.scaleY=1);var f=a.__hostTarget,h;if(f){h=f.getBoundingRect().plain();var v=f.getComputedTransform();Pe.applyTransform(h,h,v)}var d=h&&f.getTextGuideLine();this._labelList.push({label:a,labelLine:d,seriesModel:n,dataIndex:e,dataType:t,layoutOption:i,computedLayoutOption:null,rect:c,hostRect:h,priority:h?h.width*h.height:0,defaultAttr:{ignore:a.ignore,labelGuideIgnore:d&&d.ignore,x:wn.x,y:wn.y,scaleX:wn.scaleX,scaleY:wn.scaleY,rotation:wn.rotation,style:{x:o.x,y:o.y,align:o.align,verticalAlign:o.verticalAlign,width:o.width,height:o.height,fontSize:o.fontSize},cursor:a.cursor,attachedPos:l.position,attachedRot:l.rotation}})},r.prototype.addLabelsOfSeries=function(e){var t=this;this._chartViewList.push(e);var n=e.__model,a=n.get("labelLayout");!(ye(a)||Fe(a).length)||e.group.traverse(function(i){if(i.ignore)return!0;var o=i.getTextContent(),s=Te(i);o&&!o.disableLabelLayout&&t._addLabel(s.dataIndex,s.dataType,n,o,a)})},r.prototype.updateLayoutConfig=function(e){var t=e.getWidth(),n=e.getHeight();function a(_,b){return function(){w2(_,b)}}for(var i=0;i<this._labelList.length;i++){var o=this._labelList[i],s=o.label,l=s.__hostTarget,u=o.defaultAttr,c=void 0;ye(o.layoutOption)?c=o.layoutOption(u8(o,l)):c=o.layoutOption,c=c||{},o.computedLayoutOption=c;var f=Math.PI/180;l&&l.setTextConfig({local:!1,position:c.x!=null||c.y!=null?null:u.attachedPos,rotation:c.rotate!=null?c.rotate*f:u.attachedRot,offset:[c.dx||0,c.dy||0]});var h=!1;if(c.x!=null?(s.x=ue(c.x,t),s.setStyle("x",0),h=!0):(s.x=u.x,s.setStyle("x",u.style.x)),c.y!=null?(s.y=ue(c.y,n),s.setStyle("y",0),h=!0):(s.y=u.y,s.setStyle("y",u.style.y)),c.labelLinePoints){var v=l.getTextGuideLine();v&&(v.setShape({points:c.labelLinePoints}),h=!1)}var d=Q_(s);d.needsUpdateLabelLine=h,s.rotation=c.rotate!=null?c.rotate*f:u.rotation,s.scaleX=u.scaleX,s.scaleY=u.scaleY;for(var p=0;p<N2.length;p++){var g=N2[p];s.setStyle(g,c[g]!=null?c[g]:u.style[g])}if(c.draggable){if(s.draggable=!0,s.cursor="move",l){var y=o.seriesModel;if(o.dataIndex!=null){var m=o.seriesModel.getData(o.dataType);y=m.getItemModel(o.dataIndex)}s.on("drag",a(l,y.getModel("labelLine")))}}else s.off("drag"),s.cursor=u.cursor}},r.prototype.layout=function(e){var t=e.getWidth(),n=e.getHeight(),a=I2(this._labelList),i=ot(a,function(l){return l.layoutOption.moveOverlap==="shiftX"}),o=ot(a,function(l){return l.layoutOption.moveOverlap==="shiftY"});s8(i,0,t),A2(o,0,n);var s=ot(a,function(l){return l.layoutOption.hideOverlap});C2(s)},r.prototype.processLabelsOverall=function(){var e=this;C(this._chartViewList,function(t){var n=t.__model,a=t.ignoreLabelLineUpdate,i=n.isAnimationEnabled();t.group.traverse(function(o){if(o.ignore&&!o.forceLabelAnimation)return!0;var s=!a,l=o.getTextContent();!s&&l&&(s=Q_(l).needsUpdateLabelLine),s&&e._updateLabelLine(o,n),i&&e._animateLabels(o,n)})})},r.prototype._updateLabelLine=function(e,t){var n=e.getTextContent(),a=Te(e),i=a.dataIndex;if(n&&i!=null){var o=t.getData(a.dataType),s=o.getItemModel(i),l={},u=o.getItemVisual(i,"style"),c=o.getVisual("drawType");l.stroke=u[c];var f=s.getModel("labelLine");U_(e,Y_(s),l),w2(e,f)}},r.prototype._animateLabels=function(e,t){var n=e.getTextContent(),a=e.getTextGuideLine();if(n&&(e.forceLabelAnimation||!n.ignore&&!n.invisible&&!e.disableLabelAnimation&&!Xl(e))){var i=Q_(n),o=i.oldLayout,s=Te(e),l=s.dataIndex,u={x:n.x,y:n.y,rotation:n.rotation},c=t.getData(s.dataType);if(o){n.attr(o);var h=e.prevStates;h&&(ze(h,"select")>=0&&n.attr(i.oldLayoutSelect),ze(h,"emphasis")>=0&&n.attr(i.oldLayoutEmphasis)),Qe(n,u,t,l)}else if(n.attr(u),!tu(n).valueAnimation){var f=Ee(n.style.opacity,1);n.style.opacity=0,Dt(n,{style:{opacity:f}},t,l)}if(i.oldLayout=u,n.states.select){var v=i.oldLayoutSelect={};Ip(v,u,Tp),Ip(v,n.states.select,Tp)}if(n.states.emphasis){var d=i.oldLayoutEmphasis={};Ip(d,u,Tp),Ip(d,n.states.emphasis,Tp)}QA(n,l,c,t,t)}if(a&&!a.ignore&&!a.invisible){var i=c8(a),o=i.oldLayout,p={points:a.shape.points};o?(a.attr({shape:o}),Qe(a,{shape:p},t)):(a.setShape(p),a.style.strokePercent=0,Dt(a,{style:{strokePercent:1}},t)),i.oldLayout=p}},r}(),h8=f8,Z_=Ye();function v8(r){r.registerUpdateLifecycle("series:beforeupdate",function(e,t,n){var a=Z_(t).labelManager;a||(a=Z_(t).labelManager=new h8),a.clearLabels()}),r.registerUpdateLifecycle("series:layoutlabels",function(e,t,n){var a=Z_(t).labelManager;n.updatedSeries.forEach(function(i){a.addLabelsOfSeries(t.getViewOfSeriesModel(i))}),a.updateLayoutConfig(t),a.layout(t),a.processLabelsOverall()})}var q_=Math.sin,X_=Math.cos,L2=Math.PI,Rs=Math.PI*2,d8=180/L2,p8=function(){function r(){}return r.prototype.reset=function(e){this._start=!0,this._d=[],this._str="",this._p=Math.pow(10,e||4)},r.prototype.moveTo=function(e,t){this._add("M",e,t)},r.prototype.lineTo=function(e,t){this._add("L",e,t)},r.prototype.bezierCurveTo=function(e,t,n,a,i,o){this._add("C",e,t,n,a,i,o)},r.prototype.quadraticCurveTo=function(e,t,n,a){this._add("Q",e,t,n,a)},r.prototype.arc=function(e,t,n,a,i,o){this.ellipse(e,t,n,n,0,a,i,o)},r.prototype.ellipse=function(e,t,n,a,i,o,s,l){var u=s-o,c=!l,f=Math.abs(u),h=eo(f-Rs)||(c?u>=Rs:-u>=Rs),v=u>0?u%Rs:u%Rs+Rs,d=!1;h?d=!0:eo(f)?d=!1:d=v>=L2==!!c;var p=e+n*X_(o),g=t+a*q_(o);this._start&&this._add("M",p,g);var y=Math.round(i*d8);if(h){var m=1/this._p,_=(c?1:-1)*(Rs-m);this._add("A",n,a,y,1,+c,e+n*X_(o+_),t+a*q_(o+_)),m>.01&&this._add("A",n,a,y,0,+c,p,g)}else{var b=e+n*X_(s),x=t+a*q_(s);this._add("A",n,a,y,+d,+c,b,x)}},r.prototype.rect=function(e,t,n,a){this._add("M",e,t),this._add("l",n,0),this._add("l",0,a),this._add("l",-n,0),this._add("Z")},r.prototype.closePath=function(){this._d.length>0&&this._add("Z")},r.prototype._add=function(e,t,n,a,i,o,s,l,u){for(var c=[],f=this._p,h=1;h<arguments.length;h++){var v=arguments[h];if(isNaN(v)){this._invalid=!0;return}c.push(Math.round(v*f)/f)}this._d.push(e+c.join(" ")),this._start=e==="Z"},r.prototype.generateStr=function(){this._str=this._invalid?"":this._d.join(""),this._d=[]},r.prototype.getStr=function(){return this._str},r}(),E2=p8,Ff="none",g8=Math.round;function y8(r){var e=r.fill;return e!=null&&e!==Ff}function m8(r){var e=r.stroke;return e!=null&&e!==Ff}var J_=["lineCap","miterLimit","lineJoin"],_8=K(J_,function(r){return"stroke-"+r.toLowerCase()});function b8(r,e,t,n){var a=e.opacity==null?1:e.opacity;if(t instanceof pr){r("opacity",a);return}if(y8(e)){var i=Pc(e.fill);r("fill",i.color);var o=e.fillOpacity!=null?e.fillOpacity*i.opacity*a:i.opacity*a;(n||o<1)&&r("fill-opacity",o)}else r("fill",Ff);if(m8(e)){var s=Pc(e.stroke);r("stroke",s.color);var l=e.strokeNoScale?t.getLineScale():1,u=l?(e.lineWidth||0)/l:0,c=e.strokeOpacity!=null?e.strokeOpacity*s.opacity*a:s.opacity*a,f=e.strokeFirst;if((n||u!==1)&&r("stroke-width",u),(n||f)&&r("paint-order",f?"stroke":"fill"),(n||c<1)&&r("stroke-opacity",c),e.lineDash){var h=o_(t),v=h[0],d=h[1];v&&(d=g8(d||0),r("stroke-dasharray",v.join(",")),(d||n)&&r("stroke-dashoffset",d))}else n&&r("stroke-dasharray",Ff);for(var p=0;p<J_.length;p++){var g=J_[p];if(n||e[g]!==cd[g]){var y=e[g]||cd[g];y&&r(_8[p],y)}}}else n&&r("stroke",Ff)}var O2="http://www.w3.org/2000/svg",P2="http://www.w3.org/1999/xlink",M8="http://www.w3.org/2000/xmlns/",x8="http://www.w3.org/XML/1998/namespace";function z2(r){return document.createElementNS(O2,r)}function ur(r,e,t,n,a){return{tag:r,attrs:t||{},children:n,text:a,key:e}}function w8(r,e){var t=[];if(e)for(var n in e){var a=e[n],i=n;a!==!1&&(a!==!0&&a!=null&&(i+='="'+a+'"'),t.push(i))}return"<"+r+" "+t.join(" ")+">"}function D8(r){return"</"+r+">"}function K_(r,e){e=e||{};var t=e.newline?`
|
|
237
|
+
`:"";function n(a){var i=a.children,o=a.tag,s=a.attrs;return w8(o,s)+$r(a.text)+(i?""+t+K(i,function(l){return n(l)}).join(t)+t:"")+D8(o)}return n(r)}function S8(r,e,t){t=t||{};var n=t.newline?`
|
|
238
|
+
`:"",a=" {"+n,i=n+"}",o=K(Fe(r),function(l){return l+a+K(Fe(r[l]),function(u){return u+":"+r[l][u]+";"}).join(n)+i}).join(n),s=K(Fe(e),function(l){return"@keyframes "+l+a+K(Fe(e[l]),function(u){return u+a+K(Fe(e[l][u]),function(c){var f=e[l][u][c];return c==="d"&&(f='path("'+f+'")'),c+":"+f+";"}).join(n)+i}).join(n)+i}).join(n);return!o&&!s?"":["<![CDATA[",o,s,"]]>"].join(n)}function eb(r){return{zrId:r,shadowCache:{},patternCache:{},gradientCache:{},clipPathCache:{},defs:{},cssNodes:{},cssAnims:{},cssClassIdx:0,cssAnimIdx:0,shadowIdx:0,gradientIdx:0,patternIdx:0,clipPathIdx:0}}function k2(r,e,t,n){return ur("svg","root",{width:r,height:e,xmlns:O2,"xmlns:xlink":P2,version:"1.1",baseProfile:"full",viewBox:n?"0 0 "+r+" "+e:!1},t)}var R2={cubicIn:"0.32,0,0.67,0",cubicOut:"0.33,1,0.68,1",cubicInOut:"0.65,0,0.35,1",quadraticIn:"0.11,0,0.5,0",quadraticOut:"0.5,1,0.89,1",quadraticInOut:"0.45,0,0.55,1",quarticIn:"0.5,0,0.75,0",quarticOut:"0.25,1,0.5,1",quarticInOut:"0.76,0,0.24,1",quinticIn:"0.64,0,0.78,0",quinticOut:"0.22,1,0.36,1",quinticInOut:"0.83,0,0.17,1",sinusoidalIn:"0.12,0,0.39,0",sinusoidalOut:"0.61,1,0.88,1",sinusoidalInOut:"0.37,0,0.63,1",exponentialIn:"0.7,0,0.84,0",exponentialOut:"0.16,1,0.3,1",exponentialInOut:"0.87,0,0.13,1",circularIn:"0.55,0,1,0.45",circularOut:"0,0.55,0.45,1",circularInOut:"0.85,0,0.15,1"},js="transform-origin";function I8(r,e,t){var n=X({},r.shape);X(n,e),r.buildPath(t,n);var a=new E2;return a.reset(TI(r)),t.rebuildPath(a,1),a.generateStr(),a.getStr()}function T8(r,e){var t=e.originX,n=e.originY;(t||n)&&(r[js]=t+"px "+n+"px")}var A8={fill:"fill",opacity:"opacity",lineWidth:"stroke-width",lineDashOffset:"stroke-dashoffset"};function j2(r,e){var t=e.zrId+"-ani-"+e.cssAnimIdx++;return e.cssAnims[t]=r,t}function C8(r,e,t){var n=r.shape.paths,a={},i,o;if(C(n,function(l){var u=eb(t.zrId);u.animation=!0,Ap(l,{},u,!0);var c=u.cssAnims,f=u.cssNodes,h=Fe(c),v=h.length;if(!!v){o=h[v-1];var d=c[o];for(var p in d){var g=d[p];a[p]=a[p]||{d:""},a[p].d+=g.d||""}for(var y in f){var m=f[y].animation;m.indexOf(o)>=0&&(i=m)}}}),!!i){e.d=!1;var s=j2(a,t);return i.replace(o,s)}}function B2(r){return ce(r)?R2[r]?"cubic-bezier("+R2[r]+")":Ym(r)?r:"":""}function Ap(r,e,t,n){var a=r.animators,i=a.length,o=[];if(r instanceof Md){var s=C8(r,e,t);if(s)o.push(s);else if(!i)return}else if(!i)return;for(var l={},u=0;u<i;u++){var c=a[u],f=[c.getMaxTime()/1e3+"s"],h=B2(c.getClip().easing),v=c.getDelay();h?f.push(h):f.push("linear"),v&&f.push(v/1e3+"s"),c.getLoop()&&f.push("infinite");var d=f.join(" ");l[d]=l[d]||[d,[]],l[d][1].push(c)}function p(m){var _=m[1],b=_.length,x={},M={},w={},D="animation-timing-function";function T(ie,he,k){for(var j=ie.getTracks(),W=ie.getMaxTime(),ae=0;ae<j.length;ae++){var re=j[ae];if(re.needsAnimate()){var ee=re.keyframes,se=re.propName;if(k&&(se=k(se)),se)for(var Le=0;Le<ee.length;Le++){var dt=ee[Le],pt=Math.round(dt.time/W*100)+"%",_t=B2(dt.easing),zt=dt.rawValue;(ce(zt)||Ue(zt))&&(he[pt]=he[pt]||{},he[pt][se]=dt.rawValue,_t&&(he[pt][D]=_t))}}}}for(var I=0;I<b;I++){var A=_[I],N=A.targetName;N?N==="shape"&&T(A,M):!n&&T(A,x)}for(var L in x){var E={};FI(E,r),X(E,x[L]);var O=AI(E),P=x[L][D];w[L]=O?{transform:O}:{},T8(w[L],E),P&&(w[L][D]=P)}var H,F=!0;for(var L in M){w[L]=w[L]||{};var G=!H,P=M[L][D];G&&(H=new Ha);var Z=H.len();H.reset(),w[L].d=I8(r,M[L],H);var te=H.len();if(!G&&Z!==te){F=!1;break}P&&(w[L][D]=P)}if(!F)for(var L in w)delete w[L].d;if(!n)for(var I=0;I<b;I++){var A=_[I],N=A.targetName;N==="style"&&T(A,w,function(j){return A8[j]})}for(var V=Fe(w),Y=!0,q,I=1;I<V.length;I++){var Q=V[I-1],ne=V[I];if(w[Q][js]!==w[ne][js]){Y=!1;break}q=w[Q][js]}if(Y&&q){for(var L in w)w[L][js]&&delete w[L][js];e[js]=q}if(ot(V,function(ie){return Fe(w[ie]).length>0}).length){var oe=j2(w,t);return oe+" "+m[0]+" both"}}for(var g in l){var s=p(l[g]);s&&o.push(s)}if(o.length){var y=t.zrId+"-cls-"+t.cssClassIdx++;t.cssNodes["."+y]={animation:o.join(",")},e.class=y}}var Vf=Math.round;function F2(r){return r&&ce(r.src)}function V2(r){return r&&ye(r.toDataURL)}function tb(r,e,t,n){b8(function(a,i){var o=a==="fill"||a==="stroke";o&&II(i)?Y2(e,r,a,n):o&&e0(i)?Q2(t,r,a,n):r[a]=i},e,t,!1),k8(t,r,n)}function H2(r){return eo(r[0]-1)&&eo(r[1])&&eo(r[2])&&eo(r[3]-1)}function N8(r){return eo(r[4])&&eo(r[5])}function rb(r,e,t){if(e&&!(N8(e)&&H2(e))){var n=t?10:1e4;r.transform=H2(e)?"translate("+Vf(e[4]*n)/n+" "+Vf(e[5]*n)/n+")":oH(e)}}function W2(r,e,t){for(var n=r.points,a=[],i=0;i<n.length;i++)a.push(Vf(n[i][0]*t)/t),a.push(Vf(n[i][1]*t)/t);e.points=a.join(" ")}function G2(r){return!r.smooth}function L8(r){var e=K(r,function(t){return typeof t=="string"?[t,t]:t});return function(t,n,a){for(var i=0;i<e.length;i++){var o=e[i],s=t[o[0]];s!=null&&(n[o[1]]=Vf(s*a)/a)}}}var E8={circle:[L8(["cx","cy","r"])],polyline:[W2,G2],polygon:[W2,G2]};function O8(r){for(var e=r.animators,t=0;t<e.length;t++)if(e[t].targetName==="shape")return!0;return!1}function $2(r,e){var t=r.style,n=r.shape,a=E8[r.type],i={},o=e.animation,s="path",l=r.style.strokePercent,u=e.compress&&TI(r)||4;if(a&&!e.willUpdate&&!(a[1]&&!a[1](n))&&!(o&&O8(r))&&!(l<1)){s=r.type;var c=Math.pow(10,u);a[0](n,i,c)}else{var f=!r.path||r.shapeChanged();r.path||r.createPathProxy();var h=r.path;f&&(h.beginPath(),r.buildPath(h,r.shape),r.pathUpdated());var v=h.getVersion(),d=r,p=d.__svgPathBuilder;(d.__svgPathVersion!==v||!p||l!==d.__svgPathStrokePercent)&&(p||(p=d.__svgPathBuilder=new E2),p.reset(u),h.rebuildPath(p,l),p.generateStr(),d.__svgPathVersion=v,d.__svgPathStrokePercent=l),i.d=p.getStr()}return rb(i,r.transform),tb(i,t,r,e),e.animation&&Ap(r,i,e),ur(s,r.id+"",i)}function P8(r,e){var t=r.style,n=t.image;if(n&&!ce(n)&&(F2(n)?n=n.src:V2(n)&&(n=n.toDataURL())),!!n){var a=t.x||0,i=t.y||0,o=t.width,s=t.height,l={href:n,width:o,height:s};return a&&(l.x=a),i&&(l.y=i),rb(l,r.transform),tb(l,t,r,e),e.animation&&Ap(r,l,e),ur("image",r.id+"",l)}}function z8(r,e){var t=r.style,n=t.text;if(n!=null&&(n+=""),!(!n||isNaN(t.x)||isNaN(t.y))){var a=t.font||$i,i=t.x||0,o=lH(t.y||0,Jv(a),t.textBaseline),s=sH[t.textAlign]||t.textAlign,l={"dominant-baseline":"central","text-anchor":s};if(RT(t)){var u="",c=t.fontStyle,f=zT(t.fontSize);if(!parseFloat(f))return;var h=t.fontFamily||PS,v=t.fontWeight;u+="font-size:"+f+";font-family:"+h+";",c&&c!=="normal"&&(u+="font-style:"+c+";"),v&&v!=="normal"&&(u+="font-weight:"+v+";"),l.style=u}else l.style="font: "+a;return n.match(/\s/)&&(l["xml:space"]="preserve"),i&&(l.x=i),o&&(l.y=o),rb(l,r.transform),tb(l,t,r,e),e.animation&&Ap(r,l,e),ur("text",r.id+"",l,void 0,n)}}function U2(r,e){if(r instanceof je)return $2(r,e);if(r instanceof pr)return P8(r,e);if(r instanceof Yc)return z8(r,e)}function k8(r,e,t){var n=r.style;if(uH(n)){var a=cH(r),i=t.shadowCache,o=i[a];if(!o){var s=r.getGlobalScale(),l=s[0],u=s[1];if(!l||!u)return;var c=n.shadowOffsetX||0,f=n.shadowOffsetY||0,h=n.shadowBlur,v=Pc(n.shadowColor),d=v.opacity,p=v.color,g=h/2/l,y=h/2/u,m=g+" "+y;o=t.zrId+"-s"+t.shadowIdx++,t.defs[o]=ur("filter",o,{id:o,x:"-100%",y:"-100%",width:"300%",height:"300%"},[ur("feDropShadow","",{dx:c/l,dy:f/u,stdDeviation:m,"flood-color":p,"flood-opacity":d})]),i[a]=o}e.filter=Gv(o)}}function Y2(r,e,t,n){var a=r[t],i,o={gradientUnits:a.global?"userSpaceOnUse":"objectBoundingBox"};if(DI(a))i="linearGradient",o.x1=a.x,o.y1=a.y,o.x2=a.x2,o.y2=a.y2;else if(SI(a))i="radialGradient",o.cx=Ee(a.x,.5),o.cy=Ee(a.y,.5),o.r=Ee(a.r,.5);else return;for(var s=a.colorStops,l=[],u=0,c=s.length;u<c;++u){var f=Km(s[u].offset)*100+"%",h=s[u].color,v=Pc(h),d=v.color,p=v.opacity,g={offset:f};g["stop-color"]=d,p<1&&(g["stop-opacity"]=p),l.push(ur("stop",u+"",g))}var y=ur(i,"",o,l),m=K_(y),_=n.gradientCache,b=_[m];b||(b=n.zrId+"-g"+n.gradientIdx++,_[m]=b,o.id=b,n.defs[b]=ur(i,b,o,l)),e[t]=Gv(b)}function Q2(r,e,t,n){var a=r.style[t],i=r.getBoundingRect(),o={},s=a.repeat,l=s==="no-repeat",u=s==="repeat-x",c=s==="repeat-y",f;if(wI(a)){var h=a.imageWidth,v=a.imageHeight,d=void 0,p=a.image;if(ce(p)?d=p:F2(p)?d=p.src:V2(p)&&(d=p.toDataURL()),typeof Image=="undefined"){var g="Image width/height must been given explictly in svg-ssr renderer.";Er(h,g),Er(v,g)}else if(h==null||v==null){var y=function(I,A){if(I){var N=I.elm,L=h||A.width,E=v||A.height;I.tag==="pattern"&&(u?(E=1,L/=i.width):c&&(L=1,E/=i.height)),I.attrs.width=L,I.attrs.height=E,N&&(N.setAttribute("width",L),N.setAttribute("height",E))}},m=P0(d,null,r,function(I){l||y(M,I),y(f,I)});m&&m.width&&m.height&&(h=h||m.width,v=v||m.height)}f=ur("image","img",{href:d,width:h,height:v}),o.width=h,o.height=v}else a.svgElement&&(f=Me(a.svgElement),o.width=a.svgWidth,o.height=a.svgHeight);if(!!f){var _,b;l?_=b=1:u?(b=1,_=o.width/i.width):c?(_=1,b=o.height/i.height):o.patternUnits="userSpaceOnUse",_!=null&&!isNaN(_)&&(o.width=_),b!=null&&!isNaN(b)&&(o.height=b);var x=AI(a);x&&(o.patternTransform=x);var M=ur("pattern","",o,[f]),w=K_(M),D=n.patternCache,T=D[w];T||(T=n.zrId+"-p"+n.patternIdx++,D[w]=T,o.id=T,M=n.defs[T]=ur("pattern",T,o,[f])),e[t]=Gv(T)}}function R8(r,e,t){var n=t.clipPathCache,a=t.defs,i=n[r.id];if(!i){i=t.zrId+"-c"+t.clipPathIdx++;var o={id:i};n[r.id]=i,a[i]=ur("clipPath",i,o,[$2(r,t)])}e["clip-path"]=Gv(i)}function Z2(r){return document.createTextNode(r)}function Bs(r,e,t){r.insertBefore(e,t)}function q2(r,e){r.removeChild(e)}function X2(r,e){r.appendChild(e)}function J2(r){return r.parentNode}function K2(r){return r.nextSibling}function nb(r,e){r.textContent=e}var eE=58,j8=120,B8=ur("","");function ab(r){return r===void 0}function qa(r){return r!==void 0}function F8(r,e,t){for(var n={},a=e;a<=t;++a){var i=r[a].key;i!==void 0&&(n[i]=a)}return n}function Hf(r,e){var t=r.key===e.key,n=r.tag===e.tag;return n&&t}function Wf(r){var e,t=r.children,n=r.tag;if(qa(n)){var a=r.elm=z2(n);if(ib(B8,r),J(t))for(e=0;e<t.length;++e){var i=t[e];i!=null&&X2(a,Wf(i))}else qa(r.text)&&!_e(r.text)&&X2(a,Z2(r.text))}else r.elm=Z2(r.text);return r.elm}function tE(r,e,t,n,a){for(;n<=a;++n){var i=t[n];i!=null&&Bs(r,Wf(i),e)}}function Cp(r,e,t,n){for(;t<=n;++t){var a=e[t];if(a!=null)if(qa(a.tag)){var i=J2(a.elm);q2(i,a.elm)}else q2(r,a.elm)}}function ib(r,e){var t,n=e.elm,a=r&&r.attrs||{},i=e.attrs||{};if(a!==i){for(t in i){var o=i[t],s=a[t];s!==o&&(o===!0?n.setAttribute(t,""):o===!1?n.removeAttribute(t):t.charCodeAt(0)!==j8?n.setAttribute(t,o):t==="xmlns:xlink"||t==="xmlns"?n.setAttributeNS(M8,t,o):t.charCodeAt(3)===eE?n.setAttributeNS(x8,t,o):t.charCodeAt(5)===eE?n.setAttributeNS(P2,t,o):n.setAttribute(t,o))}for(t in a)t in i||n.removeAttribute(t)}}function V8(r,e,t){for(var n=0,a=0,i=e.length-1,o=e[0],s=e[i],l=t.length-1,u=t[0],c=t[l],f,h,v,d;n<=i&&a<=l;)o==null?o=e[++n]:s==null?s=e[--i]:u==null?u=t[++a]:c==null?c=t[--l]:Hf(o,u)?(xu(o,u),o=e[++n],u=t[++a]):Hf(s,c)?(xu(s,c),s=e[--i],c=t[--l]):Hf(o,c)?(xu(o,c),Bs(r,o.elm,K2(s.elm)),o=e[++n],c=t[--l]):Hf(s,u)?(xu(s,u),Bs(r,s.elm,o.elm),s=e[--i],u=t[++a]):(ab(f)&&(f=F8(e,n,i)),h=f[u.key],ab(h)?Bs(r,Wf(u),o.elm):(v=e[h],v.tag!==u.tag?Bs(r,Wf(u),o.elm):(xu(v,u),e[h]=void 0,Bs(r,v.elm,o.elm))),u=t[++a]);(n<=i||a<=l)&&(n>i?(d=t[l+1]==null?null:t[l+1].elm,tE(r,d,t,a,l)):Cp(r,e,n,i))}function xu(r,e){var t=e.elm=r.elm,n=r.children,a=e.children;r!==e&&(ib(r,e),ab(e.text)?qa(n)&&qa(a)?n!==a&&V8(t,n,a):qa(a)?(qa(r.text)&&nb(t,""),tE(t,null,a,0,a.length-1)):qa(n)?Cp(t,n,0,n.length-1):qa(r.text)&&nb(t,""):r.text!==e.text&&(qa(n)&&Cp(t,n,0,n.length-1),nb(t,e.text)))}function H8(r,e){if(Hf(r,e))xu(r,e);else{var t=r.elm,n=J2(t);Wf(e),n!==null&&(Bs(n,e.elm,K2(t)),Cp(n,[r],0,0))}return e}var W8=0,G8=function(){function r(e,t,n){if(this.type="svg",this.refreshHover=rE(),this.configLayer=rE(),this.storage=t,this._opts=n=X({},n),this.root=e,this._id="zr"+W8++,this._oldVNode=k2(n.width,n.height),e&&!n.ssr){var a=this._viewport=document.createElement("div");a.style.cssText="position:relative;overflow:hidden";var i=this._svgDom=this._oldVNode.elm=z2("svg");ib(null,this._oldVNode),a.appendChild(i),e.appendChild(a)}this.resize(n.width,n.height)}return r.prototype.getType=function(){return this.type},r.prototype.getViewportRoot=function(){return this._viewport},r.prototype.getViewportRootOffset=function(){var e=this.getViewportRoot();if(e)return{offsetLeft:e.offsetLeft||0,offsetTop:e.offsetTop||0}},r.prototype.getSvgDom=function(){return this._svgDom},r.prototype.refresh=function(){if(this.root){var e=this.renderToVNode({willUpdate:!0});e.attrs.style="position:absolute;left:0;top:0;user-select:none",H8(this._oldVNode,e),this._oldVNode=e}},r.prototype.renderOneToVNode=function(e){return U2(e,eb(this._id))},r.prototype.renderToVNode=function(e){e=e||{};var t=this.storage.getDisplayList(!0),n=this._width,a=this._height,i=eb(this._id);i.animation=e.animation,i.willUpdate=e.willUpdate,i.compress=e.compress;var o=[],s=this._bgVNode=$8(n,a,this._backgroundColor,i);s&&o.push(s);var l=e.compress?null:this._mainVNode=ur("g","main",{},[]);this._paintList(t,i,l?l.children:o),l&&o.push(l);var u=K(Fe(i.defs),function(h){return i.defs[h]});if(u.length&&o.push(ur("defs","defs",{},u)),e.animation){var c=S8(i.cssNodes,i.cssAnims,{newline:!0});if(c){var f=ur("style","stl",{},[],c);o.push(f)}}return k2(n,a,o,e.useViewBox)},r.prototype.renderToString=function(e){return e=e||{},K_(this.renderToVNode({animation:Ee(e.cssAnimation,!0),willUpdate:!1,compress:!0,useViewBox:Ee(e.useViewBox,!0)}),{newline:!0})},r.prototype.setBackgroundColor=function(e){this._backgroundColor=e},r.prototype.getSvgRoot=function(){return this._mainVNode&&this._mainVNode.elm},r.prototype._paintList=function(e,t,n){for(var a=e.length,i=[],o=0,s,l,u=0,c=0;c<a;c++){var f=e[c];if(!f.invisible){var h=f.__clipPaths,v=h&&h.length||0,d=l&&l.length||0,p=void 0;for(p=Math.max(v-1,d-1);p>=0&&!(h&&l&&h[p]===l[p]);p--);for(var g=d-1;g>p;g--)o--,s=i[o-1];for(var y=p+1;y<v;y++){var m={};R8(h[y],m,t);var _=ur("g","clip-g-"+u++,m,[]);(s?s.children:n).push(_),i[o++]=_,s=_}l=h;var b=U2(f,t);b&&(s?s.children:n).push(b)}}},r.prototype.resize=function(e,t){var n=this._opts,a=this.root,i=this._viewport;if(e!=null&&(n.width=e),t!=null&&(n.height=t),a&&i&&(i.style.display="none",e=gu(a,0,n),t=gu(a,1,n),i.style.display=""),this._width!==e||this._height!==t){if(this._width=e,this._height=t,i){var o=i.style;o.width=e+"px",o.height=t+"px"}if(e0(this._backgroundColor))this.refresh();else{var s=this._svgDom;s&&(s.setAttribute("width",e),s.setAttribute("height",t));var l=this._bgVNode&&this._bgVNode.elm;l&&(l.setAttribute("width",e),l.setAttribute("height",t))}}},r.prototype.getWidth=function(){return this._width},r.prototype.getHeight=function(){return this._height},r.prototype.dispose=function(){this.root&&(this.root.innerHTML=""),this._svgDom=this._viewport=this.storage=this._oldVNode=this._bgVNode=this._mainVNode=null},r.prototype.clear=function(){this._svgDom&&(this._svgDom.innerHTML=null),this._oldVNode=null},r.prototype.toDataURL=function(e){var t=this.renderToString(),n="data:image/svg+xml;";return e?(t=hH(t),t&&n+"base64,"+t):n+"charset=UTF-8,"+encodeURIComponent(t)},r}();function rE(r){return function(){}}function $8(r,e,t,n){var a;if(t&&t!=="none")if(a=ur("rect","bg",{width:r,height:e,x:"0",y:"0",id:"0"}),II(t))Y2({fill:t},a.attrs,"fill",n);else if(e0(t))Q2({style:{fill:t},dirty:Ot,getBoundingRect:function(){return{width:r,height:e}}},a.attrs,"fill",n);else{var i=Pc(t),o=i.color,s=i.opacity;a.attrs.fill=o,s<1&&(a.attrs["fill-opacity"]=s)}return a}var U8=G8;function Y8(r){r.registerPainter("svg",U8)}function nE(r,e,t){var n=la.createCanvas(),a=e.getWidth(),i=e.getHeight(),o=n.style;return o&&(o.position="absolute",o.left="0",o.top="0",o.width=a+"px",o.height=i+"px",n.setAttribute("data-zr-dom-id",r)),n.width=a*t,n.height=i*t,n}var Q8=function(r){xt(e,r);function e(t,n,a){var i=r.call(this)||this;i.motionBlur=!1,i.lastFrameAlpha=.7,i.dpr=1,i.virtual=!1,i.config={},i.incremental=!1,i.zlevel=0,i.maxRepaintRectCount=5,i.__dirty=!0,i.__firstTimePaint=!0,i.__used=!1,i.__drawIndex=0,i.__startIndex=0,i.__endIndex=0,i.__prevStartIndex=null,i.__prevEndIndex=null;var o;a=a||Xv,typeof t=="string"?o=nE(t,n,a):_e(t)&&(o=t,t=o.id),i.id=t,i.dom=o;var s=o.style;return s&&(Cm(o),o.onselectstart=function(){return!1},s.padding="0",s.margin="0",s.borderWidth="0"),i.painter=n,i.dpr=a,i}return e.prototype.getElementCount=function(){return this.__endIndex-this.__startIndex},e.prototype.afterBrush=function(){this.__prevStartIndex=this.__startIndex,this.__prevEndIndex=this.__endIndex},e.prototype.initContext=function(){this.ctx=this.dom.getContext("2d"),this.ctx.dpr=this.dpr},e.prototype.setUnpainted=function(){this.__firstTimePaint=!0},e.prototype.createBackBuffer=function(){var t=this.dpr;this.domBack=nE("back-"+this.id,this.painter,t),this.ctxBack=this.domBack.getContext("2d"),t!==1&&this.ctxBack.scale(t,t)},e.prototype.createRepaintRects=function(t,n,a,i){if(this.__firstTimePaint)return this.__firstTimePaint=!1,null;var o=[],s=this.maxRepaintRectCount,l=!1,u=new Pe(0,0,0,0);function c(m){if(!(!m.isFinite()||m.isZero()))if(o.length===0){var _=new Pe(0,0,0,0);_.copy(m),o.push(_)}else{for(var b=!1,x=1/0,M=0,w=0;w<o.length;++w){var D=o[w];if(D.intersect(m)){var T=new Pe(0,0,0,0);T.copy(D),T.union(m),o[w]=T,b=!0;break}else if(l){u.copy(m),u.union(D);var I=m.width*m.height,A=D.width*D.height,N=u.width*u.height,L=N-I-A;L<x&&(x=L,M=w)}}if(l&&(o[M].union(m),b=!0),!b){var _=new Pe(0,0,0,0);_.copy(m),o.push(_)}l||(l=o.length>=s)}}for(var f=this.__startIndex;f<this.__endIndex;++f){var h=t[f];if(h){var v=h.shouldBePainted(a,i,!0,!0),d=h.__isRendered&&(h.__dirty&mn||!v)?h.getPrevPaintRect():null;d&&c(d);var p=v&&(h.__dirty&mn||!h.__isRendered)?h.getPaintRect():null;p&&c(p)}}for(var f=this.__prevStartIndex;f<this.__prevEndIndex;++f){var h=n[f],v=h.shouldBePainted(a,i,!0,!0);if(h&&(!v||!h.__zr)&&h.__isRendered){var d=h.getPrevPaintRect();d&&c(d)}}var g;do{g=!1;for(var f=0;f<o.length;){if(o[f].isZero()){o.splice(f,1);continue}for(var y=f+1;y<o.length;)o[f].intersect(o[y])?(g=!0,o[f].union(o[y]),o.splice(y,1)):y++;f++}}while(g);return this._paintRects=o,o},e.prototype.debugGetPaintRects=function(){return(this._paintRects||[]).slice()},e.prototype.resize=function(t,n){var a=this.dpr,i=this.dom,o=i.style,s=this.domBack;o&&(o.width=t+"px",o.height=n+"px"),i.width=t*a,i.height=n*a,s&&(s.width=t*a,s.height=n*a,a!==1&&this.ctxBack.scale(a,a))},e.prototype.clear=function(t,n,a){var i=this.dom,o=this.ctx,s=i.width,l=i.height;n=n||this.clearColor;var u=this.motionBlur&&!t,c=this.lastFrameAlpha,f=this.dpr,h=this;u&&(this.domBack||this.createBackBuffer(),this.ctxBack.globalCompositeOperation="copy",this.ctxBack.drawImage(i,0,0,s/f,l/f));var v=this.domBack;function d(p,g,y,m){if(o.clearRect(p,g,y,m),n&&n!=="transparent"){var _=void 0;if(dc(n)){var b=n.global||n.__width===y&&n.__height===m;_=b&&n.__canvasGradient||i_(o,n,{x:0,y:0,width:y,height:m}),n.__canvasGradient=_,n.__width=y,n.__height=m}else FS(n)&&(n.scaleX=n.scaleX||f,n.scaleY=n.scaleY||f,_=s_(o,n,{dirty:function(){h.setUnpainted(),h.__painter.refresh()}}));o.save(),o.fillStyle=_||n,o.fillRect(p,g,y,m),o.restore()}u&&(o.save(),o.globalAlpha=c,o.drawImage(v,p,g,y,m),o.restore())}!a||u?d(0,0,s,l):a.length&&C(a,function(p){d(p.x*f,p.y*f,p.width*f,p.height*f)})},e}(zn),ob=Q8,aE=1e5,Fs=314159,Np=.01,Z8=.001;function q8(r){return r?r.__builtin__?!0:!(typeof r.resize!="function"||typeof r.refresh!="function"):!1}function X8(r,e){var t=document.createElement("div");return t.style.cssText=["position:relative","width:"+r+"px","height:"+e+"px","padding:0","margin:0","border-width:0"].join(";")+";",t}var J8=function(){function r(e,t,n,a){this.type="canvas",this._zlevelList=[],this._prevDisplayList=[],this._layers={},this._layerConfig={},this._needsManuallyCompositing=!1,this.type="canvas";var i=!e.nodeName||e.nodeName.toUpperCase()==="CANVAS";this._opts=n=X({},n||{}),this.dpr=n.devicePixelRatio||Xv,this._singleCanvas=i,this.root=e;var o=e.style;o&&(Cm(e),e.innerHTML=""),this.storage=t;var s=this._zlevelList;this._prevDisplayList=[];var l=this._layers;if(i){var c=e,f=c.width,h=c.height;n.width!=null&&(f=n.width),n.height!=null&&(h=n.height),this.dpr=n.devicePixelRatio||1,c.width=f*this.dpr,c.height=h*this.dpr,this._width=f,this._height=h;var v=new ob(c,this,this.dpr);v.__builtin__=!0,v.initContext(),l[Fs]=v,v.zlevel=Fs,s.push(Fs),this._domRoot=e}else{this._width=gu(e,0,n),this._height=gu(e,1,n);var u=this._domRoot=X8(this._width,this._height);e.appendChild(u)}}return r.prototype.getType=function(){return"canvas"},r.prototype.isSingleCanvas=function(){return this._singleCanvas},r.prototype.getViewportRoot=function(){return this._domRoot},r.prototype.getViewportRootOffset=function(){var e=this.getViewportRoot();if(e)return{offsetLeft:e.offsetLeft||0,offsetTop:e.offsetTop||0}},r.prototype.refresh=function(e){var t=this.storage.getDisplayList(!0),n=this._prevDisplayList,a=this._zlevelList;this._redrawId=Math.random(),this._paintList(t,n,e,this._redrawId);for(var i=0;i<a.length;i++){var o=a[i],s=this._layers[o];if(!s.__builtin__&&s.refresh){var l=i===0?this._backgroundColor:null;s.refresh(l)}}return this._opts.useDirtyRect&&(this._prevDisplayList=t.slice()),this},r.prototype.refreshHover=function(){this._paintHoverList(this.storage.getDisplayList(!1))},r.prototype._paintHoverList=function(e){var t=e.length,n=this._hoverlayer;if(n&&n.clear(),!!t){for(var a={inHover:!0,viewWidth:this._width,viewHeight:this._height},i,o=0;o<t;o++){var s=e[o];s.__inHover&&(n||(n=this._hoverlayer=this.getLayer(aE)),i||(i=n.ctx,i.save()),Ls(i,s,a,o===t-1))}i&&i.restore()}},r.prototype.getHoverLayer=function(){return this.getLayer(aE)},r.prototype.paintOne=function(e,t){l_(e,t)},r.prototype._paintList=function(e,t,n,a){if(this._redrawId===a){n=n||!1,this._updateLayerStatus(e);var i=this._doPaintList(e,t,n),o=i.finished,s=i.needsRefreshHover;if(this._needsManuallyCompositing&&this._compositeManually(),s&&this._paintHoverList(e),o)this.eachLayer(function(u){u.afterBrush&&u.afterBrush()});else{var l=this;$m(function(){l._paintList(e,t,n,a)})}}},r.prototype._compositeManually=function(){var e=this.getLayer(Fs).ctx,t=this._domRoot.width,n=this._domRoot.height;e.clearRect(0,0,t,n),this.eachBuiltinLayer(function(a){a.virtual&&e.drawImage(a.dom,0,0,t,n)})},r.prototype._doPaintList=function(e,t,n){for(var a=this,i=[],o=this._opts.useDirtyRect,s=0;s<this._zlevelList.length;s++){var l=this._zlevelList[s],u=this._layers[l];u.__builtin__&&u!==this._hoverlayer&&(u.__dirty||n)&&i.push(u)}for(var c=!0,f=!1,h=function(p){var g=i[p],y=g.ctx,m=o&&g.createRepaintRects(e,t,v._width,v._height),_=n?g.__startIndex:g.__drawIndex,b=!n&&g.incremental&&Date.now,x=b&&Date.now(),M=g.zlevel===v._zlevelList[0]?v._backgroundColor:null;if(g.__startIndex===g.__endIndex)g.clear(!1,M,m);else if(_===g.__startIndex){var w=e[_];(!w.incremental||!w.notClear||n)&&g.clear(!1,M,m)}_===-1&&(console.error("For some unknown reason. drawIndex is -1"),_=g.__startIndex);var D,T=function(L){var E={inHover:!1,allClipped:!1,prevEl:null,viewWidth:a._width,viewHeight:a._height};for(D=_;D<g.__endIndex;D++){var O=e[D];if(O.__inHover&&(f=!0),a._doPaintEl(O,g,o,L,E,D===g.__endIndex-1),b){var P=Date.now()-x;if(P>15)break}}E.prevElClipPaths&&y.restore()};if(m)if(m.length===0)D=g.__endIndex;else for(var I=v.dpr,A=0;A<m.length;++A){var N=m[A];y.save(),y.beginPath(),y.rect(N.x*I,N.y*I,N.width*I,N.height*I),y.clip(),T(N),y.restore()}else y.save(),T(),y.restore();g.__drawIndex=D,g.__drawIndex<g.__endIndex&&(c=!1)},v=this,d=0;d<i.length;d++)h(d);return $e.wxa&&C(this._layers,function(p){p&&p.ctx&&p.ctx.draw&&p.ctx.draw()}),{finished:c,needsRefreshHover:f}},r.prototype._doPaintEl=function(e,t,n,a,i,o){var s=t.ctx;if(n){var l=e.getPaintRect();(!a||l&&l.intersect(a))&&(Ls(s,e,i,o),e.setPrevPaintRect(l))}else Ls(s,e,i,o)},r.prototype.getLayer=function(e,t){this._singleCanvas&&!this._needsManuallyCompositing&&(e=Fs);var n=this._layers[e];return n||(n=new ob("zr_"+e,this,this.dpr),n.zlevel=e,n.__builtin__=!0,this._layerConfig[e]?Ne(n,this._layerConfig[e],!0):this._layerConfig[e-Np]&&Ne(n,this._layerConfig[e-Np],!0),t&&(n.virtual=t),this.insertLayer(e,n),n.initContext()),n},r.prototype.insertLayer=function(e,t){var n=this._layers,a=this._zlevelList,i=a.length,o=this._domRoot,s=null,l=-1;if(!n[e]&&!!q8(t)){if(i>0&&e>a[0]){for(l=0;l<i-1&&!(a[l]<e&&a[l+1]>e);l++);s=n[a[l]]}if(a.splice(l+1,0,e),n[e]=t,!t.virtual)if(s){var u=s.dom;u.nextSibling?o.insertBefore(t.dom,u.nextSibling):o.appendChild(t.dom)}else o.firstChild?o.insertBefore(t.dom,o.firstChild):o.appendChild(t.dom);t.__painter=this}},r.prototype.eachLayer=function(e,t){for(var n=this._zlevelList,a=0;a<n.length;a++){var i=n[a];e.call(t,this._layers[i],i)}},r.prototype.eachBuiltinLayer=function(e,t){for(var n=this._zlevelList,a=0;a<n.length;a++){var i=n[a],o=this._layers[i];o.__builtin__&&e.call(t,o,i)}},r.prototype.eachOtherLayer=function(e,t){for(var n=this._zlevelList,a=0;a<n.length;a++){var i=n[a],o=this._layers[i];o.__builtin__||e.call(t,o,i)}},r.prototype.getLayers=function(){return this._layers},r.prototype._updateLayerStatus=function(e){this.eachBuiltinLayer(function(f,h){f.__dirty=f.__used=!1});function t(f){i&&(i.__endIndex!==f&&(i.__dirty=!0),i.__endIndex=f)}if(this._singleCanvas)for(var n=1;n<e.length;n++){var a=e[n];if(a.zlevel!==e[n-1].zlevel||a.incremental){this._needsManuallyCompositing=!0;break}}var i=null,o=0,s,l;for(l=0;l<e.length;l++){var a=e[l],u=a.zlevel,c=void 0;s!==u&&(s=u,o=0),a.incremental?(c=this.getLayer(u+Z8,this._needsManuallyCompositing),c.incremental=!0,o=1):c=this.getLayer(u+(o>0?Np:0),this._needsManuallyCompositing),c.__builtin__||wv("ZLevel "+u+" has been used by unkown layer "+c.id),c!==i&&(c.__used=!0,c.__startIndex!==l&&(c.__dirty=!0),c.__startIndex=l,c.incremental?c.__drawIndex=-1:c.__drawIndex=l,t(l),i=c),a.__dirty&mn&&!a.__inHover&&(c.__dirty=!0,c.incremental&&c.__drawIndex<0&&(c.__drawIndex=l))}t(l),this.eachBuiltinLayer(function(f,h){!f.__used&&f.getElementCount()>0&&(f.__dirty=!0,f.__startIndex=f.__endIndex=f.__drawIndex=0),f.__dirty&&f.__drawIndex<0&&(f.__drawIndex=f.__startIndex)})},r.prototype.clear=function(){return this.eachBuiltinLayer(this._clearLayer),this},r.prototype._clearLayer=function(e){e.clear()},r.prototype.setBackgroundColor=function(e){this._backgroundColor=e,C(this._layers,function(t){t.setUnpainted()})},r.prototype.configLayer=function(e,t){if(t){var n=this._layerConfig;n[e]?Ne(n[e],t,!0):n[e]=t;for(var a=0;a<this._zlevelList.length;a++){var i=this._zlevelList[a];if(i===e||i===e+Np){var o=this._layers[i];Ne(o,n[e],!0)}}}},r.prototype.delLayer=function(e){var t=this._layers,n=this._zlevelList,a=t[e];!a||(a.dom.parentNode.removeChild(a.dom),delete t[e],n.splice(ze(n,e),1))},r.prototype.resize=function(e,t){if(this._domRoot.style){var n=this._domRoot;n.style.display="none";var a=this._opts,i=this.root;if(e!=null&&(a.width=e),t!=null&&(a.height=t),e=gu(i,0,a),t=gu(i,1,a),n.style.display="",this._width!==e||t!==this._height){n.style.width=e+"px",n.style.height=t+"px";for(var o in this._layers)this._layers.hasOwnProperty(o)&&this._layers[o].resize(e,t);this.refresh(!0)}this._width=e,this._height=t}else{if(e==null||t==null)return;this._width=e,this._height=t,this.getLayer(Fs).resize(e,t)}return this},r.prototype.clearLayer=function(e){var t=this._layers[e];t&&t.clear()},r.prototype.dispose=function(){this.root.innerHTML="",this.root=this.storage=this._domRoot=this._layers=null},r.prototype.getRenderedCanvas=function(e){if(e=e||{},this._singleCanvas&&!this._compositeManually)return this._layers[Fs].dom;var t=new ob("image",this,e.pixelRatio||this.dpr);t.initContext(),t.clear(!1,e.backgroundColor||this._backgroundColor);var n=t.ctx;if(e.pixelRatio<=this.dpr){this.refresh();var a=t.dom.width,i=t.dom.height;this.eachLayer(function(f){f.__builtin__?n.drawImage(f.dom,0,0,a,i):f.renderToCanvas&&(n.save(),f.renderToCanvas(n),n.restore())})}else for(var o={inHover:!1,viewWidth:this._width,viewHeight:this._height},s=this.storage.getDisplayList(!0),l=0,u=s.length;l<u;l++){var c=s[l];Ls(n,c,o,l===u-1)}return t.dom},r.prototype.getWidth=function(){return this._width},r.prototype.getHeight=function(){return this._height},r}(),K8=J8;function eZ(r){r.registerPainter("canvas",K8)}var tZ=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t}return e.prototype.getInitialData=function(t){return Ua(null,this,{useEncodeDefaulter:!0})},e.prototype.getLegendIcon=function(t){var n=new De,a=Ft("line",0,t.itemHeight/2,t.itemWidth,0,t.lineStyle.stroke,!1);n.add(a),a.setStyle(t.lineStyle);var i=this.getData().getVisual("symbol"),o=this.getData().getVisual("symbolRotate"),s=i==="none"?"circle":i,l=t.itemHeight*.8,u=Ft(s,(t.itemWidth-l)/2,(t.itemHeight-l)/2,l,l,t.itemStyle.fill);n.add(u),u.setStyle(t.itemStyle);var c=t.iconRotate==="inherit"?o:t.iconRotate||0;return u.rotation=c*Math.PI/180,u.setOrigin([t.itemWidth/2,t.itemHeight/2]),s.indexOf("empty")>-1&&(u.style.stroke=u.style.fill,u.style.fill="#fff",u.style.lineWidth=2),n},e.type="series.line",e.dependencies=["grid","polar"],e.defaultOption={z:3,coordinateSystem:"cartesian2d",legendHoverLink:!0,clip:!0,label:{position:"top"},endLabel:{show:!1,valueAnimation:!0,distance:8},lineStyle:{width:2,type:"solid"},emphasis:{scale:!0},step:!1,smooth:!1,smoothMonotone:null,symbol:"emptyCircle",symbolSize:4,symbolRotate:null,showSymbol:!0,showAllSymbol:"auto",connectNulls:!1,sampling:"none",animationEasing:"linear",progressive:0,hoverLayerThreshold:1/0,universalTransition:{divideShape:"clone"},triggerLineEvent:!1},e}(bt),rZ=tZ;function wu(r,e){var t=r.mapDimensionsAll("defaultedLabel"),n=t.length;if(n===1){var a=cu(r,e,t[0]);return a!=null?a+"":null}else if(n){for(var i=[],o=0;o<t.length;o++)i.push(cu(r,e,t[o]));return i.join(" ")}}function iE(r,e){var t=r.mapDimensionsAll("defaultedLabel");if(!J(e))return e+"";for(var n=[],a=0;a<t.length;a++){var i=r.getDimensionIndex(t[a]);i>=0&&n.push(e[i])}return n.join(" ")}var nZ=function(r){U(e,r);function e(t,n,a,i){var o=r.call(this)||this;return o.updateData(t,n,a,i),o}return e.prototype._createSymbol=function(t,n,a,i,o){this.removeAll();var s=Ft(t,-1,-1,2,2,null,o);s.attr({z2:100,culling:!0,scaleX:i[0]/2,scaleY:i[1]/2}),s.drift=aZ,this._symbolType=t,this.add(s)},e.prototype.stopSymbolAnimation=function(t){this.childAt(0).stopAnimation(null,t)},e.prototype.getSymbolType=function(){return this._symbolType},e.prototype.getSymbolPath=function(){return this.childAt(0)},e.prototype.highlight=function(){mi(this.childAt(0))},e.prototype.downplay=function(){_i(this.childAt(0))},e.prototype.setZ=function(t,n){var a=this.childAt(0);a.zlevel=t,a.z=n},e.prototype.setDraggable=function(t,n){var a=this.childAt(0);a.draggable=t,a.cursor=!n&&t?"move":a.cursor},e.prototype.updateData=function(t,n,a,i){this.silent=!1;var o=t.getItemVisual(n,"symbol")||"circle",s=t.hostModel,l=e.getSymbolSize(t,n),u=o!==this._symbolType,c=i&&i.disableAnimation;if(u){var f=t.getItemVisual(n,"symbolKeepAspect");this._createSymbol(o,t,n,l,f)}else{var h=this.childAt(0);h.silent=!1;var v={scaleX:l[0]/2,scaleY:l[1]/2};c?h.attr(v):Qe(h,v,s,n),ya(h)}if(this._updateCommon(t,n,l,a,i),u){var h=this.childAt(0);if(!c){var v={scaleX:this._sizeX,scaleY:this._sizeY,style:{opacity:h.style.opacity}};h.scaleX=h.scaleY=0,h.style.opacity=0,Dt(h,v,s,n)}}c&&this.childAt(0).stopAnimation("leave")},e.prototype._updateCommon=function(t,n,a,i,o){var s=this.childAt(0),l=t.hostModel,u,c,f,h,v,d,p,g,y;if(i&&(u=i.emphasisItemStyle,c=i.blurItemStyle,f=i.selectItemStyle,h=i.focus,v=i.blurScope,p=i.labelStatesModels,g=i.hoverScale,y=i.cursorStyle,d=i.emphasisDisabled),!i||t.hasItemOption){var m=i&&i.itemModel?i.itemModel:t.getItemModel(n),_=m.getModel("emphasis");u=_.getModel("itemStyle").getItemStyle(),f=m.getModel(["select","itemStyle"]).getItemStyle(),c=m.getModel(["blur","itemStyle"]).getItemStyle(),h=_.get("focus"),v=_.get("blurScope"),d=_.get("disabled"),p=sr(m),g=_.getShallow("scale"),y=m.getShallow("cursor")}var b=t.getItemVisual(n,"symbolRotate");s.attr("rotation",(b||0)*Math.PI/180||0);var x=pu(t.getItemVisual(n,"symbolOffset"),a);x&&(s.x=x[0],s.y=x[1]),y&&s.attr("cursor",y);var M=t.getItemVisual(n,"style"),w=M.fill;if(s instanceof pr){var D=s.style;s.useStyle(X({image:D.image,x:D.x,y:D.y,width:D.width,height:D.height},M))}else s.__isEmptyBrush?s.useStyle(X({},M)):s.useStyle(M),s.style.decal=null,s.setColor(w,o&&o.symbolInnerColor),s.style.strokeNoScale=!0;var T=t.getItemVisual(n,"liftZ"),I=this._z2;T!=null?I==null&&(this._z2=s.z2,s.z2+=T):I!=null&&(s.z2=I,this._z2=null);var A=o&&o.useNameLabel;wr(s,p,{labelFetcher:l,labelDataIndex:n,defaultText:N,inheritColor:w,defaultOpacity:M.opacity});function N(O){return A?t.getName(O):wu(t,O)}this._sizeX=a[0]/2,this._sizeY=a[1]/2;var L=s.ensureState("emphasis");L.style=u,s.ensureState("select").style=f,s.ensureState("blur").style=c;var E=g==null||g===!0?Math.max(1.1,3/this._sizeY):isFinite(g)&&g>0?+g:1;L.scaleX=this._sizeX*E,L.scaleY=this._sizeY*E,this.setSymbolScale(1),Lt(this,h,v,d)},e.prototype.setSymbolScale=function(t){this.scaleX=this.scaleY=t},e.prototype.fadeOut=function(t,n,a){var i=this.childAt(0),o=Te(this).dataIndex,s=a&&a.animation;if(this.silent=i.silent=!0,a&&a.fadeLabel){var l=i.getTextContent();l&&so(l,{style:{opacity:0}},n,{dataIndex:o,removeOpt:s,cb:function(){i.removeTextContent()}})}else i.removeTextContent();so(i,{style:{opacity:0},scaleX:0,scaleY:0},n,{dataIndex:o,cb:t,removeOpt:s})},e.getSymbolSize=function(t,n){return If(t.getItemVisual(n,"symbolSize"))},e}(De);function aZ(r,e){this.parent.drift(r,e)}var Gf=nZ;function sb(r,e,t,n){return e&&!isNaN(e[0])&&!isNaN(e[1])&&!(n.isIgnore&&n.isIgnore(t))&&!(n.clipShape&&!n.clipShape.contain(e[0],e[1]))&&r.getItemVisual(t,"symbol")!=="none"}function oE(r){return r!=null&&!_e(r)&&(r={isIgnore:r}),r||{}}function sE(r){var e=r.hostModel,t=e.getModel("emphasis");return{emphasisItemStyle:t.getModel("itemStyle").getItemStyle(),blurItemStyle:e.getModel(["blur","itemStyle"]).getItemStyle(),selectItemStyle:e.getModel(["select","itemStyle"]).getItemStyle(),focus:t.get("focus"),blurScope:t.get("blurScope"),emphasisDisabled:t.get("disabled"),hoverScale:t.get("scale"),labelStatesModels:sr(e),cursorStyle:e.get("cursor")}}var iZ=function(){function r(e){this.group=new De,this._SymbolCtor=e||Gf}return r.prototype.updateData=function(e,t){this._progressiveEls=null,t=oE(t);var n=this.group,a=e.hostModel,i=this._data,o=this._SymbolCtor,s=t.disableAnimation,l=sE(e),u={disableAnimation:s},c=t.getSymbolPoint||function(f){return e.getItemLayout(f)};i||n.removeAll(),e.diff(i).add(function(f){var h=c(f);if(sb(e,h,f,t)){var v=new o(e,f,l,u);v.setPosition(h),e.setItemGraphicEl(f,v),n.add(v)}}).update(function(f,h){var v=i.getItemGraphicEl(h),d=c(f);if(!sb(e,d,f,t)){n.remove(v);return}var p=e.getItemVisual(f,"symbol")||"circle",g=v&&v.getSymbolType&&v.getSymbolType();if(!v||g&&g!==p)n.remove(v),v=new o(e,f,l,u),v.setPosition(d);else{v.updateData(e,f,l,u);var y={x:d[0],y:d[1]};s?v.attr(y):Qe(v,y,a)}n.add(v),e.setItemGraphicEl(f,v)}).remove(function(f){var h=i.getItemGraphicEl(f);h&&h.fadeOut(function(){n.remove(h)},a)}).execute(),this._getSymbolPoint=c,this._data=e},r.prototype.updateLayout=function(){var e=this,t=this._data;t&&t.eachItemGraphicEl(function(n,a){var i=e._getSymbolPoint(a);n.setPosition(i),n.markRedraw()})},r.prototype.incrementalPrepareUpdate=function(e){this._seriesScope=sE(e),this._data=null,this.group.removeAll()},r.prototype.incrementalUpdate=function(e,t,n){this._progressiveEls=[],n=oE(n);function a(l){l.isGroup||(l.incremental=!0,l.ensureState("emphasis").hoverLayer=!0)}for(var i=e.start;i<e.end;i++){var o=t.getItemLayout(i);if(sb(t,o,i,n)){var s=new this._SymbolCtor(t,i,this._seriesScope);s.traverse(a),s.setPosition(o),this.group.add(s),t.setItemGraphicEl(i,s),this._progressiveEls.push(s)}}},r.prototype.eachRendered=function(e){uo(this._progressiveEls||this.group,e)},r.prototype.remove=function(e){var t=this.group,n=this._data;n&&e?n.eachItemGraphicEl(function(a){a.fadeOut(function(){t.remove(a)},n.hostModel)}):t.removeAll()},r}(),$f=iZ;function lE(r,e,t){var n=r.getBaseAxis(),a=r.getOtherAxis(n),i=oZ(a,t),o=n.dim,s=a.dim,l=e.mapDimension(s),u=e.mapDimension(o),c=s==="x"||s==="radius"?1:0,f=K(r.dimensions,function(d){return e.mapDimension(d)}),h=!1,v=e.getCalculationInfo("stackResultDimension");return xi(e,f[0])&&(h=!0,f[0]=v),xi(e,f[1])&&(h=!0,f[1]=v),{dataDimsForPoint:f,valueStart:i,valueAxisDim:s,baseAxisDim:o,stacked:!!h,valueDim:l,baseDim:u,baseDataOffset:c,stackedOverDimension:e.getCalculationInfo("stackedOverDimension")}}function oZ(r,e){var t=0,n=r.scale.getExtent();return e==="start"?t=n[0]:e==="end"?t=n[1]:Ue(e)&&!isNaN(e)?t=e:n[0]>0?t=n[0]:n[1]<0&&(t=n[1]),t}function uE(r,e,t,n){var a=NaN;r.stacked&&(a=t.get(t.getCalculationInfo("stackedOverDimension"),n)),isNaN(a)&&(a=r.valueStart);var i=r.baseDataOffset,o=[];return o[i]=t.get(r.baseDim,n),o[1-i]=a,e.dataToPoint(o)}function sZ(r,e){var t=[];return e.diff(r).add(function(n){t.push({cmd:"+",idx:n})}).update(function(n,a){t.push({cmd:"=",idx:a,idx1:n})}).remove(function(n){t.push({cmd:"-",idx:n})}).execute(),t}function lZ(r,e,t,n,a,i,o,s){for(var l=sZ(r,e),u=[],c=[],f=[],h=[],v=[],d=[],p=[],g=lE(a,e,o),y=r.getLayout("points")||[],m=e.getLayout("points")||[],_=0;_<l.length;_++){var b=l[_],x=!0,M=void 0,w=void 0;switch(b.cmd){case"=":M=b.idx*2,w=b.idx1*2;var D=y[M],T=y[M+1],I=m[w],A=m[w+1];(isNaN(D)||isNaN(T))&&(D=I,T=A),u.push(D,T),c.push(I,A),f.push(t[M],t[M+1]),h.push(n[w],n[w+1]),p.push(e.getRawIndex(b.idx1));break;case"+":var N=b.idx,L=g.dataDimsForPoint,E=a.dataToPoint([e.get(L[0],N),e.get(L[1],N)]);w=N*2,u.push(E[0],E[1]),c.push(m[w],m[w+1]);var O=uE(g,a,e,N);f.push(O[0],O[1]),h.push(n[w],n[w+1]),p.push(e.getRawIndex(N));break;case"-":x=!1}x&&(v.push(b),d.push(d.length))}d.sort(function(Q,ne){return p[Q]-p[ne]});for(var P=u.length,H=Ya(P),F=Ya(P),G=Ya(P),Z=Ya(P),te=[],_=0;_<d.length;_++){var V=d[_],Y=_*2,q=V*2;H[Y]=u[q],H[Y+1]=u[q+1],F[Y]=c[q],F[Y+1]=c[q+1],G[Y]=f[q],G[Y+1]=f[q+1],Z[Y]=h[q],Z[Y+1]=h[q+1],te[_]=v[V]}return{current:H,next:F,stackedOnCurrent:G,stackedOnNext:Z,status:te}}var bo=Math.min,Mo=Math.max;function Vs(r,e){return isNaN(r)||isNaN(e)}function lb(r,e,t,n,a,i,o,s,l){for(var u,c,f,h,v,d,p=t,g=0;g<n;g++){var y=e[p*2],m=e[p*2+1];if(p>=a||p<0)break;if(Vs(y,m)){if(l){p+=i;continue}break}if(p===t)r[i>0?"moveTo":"lineTo"](y,m),f=y,h=m;else{var _=y-u,b=m-c;if(_*_+b*b<.5){p+=i;continue}if(o>0){for(var x=p+i,M=e[x*2],w=e[x*2+1];M===y&&w===m&&g<n;)g++,x+=i,p+=i,M=e[x*2],w=e[x*2+1],y=e[p*2],m=e[p*2+1],_=y-u,b=m-c;var D=g+1;if(l)for(;Vs(M,w)&&D<n;)D++,x+=i,M=e[x*2],w=e[x*2+1];var T=.5,I=0,A=0,N=void 0,L=void 0;if(D>=n||Vs(M,w))v=y,d=m;else{I=M-u,A=w-c;var E=y-u,O=M-y,P=m-c,H=w-m,F=void 0,G=void 0;if(s==="x"){F=Math.abs(E),G=Math.abs(O);var Z=I>0?1:-1;v=y-Z*F*o,d=m,N=y+Z*G*o,L=m}else if(s==="y"){F=Math.abs(P),G=Math.abs(H);var te=A>0?1:-1;v=y,d=m-te*F*o,N=y,L=m+te*G*o}else F=Math.sqrt(E*E+P*P),G=Math.sqrt(O*O+H*H),T=G/(G+F),v=y-I*o*(1-T),d=m-A*o*(1-T),N=y+I*o*T,L=m+A*o*T,N=bo(N,Mo(M,y)),L=bo(L,Mo(w,m)),N=Mo(N,bo(M,y)),L=Mo(L,bo(w,m)),I=N-y,A=L-m,v=y-I*F/G,d=m-A*F/G,v=bo(v,Mo(u,y)),d=bo(d,Mo(c,m)),v=Mo(v,bo(u,y)),d=Mo(d,bo(c,m)),I=y-v,A=m-d,N=y+I*G/F,L=m+A*G/F}r.bezierCurveTo(f,h,v,d,y,m),f=N,h=L}else r.lineTo(y,m)}u=y,c=m,p+=i}return g}var cE=function(){function r(){this.smooth=0,this.smoothConstraint=!0}return r}(),uZ=function(r){U(e,r);function e(t){var n=r.call(this,t)||this;return n.type="ec-polyline",n}return e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new cE},e.prototype.buildPath=function(t,n){var a=n.points,i=0,o=a.length/2;if(n.connectNulls){for(;o>0&&Vs(a[o*2-2],a[o*2-1]);o--);for(;i<o&&Vs(a[i*2],a[i*2+1]);i++);}for(;i<o;)i+=lb(t,a,i,o,o,1,n.smooth,n.smoothMonotone,n.connectNulls)+1},e.prototype.getPointOn=function(t,n){this.path||(this.createPathProxy(),this.buildPath(this.path,this.shape));for(var a=this.path,i=a.data,o=Ha.CMD,s,l,u=n==="x",c=[],f=0;f<i.length;){var h=i[f++],v=void 0,d=void 0,p=void 0,g=void 0,y=void 0,m=void 0,_=void 0;switch(h){case o.M:s=i[f++],l=i[f++];break;case o.L:if(v=i[f++],d=i[f++],_=u?(t-s)/(v-s):(t-l)/(d-l),_<=1&&_>=0){var b=u?(d-l)*_+l:(v-s)*_+s;return u?[t,b]:[b,t]}s=v,l=d;break;case o.C:v=i[f++],d=i[f++],p=i[f++],g=i[f++],y=i[f++],m=i[f++];var x=u?Bv(s,v,p,y,t,c):Bv(l,d,g,m,t,c);if(x>0)for(var M=0;M<x;M++){var w=c[M];if(w<=1&&w>=0){var b=u?ir(l,d,g,m,w):ir(s,v,p,y,w);return u?[t,b]:[b,t]}}s=y,l=m;break}}},e}(je),cZ=function(r){U(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e}(cE),fE=function(r){U(e,r);function e(t){var n=r.call(this,t)||this;return n.type="ec-polygon",n}return e.prototype.getDefaultShape=function(){return new cZ},e.prototype.buildPath=function(t,n){var a=n.points,i=n.stackedOnPoints,o=0,s=a.length/2,l=n.smoothMonotone;if(n.connectNulls){for(;s>0&&Vs(a[s*2-2],a[s*2-1]);s--);for(;o<s&&Vs(a[o*2],a[o*2+1]);o++);}for(;o<s;){var u=lb(t,a,o,s,s,1,n.smooth,l,n.connectNulls);lb(t,i,o+u-1,u,s,-1,n.stackedOnSmooth,l,n.connectNulls),o+=u+1,t.closePath()}},e}(je);function hE(r,e,t,n,a){var i=r.getArea(),o=i.x,s=i.y,l=i.width,u=i.height,c=t.get(["lineStyle","width"])||2;o-=c/2,s-=c/2,l+=c,u+=c,o=Math.floor(o),l=Math.round(l);var f=new We({shape:{x:o,y:s,width:l,height:u}});if(e){var h=r.getBaseAxis(),v=h.isHorizontal(),d=h.inverse;v?(d&&(f.shape.x+=l),f.shape.width=0):(d||(f.shape.y+=u),f.shape.height=0);var p=ye(a)?function(g){a(g,f)}:null;Dt(f,{shape:{width:l,height:u,x:o,y:s}},t,null,n,p)}return f}function vE(r,e,t){var n=r.getArea(),a=Nt(n.r0,1),i=Nt(n.r,1),o=new Zr({shape:{cx:Nt(r.cx,1),cy:Nt(r.cy,1),r0:a,r:i,startAngle:n.startAngle,endAngle:n.endAngle,clockwise:n.clockwise}});if(e){var s=r.getBaseAxis().dim==="angle";s?o.shape.endAngle=n.startAngle:o.shape.r=a,Dt(o,{shape:{endAngle:n.endAngle,r:i}},t)}return o}function Lp(r,e,t,n,a){if(r){if(r.type==="polar")return vE(r,e,t);if(r.type==="cartesian2d")return hE(r,e,t,n,a)}else return null;return null}function Hs(r,e){return r.type===e}function dE(r,e){if(r.length===e.length){for(var t=0;t<r.length;t++)if(r[t]!==e[t])return;return!0}}function pE(r){for(var e=1/0,t=1/0,n=-1/0,a=-1/0,i=0;i<r.length;){var o=r[i++],s=r[i++];isNaN(o)||(e=Math.min(o,e),n=Math.max(o,n)),isNaN(s)||(t=Math.min(s,t),a=Math.max(s,a))}return[[e,t],[n,a]]}function gE(r,e){var t=pE(r),n=t[0],a=t[1],i=pE(e),o=i[0],s=i[1];return Math.max(Math.abs(n[0]-o[0]),Math.abs(n[1]-o[1]),Math.abs(a[0]-s[0]),Math.abs(a[1]-s[1]))}function yE(r){return Ue(r)?r:r?.5:0}function fZ(r,e,t){if(!t.valueDim)return[];for(var n=e.count(),a=Ya(n*2),i=0;i<n;i++){var o=uE(t,r,e,i);a[i*2]=o[0],a[i*2+1]=o[1]}return a}function xo(r,e,t,n){var a=e.getBaseAxis(),i=a.dim==="x"||a.dim==="radius"?0:1,o=[],s=0,l=[],u=[],c=[],f=[];if(n){for(s=0;s<r.length;s+=2)!isNaN(r[s])&&!isNaN(r[s+1])&&f.push(r[s],r[s+1]);r=f}for(s=0;s<r.length-2;s+=2)switch(c[0]=r[s+2],c[1]=r[s+3],u[0]=r[s],u[1]=r[s+1],o.push(u[0],u[1]),t){case"end":l[i]=c[i],l[1-i]=u[1-i],o.push(l[0],l[1]);break;case"middle":var h=(u[i]+c[i])/2,v=[];l[i]=v[i]=h,l[1-i]=u[1-i],v[1-i]=c[1-i],o.push(l[0],l[1]),o.push(v[0],v[1]);break;default:l[i]=u[i],l[1-i]=c[1-i],o.push(l[0],l[1])}return o.push(r[s++],r[s++]),o}function hZ(r,e){var t=[],n=r.length,a,i;function o(c,f,h){var v=c.coord,d=(h-v)/(f.coord-v),p=Jm(d,[c.color,f.color]);return{coord:h,color:p}}for(var s=0;s<n;s++){var l=r[s],u=l.coord;if(u<0)a=l;else if(u>e){i?t.push(o(i,l,e)):a&&t.push(o(a,l,0),o(a,l,e));break}else a&&(t.push(o(a,l,0)),a=null),t.push(l),i=l}return t}function vZ(r,e,t){var n=r.getVisual("visualMeta");if(!(!n||!n.length||!r.count())&&e.type==="cartesian2d"){for(var a,i,o=n.length-1;o>=0;o--){var s=r.getDimensionInfo(n[o].dimension);if(a=s&&s.coordDim,a==="x"||a==="y"){i=n[o];break}}if(!!i){var l=e.getAxis(a),u=K(i.stops,function(_){return{coord:l.toGlobalCoord(l.dataToCoord(_.value)),color:_.color}}),c=u.length,f=i.outerColors.slice();c&&u[0].coord>u[c-1].coord&&(u.reverse(),f.reverse());var h=hZ(u,a==="x"?t.getWidth():t.getHeight()),v=h.length;if(!v&&c)return u[0].coord<0?f[1]?f[1]:u[c-1].color:f[0]?f[0]:u[0].color;var d=10,p=h[0].coord-d,g=h[v-1].coord+d,y=g-p;if(y<.001)return"transparent";C(h,function(_){_.offset=(_.coord-p)/y}),h.push({offset:v?h[v-1].offset:.5,color:f[1]||"transparent"}),h.unshift({offset:v?h[0].offset:.5,color:f[0]||"transparent"});var m=new Zl(0,0,0,0,h,!0);return m[a]=p,m[a+"2"]=g,m}}}function dZ(r,e,t){var n=r.get("showAllSymbol"),a=n==="auto";if(!(n&&!a)){var i=t.getAxesByScale("ordinal")[0];if(!!i&&!(a&&pZ(i,e))){var o=e.mapDimension(i.dim),s={};return C(i.getViewLabels(),function(l){var u=i.scale.getRawOrdinalNumber(l.tickValue);s[u]=1}),function(l){return!s.hasOwnProperty(e.get(o,l))}}}}function pZ(r,e){var t=r.getExtent(),n=Math.abs(t[1]-t[0])/r.scale.count();isNaN(n)&&(n=0);for(var a=e.count(),i=Math.max(1,Math.round(a/5)),o=0;o<a;o+=i)if(Gf.getSymbolSize(e,o)[r.isHorizontal()?1:0]*1.5>n)return!1;return!0}function gZ(r,e){return isNaN(r)||isNaN(e)}function yZ(r){for(var e=r.length/2;e>0&&gZ(r[e*2-2],r[e*2-1]);e--);return e-1}function mE(r,e){return[r[e*2],r[e*2+1]]}function mZ(r,e,t){for(var n=r.length/2,a=t==="x"?0:1,i,o,s=0,l=-1,u=0;u<n;u++)if(o=r[u*2+a],!(isNaN(o)||isNaN(r[u*2+1-a]))){if(u===0){i=o;continue}if(i<=e&&o>=e||i>=e&&o<=e){l=u;break}s=u,i=o}return{range:[s,l],t:(e-i)/(o-i)}}function _E(r){if(r.get(["endLabel","show"]))return!0;for(var e=0;e<Qr.length;e++)if(r.get([Qr[e],"endLabel","show"]))return!0;return!1}function ub(r,e,t,n){if(Hs(e,"cartesian2d")){var a=n.getModel("endLabel"),i=a.get("valueAnimation"),o=n.getData(),s={lastFrameIndex:0},l=_E(n)?function(v,d){r._endLabelOnDuring(v,d,o,s,i,a,e)}:null,u=e.getBaseAxis().isHorizontal(),c=hE(e,t,n,function(){var v=r._endLabel;v&&t&&s.originalX!=null&&v.attr({x:s.originalX,y:s.originalY})},l);if(!n.get("clip",!0)){var f=c.shape,h=Math.max(f.width,f.height);u?(f.y-=h,f.height+=h*2):(f.x-=h,f.width+=h*2)}return l&&l(1,c),c}else return vE(e,t,n)}function _Z(r,e){var t=e.getBaseAxis(),n=t.isHorizontal(),a=t.inverse,i=n?a?"right":"left":"center",o=n?"middle":a?"top":"bottom";return{normal:{align:r.get("align")||i,verticalAlign:r.get("verticalAlign")||o}}}var bZ=function(r){U(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.init=function(){var t=new De,n=new $f;this.group.add(n.group),this._symbolDraw=n,this._lineGroup=t},e.prototype.render=function(t,n,a){var i=this,o=t.coordinateSystem,s=this.group,l=t.getData(),u=t.getModel("lineStyle"),c=t.getModel("areaStyle"),f=l.getLayout("points")||[],h=o.type==="polar",v=this._coordSys,d=this._symbolDraw,p=this._polyline,g=this._polygon,y=this._lineGroup,m=t.get("animation"),_=!c.isEmpty(),b=c.get("origin"),x=lE(o,l,b),M=_&&fZ(o,l,x),w=t.get("showSymbol"),D=t.get("connectNulls"),T=w&&!h&&dZ(t,l,o),I=this._data;I&&I.eachItemGraphicEl(function(ne,oe){ne.__temp&&(s.remove(ne),I.setItemGraphicEl(oe,null))}),w||d.remove(),s.add(y);var A=h?!1:t.get("step"),N;o&&o.getArea&&t.get("clip",!0)&&(N=o.getArea(),N.width!=null?(N.x-=.1,N.y-=.1,N.width+=.2,N.height+=.2):N.r0&&(N.r0-=.5,N.r+=.5)),this._clipShapeForSymbol=N;var L=vZ(l,o,a)||l.getVisual("style")[l.getVisual("drawType")];if(!(p&&v.type===o.type&&A===this._step))w&&d.updateData(l,{isIgnore:T,clipShape:N,disableAnimation:!0,getSymbolPoint:function(ne){return[f[ne*2],f[ne*2+1]]}}),m&&this._initSymbolLabelAnimation(l,o,N),A&&(f=xo(f,o,A,D),M&&(M=xo(M,o,A,D))),p=this._newPolyline(f),_?g=this._newPolygon(f,M):g&&(y.remove(g),g=this._polygon=null),h||this._initOrUpdateEndLabel(t,o,ws(L)),y.setClipPath(ub(this,o,!0,t));else{_&&!g?g=this._newPolygon(f,M):g&&!_&&(y.remove(g),g=this._polygon=null),h||this._initOrUpdateEndLabel(t,o,ws(L));var E=y.getClipPath();if(E){var O=ub(this,o,!1,t);Dt(E,{shape:O.shape},t)}else y.setClipPath(ub(this,o,!0,t));w&&d.updateData(l,{isIgnore:T,clipShape:N,disableAnimation:!0,getSymbolPoint:function(ne){return[f[ne*2],f[ne*2+1]]}}),(!dE(this._stackedOnPoints,M)||!dE(this._points,f))&&(m?this._doUpdateAnimation(l,M,o,a,A,b,D):(A&&(f=xo(f,o,A,D),M&&(M=xo(M,o,A,D))),p.setShape({points:f}),g&&g.setShape({points:f,stackedOnPoints:M})))}var P=t.getModel("emphasis"),H=P.get("focus"),F=P.get("blurScope"),G=P.get("disabled");if(p.useStyle(me(u.getLineStyle(),{fill:"none",stroke:L,lineJoin:"bevel"})),xr(p,t,"lineStyle"),p.style.lineWidth>0&&t.get(["emphasis","lineStyle","width"])==="bolder"){var Z=p.getState("emphasis").style;Z.lineWidth=+p.style.lineWidth+1}Te(p).seriesIndex=t.seriesIndex,Lt(p,H,F,G);var te=yE(t.get("smooth")),V=t.get("smoothMonotone");if(p.setShape({smooth:te,smoothMonotone:V,connectNulls:D}),g){var Y=l.getCalculationInfo("stackedOnSeries"),q=0;g.useStyle(me(c.getAreaStyle(),{fill:L,opacity:.7,lineJoin:"bevel",decal:l.getVisual("style").decal})),Y&&(q=yE(Y.get("smooth"))),g.setShape({smooth:te,stackedOnSmooth:q,smoothMonotone:V,connectNulls:D}),xr(g,t,"areaStyle"),Te(g).seriesIndex=t.seriesIndex,Lt(g,H,F,G)}var Q=function(ne){i._changePolyState(ne)};l.eachItemGraphicEl(function(ne){ne&&(ne.onHoverStateChange=Q)}),this._polyline.onHoverStateChange=Q,this._data=l,this._coordSys=o,this._stackedOnPoints=M,this._points=f,this._step=A,this._valueOrigin=b,t.get("triggerLineEvent")&&(this.packEventData(t,p),g&&this.packEventData(t,g))},e.prototype.packEventData=function(t,n){Te(n).eventData={componentType:"series",componentSubType:"line",componentIndex:t.componentIndex,seriesIndex:t.seriesIndex,seriesName:t.name,seriesType:"line"}},e.prototype.highlight=function(t,n,a,i){var o=t.getData(),s=as(o,i);if(this._changePolyState("emphasis"),!(s instanceof Array)&&s!=null&&s>=0){var l=o.getLayout("points"),u=o.getItemGraphicEl(s);if(!u){var c=l[s*2],f=l[s*2+1];if(isNaN(c)||isNaN(f)||this._clipShapeForSymbol&&!this._clipShapeForSymbol.contain(c,f))return;var h=t.get("zlevel")||0,v=t.get("z")||0;u=new Gf(o,s),u.x=c,u.y=f,u.setZ(h,v);var d=u.getSymbolPath().getTextContent();d&&(d.zlevel=h,d.z=v,d.z2=this._polyline.z2+1),u.__temp=!0,o.setItemGraphicEl(s,u),u.stopSymbolAnimation(!0),this.group.add(u)}u.highlight()}else ht.prototype.highlight.call(this,t,n,a,i)},e.prototype.downplay=function(t,n,a,i){var o=t.getData(),s=as(o,i);if(this._changePolyState("normal"),s!=null&&s>=0){var l=o.getItemGraphicEl(s);l&&(l.__temp?(o.setItemGraphicEl(s,null),this.group.remove(l)):l.downplay())}else ht.prototype.downplay.call(this,t,n,a,i)},e.prototype._changePolyState=function(t){var n=this._polygon;pd(this._polyline,t),n&&pd(n,t)},e.prototype._newPolyline=function(t){var n=this._polyline;return n&&this._lineGroup.remove(n),n=new uZ({shape:{points:t},segmentIgnoreThreshold:2,z2:10}),this._lineGroup.add(n),this._polyline=n,n},e.prototype._newPolygon=function(t,n){var a=this._polygon;return a&&this._lineGroup.remove(a),a=new fE({shape:{points:t,stackedOnPoints:n},segmentIgnoreThreshold:2}),this._lineGroup.add(a),this._polygon=a,a},e.prototype._initSymbolLabelAnimation=function(t,n,a){var i,o,s=n.getBaseAxis(),l=s.inverse;n.type==="cartesian2d"?(i=s.isHorizontal(),o=!1):n.type==="polar"&&(i=s.dim==="angle",o=!0);var u=t.hostModel,c=u.get("animationDuration");ye(c)&&(c=c(null));var f=u.get("animationDelay")||0,h=ye(f)?f(null):f;t.eachItemGraphicEl(function(v,d){var p=v;if(p){var g=[v.x,v.y],y=void 0,m=void 0,_=void 0;if(a)if(o){var b=a,x=n.pointToCoord(g);i?(y=b.startAngle,m=b.endAngle,_=-x[1]/180*Math.PI):(y=b.r0,m=b.r,_=x[0])}else{var M=a;i?(y=M.x,m=M.x+M.width,_=v.x):(y=M.y+M.height,m=M.y,_=v.y)}var w=m===y?0:(_-y)/(m-y);l&&(w=1-w);var D=ye(f)?f(d):c*w+h,T=p.getSymbolPath(),I=T.getTextContent();p.attr({scaleX:0,scaleY:0}),p.animateTo({scaleX:1,scaleY:1},{duration:200,setToFinal:!0,delay:D}),I&&I.animateFrom({style:{opacity:0}},{duration:300,delay:D}),T.disableLabelAnimation=!0}})},e.prototype._initOrUpdateEndLabel=function(t,n,a){var i=t.getModel("endLabel");if(_E(t)){var o=t.getData(),s=this._polyline,l=o.getLayout("points");if(!l){s.removeTextContent(),this._endLabel=null;return}var u=this._endLabel;u||(u=this._endLabel=new Ge({z2:200}),u.ignoreClip=!0,s.setTextContent(this._endLabel),s.disableLabelAnimation=!0);var c=yZ(l);c>=0&&(wr(s,sr(t,"endLabel"),{inheritColor:a,labelFetcher:t,labelDataIndex:c,defaultText:function(f,h,v){return v!=null?iE(o,v):wu(o,f)},enableTextSetter:!0},_Z(i,n)),s.textConfig.position=null)}else this._endLabel&&(this._polyline.removeTextContent(),this._endLabel=null)},e.prototype._endLabelOnDuring=function(t,n,a,i,o,s,l){var u=this._endLabel,c=this._polyline;if(u){t<1&&i.originalX==null&&(i.originalX=u.x,i.originalY=u.y);var f=a.getLayout("points"),h=a.hostModel,v=h.get("connectNulls"),d=s.get("precision"),p=s.get("distance")||0,g=l.getBaseAxis(),y=g.isHorizontal(),m=g.inverse,_=n.shape,b=m?y?_.x:_.y+_.height:y?_.x+_.width:_.y,x=(y?p:0)*(m?-1:1),M=(y?0:-p)*(m?-1:1),w=y?"x":"y",D=mZ(f,b,w),T=D.range,I=T[1]-T[0],A=void 0;if(I>=1){if(I>1&&!v){var N=mE(f,T[0]);u.attr({x:N[0]+x,y:N[1]+M}),o&&(A=h.getRawValue(T[0]))}else{var N=c.getPointOn(b,w);N&&u.attr({x:N[0]+x,y:N[1]+M});var L=h.getRawValue(T[0]),E=h.getRawValue(T[1]);o&&(A=uT(a,d,L,E,D.t))}i.lastFrameIndex=T[0]}else{var O=t===1||i.lastFrameIndex>0?T[0]:0,N=mE(f,O);o&&(A=h.getRawValue(O)),u.attr({x:N[0]+x,y:N[1]+M})}o&&tu(u).setLabelText(A)}},e.prototype._doUpdateAnimation=function(t,n,a,i,o,s,l){var u=this._polyline,c=this._polygon,f=t.hostModel,h=lZ(this._data,t,this._stackedOnPoints,n,this._coordSys,a,this._valueOrigin),v=h.current,d=h.stackedOnCurrent,p=h.next,g=h.stackedOnNext;if(o&&(v=xo(h.current,a,o,l),d=xo(h.stackedOnCurrent,a,o,l),p=xo(h.next,a,o,l),g=xo(h.stackedOnNext,a,o,l)),gE(v,p)>3e3||c&&gE(d,g)>3e3){u.stopAnimation(),u.setShape({points:p}),c&&(c.stopAnimation(),c.setShape({points:p,stackedOnPoints:g}));return}u.shape.__points=h.current,u.shape.points=v;var y={shape:{points:p}};h.current!==v&&(y.shape.__points=h.next),u.stopAnimation(),Qe(u,y,f),c&&(c.setShape({points:v,stackedOnPoints:d}),c.stopAnimation(),Qe(c,{shape:{stackedOnPoints:g}},f),u.shape.points!==c.shape.points&&(c.shape.points=u.shape.points));for(var m=[],_=h.status,b=0;b<_.length;b++){var x=_[b].cmd;if(x==="="){var M=t.getItemGraphicEl(_[b].idx1);M&&m.push({el:M,ptIdx:b})}}u.animators&&u.animators.length&&u.animators[0].during(function(){c&&c.dirtyShape();for(var w=u.shape.__points,D=0;D<m.length;D++){var T=m[D].el,I=m[D].ptIdx*2;T.x=w[I],T.y=w[I+1],T.markRedraw()}})},e.prototype.remove=function(t){var n=this.group,a=this._data;this._lineGroup.removeAll(),this._symbolDraw.remove(!0),a&&a.eachItemGraphicEl(function(i,o){i.__temp&&(n.remove(i),a.setItemGraphicEl(o,null))}),this._polyline=this._polygon=this._coordSys=this._points=this._stackedOnPoints=this._endLabel=this._data=null},e.type="line",e}(ht),MZ=bZ;function Uf(r,e){return{seriesType:r,plan:hu(),reset:function(t){var n=t.getData(),a=t.coordinateSystem,i=t.pipelineContext,o=e||i.large;if(!!a){var s=K(a.dimensions,function(v){return n.mapDimension(v)}).slice(0,2),l=s.length,u=n.getCalculationInfo("stackResultDimension");xi(n,s[0])&&(s[0]=u),xi(n,s[1])&&(s[1]=u);var c=n.getStore(),f=n.getDimensionIndex(s[0]),h=n.getDimensionIndex(s[1]);return l&&{progress:function(v,d){for(var p=v.end-v.start,g=o&&Ya(p*l),y=[],m=[],_=v.start,b=0;_<v.end;_++){var x=void 0;if(l===1){var M=c.get(f,_);x=a.dataToPoint(M,null,m)}else y[0]=c.get(f,_),y[1]=c.get(h,_),x=a.dataToPoint(y,null,m);o?(g[b++]=x[0],g[b++]=x[1]):d.setItemLayout(_,x.slice())}o&&d.setLayout("points",g)}}}}}}var xZ={average:function(r){for(var e=0,t=0,n=0;n<r.length;n++)isNaN(r[n])||(e+=r[n],t++);return t===0?NaN:e/t},sum:function(r){for(var e=0,t=0;t<r.length;t++)e+=r[t]||0;return e},max:function(r){for(var e=-1/0,t=0;t<r.length;t++)r[t]>e&&(e=r[t]);return isFinite(e)?e:NaN},min:function(r){for(var e=1/0,t=0;t<r.length;t++)r[t]<e&&(e=r[t]);return isFinite(e)?e:NaN},nearest:function(r){return r[0]}},wZ=function(r){return Math.round(r.length/2)};function bE(r){return{seriesType:r,reset:function(e,t,n){var a=e.getData(),i=e.get("sampling"),o=e.coordinateSystem,s=a.count();if(s>10&&o.type==="cartesian2d"&&i){var l=o.getBaseAxis(),u=o.getOtherAxis(l),c=l.getExtent(),f=n.getDevicePixelRatio(),h=Math.abs(c[1]-c[0])*(f||1),v=Math.round(s/h);if(isFinite(v)&&v>1){i==="lttb"&&e.setData(a.lttbDownSample(a.mapDimension(u.dim),1/v));var d=void 0;ce(i)?d=xZ[i]:ye(i)&&(d=i),d&&e.setData(a.downSample(a.mapDimension(u.dim),1/v,d,wZ))}}}}}function DZ(r){r.registerChartView(MZ),r.registerSeriesModel(rZ),r.registerLayout(Uf("line",!0)),r.registerVisual({seriesType:"line",reset:function(e){var t=e.getData(),n=e.getModel("lineStyle").getLineStyle();n&&!n.stroke&&(n.stroke=t.getVisual("style").fill),t.setVisual("legendLineStyle",n)}}),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,bE("line"))}var ME=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.getInitialData=function(t,n){return Ua(null,this,{useEncodeDefaulter:!0})},e.prototype.getMarkerPosition=function(t,n,a){var i=this.coordinateSystem;if(i&&i.clampData){var o=i.dataToPoint(i.clampData(t));if(a)C(i.getAxes(),function(f,h){if(f.type==="category"){var v=f.getTicksCoords(),d=i.clampData(t)[h];n&&(n[h]==="x1"||n[h]==="y1")&&(d+=1),d>v.length-1&&(d=v.length-1),d<0&&(d=0),v[d]&&(o[h]=f.toGlobalCoord(v[d].coord))}});else{var s=this.getData(),l=s.getLayout("offset"),u=s.getLayout("size"),c=i.getBaseAxis().isHorizontal()?0:1;o[c]+=l+u/2}return o}return[NaN,NaN]},e.type="series.__base_bar__",e.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,barMinHeight:0,barMinAngle:0,large:!1,largeThreshold:400,progressive:3e3,progressiveChunkMode:"mod"},e}(bt);bt.registerClass(ME);var Ep=ME,SZ=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.getInitialData=function(){return Ua(null,this,{useEncodeDefaulter:!0,createInvertedIndices:!!this.get("realtimeSort",!0)||null})},e.prototype.getProgressive=function(){return this.get("large")?this.get("progressive"):!1},e.prototype.getProgressiveThreshold=function(){var t=this.get("progressiveThreshold"),n=this.get("largeThreshold");return n>t&&(t=n),t},e.prototype.brushSelector=function(t,n,a){return a.rect(n.getItemLayout(t))},e.type="series.bar",e.dependencies=["grid","polar"],e.defaultOption=co(Ep.defaultOption,{clip:!0,roundCap:!1,showBackground:!1,backgroundStyle:{color:"rgba(180, 180, 180, 0.2)",borderColor:null,borderWidth:0,borderType:"solid",borderRadius:0,shadowBlur:0,shadowColor:null,shadowOffsetX:0,shadowOffsetY:0,opacity:1},select:{itemStyle:{borderColor:"#212121"}},realtimeSort:!1}),e}(Ep),IZ=SZ,TZ=function(){function r(){this.cx=0,this.cy=0,this.r0=0,this.r=0,this.startAngle=0,this.endAngle=Math.PI*2,this.clockwise=!0}return r}(),AZ=function(r){U(e,r);function e(t){var n=r.call(this,t)||this;return n.type="sausage",n}return e.prototype.getDefaultShape=function(){return new TZ},e.prototype.buildPath=function(t,n){var a=n.cx,i=n.cy,o=Math.max(n.r0||0,0),s=Math.max(n.r,0),l=(s-o)*.5,u=o+l,c=n.startAngle,f=n.endAngle,h=n.clockwise,v=Math.PI*2,d=h?f-c<v:c-f<v;d||(c=f-(h?v:-v));var p=Math.cos(c),g=Math.sin(c),y=Math.cos(f),m=Math.sin(f);d?(t.moveTo(p*o+a,g*o+i),t.arc(p*u+a,g*u+i,l,-Math.PI+c,c,!h)):t.moveTo(p*s+a,g*s+i),t.arc(a,i,s,c,f,!h),t.arc(y*u+a,m*u+i,l,f-Math.PI*2,f-Math.PI,!h),o!==0&&t.arc(a,i,o,f,c,h)},e}(je),Op=AZ;function CZ(r,e){e=e||{};var t=e.isRoundCap;return function(n,a,i){var o=a.position;if(!o||o instanceof Array)return Kv(n,a,i);var s=r(o),l=a.distance!=null?a.distance:5,u=this.shape,c=u.cx,f=u.cy,h=u.r,v=u.r0,d=(h+v)/2,p=u.startAngle,g=u.endAngle,y=(p+g)/2,m=t?Math.abs(h-v)/2:0,_=Math.cos,b=Math.sin,x=c+h*_(p),M=f+h*b(p),w="left",D="top";switch(s){case"startArc":x=c+(v-l)*_(y),M=f+(v-l)*b(y),w="center",D="top";break;case"insideStartArc":x=c+(v+l)*_(y),M=f+(v+l)*b(y),w="center",D="bottom";break;case"startAngle":x=c+d*_(p)+Pp(p,l+m,!1),M=f+d*b(p)+zp(p,l+m,!1),w="right",D="middle";break;case"insideStartAngle":x=c+d*_(p)+Pp(p,-l+m,!1),M=f+d*b(p)+zp(p,-l+m,!1),w="left",D="middle";break;case"middle":x=c+d*_(y),M=f+d*b(y),w="center",D="middle";break;case"endArc":x=c+(h+l)*_(y),M=f+(h+l)*b(y),w="center",D="bottom";break;case"insideEndArc":x=c+(h-l)*_(y),M=f+(h-l)*b(y),w="center",D="top";break;case"endAngle":x=c+d*_(g)+Pp(g,l+m,!0),M=f+d*b(g)+zp(g,l+m,!0),w="left",D="middle";break;case"insideEndAngle":x=c+d*_(g)+Pp(g,-l+m,!0),M=f+d*b(g)+zp(g,-l+m,!0),w="right",D="middle";break;default:return Kv(n,a,i)}return n=n||{},n.x=x,n.y=M,n.align=w,n.verticalAlign=D,n}}function NZ(r,e,t,n){if(Ue(n)){r.setTextConfig({rotation:n});return}else if(J(e)){r.setTextConfig({rotation:0});return}var a=r.shape,i=a.clockwise?a.startAngle:a.endAngle,o=a.clockwise?a.endAngle:a.startAngle,s=(i+o)/2,l,u=t(e);switch(u){case"startArc":case"insideStartArc":case"middle":case"insideEndArc":case"endArc":l=s;break;case"startAngle":case"insideStartAngle":l=i;break;case"endAngle":case"insideEndAngle":l=o;break;default:r.setTextConfig({rotation:0});return}var c=Math.PI*1.5-l;u==="middle"&&c>Math.PI/2&&c<Math.PI*1.5&&(c-=Math.PI),r.setTextConfig({rotation:c})}function Pp(r,e,t){return e*Math.sin(r)*(t?-1:1)}function zp(r,e,t){return e*Math.cos(r)*(t?1:-1)}var cb=Math.max,fb=Math.min;function LZ(r,e){var t=r.getArea&&r.getArea();if(Hs(r,"cartesian2d")){var n=r.getBaseAxis();if(n.type!=="category"||!n.onBand){var a=e.getLayout("bandWidth");n.isHorizontal()?(t.x-=a,t.width+=a*2):(t.y-=a,t.height+=a*2)}}return t}var EZ=function(r){U(e,r);function e(){var t=r.call(this)||this;return t.type=e.type,t._isFirstFrame=!0,t}return e.prototype.render=function(t,n,a,i){this._model=t,this._removeOnRenderedListener(a),this._updateDrawMode(t);var o=t.get("coordinateSystem");(o==="cartesian2d"||o==="polar")&&(this._progressiveEls=null,this._isLargeDraw?this._renderLarge(t,n,a):this._renderNormal(t,n,a,i))},e.prototype.incrementalPrepareRender=function(t){this._clear(),this._updateDrawMode(t),this._updateLargeClip(t)},e.prototype.incrementalRender=function(t,n){this._progressiveEls=[],this._incrementalRenderLarge(t,n)},e.prototype.eachRendered=function(t){uo(this._progressiveEls||this.group,t)},e.prototype._updateDrawMode=function(t){var n=t.pipelineContext.large;(this._isLargeDraw==null||n!==this._isLargeDraw)&&(this._isLargeDraw=n,this._clear())},e.prototype._renderNormal=function(t,n,a,i){var o=this.group,s=t.getData(),l=this._data,u=t.coordinateSystem,c=u.getBaseAxis(),f;u.type==="cartesian2d"?f=c.isHorizontal():u.type==="polar"&&(f=c.dim==="angle");var h=t.isAnimationEnabled()?t:null,v=OZ(t,u);v&&this._enableRealtimeSort(v,s,a);var d=t.get("clip",!0)||v,p=LZ(u,s);o.removeClipPath();var g=t.get("roundCap",!0),y=t.get("showBackground",!0),m=t.getModel("backgroundStyle"),_=m.get("borderRadius")||0,b=[],x=this._backgroundEls,M=i&&i.isInitSort,w=i&&i.type==="changeAxisOrder";function D(A){var N=kp[u.type](s,A),L=FZ(u,f,N);return L.useStyle(m.getItemStyle()),u.type==="cartesian2d"&&L.setShape("r",_),b[A]=L,L}s.diff(l).add(function(A){var N=s.getItemModel(A),L=kp[u.type](s,A,N);if(y&&D(A),!(!s.hasValue(A)||!IE[u.type](L))){var E=!1;d&&(E=xE[u.type](p,L));var O=wE[u.type](t,s,A,L,f,h,c.model,!1,g);v&&(O.forceLabelAnimation=!0),AE(O,s,A,N,L,t,f,u.type==="polar"),M?O.attr({shape:L}):v?DE(v,h,O,L,A,f,!1,!1):Dt(O,{shape:L},t,A),s.setItemGraphicEl(A,O),o.add(O),O.ignore=E}}).update(function(A,N){var L=s.getItemModel(A),E=kp[u.type](s,A,L);if(y){var O=void 0;x.length===0?O=D(N):(O=x[N],O.useStyle(m.getItemStyle()),u.type==="cartesian2d"&&O.setShape("r",_),b[A]=O);var P=kp[u.type](s,A),H=EE(f,P,u);Qe(O,{shape:H},h,A)}var F=l.getItemGraphicEl(N);if(!s.hasValue(A)||!IE[u.type](E)){o.remove(F);return}var G=!1;if(d&&(G=xE[u.type](p,E),G&&o.remove(F)),F?ya(F):F=wE[u.type](t,s,A,E,f,h,c.model,!!F,g),v&&(F.forceLabelAnimation=!0),w){var Z=F.getTextContent();if(Z){var te=tu(Z);te.prevValue!=null&&(te.prevValue=te.value)}}else AE(F,s,A,L,E,t,f,u.type==="polar");M?F.attr({shape:E}):v?DE(v,h,F,E,A,f,!0,w):Qe(F,{shape:E},t,A,null),s.setItemGraphicEl(A,F),F.ignore=G,o.add(F)}).remove(function(A){var N=l.getItemGraphicEl(A);N&&af(N,t,A)}).execute();var T=this._backgroundGroup||(this._backgroundGroup=new De);T.removeAll();for(var I=0;I<b.length;++I)T.add(b[I]);o.add(T),this._backgroundEls=b,this._data=s},e.prototype._renderLarge=function(t,n,a){this._clear(),NE(t,this.group),this._updateLargeClip(t)},e.prototype._incrementalRenderLarge=function(t,n){this._removeBackground(),NE(n,this.group,this._progressiveEls,!0)},e.prototype._updateLargeClip=function(t){var n=t.get("clip",!0)&&Lp(t.coordinateSystem,!1,t),a=this.group;n?a.setClipPath(n):a.removeClipPath()},e.prototype._enableRealtimeSort=function(t,n,a){var i=this;if(!!n.count()){var o=t.baseAxis;if(this._isFirstFrame)this._dispatchInitSort(n,t,a),this._isFirstFrame=!1;else{var s=function(l){var u=n.getItemGraphicEl(l),c=u&&u.shape;return c&&Math.abs(o.isHorizontal()?c.height:c.width)||0};this._onRendered=function(){i._updateSortWithinSameData(n,s,o,a)},a.getZr().on("rendered",this._onRendered)}}},e.prototype._dataSort=function(t,n,a){var i=[];return t.each(t.mapDimension(n.dim),function(o,s){var l=a(s);l=l==null?NaN:l,i.push({dataIndex:s,mappedValue:l,ordinalNumber:o})}),i.sort(function(o,s){return s.mappedValue-o.mappedValue}),{ordinalNumbers:K(i,function(o){return o.ordinalNumber})}},e.prototype._isOrderChangedWithinSameData=function(t,n,a){for(var i=a.scale,o=t.mapDimension(a.dim),s=Number.MAX_VALUE,l=0,u=i.getOrdinalMeta().categories.length;l<u;++l){var c=t.rawIndexOf(o,i.getRawOrdinalNumber(l)),f=c<0?Number.MIN_VALUE:n(t.indexOfRawIndex(c));if(f>s)return!0;s=f}return!1},e.prototype._isOrderDifferentInView=function(t,n){for(var a=n.scale,i=a.getExtent(),o=Math.max(0,i[0]),s=Math.min(i[1],a.getOrdinalMeta().categories.length-1);o<=s;++o)if(t.ordinalNumbers[o]!==a.getRawOrdinalNumber(o))return!0},e.prototype._updateSortWithinSameData=function(t,n,a,i){if(!!this._isOrderChangedWithinSameData(t,n,a)){var o=this._dataSort(t,a,n);this._isOrderDifferentInView(o,a)&&(this._removeOnRenderedListener(i),i.dispatchAction({type:"changeAxisOrder",componentType:a.dim+"Axis",axisId:a.index,sortInfo:o}))}},e.prototype._dispatchInitSort=function(t,n,a){var i=n.baseAxis,o=this._dataSort(t,i,function(s){return t.get(t.mapDimension(n.otherAxis.dim),s)});a.dispatchAction({type:"changeAxisOrder",componentType:i.dim+"Axis",isInitSort:!0,axisId:i.index,sortInfo:o})},e.prototype.remove=function(t,n){this._clear(this._model),this._removeOnRenderedListener(n)},e.prototype.dispose=function(t,n){this._removeOnRenderedListener(n)},e.prototype._removeOnRenderedListener=function(t){this._onRendered&&(t.getZr().off("rendered",this._onRendered),this._onRendered=null)},e.prototype._clear=function(t){var n=this.group,a=this._data;t&&t.isAnimationEnabled()&&a&&!this._isLargeDraw?(this._removeBackground(),this._backgroundEls=[],a.eachItemGraphicEl(function(i){af(i,t,Te(i).dataIndex)})):n.removeAll(),this._data=null,this._isFirstFrame=!0},e.prototype._removeBackground=function(){this.group.remove(this._backgroundGroup),this._backgroundGroup=null},e.type="bar",e}(ht),xE={cartesian2d:function(r,e){var t=e.width<0?-1:1,n=e.height<0?-1:1;t<0&&(e.x+=e.width,e.width=-e.width),n<0&&(e.y+=e.height,e.height=-e.height);var a=r.x+r.width,i=r.y+r.height,o=cb(e.x,r.x),s=fb(e.x+e.width,a),l=cb(e.y,r.y),u=fb(e.y+e.height,i),c=s<o,f=u<l;return e.x=c&&o>a?s:o,e.y=f&&l>i?u:l,e.width=c?0:s-o,e.height=f?0:u-l,t<0&&(e.x+=e.width,e.width=-e.width),n<0&&(e.y+=e.height,e.height=-e.height),c||f},polar:function(r,e){var t=e.r0<=e.r?1:-1;if(t<0){var n=e.r;e.r=e.r0,e.r0=n}var a=fb(e.r,r.r),i=cb(e.r0,r.r0);e.r=a,e.r0=i;var o=a-i<0;if(t<0){var n=e.r;e.r=e.r0,e.r0=n}return o}},wE={cartesian2d:function(r,e,t,n,a,i,o,s,l){var u=new We({shape:X({},n),z2:1});if(u.__dataIndex=t,u.name="item",i){var c=u.shape,f=a?"height":"width";c[f]=0}return u},polar:function(r,e,t,n,a,i,o,s,l){var u=!a&&l?Op:Zr,c=new u({shape:n,z2:1});c.name="item";var f=TE(a);if(c.calculateTextPosition=CZ(f,{isRoundCap:u===Op}),i){var h=c.shape,v=a?"r":"endAngle",d={};h[v]=a?0:n.startAngle,d[v]=n[v],(s?Qe:Dt)(c,{shape:d},i)}return c}};function OZ(r,e){var t=r.get("realtimeSort",!0),n=e.getBaseAxis();if(t&&n.type==="category"&&e.type==="cartesian2d")return{baseAxis:n,otherAxis:e.getOtherAxis(n)}}function DE(r,e,t,n,a,i,o,s){var l,u;i?(u={x:n.x,width:n.width},l={y:n.y,height:n.height}):(u={y:n.y,height:n.height},l={x:n.x,width:n.width}),s||(o?Qe:Dt)(t,{shape:l},e,a,null);var c=e?r.baseAxis.model:null;(o?Qe:Dt)(t,{shape:u},c,a)}function SE(r,e){for(var t=0;t<e.length;t++)if(!isFinite(r[e[t]]))return!0;return!1}var PZ=["x","y","width","height"],zZ=["cx","cy","r","startAngle","endAngle"],IE={cartesian2d:function(r){return!SE(r,PZ)},polar:function(r){return!SE(r,zZ)}},kp={cartesian2d:function(r,e,t){var n=r.getItemLayout(e),a=t?RZ(t,n):0,i=n.width>0?1:-1,o=n.height>0?1:-1;return{x:n.x+i*a/2,y:n.y+o*a/2,width:n.width-i*a,height:n.height-o*a}},polar:function(r,e,t){var n=r.getItemLayout(e);return{cx:n.cx,cy:n.cy,r0:n.r0,r:n.r,startAngle:n.startAngle,endAngle:n.endAngle,clockwise:n.clockwise}}};function kZ(r){return r.startAngle!=null&&r.endAngle!=null&&r.startAngle===r.endAngle}function TE(r){return function(e){var t=e?"Arc":"Angle";return function(n){switch(n){case"start":case"insideStart":case"end":case"insideEnd":return n+t;default:return n}}}(r)}function AE(r,e,t,n,a,i,o,s){var l=e.getItemVisual(t,"style");s||r.setShape("r",n.get(["itemStyle","borderRadius"])||0),r.useStyle(l);var u=n.getShallow("cursor");u&&r.attr("cursor",u);var c=s?o?a.r>=a.r0?"endArc":"startArc":a.endAngle>=a.startAngle?"endAngle":"startAngle":o?a.height>=0?"bottom":"top":a.width>=0?"right":"left",f=sr(n);wr(r,f,{labelFetcher:i,labelDataIndex:t,defaultText:wu(i.getData(),t),inheritColor:l.fill,defaultOpacity:l.opacity,defaultOutsidePosition:c});var h=r.getTextContent();if(s&&h){var v=n.get(["label","position"]);r.textConfig.inside=v==="middle"?!0:null,NZ(r,v==="outside"?c:v,TE(o),n.get(["label","rotate"]))}YA(h,f,i.getRawValue(t),function(p){return iE(e,p)});var d=n.getModel(["emphasis"]);Lt(r,d.get("focus"),d.get("blurScope"),d.get("disabled")),xr(r,n),kZ(a)&&(r.style.fill="none",r.style.stroke="none",C(r.states,function(p){p.style&&(p.style.fill=p.style.stroke="none")}))}function RZ(r,e){var t=r.get(["itemStyle","borderColor"]);if(!t||t==="none")return 0;var n=r.get(["itemStyle","borderWidth"])||0,a=isNaN(e.width)?Number.MAX_VALUE:Math.abs(e.width),i=isNaN(e.height)?Number.MAX_VALUE:Math.abs(e.height);return Math.min(n,a,i)}var jZ=function(){function r(){}return r}(),CE=function(r){U(e,r);function e(t){var n=r.call(this,t)||this;return n.type="largeBar",n}return e.prototype.getDefaultShape=function(){return new jZ},e.prototype.buildPath=function(t,n){for(var a=n.points,i=this.baseDimIdx,o=1-this.baseDimIdx,s=[],l=[],u=this.barWidth,c=0;c<a.length;c+=3)l[i]=u,l[o]=a[c+2],s[i]=a[c+i],s[o]=a[c+o],t.rect(s[0],s[1],l[0],l[1])},e}(je);function NE(r,e,t,n){var a=r.getData(),i=a.getLayout("valueAxisHorizontal")?1:0,o=a.getLayout("largeDataIndices"),s=a.getLayout("size"),l=r.getModel("backgroundStyle"),u=a.getLayout("largeBackgroundPoints");if(u){var c=new CE({shape:{points:u},incremental:!!n,silent:!0,z2:0});c.baseDimIdx=i,c.largeDataIndices=o,c.barWidth=s,c.useStyle(l.getItemStyle()),e.add(c),t&&t.push(c)}var f=new CE({shape:{points:a.getLayout("largePoints")},incremental:!!n,ignoreCoarsePointer:!0,z2:1});f.baseDimIdx=i,f.largeDataIndices=o,f.barWidth=s,e.add(f),f.useStyle(a.getVisual("style")),Te(f).seriesIndex=r.seriesIndex,r.get("silent")||(f.on("mousedown",LE),f.on("mousemove",LE)),t&&t.push(f)}var LE=qd(function(r){var e=this,t=BZ(e,r.offsetX,r.offsetY);Te(e).dataIndex=t>=0?t:null},30,!1);function BZ(r,e,t){for(var n=r.baseDimIdx,a=1-n,i=r.shape.points,o=r.largeDataIndices,s=[],l=[],u=r.barWidth,c=0,f=i.length/3;c<f;c++){var h=c*3;if(l[n]=u,l[a]=i[h+2],s[n]=i[h+n],s[a]=i[h+a],l[a]<0&&(s[a]+=l[a],l[a]=-l[a]),e>=s[0]&&e<=s[0]+l[0]&&t>=s[1]&&t<=s[1]+l[1])return o[c]}return-1}function EE(r,e,t){if(Hs(t,"cartesian2d")){var n=e,a=t.getArea();return{x:r?n.x:a.x,y:r?a.y:n.y,width:r?n.width:a.width,height:r?a.height:n.height}}else{var a=t.getArea(),i=e;return{cx:a.cx,cy:a.cy,r0:r?a.r0:i.r0,r:r?a.r:i.r,startAngle:r?i.startAngle:0,endAngle:r?i.endAngle:Math.PI*2}}}function FZ(r,e,t){var n=r.type==="polar"?Zr:We;return new n({shape:EE(e,t,r),silent:!0,z2:0})}var VZ=EZ;function HZ(r){r.registerChartView(VZ),r.registerSeriesModel(IZ),r.registerLayout(r.PRIORITY.VISUAL.LAYOUT,Ae(ZL,"bar")),r.registerLayout(r.PRIORITY.VISUAL.PROGRESSIVE_LAYOUT,qL("bar")),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,bE("bar")),r.registerAction({type:"changeAxisOrder",event:"changeAxisOrder",update:"update"},function(e,t){var n=e.componentType||"series";t.eachComponent({mainType:n,query:e},function(a){e.sortInfo&&a.axis.setCategorySortInfo(e.sortInfo)})})}var Rp=Math.PI*2,OE=Math.PI/180;function PE(r,e){return Yt(r.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}function zE(r,e){var t=PE(r,e),n=r.get("center"),a=r.get("radius");J(a)||(a=[0,a]);var i=ue(t.width,e.getWidth()),o=ue(t.height,e.getHeight()),s=Math.min(i,o),l=ue(a[0],s/2),u=ue(a[1],s/2),c,f,h=r.coordinateSystem;if(h){var v=h.dataToPoint(n);c=v[0]||0,f=v[1]||0}else J(n)||(n=[n,n]),c=ue(n[0],i)+t.x,f=ue(n[1],o)+t.y;return{cx:c,cy:f,r0:l,r:u}}function WZ(r,e,t){e.eachSeriesByType(r,function(n){var a=n.getData(),i=a.mapDimension("value"),o=PE(n,t),s=zE(n,t),l=s.cx,u=s.cy,c=s.r,f=s.r0,h=-n.get("startAngle")*OE,v=n.get("minAngle")*OE,d=0;a.each(i,function(I){!isNaN(I)&&d++});var p=a.getSum(i),g=Math.PI/(p||d)*2,y=n.get("clockwise"),m=n.get("roseType"),_=n.get("stillShowZeroSum"),b=a.getDataExtent(i);b[0]=0;var x=Rp,M=0,w=h,D=y?1:-1;if(a.setLayout({viewRect:o,r:c}),a.each(i,function(I,A){var N;if(isNaN(I)){a.setItemLayout(A,{angle:NaN,startAngle:NaN,endAngle:NaN,clockwise:y,cx:l,cy:u,r0:f,r:m?NaN:c});return}m!=="area"?N=p===0&&_?g:I*g:N=Rp/d,N<v?(N=v,x-=v):M+=I;var L=w+D*N;a.setItemLayout(A,{angle:N,startAngle:w,endAngle:L,clockwise:y,cx:l,cy:u,r0:f,r:m?st(I,b,[f,c]):c}),w=L}),x<Rp&&d)if(x<=.001){var T=Rp/d;a.each(i,function(I,A){if(!isNaN(I)){var N=a.getItemLayout(A);N.angle=T,N.startAngle=h+D*A*T,N.endAngle=h+D*(A+1)*T}})}else g=x/M,w=h,a.each(i,function(I,A){if(!isNaN(I)){var N=a.getItemLayout(A),L=N.angle===v?v:I*g;N.startAngle=w,N.endAngle=w+D*L,w+=D*L}})})}function Yf(r){return{seriesType:r,reset:function(e,t){var n=t.findComponents({mainType:"legend"});if(!(!n||!n.length)){var a=e.getData();a.filterSelf(function(i){for(var o=a.getName(i),s=0;s<n.length;s++)if(!n[s].isSelected(o))return!1;return!0})}}}}var GZ=Math.PI/180;function kE(r,e,t,n,a,i,o,s,l,u){if(r.length<2)return;function c(p){for(var g=p.rB,y=g*g,m=0;m<p.list.length;m++){var _=p.list[m],b=Math.abs(_.label.y-t),x=n+_.len,M=x*x,w=Math.sqrt((1-Math.abs(b*b/y))*M),D=e+(w+_.len2)*a,T=D-_.label.x,I=_.targetTextWidth-T*a;RE(_,I,!0),_.label.x=D}}function f(p){for(var g={list:[],maxY:0},y={list:[],maxY:0},m=0;m<p.length;m++)if(p[m].labelAlignTo==="none"){var _=p[m],b=_.label.y>t?y:g,x=Math.abs(_.label.y-t);if(x>=b.maxY){var M=_.label.x-e-_.len2*a,w=n+_.len,D=Math.abs(M)<w?Math.sqrt(x*x/(1-M*M/w/w)):w;b.rB=D,b.maxY=x}b.list.push(_)}c(g),c(y)}for(var h=r.length,v=0;v<h;v++)if(r[v].position==="outer"&&r[v].labelAlignTo==="labelLine"){var d=r[v].label.x-u;r[v].linePoints[1][0]+=d,r[v].label.x=u}A2(r,l,l+o)&&f(r)}function $Z(r,e,t,n,a,i,o,s){for(var l=[],u=[],c=Number.MAX_VALUE,f=-Number.MAX_VALUE,h=0;h<r.length;h++){var v=r[h].label;hb(r[h])||(v.x<e?(c=Math.min(c,v.x),l.push(r[h])):(f=Math.max(f,v.x),u.push(r[h])))}for(var h=0;h<r.length;h++){var d=r[h];if(!hb(d)&&d.linePoints){if(d.labelStyleWidth!=null)continue;var v=d.label,p=d.linePoints,g=void 0;d.labelAlignTo==="edge"?v.x<e?g=p[2][0]-d.labelDistance-o-d.edgeDistance:g=o+a-d.edgeDistance-p[2][0]-d.labelDistance:d.labelAlignTo==="labelLine"?v.x<e?g=c-o-d.bleedMargin:g=o+a-f-d.bleedMargin:v.x<e?g=v.x-o-d.bleedMargin:g=o+a-v.x-d.bleedMargin,d.targetTextWidth=g,RE(d,g)}}kE(u,e,t,n,1,a,i,o,s,f),kE(l,e,t,n,-1,a,i,o,s,c);for(var h=0;h<r.length;h++){var d=r[h];if(!hb(d)&&d.linePoints){var v=d.label,p=d.linePoints,y=d.labelAlignTo==="edge",m=v.style.padding,_=m?m[1]+m[3]:0,b=v.style.backgroundColor?0:_,x=d.rect.width+b,M=p[1][0]-p[2][0];y?v.x<e?p[2][0]=o+d.edgeDistance+x+d.labelDistance:p[2][0]=o+a-d.edgeDistance-x-d.labelDistance:(v.x<e?p[2][0]=v.x+d.labelDistance:p[2][0]=v.x-d.labelDistance,p[1][0]=p[2][0]+M),p[1][1]=p[2][1]=v.y}}}function RE(r,e,t){if(t===void 0&&(t=!1),r.labelStyleWidth==null){var n=r.label,a=n.style,i=r.rect,o=a.backgroundColor,s=a.padding,l=s?s[1]+s[3]:0,u=a.overflow,c=i.width+(o?0:l);if(e<c||t){var f=i.height;if(u&&u.match("break")){n.setStyle("backgroundColor",null),n.setStyle("width",e-l);var h=n.getBoundingRect();n.setStyle("width",Math.ceil(h.width)),n.setStyle("backgroundColor",o)}else{var v=e-l,d=e<c?v:t?v>r.unconstrainedWidth?null:v:null;n.setStyle("width",d)}var p=n.getBoundingRect();i.width=p.width;var g=(n.style.margin||0)+2.1;i.height=p.height+g,i.y-=(i.height-f)/2}}}function hb(r){return r.position==="center"}function UZ(r){var e=r.getData(),t=[],n,a,i=!1,o=(r.get("minShowLabelAngle")||0)*GZ,s=e.getLayout("viewRect"),l=e.getLayout("r"),u=s.width,c=s.x,f=s.y,h=s.height;function v(M){M.ignore=!0}function d(M){if(!M.ignore)return!0;for(var w in M.states)if(M.states[w].ignore===!1)return!0;return!1}e.each(function(M){var w=e.getItemGraphicEl(M),D=w.shape,T=w.getTextContent(),I=w.getTextGuideLine(),A=e.getItemModel(M),N=A.getModel("label"),L=N.get("position")||A.get(["emphasis","label","position"]),E=N.get("distanceToLabelLine"),O=N.get("alignTo"),P=ue(N.get("edgeDistance"),u),H=N.get("bleedMargin"),F=A.getModel("labelLine"),G=F.get("length");G=ue(G,u);var Z=F.get("length2");if(Z=ue(Z,u),Math.abs(D.endAngle-D.startAngle)<o){C(T.states,v),T.ignore=!0,I&&(C(I.states,v),I.ignore=!0);return}if(!!d(T)){var te=(D.startAngle+D.endAngle)/2,V=Math.cos(te),Y=Math.sin(te),q,Q,ne,oe;n=D.cx,a=D.cy;var ie=L==="inside"||L==="inner";if(L==="center")q=D.cx,Q=D.cy,oe="center";else{var he=(ie?(D.r+D.r0)/2*V:D.r*V)+n,k=(ie?(D.r+D.r0)/2*Y:D.r*Y)+a;if(q=he+V*3,Q=k+Y*3,!ie){var j=he+V*(G+l-D.r),W=k+Y*(G+l-D.r),ae=j+(V<0?-1:1)*Z,re=W;O==="edge"?q=V<0?c+P:c+u-P:q=ae+(V<0?-E:E),Q=re,ne=[[he,k],[j,W],[ae,re]]}oe=ie?"center":O==="edge"?V>0?"right":"left":V>0?"left":"right"}var ee=Math.PI,se=0,Le=N.get("rotate");if(Ue(Le))se=Le*(ee/180);else if(L==="center")se=0;else if(Le==="radial"||Le===!0){var dt=V<0?-te+ee:-te;se=dt}else if(Le==="tangential"&&L!=="outside"&&L!=="outer"){var pt=Math.atan2(V,Y);pt<0&&(pt=ee*2+pt);var _t=Y>0;_t&&(pt=ee+pt),se=pt-ee}if(i=!!se,T.x=q,T.y=Q,T.rotation=se,T.setStyle({verticalAlign:"middle"}),ie){T.setStyle({align:oe});var Cn=T.states.select;Cn&&(Cn.x+=T.x,Cn.y+=T.y)}else{var zt=T.getBoundingRect().clone();zt.applyTransform(T.getComputedTransform());var qt=(T.style.margin||0)+2.1;zt.y-=qt/2,zt.height+=qt,t.push({label:T,labelLine:I,position:L,len:G,len2:Z,minTurnAngle:F.get("minTurnAngle"),maxSurfaceAngle:F.get("maxSurfaceAngle"),surfaceNormal:new Oe(V,Y),linePoints:ne,textAlign:oe,labelDistance:E,labelAlignTo:O,edgeDistance:P,bleedMargin:H,rect:zt,unconstrainedWidth:zt.width,labelStyleWidth:T.style.width})}w.setTextConfig({inside:ie})}}),!i&&r.get("avoidLabelOverlap")&&$Z(t,n,a,l,u,h,c,f);for(var p=0;p<t.length;p++){var g=t[p],y=g.label,m=g.labelLine,_=isNaN(y.x)||isNaN(y.y);if(y){y.setStyle({align:g.textAlign}),_&&(C(y.states,v),y.ignore=!0);var b=y.states.select;b&&(b.x+=y.x,b.y+=y.y)}if(m){var x=g.linePoints;_||!x?(C(m.states,v),m.ignore=!0):(D2(x,g.minTurnAngle),i8(x,g.surfaceNormal,g.maxSurfaceAngle),m.setShape({points:x}),y.__hostTarget.textGuideLineConfig={anchor:new Oe(x[0][0],x[0][1])})}}}function Du(r,e,t){var n=r.get("borderRadius");if(n==null)return t?{cornerRadius:0}:null;J(n)||(n=[n,n,n,n]);var a=Math.abs(e.r||0-e.r0||0);return{cornerRadius:K(n,function(i){return va(i,a)})}}var YZ=function(r){U(e,r);function e(t,n,a){var i=r.call(this)||this;i.z2=2;var o=new Ge;return i.setTextContent(o),i.updateData(t,n,a,!0),i}return e.prototype.updateData=function(t,n,a,i){var o=this,s=t.hostModel,l=t.getItemModel(n),u=l.getModel("emphasis"),c=t.getItemLayout(n),f=X(Du(l.getModel("itemStyle"),c,!0),c);if(isNaN(f.startAngle)){o.setShape(f);return}if(i){o.setShape(f);var h=s.getShallow("animationType");s.ecModel.ssr?(Dt(o,{scaleX:0,scaleY:0},s,{dataIndex:n,isFrom:!0}),o.originX=f.cx,o.originY=f.cy):h==="scale"?(o.shape.r=c.r0,Dt(o,{shape:{r:c.r}},s,n)):a!=null?(o.setShape({startAngle:a,endAngle:a}),Dt(o,{shape:{startAngle:c.startAngle,endAngle:c.endAngle}},s,n)):(o.shape.endAngle=c.startAngle,Qe(o,{shape:{endAngle:c.endAngle}},s,n))}else ya(o),Qe(o,{shape:f},s,n);o.useStyle(t.getItemVisual(n,"style")),xr(o,l);var v=(c.startAngle+c.endAngle)/2,d=s.get("selectedOffset"),p=Math.cos(v)*d,g=Math.sin(v)*d,y=l.getShallow("cursor");y&&o.attr("cursor",y),this._updateLabel(s,t,n),o.ensureState("emphasis").shape=X({r:c.r+(u.get("scale")&&u.get("scaleSize")||0)},Du(u.getModel("itemStyle"),c)),X(o.ensureState("select"),{x:p,y:g,shape:Du(l.getModel(["select","itemStyle"]),c)}),X(o.ensureState("blur"),{shape:Du(l.getModel(["blur","itemStyle"]),c)});var m=o.getTextGuideLine(),_=o.getTextContent();m&&X(m.ensureState("select"),{x:p,y:g}),X(_.ensureState("select"),{x:p,y:g}),Lt(this,u.get("focus"),u.get("blurScope"),u.get("disabled"))},e.prototype._updateLabel=function(t,n,a){var i=this,o=n.getItemModel(a),s=o.getModel("labelLine"),l=n.getItemVisual(a,"style"),u=l&&l.fill,c=l&&l.opacity;wr(i,sr(o),{labelFetcher:n.hostModel,labelDataIndex:a,inheritColor:u,defaultOpacity:c,defaultText:t.getFormattedLabel(a,"normal")||n.getName(a)});var f=i.getTextContent();i.setTextConfig({position:null,rotation:null}),f.attr({z2:10});var h=t.get(["label","position"]);if(h!=="outside"&&h!=="outer")i.removeTextGuideLine();else{var v=this.getTextGuideLine();v||(v=new Xr,this.setTextGuideLine(v)),U_(this,Y_(o),{stroke:u,opacity:Ea(s.get(["lineStyle","opacity"]),c,1)})}},e}(Zr),QZ=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.ignoreLabelLineUpdate=!0,t}return e.prototype.render=function(t,n,a,i){var o=t.getData(),s=this._data,l=this.group,u;if(!s&&o.count()>0){for(var c=o.getItemLayout(0),f=1;isNaN(c&&c.startAngle)&&f<o.count();++f)c=o.getItemLayout(f);c&&(u=c.startAngle)}if(this._emptyCircleSector&&l.remove(this._emptyCircleSector),o.count()===0&&t.get("showEmptyCircle")){var h=new Zr({shape:zE(t,a)});h.useStyle(t.getModel("emptyCircleStyle").getItemStyle()),this._emptyCircleSector=h,l.add(h)}o.diff(s).add(function(v){var d=new YZ(o,v,u);o.setItemGraphicEl(v,d),l.add(d)}).update(function(v,d){var p=s.getItemGraphicEl(d);p.updateData(o,v,u),p.off("click"),l.add(p),o.setItemGraphicEl(v,p)}).remove(function(v){var d=s.getItemGraphicEl(v);af(d,t,v)}).execute(),UZ(t),t.get("animationTypeUpdate")!=="expansion"&&(this._data=o)},e.prototype.dispose=function(){},e.prototype.containPoint=function(t,n){var a=n.getData(),i=a.getItemLayout(0);if(i){var o=t[0]-i.cx,s=t[1]-i.cy,l=Math.sqrt(o*o+s*s);return l<=i.r&&l>=i.r0}},e.type="pie",e}(ht),ZZ=QZ;function Su(r,e,t){e=J(e)&&{coordDimensions:e}||X({encodeDefine:r.getEncode()},e);var n=r.getSource(),a=_u(n,e).dimensions,i=new jr(a,r);return i.initData(n,t),i}var qZ=function(){function r(e,t){this._getDataWithEncodedVisual=e,this._getRawData=t}return r.prototype.getAllNames=function(){var e=this._getRawData();return e.mapArray(e.getName)},r.prototype.containName=function(e){var t=this._getRawData();return t.indexOfName(e)>=0},r.prototype.indexOfName=function(e){var t=this._getDataWithEncodedVisual();return t.indexOfName(e)},r.prototype.getItemVisual=function(e,t){var n=this._getDataWithEncodedVisual();return n.getItemVisual(e,t)},r}(),Qf=qZ,XZ=Ye(),JZ=function(r){U(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.init=function(t){r.prototype.init.apply(this,arguments),this.legendVisualProvider=new Qf(fe(this.getData,this),fe(this.getRawData,this)),this._defaultLabelLine(t)},e.prototype.mergeOption=function(){r.prototype.mergeOption.apply(this,arguments)},e.prototype.getInitialData=function(){return Su(this,{coordDimensions:["value"],encodeDefaulter:Ae(P1,this)})},e.prototype.getDataParams=function(t){var n=this.getData(),a=XZ(n),i=a.seats;if(!i){var o=[];n.each(n.mapDimension("value"),function(l){o.push(l)}),i=a.seats=qI(o,n.hostModel.get("percentPrecision"))}var s=r.prototype.getDataParams.call(this,t);return s.percent=i[t]||0,s.$vars.push("percent"),s},e.prototype._defaultLabelLine=function(t){ns(t,"labelLine",["show"]);var n=t.labelLine,a=t.emphasis.labelLine;n.show=n.show&&t.label.show,a.show=a.show&&t.emphasis.label.show},e.type="series.pie",e.defaultOption={z:2,legendHoverLink:!0,colorBy:"data",center:["50%","50%"],radius:[0,"75%"],clockwise:!0,startAngle:90,minAngle:0,minShowLabelAngle:0,selectedOffset:10,percentPrecision:2,stillShowZeroSum:!0,left:0,top:0,right:0,bottom:0,width:null,height:null,label:{rotate:0,show:!0,overflow:"truncate",position:"outer",alignTo:"none",edgeDistance:"25%",bleedMargin:10,distanceToLabelLine:5},labelLine:{show:!0,length:15,length2:15,smooth:!1,minTurnAngle:90,maxSurfaceAngle:90,lineStyle:{width:1,type:"solid"}},itemStyle:{borderWidth:1,borderJoin:"round"},showEmptyCircle:!0,emptyCircleStyle:{color:"lightgray",opacity:1},labelLayout:{hideOverlap:!0},emphasis:{scale:!0,scaleSize:5},avoidLabelOverlap:!0,animationType:"expansion",animationDuration:1e3,animationTypeUpdate:"transition",animationEasingUpdate:"cubicInOut",animationDurationUpdate:500,animationEasing:"cubicInOut"},e}(bt),KZ=JZ;function e7(r){return{seriesType:r,reset:function(e,t){var n=e.getData();n.filterSelf(function(a){var i=n.mapDimension("value"),o=n.get(i,a);return!(Ue(o)&&!isNaN(o)&&o<0)})}}}function t7(r){r.registerChartView(ZZ),r.registerSeriesModel(KZ),jN("pie",r.registerAction),r.registerLayout(Ae(WZ,"pie")),r.registerProcessor(Yf("pie")),r.registerProcessor(e7("pie"))}var r7=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t}return e.prototype.getInitialData=function(t,n){return Ua(null,this,{useEncodeDefaulter:!0})},e.prototype.getProgressive=function(){var t=this.option.progressive;return t==null?this.option.large?5e3:this.get("progressive"):t},e.prototype.getProgressiveThreshold=function(){var t=this.option.progressiveThreshold;return t==null?this.option.large?1e4:this.get("progressiveThreshold"):t},e.prototype.brushSelector=function(t,n,a){return a.point(n.getItemLayout(t))},e.prototype.getZLevelKey=function(){return this.getData().count()>this.getProgressiveThreshold()?this.id:""},e.type="series.scatter",e.dependencies=["grid","polar","geo","singleAxis","calendar"],e.defaultOption={coordinateSystem:"cartesian2d",z:2,legendHoverLink:!0,symbolSize:10,large:!1,largeThreshold:2e3,itemStyle:{opacity:.8},emphasis:{scale:!0},clip:!0,select:{itemStyle:{borderColor:"#212121"}},universalTransition:{divideShape:"clone"}},e}(bt),n7=r7,jE=4,a7=function(){function r(){}return r}(),i7=function(r){U(e,r);function e(t){var n=r.call(this,t)||this;return n._off=0,n.hoverDataIdx=-1,n}return e.prototype.getDefaultShape=function(){return new a7},e.prototype.reset=function(){this.notClear=!1,this._off=0},e.prototype.buildPath=function(t,n){var a=n.points,i=n.size,o=this.symbolProxy,s=o.shape,l=t.getContext?t.getContext():t,u=l&&i[0]<jE,c=this.softClipShape,f;if(u){this._ctx=l;return}for(this._ctx=null,f=this._off;f<a.length;){var h=a[f++],v=a[f++];isNaN(h)||isNaN(v)||c&&!c.contain(h,v)||(s.x=h-i[0]/2,s.y=v-i[1]/2,s.width=i[0],s.height=i[1],o.buildPath(t,s,!0))}this.incremental&&(this._off=f,this.notClear=!0)},e.prototype.afterBrush=function(){var t=this.shape,n=t.points,a=t.size,i=this._ctx,o=this.softClipShape,s;if(!!i){for(s=this._off;s<n.length;){var l=n[s++],u=n[s++];isNaN(l)||isNaN(u)||o&&!o.contain(l,u)||i.fillRect(l-a[0]/2,u-a[1]/2,a[0],a[1])}this.incremental&&(this._off=s,this.notClear=!0)}},e.prototype.findDataIndex=function(t,n){for(var a=this.shape,i=a.points,o=a.size,s=Math.max(o[0],4),l=Math.max(o[1],4),u=i.length/2-1;u>=0;u--){var c=u*2,f=i[c]-s/2,h=i[c+1]-l/2;if(t>=f&&n>=h&&t<=f+s&&n<=h+l)return u}return-1},e.prototype.contain=function(t,n){var a=this.transformCoordToLocal(t,n),i=this.getBoundingRect();if(t=a[0],n=a[1],i.contain(t,n)){var o=this.hoverDataIdx=this.findDataIndex(t,n);return o>=0}return this.hoverDataIdx=-1,!1},e.prototype.getBoundingRect=function(){var t=this._rect;if(!t){for(var n=this.shape,a=n.points,i=n.size,o=i[0],s=i[1],l=1/0,u=1/0,c=-1/0,f=-1/0,h=0;h<a.length;){var v=a[h++],d=a[h++];l=Math.min(v,l),c=Math.max(v,c),u=Math.min(d,u),f=Math.max(d,f)}t=this._rect=new Pe(l-o/2,u-s/2,c-l+o,f-u+s)}return t},e}(je),o7=function(){function r(){this.group=new De}return r.prototype.updateData=function(e,t){this._clear();var n=this._create();n.setShape({points:e.getLayout("points")}),this._setCommon(n,e,t)},r.prototype.updateLayout=function(e){var t=e.getLayout("points");this.group.eachChild(function(n){if(n.startIndex!=null){var a=(n.endIndex-n.startIndex)*2,i=n.startIndex*4*2;t=new Float32Array(t.buffer,i,a)}n.setShape("points",t),n.reset()})},r.prototype.incrementalPrepareUpdate=function(e){this._clear()},r.prototype.incrementalUpdate=function(e,t,n){var a=this._newAdded[0],i=t.getLayout("points"),o=a&&a.shape.points;if(o&&o.length<2e4){var s=o.length,l=new Float32Array(s+i.length);l.set(o),l.set(i,s),a.endIndex=e.end,a.setShape({points:l})}else{this._newAdded=[];var u=this._create();u.startIndex=e.start,u.endIndex=e.end,u.incremental=!0,u.setShape({points:i}),this._setCommon(u,t,n)}},r.prototype.eachRendered=function(e){this._newAdded[0]&&e(this._newAdded[0])},r.prototype._create=function(){var e=new i7({cursor:"default"});return e.ignoreCoarsePointer=!0,this.group.add(e),this._newAdded.push(e),e},r.prototype._setCommon=function(e,t,n){var a=t.hostModel;n=n||{};var i=t.getVisual("symbolSize");e.setShape("size",i instanceof Array?i:[i,i]),e.softClipShape=n.clipShape||null,e.symbolProxy=Ft(t.getVisual("symbol"),0,0,0,0),e.setColor=e.symbolProxy.setColor;var o=e.shape.size[0]<jE;e.useStyle(a.getModel("itemStyle").getItemStyle(o?["color","shadowBlur","shadowColor"]:["color"]));var s=t.getVisual("style"),l=s&&s.fill;l&&e.setColor(l);var u=Te(e);u.seriesIndex=a.seriesIndex,e.on("mousemove",function(c){u.dataIndex=null;var f=e.hoverDataIdx;f>=0&&(u.dataIndex=f+(e.startIndex||0))})},r.prototype.remove=function(){this._clear()},r.prototype._clear=function(){this._newAdded=[],this.group.removeAll()},r}(),s7=o7,l7=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a){var i=t.getData(),o=this._updateSymbolDraw(i,t);o.updateData(i,{clipShape:this._getClipShape(t)}),this._finished=!0},e.prototype.incrementalPrepareRender=function(t,n,a){var i=t.getData(),o=this._updateSymbolDraw(i,t);o.incrementalPrepareUpdate(i),this._finished=!1},e.prototype.incrementalRender=function(t,n,a){this._symbolDraw.incrementalUpdate(t,n.getData(),{clipShape:this._getClipShape(n)}),this._finished=t.end===n.getData().count()},e.prototype.updateTransform=function(t,n,a){var i=t.getData();if(this.group.dirty(),!this._finished||i.count()>1e4)return{update:!0};var o=Uf("").reset(t,n,a);o.progress&&o.progress({start:0,end:i.count(),count:i.count()},i),this._symbolDraw.updateLayout(i)},e.prototype.eachRendered=function(t){this._symbolDraw&&this._symbolDraw.eachRendered(t)},e.prototype._getClipShape=function(t){var n=t.coordinateSystem,a=n&&n.getArea&&n.getArea();return t.get("clip",!0)?a:null},e.prototype._updateSymbolDraw=function(t,n){var a=this._symbolDraw,i=n.pipelineContext,o=i.large;return(!a||o!==this._isLargeDraw)&&(a&&a.remove(),a=this._symbolDraw=o?new s7:new $f,this._isLargeDraw=o,this.group.removeAll()),this.group.add(a.group),a},e.prototype.remove=function(t,n){this._symbolDraw&&this._symbolDraw.remove(!0),this._symbolDraw=null},e.prototype.dispose=function(){},e.type="scatter",e}(ht),u7=l7,c7=function(r){U(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.type="grid",e.dependencies=["xAxis","yAxis"],e.layoutMode="box",e.defaultOption={show:!1,z:0,left:"10%",top:60,right:"10%",bottom:70,containLabel:!1,backgroundColor:"rgba(0,0,0,0)",borderWidth:1,borderColor:"#ccc"},e}(He),f7=c7,vb=function(r){U(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getCoordSysModel=function(){return this.getReferringComponents("grid",Ut).models[0]},e.type="cartesian2dAxis",e}(He);Et(vb,Mu);var BE={show:!0,z:0,inverse:!1,name:"",nameLocation:"end",nameRotate:null,nameTruncate:{maxWidth:null,ellipsis:"...",placeholder:"."},nameTextStyle:{},nameGap:15,silent:!1,triggerEvent:!1,tooltip:{show:!1},axisPointer:{},axisLine:{show:!0,onZero:!0,onZeroAxisIndex:null,lineStyle:{color:"#6E7079",width:1,type:"solid"},symbol:["none","none"],symbolSize:[10,15]},axisTick:{show:!0,inside:!1,length:5,lineStyle:{width:1}},axisLabel:{show:!0,inside:!1,rotate:0,showMinLabel:null,showMaxLabel:null,margin:8,fontSize:12},splitLine:{show:!0,lineStyle:{color:["#E0E6F1"],width:1,type:"solid"}},splitArea:{show:!1,areaStyle:{color:["rgba(250,250,250,0.2)","rgba(210,219,238,0.2)"]}}},h7=Ne({boundaryGap:!0,deduplication:null,splitLine:{show:!1},axisTick:{alignWithLabel:!1,interval:"auto"},axisLabel:{interval:"auto"}},BE),db=Ne({boundaryGap:[0,0],axisLine:{show:"auto"},axisTick:{show:"auto"},splitNumber:5,minorTick:{show:!1,splitNumber:5,length:3,lineStyle:{}},minorSplitLine:{show:!1,lineStyle:{color:"#F4F7FD",width:1}}},BE),v7=Ne({splitNumber:6,axisLabel:{showMinLabel:!1,showMaxLabel:!1,rich:{primary:{fontWeight:"bold"}}},splitLine:{show:!1}},db),d7=me({logBase:10},db),FE={category:h7,value:db,time:v7,log:d7},p7={value:1,category:1,time:1,log:1};function Iu(r,e,t,n){C(p7,function(a,i){var o=Ne(Ne({},FE[i],!0),n,!0),s=function(l){U(u,l);function u(){var c=l!==null&&l.apply(this,arguments)||this;return c.type=e+"Axis."+i,c}return u.prototype.mergeDefaultAndTheme=function(c,f){var h=pf(this),v=h?iu(c):{},d=f.getTheme();Ne(c,d.get(i+"Axis")),Ne(c,this.getDefaultOption()),c.type=VE(c),h&&fo(c,v,h)},u.prototype.optionUpdated=function(){var c=this.option;c.type==="category"&&(this.__ordinalMeta=O_.createByAxisModel(this))},u.prototype.getCategories=function(c){var f=this.option;if(f.type==="category")return c?f.data:this.__ordinalMeta.categories},u.prototype.getOrdinalMeta=function(){return this.__ordinalMeta},u.type=e+"Axis."+i,u.defaultOption=o,u}(t);r.registerComponentModel(s)}),r.registerSubTypeDefaulter(e+"Axis",VE)}function VE(r){return r.type||(r.data?"category":"value")}var g7=function(){function r(e){this.type="cartesian",this._dimList=[],this._axes={},this.name=e||""}return r.prototype.getAxis=function(e){return this._axes[e]},r.prototype.getAxes=function(){return K(this._dimList,function(e){return this._axes[e]},this)},r.prototype.getAxesByScale=function(e){return e=e.toLowerCase(),ot(this.getAxes(),function(t){return t.scale.type===e})},r.prototype.addAxis=function(e){var t=e.dim;this._axes[t]=e,this._dimList.push(t)},r}(),y7=g7,pb=["x","y"];function HE(r){return r.type==="interval"||r.type==="time"}var m7=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="cartesian2d",t.dimensions=pb,t}return e.prototype.calcAffineTransform=function(){this._transform=this._invTransform=null;var t=this.getAxis("x").scale,n=this.getAxis("y").scale;if(!(!HE(t)||!HE(n))){var a=t.getExtent(),i=n.getExtent(),o=this.dataToPoint([a[0],i[0]]),s=this.dataToPoint([a[1],i[1]]),l=a[1]-a[0],u=i[1]-i[0];if(!(!l||!u)){var c=(s[0]-o[0])/l,f=(s[1]-o[1])/u,h=o[0]-a[0]*c,v=o[1]-i[0]*f,d=this._transform=[c,0,0,f,h,v];this._invTransform=Qo([],d)}}},e.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAxis("x")},e.prototype.containPoint=function(t){var n=this.getAxis("x"),a=this.getAxis("y");return n.contain(n.toLocalCoord(t[0]))&&a.contain(a.toLocalCoord(t[1]))},e.prototype.containData=function(t){return this.getAxis("x").containData(t[0])&&this.getAxis("y").containData(t[1])},e.prototype.containZone=function(t,n){var a=this.dataToPoint(t),i=this.dataToPoint(n),o=this.getArea(),s=new Pe(a[0],a[1],i[0]-a[0],i[1]-a[1]);return o.intersect(s)},e.prototype.dataToPoint=function(t,n,a){a=a||[];var i=t[0],o=t[1];if(this._transform&&i!=null&&isFinite(i)&&o!=null&&isFinite(o))return vr(a,t,this._transform);var s=this.getAxis("x"),l=this.getAxis("y");return a[0]=s.toGlobalCoord(s.dataToCoord(i,n)),a[1]=l.toGlobalCoord(l.dataToCoord(o,n)),a},e.prototype.clampData=function(t,n){var a=this.getAxis("x").scale,i=this.getAxis("y").scale,o=a.getExtent(),s=i.getExtent(),l=a.parse(t[0]),u=i.parse(t[1]);return n=n||[],n[0]=Math.min(Math.max(Math.min(o[0],o[1]),l),Math.max(o[0],o[1])),n[1]=Math.min(Math.max(Math.min(s[0],s[1]),u),Math.max(s[0],s[1])),n},e.prototype.pointToData=function(t,n){var a=[];if(this._invTransform)return vr(a,t,this._invTransform);var i=this.getAxis("x"),o=this.getAxis("y");return a[0]=i.coordToData(i.toLocalCoord(t[0]),n),a[1]=o.coordToData(o.toLocalCoord(t[1]),n),a},e.prototype.getOtherAxis=function(t){return this.getAxis(t.dim==="x"?"y":"x")},e.prototype.getArea=function(){var t=this.getAxis("x").getGlobalExtent(),n=this.getAxis("y").getGlobalExtent(),a=Math.min(t[0],t[1]),i=Math.min(n[0],n[1]),o=Math.max(t[0],t[1])-a,s=Math.max(n[0],n[1])-i;return new Pe(a,i,o,s)},e}(y7),_7=function(r){U(e,r);function e(t,n,a,i,o){var s=r.call(this,t,n,a)||this;return s.index=0,s.type=i||"value",s.position=o||"bottom",s}return e.prototype.isHorizontal=function(){var t=this.position;return t==="top"||t==="bottom"},e.prototype.getGlobalExtent=function(t){var n=this.getExtent();return n[0]=this.toGlobalCoord(n[0]),n[1]=this.toGlobalCoord(n[1]),t&&n[0]>n[1]&&n.reverse(),n},e.prototype.pointToData=function(t,n){return this.coordToData(this.toLocalCoord(t[this.dim==="x"?0:1]),n)},e.prototype.setCategorySortInfo=function(t){if(this.type!=="category")return!1;this.model.option.categorySortInfo=t,this.scale.setSortInfo(t)},e}(Yn),b7=_7;function gb(r,e,t){t=t||{};var n=r.coordinateSystem,a=e.axis,i={},o=a.getAxesOnZeroOf()[0],s=a.position,l=o?"onZero":s,u=a.dim,c=n.getRect(),f=[c.x,c.x+c.width,c.y,c.y+c.height],h={left:0,right:1,top:0,bottom:1,onZero:2},v=e.get("offset")||0,d=u==="x"?[f[2]-v,f[3]+v]:[f[0]-v,f[1]+v];if(o){var p=o.toGlobalCoord(o.dataToCoord(0));d[h.onZero]=Math.max(Math.min(p,d[1]),d[0])}i.position=[u==="y"?d[h[l]]:f[0],u==="x"?d[h[l]]:f[3]],i.rotation=Math.PI/2*(u==="x"?0:1);var g={top:-1,bottom:1,left:-1,right:1};i.labelDirection=i.tickDirection=i.nameDirection=g[s],i.labelOffset=o?d[h[s]]-d[h.onZero]:0,e.get(["axisTick","inside"])&&(i.tickDirection=-i.tickDirection),ar(t.labelInside,e.get(["axisLabel","inside"]))&&(i.labelDirection=-i.labelDirection);var y=e.get(["axisLabel","rotate"]);return i.labelRotate=l==="top"?-y:y,i.z2=1,i}function WE(r){return r.get("coordinateSystem")==="cartesian2d"}function GE(r){var e={xAxisModel:null,yAxisModel:null};return C(e,function(t,n){var a=n.replace(/Model$/,""),i=r.getReferringComponents(a,Ut).models[0];e[n]=i}),e}var yb=Math.log;function $E(r,e,t){var n=_o.prototype,a=n.getTicks.call(t),i=n.getTicks.call(t,!0),o=a.length-1,s=n.getInterval.call(t),l=i2(r,e),u=l.extent,c=l.fixMin,f=l.fixMax;if(r.type==="log"){var h=yb(r.base);u=[yb(u[0])/h,yb(u[1])/h]}r.setExtent(u[0],u[1]),r.calcNiceExtent({splitNumber:o,fixMin:c,fixMax:f});var v=n.getExtent.call(r);c&&(u[0]=v[0]),f&&(u[1]=v[1]);var d=n.getInterval.call(r),p=u[0],g=u[1];if(c&&f)d=(g-p)/o;else if(c)for(g=u[0]+d*o;g<u[1]&&isFinite(g)&&isFinite(u[1]);)d=z_(d),g=u[0]+d*o;else if(f)for(p=u[1]-d*o;p>u[0]&&isFinite(p)&&isFinite(u[0]);)d=z_(d),p=u[1]-d*o;else{var y=r.getTicks().length-1;y>o&&(d=z_(d));var m=d*o;g=Math.ceil(u[1]/d)*d,p=Nt(g-m),p<0&&u[0]>=0?(p=0,g=Nt(m)):g>0&&u[1]<=0&&(g=0,p=-Nt(m))}var _=(a[0].value-i[0].value)/s,b=(a[o].value-i[o].value)/s;n.setExtent.call(r,p+d*_,g+d*b),n.setInterval.call(r,d),(_||b)&&n.setNiceExtent.call(r,p+d,g-d)}var M7=function(){function r(e,t,n){this.type="grid",this._coordsMap={},this._coordsList=[],this._axesMap={},this._axesList=[],this.axisPointerEnabled=!0,this.dimensions=pb,this._initCartesian(e,t,n),this.model=e}return r.prototype.getRect=function(){return this._rect},r.prototype.update=function(e,t){var n=this._axesMap;this._updateScale(e,this.model);function a(o){var s,l=Fe(o),u=l.length;if(!!u){for(var c=[],f=u-1;f>=0;f--){var h=+l[f],v=o[h],d=v.model,p=v.scale;P_(p)&&d.get("alignTicks")&&d.get("interval")==null?c.push(v):(Ps(p,d),P_(p)&&(s=v))}c.length&&(s||(s=c.pop(),Ps(s.scale,s.model)),C(c,function(g){$E(g.scale,g.model,s.scale)}))}}a(n.x),a(n.y);var i={};C(n.x,function(o){UE(n,"y",o,i)}),C(n.y,function(o){UE(n,"x",o,i)}),this.resize(this.model,t)},r.prototype.resize=function(e,t,n){var a=e.getBoxLayoutParams(),i=!n&&e.get("containLabel"),o=Yt(a,{width:t.getWidth(),height:t.getHeight()});this._rect=o;var s=this._axesList;l(),i&&(C(s,function(u){if(!u.model.get(["axisLabel","inside"])){var c=MQ(u);if(c){var f=u.isHorizontal()?"height":"width",h=u.model.get(["axisLabel","margin"]);o[f]-=c[f]+h,u.position==="top"?o.y+=c.height+h:u.position==="left"&&(o.x+=c.width+h)}}}),l()),C(this._coordsList,function(u){u.calcAffineTransform()});function l(){C(s,function(u){var c=u.isHorizontal(),f=c?[0,o.width]:[0,o.height],h=u.inverse?1:0;u.setExtent(f[h],f[1-h]),x7(u,c?o.x:o.y)})}},r.prototype.getAxis=function(e,t){var n=this._axesMap[e];if(n!=null)return n[t||0]},r.prototype.getAxes=function(){return this._axesList.slice()},r.prototype.getCartesian=function(e,t){if(e!=null&&t!=null){var n="x"+e+"y"+t;return this._coordsMap[n]}_e(e)&&(t=e.yAxisIndex,e=e.xAxisIndex);for(var a=0,i=this._coordsList;a<i.length;a++)if(i[a].getAxis("x").index===e||i[a].getAxis("y").index===t)return i[a]},r.prototype.getCartesians=function(){return this._coordsList.slice()},r.prototype.convertToPixel=function(e,t,n){var a=this._findConvertTarget(t);return a.cartesian?a.cartesian.dataToPoint(n):a.axis?a.axis.toGlobalCoord(a.axis.dataToCoord(n)):null},r.prototype.convertFromPixel=function(e,t,n){var a=this._findConvertTarget(t);return a.cartesian?a.cartesian.pointToData(n):a.axis?a.axis.coordToData(a.axis.toLocalCoord(n)):null},r.prototype._findConvertTarget=function(e){var t=e.seriesModel,n=e.xAxisModel||t&&t.getReferringComponents("xAxis",Ut).models[0],a=e.yAxisModel||t&&t.getReferringComponents("yAxis",Ut).models[0],i=e.gridModel,o=this._coordsList,s,l;if(t)s=t.coordinateSystem,ze(o,s)<0&&(s=null);else if(n&&a)s=this.getCartesian(n.componentIndex,a.componentIndex);else if(n)l=this.getAxis("x",n.componentIndex);else if(a)l=this.getAxis("y",a.componentIndex);else if(i){var u=i.coordinateSystem;u===this&&(s=this._coordsList[0])}return{cartesian:s,axis:l}},r.prototype.containPoint=function(e){var t=this._coordsList[0];if(t)return t.containPoint(e)},r.prototype._initCartesian=function(e,t,n){var a=this,i=this,o={left:!1,right:!1,top:!1,bottom:!1},s={x:{},y:{}},l={x:0,y:0};if(t.eachComponent("xAxis",u("x"),this),t.eachComponent("yAxis",u("y"),this),!l.x||!l.y){this._axesMap={},this._axesList=[];return}this._axesMap=s,C(s.x,function(c,f){C(s.y,function(h,v){var d="x"+f+"y"+v,p=new m7(d);p.master=a,p.model=e,a._coordsMap[d]=p,a._coordsList.push(p),p.addAxis(c),p.addAxis(h)})});function u(c){return function(f,h){if(!!mb(f,e)){var v=f.get("position");c==="x"?v!=="top"&&v!=="bottom"&&(v=o.bottom?"top":"bottom"):v!=="left"&&v!=="right"&&(v=o.left?"right":"left"),o[v]=!0;var d=new b7(c,kf(f),[0,0],f.get("type"),v),p=d.type==="category";d.onBand=p&&f.get("boundaryGap"),d.inverse=f.get("inverse"),f.axis=d,d.model=f,d.grid=i,d.index=h,i._axesList.push(d),s[c][h]=d,l[c]++}}}},r.prototype._updateScale=function(e,t){C(this._axesList,function(a){if(a.scale.setExtent(1/0,-1/0),a.type==="category"){var i=a.model.get("categorySortInfo");a.scale.setSortInfo(i)}}),e.eachSeries(function(a){if(WE(a)){var i=GE(a),o=i.xAxisModel,s=i.yAxisModel;if(!mb(o,t)||!mb(s,t))return;var l=this.getCartesian(o.componentIndex,s.componentIndex),u=a.getData(),c=l.getAxis("x"),f=l.getAxis("y");n(u,c),n(u,f)}},this);function n(a,i){C(wp(a,i.dim),function(o){i.scale.unionExtentFromData(a,o)})}},r.prototype.getTooltipAxes=function(e){var t=[],n=[];return C(this.getCartesians(),function(a){var i=e!=null&&e!=="auto"?a.getAxis(e):a.getBaseAxis(),o=a.getOtherAxis(i);ze(t,i)<0&&t.push(i),ze(n,o)<0&&n.push(o)}),{baseAxes:t,otherAxes:n}},r.create=function(e,t){var n=[];return e.eachComponent("grid",function(a,i){var o=new r(a,e,t);o.name="grid_"+i,o.resize(a,t,!0),a.coordinateSystem=o,n.push(o)}),e.eachSeries(function(a){if(!!WE(a)){var i=GE(a),o=i.xAxisModel,s=i.yAxisModel,l=o.getCoordSysModel(),u=l.coordinateSystem;a.coordinateSystem=u.getCartesian(o.componentIndex,s.componentIndex)}}),n},r.dimensions=pb,r}();function mb(r,e){return r.getCoordSysModel()===e}function UE(r,e,t,n){t.getAxesOnZeroOf=function(){return i?[i]:[]};var a=r[e],i,o=t.model,s=o.get(["axisLine","onZero"]),l=o.get(["axisLine","onZeroAxisIndex"]);if(!s)return;if(l!=null)YE(a[l])&&(i=a[l]);else for(var u in a)if(a.hasOwnProperty(u)&&YE(a[u])&&!n[c(a[u])]){i=a[u];break}i&&(n[c(i)]=!0);function c(f){return f.dim+"_"+f.index}}function YE(r){return r&&r.type!=="category"&&r.type!=="time"&&bQ(r)}function x7(r,e){var t=r.getExtent(),n=t[0]+t[1];r.toGlobalCoord=r.dim==="x"?function(a){return a+e}:function(a){return n-a+e},r.toLocalCoord=r.dim==="x"?function(a){return a-e}:function(a){return n-a+e}}var w7=M7,wo=Math.PI,Ws=function(){function r(e,t){this.group=new De,this.opt=t,this.axisModel=e,me(t,{labelOffset:0,nameDirection:1,tickDirection:1,labelDirection:1,silent:!0,handleAutoShown:function(){return!0}});var n=new De({x:t.position[0],y:t.position[1],rotation:t.rotation});n.updateTransform(),this._transformGroup=n}return r.prototype.hasBuilder=function(e){return!!QE[e]},r.prototype.add=function(e){QE[e](this.opt,this.axisModel,this.group,this._transformGroup)},r.prototype.getGroup=function(){return this.group},r.innerTextLayout=function(e,t,n){var a=S0(t-e),i,o;return Fc(a)?(o=n>0?"top":"bottom",i="center"):Fc(a-wo)?(o=n>0?"bottom":"top",i="center"):(o="middle",a>0&&a<wo?i=n>0?"right":"left":i=n>0?"left":"right"),{rotation:a,textAlign:i,textVerticalAlign:o}},r.makeAxisEventDataBase=function(e){var t={componentType:e.mainType,componentIndex:e.componentIndex};return t[e.mainType+"Index"]=e.componentIndex,t},r.isLabelSilent=function(e){var t=e.get("tooltip");return e.get("silent")||!(e.get("triggerEvent")||t&&t.show)},r}(),QE={axisLine:function(r,e,t,n){var a=e.get(["axisLine","show"]);if(a==="auto"&&r.handleAutoShown&&(a=r.handleAutoShown("axisLine")),!!a){var i=e.axis.getExtent(),o=n.transform,s=[i[0],0],l=[i[1],0],u=s[0]>l[0];o&&(vr(s,s,o),vr(l,l,o));var c=X({lineCap:"round"},e.getModel(["axisLine","lineStyle"]).getLineStyle()),f=new or({shape:{x1:s[0],y1:s[1],x2:l[0],y2:l[1]},style:c,strokeContainThreshold:r.strokeContainThreshold||5,silent:!0,z2:1});Jl(f.shape,f.style.lineWidth),f.anid="line",t.add(f);var h=e.get(["axisLine","symbol"]);if(h!=null){var v=e.get(["axisLine","symbolSize"]);ce(h)&&(h=[h,h]),(ce(v)||Ue(v))&&(v=[v,v]);var d=pu(e.get(["axisLine","symbolOffset"])||0,v),p=v[0],g=v[1];C([{rotate:r.rotation+Math.PI/2,offset:d[0],r:0},{rotate:r.rotation-Math.PI/2,offset:d[1],r:Math.sqrt((s[0]-l[0])*(s[0]-l[0])+(s[1]-l[1])*(s[1]-l[1]))}],function(y,m){if(h[m]!=="none"&&h[m]!=null){var _=Ft(h[m],-p/2,-g/2,p,g,c.stroke,!0),b=y.r+y.offset,x=u?l:s;_.attr({rotation:y.rotate,x:x[0]+b*Math.cos(r.rotation),y:x[1]-b*Math.sin(r.rotation),silent:!0,z2:11}),t.add(_)}})}}},axisTickLabel:function(r,e,t,n){var a=I7(t,n,e,r),i=A7(t,n,e,r);if(S7(e,i,a),T7(t,n,e,r.tickDirection),e.get(["axisLabel","hideOverlap"])){var o=I2(K(i,function(s){return{label:s,priority:s.z2,defaultAttr:{ignore:s.ignore}}}));C2(o)}},axisName:function(r,e,t,n){var a=ar(r.axisName,e.get("name"));if(!!a){var i=e.get("nameLocation"),o=r.nameDirection,s=e.getModel("nameTextStyle"),l=e.get("nameGap")||0,u=e.axis.getExtent(),c=u[0]>u[1]?-1:1,f=[i==="start"?u[0]-c*l:i==="end"?u[1]+c*l:(u[0]+u[1])/2,qE(i)?r.labelOffset+o*l:0],h,v=e.get("nameRotate");v!=null&&(v=v*wo/180);var d;qE(i)?h=Ws.innerTextLayout(r.rotation,v!=null?v:r.rotation,o):(h=D7(r.rotation,i,v||0,u),d=r.axisNameAvailableWidth,d!=null&&(d=Math.abs(d/Math.sin(h.rotation)),!isFinite(d)&&(d=null)));var p=s.getFont(),g=e.get("nameTruncate",!0)||{},y=g.ellipsis,m=ar(r.nameTruncateMaxWidth,g.maxWidth,d),_=new Ge({x:f[0],y:f[1],rotation:h.rotation,silent:Ws.isLabelSilent(e),style:yt(s,{text:a,font:p,overflow:"truncate",width:m,ellipsis:y,fill:s.getTextColor()||e.get(["axisLine","lineStyle","color"]),align:s.get("align")||h.textAlign,verticalAlign:s.get("verticalAlign")||h.textVerticalAlign}),z2:1});if(eu({el:_,componentModel:e,itemName:a}),_.__fullText=a,_.anid="name",e.get("triggerEvent")){var b=Ws.makeAxisEventDataBase(e);b.targetType="axisName",b.name=a,Te(_).eventData=b}n.add(_),_.updateTransform(),t.add(_),_.decomposeTransform()}}};function D7(r,e,t,n){var a=S0(t-r),i,o,s=n[0]>n[1],l=e==="start"&&!s||e!=="start"&&s;return Fc(a-wo/2)?(o=l?"bottom":"top",i="center"):Fc(a-wo*1.5)?(o=l?"top":"bottom",i="center"):(o="middle",a<wo*1.5&&a>wo/2?i=l?"left":"right":i=l?"right":"left"),{rotation:a,textAlign:i,textVerticalAlign:o}}function S7(r,e,t){if(!o2(r.axis)){var n=r.get(["axisLabel","showMinLabel"]),a=r.get(["axisLabel","showMaxLabel"]);e=e||[],t=t||[];var i=e[0],o=e[1],s=e[e.length-1],l=e[e.length-2],u=t[0],c=t[1],f=t[t.length-1],h=t[t.length-2];n===!1?(Qn(i),Qn(u)):ZE(i,o)&&(n?(Qn(o),Qn(c)):(Qn(i),Qn(u))),a===!1?(Qn(s),Qn(f)):ZE(l,s)&&(a?(Qn(l),Qn(h)):(Qn(s),Qn(f)))}}function Qn(r){r&&(r.ignore=!0)}function ZE(r,e){var t=r&&r.getBoundingRect().clone(),n=e&&e.getBoundingRect().clone();if(!(!t||!n)){var a=xc([]);return Zi(a,a,-r.rotation),t.applyTransform(Pa([],a,r.getLocalTransform())),n.applyTransform(Pa([],a,e.getLocalTransform())),t.intersect(n)}}function qE(r){return r==="middle"||r==="center"}function XE(r,e,t,n,a){for(var i=[],o=[],s=[],l=0;l<r.length;l++){var u=r[l].coord;o[0]=u,o[1]=0,s[0]=u,s[1]=t,e&&(vr(o,o,e),vr(s,s,e));var c=new or({shape:{x1:o[0],y1:o[1],x2:s[0],y2:s[1]},style:n,z2:2,autoBatch:!0,silent:!0});Jl(c.shape,c.style.lineWidth),c.anid=a+"_"+r[l].tickValue,i.push(c)}return i}function I7(r,e,t,n){var a=t.axis,i=t.getModel("axisTick"),o=i.get("show");if(o==="auto"&&n.handleAutoShown&&(o=n.handleAutoShown("axisTick")),!(!o||a.scale.isBlank())){for(var s=i.getModel("lineStyle"),l=n.tickDirection*i.get("length"),u=a.getTicksCoords(),c=XE(u,e.transform,l,me(s.getLineStyle(),{stroke:t.get(["axisLine","lineStyle","color"])}),"ticks"),f=0;f<c.length;f++)r.add(c[f]);return c}}function T7(r,e,t,n){var a=t.axis,i=t.getModel("minorTick");if(!(!i.get("show")||a.scale.isBlank())){var o=a.getMinorTicksCoords();if(!!o.length)for(var s=i.getModel("lineStyle"),l=n*i.get("length"),u=me(s.getLineStyle(),me(t.getModel("axisTick").getLineStyle(),{stroke:t.get(["axisLine","lineStyle","color"])})),c=0;c<o.length;c++)for(var f=XE(o[c],e.transform,l,u,"minorticks_"+c),h=0;h<f.length;h++)r.add(f[h])}}function A7(r,e,t,n){var a=t.axis,i=ar(n.axisLabelShow,t.get(["axisLabel","show"]));if(!(!i||a.scale.isBlank())){var o=t.getModel("axisLabel"),s=o.get("margin"),l=a.getViewLabels(),u=(ar(n.labelRotate,o.get("rotate"))||0)*wo/180,c=Ws.innerTextLayout(n.rotation,u,n.labelDirection),f=t.getCategories&&t.getCategories(!0),h=[],v=Ws.isLabelSilent(t),d=t.get("triggerEvent");return C(l,function(p,g){var y=a.scale.type==="ordinal"?a.scale.getRawOrdinalNumber(p.tickValue):p.tickValue,m=p.formattedLabel,_=p.rawLabel,b=o;if(f&&f[y]){var x=f[y];_e(x)&&x.textStyle&&(b=new ft(x.textStyle,o,t.ecModel))}var M=b.getTextColor()||t.get(["axisLine","lineStyle","color"]),w=a.dataToCoord(y),D=new Ge({x:w,y:n.labelOffset+n.labelDirection*s,rotation:c.rotation,silent:v,z2:10+(p.level||0),style:yt(b,{text:m,align:b.getShallow("align",!0)||c.textAlign,verticalAlign:b.getShallow("verticalAlign",!0)||b.getShallow("baseline",!0)||c.textVerticalAlign,fill:ye(M)?M(a.type==="category"?_:a.type==="value"?y+"":y,g):M})});if(D.anid="label_"+y,d){var T=Ws.makeAxisEventDataBase(t);T.targetType="axisLabel",T.value=_,T.tickIndex=g,a.type==="category"&&(T.dataIndex=y),Te(D).eventData=T}e.add(D),D.updateTransform(),h.push(D),r.add(D),D.decomposeTransform()}),h}}var Di=Ws;function C7(r,e){var t={axesInfo:{},seriesInvolved:!1,coordSysAxesInfo:{},coordSysMap:{}};return N7(t,r,e),t.seriesInvolved&&E7(t,r),t}function N7(r,e,t){var n=e.getComponent("tooltip"),a=e.getComponent("axisPointer"),i=a.get("link",!0)||[],o=[];C(t.getCoordinateSystems(),function(s){if(!s.axisPointerEnabled)return;var l=Zf(s.model),u=r.coordSysAxesInfo[l]={};r.coordSysMap[l]=s;var c=s.model,f=c.getModel("tooltip",n);if(C(s.getAxes(),Ae(p,!1,null)),s.getTooltipAxes&&n&&f.get("show")){var h=f.get("trigger")==="axis",v=f.get(["axisPointer","type"])==="cross",d=s.getTooltipAxes(f.get(["axisPointer","axis"]));(h||v)&&C(d.baseAxes,Ae(p,v?"cross":!0,h)),v&&C(d.otherAxes,Ae(p,"cross",!1))}function p(g,y,m){var _=m.model.getModel("axisPointer",a),b=_.get("show");if(!(!b||b==="auto"&&!g&&!Mb(_))){y==null&&(y=_.get("triggerTooltip")),_=g?L7(m,f,a,e,g,y):_;var x=_.get("snap"),M=Zf(m.model),w=y||x||m.type==="category",D=r.axesInfo[M]={key:M,axis:m,coordSys:s,axisPointerModel:_,triggerTooltip:y,involveSeries:w,snap:x,useHandle:Mb(_),seriesModels:[],linkGroup:null};u[M]=D,r.seriesInvolved=r.seriesInvolved||w;var T=O7(i,m);if(T!=null){var I=o[T]||(o[T]={axesInfo:{}});I.axesInfo[M]=D,I.mapper=i[T].mapper,D.linkGroup=I}}}})}function L7(r,e,t,n,a,i){var o=e.getModel("axisPointer"),s=["type","snap","lineStyle","shadowStyle","label","animation","animationDurationUpdate","animationEasingUpdate","z"],l={};C(s,function(h){l[h]=Me(o.get(h))}),l.snap=r.type!=="category"&&!!i,o.get("type")==="cross"&&(l.type="line");var u=l.label||(l.label={});if(u.show==null&&(u.show=!1),a==="cross"){var c=o.get(["label","show"]);if(u.show=c!=null?c:!0,!i){var f=l.lineStyle=o.get("crossStyle");f&&me(u,f.textStyle)}}return r.model.getModel("axisPointer",new ft(l,t,n))}function E7(r,e){e.eachSeries(function(t){var n=t.coordinateSystem,a=t.get(["tooltip","trigger"],!0),i=t.get(["tooltip","show"],!0);!n||a==="none"||a===!1||a==="item"||i===!1||t.get(["axisPointer","show"],!0)===!1||C(r.coordSysAxesInfo[Zf(n.model)],function(o){var s=o.axis;n.getAxis(s.dim)===s&&(o.seriesModels.push(t),o.seriesDataCount==null&&(o.seriesDataCount=0),o.seriesDataCount+=t.getData().count())})})}function O7(r,e){for(var t=e.model,n=e.dim,a=0;a<r.length;a++){var i=r[a]||{};if(_b(i[n+"AxisId"],t.id)||_b(i[n+"AxisIndex"],t.componentIndex)||_b(i[n+"AxisName"],t.name))return a}}function _b(r,e){return r==="all"||J(r)&&ze(r,e)>=0||r===e}function P7(r){var e=bb(r);if(!!e){var t=e.axisPointerModel,n=e.axis.scale,a=t.option,i=t.get("status"),o=t.get("value");o!=null&&(o=n.parse(o));var s=Mb(t);i==null&&(a.status=s?"show":"hide");var l=n.getExtent().slice();l[0]>l[1]&&l.reverse(),(o==null||o>l[1])&&(o=l[1]),o<l[0]&&(o=l[0]),a.value=o,s&&(a.status=e.axis.scale.isBlank()?"hide":"show")}}function bb(r){var e=(r.ecModel.getComponent("axisPointer")||{}).coordSysAxesInfo;return e&&e.axesInfo[Zf(r)]}function z7(r){var e=bb(r);return e&&e.axisPointerModel}function Mb(r){return!!r.get(["handle","show"])}function Zf(r){return r.type+"||"+r.id}var JE={},k7=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a,i){this.axisPointerClass&&P7(t),r.prototype.render.apply(this,arguments),this._doUpdateAxisPointerClass(t,a,!0)},e.prototype.updateAxisPointer=function(t,n,a,i){this._doUpdateAxisPointerClass(t,a,!1)},e.prototype.remove=function(t,n){var a=this._axisPointer;a&&a.remove(n)},e.prototype.dispose=function(t,n){this._disposeAxisPointer(n),r.prototype.dispose.apply(this,arguments)},e.prototype._doUpdateAxisPointerClass=function(t,n,a){var i=e.getAxisPointerClass(this.axisPointerClass);if(!!i){var o=z7(t);o?(this._axisPointer||(this._axisPointer=new i)).render(t,o,n,a):this._disposeAxisPointer(n)}},e.prototype._disposeAxisPointer=function(t){this._axisPointer&&this._axisPointer.dispose(t),this._axisPointer=null},e.registerAxisPointerClass=function(t,n){JE[t]=n},e.getAxisPointerClass=function(t){return t&&JE[t]},e.type="axis",e}(St),Gs=k7,xb=Ye();function KE(r,e,t,n){var a=t.axis;if(!a.scale.isBlank()){var i=t.getModel("splitArea"),o=i.getModel("areaStyle"),s=o.get("color"),l=n.coordinateSystem.getRect(),u=a.getTicksCoords({tickModel:i,clamp:!0});if(!!u.length){var c=s.length,f=xb(r).splitAreaColors,h=ge(),v=0;if(f)for(var d=0;d<u.length;d++){var p=f.get(u[d].tickValue);if(p!=null){v=(p+(c-1)*d)%c;break}}var g=a.toGlobalCoord(u[0].coord),y=o.getAreaStyle();s=J(s)?s:[s];for(var d=1;d<u.length;d++){var m=a.toGlobalCoord(u[d].coord),_=void 0,b=void 0,x=void 0,M=void 0;a.isHorizontal()?(_=g,b=l.y,x=m-_,M=l.height,g=_+x):(_=l.x,b=g,x=l.width,M=m-b,g=b+M);var w=u[d-1].tickValue;w!=null&&h.set(w,v),e.add(new We({anid:w!=null?"area_"+w:null,shape:{x:_,y:b,width:x,height:M},style:me({fill:s[v]},y),autoBatch:!0,silent:!0})),v=(v+1)%c}xb(r).splitAreaColors=h}}}function eO(r){xb(r).splitAreaColors=null}var R7=["axisLine","axisTickLabel","axisName"],j7=["splitArea","splitLine","minorSplitLine"],tO=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.axisPointerClass="CartesianAxisPointer",t}return e.prototype.render=function(t,n,a,i){this.group.removeAll();var o=this._axisGroup;if(this._axisGroup=new De,this.group.add(this._axisGroup),!!t.get("show")){var s=t.getCoordSysModel(),l=gb(s,t),u=new Di(t,X({handleAutoShown:function(f){for(var h=s.coordinateSystem.getCartesians(),v=0;v<h.length;v++)if(P_(h[v].getOtherAxis(t.axis).scale))return!0;return!1}},l));C(R7,u.add,u),this._axisGroup.add(u.getGroup()),C(j7,function(f){t.get([f,"show"])&&B7[f](this,this._axisGroup,t,s)},this);var c=i&&i.type==="changeAxisOrder"&&i.isInitSort;c||sf(o,this._axisGroup,t),r.prototype.render.call(this,t,n,a,i)}},e.prototype.remove=function(){eO(this)},e.type="cartesianAxis",e}(Gs),B7={splitLine:function(r,e,t,n){var a=t.axis;if(!a.scale.isBlank()){var i=t.getModel("splitLine"),o=i.getModel("lineStyle"),s=o.get("color");s=J(s)?s:[s];for(var l=n.coordinateSystem.getRect(),u=a.isHorizontal(),c=0,f=a.getTicksCoords({tickModel:i}),h=[],v=[],d=o.getLineStyle(),p=0;p<f.length;p++){var g=a.toGlobalCoord(f[p].coord);u?(h[0]=g,h[1]=l.y,v[0]=g,v[1]=l.y+l.height):(h[0]=l.x,h[1]=g,v[0]=l.x+l.width,v[1]=g);var y=c++%s.length,m=f[p].tickValue,_=new or({anid:m!=null?"line_"+f[p].tickValue:null,autoBatch:!0,shape:{x1:h[0],y1:h[1],x2:v[0],y2:v[1]},style:me({stroke:s[y]},d),silent:!0});Jl(_.shape,d.lineWidth),e.add(_)}}},minorSplitLine:function(r,e,t,n){var a=t.axis,i=t.getModel("minorSplitLine"),o=i.getModel("lineStyle"),s=n.coordinateSystem.getRect(),l=a.isHorizontal(),u=a.getMinorTicksCoords();if(!!u.length)for(var c=[],f=[],h=o.getLineStyle(),v=0;v<u.length;v++)for(var d=0;d<u[v].length;d++){var p=a.toGlobalCoord(u[v][d].coord);l?(c[0]=p,c[1]=s.y,f[0]=p,f[1]=s.y+s.height):(c[0]=s.x,c[1]=p,f[0]=s.x+s.width,f[1]=p);var g=new or({anid:"minor_line_"+u[v][d].tickValue,autoBatch:!0,shape:{x1:c[0],y1:c[1],x2:f[0],y2:f[1]},style:h,silent:!0});Jl(g.shape,h.lineWidth),e.add(g)}},splitArea:function(r,e,t,n){KE(r,e,t,n)}},rO=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="xAxis",e}(tO),F7=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=rO.type,t}return e.type="yAxis",e}(tO),V7=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="grid",t}return e.prototype.render=function(t,n){this.group.removeAll(),t.get("show")&&this.group.add(new We({shape:t.coordinateSystem.getRect(),style:me({fill:t.get("backgroundColor")},t.getItemStyle()),silent:!0,z2:-1}))},e.type="grid",e}(St),nO={offset:0};function aO(r){r.registerComponentView(V7),r.registerComponentModel(f7),r.registerCoordinateSystem("cartesian2d",w7),Iu(r,"x",vb,nO),Iu(r,"y",vb,nO),r.registerComponentView(rO),r.registerComponentView(F7),r.registerPreprocessor(function(e){e.xAxis&&e.yAxis&&!e.grid&&(e.grid={})})}function H7(r){Re(aO),r.registerSeriesModel(n7),r.registerChartView(u7),r.registerLayout(Uf("scatter"))}function W7(r){r.eachSeriesByType("radar",function(e){var t=e.getData(),n=[],a=e.coordinateSystem;if(!!a){var i=a.getIndicatorAxes();C(i,function(o,s){t.each(t.mapDimension(i[s].dim),function(l,u){n[u]=n[u]||[];var c=a.dataToPoint(l,s);n[u][s]=iO(c)?c:oO(a)})}),t.each(function(o){var s=BS(n[o],function(l){return iO(l)})||oO(a);n[o].push(s.slice()),t.setItemLayout(o,n[o])})}})}function iO(r){return!isNaN(r[0])&&!isNaN(r[1])}function oO(r){return[r.cx,r.cy]}function G7(r){var e=r.polar;if(e){J(e)||(e=[e]);var t=[];C(e,function(n,a){n.indicator?(n.type&&!n.shape&&(n.shape=n.type),r.radar=r.radar||[],J(r.radar)||(r.radar=[r.radar]),r.radar.push(n)):t.push(n)}),r.polar=t}C(r.series,function(n){n&&n.type==="radar"&&n.polarIndex&&(n.radarIndex=n.polarIndex)})}var $7=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a){var i=t.coordinateSystem,o=this.group,s=t.getData(),l=this._data;function u(h,v){var d=h.getItemVisual(v,"symbol")||"circle";if(d!=="none"){var p=If(h.getItemVisual(v,"symbolSize")),g=Ft(d,-1,-1,2,2),y=h.getItemVisual(v,"symbolRotate")||0;return g.attr({style:{strokeNoScale:!0},z2:100,scaleX:p[0]/2,scaleY:p[1]/2,rotation:y*Math.PI/180||0}),g}}function c(h,v,d,p,g,y){d.removeAll();for(var m=0;m<v.length-1;m++){var _=u(p,g);_&&(_.__dimIdx=m,h[m]?(_.setPosition(h[m]),uf[y?"initProps":"updateProps"](_,{x:v[m][0],y:v[m][1]},t,g)):_.setPosition(v[m]),d.add(_))}}function f(h){return K(h,function(v){return[i.cx,i.cy]})}s.diff(l).add(function(h){var v=s.getItemLayout(h);if(!!v){var d=new qr,p=new Xr,g={shape:{points:v}};d.shape.points=f(v),p.shape.points=f(v),Dt(d,g,t,h),Dt(p,g,t,h);var y=new De,m=new De;y.add(p),y.add(d),y.add(m),c(p.shape.points,v,m,s,h,!0),s.setItemGraphicEl(h,y)}}).update(function(h,v){var d=l.getItemGraphicEl(v),p=d.childAt(0),g=d.childAt(1),y=d.childAt(2),m={shape:{points:s.getItemLayout(h)}};!m.shape.points||(c(p.shape.points,m.shape.points,y,s,h,!1),ya(g),ya(p),Qe(p,m,t),Qe(g,m,t),s.setItemGraphicEl(h,d))}).remove(function(h){o.remove(l.getItemGraphicEl(h))}).execute(),s.eachItemGraphicEl(function(h,v){var d=s.getItemModel(v),p=h.childAt(0),g=h.childAt(1),y=h.childAt(2),m=s.getItemVisual(v,"style"),_=m.fill;o.add(h),p.useStyle(me(d.getModel("lineStyle").getLineStyle(),{fill:"none",stroke:_})),xr(p,d,"lineStyle"),xr(g,d,"areaStyle");var b=d.getModel("areaStyle"),x=b.isEmpty()&&b.parentModel.isEmpty();g.ignore=x,C(["emphasis","select","blur"],function(D){var T=d.getModel([D,"areaStyle"]),I=T.isEmpty()&&T.parentModel.isEmpty();g.ensureState(D).ignore=I&&x}),g.useStyle(me(b.getAreaStyle(),{fill:_,opacity:.7,decal:m.decal}));var M=d.getModel("emphasis"),w=M.getModel("itemStyle").getItemStyle();y.eachChild(function(D){if(D instanceof pr){var T=D.style;D.useStyle(X({image:T.image,x:T.x,y:T.y,width:T.width,height:T.height},m))}else D.useStyle(m),D.setColor(_),D.style.strokeNoScale=!0;var I=D.ensureState("emphasis");I.style=Me(w);var A=s.getStore().get(s.getDimensionIndex(D.__dimIdx),v);(A==null||isNaN(A))&&(A=""),wr(D,sr(d),{labelFetcher:s.hostModel,labelDataIndex:v,labelDimIndex:D.__dimIdx,defaultText:A,inheritColor:_,defaultOpacity:m.opacity})}),Lt(h,M.get("focus"),M.get("blurScope"),M.get("disabled"))}),this._data=s},e.prototype.remove=function(){this.group.removeAll(),this._data=null},e.type="radar",e}(ht),U7=$7,Y7=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t}return e.prototype.init=function(t){r.prototype.init.apply(this,arguments),this.legendVisualProvider=new Qf(fe(this.getData,this),fe(this.getRawData,this))},e.prototype.getInitialData=function(t,n){return Su(this,{generateCoord:"indicator_",generateCoordCount:1/0})},e.prototype.formatTooltip=function(t,n,a){var i=this.getData(),o=this.coordinateSystem,s=o.getIndicatorAxes(),l=this.getData().getName(t),u=l===""?this.name:l,c=dN(this,t);return lr("section",{header:u,sortBlocks:!0,blocks:K(s,function(f){var h=i.get(i.mapDimension(f.dim),t);return lr("nameValue",{markerType:"subItem",markerColor:c,name:f.name,value:h,sortParam:h})})})},e.prototype.getTooltipPosition=function(t){if(t!=null){for(var n=this.getData(),a=this.coordinateSystem,i=n.getValues(K(a.dimensions,function(u){return n.mapDimension(u)}),t),o=0,s=i.length;o<s;o++)if(!isNaN(i[o])){var l=a.getIndicatorAxes();return a.coordToPoint(l[o].dataToCoord(i[o]),o)}}},e.type="series.radar",e.dependencies=["radar"],e.defaultOption={z:2,colorBy:"data",coordinateSystem:"radar",legendHoverLink:!0,radarIndex:0,lineStyle:{width:2,type:"solid",join:"round"},label:{position:"top"},symbolSize:8},e}(bt),Q7=Y7,qf=FE.value;function jp(r,e){return me({show:e},r)}var Z7=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.optionUpdated=function(){var t=this.get("boundaryGap"),n=this.get("splitNumber"),a=this.get("scale"),i=this.get("axisLine"),o=this.get("axisTick"),s=this.get("axisLabel"),l=this.get("axisName"),u=this.get(["axisName","show"]),c=this.get(["axisName","formatter"]),f=this.get("axisNameGap"),h=this.get("triggerEvent"),v=K(this.get("indicator")||[],function(d){d.max!=null&&d.max>0&&!d.min?d.min=0:d.min!=null&&d.min<0&&!d.max&&(d.max=0);var p=l;d.color!=null&&(p=me({color:d.color},l));var g=Ne(Me(d),{boundaryGap:t,splitNumber:n,scale:a,axisLine:i,axisTick:o,axisLabel:s,name:d.text,showName:u,nameLocation:"end",nameGap:f,nameTextStyle:p,triggerEvent:h},!1);if(ce(c)){var y=g.name;g.name=c.replace("{value}",y!=null?y:"")}else ye(c)&&(g.name=c(g.name,g));var m=new ft(g,null,this.ecModel);return Et(m,Mu.prototype),m.mainType="radar",m.componentIndex=this.componentIndex,m},this);this._indicatorModels=v},e.prototype.getIndicatorModels=function(){return this._indicatorModels},e.type="radar",e.defaultOption={z:0,center:["50%","50%"],radius:"75%",startAngle:90,axisName:{show:!0},boundaryGap:[0,0],splitNumber:5,axisNameGap:15,scale:!1,shape:"polygon",axisLine:Ne({lineStyle:{color:"#bbb"}},qf.axisLine),axisLabel:jp(qf.axisLabel,!1),axisTick:jp(qf.axisTick,!1),splitLine:jp(qf.splitLine,!0),splitArea:jp(qf.splitArea,!0),indicator:[]},e}(He),q7=Z7,X7=["axisLine","axisTickLabel","axisName"],J7=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a){var i=this.group;i.removeAll(),this._buildAxes(t),this._buildSplitLineAndArea(t)},e.prototype._buildAxes=function(t){var n=t.coordinateSystem,a=n.getIndicatorAxes(),i=K(a,function(o){var s=o.model.get("showName")?o.name:"",l=new Di(o.model,{axisName:s,position:[n.cx,n.cy],rotation:o.angle,labelDirection:-1,tickDirection:-1,nameDirection:1});return l});C(i,function(o){C(X7,o.add,o),this.group.add(o.getGroup())},this)},e.prototype._buildSplitLineAndArea=function(t){var n=t.coordinateSystem,a=n.getIndicatorAxes();if(!a.length)return;var i=t.get("shape"),o=t.getModel("splitLine"),s=t.getModel("splitArea"),l=o.getModel("lineStyle"),u=s.getModel("areaStyle"),c=o.get("show"),f=s.get("show"),h=l.get("color"),v=u.get("color"),d=J(h)?h:[h],p=J(v)?v:[v],g=[],y=[];function m(O,P,H){var F=H%P.length;return O[F]=O[F]||[],F}if(i==="circle")for(var _=a[0].getTicksCoords(),b=n.cx,x=n.cy,M=0;M<_.length;M++){if(c){var w=m(g,d,M);g[w].push(new pa({shape:{cx:b,cy:x,r:_[M].coord}}))}if(f&&M<_.length-1){var w=m(y,p,M);y[w].push(new rf({shape:{cx:b,cy:x,r0:_[M].coord,r:_[M+1].coord}}))}}else for(var D,T=K(a,function(O,P){var H=O.getTicksCoords();return D=D==null?H.length-1:Math.min(H.length-1,D),K(H,function(F){return n.coordToPoint(F.coord,P)})}),I=[],M=0;M<=D;M++){for(var A=[],N=0;N<a.length;N++)A.push(T[N][M]);if(A[0]&&A.push(A[0].slice()),c){var w=m(g,d,M);g[w].push(new Xr({shape:{points:A}}))}if(f&&I){var w=m(y,p,M-1);y[w].push(new qr({shape:{points:A.concat(I)}}))}I=A.slice().reverse()}var L=l.getLineStyle(),E=u.getAreaStyle();C(y,function(O,P){this.group.add(xn(O,{style:me({stroke:"none",fill:p[P%p.length]},E),silent:!0}))},this),C(g,function(O,P){this.group.add(xn(O,{style:me({fill:"none",stroke:d[P%d.length]},L),silent:!0}))},this)},e.type="radar",e}(St),K7=J7,e6=function(r){U(e,r);function e(t,n,a){var i=r.call(this,t,n,a)||this;return i.type="value",i.angle=0,i.name="",i}return e}(Yn),t6=e6,r6=function(){function r(e,t,n){this.dimensions=[],this._model=e,this._indicatorAxes=K(e.getIndicatorModels(),function(a,i){var o="indicator_"+i,s=new t6(o,new _o);return s.name=a.get("name"),s.model=a,a.axis=s,this.dimensions.push(o),s},this),this.resize(e,n)}return r.prototype.getIndicatorAxes=function(){return this._indicatorAxes},r.prototype.dataToPoint=function(e,t){var n=this._indicatorAxes[t];return this.coordToPoint(n.dataToCoord(e),t)},r.prototype.coordToPoint=function(e,t){var n=this._indicatorAxes[t],a=n.angle,i=this.cx+e*Math.cos(a),o=this.cy-e*Math.sin(a);return[i,o]},r.prototype.pointToData=function(e){var t=e[0]-this.cx,n=e[1]-this.cy,a=Math.sqrt(t*t+n*n);t/=a,n/=a;for(var i=Math.atan2(-n,t),o=1/0,s,l=-1,u=0;u<this._indicatorAxes.length;u++){var c=this._indicatorAxes[u],f=Math.abs(i-c.angle);f<o&&(s=c,l=u,o=f)}return[l,+(s&&s.coordToData(a))]},r.prototype.resize=function(e,t){var n=e.get("center"),a=t.getWidth(),i=t.getHeight(),o=Math.min(a,i)/2;this.cx=ue(n[0],a),this.cy=ue(n[1],i),this.startAngle=e.get("startAngle")*Math.PI/180;var s=e.get("radius");(ce(s)||Ue(s))&&(s=[0,s]),this.r0=ue(s[0],o),this.r=ue(s[1],o),C(this._indicatorAxes,function(l,u){l.setExtent(this.r0,this.r);var c=this.startAngle+u*Math.PI*2/this._indicatorAxes.length;c=Math.atan2(Math.sin(c),Math.cos(c)),l.angle=c},this)},r.prototype.update=function(e,t){var n=this._indicatorAxes,a=this._model;C(n,function(s){s.scale.setExtent(1/0,-1/0)}),e.eachSeriesByType("radar",function(s,l){if(!(s.get("coordinateSystem")!=="radar"||e.getComponent("radar",s.get("radarIndex"))!==a)){var u=s.getData();C(n,function(c){c.scale.unionExtentFromData(u,u.mapDimension(c.dim))})}},this);var i=a.get("splitNumber"),o=new _o;o.setExtent(0,i),o.setInterval(1),C(n,function(s,l){$E(s.scale,s.model,o)})},r.prototype.convertToPixel=function(e,t,n){return console.warn("Not implemented."),null},r.prototype.convertFromPixel=function(e,t,n){return console.warn("Not implemented."),null},r.prototype.containPoint=function(e){return console.warn("Not implemented."),!1},r.create=function(e,t){var n=[];return e.eachComponent("radar",function(a){var i=new r(a,e,t);n.push(i),a.coordinateSystem=i}),e.eachSeriesByType("radar",function(a){a.get("coordinateSystem")==="radar"&&(a.coordinateSystem=n[a.get("radarIndex")||0])}),n},r.dimensions=[],r}(),n6=r6;function a6(r){r.registerCoordinateSystem("radar",n6),r.registerComponentModel(q7),r.registerComponentView(K7),r.registerVisual({seriesType:"radar",reset:function(e){var t=e.getData();t.each(function(n){t.setItemVisual(n,"legendIcon","roundRect")}),t.setVisual("legendIcon","roundRect")}})}function i6(r){Re(a6),r.registerChartView(U7),r.registerSeriesModel(Q7),r.registerLayout(W7),r.registerProcessor(Yf("radar")),r.registerPreprocessor(G7)}var sO="\0_ec_interaction_mutex";function o6(r,e,t){var n=wb(r);n[e]=t}function s6(r,e,t){var n=wb(r),a=n[e];a===t&&(n[e]=null)}function lO(r,e){return!!wb(r)[e]}function wb(r){return r[sO]||(r[sO]={})}Ma({type:"takeGlobalCursor",event:"globalCursorTaken",update:"update"},Ot);var l6=function(r){U(e,r);function e(t){var n=r.call(this)||this;n._zr=t;var a=fe(n._mousedownHandler,n),i=fe(n._mousemoveHandler,n),o=fe(n._mouseupHandler,n),s=fe(n._mousewheelHandler,n),l=fe(n._pinchHandler,n);return n.enable=function(u,c){this.disable(),this._opt=me(Me(c)||{},{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}),u==null&&(u=!0),(u===!0||u==="move"||u==="pan")&&(t.on("mousedown",a),t.on("mousemove",i),t.on("mouseup",o)),(u===!0||u==="scale"||u==="zoom")&&(t.on("mousewheel",s),t.on("pinch",l))},n.disable=function(){t.off("mousedown",a),t.off("mousemove",i),t.off("mouseup",o),t.off("mousewheel",s),t.off("pinch",l)},n}return e.prototype.isDragging=function(){return this._dragging},e.prototype.isPinching=function(){return this._pinching},e.prototype.setPointerChecker=function(t){this.pointerChecker=t},e.prototype.dispose=function(){this.disable()},e.prototype._mousedownHandler=function(t){if(!XS(t)){for(var n=t.target;n;){if(n.draggable)return;n=n.__hostTarget||n.parent}var a=t.offsetX,i=t.offsetY;this.pointerChecker&&this.pointerChecker(t,a,i)&&(this._x=a,this._y=i,this._dragging=!0)}},e.prototype._mousemoveHandler=function(t){if(!(!this._dragging||!Bp("moveOnMouseMove",t,this._opt)||t.gestureEvent==="pinch"||lO(this._zr,"globalPan"))){var n=t.offsetX,a=t.offsetY,i=this._x,o=this._y,s=n-i,l=a-o;this._x=n,this._y=a,this._opt.preventDefaultMouseMove&&hi(t.event),uO(this,"pan","moveOnMouseMove",t,{dx:s,dy:l,oldX:i,oldY:o,newX:n,newY:a,isAvailableBehavior:null})}},e.prototype._mouseupHandler=function(t){XS(t)||(this._dragging=!1)},e.prototype._mousewheelHandler=function(t){var n=Bp("zoomOnMouseWheel",t,this._opt),a=Bp("moveOnMouseWheel",t,this._opt),i=t.wheelDelta,o=Math.abs(i),s=t.offsetX,l=t.offsetY;if(!(i===0||!n&&!a)){if(n){var u=o>3?1.4:o>1?1.2:1.1,c=i>0?u:1/u;Db(this,"zoom","zoomOnMouseWheel",t,{scale:c,originX:s,originY:l,isAvailableBehavior:null})}if(a){var f=Math.abs(i),h=(i>0?1:-1)*(f>3?.4:f>1?.15:.05);Db(this,"scrollMove","moveOnMouseWheel",t,{scrollDelta:h,originX:s,originY:l,isAvailableBehavior:null})}}},e.prototype._pinchHandler=function(t){if(!lO(this._zr,"globalPan")){var n=t.pinchScale>1?1.1:1/1.1;Db(this,"zoom",null,t,{scale:n,originX:t.pinchX,originY:t.pinchY,isAvailableBehavior:null})}},e}(zn);function Db(r,e,t,n,a){r.pointerChecker&&r.pointerChecker(n,a.originX,a.originY)&&(hi(n.event),uO(r,e,t,n,a))}function uO(r,e,t,n,a){a.isAvailableBehavior=fe(Bp,null,t,n),r.trigger(e,a)}function Bp(r,e,t){var n=t[r];return!r||n&&(!ce(n)||e.event[n+"Key"])}var Xf=l6;function Sb(r,e,t){var n=r.target;n.x+=e,n.y+=t,n.dirty()}function Ib(r,e,t,n){var a=r.target,i=r.zoomLimit,o=r.zoom=r.zoom||1;if(o*=e,i){var s=i.min||0,l=i.max||1/0;o=Math.max(Math.min(l,o),s)}var u=o/r.zoom;r.zoom=o,a.x-=(t-a.x)*(u-1),a.y-=(n-a.y)*(u-1),a.scaleX*=u,a.scaleY*=u,a.dirty()}var u6={axisPointer:1,tooltip:1,brush:1};function Fp(r,e,t){var n=e.getComponentByElement(r.topTarget),a=n&&n.coordinateSystem;return n&&n!==t&&!u6.hasOwnProperty(n.mainType)&&a&&a.model!==t}function cO(r){if(ce(r)){var e=new DOMParser;r=e.parseFromString(r,"text/xml")}var t=r;for(t.nodeType===9&&(t=t.firstChild);t.nodeName.toLowerCase()!=="svg"||t.nodeType!==1;)t=t.nextSibling;return t}var Tb,Vp={fill:"fill",stroke:"stroke","stroke-width":"lineWidth",opacity:"opacity","fill-opacity":"fillOpacity","stroke-opacity":"strokeOpacity","stroke-dasharray":"lineDash","stroke-dashoffset":"lineDashOffset","stroke-linecap":"lineCap","stroke-linejoin":"lineJoin","stroke-miterlimit":"miterLimit","font-family":"fontFamily","font-size":"fontSize","font-style":"fontStyle","font-weight":"fontWeight","text-anchor":"textAlign",visibility:"visibility",display:"display"},fO=Fe(Vp),Hp={"alignment-baseline":"textBaseline","stop-color":"stopColor"},hO=Fe(Hp),c6=function(){function r(){this._defs={},this._root=null}return r.prototype.parse=function(e,t){t=t||{};var n=cO(e);this._defsUsePending=[];var a=new De;this._root=a;var i=[],o=n.getAttribute("viewBox")||"",s=parseFloat(n.getAttribute("width")||t.width),l=parseFloat(n.getAttribute("height")||t.height);isNaN(s)&&(s=null),isNaN(l)&&(l=null),Dn(n,a,null,!0,!1);for(var u=n.firstChild;u;)this._parseNode(u,a,i,null,!1,!1),u=u.nextSibling;v6(this._defs,this._defsUsePending),this._defsUsePending=[];var c,f;if(o){var h=Wp(o);h.length>=4&&(c={x:parseFloat(h[0]||0),y:parseFloat(h[1]||0),width:parseFloat(h[2]),height:parseFloat(h[3])})}if(c&&s!=null&&l!=null&&(f=bO(c,{x:0,y:0,width:s,height:l}),!t.ignoreViewBox)){var v=a;a=new De,a.add(v),v.scaleX=v.scaleY=f.scale,v.x=f.x,v.y=f.y}return!t.ignoreRootClip&&s!=null&&l!=null&&a.setClipPath(new We({shape:{x:0,y:0,width:s,height:l}})),{root:a,width:s,height:l,viewBoxRect:c,viewBoxTransform:f,named:i}},r.prototype._parseNode=function(e,t,n,a,i,o){var s=e.nodeName.toLowerCase(),l,u=a;if(s==="defs"&&(i=!0),s==="text"&&(o=!0),s==="defs"||s==="switch")l=t;else{if(!i){var c=Tb[s];if(c&&ve(Tb,s)){l=c.call(this,e,t);var f=e.getAttribute("name");if(f){var h={name:f,namedFrom:null,svgNodeTagLower:s,el:l};n.push(h),s==="g"&&(u=h)}else a&&n.push({name:a.name,namedFrom:a,svgNodeTagLower:s,el:l});t.add(l)}}var v=vO[s];if(v&&ve(vO,s)){var d=v.call(this,e),p=e.getAttribute("id");p&&(this._defs[p]=d)}}if(l&&l.isGroup)for(var g=e.firstChild;g;)g.nodeType===1?this._parseNode(g,l,n,u,i,o):g.nodeType===3&&o&&this._parseText(g,l),g=g.nextSibling},r.prototype._parseText=function(e,t){var n=new Yc({style:{text:e.textContent},silent:!0,x:this._textX||0,y:this._textY||0});Zn(t,n),Dn(e,n,this._defsUsePending,!1,!1),f6(n,t);var a=n.style,i=a.fontSize;i&&i<9&&(a.fontSize=9,n.scaleX*=i/9,n.scaleY*=i/9);var o=(a.fontSize||a.fontFamily)&&[a.fontStyle,a.fontWeight,(a.fontSize||12)+"px",a.fontFamily||"sans-serif"].join(" ");a.font=o;var s=n.getBoundingRect();return this._textX+=s.width,t.add(n),n},r.internalField=function(){Tb={g:function(e,t){var n=new De;return Zn(t,n),Dn(e,n,this._defsUsePending,!1,!1),n},rect:function(e,t){var n=new We;return Zn(t,n),Dn(e,n,this._defsUsePending,!1,!1),n.setShape({x:parseFloat(e.getAttribute("x")||"0"),y:parseFloat(e.getAttribute("y")||"0"),width:parseFloat(e.getAttribute("width")||"0"),height:parseFloat(e.getAttribute("height")||"0")}),n.silent=!0,n},circle:function(e,t){var n=new pa;return Zn(t,n),Dn(e,n,this._defsUsePending,!1,!1),n.setShape({cx:parseFloat(e.getAttribute("cx")||"0"),cy:parseFloat(e.getAttribute("cy")||"0"),r:parseFloat(e.getAttribute("r")||"0")}),n.silent=!0,n},line:function(e,t){var n=new or;return Zn(t,n),Dn(e,n,this._defsUsePending,!1,!1),n.setShape({x1:parseFloat(e.getAttribute("x1")||"0"),y1:parseFloat(e.getAttribute("y1")||"0"),x2:parseFloat(e.getAttribute("x2")||"0"),y2:parseFloat(e.getAttribute("y2")||"0")}),n.silent=!0,n},ellipse:function(e,t){var n=new md;return Zn(t,n),Dn(e,n,this._defsUsePending,!1,!1),n.setShape({cx:parseFloat(e.getAttribute("cx")||"0"),cy:parseFloat(e.getAttribute("cy")||"0"),rx:parseFloat(e.getAttribute("rx")||"0"),ry:parseFloat(e.getAttribute("ry")||"0")}),n.silent=!0,n},polygon:function(e,t){var n=e.getAttribute("points"),a;n&&(a=gO(n));var i=new qr({shape:{points:a||[]},silent:!0});return Zn(t,i),Dn(e,i,this._defsUsePending,!1,!1),i},polyline:function(e,t){var n=e.getAttribute("points"),a;n&&(a=gO(n));var i=new Xr({shape:{points:a||[]},silent:!0});return Zn(t,i),Dn(e,i,this._defsUsePending,!1,!1),i},image:function(e,t){var n=new pr;return Zn(t,n),Dn(e,n,this._defsUsePending,!1,!1),n.setStyle({image:e.getAttribute("xlink:href")||e.getAttribute("href"),x:+e.getAttribute("x"),y:+e.getAttribute("y"),width:+e.getAttribute("width"),height:+e.getAttribute("height")}),n.silent=!0,n},text:function(e,t){var n=e.getAttribute("x")||"0",a=e.getAttribute("y")||"0",i=e.getAttribute("dx")||"0",o=e.getAttribute("dy")||"0";this._textX=parseFloat(n)+parseFloat(i),this._textY=parseFloat(a)+parseFloat(o);var s=new De;return Zn(t,s),Dn(e,s,this._defsUsePending,!1,!0),s},tspan:function(e,t){var n=e.getAttribute("x"),a=e.getAttribute("y");n!=null&&(this._textX=parseFloat(n)),a!=null&&(this._textY=parseFloat(a));var i=e.getAttribute("dx")||"0",o=e.getAttribute("dy")||"0",s=new De;return Zn(t,s),Dn(e,s,this._defsUsePending,!1,!0),this._textX+=parseFloat(i),this._textY+=parseFloat(o),s},path:function(e,t){var n=e.getAttribute("d")||"",a=gA(n);return Zn(t,a),Dn(e,a,this._defsUsePending,!1,!1),a.silent=!0,a}}}(),r}(),vO={lineargradient:function(r){var e=parseInt(r.getAttribute("x1")||"0",10),t=parseInt(r.getAttribute("y1")||"0",10),n=parseInt(r.getAttribute("x2")||"10",10),a=parseInt(r.getAttribute("y2")||"0",10),i=new Zl(e,t,n,a);return dO(r,i),pO(r,i),i},radialgradient:function(r){var e=parseInt(r.getAttribute("cx")||"0",10),t=parseInt(r.getAttribute("cy")||"0",10),n=parseInt(r.getAttribute("r")||"0",10),a=new c1(e,t,n);return dO(r,a),pO(r,a),a}};function dO(r,e){var t=r.getAttribute("gradientUnits");t==="userSpaceOnUse"&&(e.global=!0)}function pO(r,e){for(var t=r.firstChild;t;){if(t.nodeType===1&&t.nodeName.toLocaleLowerCase()==="stop"){var n=t.getAttribute("offset"),a=void 0;n&&n.indexOf("%")>0?a=parseInt(n,10)/100:n?a=parseFloat(n):a=0;var i={};_O(t,i,i);var o=i.stopColor||t.getAttribute("stop-color")||"#000000";e.colorStops.push({offset:a,color:o})}t=t.nextSibling}}function Zn(r,e){r&&r.__inheritedStyle&&(e.__inheritedStyle||(e.__inheritedStyle={}),me(e.__inheritedStyle,r.__inheritedStyle))}function gO(r){for(var e=Wp(r),t=[],n=0;n<e.length;n+=2){var a=parseFloat(e[n]),i=parseFloat(e[n+1]);t.push([a,i])}return t}function Dn(r,e,t,n,a){var i=e,o=i.__inheritedStyle=i.__inheritedStyle||{},s={};r.nodeType===1&&(g6(r,e),_O(r,o,s),n||y6(r,o,s)),i.style=i.style||{},o.fill!=null&&(i.style.fill=yO(i,"fill",o.fill,t)),o.stroke!=null&&(i.style.stroke=yO(i,"stroke",o.stroke,t)),C(["lineWidth","opacity","fillOpacity","strokeOpacity","miterLimit","fontSize"],function(l){o[l]!=null&&(i.style[l]=parseFloat(o[l]))}),C(["lineDashOffset","lineCap","lineJoin","fontWeight","fontFamily","fontStyle","textAlign"],function(l){o[l]!=null&&(i.style[l]=o[l])}),a&&(i.__selfStyle=s),o.lineDash&&(i.style.lineDash=K(Wp(o.lineDash),function(l){return parseFloat(l)})),(o.visibility==="hidden"||o.visibility==="collapse")&&(i.invisible=!0),o.display==="none"&&(i.ignore=!0)}function f6(r,e){var t=e.__selfStyle;if(t){var n=t.textBaseline,a=n;!n||n==="auto"||n==="baseline"?a="alphabetic":n==="before-edge"||n==="text-before-edge"?a="top":n==="after-edge"||n==="text-after-edge"?a="bottom":(n==="central"||n==="mathematical")&&(a="middle"),r.style.textBaseline=a}var i=e.__inheritedStyle;if(i){var o=i.textAlign,s=o;o&&(o==="middle"&&(s="center"),r.style.textAlign=s)}}var h6=/^url\(\s*#(.*?)\)/;function yO(r,e,t,n){var a=t&&t.match(h6);if(a){var i=Pn(a[1]);n.push([r,e,i]);return}return t==="none"&&(t=null),t}function v6(r,e){for(var t=0;t<e.length;t++){var n=e[t];n[0].style[n[1]]=r[n[2]]}}var d6=/-?([0-9]*\.)?[0-9]+([eE]-?[0-9]+)?/g;function Wp(r){return r.match(d6)||[]}var p6=/(translate|scale|rotate|skewX|skewY|matrix)\(([\-\s0-9\.eE,]*)\)/g,Ab=Math.PI/180;function g6(r,e){var t=r.getAttribute("transform");if(t){t=t.replace(/,/g," ");var n=[],a=null;t.replace(p6,function(f,h,v){return n.push(h,v),""});for(var i=n.length-1;i>0;i-=2){var o=n[i],s=n[i-1],l=Wp(o);switch(a=a||yn(),s){case"translate":ua(a,a,[parseFloat(l[0]),parseFloat(l[1]||"0")]);break;case"scale":Lv(a,a,[parseFloat(l[0]),parseFloat(l[1]||l[0])]);break;case"rotate":Zi(a,a,-parseFloat(l[0])*Ab);break;case"skewX":var u=Math.tan(parseFloat(l[0])*Ab);Pa(a,[1,0,u,1,0,0],a);break;case"skewY":var c=Math.tan(parseFloat(l[0])*Ab);Pa(a,[1,c,0,1,0,0],a);break;case"matrix":a[0]=parseFloat(l[0]),a[1]=parseFloat(l[1]),a[2]=parseFloat(l[2]),a[3]=parseFloat(l[3]),a[4]=parseFloat(l[4]),a[5]=parseFloat(l[5]);break}}e.setLocalTransform(a)}}var mO=/([^\s:;]+)\s*:\s*([^:;]+)/g;function _O(r,e,t){var n=r.getAttribute("style");if(!!n){mO.lastIndex=0;for(var a;(a=mO.exec(n))!=null;){var i=a[1],o=ve(Vp,i)?Vp[i]:null;o&&(e[o]=a[2]);var s=ve(Hp,i)?Hp[i]:null;s&&(t[s]=a[2])}}}function y6(r,e,t){for(var n=0;n<fO.length;n++){var a=fO[n],i=r.getAttribute(a);i!=null&&(e[Vp[a]]=i)}for(var n=0;n<hO.length;n++){var a=hO[n],i=r.getAttribute(a);i!=null&&(t[Hp[a]]=i)}}function bO(r,e){var t=e.width/r.width,n=e.height/r.height,a=Math.min(t,n);return{scale:a,x:-(r.x+r.width/2)*a+(e.x+e.width/2),y:-(r.y+r.height/2)*a+(e.y+e.height/2)}}function m6(r,e){var t=new c6;return t.parse(r,e)}var _6=ge(["rect","circle","line","ellipse","polygon","polyline","path","text","tspan","g"]),b6=function(){function r(e,t){this.type="geoSVG",this._usedGraphicMap=ge(),this._freedGraphics=[],this._mapName=e,this._parsedXML=cO(t)}return r.prototype.load=function(){var e=this._firstGraphic;if(!e){e=this._firstGraphic=this._buildGraphic(this._parsedXML),this._freedGraphics.push(e),this._boundingRect=this._firstGraphic.boundingRect.clone();var t=x6(e.named),n=t.regions,a=t.regionsMap;this._regions=n,this._regionsMap=a}return{boundingRect:this._boundingRect,regions:this._regions,regionsMap:this._regionsMap}},r.prototype._buildGraphic=function(e){var t,n;try{t=e&&m6(e,{ignoreViewBox:!0,ignoreRootClip:!0})||{},n=t.root,Er(n!=null)}catch(g){throw new Error(`Invalid svg format
|
|
239
|
+
`+g.message)}var a=new De;a.add(n),a.isGeoSVGGraphicRoot=!0;var i=t.width,o=t.height,s=t.viewBoxRect,l=this._boundingRect;if(!l){var u=void 0,c=void 0,f=void 0,h=void 0;if(i!=null?(u=0,f=i):s&&(u=s.x,f=s.width),o!=null?(c=0,h=o):s&&(c=s.y,h=s.height),u==null||c==null){var v=n.getBoundingRect();u==null&&(u=v.x,f=v.width),c==null&&(c=v.y,h=v.height)}l=this._boundingRect=new Pe(u,c,f,h)}if(s){var d=bO(s,l);n.scaleX=n.scaleY=d.scale,n.x=d.x,n.y=d.y}a.setClipPath(new We({shape:l.plain()}));var p=[];return C(t.named,function(g){_6.get(g.svgNodeTagLower)!=null&&(p.push(g),M6(g.el))}),{root:a,boundingRect:l,named:p}},r.prototype.useGraphic=function(e){var t=this._usedGraphicMap,n=t.get(e);return n||(n=this._freedGraphics.pop()||this._buildGraphic(this._parsedXML),t.set(e,n),n)},r.prototype.freeGraphic=function(e){var t=this._usedGraphicMap,n=t.get(e);n&&(t.removeKey(e),this._freedGraphics.push(n))},r}();function M6(r){r.silent=!1,r.isGroup&&r.traverse(function(e){e.silent=!1})}function x6(r){var e=[],t=ge();return C(r,function(n){if(n.namedFrom==null){var a=new OQ(n.name,n.el);e.push(a),t.set(n.name,a)}}),{regions:e,regionsMap:t}}for(var Cb=[126,25],MO="\u5357\u6D77\u8BF8\u5C9B",$s=[[[0,3.5],[7,11.2],[15,11.9],[30,7],[42,.7],[52,.7],[56,7.7],[59,.7],[64,.7],[64,0],[5,0],[0,3.5]],[[13,16.1],[19,14.7],[16,21.7],[11,23.1],[13,16.1]],[[12,32.2],[14,38.5],[15,38.5],[13,32.2],[12,32.2]],[[16,47.6],[12,53.2],[13,53.2],[18,47.6],[16,47.6]],[[6,64.4],[8,70],[9,70],[8,64.4],[6,64.4]],[[23,82.6],[29,79.8],[30,79.8],[25,82.6],[23,82.6]],[[37,70.7],[43,62.3],[44,62.3],[39,70.7],[37,70.7]],[[48,51.1],[51,45.5],[53,45.5],[50,51.1],[48,51.1]],[[51,35],[51,28.7],[53,28.7],[53,35],[51,35]],[[52,22.4],[55,17.5],[56,17.5],[53,22.4],[52,22.4]],[[58,12.6],[62,7],[63,7],[60,12.6],[58,12.6]],[[0,3.5],[0,93.1],[64,93.1],[64,0],[63,0],[63,92.4],[1,92.4],[1,3.5],[0,3.5]]],Us=0;Us<$s.length;Us++)for(var Tu=0;Tu<$s[Us].length;Tu++)$s[Us][Tu][0]/=10.5,$s[Us][Tu][1]/=-10.5/.75,$s[Us][Tu][0]+=Cb[0],$s[Us][Tu][1]+=Cb[1];function w6(r,e){if(r==="china"){for(var t=0;t<e.length;t++)if(e[t].name===MO)return;e.push(new h2(MO,K($s,function(n){return{type:"polygon",exterior:n}}),Cb))}}var D6={\u5357\u6D77\u8BF8\u5C9B:[32,80],\u5E7F\u4E1C:[0,-10],\u9999\u6E2F:[10,5],\u6FB3\u95E8:[-10,10],\u5929\u6D25:[5,5]};function S6(r,e){if(r==="china"){var t=D6[e.name];if(t){var n=e.getCenter();n[0]+=t[0]/10.5,n[1]+=-t[1]/(10.5/.75),e.setCenter(n)}}}var I6=[[[123.45165252685547,25.73527164402261],[123.49731445312499,25.73527164402261],[123.49731445312499,25.750734064600884],[123.45165252685547,25.750734064600884],[123.45165252685547,25.73527164402261]]];function T6(r,e){r==="china"&&e.name==="\u53F0\u6E7E"&&e.geometries.push({type:"polygon",exterior:I6[0]})}var A6="name",C6=function(){function r(e,t,n){this.type="geoJSON",this._parsedMap=ge(),this._mapName=e,this._specialAreas=n,this._geoJSON=L6(t)}return r.prototype.load=function(e,t){t=t||A6;var n=this._parsedMap.get(t);if(!n){var a=this._parseToRegions(t);n=this._parsedMap.set(t,{regions:a,boundingRect:N6(a)})}var i=ge(),o=[];return C(n.regions,function(s){var l=s.name;e&&ve(e,l)&&(s=s.cloneShallow(l=e[l])),o.push(s),i.set(l,s)}),{regions:o,boundingRect:n.boundingRect||new Pe(0,0,0,0),regionsMap:i}},r.prototype._parseToRegions=function(e){var t=this._mapName,n=this._geoJSON,a;try{a=n?$_(n,e):[]}catch(i){throw new Error(`Invalid geoJson format
|
|
240
|
+
`+i.message)}return w6(t,a),C(a,function(i){var o=i.name;S6(t,i),T6(t,i);var s=this._specialAreas&&this._specialAreas[o];s&&i.transformTo(s.left,s.top,s.width,s.height)},this),a},r.prototype.getMapForUser=function(){return{geoJson:this._geoJSON,geoJSON:this._geoJSON,specialAreas:this._specialAreas}},r}();function N6(r){for(var e,t=0;t<r.length;t++){var n=r[t].getBoundingRect();e=e||n.clone(),e.union(n)}return e}function L6(r){return ce(r)?typeof JSON!="undefined"&&JSON.parse?JSON.parse(r):new Function("return ("+r+");")():r}var Jf=ge(),Si={registerMap:function(r,e,t){if(e.svg){var n=new b6(r,e.svg);Jf.set(r,n)}else{var a=e.geoJson||e.geoJSON;a&&!e.features?t=e.specialAreas:a=e;var n=new C6(r,a,t);Jf.set(r,n)}},getGeoResource:function(r){return Jf.get(r)},getMapForUser:function(r){var e=Jf.get(r);return e&&e.type==="geoJSON"&&e.getMapForUser()},load:function(r,e,t){var n=Jf.get(r);if(!!n)return n.load(e,t)}},Nb=["rect","circle","line","ellipse","polygon","polyline","path"],E6=ge(Nb),O6=ge(Nb.concat(["g"])),P6=ge(Nb.concat(["g"])),xO=Ye();function Gp(r){var e=r.getItemStyle(),t=r.get("areaColor");return t!=null&&(e.fill=t),e}function wO(r){var e=r.style;e&&(e.stroke=e.stroke||e.fill,e.fill=null)}var z6=function(){function r(e){var t=new De;this.uid=ru("ec_map_draw"),this._controller=new Xf(e.getZr()),this._controllerHost={target:t},this.group=t,t.add(this._regionsGroup=new De),t.add(this._svgGroup=new De)}return r.prototype.draw=function(e,t,n,a,i){var o=e.mainType==="geo",s=e.getData&&e.getData();o&&t.eachComponent({mainType:"series",subType:"map"},function(y){!s&&y.getHostGeoModel()===e&&(s=y.getData())});var l=e.coordinateSystem,u=this._regionsGroup,c=this.group,f=l.getTransformInfo(),h=f.raw,v=f.roam,d=!u.childAt(0)||i;d?(c.x=v.x,c.y=v.y,c.scaleX=v.scaleX,c.scaleY=v.scaleY,c.dirty()):Qe(c,v,e);var p=s&&s.getVisual("visualMeta")&&s.getVisual("visualMeta").length>0,g={api:n,geo:l,mapOrGeoModel:e,data:s,isVisualEncodedByVisualMap:p,isGeo:o,transformInfoRaw:h};l.resourceType==="geoJSON"?this._buildGeoJSON(g):l.resourceType==="geoSVG"&&this._buildSVG(g),this._updateController(e,t,n),this._updateMapSelectHandler(e,u,n,a)},r.prototype._buildGeoJSON=function(e){var t=this._regionsGroupByName=ge(),n=ge(),a=this._regionsGroup,i=e.transformInfoRaw,o=e.mapOrGeoModel,s=e.data,l=e.geo.projection,u=l&&l.stream;function c(v,d){return d&&(v=d(v)),v&&[v[0]*i.scaleX+i.x,v[1]*i.scaleY+i.y]}function f(v){for(var d=[],p=!u&&l&&l.project,g=0;g<v.length;++g){var y=c(v[g],p);y&&d.push(y)}return d}function h(v){return{shape:{points:f(v)}}}a.removeAll(),C(e.geo.regions,function(v){var d=v.name,p=t.get(d),g=n.get(d)||{},y=g.dataIdx,m=g.regionModel;p||(p=t.set(d,new De),a.add(p),y=s?s.indexOfName(d):null,m=e.isGeo?o.getRegionModel(d):s?s.getItemModel(y):null,n.set(d,{dataIdx:y,regionModel:m}));var _=[],b=[];C(v.geometries,function(w){if(w.type==="polygon"){var D=[w.exterior].concat(w.interiors||[]);u&&(D=CO(D,u)),C(D,function(I){_.push(new qr(h(I)))})}else{var T=w.points;u&&(T=CO(T,u,!0)),C(T,function(I){b.push(new Xr(h(I)))})}});var x=c(v.getCenter(),l&&l.project);function M(w,D){if(!!w.length){var T=new Md({culling:!0,segmentIgnoreThreshold:1,shape:{paths:w}});p.add(T),DO(e,T,y,m),SO(e,T,d,m,o,y,x),D&&(wO(T),C(T.states,wO))}}M(_),M(b,!0)}),t.each(function(v,d){var p=n.get(d),g=p.dataIdx,y=p.regionModel;IO(e,v,d,y,o,g),TO(e,v,d,y,o),AO(e,v,d,y,o)},this)},r.prototype._buildSVG=function(e){var t=e.geo.map,n=e.transformInfoRaw;this._svgGroup.x=n.x,this._svgGroup.y=n.y,this._svgGroup.scaleX=n.scaleX,this._svgGroup.scaleY=n.scaleY,this._svgResourceChanged(t)&&(this._freeSVG(),this._useSVG(t));var a=this._svgDispatcherMap=ge(),i=!1;C(this._svgGraphicRecord.named,function(o){var s=o.name,l=e.mapOrGeoModel,u=e.data,c=o.svgNodeTagLower,f=o.el,h=u?u.indexOfName(s):null,v=l.getRegionModel(s);if(E6.get(c)!=null&&f instanceof Bn&&DO(e,f,h,v),f instanceof Bn&&(f.culling=!0),f.z2EmphasisLift=0,!o.namedFrom&&(P6.get(c)!=null&&SO(e,f,s,v,l,h,null),IO(e,f,s,v,l,h),TO(e,f,s,v,l),O6.get(c)!=null)){var d=AO(e,f,s,v,l);d==="self"&&(i=!0);var p=a.get(s)||a.set(s,[]);p.push(f)}},this),this._enableBlurEntireSVG(i,e)},r.prototype._enableBlurEntireSVG=function(e,t){if(e&&t.isGeo){var n=t.mapOrGeoModel.getModel(["blur","itemStyle"]).getItemStyle(),a=n.opacity;this._svgGraphicRecord.root.traverse(function(i){if(!i.isGroup){gs(i);var o=i.ensureState("blur").style||{};o.opacity==null&&a!=null&&(o.opacity=a),i.ensureState("emphasis")}})}},r.prototype.remove=function(){this._regionsGroup.removeAll(),this._regionsGroupByName=null,this._svgGroup.removeAll(),this._freeSVG(),this._controller.dispose(),this._controllerHost=null},r.prototype.findHighDownDispatchers=function(e,t){if(e==null)return[];var n=t.coordinateSystem;if(n.resourceType==="geoJSON"){var a=this._regionsGroupByName;if(a){var i=a.get(e);return i?[i]:[]}}else if(n.resourceType==="geoSVG")return this._svgDispatcherMap&&this._svgDispatcherMap.get(e)||[]},r.prototype._svgResourceChanged=function(e){return this._svgMapName!==e},r.prototype._useSVG=function(e){var t=Si.getGeoResource(e);if(t&&t.type==="geoSVG"){var n=t.useGraphic(this.uid);this._svgGroup.add(n.root),this._svgGraphicRecord=n,this._svgMapName=e}},r.prototype._freeSVG=function(){var e=this._svgMapName;if(e!=null){var t=Si.getGeoResource(e);t&&t.type==="geoSVG"&&t.freeGraphic(this.uid),this._svgGraphicRecord=null,this._svgDispatcherMap=null,this._svgGroup.removeAll(),this._svgMapName=null}},r.prototype._updateController=function(e,t,n){var a=e.coordinateSystem,i=this._controller,o=this._controllerHost;o.zoomLimit=e.get("scaleLimit"),o.zoom=a.getZoom(),i.enable(e.get("roam")||!1);var s=e.mainType;function l(){var u={type:"geoRoam",componentType:s};return u[s+"Id"]=e.id,u}i.off("pan").on("pan",function(u){this._mouseDownFlag=!1,Sb(o,u.dx,u.dy),n.dispatchAction(X(l(),{dx:u.dx,dy:u.dy,animation:{duration:0}}))},this),i.off("zoom").on("zoom",function(u){this._mouseDownFlag=!1,Ib(o,u.scale,u.originX,u.originY),n.dispatchAction(X(l(),{zoom:u.scale,originX:u.originX,originY:u.originY,animation:{duration:0}}))},this),i.setPointerChecker(function(u,c,f){return a.containPoint([c,f])&&!Fp(u,n,e)})},r.prototype.resetForLabelLayout=function(){this.group.traverse(function(e){var t=e.getTextContent();t&&(t.ignore=xO(t).ignore)})},r.prototype._updateMapSelectHandler=function(e,t,n,a){var i=this;t.off("mousedown"),t.off("click"),e.get("selectedMode")&&(t.on("mousedown",function(){i._mouseDownFlag=!0}),t.on("click",function(o){!i._mouseDownFlag||(i._mouseDownFlag=!1)}))},r}();function DO(r,e,t,n){var a=n.getModel("itemStyle"),i=n.getModel(["emphasis","itemStyle"]),o=n.getModel(["blur","itemStyle"]),s=n.getModel(["select","itemStyle"]),l=Gp(a),u=Gp(i),c=Gp(s),f=Gp(o),h=r.data;if(h){var v=h.getItemVisual(t,"style"),d=h.getItemVisual(t,"decal");r.isVisualEncodedByVisualMap&&v.fill&&(l.fill=v.fill),d&&(l.decal=yu(d,r.api))}e.setStyle(l),e.style.strokeNoScale=!0,e.ensureState("emphasis").style=u,e.ensureState("select").style=c,e.ensureState("blur").style=f,gs(e)}function SO(r,e,t,n,a,i,o){var s=r.data,l=r.isGeo,u=s&&isNaN(s.get(s.mapDimension("value"),i)),c=s&&s.getItemLayout(i);if(l||u||c&&c.showLabel){var f=l?t:i,h=void 0;(!s||i>=0)&&(h=a);var v=o?{normal:{align:"center",verticalAlign:"middle"}}:null;wr(e,sr(n),{labelFetcher:h,labelDataIndex:f,defaultText:t},v);var d=e.getTextContent();if(d&&(xO(d).ignore=d.ignore,e.textConfig&&o)){var p=e.getBoundingRect().clone();e.textConfig.layoutRect=p,e.textConfig.position=[(o[0]-p.x)/p.width*100+"%",(o[1]-p.y)/p.height*100+"%"]}e.disableLabelAnimation=!0}else e.removeTextContent(),e.removeTextConfig(),e.disableLabelAnimation=null}function IO(r,e,t,n,a,i){r.data?r.data.setItemGraphicEl(i,e):Te(e).eventData={componentType:"geo",componentIndex:a.componentIndex,geoIndex:a.componentIndex,name:t,region:n&&n.option||{}}}function TO(r,e,t,n,a){r.data||eu({el:e,componentModel:a,itemName:t,itemTooltipOption:n.get("tooltip")})}function AO(r,e,t,n,a){e.highDownSilentOnTouch=!!a.get("selectedMode");var i=n.getModel("emphasis"),o=i.get("focus");return Lt(e,o,i.get("blurScope"),i.get("disabled")),r.isGeo&&wG(e,a,t),o}function CO(r,e,t){var n=[],a;function i(){a=[]}function o(){a.length&&(n.push(a),a=[])}var s=e({polygonStart:i,polygonEnd:o,lineStart:i,lineEnd:o,point:function(l,u){isFinite(l)&&isFinite(u)&&a.push([l,u])},sphere:function(){}});return!t&&s.polygonStart(),C(r,function(l){s.lineStart();for(var u=0;u<l.length;u++)s.point(l[u][0],l[u][1]);s.lineEnd()}),!t&&s.polygonEnd(),n}var NO=z6,k6=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a,i){if(!(i&&i.type==="mapToggleSelect"&&i.from===this.uid)){var o=this.group;if(o.removeAll(),!t.getHostGeoModel()){if(this._mapDraw&&i&&i.type==="geoRoam"&&this._mapDraw.resetForLabelLayout(),i&&i.type==="geoRoam"&&i.componentType==="series"&&i.seriesId===t.id){var s=this._mapDraw;s&&o.add(s.group)}else if(t.needsDrawMap){var s=this._mapDraw||new NO(a);o.add(s.group),s.draw(t,n,a,this,i),this._mapDraw=s}else this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null;t.get("showLegendSymbol")&&n.getComponent("legend")&&this._renderSymbols(t,n,a)}}},e.prototype.remove=function(){this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null,this.group.removeAll()},e.prototype.dispose=function(){this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null},e.prototype._renderSymbols=function(t,n,a){var i=t.originalData,o=this.group;i.each(i.mapDimension("value"),function(s,l){if(!isNaN(s)){var u=i.getItemLayout(l);if(!(!u||!u.point)){var c=u.point,f=u.offset,h=new pa({style:{fill:t.getData().getVisual("style").fill},shape:{cx:c[0]+f*9,cy:c[1],r:3},silent:!0,z2:8+(f?0:$l+1)});if(!f){var v=t.mainSeries.getData(),d=i.getName(l),p=v.indexOfName(d),g=i.getItemModel(l),y=g.getModel("label"),m=v.getItemGraphicEl(p);wr(h,sr(g),{labelFetcher:{getFormattedLabel:function(_,b){return t.getFormattedLabel(p,b)}},defaultText:d}),h.disableLabelAnimation=!0,y.get("position")||h.setTextConfig({position:"bottom"}),m.onHoverStateChange=function(_){pd(h,_)}}o.add(h)}}})},e.type="map",e}(ht),R6=k6,j6=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.needsDrawMap=!1,t.seriesGroup=[],t.getTooltipPosition=function(n){if(n!=null){var a=this.getData().getName(n),i=this.coordinateSystem,o=i.getRegion(a);return o&&i.dataToPoint(o.getCenter())}},t}return e.prototype.getInitialData=function(t){for(var n=Su(this,{coordDimensions:["value"],encodeDefaulter:Ae(P1,this)}),a=ge(),i=[],o=0,s=n.count();o<s;o++){var l=n.getName(o);a.set(l,!0)}var u=Si.load(this.getMapType(),this.option.nameMap,this.option.nameProperty);return C(u.regions,function(c){var f=c.name;a.get(f)||i.push(f)}),n.appendValues([],i),n},e.prototype.getHostGeoModel=function(){var t=this.option.geoIndex;return t!=null?this.ecModel.getComponent("geo",t):null},e.prototype.getMapType=function(){return(this.getHostGeoModel()||this).option.map},e.prototype.getRawValue=function(t){var n=this.getData();return n.get(n.mapDimension("value"),t)},e.prototype.getRegionModel=function(t){var n=this.getData();return n.getItemModel(n.indexOfName(t))},e.prototype.formatTooltip=function(t,n,a){for(var i=this.getData(),o=this.getRawValue(t),s=i.getName(t),l=this.seriesGroup,u=[],c=0;c<l.length;c++){var f=l[c].originalData.indexOfName(s),h=i.mapDimension("value");isNaN(l[c].originalData.get(h,f))||u.push(l[c].name)}return lr("section",{header:u.join(", "),noHeader:!u.length,blocks:[lr("nameValue",{name:s,value:o})]})},e.prototype.setZoom=function(t){this.option.zoom=t},e.prototype.setCenter=function(t){this.option.center=t},e.prototype.getLegendIcon=function(t){var n=t.icon||"roundRect",a=Ft(n,0,0,t.itemWidth,t.itemHeight,t.itemStyle.fill);return a.setStyle(t.itemStyle),a.style.stroke="none",n.indexOf("empty")>-1&&(a.style.stroke=a.style.fill,a.style.fill="#fff",a.style.lineWidth=2),a},e.type="series.map",e.dependencies=["geo"],e.layoutMode="box",e.defaultOption={z:2,coordinateSystem:"geo",map:"",left:"center",top:"center",aspectScale:null,showLegendSymbol:!0,boundingCoords:null,center:null,zoom:1,scaleLimit:null,selectedMode:!0,label:{show:!1,color:"#000"},itemStyle:{borderWidth:.5,borderColor:"#444",areaColor:"#eee"},emphasis:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{areaColor:"rgba(255,215,0,0.8)"}},select:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{color:"rgba(255,215,0,0.8)"}},nameProperty:"name"},e}(bt),B6=j6;function F6(r,e){var t={};return C(r,function(n){n.each(n.mapDimension("value"),function(a,i){var o="ec-"+n.getName(i);t[o]=t[o]||[],isNaN(a)||t[o].push(a)})}),r[0].map(r[0].mapDimension("value"),function(n,a){for(var i="ec-"+r[0].getName(a),o=0,s=1/0,l=-1/0,u=t[i].length,c=0;c<u;c++)s=Math.min(s,t[i][c]),l=Math.max(l,t[i][c]),o+=t[i][c];var f;return e==="min"?f=s:e==="max"?f=l:e==="average"?f=o/u:f=o,u===0?NaN:f})}function V6(r){var e={};r.eachSeriesByType("map",function(t){var n=t.getHostGeoModel(),a=n?"o"+n.id:"i"+t.getMapType();(e[a]=e[a]||[]).push(t)}),C(e,function(t,n){for(var a=F6(K(t,function(o){return o.getData()}),t[0].get("mapValueCalculation")),i=0;i<t.length;i++)t[i].originalData=t[i].getData();for(var i=0;i<t.length;i++)t[i].seriesGroup=t,t[i].needsDrawMap=i===0&&!t[i].getHostGeoModel(),t[i].setData(a.cloneShallow()),t[i].mainSeries=t[0]})}function H6(r){var e={};r.eachSeriesByType("map",function(t){var n=t.getMapType();if(!(t.getHostGeoModel()||e[n])){var a={};C(t.seriesGroup,function(o){var s=o.coordinateSystem,l=o.originalData;o.get("showLegendSymbol")&&r.getComponent("legend")&&l.each(l.mapDimension("value"),function(u,c){var f=l.getName(c),h=s.getRegion(f);if(!(!h||isNaN(u))){var v=a[f]||0,d=s.dataToPoint(h.getCenter());a[f]=v+1,l.setItemLayout(c,{point:d,offset:v})}})});var i=t.getData();i.each(function(o){var s=i.getName(o),l=i.getItemLayout(o)||{};l.showLabel=!a[s],i.setItemLayout(o,l)}),e[n]=!0}})}var LO=vr,W6=function(r){U(e,r);function e(t){var n=r.call(this)||this;return n.type="view",n.dimensions=["x","y"],n._roamTransformable=new di,n._rawTransformable=new di,n.name=t,n}return e.prototype.setBoundingRect=function(t,n,a,i){return this._rect=new Pe(t,n,a,i),this._rect},e.prototype.getBoundingRect=function(){return this._rect},e.prototype.setViewRect=function(t,n,a,i){this._transformTo(t,n,a,i),this._viewRect=new Pe(t,n,a,i)},e.prototype._transformTo=function(t,n,a,i){var o=this.getBoundingRect(),s=this._rawTransformable;s.transform=o.calculateTransform(new Pe(t,n,a,i));var l=s.parent;s.parent=null,s.decomposeTransform(),s.parent=l,this._updateTransform()},e.prototype.setCenter=function(t,n){!t||(this._center=[ue(t[0],n.getWidth()),ue(t[1],n.getHeight())],this._updateCenterAndZoom())},e.prototype.setZoom=function(t){t=t||1;var n=this.zoomLimit;n&&(n.max!=null&&(t=Math.min(n.max,t)),n.min!=null&&(t=Math.max(n.min,t))),this._zoom=t,this._updateCenterAndZoom()},e.prototype.getDefaultCenter=function(){var t=this.getBoundingRect(),n=t.x+t.width/2,a=t.y+t.height/2;return[n,a]},e.prototype.getCenter=function(){return this._center||this.getDefaultCenter()},e.prototype.getZoom=function(){return this._zoom||1},e.prototype.getRoamTransform=function(){return this._roamTransformable.getLocalTransform()},e.prototype._updateCenterAndZoom=function(){var t=this._rawTransformable.getLocalTransform(),n=this._roamTransformable,a=this.getDefaultCenter(),i=this.getCenter(),o=this.getZoom();i=vr([],i,t),a=vr([],a,t),n.originX=i[0],n.originY=i[1],n.x=a[0]-i[0],n.y=a[1]-i[1],n.scaleX=n.scaleY=o,this._updateTransform()},e.prototype._updateTransform=function(){var t=this._roamTransformable,n=this._rawTransformable;n.parent=t,t.updateTransform(),n.updateTransform(),Nv(this.transform||(this.transform=[]),n.transform||yn()),this._rawTransform=n.getLocalTransform(),this.invTransform=this.invTransform||[],Qo(this.invTransform,this.transform),this.decomposeTransform()},e.prototype.getTransformInfo=function(){var t=this._rawTransformable,n=this._roamTransformable,a=new di;return a.transform=n.transform,a.decomposeTransform(),{roam:{x:a.x,y:a.y,scaleX:a.scaleX,scaleY:a.scaleY},raw:{x:t.x,y:t.y,scaleX:t.scaleX,scaleY:t.scaleY}}},e.prototype.getViewRect=function(){return this._viewRect},e.prototype.getViewRectAfterRoam=function(){var t=this.getBoundingRect().clone();return t.applyTransform(this.transform),t},e.prototype.dataToPoint=function(t,n,a){var i=n?this._rawTransform:this.transform;return a=a||[],i?LO(a,t,i):Or(a,t)},e.prototype.pointToData=function(t){var n=this.invTransform;return n?LO([],t,n):[t[0],t[1]]},e.prototype.convertToPixel=function(t,n,a){var i=EO(n);return i===this?i.dataToPoint(a):null},e.prototype.convertFromPixel=function(t,n,a){var i=EO(n);return i===this?i.pointToData(a):null},e.prototype.containPoint=function(t){return this.getViewRectAfterRoam().contain(t[0],t[1])},e.dimensions=["x","y"],e}(di);function EO(r){var e=r.seriesModel;return e?e.coordinateSystem:null}var Kf=W6,G6={geoJSON:{aspectScale:.75,invertLongitute:!0},geoSVG:{aspectScale:1,invertLongitute:!1}},OO=["lng","lat"],PO=function(r){U(e,r);function e(t,n,a){var i=r.call(this,t)||this;i.dimensions=OO,i.type="geo",i._nameCoordMap=ge(),i.map=n;var o=a.projection,s=Si.load(n,a.nameMap,a.nameProperty),l=Si.getGeoResource(n);i.resourceType=l?l.type:null;var u=i.regions=s.regions,c=G6[l.type];i._regionsMap=s.regionsMap,i.regions=s.regions,i.projection=o;var f;if(o)for(var h=0;h<u.length;h++){var v=u[h].getBoundingRect(o);f=f||v.clone(),f.union(v)}else f=s.boundingRect;return i.setBoundingRect(f.x,f.y,f.width,f.height),i.aspectScale=o?1:Ee(a.aspectScale,c.aspectScale),i._invertLongitute=o?!1:c.invertLongitute,i}return e.prototype._transformTo=function(t,n,a,i){var o=this.getBoundingRect(),s=this._invertLongitute;o=o.clone(),s&&(o.y=-o.y-o.height);var l=this._rawTransformable;l.transform=o.calculateTransform(new Pe(t,n,a,i));var u=l.parent;l.parent=null,l.decomposeTransform(),l.parent=u,s&&(l.scaleY=-l.scaleY),this._updateTransform()},e.prototype.getRegion=function(t){return this._regionsMap.get(t)},e.prototype.getRegionByCoord=function(t){for(var n=this.regions,a=0;a<n.length;a++){var i=n[a];if(i.type==="geoJSON"&&i.contain(t))return n[a]}},e.prototype.addGeoCoord=function(t,n){this._nameCoordMap.set(t,n)},e.prototype.getGeoCoord=function(t){var n=this._regionsMap.get(t);return this._nameCoordMap.get(t)||n&&n.getCenter()},e.prototype.dataToPoint=function(t,n,a){if(ce(t)&&(t=this.getGeoCoord(t)),t){var i=this.projection;return i&&(t=i.project(t)),t&&this.projectedToPoint(t,n,a)}},e.prototype.pointToData=function(t){var n=this.projection;return n&&(t=n.unproject(t)),t&&this.pointToProjected(t)},e.prototype.pointToProjected=function(t){return r.prototype.pointToData.call(this,t)},e.prototype.projectedToPoint=function(t,n,a){return r.prototype.dataToPoint.call(this,t,n,a)},e.prototype.convertToPixel=function(t,n,a){var i=zO(n);return i===this?i.dataToPoint(a):null},e.prototype.convertFromPixel=function(t,n,a){var i=zO(n);return i===this?i.pointToData(a):null},e}(Kf);Et(PO,Kf);function zO(r){var e=r.geoModel,t=r.seriesModel;return e?e.coordinateSystem:t?t.coordinateSystem||(t.getReferringComponents("geo",Ut).models[0]||{}).coordinateSystem:null}var kO=PO;function RO(r,e){var t=r.get("boundingCoords");if(t!=null){var n=t[0],a=t[1];if(isFinite(n[0])&&isFinite(n[1])&&isFinite(a[0])&&isFinite(a[1])){var i=this.projection;if(i){var o=n[0],s=n[1],l=a[0],u=a[1];n=[1/0,1/0],a=[-1/0,-1/0];var c=function(M,w,D,T){for(var I=D-M,A=T-w,N=0;N<=100;N++){var L=N/100,E=i.project([M+I*L,w+A*L]);ci(n,n,E),fi(a,a,E)}};c(o,s,l,s),c(l,s,l,u),c(l,u,o,u),c(o,u,l,s)}this.setBoundingRect(n[0],n[1],a[0]-n[0],a[1]-n[1])}}var f=this.getBoundingRect(),h=r.get("layoutCenter"),v=r.get("layoutSize"),d=e.getWidth(),p=e.getHeight(),g=f.width/f.height*this.aspectScale,y=!1,m,_;h&&v&&(m=[ue(h[0],d),ue(h[1],p)],_=ue(v,Math.min(d,p)),!isNaN(m[0])&&!isNaN(m[1])&&!isNaN(_)&&(y=!0));var b;if(y)b={},g>1?(b.width=_,b.height=_/g):(b.height=_,b.width=_*g),b.y=m[1]-b.height/2,b.x=m[0]-b.width/2;else{var x=r.getBoxLayoutParams();x.aspect=g,b=Yt(x,{width:d,height:p})}this.setViewRect(b.x,b.y,b.width,b.height),this.setCenter(r.get("center"),e),this.setZoom(r.get("zoom"))}function $6(r,e){C(e.get("geoCoord"),function(t,n){r.addGeoCoord(n,t)})}var U6=function(){function r(){this.dimensions=OO}return r.prototype.create=function(e,t){var n=[];function a(o){return{nameProperty:o.get("nameProperty"),aspectScale:o.get("aspectScale"),projection:o.get("projection")}}e.eachComponent("geo",function(o,s){var l=o.get("map"),u=new kO(l+s,l,X({nameMap:o.get("nameMap")},a(o)));u.zoomLimit=o.get("scaleLimit"),n.push(u),o.coordinateSystem=u,u.model=o,u.resize=RO,u.resize(o,t)}),e.eachSeries(function(o){var s=o.get("coordinateSystem");if(s==="geo"){var l=o.get("geoIndex")||0;o.coordinateSystem=n[l]}});var i={};return e.eachSeriesByType("map",function(o){if(!o.getHostGeoModel()){var s=o.getMapType();i[s]=i[s]||[],i[s].push(o)}}),C(i,function(o,s){var l=K(o,function(c){return c.get("nameMap")}),u=new kO(s,s,X({nameMap:Dv(l)},a(o[0])));u.zoomLimit=ar.apply(null,K(o,function(c){return c.get("scaleLimit")})),n.push(u),u.resize=RO,u.resize(o[0],t),C(o,function(c){c.coordinateSystem=u,$6(u,c)})}),n},r.prototype.getFilledRegions=function(e,t,n,a){for(var i=(e||[]).slice(),o=ge(),s=0;s<i.length;s++)o.set(i[s].name,i[s]);var l=Si.load(t,n,a);return C(l.regions,function(u){var c=u.name;!o.get(c)&&i.push({name:c})}),i},r}(),Y6=new U6,jO=Y6,Q6=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,n,a){var i=Si.getGeoResource(t.map);if(i&&i.type==="geoJSON"){var o=t.itemStyle=t.itemStyle||{};"color"in o||(o.color="#eee")}this.mergeDefaultAndTheme(t,a),ns(t,"label",["show"])},e.prototype.optionUpdated=function(){var t=this,n=this.option;n.regions=jO.getFilledRegions(n.regions,n.map,n.nameMap,n.nameProperty);var a={};this._optionModelMap=On(n.regions||[],function(i,o){var s=o.name;return s&&(i.set(s,new ft(o,t,t.ecModel)),o.selected&&(a[s]=!0)),i},ge()),n.selectedMap||(n.selectedMap=a)},e.prototype.getRegionModel=function(t){return this._optionModelMap.get(t)||new ft(null,this,this.ecModel)},e.prototype.getFormattedLabel=function(t,n){var a=this.getRegionModel(t),i=n==="normal"?a.get(["label","formatter"]):a.get(["emphasis","label","formatter"]),o={name:t};if(ye(i))return o.status=n,i(o);if(ce(i))return i.replace("{a}",t!=null?t:"")},e.prototype.setZoom=function(t){this.option.zoom=t},e.prototype.setCenter=function(t){this.option.center=t},e.prototype.select=function(t){var n=this.option,a=n.selectedMode;if(!!a){a!=="multiple"&&(n.selectedMap=null);var i=n.selectedMap||(n.selectedMap={});i[t]=!0}},e.prototype.unSelect=function(t){var n=this.option.selectedMap;n&&(n[t]=!1)},e.prototype.toggleSelected=function(t){this[this.isSelected(t)?"unSelect":"select"](t)},e.prototype.isSelected=function(t){var n=this.option.selectedMap;return!!(n&&n[t])},e.type="geo",e.layoutMode="box",e.defaultOption={z:0,show:!0,left:"center",top:"center",aspectScale:null,silent:!1,map:"",boundingCoords:null,center:null,zoom:1,scaleLimit:null,label:{show:!1,color:"#000"},itemStyle:{borderWidth:.5,borderColor:"#444"},emphasis:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{color:"rgba(255,215,0,0.8)"}},select:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{color:"rgba(255,215,0,0.8)"}},regions:[]},e}(He),Z6=Q6;function BO(r,e){return r.pointToProjected?r.pointToProjected(e):r.pointToData(e)}function Lb(r,e,t,n){var a=r.getZoom(),i=r.getCenter(),o=e.zoom,s=r.projectedToPoint?r.projectedToPoint(i):r.dataToPoint(i);if(e.dx!=null&&e.dy!=null&&(s[0]-=e.dx,s[1]-=e.dy,r.setCenter(BO(r,s),n)),o!=null){if(t){var l=t.min||0,u=t.max||1/0;o=Math.max(Math.min(a*o,u),l)/a}r.scaleX*=o,r.scaleY*=o;var c=(e.originX-r.x)*(o-1),f=(e.originY-r.y)*(o-1);r.x-=c,r.y-=f,r.updateTransform(),r.setCenter(BO(r,s),n),r.setZoom(o*a)}return{center:r.getCenter(),zoom:r.getZoom()}}var q6=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.focusBlurEnabled=!0,t}return e.prototype.init=function(t,n){this._api=n},e.prototype.render=function(t,n,a,i){if(this._model=t,!t.get("show")){this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null;return}this._mapDraw||(this._mapDraw=new NO(a));var o=this._mapDraw;o.draw(t,n,a,this,i),o.group.on("click",this._handleRegionClick,this),o.group.silent=t.get("silent"),this.group.add(o.group),this.updateSelectStatus(t,n,a)},e.prototype._handleRegionClick=function(t){var n;Cs(t.target,function(a){return(n=Te(a).eventData)!=null},!0),n&&this._api.dispatchAction({type:"geoToggleSelect",geoId:this._model.id,name:n.name})},e.prototype.updateSelectStatus=function(t,n,a){var i=this;this._mapDraw.group.traverse(function(o){var s=Te(o).eventData;if(s)return i._model.isSelected(s.name)?a.enterSelect(o):a.leaveSelect(o),!0})},e.prototype.findHighDownDispatchers=function(t){return this._mapDraw&&this._mapDraw.findHighDownDispatchers(t,this._model)},e.prototype.dispose=function(){this._mapDraw&&this._mapDraw.remove()},e.type="geo",e}(St),X6=q6;function J6(r,e,t){Si.registerMap(r,e,t)}function FO(r){r.registerCoordinateSystem("geo",jO),r.registerComponentModel(Z6),r.registerComponentView(X6),r.registerImpl("registerMap",J6),r.registerImpl("getMap",function(t){return Si.getMapForUser(t)});function e(t,n){n.update="geo:updateSelectStatus",r.registerAction(n,function(a,i){var o={},s=[];return i.eachComponent({mainType:"geo",query:a},function(l){l[t](a.name);var u=l.coordinateSystem;C(u.regions,function(f){o[f.name]=l.isSelected(f.name)||!1});var c=[];C(o,function(f,h){o[h]&&c.push(h)}),s.push({geoIndex:l.componentIndex,name:c})}),{selected:o,allSelected:s,name:a.name}})}e("toggleSelected",{type:"geoToggleSelect",event:"geoselectchanged"}),e("select",{type:"geoSelect",event:"geoselected"}),e("unSelect",{type:"geoUnSelect",event:"geounselected"}),r.registerAction({type:"geoRoam",event:"geoRoam",update:"updateTransform"},function(t,n,a){var i=t.componentType||"series";n.eachComponent({mainType:i,query:t},function(o){var s=o.coordinateSystem;if(s.type==="geo"){var l=Lb(s,t,o.get("scaleLimit"),a);o.setCenter&&o.setCenter(l.center),o.setZoom&&o.setZoom(l.zoom),i==="series"&&C(o.seriesGroup,function(u){u.setCenter(l.center),u.setZoom(l.zoom)})}})})}function K6(r){Re(FO),r.registerChartView(R6),r.registerSeriesModel(B6),r.registerLayout(H6),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,V6),jN("map",r.registerAction)}function eq(r){var e=r;e.hierNode={defaultAncestor:null,ancestor:e,prelim:0,modifier:0,change:0,shift:0,i:0,thread:null};for(var t=[e],n,a;n=t.pop();)if(a=n.children,n.isExpand&&a.length)for(var i=a.length,o=i-1;o>=0;o--){var s=a[o];s.hierNode={defaultAncestor:null,ancestor:s,prelim:0,modifier:0,change:0,shift:0,i:o,thread:null},t.push(s)}}function tq(r,e){var t=r.isExpand?r.children:[],n=r.parentNode.children,a=r.hierNode.i?n[r.hierNode.i-1]:null;if(t.length){aq(r);var i=(t[0].hierNode.prelim+t[t.length-1].hierNode.prelim)/2;a?(r.hierNode.prelim=a.hierNode.prelim+e(r,a),r.hierNode.modifier=r.hierNode.prelim-i):r.hierNode.prelim=i}else a&&(r.hierNode.prelim=a.hierNode.prelim+e(r,a));r.parentNode.hierNode.defaultAncestor=iq(r,a,r.parentNode.hierNode.defaultAncestor||n[0],e)}function rq(r){var e=r.hierNode.prelim+r.parentNode.hierNode.modifier;r.setLayout({x:e},!0),r.hierNode.modifier+=r.parentNode.hierNode.modifier}function VO(r){return arguments.length?r:lq}function eh(r,e){return r-=Math.PI/2,{x:e*Math.cos(r),y:e*Math.sin(r)}}function nq(r,e){return Yt(r.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}function aq(r){for(var e=r.children,t=e.length,n=0,a=0;--t>=0;){var i=e[t];i.hierNode.prelim+=n,i.hierNode.modifier+=n,a+=i.hierNode.change,n+=i.hierNode.shift+a}}function iq(r,e,t,n){if(e){for(var a=r,i=r,o=i.parentNode.children[0],s=e,l=a.hierNode.modifier,u=i.hierNode.modifier,c=o.hierNode.modifier,f=s.hierNode.modifier;s=Eb(s),i=Ob(i),s&&i;){a=Eb(a),o=Ob(o),a.hierNode.ancestor=r;var h=s.hierNode.prelim+f-i.hierNode.prelim-u+n(s,i);h>0&&(sq(oq(s,r,t),r,h),u+=h,l+=h),f+=s.hierNode.modifier,u+=i.hierNode.modifier,l+=a.hierNode.modifier,c+=o.hierNode.modifier}s&&!Eb(a)&&(a.hierNode.thread=s,a.hierNode.modifier+=f-l),i&&!Ob(o)&&(o.hierNode.thread=i,o.hierNode.modifier+=u-c,t=r)}return t}function Eb(r){var e=r.children;return e.length&&r.isExpand?e[e.length-1]:r.hierNode.thread}function Ob(r){var e=r.children;return e.length&&r.isExpand?e[0]:r.hierNode.thread}function oq(r,e,t){return r.hierNode.ancestor.parentNode===e.parentNode?r.hierNode.ancestor:t}function sq(r,e,t){var n=t/(e.hierNode.i-r.hierNode.i);e.hierNode.change-=n,e.hierNode.shift+=t,e.hierNode.modifier+=t,e.hierNode.prelim+=t,r.hierNode.change+=n}function lq(r,e){return r.parentNode===e.parentNode?1:2}var uq=function(){function r(){this.parentPoint=[],this.childPoints=[]}return r}(),cq=function(r){U(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new uq},e.prototype.buildPath=function(t,n){var a=n.childPoints,i=a.length,o=n.parentPoint,s=a[0],l=a[i-1];if(i===1){t.moveTo(o[0],o[1]),t.lineTo(s[0],s[1]);return}var u=n.orient,c=u==="TB"||u==="BT"?0:1,f=1-c,h=ue(n.forkPosition,1),v=[];v[c]=o[c],v[f]=o[f]+(l[f]-o[f])*h,t.moveTo(o[0],o[1]),t.lineTo(v[0],v[1]),t.moveTo(s[0],s[1]),v[c]=s[c],t.lineTo(v[0],v[1]),v[c]=l[c],t.lineTo(v[0],v[1]),t.lineTo(l[0],l[1]);for(var d=1;d<i-1;d++){var p=a[d];t.moveTo(p[0],p[1]),v[c]=p[c],t.lineTo(v[0],v[1])}},e}(je),fq=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._mainGroup=new De,t}return e.prototype.init=function(t,n){this._controller=new Xf(n.getZr()),this._controllerHost={target:this.group},this.group.add(this._mainGroup)},e.prototype.render=function(t,n,a){var i=t.getData(),o=t.layoutInfo,s=this._mainGroup,l=t.get("layout");l==="radial"?(s.x=o.x+o.width/2,s.y=o.y+o.height/2):(s.x=o.x,s.y=o.y),this._updateViewCoordSys(t,a),this._updateController(t,n,a);var u=this._data;i.diff(u).add(function(c){HO(i,c)&&WO(i,c,null,s,t)}).update(function(c,f){var h=u.getItemGraphicEl(f);if(!HO(i,c)){h&&UO(u,f,h,s,t);return}WO(i,c,h,s,t)}).remove(function(c){var f=u.getItemGraphicEl(c);f&&UO(u,c,f,s,t)}).execute(),this._nodeScaleRatio=t.get("nodeScaleRatio"),this._updateNodeAndLinkScale(t),t.get("expandAndCollapse")===!0&&i.eachItemGraphicEl(function(c,f){c.off("click").on("click",function(){a.dispatchAction({type:"treeExpandAndCollapse",seriesId:t.id,dataIndex:f})})}),this._data=i},e.prototype._updateViewCoordSys=function(t,n){var a=t.getData(),i=[];a.each(function(f){var h=a.getItemLayout(f);h&&!isNaN(h.x)&&!isNaN(h.y)&&i.push([+h.x,+h.y])});var o=[],s=[];ud(i,o,s);var l=this._min,u=this._max;s[0]-o[0]===0&&(o[0]=l?l[0]:o[0]-1,s[0]=u?u[0]:s[0]+1),s[1]-o[1]===0&&(o[1]=l?l[1]:o[1]-1,s[1]=u?u[1]:s[1]+1);var c=t.coordinateSystem=new Kf;c.zoomLimit=t.get("scaleLimit"),c.setBoundingRect(o[0],o[1],s[0]-o[0],s[1]-o[1]),c.setCenter(t.get("center"),n),c.setZoom(t.get("zoom")),this.group.attr({x:c.x,y:c.y,scaleX:c.scaleX,scaleY:c.scaleY}),this._min=o,this._max=s},e.prototype._updateController=function(t,n,a){var i=this,o=this._controller,s=this._controllerHost,l=this.group;o.setPointerChecker(function(u,c,f){var h=l.getBoundingRect();return h.applyTransform(l.transform),h.contain(c,f)&&!Fp(u,a,t)}),o.enable(t.get("roam")),s.zoomLimit=t.get("scaleLimit"),s.zoom=t.coordinateSystem.getZoom(),o.off("pan").off("zoom").on("pan",function(u){Sb(s,u.dx,u.dy),a.dispatchAction({seriesId:t.id,type:"treeRoam",dx:u.dx,dy:u.dy})}).on("zoom",function(u){Ib(s,u.scale,u.originX,u.originY),a.dispatchAction({seriesId:t.id,type:"treeRoam",zoom:u.scale,originX:u.originX,originY:u.originY}),i._updateNodeAndLinkScale(t),a.updateLabelLayout()})},e.prototype._updateNodeAndLinkScale=function(t){var n=t.getData(),a=this._getNodeGlobalScale(t);n.eachItemGraphicEl(function(i,o){i.setSymbolScale(a)})},e.prototype._getNodeGlobalScale=function(t){var n=t.coordinateSystem;if(n.type!=="view")return 1;var a=this._nodeScaleRatio,i=n.scaleX||1,o=n.getZoom(),s=(o-1)*a+1;return s/i},e.prototype.dispose=function(){this._controller&&this._controller.dispose(),this._controllerHost=null},e.prototype.remove=function(){this._mainGroup.removeAll(),this._data=null},e.type="tree",e}(ht);function HO(r,e){var t=r.getItemLayout(e);return t&&!isNaN(t.x)&&!isNaN(t.y)}function WO(r,e,t,n,a){var i=!t,o=r.tree.getNodeByDataIndex(e),s=o.getModel(),l=o.getVisual("style").fill,u=o.isExpand===!1&&o.children.length!==0?l:"#fff",c=r.tree.root,f=o.parentNode===c?o:o.parentNode||o,h=r.getItemGraphicEl(f.dataIndex),v=f.getLayout(),d=h?{x:h.__oldX,y:h.__oldY,rawX:h.__radialOldRawX,rawY:h.__radialOldRawY}:v,p=o.getLayout();i?(t=new Gf(r,e,null,{symbolInnerColor:u,useNameLabel:!0}),t.x=d.x,t.y=d.y):t.updateData(r,e,null,{symbolInnerColor:u,useNameLabel:!0}),t.__radialOldRawX=t.__radialRawX,t.__radialOldRawY=t.__radialRawY,t.__radialRawX=p.rawX,t.__radialRawY=p.rawY,n.add(t),r.setItemGraphicEl(e,t),t.__oldX=t.x,t.__oldY=t.y,Qe(t,{x:p.x,y:p.y},a);var g=t.getSymbolPath();if(a.get("layout")==="radial"){var y=c.children[0],m=y.getLayout(),_=y.children.length,b=void 0,x=void 0;if(p.x===m.x&&o.isExpand===!0&&y.children.length){var M={x:(y.children[0].getLayout().x+y.children[_-1].getLayout().x)/2,y:(y.children[0].getLayout().y+y.children[_-1].getLayout().y)/2};b=Math.atan2(M.y-m.y,M.x-m.x),b<0&&(b=Math.PI*2+b),x=M.x<m.x,x&&(b=b-Math.PI)}else b=Math.atan2(p.y-m.y,p.x-m.x),b<0&&(b=Math.PI*2+b),o.children.length===0||o.children.length!==0&&o.isExpand===!1?(x=p.x<m.x,x&&(b=b-Math.PI)):(x=p.x>m.x,x||(b=b-Math.PI));var w=x?"left":"right",D=s.getModel("label"),T=D.get("rotate"),I=T*(Math.PI/180),A=g.getTextContent();A&&(g.setTextConfig({position:D.get("position")||w,rotation:T==null?-b:I,origin:"center"}),A.setStyle("verticalAlign","middle"))}var N=s.get(["emphasis","focus"]),L=N==="relative"?gc(o.getAncestorsIndices(),o.getDescendantIndices()):N==="ancestor"?o.getAncestorsIndices():N==="descendant"?o.getDescendantIndices():null;L&&(Te(t).focus=L),hq(a,o,c,t,d,v,p,n),t.__edge&&(t.onHoverStateChange=function(E){if(E!=="blur"){var O=o.parentNode&&r.getItemGraphicEl(o.parentNode.dataIndex);O&&O.hoverState===Qc||pd(t.__edge,E)}})}function hq(r,e,t,n,a,i,o,s){var l=e.getModel(),u=r.get("edgeShape"),c=r.get("layout"),f=r.getOrient(),h=r.get(["lineStyle","curveness"]),v=r.get("edgeForkPosition"),d=l.getModel("lineStyle").getLineStyle(),p=n.__edge;if(u==="curve")e.parentNode&&e.parentNode!==t&&(p||(p=n.__edge=new nf({shape:Pb(c,f,h,a,a)})),Qe(p,{shape:Pb(c,f,h,i,o)},r));else if(u==="polyline"&&c==="orthogonal"&&e!==t&&e.children&&e.children.length!==0&&e.isExpand===!0){for(var g=e.children,y=[],m=0;m<g.length;m++){var _=g[m].getLayout();y.push([_.x,_.y])}p||(p=n.__edge=new cq({shape:{parentPoint:[o.x,o.y],childPoints:[[o.x,o.y]],orient:f,forkPosition:v}})),Qe(p,{shape:{parentPoint:[o.x,o.y],childPoints:y}},r)}p&&!(u==="polyline"&&!e.isExpand)&&(p.useStyle(me({strokeNoScale:!0,fill:null},d)),xr(p,l,"lineStyle"),gs(p),s.add(p))}function GO(r,e,t,n,a){var i=e.tree.root,o=$O(i,r),s=o.source,l=o.sourceLayout,u=e.getItemGraphicEl(r.dataIndex);if(!!u){var c=e.getItemGraphicEl(s.dataIndex),f=c.__edge,h=u.__edge||(s.isExpand===!1||s.children.length===1?f:void 0),v=n.get("edgeShape"),d=n.get("layout"),p=n.get("orient"),g=n.get(["lineStyle","curveness"]);h&&(v==="curve"?so(h,{shape:Pb(d,p,g,l,l),style:{opacity:0}},n,{cb:function(){t.remove(h)},removeOpt:a}):v==="polyline"&&n.get("layout")==="orthogonal"&&so(h,{shape:{parentPoint:[l.x,l.y],childPoints:[[l.x,l.y]]},style:{opacity:0}},n,{cb:function(){t.remove(h)},removeOpt:a}))}}function $O(r,e){for(var t=e.parentNode===r?e:e.parentNode||e,n;n=t.getLayout(),n==null;)t=t.parentNode===r?t:t.parentNode||t;return{source:t,sourceLayout:n}}function UO(r,e,t,n,a){var i=r.tree.getNodeByDataIndex(e),o=r.tree.root,s=$O(o,i).sourceLayout,l={duration:a.get("animationDurationUpdate"),easing:a.get("animationEasingUpdate")};so(t,{x:s.x+1,y:s.y+1},a,{cb:function(){n.remove(t),r.setItemGraphicEl(e,null)},removeOpt:l}),t.fadeOut(null,r.hostModel,{fadeLabel:!0,animation:l}),i.children.forEach(function(u){GO(u,r,n,a,l)}),GO(i,r,n,a,l)}function Pb(r,e,t,n,a){var i,o,s,l,u,c,f,h;if(r==="radial"){u=n.rawX,f=n.rawY,c=a.rawX,h=a.rawY;var v=eh(u,f),d=eh(u,f+(h-f)*t),p=eh(c,h+(f-h)*t),g=eh(c,h);return{x1:v.x||0,y1:v.y||0,x2:g.x||0,y2:g.y||0,cpx1:d.x||0,cpy1:d.y||0,cpx2:p.x||0,cpy2:p.y||0}}else u=n.x,f=n.y,c=a.x,h=a.y,(e==="LR"||e==="RL")&&(i=u+(c-u)*t,o=f,s=c+(u-c)*t,l=h),(e==="TB"||e==="BT")&&(i=u,o=f+(h-f)*t,s=c,l=h+(f-h)*t);return{x1:u,y1:f,x2:c,y2:h,cpx1:i,cpy1:o,cpx2:s,cpy2:l}}var vq=fq,qn=Ye();function YO(r){var e=r.mainData,t=r.datas;t||(t={main:e},r.datasAttr={main:"data"}),r.datas=r.mainData=null,QO(e,t,r),C(t,function(n){C(e.TRANSFERABLE_METHODS,function(a){n.wrapMethod(a,Ae(dq,r))})}),e.wrapMethod("cloneShallow",Ae(gq,r)),C(e.CHANGABLE_METHODS,function(n){e.wrapMethod(n,Ae(pq,r))}),Er(t[e.dataType]===e)}function dq(r,e){if(_q(this)){var t=X({},qn(this).datas);t[this.dataType]=e,QO(e,t,r)}else zb(e,this.dataType,qn(this).mainData,r);return e}function pq(r,e){return r.struct&&r.struct.update(),e}function gq(r,e){return C(qn(e).datas,function(t,n){t!==e&&zb(t.cloneShallow(),n,e,r)}),e}function yq(r){var e=qn(this).mainData;return r==null||e==null?e:qn(e).datas[r]}function mq(){var r=qn(this).mainData;return r==null?[{data:r}]:K(Fe(qn(r).datas),function(e){return{type:e,data:qn(r).datas[e]}})}function _q(r){return qn(r).mainData===r}function QO(r,e,t){qn(r).datas={},C(e,function(n,a){zb(n,a,r,t)})}function zb(r,e,t,n){qn(t).datas[e]=r,qn(r).mainData=t,r.dataType=e,n.struct&&(r[n.structAttr]=n.struct,n.struct[n.datasAttr[e]]=r),r.getLinkedData=yq,r.getLinkedDataAll=mq}var bq=function(){function r(e,t){this.depth=0,this.height=0,this.dataIndex=-1,this.children=[],this.viewChildren=[],this.isExpand=!1,this.name=e||"",this.hostTree=t}return r.prototype.isRemoved=function(){return this.dataIndex<0},r.prototype.eachNode=function(e,t,n){ye(e)&&(n=t,t=e,e=null),e=e||{},ce(e)&&(e={order:e});var a=e.order||"preorder",i=this[e.attr||"children"],o;a==="preorder"&&(o=t.call(n,this));for(var s=0;!o&&s<i.length;s++)i[s].eachNode(e,t,n);a==="postorder"&&t.call(n,this)},r.prototype.updateDepthAndHeight=function(e){var t=0;this.depth=e;for(var n=0;n<this.children.length;n++){var a=this.children[n];a.updateDepthAndHeight(e+1),a.height>t&&(t=a.height)}this.height=t+1},r.prototype.getNodeById=function(e){if(this.getId()===e)return this;for(var t=0,n=this.children,a=n.length;t<a;t++){var i=n[t].getNodeById(e);if(i)return i}},r.prototype.contains=function(e){if(e===this)return!0;for(var t=0,n=this.children,a=n.length;t<a;t++){var i=n[t].contains(e);if(i)return i}},r.prototype.getAncestors=function(e){for(var t=[],n=e?this:this.parentNode;n;)t.push(n),n=n.parentNode;return t.reverse(),t},r.prototype.getAncestorsIndices=function(){for(var e=[],t=this;t;)e.push(t.dataIndex),t=t.parentNode;return e.reverse(),e},r.prototype.getDescendantIndices=function(){var e=[];return this.eachNode(function(t){e.push(t.dataIndex)}),e},r.prototype.getValue=function(e){var t=this.hostTree.data;return t.getStore().get(t.getDimensionIndex(e||"value"),this.dataIndex)},r.prototype.setLayout=function(e,t){this.dataIndex>=0&&this.hostTree.data.setItemLayout(this.dataIndex,e,t)},r.prototype.getLayout=function(){return this.hostTree.data.getItemLayout(this.dataIndex)},r.prototype.getModel=function(e){if(!(this.dataIndex<0)){var t=this.hostTree,n=t.data.getItemModel(this.dataIndex);return n.getModel(e)}},r.prototype.getLevelModel=function(){return(this.hostTree.levelModels||[])[this.depth]},r.prototype.setVisual=function(e,t){this.dataIndex>=0&&this.hostTree.data.setItemVisual(this.dataIndex,e,t)},r.prototype.getVisual=function(e){return this.hostTree.data.getItemVisual(this.dataIndex,e)},r.prototype.getRawIndex=function(){return this.hostTree.data.getRawIndex(this.dataIndex)},r.prototype.getId=function(){return this.hostTree.data.getId(this.dataIndex)},r.prototype.getChildIndex=function(){if(this.parentNode){for(var e=this.parentNode.children,t=0;t<e.length;++t)if(e[t]===this)return t;return-1}return-1},r.prototype.isAncestorOf=function(e){for(var t=e.parentNode;t;){if(t===this)return!0;t=t.parentNode}return!1},r.prototype.isDescendantOf=function(e){return e!==this&&e.isAncestorOf(this)},r}(),Mq=function(){function r(e){this.type="tree",this._nodes=[],this.hostModel=e}return r.prototype.eachNode=function(e,t,n){this.root.eachNode(e,t,n)},r.prototype.getNodeByDataIndex=function(e){var t=this.data.getRawIndex(e);return this._nodes[t]},r.prototype.getNodeById=function(e){return this.root.getNodeById(e)},r.prototype.update=function(){for(var e=this.data,t=this._nodes,n=0,a=t.length;n<a;n++)t[n].dataIndex=-1;for(var n=0,a=e.count();n<a;n++)t[e.getRawIndex(n)].dataIndex=n},r.prototype.clearLayouts=function(){this.data.clearItemLayouts()},r.createTree=function(e,t,n){var a=new r(t),i=[],o=1;s(e);function s(c,f){var h=c.value;o=Math.max(o,J(h)?h.length:1),i.push(c);var v=new bq(Kt(c.name,""),a);f?xq(v,f):a.root=v,a._nodes.push(v);var d=c.children;if(d)for(var p=0;p<d.length;p++)s(d[p],v)}a.root.updateDepthAndHeight(0);var l=_u(i,{coordDimensions:["value"],dimensionsCount:o}).dimensions,u=new jr(l,t);return u.initData(i),n&&n(u),YO({mainData:u,struct:a,structAttr:"tree"}),a.update(),a},r}();function xq(r,e){var t=e.children;r.parentNode!==e&&(t.push(r),r.parentNode=e)}var kb=Mq;function th(r,e,t){if(r&&ze(e,r.type)>=0){var n=t.getData().tree.root,a=r.targetNode;if(ce(a)&&(a=n.getNodeById(a)),a&&n.contains(a))return{node:a};var i=r.targetNodeId;if(i!=null&&(a=n.getNodeById(i)))return{node:a}}}function ZO(r){for(var e=[];r;)r=r.parentNode,r&&e.push(r);return e.reverse()}function Rb(r,e){var t=ZO(r);return ze(t,e)>=0}function $p(r,e){for(var t=[];r;){var n=r.dataIndex;t.push({name:r.name,dataIndex:n,value:e.getRawValue(n)}),r=r.parentNode}return t.reverse(),t}var wq=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.hasSymbolVisual=!0,t.ignoreStyleOnData=!0,t}return e.prototype.getInitialData=function(t){var n={name:t.name,children:t.data},a=t.leaves||{},i=new ft(a,this,this.ecModel),o=kb.createTree(n,this,s);function s(f){f.wrapMethod("getItemModel",function(h,v){var d=o.getNodeByDataIndex(v);return d&&d.children.length&&d.isExpand||(h.parentModel=i),h})}var l=0;o.eachNode("preorder",function(f){f.depth>l&&(l=f.depth)});var u=t.expandAndCollapse,c=u&&t.initialTreeDepth>=0?t.initialTreeDepth:l;return o.root.eachNode("preorder",function(f){var h=f.hostTree.data.getRawDataItem(f.dataIndex);f.isExpand=h&&h.collapsed!=null?!h.collapsed:f.depth<=c}),o.data},e.prototype.getOrient=function(){var t=this.get("orient");return t==="horizontal"?t="LR":t==="vertical"&&(t="TB"),t},e.prototype.setZoom=function(t){this.option.zoom=t},e.prototype.setCenter=function(t){this.option.center=t},e.prototype.formatTooltip=function(t,n,a){for(var i=this.getData().tree,o=i.root.children[0],s=i.getNodeByDataIndex(t),l=s.getValue(),u=s.name;s&&s!==o;)u=s.parentNode.name+"."+u,s=s.parentNode;return lr("nameValue",{name:u,value:l,noValue:isNaN(l)||l==null})},e.prototype.getDataParams=function(t){var n=r.prototype.getDataParams.apply(this,arguments),a=this.getData().tree.getNodeByDataIndex(t);return n.treeAncestors=$p(a,this),n.collapsed=!a.isExpand,n},e.type="series.tree",e.layoutMode="box",e.defaultOption={z:2,coordinateSystem:"view",left:"12%",top:"12%",right:"12%",bottom:"12%",layout:"orthogonal",edgeShape:"curve",edgeForkPosition:"50%",roam:!1,nodeScaleRatio:.4,center:null,zoom:1,orient:"LR",symbol:"emptyCircle",symbolSize:7,expandAndCollapse:!0,initialTreeDepth:2,lineStyle:{color:"#ccc",width:1.5,curveness:.5},itemStyle:{color:"lightsteelblue",borderWidth:1.5},label:{show:!0},animationEasing:"linear",animationDuration:700,animationDurationUpdate:500},e}(bt),Dq=wq;function Sq(r,e,t){for(var n=[r],a=[],i;i=n.pop();)if(a.push(i),i.isExpand){var o=i.children;if(o.length)for(var s=0;s<o.length;s++)n.push(o[s])}for(;i=a.pop();)e(i,t)}function rh(r,e){for(var t=[r],n;n=t.pop();)if(e(n),n.isExpand){var a=n.children;if(a.length)for(var i=a.length-1;i>=0;i--)t.push(a[i])}}function Iq(r,e){r.eachSeriesByType("tree",function(t){Tq(t,e)})}function Tq(r,e){var t=nq(r,e);r.layoutInfo=t;var n=r.get("layout"),a=0,i=0,o=null;n==="radial"?(a=2*Math.PI,i=Math.min(t.height,t.width)/2,o=VO(function(_,b){return(_.parentNode===b.parentNode?1:2)/_.depth})):(a=t.width,i=t.height,o=VO());var s=r.getData().tree.root,l=s.children[0];if(l){eq(s),Sq(l,tq,o),s.hierNode.modifier=-l.hierNode.prelim,rh(l,rq);var u=l,c=l,f=l;rh(l,function(_){var b=_.getLayout().x;b<u.getLayout().x&&(u=_),b>c.getLayout().x&&(c=_),_.depth>f.depth&&(f=_)});var h=u===c?1:o(u,c)/2,v=h-u.getLayout().x,d=0,p=0,g=0,y=0;if(n==="radial")d=a/(c.getLayout().x+h+v),p=i/(f.depth-1||1),rh(l,function(_){g=(_.getLayout().x+v)*d,y=(_.depth-1)*p;var b=eh(g,y);_.setLayout({x:b.x,y:b.y,rawX:g,rawY:y},!0)});else{var m=r.getOrient();m==="RL"||m==="LR"?(p=i/(c.getLayout().x+h+v),d=a/(f.depth-1||1),rh(l,function(_){y=(_.getLayout().x+v)*p,g=m==="LR"?(_.depth-1)*d:a-(_.depth-1)*d,_.setLayout({x:g,y},!0)})):(m==="TB"||m==="BT")&&(d=a/(c.getLayout().x+h+v),p=i/(f.depth-1||1),rh(l,function(_){g=(_.getLayout().x+v)*d,y=m==="TB"?(_.depth-1)*p:i-(_.depth-1)*p,_.setLayout({x:g,y},!0)}))}}}function Aq(r){r.eachSeriesByType("tree",function(e){var t=e.getData(),n=t.tree;n.eachNode(function(a){var i=a.getModel(),o=i.getModel("itemStyle").getItemStyle(),s=t.ensureUniqueItemVisual(a.dataIndex,"style");X(s,o)})})}function Cq(r){r.registerAction({type:"treeExpandAndCollapse",event:"treeExpandAndCollapse",update:"update"},function(e,t){t.eachComponent({mainType:"series",subType:"tree",query:e},function(n){var a=e.dataIndex,i=n.getData().tree,o=i.getNodeByDataIndex(a);o.isExpand=!o.isExpand})}),r.registerAction({type:"treeRoam",event:"treeRoam",update:"none"},function(e,t,n){t.eachComponent({mainType:"series",subType:"tree",query:e},function(a){var i=a.coordinateSystem,o=Lb(i,e,void 0,n);a.setCenter&&a.setCenter(o.center),a.setZoom&&a.setZoom(o.zoom)})})}function Nq(r){r.registerChartView(vq),r.registerSeriesModel(Dq),r.registerLayout(Iq),r.registerVisual(Aq),Cq(r)}var qO=["treemapZoomToNode","treemapRender","treemapMove"];function Lq(r){for(var e=0;e<qO.length;e++)r.registerAction({type:qO[e],update:"updateView"},Ot);r.registerAction({type:"treemapRootToNode",update:"updateView"},function(t,n){n.eachComponent({mainType:"series",subType:"treemap",query:t},a);function a(i,o){var s=["treemapZoomToNode","treemapRootToNode"],l=th(t,s,i);if(l){var u=i.getViewRoot();u&&(t.direction=Rb(u,l.node)?"rollUp":"drillDown"),i.resetViewRoot(l.node)}}})}function XO(r){var e=r.getData(),t=e.tree,n={};t.eachNode(function(a){for(var i=a;i&&i.depth>1;)i=i.parentNode;var o=j1(r.ecModel,i.name||i.dataIndex+"",n);a.setVisual("decal",o)})}var Eq=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.preventUsingHoverLayer=!0,t}return e.prototype.getInitialData=function(t,n){var a={name:t.name,children:t.data};JO(a);var i=t.levels||[],o=this.designatedVisualItemStyle={},s=new ft({itemStyle:o},this,n);i=t.levels=Oq(i,n);var l=K(i||[],function(f){return new ft(f,s,n)},this),u=kb.createTree(a,this,c);function c(f){f.wrapMethod("getItemModel",function(h,v){var d=u.getNodeByDataIndex(v),p=d?l[d.depth]:null;return h.parentModel=p||s,h})}return u.data},e.prototype.optionUpdated=function(){this.resetViewRoot()},e.prototype.formatTooltip=function(t,n,a){var i=this.getData(),o=this.getRawValue(t),s=i.getName(t);return lr("nameValue",{name:s,value:o})},e.prototype.getDataParams=function(t){var n=r.prototype.getDataParams.apply(this,arguments),a=this.getData().tree.getNodeByDataIndex(t);return n.treeAncestors=$p(a,this),n.treePathInfo=n.treeAncestors,n},e.prototype.setLayoutInfo=function(t){this.layoutInfo=this.layoutInfo||{},X(this.layoutInfo,t)},e.prototype.mapIdToIndex=function(t){var n=this._idIndexMap;n||(n=this._idIndexMap=ge(),this._idIndexMapCount=0);var a=n.get(t);return a==null&&n.set(t,a=this._idIndexMapCount++),a},e.prototype.getViewRoot=function(){return this._viewRoot},e.prototype.resetViewRoot=function(t){t?this._viewRoot=t:t=this._viewRoot;var n=this.getRawData().tree.root;(!t||t!==n&&!n.contains(t))&&(this._viewRoot=n)},e.prototype.enableAriaDecal=function(){XO(this)},e.type="series.treemap",e.layoutMode="box",e.defaultOption={progressive:0,left:"center",top:"middle",width:"80%",height:"80%",sort:!0,clipWindow:"origin",squareRatio:.5*(1+Math.sqrt(5)),leafDepth:null,drillDownIcon:"\u25B6",zoomToNodeRatio:.32*.32,roam:!0,nodeClick:"zoomToNode",animation:!0,animationDurationUpdate:900,animationEasing:"quinticInOut",breadcrumb:{show:!0,height:22,left:"center",top:"bottom",emptyItemWidth:25,itemStyle:{color:"rgba(0,0,0,0.7)",textStyle:{color:"#fff"}},emphasis:{itemStyle:{color:"rgba(0,0,0,0.9)"}}},label:{show:!0,distance:0,padding:5,position:"inside",color:"#fff",overflow:"truncate"},upperLabel:{show:!1,position:[0,"50%"],height:20,overflow:"truncate",verticalAlign:"middle"},itemStyle:{color:null,colorAlpha:null,colorSaturation:null,borderWidth:0,gapWidth:0,borderColor:"#fff",borderColorSaturation:null},emphasis:{upperLabel:{show:!0,position:[0,"50%"],overflow:"truncate",verticalAlign:"middle"}},visualDimension:0,visualMin:null,visualMax:null,color:[],colorAlpha:null,colorSaturation:null,colorMappingBy:"index",visibleMin:10,childrenVisibleMin:null,levels:[]},e}(bt);function JO(r){var e=0;C(r.children,function(n){JO(n);var a=n.value;J(a)&&(a=a[0]),e+=a});var t=r.value;J(t)&&(t=t[0]),(t==null||isNaN(t))&&(t=e),t<0&&(t=0),J(r.value)?r.value[0]=t:r.value=t}function Oq(r,e){var t=ct(e.get("color")),n=ct(e.get(["aria","decal","decals"]));if(!!t){r=r||[];var a,i;C(r,function(s){var l=new ft(s),u=l.get("color"),c=l.get("decal");(l.get(["itemStyle","color"])||u&&u!=="none")&&(a=!0),(l.get(["itemStyle","decal"])||c&&c!=="none")&&(i=!0)});var o=r[0]||(r[0]={});return a||(o.color=t.slice()),!i&&n&&(o.decal=n.slice()),r}}var Pq=Eq,zq=8,KO=8,jb=5,kq=function(){function r(e){this.group=new De,e.add(this.group)}return r.prototype.render=function(e,t,n,a){var i=e.getModel("breadcrumb"),o=this.group;if(o.removeAll(),!(!i.get("show")||!n)){var s=i.getModel("itemStyle"),l=i.getModel("emphasis"),u=s.getModel("textStyle"),c=l.getModel(["itemStyle","textStyle"]),f={pos:{left:i.get("left"),right:i.get("right"),top:i.get("top"),bottom:i.get("bottom")},box:{width:t.getWidth(),height:t.getHeight()},emptyItemWidth:i.get("emptyItemWidth"),totalWidth:0,renderList:[]};this._prepare(n,f,u),this._renderContent(e,f,s,l,u,c,a),Vd(o,f.pos,f.box)}},r.prototype._prepare=function(e,t,n){for(var a=e;a;a=a.parentNode){var i=Kt(a.getModel().get("name"),""),o=n.getTextRect(i),s=Math.max(o.width+zq*2,t.emptyItemWidth);t.totalWidth+=s+KO,t.renderList.push({node:a,text:i,width:s})}},r.prototype._renderContent=function(e,t,n,a,i,o,s){for(var l=0,u=t.emptyItemWidth,c=e.get(["breadcrumb","height"]),f=N$(t.pos,t.box),h=t.totalWidth,v=t.renderList,d=a.getModel("itemStyle").getItemStyle(),p=v.length-1;p>=0;p--){var g=v[p],y=g.node,m=g.width,_=g.text;h>f.width&&(h-=m-u,m=u,_=null);var b=new qr({shape:{points:Rq(l,0,m,c,p===v.length-1,p===0)},style:me(n.getItemStyle(),{lineJoin:"bevel"}),textContent:new Ge({style:yt(i,{text:_})}),textConfig:{position:"inside"},z2:$l*1e4,onclick:Ae(s,y)});b.disableLabelAnimation=!0,b.getTextContent().ensureState("emphasis").style=yt(o,{text:_}),b.ensureState("emphasis").style=d,Lt(b,a.get("focus"),a.get("blurScope"),a.get("disabled")),this.group.add(b),jq(b,e,y),l+=m+KO}},r.prototype.remove=function(){this.group.removeAll()},r}();function Rq(r,e,t,n,a,i){var o=[[a?r:r-jb,e],[r+t,e],[r+t,e+n],[a?r:r-jb,e+n]];return!i&&o.splice(2,0,[r+t+jb,e+n/2]),!a&&o.push([r,e+n/2]),o}function jq(r,e,t){Te(r).eventData={componentType:"series",componentSubType:"treemap",componentIndex:e.componentIndex,seriesIndex:e.seriesIndex,seriesName:e.name,seriesType:"treemap",selfType:"breadcrumb",nodeData:{dataIndex:t&&t.dataIndex,name:t&&t.name},treePathInfo:t&&$p(t,e)}}var Bq=kq,Fq=function(){function r(){this._storage=[],this._elExistsMap={}}return r.prototype.add=function(e,t,n,a,i){return this._elExistsMap[e.id]?!1:(this._elExistsMap[e.id]=!0,this._storage.push({el:e,target:t,duration:n,delay:a,easing:i}),!0)},r.prototype.finished=function(e){return this._finishedCallback=e,this},r.prototype.start=function(){for(var e=this,t=this._storage.length,n=function(){t--,t<=0&&(e._storage.length=0,e._elExistsMap={},e._finishedCallback&&e._finishedCallback())},a=0,i=this._storage.length;a<i;a++){var o=this._storage[a];o.el.animateTo(o.target,{duration:o.duration,delay:o.delay,easing:o.easing,setToFinal:!0,done:n,aborted:n})}return this},r}();function Vq(){return new Fq}var Bb=De,eP=We,tP=3,rP="label",nP="upperLabel",Hq=$l*10,Wq=$l*2,Gq=$l*3,Ys=os([["fill","color"],["stroke","strokeColor"],["lineWidth","strokeWidth"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"]]),aP=function(r){var e=Ys(r);return e.stroke=e.fill=e.lineWidth=null,e},Up=Ye(),$q=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._state="ready",t._storage=nh(),t}return e.prototype.render=function(t,n,a,i){var o=n.findComponents({mainType:"series",subType:"treemap",query:i});if(!(ze(o,t)<0)){this.seriesModel=t,this.api=a,this.ecModel=n;var s=["treemapZoomToNode","treemapRootToNode"],l=th(i,s,t),u=i&&i.type,c=t.layoutInfo,f=!this._oldTree,h=this._storage,v=u==="treemapRootToNode"&&l&&h?{rootNodeGroup:h.nodeGroup[l.node.getRawIndex()],direction:i.direction}:null,d=this._giveContainerGroup(c),p=t.get("animation"),g=this._doRender(d,t,v);p&&!f&&(!u||u==="treemapZoomToNode"||u==="treemapRootToNode")?this._doAnimation(d,g,t,v):g.renderFinally(),this._resetController(a),this._renderBreadcrumb(t,a,l)}},e.prototype._giveContainerGroup=function(t){var n=this._containerGroup;return n||(n=this._containerGroup=new Bb,this._initEvents(n),this.group.add(n)),n.x=t.x,n.y=t.y,n},e.prototype._doRender=function(t,n,a){var i=n.getData().tree,o=this._oldTree,s=nh(),l=nh(),u=this._storage,c=[];function f(g,y,m,_){return Uq(n,l,u,a,s,c,g,y,m,_)}v(i.root?[i.root]:[],o&&o.root?[o.root]:[],t,i===o||!o,0);var h=d(u);return this._oldTree=i,this._storage=l,{lastsForAnimation:s,willDeleteEls:h,renderFinally:p};function v(g,y,m,_,b){_?(y=g,C(g,function(w,D){!w.isRemoved()&&M(D,D)})):new Mi(y,g,x,x).add(M).update(M).remove(Ae(M,null)).execute();function x(w){return w.getId()}function M(w,D){var T=w!=null?g[w]:null,I=D!=null?y[D]:null,A=f(T,I,m,b);A&&v(T&&T.viewChildren||[],I&&I.viewChildren||[],A,_,b+1)}}function d(g){var y=nh();return g&&C(g,function(m,_){var b=y[_];C(m,function(x){x&&(b.push(x),Up(x).willDelete=!0)})}),y}function p(){C(h,function(g){C(g,function(y){y.parent&&y.parent.remove(y)})}),C(c,function(g){g.invisible=!0,g.dirty()})}},e.prototype._doAnimation=function(t,n,a,i){var o=a.get("animationDurationUpdate"),s=a.get("animationEasing"),l=(ye(o)?0:o)||0,u=(ye(s)?null:s)||"cubicOut",c=Vq();C(n.willDeleteEls,function(f,h){C(f,function(v,d){if(!v.invisible){var p=v.parent,g,y=Up(p);if(i&&i.direction==="drillDown")g=p===i.rootNodeGroup?{shape:{x:0,y:0,width:y.nodeWidth,height:y.nodeHeight},style:{opacity:0}}:{style:{opacity:0}};else{var m=0,_=0;y.willDelete||(m=y.nodeWidth/2,_=y.nodeHeight/2),g=h==="nodeGroup"?{x:m,y:_,style:{opacity:0}}:{shape:{x:m,y:_,width:0,height:0},style:{opacity:0}}}g&&c.add(v,g,l,0,u)}})}),C(this._storage,function(f,h){C(f,function(v,d){var p=n.lastsForAnimation[h][d],g={};!p||(v instanceof De?p.oldX!=null&&(g.x=v.x,g.y=v.y,v.x=p.oldX,v.y=p.oldY):(p.oldShape&&(g.shape=X({},v.shape),v.setShape(p.oldShape)),p.fadein?(v.setStyle("opacity",0),g.style={opacity:1}):v.style.opacity!==1&&(g.style={opacity:1})),c.add(v,g,l,0,u))})},this),this._state="animating",c.finished(fe(function(){this._state="ready",n.renderFinally()},this)).start()},e.prototype._resetController=function(t){var n=this._controller;n||(n=this._controller=new Xf(t.getZr()),n.enable(this.seriesModel.get("roam")),n.on("pan",fe(this._onPan,this)),n.on("zoom",fe(this._onZoom,this)));var a=new Pe(0,0,t.getWidth(),t.getHeight());n.setPointerChecker(function(i,o,s){return a.contain(o,s)})},e.prototype._clearController=function(){var t=this._controller;t&&(t.dispose(),t=null)},e.prototype._onPan=function(t){if(this._state!=="animating"&&(Math.abs(t.dx)>tP||Math.abs(t.dy)>tP)){var n=this.seriesModel.getData().tree.root;if(!n)return;var a=n.getLayout();if(!a)return;this.api.dispatchAction({type:"treemapMove",from:this.uid,seriesId:this.seriesModel.id,rootRect:{x:a.x+t.dx,y:a.y+t.dy,width:a.width,height:a.height}})}},e.prototype._onZoom=function(t){var n=t.originX,a=t.originY;if(this._state!=="animating"){var i=this.seriesModel.getData().tree.root;if(!i)return;var o=i.getLayout();if(!o)return;var s=new Pe(o.x,o.y,o.width,o.height),l=this.seriesModel.layoutInfo;n-=l.x,a-=l.y;var u=yn();ua(u,u,[-n,-a]),Lv(u,u,[t.scale,t.scale]),ua(u,u,[n,a]),s.applyTransform(u),this.api.dispatchAction({type:"treemapRender",from:this.uid,seriesId:this.seriesModel.id,rootRect:{x:s.x,y:s.y,width:s.width,height:s.height}})}},e.prototype._initEvents=function(t){var n=this;t.on("click",function(a){if(n._state==="ready"){var i=n.seriesModel.get("nodeClick",!0);if(!!i){var o=n.findTarget(a.offsetX,a.offsetY);if(!!o){var s=o.node;if(s.getLayout().isLeafRoot)n._rootToNode(o);else if(i==="zoomToNode")n._zoomToNode(o);else if(i==="link"){var l=s.hostTree.data.getItemModel(s.dataIndex),u=l.get("link",!0),c=l.get("target",!0)||"blank";u&&Bd(u,c)}}}}},this)},e.prototype._renderBreadcrumb=function(t,n,a){var i=this;a||(a=t.get("leafDepth",!0)!=null?{node:t.getViewRoot()}:this.findTarget(n.getWidth()/2,n.getHeight()/2),a||(a={node:t.getData().tree.root})),(this._breadcrumb||(this._breadcrumb=new Bq(this.group))).render(t,n,a.node,function(o){i._state!=="animating"&&(Rb(t.getViewRoot(),o)?i._rootToNode({node:o}):i._zoomToNode({node:o}))})},e.prototype.remove=function(){this._clearController(),this._containerGroup&&this._containerGroup.removeAll(),this._storage=nh(),this._state="ready",this._breadcrumb&&this._breadcrumb.remove()},e.prototype.dispose=function(){this._clearController()},e.prototype._zoomToNode=function(t){this.api.dispatchAction({type:"treemapZoomToNode",from:this.uid,seriesId:this.seriesModel.id,targetNode:t.node})},e.prototype._rootToNode=function(t){this.api.dispatchAction({type:"treemapRootToNode",from:this.uid,seriesId:this.seriesModel.id,targetNode:t.node})},e.prototype.findTarget=function(t,n){var a,i=this.seriesModel.getViewRoot();return i.eachNode({attr:"viewChildren",order:"preorder"},function(o){var s=this._storage.background[o.getRawIndex()];if(s){var l=s.transformCoordToLocal(t,n),u=s.shape;if(u.x<=l[0]&&l[0]<=u.x+u.width&&u.y<=l[1]&&l[1]<=u.y+u.height)a={node:o,offsetX:l[0],offsetY:l[1]};else return!1}},this),a},e.type="treemap",e}(ht);function nh(){return{nodeGroup:[],background:[],content:[]}}function Uq(r,e,t,n,a,i,o,s,l,u){if(!o)return;var c=o.getLayout(),f=r.getData(),h=o.getModel();if(f.setItemGraphicEl(o.dataIndex,null),!c||!c.isInView)return;var v=c.width,d=c.height,p=c.borderWidth,g=c.invisible,y=o.getRawIndex(),m=s&&s.getRawIndex(),_=o.viewChildren,b=c.upperHeight,x=_&&_.length,M=h.getModel("itemStyle"),w=h.getModel(["emphasis","itemStyle"]),D=h.getModel(["blur","itemStyle"]),T=h.getModel(["select","itemStyle"]),I=M.get("borderRadius")||0,A=q("nodeGroup",Bb);if(!A)return;if(l.add(A),A.x=c.x||0,A.y=c.y||0,A.markRedraw(),Up(A).nodeWidth=v,Up(A).nodeHeight=d,c.isAboveViewRoot)return A;var N=q("background",eP,u,Wq);N&&G(A,N,x&&c.upperLabelHeight);var L=h.getModel("emphasis"),E=L.get("focus"),O=L.get("blurScope"),P=L.get("disabled"),H=E==="ancestor"?o.getAncestorsIndices():E==="descendant"?o.getDescendantIndices():E;if(x)Jc(A)&&ys(A,!1),N&&(ys(N,!P),f.setItemGraphicEl(o.dataIndex,N),a1(N,H,O));else{var F=q("content",eP,u,Gq);F&&Z(A,F),N.disableMorphing=!0,N&&Jc(N)&&ys(N,!1),ys(A,!P),f.setItemGraphicEl(o.dataIndex,A),a1(A,H,O)}return A;function G(oe,ie,he){var k=Te(ie);if(k.dataIndex=o.dataIndex,k.seriesIndex=r.seriesIndex,ie.setShape({x:0,y:0,width:v,height:d,r:I}),g)te(ie);else{ie.invisible=!1;var j=o.getVisual("style"),W=j.stroke,ae=aP(M);ae.fill=W;var re=Ys(w);re.fill=w.get("borderColor");var ee=Ys(D);ee.fill=D.get("borderColor");var se=Ys(T);if(se.fill=T.get("borderColor"),he){var Le=v-2*p;V(ie,W,j.opacity,{x:p,y:0,width:Le,height:b})}else ie.removeTextContent();ie.setStyle(ae),ie.ensureState("emphasis").style=re,ie.ensureState("blur").style=ee,ie.ensureState("select").style=se,gs(ie)}oe.add(ie)}function Z(oe,ie){var he=Te(ie);he.dataIndex=o.dataIndex,he.seriesIndex=r.seriesIndex;var k=Math.max(v-2*p,0),j=Math.max(d-2*p,0);if(ie.culling=!0,ie.setShape({x:p,y:p,width:k,height:j,r:I}),g)te(ie);else{ie.invisible=!1;var W=o.getVisual("style"),ae=W.fill,re=aP(M);re.fill=ae,re.decal=W.decal;var ee=Ys(w),se=Ys(D),Le=Ys(T);V(ie,ae,W.opacity,null),ie.setStyle(re),ie.ensureState("emphasis").style=ee,ie.ensureState("blur").style=se,ie.ensureState("select").style=Le,gs(ie)}oe.add(ie)}function te(oe){!oe.invisible&&i.push(oe)}function V(oe,ie,he,k){var j=h.getModel(k?nP:rP),W=Kt(h.get("name"),null),ae=j.getShallow("show");wr(oe,sr(h,k?nP:rP),{defaultText:ae?W:null,inheritColor:ie,defaultOpacity:he,labelFetcher:r,labelDataIndex:o.dataIndex});var re=oe.getTextContent();if(!!re){var ee=re.style,se=Tv(ee.padding||0);k&&(oe.setTextConfig({layoutRect:k}),re.disableLabelLayout=!0),re.beforeUpdate=function(){var dt=Math.max((k?k.width:oe.shape.width)-se[1]-se[3],0),pt=Math.max((k?k.height:oe.shape.height)-se[0]-se[2],0);(ee.width!==dt||ee.height!==pt)&&re.setStyle({width:dt,height:pt})},ee.truncateMinChar=2,ee.lineOverflow="truncate",Y(ee,k,c);var Le=re.getState("emphasis");Y(Le?Le.style:null,k,c)}}function Y(oe,ie,he){var k=oe?oe.text:null;if(!ie&&he.isLeafRoot&&k!=null){var j=r.get("drillDownIcon",!0);oe.text=j?j+" "+k:k}}function q(oe,ie,he,k){var j=m!=null&&t[oe][m],W=a[oe];return j?(t[oe][m]=null,Q(W,j)):g||(j=new ie,j instanceof Bn&&(j.z2=Yq(he,k)),ne(W,j)),e[oe][y]=j}function Q(oe,ie){var he=oe[y]={};ie instanceof Bb?(he.oldX=ie.x,he.oldY=ie.y):he.oldShape=X({},ie.shape)}function ne(oe,ie){var he=oe[y]={},k=o.parentNode,j=ie instanceof De;if(k&&(!n||n.direction==="drillDown")){var W=0,ae=0,re=a.background[k.getRawIndex()];!n&&re&&re.oldShape&&(W=re.oldShape.width,ae=re.oldShape.height),j?(he.oldX=0,he.oldY=ae):he.oldShape={x:W,y:ae,width:0,height:0}}he.fadein=!j}}function Yq(r,e){return r*Hq+e}var Qq=$q,ah=C,Zq=_e,Yp=-1,Fb=function(){function r(e){var t=e.mappingMethod,n=e.type,a=this.option=Me(e);this.type=n,this.mappingMethod=t,this._normalizeData=Jq[t];var i=r.visualHandlers[n];this.applyVisual=i.applyVisual,this.getColorMapper=i.getColorMapper,this._normalizedToVisual=i._normalizedToVisual[t],t==="piecewise"?(Vb(a),qq(a)):t==="category"?a.categories?Xq(a):Vb(a,!0):(Er(t!=="linear"||a.dataExtent),Vb(a))}return r.prototype.mapValueToVisual=function(e){var t=this._normalizeData(e);return this._normalizedToVisual(t,e)},r.prototype.getNormalizer=function(){return fe(this._normalizeData,this)},r.listVisualTypes=function(){return Fe(r.visualHandlers)},r.isValidType=function(e){return r.visualHandlers.hasOwnProperty(e)},r.eachVisual=function(e,t,n){_e(e)?C(e,t,n):t.call(n,e)},r.mapVisual=function(e,t,n){var a,i=J(e)?[]:_e(e)?{}:(a=!0,null);return r.eachVisual(e,function(o,s){var l=t.call(n,o,s);a?i=l:i[s]=l}),i},r.retrieveVisuals=function(e){var t={},n;return e&&ah(r.visualHandlers,function(a,i){e.hasOwnProperty(i)&&(t[i]=e[i],n=!0)}),n?t:null},r.prepareVisualTypes=function(e){if(J(e))e=e.slice();else if(Zq(e)){var t=[];ah(e,function(n,a){t.push(a)}),e=t}else return[];return e.sort(function(n,a){return a==="color"&&n!=="color"&&n.indexOf("color")===0?1:-1}),e},r.dependsOn=function(e,t){return t==="color"?!!(e&&e.indexOf(t)===0):e===t},r.findPieceIndex=function(e,t,n){for(var a,i=1/0,o=0,s=t.length;o<s;o++){var l=t[o].value;if(l!=null){if(l===e||ce(l)&&l===e+"")return o;n&&h(l,o)}}for(var o=0,s=t.length;o<s;o++){var u=t[o],c=u.interval,f=u.close;if(c){if(c[0]===-1/0){if(Zp(f[1],e,c[1]))return o}else if(c[1]===1/0){if(Zp(f[0],c[0],e))return o}else if(Zp(f[0],c[0],e)&&Zp(f[1],e,c[1]))return o;n&&h(c[0],o),n&&h(c[1],o)}}if(n)return e===1/0?t.length-1:e===-1/0?0:a;function h(v,d){var p=Math.abs(v-e);p<i&&(i=p,a=d)}},r.visualHandlers={color:{applyVisual:ih("color"),getColorMapper:function(){var e=this.option;return fe(e.mappingMethod==="category"?function(t,n){return!n&&(t=this._normalizeData(t)),oh.call(this,t)}:function(t,n,a){var i=!!a;return!n&&(t=this._normalizeData(t)),a=Lc(t,e.parsedVisual,a),i?a:fa(a,"rgba")},this)},_normalizedToVisual:{linear:function(e){return fa(Lc(e,this.option.parsedVisual),"rgba")},category:oh,piecewise:function(e,t){var n=Wb.call(this,t);return n==null&&(n=fa(Lc(e,this.option.parsedVisual),"rgba")),n},fixed:Qs}},colorHue:Qp(function(e,t){return jl(e,t)}),colorSaturation:Qp(function(e,t){return jl(e,null,t)}),colorLightness:Qp(function(e,t){return jl(e,null,null,t)}),colorAlpha:Qp(function(e,t){return Ec(e,t)}),decal:{applyVisual:ih("decal"),_normalizedToVisual:{linear:null,category:oh,piecewise:null,fixed:null}},opacity:{applyVisual:ih("opacity"),_normalizedToVisual:Hb([0,1])},liftZ:{applyVisual:ih("liftZ"),_normalizedToVisual:{linear:Qs,category:Qs,piecewise:Qs,fixed:Qs}},symbol:{applyVisual:function(e,t,n){var a=this.mapValueToVisual(e);n("symbol",a)},_normalizedToVisual:{linear:iP,category:oh,piecewise:function(e,t){var n=Wb.call(this,t);return n==null&&(n=iP.call(this,e)),n},fixed:Qs}},symbolSize:{applyVisual:ih("symbolSize"),_normalizedToVisual:Hb([0,1])}},r}();function qq(r){var e=r.pieceList;r.hasSpecialVisual=!1,C(e,function(t,n){t.originIndex=n,t.visual!=null&&(r.hasSpecialVisual=!0)})}function Xq(r){var e=r.categories,t=r.categoryMap={},n=r.visual;if(ah(e,function(o,s){t[o]=s}),!J(n)){var a=[];_e(n)?ah(n,function(o,s){var l=t[s];a[l!=null?l:Yp]=o}):a[Yp]=n,n=oP(r,a)}for(var i=e.length-1;i>=0;i--)n[i]==null&&(delete t[e[i]],e.pop())}function Vb(r,e){var t=r.visual,n=[];_e(t)?ah(t,function(i){n.push(i)}):t!=null&&n.push(t);var a={color:1,symbol:1};!e&&n.length===1&&!a.hasOwnProperty(r.type)&&(n[1]=n[0]),oP(r,n)}function Qp(r){return{applyVisual:function(e,t,n){var a=this.mapValueToVisual(e);n("color",r(t("color"),a))},_normalizedToVisual:Hb([0,1])}}function iP(r){var e=this.option.visual;return e[Math.round(st(r,[0,1],[0,e.length-1],!0))]||{}}function ih(r){return function(e,t,n){n(r,this.mapValueToVisual(e))}}function oh(r){var e=this.option.visual;return e[this.option.loop&&r!==Yp?r%e.length:r]}function Qs(){return this.option.visual[0]}function Hb(r){return{linear:function(e){return st(e,r,this.option.visual,!0)},category:oh,piecewise:function(e,t){var n=Wb.call(this,t);return n==null&&(n=st(e,r,this.option.visual,!0)),n},fixed:Qs}}function Wb(r){var e=this.option,t=e.pieceList;if(e.hasSpecialVisual){var n=Fb.findPieceIndex(r,t),a=t[n];if(a&&a.visual)return a.visual[this.type]}}function oP(r,e){return r.visual=e,r.type==="color"&&(r.parsedVisual=K(e,function(t){var n=Ur(t);return n||[0,0,0,1]})),e}var Jq={linear:function(r){return st(r,this.option.dataExtent,[0,1],!0)},piecewise:function(r){var e=this.option.pieceList,t=Fb.findPieceIndex(r,e,!0);if(t!=null)return st(t,[0,e.length-1],[0,1],!0)},category:function(r){var e=this.option.categories?this.option.categoryMap[r]:r;return e==null?Yp:e},fixed:Ot};function Zp(r,e,t){return r?e<=t:e<t}var Sr=Fb,Kq="itemStyle",sP=Ye(),eX={seriesType:"treemap",reset:function(r){var e=r.getData().tree,t=e.root;t.isRemoved()||lP(t,{},r.getViewRoot().getAncestors(),r)}};function lP(r,e,t,n){var a=r.getModel(),i=r.getLayout(),o=r.hostTree.data;if(!(!i||i.invisible||!i.isInView)){var s=a.getModel(Kq),l=tX(s,e,n),u=o.ensureUniqueItemVisual(r.dataIndex,"style"),c=s.get("borderColor"),f=s.get("borderColorSaturation"),h;f!=null&&(h=uP(l),c=rX(f,h)),u.stroke=c;var v=r.viewChildren;if(!v||!v.length)h=uP(l),u.fill=h;else{var d=nX(r,a,i,s,l,v);C(v,function(p,g){if(p.depth>=t.length||p===t[p.depth]){var y=aX(a,l,p,g,d,n);lP(p,y,t,n)}})}}}function tX(r,e,t){var n=X({},e),a=t.designatedVisualItemStyle;return C(["color","colorAlpha","colorSaturation"],function(i){a[i]=e[i];var o=r.get(i);a[i]=null,o!=null&&(n[i]=o)}),n}function uP(r){var e=Gb(r,"color");if(e){var t=Gb(r,"colorAlpha"),n=Gb(r,"colorSaturation");return n&&(e=jl(e,null,null,n)),t&&(e=Ec(e,t)),e}}function rX(r,e){return e!=null?jl(e,null,null,r):null}function Gb(r,e){var t=r[e];if(t!=null&&t!=="none")return t}function nX(r,e,t,n,a,i){if(!(!i||!i.length)){var o=$b(e,"color")||a.color!=null&&a.color!=="none"&&($b(e,"colorAlpha")||$b(e,"colorSaturation"));if(!!o){var s=e.get("visualMin"),l=e.get("visualMax"),u=t.dataExtent.slice();s!=null&&s<u[0]&&(u[0]=s),l!=null&&l>u[1]&&(u[1]=l);var c=e.get("colorMappingBy"),f={type:o.name,dataExtent:u,visual:o.range};f.type==="color"&&(c==="index"||c==="id")?(f.mappingMethod="category",f.loop=!0):f.mappingMethod="linear";var h=new Sr(f);return sP(h).drColorMappingBy=c,h}}}function $b(r,e){var t=r.get(e);return J(t)&&t.length?{name:e,range:t}:null}function aX(r,e,t,n,a,i){var o=X({},e);if(a){var s=a.type,l=s==="color"&&sP(a).drColorMappingBy,u=l==="index"?n:l==="id"?i.mapIdToIndex(t.getId()):t.getValue(r.get("visualDimension"));o[s]=a.mapValueToVisual(u)}return o}var sh=Math.max,qp=Math.min,cP=ar,Ub=C,fP=["itemStyle","borderWidth"],iX=["itemStyle","gapWidth"],oX=["upperLabel","show"],sX=["upperLabel","height"],lX={seriesType:"treemap",reset:function(r,e,t,n){var a=t.getWidth(),i=t.getHeight(),o=r.option,s=Yt(r.getBoxLayoutParams(),{width:t.getWidth(),height:t.getHeight()}),l=o.size||[],u=ue(cP(s.width,l[0]),a),c=ue(cP(s.height,l[1]),i),f=n&&n.type,h=["treemapZoomToNode","treemapRootToNode"],v=th(n,h,r),d=f==="treemapRender"||f==="treemapMove"?n.rootRect:null,p=r.getViewRoot(),g=ZO(p);if(f!=="treemapMove"){var y=f==="treemapZoomToNode"?dX(r,v,p,u,c):d?[d.width,d.height]:[u,c],m=o.sort;m&&m!=="asc"&&m!=="desc"&&(m="desc");var _={squareRatio:o.squareRatio,sort:m,leafDepth:o.leafDepth};p.hostTree.clearLayouts();var b={x:0,y:0,width:y[0],height:y[1],area:y[0]*y[1]};p.setLayout(b),hP(p,_,!1,0),b=p.getLayout(),Ub(g,function(M,w){var D=(g[w+1]||p).getValue();M.setLayout(X({dataExtent:[D,D],borderWidth:0,upperHeight:0},b))})}var x=r.getData().tree.root;x.setLayout(pX(s,d,v),!0),r.setLayoutInfo(s),dP(x,new Pe(-s.x,-s.y,a,i),g,p,0)}};function hP(r,e,t,n){var a,i;if(!r.isRemoved()){var o=r.getLayout();a=o.width,i=o.height;var s=r.getModel(),l=s.get(fP),u=s.get(iX)/2,c=pP(s),f=Math.max(l,c),h=l-u,v=f-u;r.setLayout({borderWidth:l,upperHeight:f,upperLabelHeight:c},!0),a=sh(a-2*h,0),i=sh(i-h-v,0);var d=a*i,p=uX(r,s,d,e,t,n);if(!!p.length){var g={x:h,y:v,width:a,height:i},y=qp(a,i),m=1/0,_=[];_.area=0;for(var b=0,x=p.length;b<x;){var M=p[b];_.push(M),_.area+=M.getLayout().area;var w=vX(_,y,e.squareRatio);w<=m?(b++,m=w):(_.area-=_.pop().getLayout().area,vP(_,y,g,u,!1),y=qp(g.width,g.height),_.length=_.area=0,m=1/0)}if(_.length&&vP(_,y,g,u,!0),!t){var D=s.get("childrenVisibleMin");D!=null&&d<D&&(t=!0)}for(var b=0,x=p.length;b<x;b++)hP(p[b],e,t,n+1)}}}function uX(r,e,t,n,a,i){var o=r.children||[],s=n.sort;s!=="asc"&&s!=="desc"&&(s=null);var l=n.leafDepth!=null&&n.leafDepth<=i;if(a&&!l)return r.viewChildren=[];o=ot(o,function(v){return!v.isRemoved()}),fX(o,s);var u=hX(e,o,s);if(u.sum===0)return r.viewChildren=[];if(u.sum=cX(e,t,u.sum,s,o),u.sum===0)return r.viewChildren=[];for(var c=0,f=o.length;c<f;c++){var h=o[c].getValue()/u.sum*t;o[c].setLayout({area:h})}return l&&(o.length&&r.setLayout({isLeafRoot:!0},!0),o.length=0),r.viewChildren=o,r.setLayout({dataExtent:u.dataExtent},!0),o}function cX(r,e,t,n,a){if(!n)return t;for(var i=r.get("visibleMin"),o=a.length,s=o,l=o-1;l>=0;l--){var u=a[n==="asc"?o-l-1:l].getValue();u/t*e<i&&(s=l,t-=u)}return n==="asc"?a.splice(0,o-s):a.splice(s,o-s),t}function fX(r,e){return e&&r.sort(function(t,n){var a=e==="asc"?t.getValue()-n.getValue():n.getValue()-t.getValue();return a===0?e==="asc"?t.dataIndex-n.dataIndex:n.dataIndex-t.dataIndex:a}),r}function hX(r,e,t){for(var n=0,a=0,i=e.length;a<i;a++)n+=e[a].getValue();var o=r.get("visualDimension"),s;return!e||!e.length?s=[NaN,NaN]:o==="value"&&t?(s=[e[e.length-1].getValue(),e[0].getValue()],t==="asc"&&s.reverse()):(s=[1/0,-1/0],Ub(e,function(l){var u=l.getValue(o);u<s[0]&&(s[0]=u),u>s[1]&&(s[1]=u)})),{sum:n,dataExtent:s}}function vX(r,e,t){for(var n=0,a=1/0,i=0,o=void 0,s=r.length;i<s;i++)o=r[i].getLayout().area,o&&(o<a&&(a=o),o>n&&(n=o));var l=r.area*r.area,u=e*e*t;return l?sh(u*n/l,l/(u*a)):1/0}function vP(r,e,t,n,a){var i=e===t.width?0:1,o=1-i,s=["x","y"],l=["width","height"],u=t[s[i]],c=e?r.area/e:0;(a||c>t[l[o]])&&(c=t[l[o]]);for(var f=0,h=r.length;f<h;f++){var v=r[f],d={},p=c?v.getLayout().area/c:0,g=d[l[o]]=sh(c-2*n,0),y=t[s[i]]+t[l[i]]-u,m=f===h-1||y<p?y:p,_=d[l[i]]=sh(m-2*n,0);d[s[o]]=t[s[o]]+qp(n,g/2),d[s[i]]=u+qp(n,_/2),u+=m,v.setLayout(d,!0)}t[s[o]]+=c,t[l[o]]-=c}function dX(r,e,t,n,a){var i=(e||{}).node,o=[n,a];if(!i||i===t)return o;for(var s,l=n*a,u=l*r.option.zoomToNodeRatio;s=i.parentNode;){for(var c=0,f=s.children,h=0,v=f.length;h<v;h++)c+=f[h].getValue();var d=i.getValue();if(d===0)return o;u*=c/d;var p=s.getModel(),g=p.get(fP),y=Math.max(g,pP(p));u+=4*g*g+(3*g+y)*Math.pow(u,.5),u>D0&&(u=D0),i=s}u<l&&(u=l);var m=Math.pow(u/l,.5);return[n*m,a*m]}function pX(r,e,t){if(e)return{x:e.x,y:e.y};var n={x:0,y:0};if(!t)return n;var a=t.node,i=a.getLayout();if(!i)return n;for(var o=[i.width/2,i.height/2],s=a;s;){var l=s.getLayout();o[0]+=l.x,o[1]+=l.y,s=s.parentNode}return{x:r.width/2-o[0],y:r.height/2-o[1]}}function dP(r,e,t,n,a){var i=r.getLayout(),o=t[a],s=o&&o===r;if(!(o&&!s||a===t.length&&r!==n)){r.setLayout({isInView:!0,invisible:!s&&!e.intersect(i),isAboveViewRoot:s},!0);var l=new Pe(e.x-i.x,e.y-i.y,e.width,e.height);Ub(r.viewChildren||[],function(u){dP(u,l,t,n,a+1)})}}function pP(r){return r.get(oX)?r.get(sX):0}function gX(r){r.registerSeriesModel(Pq),r.registerChartView(Qq),r.registerVisual(eX),r.registerLayout(lX),Lq(r)}function yX(r){var e=r.findComponents({mainType:"legend"});!e||!e.length||r.eachSeriesByType("graph",function(t){var n=t.getCategoriesData(),a=t.getGraph(),i=a.data,o=n.mapArray(n.getName);i.filterSelf(function(s){var l=i.getItemModel(s),u=l.getShallow("category");if(u!=null){Ue(u)&&(u=o[u]);for(var c=0;c<e.length;c++)if(!e[c].isSelected(u))return!1}return!0})})}function mX(r){var e={};r.eachSeriesByType("graph",function(t){var n=t.getCategoriesData(),a=t.getData(),i={};n.each(function(o){var s=n.getName(o);i["ec-"+s]=o;var l=n.getItemModel(o),u=l.getModel("itemStyle").getItemStyle();u.fill||(u.fill=t.getColorFromPalette(s,e)),n.setItemVisual(o,"style",u);for(var c=["symbol","symbolSize","symbolKeepAspect"],f=0;f<c.length;f++){var h=l.getShallow(c[f],!0);h!=null&&n.setItemVisual(o,c[f],h)}}),n.count()&&a.each(function(o){var s=a.getItemModel(o),l=s.getShallow("category");if(l!=null){ce(l)&&(l=i["ec-"+l]);var u=n.getItemVisual(l,"style"),c=a.ensureUniqueItemVisual(o,"style");X(c,u);for(var f=["symbol","symbolSize","symbolKeepAspect"],h=0;h<f.length;h++)a.setItemVisual(o,f[h],n.getItemVisual(l,f[h]))}})})}function Xp(r){return r instanceof Array||(r=[r,r]),r}function _X(r){r.eachSeriesByType("graph",function(e){var t=e.getGraph(),n=e.getEdgeData(),a=Xp(e.get("edgeSymbol")),i=Xp(e.get("edgeSymbolSize"));n.setVisual("fromSymbol",a&&a[0]),n.setVisual("toSymbol",a&&a[1]),n.setVisual("fromSymbolSize",i&&i[0]),n.setVisual("toSymbolSize",i&&i[1]),n.setVisual("style",e.getModel("lineStyle").getLineStyle()),n.each(function(o){var s=n.getItemModel(o),l=t.getEdgeByIndex(o),u=Xp(s.getShallow("symbol",!0)),c=Xp(s.getShallow("symbolSize",!0)),f=s.getModel("lineStyle").getLineStyle(),h=n.ensureUniqueItemVisual(o,"style");switch(X(h,f),h.stroke){case"source":{var v=l.node1.getVisual("style");h.stroke=v&&v.fill;break}case"target":{var v=l.node2.getVisual("style");h.stroke=v&&v.fill;break}}u[0]&&l.setVisual("fromSymbol",u[0]),u[1]&&l.setVisual("toSymbol",u[1]),c[0]&&l.setVisual("fromSymbolSize",c[0]),c[1]&&l.setVisual("toSymbolSize",c[1])})})}var Yb="-->",Jp=function(r){return r.get("autoCurveness")||null},gP=function(r,e){var t=Jp(r),n=20,a=[];if(Ue(t))n=t;else if(J(t)){r.__curvenessList=t;return}e>n&&(n=e);var i=n%2?n+2:n+3;a=[];for(var o=0;o<i;o++)a.push((o%2?o+1:o)/10*(o%2?-1:1));r.__curvenessList=a},lh=function(r,e,t){var n=[r.id,r.dataIndex].join("."),a=[e.id,e.dataIndex].join(".");return[t.uid,n,a].join(Yb)},yP=function(r){var e=r.split(Yb);return[e[0],e[2],e[1]].join(Yb)},bX=function(r,e){var t=lh(r.node1,r.node2,e);return e.__edgeMap[t]},MX=function(r,e){var t=Qb(lh(r.node1,r.node2,e),e),n=Qb(lh(r.node2,r.node1,e),e);return t+n},Qb=function(r,e){var t=e.__edgeMap;return t[r]?t[r].length:0};function xX(r){!Jp(r)||(r.__curvenessList=[],r.__edgeMap={},gP(r))}function wX(r,e,t,n){if(!!Jp(t)){var a=lh(r,e,t),i=t.__edgeMap,o=i[yP(a)];i[a]&&!o?i[a].isForward=!0:o&&i[a]&&(o.isForward=!0,i[a].isForward=!1),i[a]=i[a]||[],i[a].push(n)}}function Zb(r,e,t,n){var a=Jp(e),i=J(a);if(!a)return null;var o=bX(r,e);if(!o)return null;for(var s=-1,l=0;l<o.length;l++)if(o[l]===t){s=l;break}var u=MX(r,e);gP(e,u),r.lineStyle=r.lineStyle||{};var c=lh(r.node1,r.node2,e),f=e.__curvenessList,h=i||u%2?0:1;if(o.isForward)return f[h+s];var v=yP(c),d=Qb(v,e),p=f[s+d+h];return n?i?a&&a[0]===0?(d+h)%2?p:-p:((d%2?0:1)+h)%2?p:-p:(d+h)%2?p:-p:f[s+d+h]}function mP(r){var e=r.coordinateSystem;if(!(e&&e.type!=="view")){var t=r.getGraph();t.eachNode(function(n){var a=n.getModel();n.setLayout([+a.get("x"),+a.get("y")])}),qb(t,r)}}function qb(r,e){r.eachEdge(function(t,n){var a=Ea(t.getModel().get(["lineStyle","curveness"]),-Zb(t,e,n,!0),0),i=Oa(t.node1.getLayout()),o=Oa(t.node2.getLayout()),s=[i,o];+a&&s.push([(i[0]+o[0])/2-(i[1]-o[1])*a,(i[1]+o[1])/2-(o[0]-i[0])*a]),t.setLayout(s)})}function DX(r,e){r.eachSeriesByType("graph",function(t){var n=t.get("layout"),a=t.coordinateSystem;if(a&&a.type!=="view"){var i=t.getData(),o=[];C(a.dimensions,function(h){o=o.concat(i.mapDimensionsAll(h))});for(var s=0;s<i.count();s++){for(var l=[],u=!1,c=0;c<o.length;c++){var f=i.get(o[c],s);isNaN(f)||(u=!0),l.push(f)}u?i.setItemLayout(s,a.dataToPoint(l)):i.setItemLayout(s,[NaN,NaN])}qb(i.graph,t)}else(!n||n==="none")&&mP(t)})}function uh(r){var e=r.coordinateSystem;if(e.type!=="view")return 1;var t=r.option.nodeScaleRatio,n=e.scaleX,a=e.getZoom(),i=(a-1)*t+1;return i/n}function ch(r){var e=r.getVisual("symbolSize");return e instanceof Array&&(e=(e[0]+e[1])/2),+e}var _P=Math.PI,Xb=[];function Jb(r,e,t,n){var a=r.coordinateSystem;if(!(a&&a.type!=="view")){var i=a.getBoundingRect(),o=r.getData(),s=o.graph,l=i.width/2+i.x,u=i.height/2+i.y,c=Math.min(i.width,i.height)/2,f=o.count();if(o.setLayout({cx:l,cy:u}),!!f){if(t){var h=a.pointToData(n),v=h[0],d=h[1],p=[v-l,d-u];Yo(p,p),bc(p,p,c),t.setLayout([l+p[0],u+p[1]],!0);var g=r.get(["circular","rotateLabel"]);bP(t,g,l,u)}SX[e](r,s,o,c,l,u,f),s.eachEdge(function(y,m){var _=Ea(y.getModel().get(["lineStyle","curveness"]),Zb(y,r,m),0),b=Oa(y.node1.getLayout()),x=Oa(y.node2.getLayout()),M,w=(b[0]+x[0])/2,D=(b[1]+x[1])/2;+_&&(_*=3,M=[l*_+w*(1-_),u*_+D*(1-_)]),y.setLayout([b,x,M])})}}}var SX={value:function(r,e,t,n,a,i,o){var s=0,l=t.getSum("value"),u=Math.PI*2/(l||o);e.eachNode(function(c){var f=c.getValue("value"),h=u*(l?f:1)/2;s+=h,c.setLayout([n*Math.cos(s)+a,n*Math.sin(s)+i]),s+=h})},symbolSize:function(r,e,t,n,a,i,o){var s=0;Xb.length=o;var l=uh(r);e.eachNode(function(f){var h=ch(f);isNaN(h)&&(h=2),h<0&&(h=0),h*=l;var v=Math.asin(h/2/n);isNaN(v)&&(v=_P/2),Xb[f.dataIndex]=v,s+=v*2});var u=(2*_P-s)/o/2,c=0;e.eachNode(function(f){var h=u+Xb[f.dataIndex];c+=h,(!f.getLayout()||!f.getLayout().fixed)&&f.setLayout([n*Math.cos(c)+a,n*Math.sin(c)+i]),c+=h})}};function bP(r,e,t,n){var a=r.getGraphicEl();if(!!a){var i=r.getModel(),o=i.get(["label","rotate"])||0,s=a.getSymbolPath();if(e){var l=r.getLayout(),u=Math.atan2(l[1]-n,l[0]-t);u<0&&(u=Math.PI*2+u);var c=l[0]<t;c&&(u=u-Math.PI);var f=c?"left":"right";s.setTextConfig({rotation:-u,position:f,origin:"center"});var h=s.ensureState("emphasis");X(h.textConfig||(h.textConfig={}),{position:f})}else s.setTextConfig({rotation:o*=Math.PI/180})}}function IX(r){r.eachSeriesByType("graph",function(e){e.get("layout")==="circular"&&Jb(e,"symbolSize")})}var Au=Av;function TX(r,e,t){for(var n=r,a=e,i=t.rect,o=i.width,s=i.height,l=[i.x+o/2,i.y+s/2],u=t.gravity==null?.1:t.gravity,c=0;c<n.length;c++){var f=n[c];f.p||(f.p=Ui(o*(Math.random()-.5)+l[0],s*(Math.random()-.5)+l[1])),f.pp=Oa(f.p),f.edges=null}var h=t.friction==null?.6:t.friction,v=h,d,p;return{warmUp:function(){v=h*.8},setFixed:function(g){n[g].fixed=!0},setUnfixed:function(g){n[g].fixed=!1},beforeStep:function(g){d=g},afterStep:function(g){p=g},step:function(g){d&&d(n,a);for(var y=[],m=n.length,_=0;_<a.length;_++){var b=a[_];if(!b.ignoreForceLayout){var x=b.n1,M=b.n2;Yi(y,M.p,x.p);var w=_c(y)-b.d,D=M.w/(x.w+M.w);isNaN(D)&&(D=0),Yo(y,y),!x.fixed&&Au(x.p,x.p,y,D*w*v),!M.fixed&&Au(M.p,M.p,y,-(1-D)*w*v)}}for(var _=0;_<m;_++){var T=n[_];T.fixed||(Yi(y,l,T.p),Au(T.p,T.p,y,u*v))}for(var _=0;_<m;_++)for(var x=n[_],I=_+1;I<m;I++){var M=n[I];Yi(y,M.p,x.p);var w=_c(y);w===0&&($S(y,Math.random()-.5,Math.random()-.5),w=1);var A=(x.rep+M.rep)/w/w;!x.fixed&&Au(x.pp,x.pp,y,A),!M.fixed&&Au(M.pp,M.pp,y,-A)}for(var N=[],_=0;_<m;_++){var T=n[_];T.fixed||(Yi(N,T.p,T.pp),Au(T.p,T.p,N,v),Or(T.pp,T.p))}v=v*.992;var L=v<.01;p&&p(n,a,L),g&&g(L)}}}function AX(r){r.eachSeriesByType("graph",function(e){var t=e.coordinateSystem;if(!(t&&t.type!=="view"))if(e.get("layout")==="force"){var n=e.preservedPoints||{},a=e.getGraph(),i=a.data,o=a.edgeData,s=e.getModel("force"),l=s.get("initLayout");e.preservedPoints?i.each(function(_){var b=i.getId(_);i.setItemLayout(_,n[b]||[NaN,NaN])}):!l||l==="none"?mP(e):l==="circular"&&Jb(e,"value");var u=i.getDataExtent("value"),c=o.getDataExtent("value"),f=s.get("repulsion"),h=s.get("edgeLength"),v=J(f)?f:[f,f],d=J(h)?h:[h,h];d=[d[1],d[0]];var p=i.mapArray("value",function(_,b){var x=i.getItemLayout(b),M=st(_,u,v);return isNaN(M)&&(M=(v[0]+v[1])/2),{w:M,rep:M,fixed:i.getItemModel(b).get("fixed"),p:!x||isNaN(x[0])||isNaN(x[1])?null:x}}),g=o.mapArray("value",function(_,b){var x=a.getEdgeByIndex(b),M=st(_,c,d);isNaN(M)&&(M=(d[0]+d[1])/2);var w=x.getModel(),D=Ea(x.getModel().get(["lineStyle","curveness"]),-Zb(x,e,b,!0),0);return{n1:p[x.node1.dataIndex],n2:p[x.node2.dataIndex],d:M,curveness:D,ignoreForceLayout:w.get("ignoreForceLayout")}}),y=t.getBoundingRect(),m=TX(p,g,{rect:y,gravity:s.get("gravity"),friction:s.get("friction")});m.beforeStep(function(_,b){for(var x=0,M=_.length;x<M;x++)_[x].fixed&&Or(_[x].p,a.getNodeByIndex(x).getLayout())}),m.afterStep(function(_,b,x){for(var M=0,w=_.length;M<w;M++)_[M].fixed||a.getNodeByIndex(M).setLayout(_[M].p),n[i.getId(M)]=_[M].p;for(var M=0,w=b.length;M<w;M++){var D=b[M],T=a.getEdgeByIndex(M),I=D.n1.p,A=D.n2.p,N=T.getLayout();N=N?N.slice():[],N[0]=N[0]||[],N[1]=N[1]||[],Or(N[0],I),Or(N[1],A),+D.curveness&&(N[2]=[(I[0]+A[0])/2-(I[1]-A[1])*D.curveness,(I[1]+A[1])/2-(A[0]-I[0])*D.curveness]),T.setLayout(N)}}),e.forceLayout=m,e.preservedPoints=n,m.step()}else e.forceLayout=null})}function CX(r,e,t){var n=X(r.getBoxLayoutParams(),{aspect:t});return Yt(n,{width:e.getWidth(),height:e.getHeight()})}function NX(r,e){var t=[];return r.eachSeriesByType("graph",function(n){var a=n.get("coordinateSystem");if(!a||a==="view"){var i=n.getData(),o=i.mapArray(function(g){var y=i.getItemModel(g);return[+y.get("x"),+y.get("y")]}),s=[],l=[];ud(o,s,l),l[0]-s[0]===0&&(l[0]+=1,s[0]-=1),l[1]-s[1]===0&&(l[1]+=1,s[1]-=1);var u=(l[0]-s[0])/(l[1]-s[1]),c=CX(n,e,u);isNaN(u)&&(s=[c.x,c.y],l=[c.x+c.width,c.y+c.height]);var f=l[0]-s[0],h=l[1]-s[1],v=c.width,d=c.height,p=n.coordinateSystem=new Kf;p.zoomLimit=n.get("scaleLimit"),p.setBoundingRect(s[0],s[1],f,h),p.setViewRect(c.x,c.y,v,d),p.setCenter(n.get("center"),e),p.setZoom(n.get("zoom")),t.push(p)}}),t}var MP=or.prototype,Kb=nf.prototype,xP=function(){function r(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.percent=1}return r}();(function(r){U(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e})(xP);function eM(r){return isNaN(+r.cpx1)||isNaN(+r.cpy1)}var LX=function(r){U(e,r);function e(t){var n=r.call(this,t)||this;return n.type="ec-line",n}return e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new xP},e.prototype.buildPath=function(t,n){eM(n)?MP.buildPath.call(this,t,n):Kb.buildPath.call(this,t,n)},e.prototype.pointAt=function(t){return eM(this.shape)?MP.pointAt.call(this,t):Kb.pointAt.call(this,t)},e.prototype.tangentAt=function(t){var n=this.shape,a=eM(n)?[n.x2-n.x1,n.y2-n.y1]:Kb.tangentAt.call(this,t);return Yo(a,a)},e}(je),EX=LX,tM=["fromSymbol","toSymbol"];function wP(r){return"_"+r+"Type"}function DP(r,e,t){var n=e.getItemVisual(t,r);if(!(!n||n==="none")){var a=e.getItemVisual(t,r+"Size"),i=e.getItemVisual(t,r+"Rotate"),o=e.getItemVisual(t,r+"Offset"),s=e.getItemVisual(t,r+"KeepAspect"),l=If(a),u=pu(o||0,l),c=Ft(n,-l[0]/2+u[0],-l[1]/2+u[1],l[0],l[1],null,s);return c.__specifiedRotation=i==null||isNaN(i)?void 0:+i*Math.PI/180||0,c.name=r,c}}function OX(r){var e=new EX({name:"line",subPixelOptimize:!0});return rM(e.shape,r),e}function rM(r,e){r.x1=e[0][0],r.y1=e[0][1],r.x2=e[1][0],r.y2=e[1][1],r.percent=1;var t=e[2];t?(r.cpx1=t[0],r.cpy1=t[1]):(r.cpx1=NaN,r.cpy1=NaN)}var PX=function(r){U(e,r);function e(t,n,a){var i=r.call(this)||this;return i._createLine(t,n,a),i}return e.prototype._createLine=function(t,n,a){var i=t.hostModel,o=t.getItemLayout(n),s=OX(o);s.shape.percent=0,Dt(s,{shape:{percent:1}},i,n),this.add(s),C(tM,function(l){var u=DP(l,t,n);this.add(u),this[wP(l)]=t.getItemVisual(n,l)},this),this._updateCommonStl(t,n,a)},e.prototype.updateData=function(t,n,a){var i=t.hostModel,o=this.childOfName("line"),s=t.getItemLayout(n),l={shape:{}};rM(l.shape,s),Qe(o,l,i,n),C(tM,function(u){var c=t.getItemVisual(n,u),f=wP(u);if(this[f]!==c){this.remove(this.childOfName(u));var h=DP(u,t,n);this.add(h)}this[f]=c},this),this._updateCommonStl(t,n,a)},e.prototype.getLinePath=function(){return this.childAt(0)},e.prototype._updateCommonStl=function(t,n,a){var i=t.hostModel,o=this.childOfName("line"),s=a&&a.emphasisLineStyle,l=a&&a.blurLineStyle,u=a&&a.selectLineStyle,c=a&&a.labelStatesModels,f=a&&a.emphasisDisabled,h=a&&a.focus,v=a&&a.blurScope;if(!a||t.hasItemOption){var d=t.getItemModel(n),p=d.getModel("emphasis");s=p.getModel("lineStyle").getLineStyle(),l=d.getModel(["blur","lineStyle"]).getLineStyle(),u=d.getModel(["select","lineStyle"]).getLineStyle(),f=p.get("disabled"),h=p.get("focus"),v=p.get("blurScope"),c=sr(d)}var g=t.getItemVisual(n,"style"),y=g.stroke;o.useStyle(g),o.style.fill=null,o.style.strokeNoScale=!0,o.ensureState("emphasis").style=s,o.ensureState("blur").style=l,o.ensureState("select").style=u,C(tM,function(M){var w=this.childOfName(M);if(w){w.setColor(y),w.style.opacity=g.opacity;for(var D=0;D<Qr.length;D++){var T=Qr[D],I=o.getState(T);if(I){var A=I.style||{},N=w.ensureState(T),L=N.style||(N.style={});A.stroke!=null&&(L[w.__isEmptyBrush?"stroke":"fill"]=A.stroke),A.opacity!=null&&(L.opacity=A.opacity)}}w.markRedraw()}},this);var m=i.getRawValue(n);wr(this,c,{labelDataIndex:n,labelFetcher:{getFormattedLabel:function(M,w){return i.getFormattedLabel(M,w,t.dataType)}},inheritColor:y||"#000",defaultOpacity:g.opacity,defaultText:(m==null?t.getName(n):isFinite(m)?Nt(m):m)+""});var _=this.getTextContent();if(_){var b=c.normal;_.__align=_.style.align,_.__verticalAlign=_.style.verticalAlign,_.__position=b.get("position")||"middle";var x=b.get("distance");J(x)||(x=[x,x]),_.__labelDistance=x}this.setTextConfig({position:null,local:!0,inside:!1}),Lt(this,h,v,f)},e.prototype.highlight=function(){mi(this)},e.prototype.downplay=function(){_i(this)},e.prototype.updateLayout=function(t,n){this.setLinePoints(t.getItemLayout(n))},e.prototype.setLinePoints=function(t){var n=this.childOfName("line");rM(n.shape,t),n.dirty()},e.prototype.beforeUpdate=function(){var t=this,n=t.childOfName("fromSymbol"),a=t.childOfName("toSymbol"),i=t.getTextContent();if(!n&&!a&&(!i||i.ignore))return;for(var o=1,s=this.parent;s;)s.scaleX&&(o/=s.scaleX),s=s.parent;var l=t.childOfName("line");if(!this.__dirty&&!l.__dirty)return;var u=l.shape.percent,c=l.pointAt(0),f=l.pointAt(u),h=Yi([],f,c);Yo(h,h);function v(I,A){var N=I.__specifiedRotation;if(N==null){var L=l.tangentAt(A);I.attr("rotation",(A===1?-1:1)*Math.PI/2-Math.atan2(L[1],L[0]))}else I.attr("rotation",N)}if(n&&(n.setPosition(c),v(n,0),n.scaleX=n.scaleY=o*u,n.markRedraw()),a&&(a.setPosition(f),v(a,1),a.scaleX=a.scaleY=o*u,a.markRedraw()),i&&!i.ignore){i.x=i.y=0,i.originX=i.originY=0;var d=void 0,p=void 0,g=i.__labelDistance,y=g[0]*o,m=g[1]*o,_=u/2,b=l.tangentAt(_),x=[b[1],-b[0]],M=l.pointAt(_);x[1]>0&&(x[0]=-x[0],x[1]=-x[1]);var w=b[0]<0?-1:1;if(i.__position!=="start"&&i.__position!=="end"){var D=-Math.atan2(b[1],b[0]);f[0]<c[0]&&(D=Math.PI+D),i.rotation=D}var T=void 0;switch(i.__position){case"insideStartTop":case"insideMiddleTop":case"insideEndTop":case"middle":T=-m,p="bottom";break;case"insideStartBottom":case"insideMiddleBottom":case"insideEndBottom":T=m,p="top";break;default:T=0,p="middle"}switch(i.__position){case"end":i.x=h[0]*y+f[0],i.y=h[1]*m+f[1],d=h[0]>.8?"left":h[0]<-.8?"right":"center",p=h[1]>.8?"top":h[1]<-.8?"bottom":"middle";break;case"start":i.x=-h[0]*y+c[0],i.y=-h[1]*m+c[1],d=h[0]>.8?"right":h[0]<-.8?"left":"center",p=h[1]>.8?"bottom":h[1]<-.8?"top":"middle";break;case"insideStartTop":case"insideStart":case"insideStartBottom":i.x=y*w+c[0],i.y=c[1]+T,d=b[0]<0?"right":"left",i.originX=-y*w,i.originY=-T;break;case"insideMiddleTop":case"insideMiddle":case"insideMiddleBottom":case"middle":i.x=M[0],i.y=M[1]+T,d="center",i.originY=-T;break;case"insideEndTop":case"insideEnd":case"insideEndBottom":i.x=-y*w+f[0],i.y=f[1]+T,d=b[0]>=0?"right":"left",i.originX=y*w,i.originY=-T;break}i.scaleX=i.scaleY=o,i.setStyle({verticalAlign:i.__verticalAlign||p,align:i.__align||d})}},e}(De),nM=PX,zX=function(){function r(e){this.group=new De,this._LineCtor=e||nM}return r.prototype.updateData=function(e){var t=this;this._progressiveEls=null;var n=this,a=n.group,i=n._lineData;n._lineData=e,i||a.removeAll();var o=SP(e);e.diff(i).add(function(s){t._doAdd(e,s,o)}).update(function(s,l){t._doUpdate(i,e,l,s,o)}).remove(function(s){a.remove(i.getItemGraphicEl(s))}).execute()},r.prototype.updateLayout=function(){var e=this._lineData;!e||e.eachItemGraphicEl(function(t,n){t.updateLayout(e,n)},this)},r.prototype.incrementalPrepareUpdate=function(e){this._seriesScope=SP(e),this._lineData=null,this.group.removeAll()},r.prototype.incrementalUpdate=function(e,t){this._progressiveEls=[];function n(s){!s.isGroup&&!kX(s)&&(s.incremental=!0,s.ensureState("emphasis").hoverLayer=!0)}for(var a=e.start;a<e.end;a++){var i=t.getItemLayout(a);if(aM(i)){var o=new this._LineCtor(t,a,this._seriesScope);o.traverse(n),this.group.add(o),t.setItemGraphicEl(a,o),this._progressiveEls.push(o)}}},r.prototype.remove=function(){this.group.removeAll()},r.prototype.eachRendered=function(e){uo(this._progressiveEls||this.group,e)},r.prototype._doAdd=function(e,t,n){var a=e.getItemLayout(t);if(!!aM(a)){var i=new this._LineCtor(e,t,n);e.setItemGraphicEl(t,i),this.group.add(i)}},r.prototype._doUpdate=function(e,t,n,a,i){var o=e.getItemGraphicEl(n);if(!aM(t.getItemLayout(a))){this.group.remove(o);return}o?o.updateData(t,a,i):o=new this._LineCtor(t,a,i),t.setItemGraphicEl(a,o),this.group.add(o)},r}();function kX(r){return r.animators&&r.animators.length>0}function SP(r){var e=r.hostModel,t=e.getModel("emphasis");return{lineStyle:e.getModel("lineStyle").getLineStyle(),emphasisLineStyle:t.getModel(["lineStyle"]).getLineStyle(),blurLineStyle:e.getModel(["blur","lineStyle"]).getLineStyle(),selectLineStyle:e.getModel(["select","lineStyle"]).getLineStyle(),emphasisDisabled:t.get("disabled"),blurScope:t.get("blurScope"),focus:t.get("focus"),labelStatesModels:sr(e)}}function IP(r){return isNaN(r[0])||isNaN(r[1])}function aM(r){return r&&!IP(r[0])&&!IP(r[1])}var iM=zX,oM=[],sM=[],lM=[],Cu=dr,uM=Qi,TP=Math.abs;function AP(r,e,t){for(var n=r[0],a=r[1],i=r[2],o=1/0,s,l=t*t,u=.1,c=.1;c<=.9;c+=.1){oM[0]=Cu(n[0],a[0],i[0],c),oM[1]=Cu(n[1],a[1],i[1],c);var f=TP(uM(oM,e)-l);f<o&&(o=f,s=c)}for(var h=0;h<32;h++){var v=s+u;sM[0]=Cu(n[0],a[0],i[0],s),sM[1]=Cu(n[1],a[1],i[1],s),lM[0]=Cu(n[0],a[0],i[0],v),lM[1]=Cu(n[1],a[1],i[1],v);var f=uM(sM,e)-l;if(TP(f)<.01)break;var d=uM(lM,e)-l;u/=2,f<0?d>=0?s=s+u:s=s-u:d>=0?s=s-u:s=s+u}return s}function cM(r,e){var t=[],n=Ac,a=[[],[],[]],i=[[],[]],o=[];e/=2,r.eachEdge(function(s,l){var u=s.getLayout(),c=s.getVisual("fromSymbol"),f=s.getVisual("toSymbol");u.__original||(u.__original=[Oa(u[0]),Oa(u[1])],u[2]&&u.__original.push(Oa(u[2])));var h=u.__original;if(u[2]!=null){if(Or(a[0],h[0]),Or(a[1],h[2]),Or(a[2],h[1]),c&&c!=="none"){var v=ch(s.node1),d=AP(a,h[0],v*e);n(a[0][0],a[1][0],a[2][0],d,t),a[0][0]=t[3],a[1][0]=t[4],n(a[0][1],a[1][1],a[2][1],d,t),a[0][1]=t[3],a[1][1]=t[4]}if(f&&f!=="none"){var v=ch(s.node2),d=AP(a,h[1],v*e);n(a[0][0],a[1][0],a[2][0],d,t),a[1][0]=t[1],a[2][0]=t[2],n(a[0][1],a[1][1],a[2][1],d,t),a[1][1]=t[1],a[2][1]=t[2]}Or(u[0],a[0]),Or(u[1],a[2]),Or(u[2],a[1])}else{if(Or(i[0],h[0]),Or(i[1],h[1]),Yi(o,i[1],i[0]),Yo(o,o),c&&c!=="none"){var v=ch(s.node1);Av(i[0],i[0],o,v*e)}if(f&&f!=="none"){var v=ch(s.node2);Av(i[1],i[1],o,-v*e)}Or(u[0],i[0]),Or(u[1],i[1])}})}function CP(r){return r.type==="view"}var RX=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,n){var a=new $f,i=new iM,o=this.group;this._controller=new Xf(n.getZr()),this._controllerHost={target:o},o.add(a.group),o.add(i.group),this._symbolDraw=a,this._lineDraw=i,this._firstRender=!0},e.prototype.render=function(t,n,a){var i=this,o=t.coordinateSystem;this._model=t;var s=this._symbolDraw,l=this._lineDraw,u=this.group;if(CP(o)){var c={x:o.x,y:o.y,scaleX:o.scaleX,scaleY:o.scaleY};this._firstRender?u.attr(c):Qe(u,c,t)}cM(t.getGraph(),uh(t));var f=t.getData();s.updateData(f);var h=t.getEdgeData();l.updateData(h),this._updateNodeAndLinkScale(),this._updateController(t,n,a),clearTimeout(this._layoutTimeout);var v=t.forceLayout,d=t.get(["force","layoutAnimation"]);v&&this._startForceLayoutIteration(v,d);var p=t.get("layout");f.graph.eachNode(function(_){var b=_.dataIndex,x=_.getGraphicEl(),M=_.getModel();if(!!x){x.off("drag").off("dragend");var w=M.get("draggable");w&&x.on("drag",function(T){switch(p){case"force":v.warmUp(),!i._layouting&&i._startForceLayoutIteration(v,d),v.setFixed(b),f.setItemLayout(b,[x.x,x.y]);break;case"circular":f.setItemLayout(b,[x.x,x.y]),_.setLayout({fixed:!0},!0),Jb(t,"symbolSize",_,[T.offsetX,T.offsetY]),i.updateLayout(t);break;case"none":default:f.setItemLayout(b,[x.x,x.y]),qb(t.getGraph(),t),i.updateLayout(t);break}}).on("dragend",function(){v&&v.setUnfixed(b)}),x.setDraggable(w,!!M.get("cursor"));var D=M.get(["emphasis","focus"]);D==="adjacency"&&(Te(x).focus=_.getAdjacentDataIndices())}}),f.graph.eachEdge(function(_){var b=_.getGraphicEl(),x=_.getModel().get(["emphasis","focus"]);!b||x==="adjacency"&&(Te(b).focus={edge:[_.dataIndex],node:[_.node1.dataIndex,_.node2.dataIndex]})});var g=t.get("layout")==="circular"&&t.get(["circular","rotateLabel"]),y=f.getLayout("cx"),m=f.getLayout("cy");f.graph.eachNode(function(_){bP(_,g,y,m)}),this._firstRender=!1},e.prototype.dispose=function(){this._controller&&this._controller.dispose(),this._controllerHost=null},e.prototype._startForceLayoutIteration=function(t,n){var a=this;(function i(){t.step(function(o){a.updateLayout(a._model),(a._layouting=!o)&&(n?a._layoutTimeout=setTimeout(i,16):i())})})()},e.prototype._updateController=function(t,n,a){var i=this,o=this._controller,s=this._controllerHost,l=this.group;if(o.setPointerChecker(function(u,c,f){var h=l.getBoundingRect();return h.applyTransform(l.transform),h.contain(c,f)&&!Fp(u,a,t)}),!CP(t.coordinateSystem)){o.disable();return}o.enable(t.get("roam")),s.zoomLimit=t.get("scaleLimit"),s.zoom=t.coordinateSystem.getZoom(),o.off("pan").off("zoom").on("pan",function(u){Sb(s,u.dx,u.dy),a.dispatchAction({seriesId:t.id,type:"graphRoam",dx:u.dx,dy:u.dy})}).on("zoom",function(u){Ib(s,u.scale,u.originX,u.originY),a.dispatchAction({seriesId:t.id,type:"graphRoam",zoom:u.scale,originX:u.originX,originY:u.originY}),i._updateNodeAndLinkScale(),cM(t.getGraph(),uh(t)),i._lineDraw.updateLayout(),a.updateLabelLayout()})},e.prototype._updateNodeAndLinkScale=function(){var t=this._model,n=t.getData(),a=uh(t);n.eachItemGraphicEl(function(i,o){i&&i.setSymbolScale(a)})},e.prototype.updateLayout=function(t){cM(t.getGraph(),uh(t)),this._symbolDraw.updateLayout(),this._lineDraw.updateLayout()},e.prototype.remove=function(t,n){this._symbolDraw&&this._symbolDraw.remove(),this._lineDraw&&this._lineDraw.remove()},e.type="graph",e}(ht),jX=RX;function Nu(r){return"_EC_"+r}var BX=function(){function r(e){this.type="graph",this.nodes=[],this.edges=[],this._nodesMap={},this._edgesMap={},this._directed=e||!1}return r.prototype.isDirected=function(){return this._directed},r.prototype.addNode=function(e,t){e=e==null?""+t:""+e;var n=this._nodesMap;if(!n[Nu(e)]){var a=new Zs(e,t);return a.hostGraph=this,this.nodes.push(a),n[Nu(e)]=a,a}},r.prototype.getNodeByIndex=function(e){var t=this.data.getRawIndex(e);return this.nodes[t]},r.prototype.getNodeById=function(e){return this._nodesMap[Nu(e)]},r.prototype.addEdge=function(e,t,n){var a=this._nodesMap,i=this._edgesMap;if(Ue(e)&&(e=this.nodes[e]),Ue(t)&&(t=this.nodes[t]),e instanceof Zs||(e=a[Nu(e)]),t instanceof Zs||(t=a[Nu(t)]),!(!e||!t)){var o=e.id+"-"+t.id,s=new NP(e,t,n);return s.hostGraph=this,this._directed&&(e.outEdges.push(s),t.inEdges.push(s)),e.edges.push(s),e!==t&&t.edges.push(s),this.edges.push(s),i[o]=s,s}},r.prototype.getEdgeByIndex=function(e){var t=this.edgeData.getRawIndex(e);return this.edges[t]},r.prototype.getEdge=function(e,t){e instanceof Zs&&(e=e.id),t instanceof Zs&&(t=t.id);var n=this._edgesMap;return this._directed?n[e+"-"+t]:n[e+"-"+t]||n[t+"-"+e]},r.prototype.eachNode=function(e,t){for(var n=this.nodes,a=n.length,i=0;i<a;i++)n[i].dataIndex>=0&&e.call(t,n[i],i)},r.prototype.eachEdge=function(e,t){for(var n=this.edges,a=n.length,i=0;i<a;i++)n[i].dataIndex>=0&&n[i].node1.dataIndex>=0&&n[i].node2.dataIndex>=0&&e.call(t,n[i],i)},r.prototype.breadthFirstTraverse=function(e,t,n,a){if(t instanceof Zs||(t=this._nodesMap[Nu(t)]),!!t){for(var i=n==="out"?"outEdges":n==="in"?"inEdges":"edges",o=0;o<this.nodes.length;o++)this.nodes[o].__visited=!1;if(!e.call(a,t,null))for(var s=[t];s.length;)for(var l=s.shift(),u=l[i],o=0;o<u.length;o++){var c=u[o],f=c.node1===l?c.node2:c.node1;if(!f.__visited){if(e.call(a,f,l))return;s.push(f),f.__visited=!0}}}},r.prototype.update=function(){for(var e=this.data,t=this.edgeData,n=this.nodes,a=this.edges,i=0,o=n.length;i<o;i++)n[i].dataIndex=-1;for(var i=0,o=e.count();i<o;i++)n[e.getRawIndex(i)].dataIndex=i;t.filterSelf(function(s){var l=a[t.getRawIndex(s)];return l.node1.dataIndex>=0&&l.node2.dataIndex>=0});for(var i=0,o=a.length;i<o;i++)a[i].dataIndex=-1;for(var i=0,o=t.count();i<o;i++)a[t.getRawIndex(i)].dataIndex=i},r.prototype.clone=function(){for(var e=new r(this._directed),t=this.nodes,n=this.edges,a=0;a<t.length;a++)e.addNode(t[a].id,t[a].dataIndex);for(var a=0;a<n.length;a++){var i=n[a];e.addEdge(i.node1.id,i.node2.id,i.dataIndex)}return e},r}(),Zs=function(){function r(e,t){this.inEdges=[],this.outEdges=[],this.edges=[],this.dataIndex=-1,this.id=e==null?"":e,this.dataIndex=t==null?-1:t}return r.prototype.degree=function(){return this.edges.length},r.prototype.inDegree=function(){return this.inEdges.length},r.prototype.outDegree=function(){return this.outEdges.length},r.prototype.getModel=function(e){if(!(this.dataIndex<0)){var t=this.hostGraph,n=t.data.getItemModel(this.dataIndex);return n.getModel(e)}},r.prototype.getAdjacentDataIndices=function(){for(var e={edge:[],node:[]},t=0;t<this.edges.length;t++){var n=this.edges[t];n.dataIndex<0||(e.edge.push(n.dataIndex),e.node.push(n.node1.dataIndex,n.node2.dataIndex))}return e},r}(),NP=function(){function r(e,t,n){this.dataIndex=-1,this.node1=e,this.node2=t,this.dataIndex=n==null?-1:n}return r.prototype.getModel=function(e){if(!(this.dataIndex<0)){var t=this.hostGraph,n=t.edgeData.getItemModel(this.dataIndex);return n.getModel(e)}},r.prototype.getAdjacentDataIndices=function(){return{edge:[this.dataIndex],node:[this.node1.dataIndex,this.node2.dataIndex]}},r}();function LP(r,e){return{getValue:function(t){var n=this[r][e];return n.getStore().get(n.getDimensionIndex(t||"value"),this.dataIndex)},setVisual:function(t,n){this.dataIndex>=0&&this[r][e].setItemVisual(this.dataIndex,t,n)},getVisual:function(t){return this[r][e].getItemVisual(this.dataIndex,t)},setLayout:function(t,n){this.dataIndex>=0&&this[r][e].setItemLayout(this.dataIndex,t,n)},getLayout:function(){return this[r][e].getItemLayout(this.dataIndex)},getGraphicEl:function(){return this[r][e].getItemGraphicEl(this.dataIndex)},getRawIndex:function(){return this[r][e].getRawIndex(this.dataIndex)}}}Et(Zs,LP("hostGraph","data")),Et(NP,LP("hostGraph","edgeData"));var FX=BX;function EP(r,e,t,n,a){for(var i=new FX(n),o=0;o<r.length;o++)i.addNode(ar(r[o].id,r[o].name,o),o);for(var s=[],l=[],u=0,o=0;o<e.length;o++){var c=e[o],f=c.source,h=c.target;i.addEdge(f,h,u)&&(l.push(c),s.push(ar(Kt(c.id,null),f+" > "+h)),u++)}var v=t.get("coordinateSystem"),d;if(v==="cartesian2d"||v==="polar")d=Ua(r,t);else{var p=uu.get(v),g=p?p.dimensions||[]:[];ze(g,"value")<0&&g.concat(["value"]);var y=_u(r,{coordDimensions:g,encodeDefine:t.getEncode()}).dimensions;d=new jr(y,t),d.initData(r)}var m=new jr(["value"],t);return m.initData(l,s),a&&a(d,m),YO({mainData:d,struct:i,structAttr:"graph",datas:{node:d,edge:m},datasAttr:{node:"data",edge:"edgeData"}}),i.update(),i}var VX=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t}return e.prototype.init=function(t){r.prototype.init.apply(this,arguments);var n=this;function a(){return n._categoriesData}this.legendVisualProvider=new Qf(a,a),this.fillDataTextStyle(t.edges||t.links),this._updateCategoriesData()},e.prototype.mergeOption=function(t){r.prototype.mergeOption.apply(this,arguments),this.fillDataTextStyle(t.edges||t.links),this._updateCategoriesData()},e.prototype.mergeDefaultAndTheme=function(t){r.prototype.mergeDefaultAndTheme.apply(this,arguments),ns(t,"edgeLabel",["show"])},e.prototype.getInitialData=function(t,n){var a=t.edges||t.links||[],i=t.data||t.nodes||[],o=this;if(i&&a){xX(this);var s=EP(i,a,this,!0,l);return C(s.edges,function(u){wX(u.node1,u.node2,this,u.dataIndex)},this),s.data}function l(u,c){u.wrapMethod("getItemModel",function(d){var p=o._categoriesModels,g=d.getShallow("category"),y=p[g];return y&&(y.parentModel=d.parentModel,d.parentModel=y),d});var f=ft.prototype.getModel;function h(d,p){var g=f.call(this,d,p);return g.resolveParentPath=v,g}c.wrapMethod("getItemModel",function(d){return d.resolveParentPath=v,d.getModel=h,d});function v(d){if(d&&(d[0]==="label"||d[1]==="label")){var p=d.slice();return d[0]==="label"?p[0]="edgeLabel":d[1]==="label"&&(p[1]="edgeLabel"),p}return d}}},e.prototype.getGraph=function(){return this.getData().graph},e.prototype.getEdgeData=function(){return this.getGraph().edgeData},e.prototype.getCategoriesData=function(){return this._categoriesData},e.prototype.formatTooltip=function(t,n,a){if(a==="edge"){var i=this.getData(),o=this.getDataParams(t,a),s=i.graph.getEdgeByIndex(t),l=i.getName(s.node1.dataIndex),u=i.getName(s.node2.dataIndex),c=[];return l!=null&&c.push(l),u!=null&&c.push(u),lr("nameValue",{name:c.join(" > "),value:o.value,noValue:o.value==null})}var f=gN({series:this,dataIndex:t,multipleSeries:n});return f},e.prototype._updateCategoriesData=function(){var t=K(this.option.categories||[],function(a){return a.value!=null?a:X({value:0},a)}),n=new jr(["value"],this);n.initData(t),this._categoriesData=n,this._categoriesModels=n.mapArray(function(a){return n.getItemModel(a)})},e.prototype.setZoom=function(t){this.option.zoom=t},e.prototype.setCenter=function(t){this.option.center=t},e.prototype.isAnimationEnabled=function(){return r.prototype.isAnimationEnabled.call(this)&&!(this.get("layout")==="force"&&this.get(["force","layoutAnimation"]))},e.type="series.graph",e.dependencies=["grid","polar","geo","singleAxis","calendar"],e.defaultOption={z:2,coordinateSystem:"view",legendHoverLink:!0,layout:null,circular:{rotateLabel:!1},force:{initLayout:null,repulsion:[0,50],gravity:.1,friction:.6,edgeLength:30,layoutAnimation:!0},left:"center",top:"center",symbol:"circle",symbolSize:10,edgeSymbol:["none","none"],edgeSymbolSize:10,edgeLabel:{position:"middle",distance:5},draggable:!1,roam:!1,center:null,zoom:1,nodeScaleRatio:.6,label:{show:!1,formatter:"{b}"},itemStyle:{},lineStyle:{color:"#aaa",width:1,opacity:.5},emphasis:{scale:!0,label:{show:!0}},select:{itemStyle:{borderColor:"#212121"}}},e}(bt),HX=VX,WX={type:"graphRoam",event:"graphRoam",update:"none"};function GX(r){r.registerChartView(jX),r.registerSeriesModel(HX),r.registerProcessor(yX),r.registerVisual(mX),r.registerVisual(_X),r.registerLayout(DX),r.registerLayout(r.PRIORITY.VISUAL.POST_CHART_LAYOUT,IX),r.registerLayout(AX),r.registerCoordinateSystem("graphView",{dimensions:Kf.dimensions,create:NX}),r.registerAction({type:"focusNodeAdjacency",event:"focusNodeAdjacency",update:"series:focusNodeAdjacency"},Ot),r.registerAction({type:"unfocusNodeAdjacency",event:"unfocusNodeAdjacency",update:"series:unfocusNodeAdjacency"},Ot),r.registerAction(WX,function(e,t,n){t.eachComponent({mainType:"series",query:e},function(a){var i=a.coordinateSystem,o=Lb(i,e,void 0,n);a.setCenter&&a.setCenter(o.center),a.setZoom&&a.setZoom(o.zoom)})})}var $X=function(){function r(){this.angle=0,this.width=10,this.r=10,this.x=0,this.y=0}return r}(),UX=function(r){U(e,r);function e(t){var n=r.call(this,t)||this;return n.type="pointer",n}return e.prototype.getDefaultShape=function(){return new $X},e.prototype.buildPath=function(t,n){var a=Math.cos,i=Math.sin,o=n.r,s=n.width,l=n.angle,u=n.x-a(l)*s*(s>=o/3?1:2),c=n.y-i(l)*s*(s>=o/3?1:2);l=n.angle-Math.PI/2,t.moveTo(u,c),t.lineTo(n.x+a(l)*s,n.y+i(l)*s),t.lineTo(n.x+a(n.angle)*o,n.y+i(n.angle)*o),t.lineTo(n.x-a(l)*s,n.y-i(l)*s),t.lineTo(u,c)},e}(je),YX=UX;function QX(r,e){var t=r.get("center"),n=e.getWidth(),a=e.getHeight(),i=Math.min(n,a),o=ue(t[0],e.getWidth()),s=ue(t[1],e.getHeight()),l=ue(r.get("radius"),i/2);return{cx:o,cy:s,r:l}}function Kp(r,e){var t=r==null?"":r+"";return e&&(ce(e)?t=e.replace("{value}",t):ye(e)&&(t=e(r))),t}var ZX=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a){this.group.removeAll();var i=t.get(["axisLine","lineStyle","color"]),o=QX(t,a);this._renderMain(t,n,a,i,o),this._data=t.getData()},e.prototype.dispose=function(){},e.prototype._renderMain=function(t,n,a,i,o){var s=this.group,l=t.get("clockwise"),u=-t.get("startAngle")/180*Math.PI,c=-t.get("endAngle")/180*Math.PI,f=t.getModel("axisLine"),h=f.get("roundCap"),v=h?Op:Zr,d=f.get("show"),p=f.getModel("lineStyle"),g=p.get("width"),y=[u,c];xT(y,!l),u=y[0],c=y[1];for(var m=c-u,_=u,b=[],x=0;d&&x<i.length;x++){var M=Math.min(Math.max(i[x][0],0),1);c=u+m*M;var w=new v({shape:{startAngle:_,endAngle:c,cx:o.cx,cy:o.cy,clockwise:l,r0:o.r-g,r:o.r},silent:!0});w.setStyle({fill:i[x][1]}),w.setStyle(p.getLineStyle(["color","width"])),b.push(w),_=c}b.reverse(),C(b,function(T){return s.add(T)});var D=function(T){if(T<=0)return i[0][1];var I;for(I=0;I<i.length;I++)if(i[I][0]>=T&&(I===0?0:i[I-1][0])<T)return i[I][1];return i[I-1][1]};this._renderTicks(t,n,a,D,o,u,c,l,g),this._renderTitleAndDetail(t,n,a,D,o),this._renderAnchor(t,o),this._renderPointer(t,n,a,D,o,u,c,l,g)},e.prototype._renderTicks=function(t,n,a,i,o,s,l,u,c){for(var f=this.group,h=o.cx,v=o.cy,d=o.r,p=+t.get("min"),g=+t.get("max"),y=t.getModel("splitLine"),m=t.getModel("axisTick"),_=t.getModel("axisLabel"),b=t.get("splitNumber"),x=m.get("splitNumber"),M=ue(y.get("length"),d),w=ue(m.get("length"),d),D=s,T=(l-s)/b,I=T/x,A=y.getModel("lineStyle").getLineStyle(),N=m.getModel("lineStyle").getLineStyle(),L=y.get("distance"),E,O,P=0;P<=b;P++){if(E=Math.cos(D),O=Math.sin(D),y.get("show")){var H=L?L+c:c,F=new or({shape:{x1:E*(d-H)+h,y1:O*(d-H)+v,x2:E*(d-M-H)+h,y2:O*(d-M-H)+v},style:A,silent:!0});A.stroke==="auto"&&F.setStyle({stroke:i(P/b)}),f.add(F)}if(_.get("show")){var H=_.get("distance")+L,G=Kp(Nt(P/b*(g-p)+p),_.get("formatter")),Z=i(P/b),te=E*(d-M-H)+h,V=O*(d-M-H)+v,Y=_.get("rotate"),q=0;Y==="radial"?(q=-D+2*Math.PI,q>Math.PI/2&&(q+=Math.PI)):Y==="tangential"?q=-D-Math.PI/2:Ue(Y)&&(q=Y*Math.PI/180),q===0?f.add(new Ge({style:yt(_,{text:G,x:te,y:V,verticalAlign:O<-.8?"top":O>.8?"bottom":"middle",align:E<-.4?"left":E>.4?"right":"center"},{inheritColor:Z}),silent:!0})):f.add(new Ge({style:yt(_,{text:G,x:te,y:V,verticalAlign:"middle",align:"center"},{inheritColor:Z}),silent:!0,originX:te,originY:V,rotation:q}))}if(m.get("show")&&P!==b){var H=m.get("distance");H=H?H+c:c;for(var Q=0;Q<=x;Q++){E=Math.cos(D),O=Math.sin(D);var ne=new or({shape:{x1:E*(d-H)+h,y1:O*(d-H)+v,x2:E*(d-w-H)+h,y2:O*(d-w-H)+v},silent:!0,style:N});N.stroke==="auto"&&ne.setStyle({stroke:i((P+Q/x)/b)}),f.add(ne),D+=I}D-=I}else D+=T}},e.prototype._renderPointer=function(t,n,a,i,o,s,l,u,c){var f=this.group,h=this._data,v=this._progressEls,d=[],p=t.get(["pointer","show"]),g=t.getModel("progress"),y=g.get("show"),m=t.getData(),_=m.mapDimension("value"),b=+t.get("min"),x=+t.get("max"),M=[b,x],w=[s,l];function D(I,A){var N=m.getItemModel(I),L=N.getModel("pointer"),E=ue(L.get("width"),o.r),O=ue(L.get("length"),o.r),P=t.get(["pointer","icon"]),H=L.get("offsetCenter"),F=ue(H[0],o.r),G=ue(H[1],o.r),Z=L.get("keepAspect"),te;return P?te=Ft(P,F-E/2,G-O,E,O,null,Z):te=new YX({shape:{angle:-Math.PI/2,width:E,r:O,x:F,y:G}}),te.rotation=-(A+Math.PI/2),te.x=o.cx,te.y=o.cy,te}function T(I,A){var N=g.get("roundCap"),L=N?Op:Zr,E=g.get("overlap"),O=E?g.get("width"):c/m.count(),P=E?o.r-O:o.r-(I+1)*O,H=E?o.r:o.r-I*O,F=new L({shape:{startAngle:s,endAngle:A,cx:o.cx,cy:o.cy,clockwise:u,r0:P,r:H}});return E&&(F.z2=x-m.get(_,I)%x),F}(y||p)&&(m.diff(h).add(function(I){var A=m.get(_,I);if(p){var N=D(I,s);Dt(N,{rotation:-((isNaN(+A)?w[0]:st(A,M,w,!0))+Math.PI/2)},t),f.add(N),m.setItemGraphicEl(I,N)}if(y){var L=T(I,s),E=g.get("clip");Dt(L,{shape:{endAngle:st(A,M,w,E)}},t),f.add(L),Z0(t.seriesIndex,m.dataType,I,L),d[I]=L}}).update(function(I,A){var N=m.get(_,I);if(p){var L=h.getItemGraphicEl(A),E=L?L.rotation:s,O=D(I,E);O.rotation=E,Qe(O,{rotation:-((isNaN(+N)?w[0]:st(N,M,w,!0))+Math.PI/2)},t),f.add(O),m.setItemGraphicEl(I,O)}if(y){var P=v[A],H=P?P.shape.endAngle:s,F=T(I,H),G=g.get("clip");Qe(F,{shape:{endAngle:st(N,M,w,G)}},t),f.add(F),Z0(t.seriesIndex,m.dataType,I,F),d[I]=F}}).execute(),m.each(function(I){var A=m.getItemModel(I),N=A.getModel("emphasis"),L=N.get("focus"),E=N.get("blurScope"),O=N.get("disabled");if(p){var P=m.getItemGraphicEl(I),H=m.getItemVisual(I,"style"),F=H.fill;if(P instanceof pr){var G=P.style;P.useStyle(X({image:G.image,x:G.x,y:G.y,width:G.width,height:G.height},H))}else P.useStyle(H),P.type!=="pointer"&&P.setColor(F);P.setStyle(A.getModel(["pointer","itemStyle"]).getItemStyle()),P.style.fill==="auto"&&P.setStyle("fill",i(st(m.get(_,I),M,[0,1],!0))),P.z2EmphasisLift=0,xr(P,A),Lt(P,L,E,O)}if(y){var Z=d[I];Z.useStyle(m.getItemVisual(I,"style")),Z.setStyle(A.getModel(["progress","itemStyle"]).getItemStyle()),Z.z2EmphasisLift=0,xr(Z,A),Lt(Z,L,E,O)}}),this._progressEls=d)},e.prototype._renderAnchor=function(t,n){var a=t.getModel("anchor"),i=a.get("show");if(i){var o=a.get("size"),s=a.get("icon"),l=a.get("offsetCenter"),u=a.get("keepAspect"),c=Ft(s,n.cx-o/2+ue(l[0],n.r),n.cy-o/2+ue(l[1],n.r),o,o,null,u);c.z2=a.get("showAbove")?1:0,c.setStyle(a.getModel("itemStyle").getItemStyle()),this.group.add(c)}},e.prototype._renderTitleAndDetail=function(t,n,a,i,o){var s=this,l=t.getData(),u=l.mapDimension("value"),c=+t.get("min"),f=+t.get("max"),h=new De,v=[],d=[],p=t.isAnimationEnabled(),g=t.get(["pointer","showAbove"]);l.diff(this._data).add(function(y){v[y]=new Ge({silent:!0}),d[y]=new Ge({silent:!0})}).update(function(y,m){v[y]=s._titleEls[m],d[y]=s._detailEls[m]}).execute(),l.each(function(y){var m=l.getItemModel(y),_=l.get(u,y),b=new De,x=i(st(_,[c,f],[0,1],!0)),M=m.getModel("title");if(M.get("show")){var w=M.get("offsetCenter"),D=o.cx+ue(w[0],o.r),T=o.cy+ue(w[1],o.r),I=v[y];I.attr({z2:g?0:2,style:yt(M,{x:D,y:T,text:l.getName(y),align:"center",verticalAlign:"middle"},{inheritColor:x})}),b.add(I)}var A=m.getModel("detail");if(A.get("show")){var N=A.get("offsetCenter"),L=o.cx+ue(N[0],o.r),E=o.cy+ue(N[1],o.r),O=ue(A.get("width"),o.r),P=ue(A.get("height"),o.r),H=t.get(["progress","show"])?l.getItemVisual(y,"style").fill:x,I=d[y],F=A.get("formatter");I.attr({z2:g?0:2,style:yt(A,{x:L,y:E,text:Kp(_,F),width:isNaN(O)?null:O,height:isNaN(P)?null:P,align:"center",verticalAlign:"middle"},{inheritColor:H})}),YA(I,{normal:A},_,function(Z){return Kp(Z,F)}),p&&QA(I,y,l,t,{getFormattedLabel:function(Z,te,V,Y,q,Q){return Kp(Q?Q.interpolatedValue:_,F)}}),b.add(I)}h.add(b)}),this.group.add(h),this._titleEls=v,this._detailEls=d},e.type="gauge",e}(ht),qX=ZX,XX=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.visualStyleAccessPath="itemStyle",t}return e.prototype.getInitialData=function(t,n){return Su(this,["value"])},e.type="series.gauge",e.defaultOption={z:2,colorBy:"data",center:["50%","50%"],legendHoverLink:!0,radius:"75%",startAngle:225,endAngle:-45,clockwise:!0,min:0,max:100,splitNumber:10,axisLine:{show:!0,roundCap:!1,lineStyle:{color:[[1,"#E6EBF8"]],width:10}},progress:{show:!1,overlap:!0,width:10,roundCap:!1,clip:!0},splitLine:{show:!0,length:10,distance:10,lineStyle:{color:"#63677A",width:3,type:"solid"}},axisTick:{show:!0,splitNumber:5,length:6,distance:10,lineStyle:{color:"#63677A",width:1,type:"solid"}},axisLabel:{show:!0,distance:15,color:"#464646",fontSize:12,rotate:0},pointer:{icon:null,offsetCenter:[0,0],show:!0,showAbove:!0,length:"60%",width:6,keepAspect:!1},anchor:{show:!1,showAbove:!1,size:6,icon:"circle",offsetCenter:[0,0],keepAspect:!1,itemStyle:{color:"#fff",borderWidth:0,borderColor:"#5470c6"}},title:{show:!0,offsetCenter:[0,"20%"],color:"#464646",fontSize:16,valueAnimation:!1},detail:{show:!0,backgroundColor:"rgba(0,0,0,0)",borderWidth:0,borderColor:"#ccc",width:100,height:null,padding:[5,10],offsetCenter:[0,"40%"],color:"#464646",fontSize:30,fontWeight:"bold",lineHeight:30,valueAnimation:!1}},e}(bt),JX=XX;function KX(r){r.registerChartView(qX),r.registerSeriesModel(JX)}var eJ=["itemStyle","opacity"],tJ=function(r){U(e,r);function e(t,n){var a=r.call(this)||this,i=a,o=new Xr,s=new Ge;return i.setTextContent(s),a.setTextGuideLine(o),a.updateData(t,n,!0),a}return e.prototype.updateData=function(t,n,a){var i=this,o=t.hostModel,s=t.getItemModel(n),l=t.getItemLayout(n),u=s.getModel("emphasis"),c=s.get(eJ);c=c==null?1:c,a||ya(i),i.useStyle(t.getItemVisual(n,"style")),i.style.lineJoin="round",a?(i.setShape({points:l.points}),i.style.opacity=0,Dt(i,{style:{opacity:c}},o,n)):Qe(i,{style:{opacity:c},shape:{points:l.points}},o,n),xr(i,s),this._updateLabel(t,n),Lt(this,u.get("focus"),u.get("blurScope"),u.get("disabled"))},e.prototype._updateLabel=function(t,n){var a=this,i=this.getTextGuideLine(),o=a.getTextContent(),s=t.hostModel,l=t.getItemModel(n),u=t.getItemLayout(n),c=u.label,f=t.getItemVisual(n,"style"),h=f.fill;wr(o,sr(l),{labelFetcher:t.hostModel,labelDataIndex:n,defaultOpacity:f.opacity,defaultText:t.getName(n)},{normal:{align:c.textAlign,verticalAlign:c.verticalAlign}}),a.setTextConfig({local:!0,inside:!!c.inside,insideStroke:h,outsideFill:h});var v=c.linePoints;i.setShape({points:v}),a.textGuideLineConfig={anchor:v?new Oe(v[0][0],v[0][1]):null},Qe(o,{style:{x:c.x,y:c.y}},s,n),o.attr({rotation:c.rotation,originX:c.x,originY:c.y,z2:10}),U_(a,Y_(l),{stroke:h})},e}(qr),rJ=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.ignoreLabelLineUpdate=!0,t}return e.prototype.render=function(t,n,a){var i=t.getData(),o=this._data,s=this.group;i.diff(o).add(function(l){var u=new tJ(i,l);i.setItemGraphicEl(l,u),s.add(u)}).update(function(l,u){var c=o.getItemGraphicEl(u);c.updateData(i,l),s.add(c),i.setItemGraphicEl(l,c)}).remove(function(l){var u=o.getItemGraphicEl(l);af(u,t,l)}).execute(),this._data=i},e.prototype.remove=function(){this.group.removeAll(),this._data=null},e.prototype.dispose=function(){},e.type="funnel",e}(ht),nJ=rJ,aJ=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t){r.prototype.init.apply(this,arguments),this.legendVisualProvider=new Qf(fe(this.getData,this),fe(this.getRawData,this)),this._defaultLabelLine(t)},e.prototype.getInitialData=function(t,n){return Su(this,{coordDimensions:["value"],encodeDefaulter:Ae(P1,this)})},e.prototype._defaultLabelLine=function(t){ns(t,"labelLine",["show"]);var n=t.labelLine,a=t.emphasis.labelLine;n.show=n.show&&t.label.show,a.show=a.show&&t.emphasis.label.show},e.prototype.getDataParams=function(t){var n=this.getData(),a=r.prototype.getDataParams.call(this,t),i=n.mapDimension("value"),o=n.getSum(i);return a.percent=o?+(n.get(i,t)/o*100).toFixed(2):0,a.$vars.push("percent"),a},e.type="series.funnel",e.defaultOption={z:2,legendHoverLink:!0,colorBy:"data",left:80,top:60,right:80,bottom:60,minSize:"0%",maxSize:"100%",sort:"descending",orient:"vertical",gap:0,funnelAlign:"center",label:{show:!0,position:"outer"},labelLine:{show:!0,length:20,lineStyle:{width:1}},itemStyle:{borderColor:"#fff",borderWidth:1},emphasis:{label:{show:!0}},select:{itemStyle:{borderColor:"#212121"}}},e}(bt),iJ=aJ;function oJ(r,e){return Yt(r.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}function sJ(r,e){for(var t=r.mapDimension("value"),n=r.mapArray(t,function(l){return l}),a=[],i=e==="ascending",o=0,s=r.count();o<s;o++)a[o]=o;return ye(e)?a.sort(e):e!=="none"&&a.sort(function(l,u){return i?n[l]-n[u]:n[u]-n[l]}),a}function lJ(r){var e=r.hostModel,t=e.get("orient");r.each(function(n){var a=r.getItemModel(n),i=a.getModel("label"),o=i.get("position"),s=a.getModel("labelLine"),l=r.getItemLayout(n),u=l.points,c=o==="inner"||o==="inside"||o==="center"||o==="insideLeft"||o==="insideRight",f,h,v,d;if(c)o==="insideLeft"?(h=(u[0][0]+u[3][0])/2+5,v=(u[0][1]+u[3][1])/2,f="left"):o==="insideRight"?(h=(u[1][0]+u[2][0])/2-5,v=(u[1][1]+u[2][1])/2,f="right"):(h=(u[0][0]+u[1][0]+u[2][0]+u[3][0])/4,v=(u[0][1]+u[1][1]+u[2][1]+u[3][1])/4,f="center"),d=[[h,v],[h,v]];else{var p=void 0,g=void 0,y=void 0,m=void 0,_=s.get("length");o==="left"?(p=(u[3][0]+u[0][0])/2,g=(u[3][1]+u[0][1])/2,y=p-_,h=y-5,f="right"):o==="right"?(p=(u[1][0]+u[2][0])/2,g=(u[1][1]+u[2][1])/2,y=p+_,h=y+5,f="left"):o==="top"?(p=(u[3][0]+u[0][0])/2,g=(u[3][1]+u[0][1])/2,m=g-_,v=m-5,f="center"):o==="bottom"?(p=(u[1][0]+u[2][0])/2,g=(u[1][1]+u[2][1])/2,m=g+_,v=m+5,f="center"):o==="rightTop"?(p=t==="horizontal"?u[3][0]:u[1][0],g=t==="horizontal"?u[3][1]:u[1][1],t==="horizontal"?(m=g-_,v=m-5,f="center"):(y=p+_,h=y+5,f="top")):o==="rightBottom"?(p=u[2][0],g=u[2][1],t==="horizontal"?(m=g+_,v=m+5,f="center"):(y=p+_,h=y+5,f="bottom")):o==="leftTop"?(p=u[0][0],g=t==="horizontal"?u[0][1]:u[1][1],t==="horizontal"?(m=g-_,v=m-5,f="center"):(y=p-_,h=y-5,f="right")):o==="leftBottom"?(p=t==="horizontal"?u[1][0]:u[3][0],g=t==="horizontal"?u[1][1]:u[2][1],t==="horizontal"?(m=g+_,v=m+5,f="center"):(y=p-_,h=y-5,f="right")):(p=(u[1][0]+u[2][0])/2,g=(u[1][1]+u[2][1])/2,t==="horizontal"?(m=g+_,v=m+5,f="center"):(y=p+_,h=y+5,f="left")),t==="horizontal"?(y=p,h=y):(m=g,v=m),d=[[p,g],[y,m]]}l.label={linePoints:d,x:h,y:v,verticalAlign:"middle",textAlign:f,inside:c}})}function uJ(r,e){r.eachSeriesByType("funnel",function(t){var n=t.getData(),a=n.mapDimension("value"),i=t.get("sort"),o=oJ(t,e),s=t.get("orient"),l=o.width,u=o.height,c=sJ(n,i),f=o.x,h=o.y,v=s==="horizontal"?[ue(t.get("minSize"),u),ue(t.get("maxSize"),u)]:[ue(t.get("minSize"),l),ue(t.get("maxSize"),l)],d=n.getDataExtent(a),p=t.get("min"),g=t.get("max");p==null&&(p=Math.min(d[0],0)),g==null&&(g=d[1]);var y=t.get("funnelAlign"),m=t.get("gap"),_=s==="horizontal"?l:u,b=(_-m*(n.count()-1))/n.count(),x=function(E,O){if(s==="horizontal"){var P=n.get(a,E)||0,H=st(P,[p,g],v,!0),F=void 0;switch(y){case"top":F=h;break;case"center":F=h+(u-H)/2;break;case"bottom":F=h+(u-H);break}return[[O,F],[O,F+H]]}var G=n.get(a,E)||0,Z=st(G,[p,g],v,!0),te;switch(y){case"left":te=f;break;case"center":te=f+(l-Z)/2;break;case"right":te=f+l-Z;break}return[[te,O],[te+Z,O]]};i==="ascending"&&(b=-b,m=-m,s==="horizontal"?f+=l:h+=u,c=c.reverse());for(var M=0;M<c.length;M++){var w=c[M],D=c[M+1],T=n.getItemModel(w);if(s==="horizontal"){var I=T.get(["itemStyle","width"]);I==null?I=b:(I=ue(I,l),i==="ascending"&&(I=-I));var A=x(w,f),N=x(D,f+I);f+=I+m,n.setItemLayout(w,{points:A.concat(N.slice().reverse())})}else{var L=T.get(["itemStyle","height"]);L==null?L=b:(L=ue(L,u),i==="ascending"&&(L=-L));var A=x(w,h),N=x(D,h+L);h+=L+m,n.setItemLayout(w,{points:A.concat(N.slice().reverse())})}}lJ(n)})}function cJ(r){r.registerChartView(nJ),r.registerSeriesModel(iJ),r.registerLayout(uJ),r.registerProcessor(Yf("funnel"))}var fJ=.3,hJ=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._dataGroup=new De,t._initialized=!1,t}return e.prototype.init=function(){this.group.add(this._dataGroup)},e.prototype.render=function(t,n,a,i){this._progressiveEls=null;var o=this._dataGroup,s=t.getData(),l=this._data,u=t.coordinateSystem,c=u.dimensions,f=zP(t);s.diff(l).add(h).update(v).remove(d).execute();function h(g){var y=PP(s,o,g,c,u);fM(y,s,g,f)}function v(g,y){var m=l.getItemGraphicEl(y),_=OP(s,g,c,u);s.setItemGraphicEl(g,m),Qe(m,{shape:{points:_}},t,g),ya(m),fM(m,s,g,f)}function d(g){var y=l.getItemGraphicEl(g);o.remove(y)}if(!this._initialized){this._initialized=!0;var p=vJ(u,t,function(){setTimeout(function(){o.removeClipPath()})});o.setClipPath(p)}this._data=s},e.prototype.incrementalPrepareRender=function(t,n,a){this._initialized=!0,this._data=null,this._dataGroup.removeAll()},e.prototype.incrementalRender=function(t,n,a){for(var i=n.getData(),o=n.coordinateSystem,s=o.dimensions,l=zP(n),u=this._progressiveEls=[],c=t.start;c<t.end;c++){var f=PP(i,this._dataGroup,c,s,o);f.incremental=!0,fM(f,i,c,l),u.push(f)}},e.prototype.remove=function(){this._dataGroup&&this._dataGroup.removeAll(),this._data=null},e.type="parallel",e}(ht);function vJ(r,e,t){var n=r.model,a=r.getRect(),i=new We({shape:{x:a.x,y:a.y,width:a.width,height:a.height}}),o=n.get("layout")==="horizontal"?"width":"height";return i.setShape(o,0),Dt(i,{shape:{width:a.width,height:a.height}},e,t),i}function OP(r,e,t,n){for(var a=[],i=0;i<t.length;i++){var o=t[i],s=r.get(r.mapDimension(o),e);dJ(s,n.getAxis(o).type)||a.push(n.dataToPoint(s,o))}return a}function PP(r,e,t,n,a){var i=OP(r,t,n,a),o=new Xr({shape:{points:i},z2:10});return e.add(o),r.setItemGraphicEl(t,o),o}function zP(r){var e=r.get("smooth",!0);return e===!0&&(e=fJ),e=Ra(e),El(e)&&(e=0),{smooth:e}}function fM(r,e,t,n){r.useStyle(e.getItemVisual(t,"style")),r.style.fill=null,r.setShape("smooth",n.smooth);var a=e.getItemModel(t),i=a.getModel("emphasis");xr(r,a,"lineStyle"),Lt(r,i.get("focus"),i.get("blurScope"),i.get("disabled"))}function dJ(r,e){return e==="category"?r==null:r==null||isNaN(r)}var pJ=hJ,gJ=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.visualStyleAccessPath="lineStyle",t.visualDrawType="stroke",t}return e.prototype.getInitialData=function(t,n){return Ua(null,this,{useEncodeDefaulter:fe(yJ,null,this)})},e.prototype.getRawIndicesByActiveState=function(t){var n=this.coordinateSystem,a=this.getData(),i=[];return n.eachActiveState(a,function(o,s){t===o&&i.push(a.getRawIndex(s))}),i},e.type="series.parallel",e.dependencies=["parallel"],e.defaultOption={z:2,coordinateSystem:"parallel",parallelIndex:0,label:{show:!1},inactiveOpacity:.05,activeOpacity:1,lineStyle:{width:1,opacity:.45,type:"solid"},emphasis:{label:{show:!1}},progressive:500,smooth:!1,animationEasing:"linear"},e}(bt);function yJ(r){var e=r.ecModel.getComponent("parallel",r.get("parallelIndex"));if(!!e){var t={};return C(e.dimensions,function(n){var a=mJ(n);t[n]=a}),t}}function mJ(r){return+r.replace("dim","")}var _J=gJ,bJ=["lineStyle","opacity"],MJ={seriesType:"parallel",reset:function(r,e){var t=r.coordinateSystem,n={normal:r.get(["lineStyle","opacity"]),active:r.get("activeOpacity"),inactive:r.get("inactiveOpacity")};return{progress:function(a,i){t.eachActiveState(i,function(o,s){var l=n[o];if(o==="normal"&&i.hasItemOption){var u=i.getItemModel(s).get(bJ,!0);u!=null&&(l=u)}var c=i.ensureUniqueItemVisual(s,"style");c.opacity=l},a.start,a.end)}}}},xJ=MJ;function wJ(r){DJ(r),SJ(r)}function DJ(r){if(!r.parallel){var e=!1;C(r.series,function(t){t&&t.type==="parallel"&&(e=!0)}),e&&(r.parallel=[{}])}}function SJ(r){var e=ct(r.parallelAxis);C(e,function(t){if(!!_e(t)){var n=t.parallelIndex||0,a=ct(r.parallel)[n];a&&a.parallelAxisDefault&&Ne(t,a.parallelAxisDefault,!1)}})}var IJ=5,TJ=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a){this._model=t,this._api=a,this._handlers||(this._handlers={},C(AJ,function(i,o){a.getZr().on(o,this._handlers[o]=fe(i,this))},this)),vu(this,"_throttledDispatchExpand",t.get("axisExpandRate"),"fixRate")},e.prototype.dispose=function(t,n){xf(this,"_throttledDispatchExpand"),C(this._handlers,function(a,i){n.getZr().off(i,a)}),this._handlers=null},e.prototype._throttledDispatchExpand=function(t){this._dispatchExpand(t)},e.prototype._dispatchExpand=function(t){t&&this._api.dispatchAction(X({type:"parallelAxisExpand"},t))},e.type="parallel",e}(St),AJ={mousedown:function(r){hM(this,"click")&&(this._mouseDownPoint=[r.offsetX,r.offsetY])},mouseup:function(r){var e=this._mouseDownPoint;if(hM(this,"click")&&e){var t=[r.offsetX,r.offsetY],n=Math.pow(e[0]-t[0],2)+Math.pow(e[1]-t[1],2);if(n>IJ)return;var a=this._model.coordinateSystem.getSlidedAxisExpandWindow([r.offsetX,r.offsetY]);a.behavior!=="none"&&this._dispatchExpand({axisExpandWindow:a.axisExpandWindow})}this._mouseDownPoint=null},mousemove:function(r){if(!(this._mouseDownPoint||!hM(this,"mousemove"))){var e=this._model,t=e.coordinateSystem.getSlidedAxisExpandWindow([r.offsetX,r.offsetY]),n=t.behavior;n==="jump"&&this._throttledDispatchExpand.debounceNextCall(e.get("axisExpandDebounce")),this._throttledDispatchExpand(n==="none"?null:{axisExpandWindow:t.axisExpandWindow,animation:n==="jump"?null:{duration:0}})}}};function hM(r,e){var t=r._model;return t.get("axisExpandable")&&t.get("axisExpandTriggerOn")===e}var CJ=TJ,NJ=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(){r.prototype.init.apply(this,arguments),this.mergeOption({})},e.prototype.mergeOption=function(t){var n=this.option;t&&Ne(n,t,!0),this._initDimensions()},e.prototype.contains=function(t,n){var a=t.get("parallelIndex");return a!=null&&n.getComponent("parallel",a)===this},e.prototype.setAxisExpand=function(t){C(["axisExpandable","axisExpandCenter","axisExpandCount","axisExpandWidth","axisExpandWindow"],function(n){t.hasOwnProperty(n)&&(this.option[n]=t[n])},this)},e.prototype._initDimensions=function(){var t=this.dimensions=[],n=this.parallelAxisIndex=[],a=ot(this.ecModel.queryComponents({mainType:"parallelAxis"}),function(i){return(i.get("parallelIndex")||0)===this.componentIndex},this);C(a,function(i){t.push("dim"+i.get("dim")),n.push(i.componentIndex)})},e.type="parallel",e.dependencies=["parallelAxis"],e.layoutMode="box",e.defaultOption={z:0,left:80,top:60,right:80,bottom:60,layout:"horizontal",axisExpandable:!1,axisExpandCenter:null,axisExpandCount:0,axisExpandWidth:50,axisExpandRate:17,axisExpandDebounce:50,axisExpandSlideTriggerArea:[-.15,.05,.4],axisExpandTriggerOn:"click",parallelAxisDefault:null},e}(He),LJ=NJ,EJ=function(r){U(e,r);function e(t,n,a,i,o){var s=r.call(this,t,n,a)||this;return s.type=i||"value",s.axisIndex=o,s}return e.prototype.isHorizontal=function(){return this.coordinateSystem.getModel().get("layout")!=="horizontal"},e}(Yn),OJ=EJ;function qs(r,e,t,n,a,i){r=r||0;var o=t[1]-t[0];if(a!=null&&(a=Lu(a,[0,o])),i!=null&&(i=Math.max(i,a!=null?a:0)),n==="all"){var s=Math.abs(e[1]-e[0]);s=Lu(s,[0,o]),a=i=Lu(s,[a,i]),n=0}e[0]=Lu(e[0],t),e[1]=Lu(e[1],t);var l=vM(e,n);e[n]+=r;var u=a||0,c=t.slice();l.sign<0?c[0]+=u:c[1]-=u,e[n]=Lu(e[n],c);var f;return f=vM(e,n),a!=null&&(f.sign!==l.sign||f.span<a)&&(e[1-n]=e[n]+l.sign*a),f=vM(e,n),i!=null&&f.span>i&&(e[1-n]=e[n]+f.sign*i),e}function vM(r,e){var t=r[e]-r[1-e];return{span:Math.abs(t),sign:t>0?-1:t<0?1:e?-1:1}}function Lu(r,e){return Math.min(e[1]!=null?e[1]:1/0,Math.max(e[0]!=null?e[0]:-1/0,r))}var dM=C,kP=Math.min,RP=Math.max,jP=Math.floor,PJ=Math.ceil,BP=Nt,zJ=Math.PI,kJ=function(){function r(e,t,n){this.type="parallel",this._axesMap=ge(),this._axesLayout={},this.dimensions=e.dimensions,this._model=e,this._init(e,t,n)}return r.prototype._init=function(e,t,n){var a=e.dimensions,i=e.parallelAxisIndex;dM(a,function(o,s){var l=i[s],u=t.getComponent("parallelAxis",l),c=this._axesMap.set(o,new OJ(o,kf(u),[0,0],u.get("type"),l)),f=c.type==="category";c.onBand=f&&u.get("boundaryGap"),c.inverse=u.get("inverse"),u.axis=c,c.model=u,c.coordinateSystem=u.coordinateSystem=this},this)},r.prototype.update=function(e,t){this._updateAxesFromSeries(this._model,e)},r.prototype.containPoint=function(e){var t=this._makeLayoutInfo(),n=t.axisBase,a=t.layoutBase,i=t.pixelDimIndex,o=e[1-i],s=e[i];return o>=n&&o<=n+t.axisLength&&s>=a&&s<=a+t.layoutLength},r.prototype.getModel=function(){return this._model},r.prototype._updateAxesFromSeries=function(e,t){t.eachSeries(function(n){if(!!e.contains(n,t)){var a=n.getData();dM(this.dimensions,function(i){var o=this._axesMap.get(i);o.scale.unionExtentFromData(a,a.mapDimension(i)),Ps(o.scale,o.model)},this)}},this)},r.prototype.resize=function(e,t){this._rect=Yt(e.getBoxLayoutParams(),{width:t.getWidth(),height:t.getHeight()}),this._layoutAxes()},r.prototype.getRect=function(){return this._rect},r.prototype._makeLayoutInfo=function(){var e=this._model,t=this._rect,n=["x","y"],a=["width","height"],i=e.get("layout"),o=i==="horizontal"?0:1,s=t[a[o]],l=[0,s],u=this.dimensions.length,c=eg(e.get("axisExpandWidth"),l),f=eg(e.get("axisExpandCount")||0,[0,u]),h=e.get("axisExpandable")&&u>3&&u>f&&f>1&&c>0&&s>0,v=e.get("axisExpandWindow"),d;if(v)d=eg(v[1]-v[0],l),v[1]=v[0]+d;else{d=eg(c*(f-1),l);var p=e.get("axisExpandCenter")||jP(u/2);v=[c*p-d/2],v[1]=v[0]+d}var g=(s-d)/(u-f);g<3&&(g=0);var y=[jP(BP(v[0]/c,1))+1,PJ(BP(v[1]/c,1))-1],m=g/c*v[0];return{layout:i,pixelDimIndex:o,layoutBase:t[n[o]],layoutLength:s,axisBase:t[n[1-o]],axisLength:t[a[1-o]],axisExpandable:h,axisExpandWidth:c,axisCollapseWidth:g,axisExpandWindow:v,axisCount:u,winInnerIndices:y,axisExpandWindow0Pos:m}},r.prototype._layoutAxes=function(){var e=this._rect,t=this._axesMap,n=this.dimensions,a=this._makeLayoutInfo(),i=a.layout;t.each(function(o){var s=[0,a.axisLength],l=o.inverse?1:0;o.setExtent(s[l],s[1-l])}),dM(n,function(o,s){var l=(a.axisExpandable?jJ:RJ)(s,a),u={horizontal:{x:l.position,y:a.axisLength},vertical:{x:0,y:l.position}},c={horizontal:zJ/2,vertical:0},f=[u[i].x+e.x,u[i].y+e.y],h=c[i],v=yn();Zi(v,v,h),ua(v,v,f),this._axesLayout[o]={position:f,rotation:h,transform:v,axisNameAvailableWidth:l.axisNameAvailableWidth,axisLabelShow:l.axisLabelShow,nameTruncateMaxWidth:l.nameTruncateMaxWidth,tickDirection:1,labelDirection:1}},this)},r.prototype.getAxis=function(e){return this._axesMap.get(e)},r.prototype.dataToPoint=function(e,t){return this.axisCoordToPoint(this._axesMap.get(t).dataToCoord(e),t)},r.prototype.eachActiveState=function(e,t,n,a){n==null&&(n=0),a==null&&(a=e.count());var i=this._axesMap,o=this.dimensions,s=[],l=[];C(o,function(g){s.push(e.mapDimension(g)),l.push(i.get(g).model)});for(var u=this.hasAxisBrushed(),c=n;c<a;c++){var f=void 0;if(!u)f="normal";else{f="active";for(var h=e.getValues(s,c),v=0,d=o.length;v<d;v++){var p=l[v].getActiveState(h[v]);if(p==="inactive"){f="inactive";break}}}t(f,c)}},r.prototype.hasAxisBrushed=function(){for(var e=this.dimensions,t=this._axesMap,n=!1,a=0,i=e.length;a<i;a++)t.get(e[a]).model.getActiveState()!=="normal"&&(n=!0);return n},r.prototype.axisCoordToPoint=function(e,t){var n=this._axesLayout[t];return ma([e,0],n.transform)},r.prototype.getAxisLayout=function(e){return Me(this._axesLayout[e])},r.prototype.getSlidedAxisExpandWindow=function(e){var t=this._makeLayoutInfo(),n=t.pixelDimIndex,a=t.axisExpandWindow.slice(),i=a[1]-a[0],o=[0,t.axisExpandWidth*(t.axisCount-1)];if(!this.containPoint(e))return{behavior:"none",axisExpandWindow:a};var s=e[n]-t.layoutBase-t.axisExpandWindow0Pos,l,u="slide",c=t.axisCollapseWidth,f=this._model.get("axisExpandSlideTriggerArea"),h=f[0]!=null;if(c)h&&c&&s<i*f[0]?(u="jump",l=s-i*f[2]):h&&c&&s>i*(1-f[0])?(u="jump",l=s-i*(1-f[2])):(l=s-i*f[1])>=0&&(l=s-i*(1-f[1]))<=0&&(l=0),l*=t.axisExpandWidth/c,l?qs(l,a,o,"all"):u="none";else{var v=a[1]-a[0],d=o[1]*s/v;a=[RP(0,d-v/2)],a[1]=kP(o[1],a[0]+v),a[0]=a[1]-v}return{axisExpandWindow:a,behavior:u}},r}();function eg(r,e){return kP(RP(r,e[0]),e[1])}function RJ(r,e){var t=e.layoutLength/(e.axisCount-1);return{position:t*r,axisNameAvailableWidth:t,axisLabelShow:!0}}function jJ(r,e){var t=e.layoutLength,n=e.axisExpandWidth,a=e.axisCount,i=e.axisCollapseWidth,o=e.winInnerIndices,s,l=i,u=!1,c;return r<o[0]?(s=r*i,c=i):r<=o[1]?(s=e.axisExpandWindow0Pos+r*n-e.axisExpandWindow[0],l=n,u=!0):(s=t-(a-1-r)*i,c=i),{position:s,axisNameAvailableWidth:l,axisLabelShow:u,nameTruncateMaxWidth:c}}var BJ=kJ;function FJ(r,e){var t=[];return r.eachComponent("parallel",function(n,a){var i=new BJ(n,r,e);i.name="parallel_"+a,i.resize(n,e),n.coordinateSystem=i,i.model=n,t.push(i)}),r.eachSeries(function(n){if(n.get("coordinateSystem")==="parallel"){var a=n.getReferringComponents("parallel",Ut).models[0];n.coordinateSystem=a.coordinateSystem}}),t}var VJ={create:FJ},HJ=VJ,FP=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.activeIntervals=[],t}return e.prototype.getAreaSelectStyle=function(){return os([["fill","color"],["lineWidth","borderWidth"],["stroke","borderColor"],["width","width"],["opacity","opacity"]])(this.getModel("areaSelectStyle"))},e.prototype.setActiveIntervals=function(t){var n=this.activeIntervals=Me(t);if(n)for(var a=n.length-1;a>=0;a--)bn(n[a])},e.prototype.getActiveState=function(t){var n=this.activeIntervals;if(!n.length)return"normal";if(t==null||isNaN(+t))return"inactive";if(n.length===1){var a=n[0];if(a[0]<=t&&t<=a[1])return"active"}else for(var i=0,o=n.length;i<o;i++)if(n[i][0]<=t&&t<=n[i][1])return"active";return"inactive"},e}(He);Et(FP,Mu);var VP=FP,Xs=!0,fh=Math.min,Eu=Math.max,WJ=Math.pow,GJ=1e4,$J=6,UJ=6,HP="globalPan",YJ={w:[0,0],e:[0,1],n:[1,0],s:[1,1]},QJ={w:"ew",e:"ew",n:"ns",s:"ns",ne:"nesw",sw:"nesw",nw:"nwse",se:"nwse"},WP={brushStyle:{lineWidth:2,stroke:"rgba(210,219,238,0.3)",fill:"#D2DBEE"},transformable:!0,brushMode:"single",removeOnClick:!1},ZJ=0,qJ=function(r){U(e,r);function e(t){var n=r.call(this)||this;return n._track=[],n._covers=[],n._handlers={},n._zr=t,n.group=new De,n._uid="brushController_"+ZJ++,C(nK,function(a,i){this._handlers[i]=fe(a,this)},n),n}return e.prototype.enableBrush=function(t){return this._brushType&&this._doDisableBrush(),t.brushType&&this._doEnableBrush(t),this},e.prototype._doEnableBrush=function(t){var n=this._zr;this._enableGlobalPan||o6(n,HP,this._uid),C(this._handlers,function(a,i){n.on(i,a)}),this._brushType=t.brushType,this._brushOption=Ne(Me(WP),t,!0)},e.prototype._doDisableBrush=function(){var t=this._zr;s6(t,HP,this._uid),C(this._handlers,function(n,a){t.off(a,n)}),this._brushType=this._brushOption=null},e.prototype.setPanels=function(t){if(t&&t.length){var n=this._panels={};C(t,function(a){n[a.panelId]=Me(a)})}else this._panels=null;return this},e.prototype.mount=function(t){t=t||{},this._enableGlobalPan=t.enableGlobalPan;var n=this.group;return this._zr.add(n),n.attr({x:t.x||0,y:t.y||0,rotation:t.rotation||0,scaleX:t.scaleX||1,scaleY:t.scaleY||1}),this._transform=n.getLocalTransform(),this},e.prototype.updateCovers=function(t){t=K(t,function(h){return Ne(Me(WP),h,!0)});var n="\0-brush-index-",a=this._covers,i=this._covers=[],o=this,s=this._creatingCover;return new Mi(a,t,u,l).add(c).update(c).remove(f).execute(),this;function l(h,v){return(h.id!=null?h.id:n+v)+"-"+h.brushType}function u(h,v){return l(h.__brushOption,v)}function c(h,v){var d=t[h];if(v!=null&&a[v]===s)i[h]=a[v];else{var p=i[h]=v!=null?(a[v].__brushOption=d,a[v]):$P(o,GP(o,d));pM(o,p)}}function f(h){a[h]!==s&&o.group.remove(a[h])}},e.prototype.unmount=function(){return this.enableBrush(!1),mM(this),this._zr.remove(this.group),this},e.prototype.dispose=function(){this.unmount(),this.off()},e}(zn);function GP(r,e){var t=tg[e.brushType].createCover(r,e);return t.__brushOption=e,YP(t,e),r.group.add(t),t}function $P(r,e){var t=gM(e);return t.endCreating&&(t.endCreating(r,e),YP(e,e.__brushOption)),e}function UP(r,e){var t=e.__brushOption;gM(e).updateCoverShape(r,e,t.range,t)}function YP(r,e){var t=e.z;t==null&&(t=GJ),r.traverse(function(n){n.z=t,n.z2=t})}function pM(r,e){gM(e).updateCommon(r,e),UP(r,e)}function gM(r){return tg[r.__brushOption.brushType]}function yM(r,e,t){var n=r._panels;if(!n)return Xs;var a,i=r._transform;return C(n,function(o){o.isTargetByCursor(e,t,i)&&(a=o)}),a}function QP(r,e){var t=r._panels;if(!t)return Xs;var n=e.__brushOption.panelId;return n!=null?t[n]:Xs}function mM(r){var e=r._covers,t=e.length;return C(e,function(n){r.group.remove(n)},r),e.length=0,!!t}function Js(r,e){var t=K(r._covers,function(n){var a=n.__brushOption,i=Me(a.range);return{brushType:a.brushType,panelId:a.panelId,range:i}});r.trigger("brush",{areas:t,isEnd:!!e.isEnd,removeOnClick:!!e.removeOnClick})}function XJ(r){var e=r._track;if(!e.length)return!1;var t=e[e.length-1],n=e[0],a=t[0]-n[0],i=t[1]-n[1],o=WJ(a*a+i*i,.5);return o>$J}function ZP(r){var e=r.length-1;return e<0&&(e=0),[r[0],r[e]]}function qP(r,e,t,n){var a=new De;return a.add(new We({name:"main",style:bM(t),silent:!0,draggable:!0,cursor:"move",drift:Ae(KP,r,e,a,["n","s","w","e"]),ondragend:Ae(Js,e,{isEnd:!0})})),C(n,function(i){a.add(new We({name:i.join(""),style:{opacity:0},draggable:!0,silent:!0,invisible:!0,drift:Ae(KP,r,e,a,i),ondragend:Ae(Js,e,{isEnd:!0})}))}),a}function XP(r,e,t,n){var a=n.brushStyle.lineWidth||0,i=Eu(a,UJ),o=t[0][0],s=t[1][0],l=o-a/2,u=s-a/2,c=t[0][1],f=t[1][1],h=c-i+a/2,v=f-i+a/2,d=c-o,p=f-s,g=d+a,y=p+a;Ii(r,e,"main",o,s,d,p),n.transformable&&(Ii(r,e,"w",l,u,i,y),Ii(r,e,"e",h,u,i,y),Ii(r,e,"n",l,u,g,i),Ii(r,e,"s",l,v,g,i),Ii(r,e,"nw",l,u,i,i),Ii(r,e,"ne",h,u,i,i),Ii(r,e,"sw",l,v,i,i),Ii(r,e,"se",h,v,i,i))}function _M(r,e){var t=e.__brushOption,n=t.transformable,a=e.childAt(0);a.useStyle(bM(t)),a.attr({silent:!n,cursor:n?"move":"default"}),C([["w"],["e"],["n"],["s"],["s","e"],["s","w"],["n","e"],["n","w"]],function(i){var o=e.childOfName(i.join("")),s=i.length===1?MM(r,i[0]):KJ(r,i);o&&o.attr({silent:!n,invisible:!n,cursor:n?QJ[s]+"-resize":null})})}function Ii(r,e,t,n,a,i,o){var s=e.childOfName(t);s&&s.setShape(tK(xM(r,e,[[n,a],[n+i,a+o]])))}function bM(r){return me({strokeNoScale:!0},r.brushStyle)}function JP(r,e,t,n){var a=[fh(r,t),fh(e,n)],i=[Eu(r,t),Eu(e,n)];return[[a[0],i[0]],[a[1],i[1]]]}function JJ(r){return lo(r.group)}function MM(r,e){var t={w:"left",e:"right",n:"top",s:"bottom"},n={left:"w",right:"e",top:"n",bottom:"s"},a=Cd(t[e],JJ(r));return n[a]}function KJ(r,e){var t=[MM(r,e[0]),MM(r,e[1])];return(t[0]==="e"||t[0]==="w")&&t.reverse(),t.join("")}function KP(r,e,t,n,a,i){var o=t.__brushOption,s=r.toRectRange(o.range),l=e4(e,a,i);C(n,function(u){var c=YJ[u];s[c[0]][c[1]]+=l[c[0]]}),o.range=r.fromRectRange(JP(s[0][0],s[1][0],s[0][1],s[1][1])),pM(e,t),Js(e,{isEnd:!1})}function eK(r,e,t,n){var a=e.__brushOption.range,i=e4(r,t,n);C(a,function(o){o[0]+=i[0],o[1]+=i[1]}),pM(r,e),Js(r,{isEnd:!1})}function e4(r,e,t){var n=r.group,a=n.transformCoordToLocal(e,t),i=n.transformCoordToLocal(0,0);return[a[0]-i[0],a[1]-i[1]]}function xM(r,e,t){var n=QP(r,e);return n&&n!==Xs?n.clipPath(t,r._transform):Me(t)}function tK(r){var e=fh(r[0][0],r[1][0]),t=fh(r[0][1],r[1][1]),n=Eu(r[0][0],r[1][0]),a=Eu(r[0][1],r[1][1]);return{x:e,y:t,width:n-e,height:a-t}}function rK(r,e,t){if(!(!r._brushType||aK(r,e.offsetX,e.offsetY))){var n=r._zr,a=r._covers,i=yM(r,e,t);if(!r._dragging)for(var o=0;o<a.length;o++){var s=a[o].__brushOption;if(i&&(i===Xs||s.panelId===i.panelId)&&tg[s.brushType].contain(a[o],t[0],t[1]))return}i&&n.setCursorStyle("crosshair")}}function wM(r){var e=r.event;e.preventDefault&&e.preventDefault()}function DM(r,e,t){return r.childOfName("main").contain(e,t)}function t4(r,e,t,n){var a=r._creatingCover,i=r._creatingPanel,o=r._brushOption,s;if(r._track.push(t.slice()),XJ(r)||a){if(i&&!a){o.brushMode==="single"&&mM(r);var l=Me(o);l.brushType=r4(l.brushType,i),l.panelId=i===Xs?null:i.panelId,a=r._creatingCover=GP(r,l),r._covers.push(a)}if(a){var u=tg[r4(r._brushType,i)],c=a.__brushOption;c.range=u.getCreatingRange(xM(r,a,r._track)),n&&($P(r,a),u.updateCommon(r,a)),UP(r,a),s={isEnd:n}}}else n&&o.brushMode==="single"&&o.removeOnClick&&yM(r,e,t)&&mM(r)&&(s={isEnd:n,removeOnClick:!0});return s}function r4(r,e){return r==="auto"?e.defaultBrushType:r}var nK={mousedown:function(r){if(this._dragging)n4(this,r);else if(!r.target||!r.target.draggable){wM(r);var e=this.group.transformCoordToLocal(r.offsetX,r.offsetY);this._creatingCover=null;var t=this._creatingPanel=yM(this,r,e);t&&(this._dragging=!0,this._track=[e.slice()])}},mousemove:function(r){var e=r.offsetX,t=r.offsetY,n=this.group.transformCoordToLocal(e,t);if(rK(this,r,n),this._dragging){wM(r);var a=t4(this,r,n,!1);a&&Js(this,a)}},mouseup:function(r){n4(this,r)}};function n4(r,e){if(r._dragging){wM(e);var t=e.offsetX,n=e.offsetY,a=r.group.transformCoordToLocal(t,n),i=t4(r,e,a,!0);r._dragging=!1,r._track=[],r._creatingCover=null,i&&Js(r,i)}}function aK(r,e,t){var n=r._zr;return e<0||e>n.getWidth()||t<0||t>n.getHeight()}var tg={lineX:a4(0),lineY:a4(1),rect:{createCover:function(r,e){function t(n){return n}return qP({toRectRange:t,fromRectRange:t},r,e,[["w"],["e"],["n"],["s"],["s","e"],["s","w"],["n","e"],["n","w"]])},getCreatingRange:function(r){var e=ZP(r);return JP(e[1][0],e[1][1],e[0][0],e[0][1])},updateCoverShape:function(r,e,t,n){XP(r,e,t,n)},updateCommon:_M,contain:DM},polygon:{createCover:function(r,e){var t=new De;return t.add(new Xr({name:"main",style:bM(e),silent:!0})),t},getCreatingRange:function(r){return r},endCreating:function(r,e){e.remove(e.childAt(0)),e.add(new qr({name:"main",draggable:!0,drift:Ae(eK,r,e),ondragend:Ae(Js,r,{isEnd:!0})}))},updateCoverShape:function(r,e,t,n){e.childAt(0).setShape({points:xM(r,e,t)})},updateCommon:_M,contain:DM}};function a4(r){return{createCover:function(e,t){return qP({toRectRange:function(n){var a=[n,[0,100]];return r&&a.reverse(),a},fromRectRange:function(n){return n[r]}},e,t,[[["w"],["e"]],[["n"],["s"]]][r])},getCreatingRange:function(e){var t=ZP(e),n=fh(t[0][r],t[1][r]),a=Eu(t[0][r],t[1][r]);return[n,a]},updateCoverShape:function(e,t,n,a){var i,o=QP(e,t);if(o!==Xs&&o.getLinearBrushOtherExtent)i=o.getLinearBrushOtherExtent(r);else{var s=e._zr;i=[0,[s.getWidth(),s.getHeight()][1-r]]}var l=[n,i];r&&l.reverse(),XP(e,t,l,a)},updateCommon:_M,contain:DM}}var SM=qJ;function i4(r){return r=IM(r),function(e){return p1(e,r)}}function o4(r,e){return r=IM(r),function(t){var n=e!=null?e:t,a=n?r.width:r.height,i=n?r.x:r.y;return[i,i+(a||0)]}}function s4(r,e,t){var n=IM(r);return function(a,i){return n.contain(i[0],i[1])&&!Fp(a,e,t)}}function IM(r){return Pe.create(r)}var iK=["axisLine","axisTickLabel","axisName"],oK=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,n){r.prototype.init.apply(this,arguments),(this._brushController=new SM(n.getZr())).on("brush",fe(this._onBrush,this))},e.prototype.render=function(t,n,a,i){if(!sK(t,n,i)){this.axisModel=t,this.api=a,this.group.removeAll();var o=this._axisGroup;if(this._axisGroup=new De,this.group.add(this._axisGroup),!!t.get("show")){var s=uK(t,n),l=s.coordinateSystem,u=t.getAreaSelectStyle(),c=u.width,f=t.axis.dim,h=l.getAxisLayout(f),v=X({strokeContainThreshold:c},h),d=new Di(t,v);C(iK,d.add,d),this._axisGroup.add(d.getGroup()),this._refreshBrushController(v,u,t,s,c,a),sf(o,this._axisGroup,t)}}},e.prototype._refreshBrushController=function(t,n,a,i,o,s){var l=a.axis.getExtent(),u=l[1]-l[0],c=Math.min(30,Math.abs(u)*.1),f=Pe.create({x:l[0],y:-o/2,width:u,height:o});f.x-=c,f.width+=2*c,this._brushController.mount({enableGlobalPan:!0,rotation:t.rotation,x:t.position[0],y:t.position[1]}).setPanels([{panelId:"pl",clipPath:i4(f),isTargetByCursor:s4(f,s,i),getLinearBrushOtherExtent:o4(f,0)}]).enableBrush({brushType:"lineX",brushStyle:n,removeOnClick:!0}).updateCovers(lK(a))},e.prototype._onBrush=function(t){var n=t.areas,a=this.axisModel,i=a.axis,o=K(n,function(s){return[i.coordToData(s.range[0],!0),i.coordToData(s.range[1],!0)]});(!a.option.realtime===t.isEnd||t.removeOnClick)&&this.api.dispatchAction({type:"axisAreaSelect",parallelAxisId:a.id,intervals:o})},e.prototype.dispose=function(){this._brushController.dispose()},e.type="parallelAxis",e}(St);function sK(r,e,t){return t&&t.type==="axisAreaSelect"&&e.findComponents({mainType:"parallelAxis",query:t})[0]===r}function lK(r){var e=r.axis;return K(r.activeIntervals,function(t){return{brushType:"lineX",panelId:"pl",range:[e.dataToCoord(t[0],!0),e.dataToCoord(t[1],!0)]}})}function uK(r,e){return e.getComponent("parallel",r.get("parallelIndex"))}var cK=oK,fK={type:"axisAreaSelect",event:"axisAreaSelected"};function hK(r){r.registerAction(fK,function(e,t){t.eachComponent({mainType:"parallelAxis",query:e},function(n){n.axis.model.setActiveIntervals(e.intervals)})}),r.registerAction("parallelAxisExpand",function(e,t){t.eachComponent({mainType:"parallel",query:e},function(n){n.setAxisExpand(e)})})}var vK={type:"value",areaSelectStyle:{width:20,borderWidth:1,borderColor:"rgba(160,197,232)",color:"rgba(160,197,232)",opacity:.3},realtime:!0,z:10};function l4(r){r.registerComponentView(CJ),r.registerComponentModel(LJ),r.registerCoordinateSystem("parallel",HJ),r.registerPreprocessor(wJ),r.registerComponentModel(VP),r.registerComponentView(cK),Iu(r,"parallel",VP,vK),hK(r)}function dK(r){Re(l4),r.registerChartView(pJ),r.registerSeriesModel(_J),r.registerVisual(r.PRIORITY.VISUAL.BRUSH,xJ)}var pK=function(){function r(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.cpx1=0,this.cpy1=0,this.cpx2=0,this.cpy2=0,this.extent=0}return r}(),gK=function(r){U(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultShape=function(){return new pK},e.prototype.buildPath=function(t,n){var a=n.extent;t.moveTo(n.x1,n.y1),t.bezierCurveTo(n.cpx1,n.cpy1,n.cpx2,n.cpy2,n.x2,n.y2),n.orient==="vertical"?(t.lineTo(n.x2+a,n.y2),t.bezierCurveTo(n.cpx2+a,n.cpy2,n.cpx1+a,n.cpy1,n.x1+a,n.y1)):(t.lineTo(n.x2,n.y2+a),t.bezierCurveTo(n.cpx2,n.cpy2+a,n.cpx1,n.cpy1+a,n.x1,n.y1+a)),t.closePath()},e.prototype.highlight=function(){mi(this)},e.prototype.downplay=function(){_i(this)},e}(je),yK=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._focusAdjacencyDisabled=!1,t}return e.prototype.render=function(t,n,a){var i=this,o=t.getGraph(),s=this.group,l=t.layoutInfo,u=l.width,c=l.height,f=t.getData(),h=t.getData("edge"),v=t.get("orient");this._model=t,s.removeAll(),s.x=l.x,s.y=l.y,o.eachEdge(function(d){var p=new gK,g=Te(p);g.dataIndex=d.dataIndex,g.seriesIndex=t.seriesIndex,g.dataType="edge";var y=d.getModel(),m=y.getModel("lineStyle"),_=m.get("curveness"),b=d.node1.getLayout(),x=d.node1.getModel(),M=x.get("localX"),w=x.get("localY"),D=d.node2.getLayout(),T=d.node2.getModel(),I=T.get("localX"),A=T.get("localY"),N=d.getLayout(),L,E,O,P,H,F,G,Z;switch(p.shape.extent=Math.max(1,N.dy),p.shape.orient=v,v==="vertical"?(L=(M!=null?M*u:b.x)+N.sy,E=(w!=null?w*c:b.y)+b.dy,O=(I!=null?I*u:D.x)+N.ty,P=A!=null?A*c:D.y,H=L,F=E*(1-_)+P*_,G=O,Z=E*_+P*(1-_)):(L=(M!=null?M*u:b.x)+b.dx,E=(w!=null?w*c:b.y)+N.sy,O=I!=null?I*u:D.x,P=(A!=null?A*c:D.y)+N.ty,H=L*(1-_)+O*_,F=E,G=L*_+O*(1-_),Z=P),p.setShape({x1:L,y1:E,x2:O,y2:P,cpx1:H,cpy1:F,cpx2:G,cpy2:Z}),p.useStyle(m.getItemStyle()),p.style.fill){case"source":p.style.fill=d.node1.getVisual("color"),p.style.decal=d.node1.getVisual("style").decal;break;case"target":p.style.fill=d.node2.getVisual("color"),p.style.decal=d.node2.getVisual("style").decal;break;case"gradient":var te=d.node1.getVisual("color"),V=d.node2.getVisual("color");ce(te)&&ce(V)&&(p.style.fill=new Zl(0,0,+(v==="horizontal"),+(v==="vertical"),[{color:te,offset:0},{color:V,offset:1}]))}wr(p,sr(y,"edgeLabel"),{labelFetcher:t,labelDataIndex:d.dataIndex,defaultText:""+y.get("value")}),p.setTextConfig({position:"inside"});var Y=y.getModel("emphasis");xr(p,y,"lineStyle",function(Q){return Q.getItemStyle()}),s.add(p),h.setItemGraphicEl(d.dataIndex,p);var q=Y.get("focus");Lt(p,q==="adjacency"?d.getAdjacentDataIndices():q,Y.get("blurScope"),Y.get("disabled")),Te(p).dataType="edge"}),o.eachNode(function(d){var p=d.getLayout(),g=d.getModel(),y=g.get("localX"),m=g.get("localY"),_=g.getModel("emphasis"),b=new We({shape:{x:y!=null?y*u:p.x,y:m!=null?m*c:p.y,width:p.dx,height:p.dy},style:g.getModel("itemStyle").getItemStyle(),z2:10});wr(b,sr(g),{labelFetcher:t,labelDataIndex:d.dataIndex,defaultText:d.id}),b.disableLabelAnimation=!0,b.setStyle("fill",d.getVisual("color")),b.setStyle("decal",d.getVisual("style").decal),xr(b,g),s.add(b),f.setItemGraphicEl(d.dataIndex,b),Te(b).dataType="node";var x=_.get("focus");Lt(b,x==="adjacency"?d.getAdjacentDataIndices():x,_.get("blurScope"),_.get("disabled"))}),f.eachItemGraphicEl(function(d,p){var g=f.getItemModel(p);g.get("draggable")&&(d.drift=function(y,m){i._focusAdjacencyDisabled=!0,this.shape.x+=y,this.shape.y+=m,this.dirty(),a.dispatchAction({type:"dragNode",seriesId:t.id,dataIndex:f.getRawIndex(p),localX:this.shape.x/u,localY:this.shape.y/c})},d.ondragend=function(){i._focusAdjacencyDisabled=!1},d.draggable=!0,d.cursor="move")}),!this._data&&t.isAnimationEnabled()&&s.setClipPath(mK(s.getBoundingRect(),t,function(){s.removeClipPath()})),this._data=t.getData()},e.prototype.dispose=function(){},e.type="sankey",e}(ht);function mK(r,e,t){var n=new We({shape:{x:r.x-10,y:r.y-10,width:0,height:r.height+20}});return Dt(n,{shape:{width:r.width+20}},e,t),n}var _K=yK,bK=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.getInitialData=function(t,n){var a=t.edges||t.links,i=t.data||t.nodes,o=t.levels;this.levelModels=[];for(var s=this.levelModels,l=0;l<o.length;l++)o[l].depth!=null&&o[l].depth>=0&&(s[o[l].depth]=new ft(o[l],this,n));if(i&&a){var u=EP(i,a,this,!0,c);return u.data}function c(f,h){f.wrapMethod("getItemModel",function(v,d){var p=v.parentModel,g=p.getData().getItemLayout(d);if(g){var y=g.depth,m=p.levelModels[y];m&&(v.parentModel=m)}return v}),h.wrapMethod("getItemModel",function(v,d){var p=v.parentModel,g=p.getGraph().getEdgeByIndex(d),y=g.node1.getLayout();if(y){var m=y.depth,_=p.levelModels[m];_&&(v.parentModel=_)}return v})}},e.prototype.setNodePosition=function(t,n){var a=this.option.data||this.option.nodes,i=a[t];i.localX=n[0],i.localY=n[1]},e.prototype.getGraph=function(){return this.getData().graph},e.prototype.getEdgeData=function(){return this.getGraph().edgeData},e.prototype.formatTooltip=function(t,n,a){function i(v){return isNaN(v)||v==null}if(a==="edge"){var o=this.getDataParams(t,a),s=o.data,l=o.value,u=s.source+" -- "+s.target;return lr("nameValue",{name:u,value:l,noValue:i(l)})}else{var c=this.getGraph().getNodeByIndex(t),f=c.getLayout().value,h=this.getDataParams(t,a).data.name;return lr("nameValue",{name:h!=null?h+"":null,value:f,noValue:i(f)})}},e.prototype.optionUpdated=function(){},e.prototype.getDataParams=function(t,n){var a=r.prototype.getDataParams.call(this,t,n);if(a.value==null&&n==="node"){var i=this.getGraph().getNodeByIndex(t),o=i.getLayout().value;a.value=o}return a},e.type="series.sankey",e.defaultOption={z:2,coordinateSystem:"view",left:"5%",top:"5%",right:"20%",bottom:"5%",orient:"horizontal",nodeWidth:20,nodeGap:8,draggable:!0,layoutIterations:32,label:{show:!0,position:"right",fontSize:12},edgeLabel:{show:!1,fontSize:12},levels:[],nodeAlign:"justify",lineStyle:{color:"#314656",opacity:.2,curveness:.5},emphasis:{label:{show:!0},lineStyle:{opacity:.5}},select:{itemStyle:{borderColor:"#212121"}},animationEasing:"linear",animationDuration:1e3},e}(bt),MK=bK;function xK(r,e){r.eachSeriesByType("sankey",function(t){var n=t.get("nodeWidth"),a=t.get("nodeGap"),i=wK(t,e);t.layoutInfo=i;var o=i.width,s=i.height,l=t.getGraph(),u=l.nodes,c=l.edges;SK(u);var f=ot(u,function(p){return p.getLayout().value===0}),h=f.length!==0?0:t.get("layoutIterations"),v=t.get("orient"),d=t.get("nodeAlign");DK(u,c,n,a,o,s,h,v,d)})}function wK(r,e){return Yt(r.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}function DK(r,e,t,n,a,i,o,s,l){IK(r,e,t,a,i,s,l),NK(r,e,i,a,n,o,s),BK(r,s)}function SK(r){C(r,function(e){var t=So(e.outEdges,rg),n=So(e.inEdges,rg),a=e.getValue()||0,i=Math.max(t,n,a);e.setLayout({value:i},!0)})}function IK(r,e,t,n,a,i,o){for(var s=[],l=[],u=[],c=[],f=0,h=0;h<e.length;h++)s[h]=1;for(var h=0;h<r.length;h++)l[h]=r[h].inEdges.length,l[h]===0&&u.push(r[h]);for(var v=-1;u.length;){for(var d=0;d<u.length;d++){var p=u[d],g=p.hostGraph.data.getRawDataItem(p.dataIndex),y=g.depth!=null&&g.depth>=0;y&&g.depth>v&&(v=g.depth),p.setLayout({depth:y?g.depth:f},!0),i==="vertical"?p.setLayout({dy:t},!0):p.setLayout({dx:t},!0);for(var m=0;m<p.outEdges.length;m++){var _=p.outEdges[m],b=e.indexOf(_);s[b]=0;var x=_.node2,M=r.indexOf(x);--l[M]===0&&c.indexOf(x)<0&&c.push(x)}}++f,u=c,c=[]}for(var h=0;h<s.length;h++)if(s[h]===1)throw new Error("Sankey is a DAG, the original data has cycle!");var w=v>f-1?v:f-1;o&&o!=="left"&&TK(r,o,i,w);var D=i==="vertical"?(a-t)/w:(n-t)/w;CK(r,D,i)}function u4(r){var e=r.hostGraph.data.getRawDataItem(r.dataIndex);return e.depth!=null&&e.depth>=0}function TK(r,e,t,n){if(e==="right"){for(var a=[],i=r,o=0;i.length;){for(var s=0;s<i.length;s++){var l=i[s];l.setLayout({skNodeHeight:o},!0);for(var u=0;u<l.inEdges.length;u++){var c=l.inEdges[u];a.indexOf(c.node1)<0&&a.push(c.node1)}}i=a,a=[],++o}C(r,function(f){u4(f)||f.setLayout({depth:Math.max(0,n-f.getLayout().skNodeHeight)},!0)})}else e==="justify"&&AK(r,n)}function AK(r,e){C(r,function(t){!u4(t)&&!t.outEdges.length&&t.setLayout({depth:e},!0)})}function CK(r,e,t){C(r,function(n){var a=n.getLayout().depth*e;t==="vertical"?n.setLayout({y:a},!0):n.setLayout({x:a},!0)})}function NK(r,e,t,n,a,i,o){var s=LK(r,o);EK(s,e,t,n,a,o),TM(s,a,t,n,o);for(var l=1;i>0;i--)l*=.99,OK(s,l,o),TM(s,a,t,n,o),jK(s,l,o),TM(s,a,t,n,o)}function LK(r,e){var t=[],n=e==="vertical"?"y":"x",a=L0(r,function(i){return i.getLayout()[n]});return a.keys.sort(function(i,o){return i-o}),C(a.keys,function(i){t.push(a.buckets.get(i))}),t}function EK(r,e,t,n,a,i){var o=1/0;C(r,function(s){var l=s.length,u=0;C(s,function(f){u+=f.getLayout().value});var c=i==="vertical"?(n-(l-1)*a)/u:(t-(l-1)*a)/u;c<o&&(o=c)}),C(r,function(s){C(s,function(l,u){var c=l.getLayout().value*o;i==="vertical"?(l.setLayout({x:u},!0),l.setLayout({dx:c},!0)):(l.setLayout({y:u},!0),l.setLayout({dy:c},!0))})}),C(e,function(s){var l=+s.getValue()*o;s.setLayout({dy:l},!0)})}function TM(r,e,t,n,a){var i=a==="vertical"?"x":"y";C(r,function(o){o.sort(function(p,g){return p.getLayout()[i]-g.getLayout()[i]});for(var s,l,u,c=0,f=o.length,h=a==="vertical"?"dx":"dy",v=0;v<f;v++)l=o[v],u=c-l.getLayout()[i],u>0&&(s=l.getLayout()[i]+u,a==="vertical"?l.setLayout({x:s},!0):l.setLayout({y:s},!0)),c=l.getLayout()[i]+l.getLayout()[h]+e;var d=a==="vertical"?n:t;if(u=c-e-d,u>0){s=l.getLayout()[i]-u,a==="vertical"?l.setLayout({x:s},!0):l.setLayout({y:s},!0),c=s;for(var v=f-2;v>=0;--v)l=o[v],u=l.getLayout()[i]+l.getLayout()[h]+e-c,u>0&&(s=l.getLayout()[i]-u,a==="vertical"?l.setLayout({x:s},!0):l.setLayout({y:s},!0)),c=l.getLayout()[i]}})}function OK(r,e,t){C(r.slice().reverse(),function(n){C(n,function(a){if(a.outEdges.length){var i=So(a.outEdges,PK,t)/So(a.outEdges,rg);if(isNaN(i)){var o=a.outEdges.length;i=o?So(a.outEdges,zK,t)/o:0}if(t==="vertical"){var s=a.getLayout().x+(i-Do(a,t))*e;a.setLayout({x:s},!0)}else{var l=a.getLayout().y+(i-Do(a,t))*e;a.setLayout({y:l},!0)}}})})}function PK(r,e){return Do(r.node2,e)*r.getValue()}function zK(r,e){return Do(r.node2,e)}function kK(r,e){return Do(r.node1,e)*r.getValue()}function RK(r,e){return Do(r.node1,e)}function Do(r,e){return e==="vertical"?r.getLayout().x+r.getLayout().dx/2:r.getLayout().y+r.getLayout().dy/2}function rg(r){return r.getValue()}function So(r,e,t){for(var n=0,a=r.length,i=-1;++i<a;){var o=+e(r[i],t);isNaN(o)||(n+=o)}return n}function jK(r,e,t){C(r,function(n){C(n,function(a){if(a.inEdges.length){var i=So(a.inEdges,kK,t)/So(a.inEdges,rg);if(isNaN(i)){var o=a.inEdges.length;i=o?So(a.inEdges,RK,t)/o:0}if(t==="vertical"){var s=a.getLayout().x+(i-Do(a,t))*e;a.setLayout({x:s},!0)}else{var l=a.getLayout().y+(i-Do(a,t))*e;a.setLayout({y:l},!0)}}})})}function BK(r,e){var t=e==="vertical"?"x":"y";C(r,function(n){n.outEdges.sort(function(a,i){return a.node2.getLayout()[t]-i.node2.getLayout()[t]}),n.inEdges.sort(function(a,i){return a.node1.getLayout()[t]-i.node1.getLayout()[t]})}),C(r,function(n){var a=0,i=0;C(n.outEdges,function(o){o.setLayout({sy:a},!0),a+=o.getLayout().dy}),C(n.inEdges,function(o){o.setLayout({ty:i},!0),i+=o.getLayout().dy})})}function FK(r){r.eachSeriesByType("sankey",function(e){var t=e.getGraph(),n=t.nodes,a=t.edges;if(n.length){var i=1/0,o=-1/0;C(n,function(s){var l=s.getLayout().value;l<i&&(i=l),l>o&&(o=l)}),C(n,function(s){var l=new Sr({type:"color",mappingMethod:"linear",dataExtent:[i,o],visual:e.get("color")}),u=l.mapValueToVisual(s.getLayout().value),c=s.getModel().get(["itemStyle","color"]);c!=null?(s.setVisual("color",c),s.setVisual("style",{fill:c})):(s.setVisual("color",u),s.setVisual("style",{fill:u}))})}a.length&&C(a,function(s){var l=s.getModel().get("lineStyle");s.setVisual("style",l)})})}function VK(r){r.registerChartView(_K),r.registerSeriesModel(MK),r.registerLayout(xK),r.registerVisual(FK),r.registerAction({type:"dragNode",event:"dragnode",update:"update"},function(e,t){t.eachComponent({mainType:"series",subType:"sankey",query:e},function(n){n.setNodePosition(e.dataIndex,[e.localX,e.localY])})})}var c4=function(){function r(){}return r.prototype.getInitialData=function(e,t){var n,a=t.getComponent("xAxis",this.get("xAxisIndex")),i=t.getComponent("yAxis",this.get("yAxisIndex")),o=a.get("type"),s=i.get("type"),l;o==="category"?(e.layout="horizontal",n=a.getOrdinalMeta(),l=!0):s==="category"?(e.layout="vertical",n=i.getOrdinalMeta(),l=!0):e.layout=e.layout||"horizontal";var u=["x","y"],c=e.layout==="horizontal"?0:1,f=this._baseAxisDim=u[c],h=u[1-c],v=[a,i],d=v[c].get("type"),p=v[1-c].get("type"),g=e.data;if(g&&l){var y=[];C(g,function(b,x){var M;J(b)?(M=b.slice(),b.unshift(x)):J(b.value)?(M=X({},b),M.value=M.value.slice(),b.value.unshift(x)):M=b,y.push(M)}),e.data=y}var m=this.defaultValueDimensions,_=[{name:f,type:hp(d),ordinalMeta:n,otherDims:{tooltip:!1,itemName:0},dimsDef:["base"]},{name:h,type:hp(p),dimsDef:m.slice()}];return Su(this,{coordDimensions:_,dimensionsCount:m.length+1,encodeDefaulter:Ae(yC,_,this)})},r.prototype.getBaseAxis=function(){var e=this._baseAxisDim;return this.ecModel.getComponent(e+"Axis",this.get(e+"AxisIndex")).axis},r}(),f4=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.defaultValueDimensions=[{name:"min",defaultTooltip:!0},{name:"Q1",defaultTooltip:!0},{name:"median",defaultTooltip:!0},{name:"Q3",defaultTooltip:!0},{name:"max",defaultTooltip:!0}],t.visualDrawType="stroke",t}return e.type="series.boxplot",e.dependencies=["xAxis","yAxis","grid"],e.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,layout:null,boxWidth:[7,50],itemStyle:{color:"#fff",borderWidth:1},emphasis:{scale:!0,itemStyle:{borderWidth:2,shadowBlur:5,shadowOffsetX:1,shadowOffsetY:1,shadowColor:"rgba(0,0,0,0.2)"}},animationDuration:800},e}(bt);Et(f4,c4,!0);var HK=f4,WK=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a){var i=t.getData(),o=this.group,s=this._data;this._data||o.removeAll();var l=t.get("layout")==="horizontal"?1:0;i.diff(s).add(function(u){if(i.hasValue(u)){var c=i.getItemLayout(u),f=h4(c,i,u,l,!0);i.setItemGraphicEl(u,f),o.add(f)}}).update(function(u,c){var f=s.getItemGraphicEl(c);if(!i.hasValue(u)){o.remove(f);return}var h=i.getItemLayout(u);f?(ya(f),v4(h,f,i,u)):f=h4(h,i,u,l),o.add(f),i.setItemGraphicEl(u,f)}).remove(function(u){var c=s.getItemGraphicEl(u);c&&o.remove(c)}).execute(),this._data=i},e.prototype.remove=function(t){var n=this.group,a=this._data;this._data=null,a&&a.eachItemGraphicEl(function(i){i&&n.remove(i)})},e.type="boxplot",e}(ht),GK=function(){function r(){}return r}(),$K=function(r){U(e,r);function e(t){var n=r.call(this,t)||this;return n.type="boxplotBoxPath",n}return e.prototype.getDefaultShape=function(){return new GK},e.prototype.buildPath=function(t,n){var a=n.points,i=0;for(t.moveTo(a[i][0],a[i][1]),i++;i<4;i++)t.lineTo(a[i][0],a[i][1]);for(t.closePath();i<a.length;i++)t.moveTo(a[i][0],a[i][1]),i++,t.lineTo(a[i][0],a[i][1])},e}(je);function h4(r,e,t,n,a){var i=r.ends,o=new $K({shape:{points:a?UK(i,n,r):i}});return v4(r,o,e,t,a),o}function v4(r,e,t,n,a){var i=t.hostModel,o=uf[a?"initProps":"updateProps"];o(e,{shape:{points:r.ends}},i,n),e.useStyle(t.getItemVisual(n,"style")),e.style.strokeNoScale=!0,e.z2=100;var s=t.getItemModel(n),l=s.getModel("emphasis");xr(e,s),Lt(e,l.get("focus"),l.get("blurScope"),l.get("disabled"))}function UK(r,e,t){return K(r,function(n){return n=n.slice(),n[e]=t.initBaseline,n})}var YK=WK,hh=C;function QK(r){var e=ZK(r);hh(e,function(t){var n=t.seriesModels;!n.length||(qK(t),hh(n,function(a,i){XK(a,t.boxOffsetList[i],t.boxWidthList[i])}))})}function ZK(r){var e=[],t=[];return r.eachSeriesByType("boxplot",function(n){var a=n.getBaseAxis(),i=ze(t,a);i<0&&(i=t.length,t[i]=a,e[i]={axis:a,seriesModels:[]}),e[i].seriesModels.push(n)}),e}function qK(r){var e=r.axis,t=r.seriesModels,n=t.length,a=r.boxWidthList=[],i=r.boxOffsetList=[],o=[],s;if(e.type==="category")s=e.getBandWidth();else{var l=0;hh(t,function(d){l=Math.max(l,d.getData().count())});var u=e.getExtent();s=Math.abs(u[1]-u[0])/l}hh(t,function(d){var p=d.get("boxWidth");J(p)||(p=[p,p]),o.push([ue(p[0],s)||0,ue(p[1],s)||0])});var c=s*.8-2,f=c/n*.3,h=(c-f*(n-1))/n,v=h/2-c/2;hh(t,function(d,p){i.push(v),v+=f+h,a.push(Math.min(Math.max(h,o[p][0]),o[p][1]))})}function XK(r,e,t){var n=r.coordinateSystem,a=r.getData(),i=t/2,o=r.get("layout")==="horizontal"?0:1,s=1-o,l=["x","y"],u=a.mapDimension(l[o]),c=a.mapDimensionsAll(l[s]);if(u==null||c.length<5)return;for(var f=0;f<a.count();f++){var h=a.get(u,f),v=_(h,c[2],f),d=_(h,c[0],f),p=_(h,c[1],f),g=_(h,c[3],f),y=_(h,c[4],f),m=[];b(m,p,!1),b(m,g,!0),m.push(d,p,y,g),x(m,d),x(m,y),x(m,v),a.setItemLayout(f,{initBaseline:v[s],ends:m})}function _(M,w,D){var T=a.get(w,D),I=[];I[o]=M,I[s]=T;var A;return isNaN(M)||isNaN(T)?A=[NaN,NaN]:(A=n.dataToPoint(I),A[o]+=e),A}function b(M,w,D){var T=w.slice(),I=w.slice();T[o]+=i,I[o]-=i,D?M.push(T,I):M.push(I,T)}function x(M,w){var D=w.slice(),T=w.slice();D[o]-=i,T[o]+=i,M.push(D,T)}}function JK(r,e){e=e||{};for(var t=[],n=[],a=e.boundIQR,i=a==="none"||a===0,o=0;o<r.length;o++){var s=bn(r[o].slice()),l=rd(s,.25),u=rd(s,.5),c=rd(s,.75),f=s[0],h=s[s.length-1],v=(a==null?1.5:a)*(c-l),d=i?f:Math.max(f,l-v),p=i?h:Math.min(h,c+v),g=e.itemNameFormatter,y=ye(g)?g({value:o}):ce(g)?g.replace("{value}",o+""):o+"";t.push([y,d,l,u,c,p]);for(var m=0;m<s.length;m++){var _=s[m];if(_<d||_>p){var b=[y,_];n.push(b)}}}return{boxData:t,outliers:n}}var KK={type:"echarts:boxplot",transform:function(e){var t=e.upstream;if(t.sourceFormat!==zr){var n="";at(n)}var a=JK(t.getRawData(),e.config);return[{dimensions:["ItemName","Low","Q1","Q2","Q3","High"],data:a.boxData},{data:a.outliers}]}};function eee(r){r.registerSeriesModel(HK),r.registerChartView(YK),r.registerLayout(QK),r.registerTransform(KK)}var tee=["color","borderColor"],ree=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a){this.group.removeClipPath(),this._progressiveEls=null,this._updateDrawMode(t),this._isLargeDraw?this._renderLarge(t):this._renderNormal(t)},e.prototype.incrementalPrepareRender=function(t,n,a){this._clear(),this._updateDrawMode(t)},e.prototype.incrementalRender=function(t,n,a,i){this._progressiveEls=[],this._isLargeDraw?this._incrementalRenderLarge(t,n):this._incrementalRenderNormal(t,n)},e.prototype.eachRendered=function(t){uo(this._progressiveEls||this.group,t)},e.prototype._updateDrawMode=function(t){var n=t.pipelineContext.large;(this._isLargeDraw==null||n!==this._isLargeDraw)&&(this._isLargeDraw=n,this._clear())},e.prototype._renderNormal=function(t){var n=t.getData(),a=this._data,i=this.group,o=n.getLayout("isSimpleBox"),s=t.get("clip",!0),l=t.coordinateSystem,u=l.getArea&&l.getArea();this._data||i.removeAll(),n.diff(a).add(function(c){if(n.hasValue(c)){var f=n.getItemLayout(c);if(s&&d4(u,f))return;var h=AM(f,c,!0);Dt(h,{shape:{points:f.ends}},t,c),CM(h,n,c,o),i.add(h),n.setItemGraphicEl(c,h)}}).update(function(c,f){var h=a.getItemGraphicEl(f);if(!n.hasValue(c)){i.remove(h);return}var v=n.getItemLayout(c);if(s&&d4(u,v)){i.remove(h);return}h?(Qe(h,{shape:{points:v.ends}},t,c),ya(h)):h=AM(v),CM(h,n,c,o),i.add(h),n.setItemGraphicEl(c,h)}).remove(function(c){var f=a.getItemGraphicEl(c);f&&i.remove(f)}).execute(),this._data=n},e.prototype._renderLarge=function(t){this._clear(),p4(t,this.group);var n=t.get("clip",!0)?Lp(t.coordinateSystem,!1,t):null;n?this.group.setClipPath(n):this.group.removeClipPath()},e.prototype._incrementalRenderNormal=function(t,n){for(var a=n.getData(),i=a.getLayout("isSimpleBox"),o;(o=t.next())!=null;){var s=a.getItemLayout(o),l=AM(s);CM(l,a,o,i),l.incremental=!0,this.group.add(l),this._progressiveEls.push(l)}},e.prototype._incrementalRenderLarge=function(t,n){p4(n,this.group,this._progressiveEls,!0)},e.prototype.remove=function(t){this._clear()},e.prototype._clear=function(){this.group.removeAll(),this._data=null},e.type="candlestick",e}(ht),nee=function(){function r(){}return r}(),aee=function(r){U(e,r);function e(t){var n=r.call(this,t)||this;return n.type="normalCandlestickBox",n}return e.prototype.getDefaultShape=function(){return new nee},e.prototype.buildPath=function(t,n){var a=n.points;this.__simpleBox?(t.moveTo(a[4][0],a[4][1]),t.lineTo(a[6][0],a[6][1])):(t.moveTo(a[0][0],a[0][1]),t.lineTo(a[1][0],a[1][1]),t.lineTo(a[2][0],a[2][1]),t.lineTo(a[3][0],a[3][1]),t.closePath(),t.moveTo(a[4][0],a[4][1]),t.lineTo(a[5][0],a[5][1]),t.moveTo(a[6][0],a[6][1]),t.lineTo(a[7][0],a[7][1]))},e}(je);function AM(r,e,t){var n=r.ends;return new aee({shape:{points:t?iee(n,r):n},z2:100})}function d4(r,e){for(var t=!0,n=0;n<e.ends.length;n++)if(r.contain(e.ends[n][0],e.ends[n][1])){t=!1;break}return t}function CM(r,e,t,n){var a=e.getItemModel(t);r.useStyle(e.getItemVisual(t,"style")),r.style.strokeNoScale=!0,r.__simpleBox=n,xr(r,a)}function iee(r,e){return K(r,function(t){return t=t.slice(),t[1]=e.initBaseline,t})}var oee=function(){function r(){}return r}(),NM=function(r){U(e,r);function e(t){var n=r.call(this,t)||this;return n.type="largeCandlestickBox",n}return e.prototype.getDefaultShape=function(){return new oee},e.prototype.buildPath=function(t,n){for(var a=n.points,i=0;i<a.length;)if(this.__sign===a[i++]){var o=a[i++];t.moveTo(o,a[i++]),t.lineTo(o,a[i++])}else i+=3},e}(je);function p4(r,e,t,n){var a=r.getData(),i=a.getLayout("largePoints"),o=new NM({shape:{points:i},__sign:1,ignoreCoarsePointer:!0});e.add(o);var s=new NM({shape:{points:i},__sign:-1,ignoreCoarsePointer:!0});e.add(s);var l=new NM({shape:{points:i},__sign:0,ignoreCoarsePointer:!0});e.add(l),LM(1,o,r),LM(-1,s,r),LM(0,l,r),n&&(o.incremental=!0,s.incremental=!0),t&&t.push(o,s)}function LM(r,e,t,n){var a=t.get(["itemStyle",r>0?"borderColor":"borderColor0"])||t.get(["itemStyle",r>0?"color":"color0"]);r===0&&(a=t.get(["itemStyle","borderColorDoji"]));var i=t.getModel("itemStyle").getItemStyle(tee);e.useStyle(i),e.style.fill=null,e.style.stroke=a}var see=ree,g4=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.defaultValueDimensions=[{name:"open",defaultTooltip:!0},{name:"close",defaultTooltip:!0},{name:"lowest",defaultTooltip:!0},{name:"highest",defaultTooltip:!0}],t}return e.prototype.getShadowDim=function(){return"open"},e.prototype.brushSelector=function(t,n,a){var i=n.getItemLayout(t);return i&&a.rect(i.brushRect)},e.type="series.candlestick",e.dependencies=["xAxis","yAxis","grid"],e.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,layout:null,clip:!0,itemStyle:{color:"#eb5454",color0:"#47b262",borderColor:"#eb5454",borderColor0:"#47b262",borderColorDoji:null,borderWidth:1},emphasis:{scale:!0,itemStyle:{borderWidth:2}},barMaxWidth:null,barMinWidth:null,barWidth:null,large:!0,largeThreshold:600,progressive:3e3,progressiveThreshold:1e4,progressiveChunkMode:"mod",animationEasing:"linear",animationDuration:300},e}(bt);Et(g4,c4,!0);var lee=g4;function uee(r){!r||!J(r.series)||C(r.series,function(e){_e(e)&&e.type==="k"&&(e.type="candlestick")})}var cee=["itemStyle","borderColor"],fee=["itemStyle","borderColor0"],hee=["itemStyle","borderColorDoji"],vee=["itemStyle","color"],dee=["itemStyle","color0"],pee={seriesType:"candlestick",plan:hu(),performRawSeries:!0,reset:function(r,e){function t(i,o){return o.get(i>0?vee:dee)}function n(i,o){return o.get(i===0?hee:i>0?cee:fee)}if(!e.isSeriesFiltered(r)){var a=r.pipelineContext.large;return!a&&{progress:function(i,o){for(var s;(s=i.next())!=null;){var l=o.getItemModel(s),u=o.getItemLayout(s).sign,c=l.getItemStyle();c.fill=t(u,l),c.stroke=n(u,l)||c.fill;var f=o.ensureUniqueItemVisual(s,"style");X(f,c)}}}}}},gee=pee,yee={seriesType:"candlestick",plan:hu(),reset:function(r){var e=r.coordinateSystem,t=r.getData(),n=mee(r,t),a=0,i=1,o=["x","y"],s=t.getDimensionIndex(t.mapDimension(o[a])),l=K(t.mapDimensionsAll(o[i]),t.getDimensionIndex,t),u=l[0],c=l[1],f=l[2],h=l[3];if(t.setLayout({candleWidth:n,isSimpleBox:n<=1.3}),s<0||l.length<4)return;return{progress:r.pipelineContext.large?d:v};function v(p,g){for(var y,m=g.getStore();(y=p.next())!=null;){var _=m.get(s,y),b=m.get(u,y),x=m.get(c,y),M=m.get(f,y),w=m.get(h,y),D=Math.min(b,x),T=Math.max(b,x),I=H(D,_),A=H(T,_),N=H(M,_),L=H(w,_),E=[];F(E,A,0),F(E,I,1),E.push(Z(L),Z(A),Z(N),Z(I));var O=g.getItemModel(y),P=!!O.get(["itemStyle","borderColorDoji"]);g.setItemLayout(y,{sign:y4(m,y,b,x,c,P),initBaseline:b>x?A[i]:I[i],ends:E,brushRect:G(M,w,_)})}function H(te,V){var Y=[];return Y[a]=V,Y[i]=te,isNaN(V)||isNaN(te)?[NaN,NaN]:e.dataToPoint(Y)}function F(te,V,Y){var q=V.slice(),Q=V.slice();q[a]=Ad(q[a]+n/2,1,!1),Q[a]=Ad(Q[a]-n/2,1,!0),Y?te.push(q,Q):te.push(Q,q)}function G(te,V,Y){var q=H(te,Y),Q=H(V,Y);return q[a]-=n/2,Q[a]-=n/2,{x:q[0],y:q[1],width:n,height:Q[1]-q[1]}}function Z(te){return te[a]=Ad(te[a],1),te}}function d(p,g){for(var y=Ya(p.count*4),m=0,_,b=[],x=[],M,w=g.getStore(),D=!!r.get(["itemStyle","borderColorDoji"]);(M=p.next())!=null;){var T=w.get(s,M),I=w.get(u,M),A=w.get(c,M),N=w.get(f,M),L=w.get(h,M);if(isNaN(T)||isNaN(N)||isNaN(L)){y[m++]=NaN,m+=3;continue}y[m++]=y4(w,M,I,A,c,D),b[a]=T,b[i]=N,_=e.dataToPoint(b,null,x),y[m++]=_?_[0]:NaN,y[m++]=_?_[1]:NaN,b[i]=L,_=e.dataToPoint(b,null,x),y[m++]=_?_[1]:NaN}g.setLayout("largePoints",y)}}};function y4(r,e,t,n,a,i){var o;return t>n?o=-1:t<n?o=1:o=i?0:e>0?r.get(a,e-1)<=n?1:-1:1,o}function mee(r,e){var t=r.getBaseAxis(),n,a=t.type==="category"?t.getBandWidth():(n=t.getExtent(),Math.abs(n[1]-n[0])/e.count()),i=ue(Ee(r.get("barMaxWidth"),a),a),o=ue(Ee(r.get("barMinWidth"),1),a),s=r.get("barWidth");return s!=null?ue(s,a):Math.max(Math.min(a/2,i),o)}var _ee=yee;function bee(r){r.registerChartView(see),r.registerSeriesModel(lee),r.registerPreprocessor(uee),r.registerVisual(gee),r.registerLayout(_ee)}function m4(r,e){var t=e.rippleEffectColor||e.color;r.eachChild(function(n){n.attr({z:e.z,zlevel:e.zlevel,style:{stroke:e.brushType==="stroke"?t:null,fill:e.brushType==="fill"?t:null}})})}var Mee=function(r){U(e,r);function e(t,n){var a=r.call(this)||this,i=new Gf(t,n),o=new De;return a.add(i),a.add(o),a.updateData(t,n),a}return e.prototype.stopEffectAnimation=function(){this.childAt(1).removeAll()},e.prototype.startEffectAnimation=function(t){for(var n=t.symbolType,a=t.color,i=t.rippleNumber,o=this.childAt(1),s=0;s<i;s++){var l=Ft(n,-1,-1,2,2,a);l.attr({style:{strokeNoScale:!0},z2:99,silent:!0,scaleX:.5,scaleY:.5});var u=-s/i*t.period+t.effectOffset;l.animate("",!0).when(t.period,{scaleX:t.rippleScale/2,scaleY:t.rippleScale/2}).delay(u).start(),l.animateStyle(!0).when(t.period,{opacity:0}).delay(u).start(),o.add(l)}m4(o,t)},e.prototype.updateEffectAnimation=function(t){for(var n=this._effectCfg,a=this.childAt(1),i=["symbolType","period","rippleScale","rippleNumber"],o=0;o<i.length;o++){var s=i[o];if(n[s]!==t[s]){this.stopEffectAnimation(),this.startEffectAnimation(t);return}}m4(a,t)},e.prototype.highlight=function(){mi(this)},e.prototype.downplay=function(){_i(this)},e.prototype.getSymbolType=function(){var t=this.childAt(0);return t&&t.getSymbolType()},e.prototype.updateData=function(t,n){var a=this,i=t.hostModel;this.childAt(0).updateData(t,n);var o=this.childAt(1),s=t.getItemModel(n),l=t.getItemVisual(n,"symbol"),u=If(t.getItemVisual(n,"symbolSize")),c=t.getItemVisual(n,"style"),f=c&&c.fill,h=s.getModel("emphasis");o.setScale(u),o.traverse(function(g){g.setStyle("fill",f)});var v=pu(t.getItemVisual(n,"symbolOffset"),u);v&&(o.x=v[0],o.y=v[1]);var d=t.getItemVisual(n,"symbolRotate");o.rotation=(d||0)*Math.PI/180||0;var p={};p.showEffectOn=i.get("showEffectOn"),p.rippleScale=s.get(["rippleEffect","scale"]),p.brushType=s.get(["rippleEffect","brushType"]),p.period=s.get(["rippleEffect","period"])*1e3,p.effectOffset=n/t.count(),p.z=i.getShallow("z")||0,p.zlevel=i.getShallow("zlevel")||0,p.symbolType=l,p.color=f,p.rippleEffectColor=s.get(["rippleEffect","color"]),p.rippleNumber=s.get(["rippleEffect","number"]),p.showEffectOn==="render"?(this._effectCfg?this.updateEffectAnimation(p):this.startEffectAnimation(p),this._effectCfg=p):(this._effectCfg=null,this.stopEffectAnimation(),this.onHoverStateChange=function(g){g==="emphasis"?p.showEffectOn!=="render"&&a.startEffectAnimation(p):g==="normal"&&p.showEffectOn!=="render"&&a.stopEffectAnimation()}),this._effectCfg=p,Lt(this,h.get("focus"),h.get("blurScope"),h.get("disabled"))},e.prototype.fadeOut=function(t){t&&t()},e}(De),xee=Mee,wee=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(){this._symbolDraw=new $f(xee)},e.prototype.render=function(t,n,a){var i=t.getData(),o=this._symbolDraw;o.updateData(i,{clipShape:this._getClipShape(t)}),this.group.add(o.group)},e.prototype._getClipShape=function(t){var n=t.coordinateSystem,a=n&&n.getArea&&n.getArea();return t.get("clip",!0)?a:null},e.prototype.updateTransform=function(t,n,a){var i=t.getData();this.group.dirty();var o=Uf("").reset(t,n,a);o.progress&&o.progress({start:0,end:i.count(),count:i.count()},i),this._symbolDraw.updateLayout()},e.prototype._updateGroupTransform=function(t){var n=t.coordinateSystem;n&&n.getRoamTransform&&(this.group.transform=KS(n.getRoamTransform()),this.group.decomposeTransform())},e.prototype.remove=function(t,n){this._symbolDraw&&this._symbolDraw.remove(!0)},e.type="effectScatter",e}(ht),Dee=wee,See=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t}return e.prototype.getInitialData=function(t,n){return Ua(null,this,{useEncodeDefaulter:!0})},e.prototype.brushSelector=function(t,n,a){return a.point(n.getItemLayout(t))},e.type="series.effectScatter",e.dependencies=["grid","polar"],e.defaultOption={coordinateSystem:"cartesian2d",z:2,legendHoverLink:!0,effectType:"ripple",progressive:0,showEffectOn:"render",clip:!0,rippleEffect:{period:4,scale:2.5,brushType:"fill",number:3},universalTransition:{divideShape:"clone"},symbolSize:10},e}(bt),Iee=See;function Tee(r){r.registerChartView(Dee),r.registerSeriesModel(Iee),r.registerLayout(Uf("effectScatter"))}var Aee=function(r){U(e,r);function e(t,n,a){var i=r.call(this)||this;return i.add(i.createLine(t,n,a)),i._updateEffectSymbol(t,n),i}return e.prototype.createLine=function(t,n,a){return new nM(t,n,a)},e.prototype._updateEffectSymbol=function(t,n){var a=t.getItemModel(n),i=a.getModel("effect"),o=i.get("symbolSize"),s=i.get("symbol");J(o)||(o=[o,o]);var l=t.getItemVisual(n,"style"),u=i.get("color")||l&&l.stroke,c=this.childAt(1);this._symbolType!==s&&(this.remove(c),c=Ft(s,-.5,-.5,1,1,u),c.z2=100,c.culling=!0,this.add(c)),c&&(c.setStyle("shadowColor",u),c.setStyle(i.getItemStyle(["color"])),c.scaleX=o[0],c.scaleY=o[1],c.setColor(u),this._symbolType=s,this._symbolScale=o,this._updateEffectAnimation(t,i,n))},e.prototype._updateEffectAnimation=function(t,n,a){var i=this.childAt(1);if(!!i){var o=t.getItemLayout(a),s=n.get("period")*1e3,l=n.get("loop"),u=n.get("roundTrip"),c=n.get("constantSpeed"),f=ar(n.get("delay"),function(v){return v/t.count()*s/3});if(i.ignore=!0,this._updateAnimationPoints(i,o),c>0&&(s=this._getLineLength(i)/c*1e3),s!==this._period||l!==this._loop||u!==this._roundTrip){i.stopAnimation();var h=void 0;ye(f)?h=f(a):h=f,i.__t>0&&(h=-s*i.__t),this._animateSymbol(i,s,h,l,u)}this._period=s,this._loop=l,this._roundTrip=u}},e.prototype._animateSymbol=function(t,n,a,i,o){if(n>0){t.__t=0;var s=this,l=t.animate("",i).when(o?n*2:n,{__t:o?2:1}).delay(a).during(function(){s._updateSymbolPosition(t)});i||l.done(function(){s.remove(t)}),l.start()}},e.prototype._getLineLength=function(t){return ui(t.__p1,t.__cp1)+ui(t.__cp1,t.__p2)},e.prototype._updateAnimationPoints=function(t,n){t.__p1=n[0],t.__p2=n[1],t.__cp1=n[2]||[(n[0][0]+n[1][0])/2,(n[0][1]+n[1][1])/2]},e.prototype.updateData=function(t,n,a){this.childAt(0).updateData(t,n,a),this._updateEffectSymbol(t,n)},e.prototype._updateSymbolPosition=function(t){var n=t.__p1,a=t.__p2,i=t.__cp1,o=t.__t<1?t.__t:2-t.__t,s=[t.x,t.y],l=s.slice(),u=dr,c=Um;s[0]=u(n[0],i[0],a[0],o),s[1]=u(n[1],i[1],a[1],o);var f=t.__t<1?c(n[0],i[0],a[0],o):c(a[0],i[0],n[0],1-o),h=t.__t<1?c(n[1],i[1],a[1],o):c(a[1],i[1],n[1],1-o);t.rotation=-Math.atan2(h,f)-Math.PI/2,(this._symbolType==="line"||this._symbolType==="rect"||this._symbolType==="roundRect")&&(t.__lastT!==void 0&&t.__lastT<t.__t?(t.scaleY=ui(l,s)*1.05,o===1&&(s[0]=l[0]+(s[0]-l[0])/2,s[1]=l[1]+(s[1]-l[1])/2)):t.__lastT===1?t.scaleY=2*ui(n,s):t.scaleY=this._symbolScale[1]),t.__lastT=t.__t,t.ignore=!1,t.x=s[0],t.y=s[1]},e.prototype.updateLayout=function(t,n){this.childAt(0).updateLayout(t,n);var a=t.getItemModel(n).getModel("effect");this._updateEffectAnimation(t,a,n)},e}(De),_4=Aee,Cee=function(r){U(e,r);function e(t,n,a){var i=r.call(this)||this;return i._createPolyline(t,n,a),i}return e.prototype._createPolyline=function(t,n,a){var i=t.getItemLayout(n),o=new Xr({shape:{points:i}});this.add(o),this._updateCommonStl(t,n,a)},e.prototype.updateData=function(t,n,a){var i=t.hostModel,o=this.childAt(0),s={shape:{points:t.getItemLayout(n)}};Qe(o,s,i,n),this._updateCommonStl(t,n,a)},e.prototype._updateCommonStl=function(t,n,a){var i=this.childAt(0),o=t.getItemModel(n),s=a&&a.emphasisLineStyle,l=a&&a.focus,u=a&&a.blurScope,c=a&&a.emphasisDisabled;if(!a||t.hasItemOption){var f=o.getModel("emphasis");s=f.getModel("lineStyle").getLineStyle(),c=f.get("disabled"),l=f.get("focus"),u=f.get("blurScope")}i.useStyle(t.getItemVisual(n,"style")),i.style.fill=null,i.style.strokeNoScale=!0;var h=i.ensureState("emphasis");h.style=s,Lt(this,l,u,c)},e.prototype.updateLayout=function(t,n){var a=this.childAt(0);a.setShape("points",t.getItemLayout(n))},e}(De),b4=Cee,Nee=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t._lastFrame=0,t._lastFramePercent=0,t}return e.prototype.createLine=function(t,n,a){return new b4(t,n,a)},e.prototype._updateAnimationPoints=function(t,n){this._points=n;for(var a=[0],i=0,o=1;o<n.length;o++){var s=n[o-1],l=n[o];i+=ui(s,l),a.push(i)}if(i===0){this._length=0;return}for(var o=0;o<a.length;o++)a[o]/=i;this._offsets=a,this._length=i},e.prototype._getLineLength=function(){return this._length},e.prototype._updateSymbolPosition=function(t){var n=t.__t<1?t.__t:2-t.__t,a=this._points,i=this._offsets,o=a.length;if(!!i){var s=this._lastFrame,l;if(n<this._lastFramePercent){var u=Math.min(s+1,o-1);for(l=u;l>=0&&!(i[l]<=n);l--);l=Math.min(l,o-2)}else{for(l=s;l<o&&!(i[l]>n);l++);l=Math.min(l-1,o-2)}var c=(n-i[l])/(i[l+1]-i[l]),f=a[l],h=a[l+1];t.x=f[0]*(1-c)+c*h[0],t.y=f[1]*(1-c)+c*h[1];var v=t.__t<1?h[0]-f[0]:f[0]-h[0],d=t.__t<1?h[1]-f[1]:f[1]-h[1];t.rotation=-Math.atan2(d,v)-Math.PI/2,this._lastFrame=l,this._lastFramePercent=n,t.ignore=!1}},e}(_4),Lee=Nee,Eee=function(){function r(){this.polyline=!1,this.curveness=0,this.segs=[]}return r}(),Oee=function(r){U(e,r);function e(t){var n=r.call(this,t)||this;return n._off=0,n.hoverDataIdx=-1,n}return e.prototype.reset=function(){this.notClear=!1,this._off=0},e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new Eee},e.prototype.buildPath=function(t,n){var a=n.segs,i=n.curveness,o;if(n.polyline)for(o=this._off;o<a.length;){var s=a[o++];if(s>0){t.moveTo(a[o++],a[o++]);for(var l=1;l<s;l++)t.lineTo(a[o++],a[o++])}}else for(o=this._off;o<a.length;){var u=a[o++],c=a[o++],f=a[o++],h=a[o++];if(t.moveTo(u,c),i>0){var v=(u+f)/2-(c-h)*i,d=(c+h)/2-(f-u)*i;t.quadraticCurveTo(v,d,f,h)}else t.lineTo(f,h)}this.incremental&&(this._off=o,this.notClear=!0)},e.prototype.findDataIndex=function(t,n){var a=this.shape,i=a.segs,o=a.curveness,s=this.style.lineWidth;if(a.polyline)for(var l=0,u=0;u<i.length;){var c=i[u++];if(c>0)for(var f=i[u++],h=i[u++],v=1;v<c;v++){var d=i[u++],p=i[u++];if(no(f,h,d,p,s,t,n))return l}l++}else for(var l=0,u=0;u<i.length;){var f=i[u++],h=i[u++],d=i[u++],p=i[u++];if(o>0){var g=(f+d)/2-(h-p)*o,y=(h+p)/2-(d-f)*o;if(wT(f,h,g,y,d,p,s,t,n))return l}else if(no(f,h,d,p,s,t,n))return l;l++}return-1},e.prototype.contain=function(t,n){var a=this.transformCoordToLocal(t,n),i=this.getBoundingRect();if(t=a[0],n=a[1],i.contain(t,n)){var o=this.hoverDataIdx=this.findDataIndex(t,n);return o>=0}return this.hoverDataIdx=-1,!1},e.prototype.getBoundingRect=function(){var t=this._rect;if(!t){for(var n=this.shape,a=n.segs,i=1/0,o=1/0,s=-1/0,l=-1/0,u=0;u<a.length;){var c=a[u++],f=a[u++];i=Math.min(c,i),s=Math.max(c,s),o=Math.min(f,o),l=Math.max(f,l)}t=this._rect=new Pe(i,o,s,l)}return t},e}(je),Pee=function(){function r(){this.group=new De}return r.prototype.updateData=function(e){this._clear();var t=this._create();t.setShape({segs:e.getLayout("linesPoints")}),this._setCommon(t,e)},r.prototype.incrementalPrepareUpdate=function(e){this.group.removeAll(),this._clear()},r.prototype.incrementalUpdate=function(e,t){var n=this._newAdded[0],a=t.getLayout("linesPoints"),i=n&&n.shape.segs;if(i&&i.length<2e4){var o=i.length,s=new Float32Array(o+a.length);s.set(i),s.set(a,o),n.setShape({segs:s})}else{this._newAdded=[];var l=this._create();l.incremental=!0,l.setShape({segs:a}),this._setCommon(l,t),l.__startIndex=e.start}},r.prototype.remove=function(){this._clear()},r.prototype.eachRendered=function(e){this._newAdded[0]&&e(this._newAdded[0])},r.prototype._create=function(){var e=new Oee({cursor:"default",ignoreCoarsePointer:!0});return this._newAdded.push(e),this.group.add(e),e},r.prototype._setCommon=function(e,t,n){var a=t.hostModel;e.setShape({polyline:a.get("polyline"),curveness:a.get(["lineStyle","curveness"])}),e.useStyle(a.getModel("lineStyle").getLineStyle()),e.style.strokeNoScale=!0;var i=t.getVisual("style");i&&i.stroke&&e.setStyle("stroke",i.stroke),e.setStyle("fill",null);var o=Te(e);o.seriesIndex=a.seriesIndex,e.on("mousemove",function(s){o.dataIndex=null;var l=e.hoverDataIdx;l>0&&(o.dataIndex=l+e.__startIndex)})},r.prototype._clear=function(){this._newAdded=[],this.group.removeAll()},r}(),zee=Pee,kee={seriesType:"lines",plan:hu(),reset:function(r){var e=r.coordinateSystem;if(!!e){var t=r.get("polyline"),n=r.pipelineContext.large;return{progress:function(a,i){var o=[];if(n){var s=void 0,l=a.end-a.start;if(t){for(var u=0,c=a.start;c<a.end;c++)u+=r.getLineCoordsCount(c);s=new Float32Array(l+u*2)}else s=new Float32Array(l*4);for(var f=0,h=[],c=a.start;c<a.end;c++){var v=r.getLineCoords(c,o);t&&(s[f++]=v);for(var d=0;d<v;d++)h=e.dataToPoint(o[d],!1,h),s[f++]=h[0],s[f++]=h[1]}i.setLayout("linesPoints",s)}else for(var c=a.start;c<a.end;c++){var p=i.getItemModel(c),v=r.getLineCoords(c,o),g=[];if(t)for(var y=0;y<v;y++)g.push(e.dataToPoint(o[y]));else{g[0]=e.dataToPoint(o[0]),g[1]=e.dataToPoint(o[1]);var m=p.get(["lineStyle","curveness"]);+m&&(g[2]=[(g[0][0]+g[1][0])/2-(g[0][1]-g[1][1])*m,(g[0][1]+g[1][1])/2-(g[1][0]-g[0][0])*m])}i.setItemLayout(c,g)}}}}}},M4=kee,Ree=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a){var i=t.getData(),o=this._updateLineDraw(i,t),s=t.get("zlevel"),l=t.get(["effect","trailLength"]),u=a.getZr(),c=u.painter.getType()==="svg";c||u.painter.getLayer(s).clear(!0),this._lastZlevel!=null&&!c&&u.configLayer(this._lastZlevel,{motionBlur:!1}),this._showEffect(t)&&l>0&&(c||u.configLayer(s,{motionBlur:!0,lastFrameAlpha:Math.max(Math.min(l/10+.9,1),0)})),o.updateData(i);var f=t.get("clip",!0)&&Lp(t.coordinateSystem,!1,t);f?this.group.setClipPath(f):this.group.removeClipPath(),this._lastZlevel=s,this._finished=!0},e.prototype.incrementalPrepareRender=function(t,n,a){var i=t.getData(),o=this._updateLineDraw(i,t);o.incrementalPrepareUpdate(i),this._clearLayer(a),this._finished=!1},e.prototype.incrementalRender=function(t,n,a){this._lineDraw.incrementalUpdate(t,n.getData()),this._finished=t.end===n.getData().count()},e.prototype.eachRendered=function(t){this._lineDraw&&this._lineDraw.eachRendered(t)},e.prototype.updateTransform=function(t,n,a){var i=t.getData(),o=t.pipelineContext;if(!this._finished||o.large||o.progressiveRender)return{update:!0};var s=M4.reset(t,n,a);s.progress&&s.progress({start:0,end:i.count(),count:i.count()},i),this._lineDraw.updateLayout(),this._clearLayer(a)},e.prototype._updateLineDraw=function(t,n){var a=this._lineDraw,i=this._showEffect(n),o=!!n.get("polyline"),s=n.pipelineContext,l=s.large;return(!a||i!==this._hasEffet||o!==this._isPolyline||l!==this._isLargeDraw)&&(a&&a.remove(),a=this._lineDraw=l?new zee:new iM(o?i?Lee:b4:i?_4:nM),this._hasEffet=i,this._isPolyline=o,this._isLargeDraw=l),this.group.add(a.group),a},e.prototype._showEffect=function(t){return!!t.get(["effect","show"])},e.prototype._clearLayer=function(t){var n=t.getZr(),a=n.painter.getType()==="svg";!a&&this._lastZlevel!=null&&n.painter.getLayer(this._lastZlevel).clear(!0)},e.prototype.remove=function(t,n){this._lineDraw&&this._lineDraw.remove(),this._lineDraw=null,this._clearLayer(n)},e.prototype.dispose=function(t,n){this.remove(t,n)},e.type="lines",e}(ht),jee=Ree,Bee=typeof Uint32Array=="undefined"?Array:Uint32Array,Fee=typeof Float64Array=="undefined"?Array:Float64Array;function x4(r){var e=r.data;e&&e[0]&&e[0][0]&&e[0][0].coord&&(r.data=K(e,function(t){var n=[t[0].coord,t[1].coord],a={coords:n};return t[0].name&&(a.fromName=t[0].name),t[1].name&&(a.toName=t[1].name),Dv([a,t[0],t[1]])}))}var Vee=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.visualStyleAccessPath="lineStyle",t.visualDrawType="stroke",t}return e.prototype.init=function(t){t.data=t.data||[],x4(t);var n=this._processFlatCoordsArray(t.data);this._flatCoords=n.flatCoords,this._flatCoordsOffset=n.flatCoordsOffset,n.flatCoords&&(t.data=new Float32Array(n.count)),r.prototype.init.apply(this,arguments)},e.prototype.mergeOption=function(t){if(x4(t),t.data){var n=this._processFlatCoordsArray(t.data);this._flatCoords=n.flatCoords,this._flatCoordsOffset=n.flatCoordsOffset,n.flatCoords&&(t.data=new Float32Array(n.count))}r.prototype.mergeOption.apply(this,arguments)},e.prototype.appendData=function(t){var n=this._processFlatCoordsArray(t.data);n.flatCoords&&(this._flatCoords?(this._flatCoords=gc(this._flatCoords,n.flatCoords),this._flatCoordsOffset=gc(this._flatCoordsOffset,n.flatCoordsOffset)):(this._flatCoords=n.flatCoords,this._flatCoordsOffset=n.flatCoordsOffset),t.data=new Float32Array(n.count)),this.getRawData().appendData(t.data)},e.prototype._getCoordsFromItemModel=function(t){var n=this.getData().getItemModel(t),a=n.option instanceof Array?n.option:n.getShallow("coords");return a},e.prototype.getLineCoordsCount=function(t){return this._flatCoordsOffset?this._flatCoordsOffset[t*2+1]:this._getCoordsFromItemModel(t).length},e.prototype.getLineCoords=function(t,n){if(this._flatCoordsOffset){for(var a=this._flatCoordsOffset[t*2],i=this._flatCoordsOffset[t*2+1],o=0;o<i;o++)n[o]=n[o]||[],n[o][0]=this._flatCoords[a+o*2],n[o][1]=this._flatCoords[a+o*2+1];return i}else{for(var s=this._getCoordsFromItemModel(t),o=0;o<s.length;o++)n[o]=n[o]||[],n[o][0]=s[o][0],n[o][1]=s[o][1];return s.length}},e.prototype._processFlatCoordsArray=function(t){var n=0;if(this._flatCoords&&(n=this._flatCoords.length),Ue(t[0])){for(var a=t.length,i=new Bee(a),o=new Fee(a),s=0,l=0,u=0,c=0;c<a;){u++;var f=t[c++];i[l++]=s+n,i[l++]=f;for(var h=0;h<f;h++){var v=t[c++],d=t[c++];o[s++]=v,o[s++]=d}}return{flatCoordsOffset:new Uint32Array(i.buffer,0,l),flatCoords:o,count:u}}return{flatCoordsOffset:null,flatCoords:null,count:t.length}},e.prototype.getInitialData=function(t,n){var a=new jr(["value"],this);return a.hasItemOption=!1,a.initData(t.data,[],function(i,o,s,l){if(i instanceof Array)return NaN;a.hasItemOption=!0;var u=i.value;if(u!=null)return u instanceof Array?u[l]:u}),a},e.prototype.formatTooltip=function(t,n,a){var i=this.getData(),o=i.getItemModel(t),s=o.get("name");if(s)return s;var l=o.get("fromName"),u=o.get("toName"),c=[];return l!=null&&c.push(l),u!=null&&c.push(u),lr("nameValue",{name:c.join(" > ")})},e.prototype.preventIncremental=function(){return!!this.get(["effect","show"])},e.prototype.getProgressive=function(){var t=this.option.progressive;return t==null?this.option.large?1e4:this.get("progressive"):t},e.prototype.getProgressiveThreshold=function(){var t=this.option.progressiveThreshold;return t==null?this.option.large?2e4:this.get("progressiveThreshold"):t},e.prototype.getZLevelKey=function(){var t=this.getModel("effect"),n=t.get("trailLength");return this.getData().count()>this.getProgressiveThreshold()?this.id:t.get("show")&&n>0?n+"":""},e.type="series.lines",e.dependencies=["grid","polar","geo","calendar"],e.defaultOption={coordinateSystem:"geo",z:2,legendHoverLink:!0,xAxisIndex:0,yAxisIndex:0,symbol:["none","none"],symbolSize:[10,10],geoIndex:0,effect:{show:!1,period:4,constantSpeed:0,symbol:"circle",symbolSize:3,loop:!0,trailLength:.2},large:!1,largeThreshold:2e3,polyline:!1,clip:!0,label:{show:!1,position:"end"},lineStyle:{opacity:.5}},e}(bt),Hee=Vee;function ng(r){return r instanceof Array||(r=[r,r]),r}var Wee={seriesType:"lines",reset:function(r){var e=ng(r.get("symbol")),t=ng(r.get("symbolSize")),n=r.getData();n.setVisual("fromSymbol",e&&e[0]),n.setVisual("toSymbol",e&&e[1]),n.setVisual("fromSymbolSize",t&&t[0]),n.setVisual("toSymbolSize",t&&t[1]);function a(i,o){var s=i.getItemModel(o),l=ng(s.getShallow("symbol",!0)),u=ng(s.getShallow("symbolSize",!0));l[0]&&i.setItemVisual(o,"fromSymbol",l[0]),l[1]&&i.setItemVisual(o,"toSymbol",l[1]),u[0]&&i.setItemVisual(o,"fromSymbolSize",u[0]),u[1]&&i.setItemVisual(o,"toSymbolSize",u[1])}return{dataEach:n.hasItemOption?a:null}}},Gee=Wee;function $ee(r){r.registerChartView(jee),r.registerSeriesModel(Hee),r.registerLayout(M4),r.registerVisual(Gee)}var Uee=256,Yee=function(){function r(){this.blurSize=30,this.pointSize=20,this.maxOpacity=1,this.minOpacity=0,this._gradientPixels={inRange:null,outOfRange:null};var e=la.createCanvas();this.canvas=e}return r.prototype.update=function(e,t,n,a,i,o){var s=this._getBrush(),l=this._getGradient(i,"inRange"),u=this._getGradient(i,"outOfRange"),c=this.pointSize+this.blurSize,f=this.canvas,h=f.getContext("2d"),v=e.length;f.width=t,f.height=n;for(var d=0;d<v;++d){var p=e[d],g=p[0],y=p[1],m=p[2],_=a(m);h.globalAlpha=_,h.drawImage(s,g-c,y-c)}if(!f.width||!f.height)return f;for(var b=h.getImageData(0,0,f.width,f.height),x=b.data,M=0,w=x.length,D=this.minOpacity,T=this.maxOpacity,I=T-D;M<w;){var _=x[M+3]/256,A=Math.floor(_*(Uee-1))*4;if(_>0){var N=o(_)?l:u;_>0&&(_=_*I+D),x[M++]=N[A],x[M++]=N[A+1],x[M++]=N[A+2],x[M++]=N[A+3]*_*256}else M+=4}return h.putImageData(b,0,0),f},r.prototype._getBrush=function(){var e=this._brushCanvas||(this._brushCanvas=la.createCanvas()),t=this.pointSize+this.blurSize,n=t*2;e.width=n,e.height=n;var a=e.getContext("2d");return a.clearRect(0,0,n,n),a.shadowOffsetX=n,a.shadowBlur=this.blurSize,a.shadowColor="#000",a.beginPath(),a.arc(-t,t,this.pointSize,0,Math.PI*2,!0),a.closePath(),a.fill(),e},r.prototype._getGradient=function(e,t){for(var n=this._gradientPixels,a=n[t]||(n[t]=new Uint8ClampedArray(256*4)),i=[0,0,0,0],o=0,s=0;s<256;s++)e[t](s/255,!0,i),a[o++]=i[0],a[o++]=i[1],a[o++]=i[2],a[o++]=i[3];return a},r}(),Qee=Yee;function Zee(r,e,t){var n=r[1]-r[0];e=K(e,function(o){return{interval:[(o.interval[0]-r[0])/n,(o.interval[1]-r[0])/n]}});var a=e.length,i=0;return function(o){var s;for(s=i;s<a;s++){var l=e[s].interval;if(l[0]<=o&&o<=l[1]){i=s;break}}if(s===a)for(s=i-1;s>=0;s--){var l=e[s].interval;if(l[0]<=o&&o<=l[1]){i=s;break}}return s>=0&&s<a&&t[s]}}function qee(r,e){var t=r[1]-r[0];return e=[(e[0]-r[0])/t,(e[1]-r[0])/t],function(n){return n>=e[0]&&n<=e[1]}}function w4(r){var e=r.dimensions;return e[0]==="lng"&&e[1]==="lat"}var Xee=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a){var i;n.eachComponent("visualMap",function(s){s.eachTargetSeries(function(l){l===t&&(i=s)})}),this._progressiveEls=null,this.group.removeAll();var o=t.coordinateSystem;o.type==="cartesian2d"||o.type==="calendar"?this._renderOnCartesianAndCalendar(t,a,0,t.getData().count()):w4(o)&&this._renderOnGeo(o,t,i,a)},e.prototype.incrementalPrepareRender=function(t,n,a){this.group.removeAll()},e.prototype.incrementalRender=function(t,n,a,i){var o=n.coordinateSystem;o&&(w4(o)?this.render(n,a,i):(this._progressiveEls=[],this._renderOnCartesianAndCalendar(n,i,t.start,t.end,!0)))},e.prototype.eachRendered=function(t){uo(this._progressiveEls||this.group,t)},e.prototype._renderOnCartesianAndCalendar=function(t,n,a,i,o){var s=t.coordinateSystem,l=Hs(s,"cartesian2d"),u,c,f,h;if(l){var v=s.getAxis("x"),d=s.getAxis("y");u=v.getBandWidth()+.5,c=d.getBandWidth()+.5,f=v.scale.getExtent(),h=d.scale.getExtent()}for(var p=this.group,g=t.getData(),y=t.getModel(["emphasis","itemStyle"]).getItemStyle(),m=t.getModel(["blur","itemStyle"]).getItemStyle(),_=t.getModel(["select","itemStyle"]).getItemStyle(),b=t.get(["itemStyle","borderRadius"]),x=sr(t),M=t.getModel("emphasis"),w=M.get("focus"),D=M.get("blurScope"),T=M.get("disabled"),I=l?[g.mapDimension("x"),g.mapDimension("y"),g.mapDimension("value")]:[g.mapDimension("time"),g.mapDimension("value")],A=a;A<i;A++){var N=void 0,L=g.getItemVisual(A,"style");if(l){var E=g.get(I[0],A),O=g.get(I[1],A);if(isNaN(g.get(I[2],A))||isNaN(E)||isNaN(O)||E<f[0]||E>f[1]||O<h[0]||O>h[1])continue;var P=s.dataToPoint([E,O]);N=new We({shape:{x:P[0]-u/2,y:P[1]-c/2,width:u,height:c},style:L})}else{if(isNaN(g.get(I[1],A)))continue;N=new We({z2:1,shape:s.dataToRect([g.get(I[0],A)]).contentShape,style:L})}if(g.hasItemOption){var H=g.getItemModel(A),F=H.getModel("emphasis");y=F.getModel("itemStyle").getItemStyle(),m=H.getModel(["blur","itemStyle"]).getItemStyle(),_=H.getModel(["select","itemStyle"]).getItemStyle(),b=H.get(["itemStyle","borderRadius"]),w=F.get("focus"),D=F.get("blurScope"),T=F.get("disabled"),x=sr(H)}N.shape.r=b;var G=t.getRawValue(A),Z="-";G&&G[2]!=null&&(Z=G[2]+""),wr(N,x,{labelFetcher:t,labelDataIndex:A,defaultOpacity:L.opacity,defaultText:Z}),N.ensureState("emphasis").style=y,N.ensureState("blur").style=m,N.ensureState("select").style=_,Lt(N,w,D,T),N.incremental=o,o&&(N.states.emphasis.hoverLayer=!0),p.add(N),g.setItemGraphicEl(A,N),this._progressiveEls&&this._progressiveEls.push(N)}},e.prototype._renderOnGeo=function(t,n,a,i){var o=a.targetVisuals.inRange,s=a.targetVisuals.outOfRange,l=n.getData(),u=this._hmLayer||this._hmLayer||new Qee;u.blurSize=n.get("blurSize"),u.pointSize=n.get("pointSize"),u.minOpacity=n.get("minOpacity"),u.maxOpacity=n.get("maxOpacity");var c=t.getViewRect().clone(),f=t.getRoamTransform();c.applyTransform(f);var h=Math.max(c.x,0),v=Math.max(c.y,0),d=Math.min(c.width+c.x,i.getWidth()),p=Math.min(c.height+c.y,i.getHeight()),g=d-h,y=p-v,m=[l.mapDimension("lng"),l.mapDimension("lat"),l.mapDimension("value")],_=l.mapArray(m,function(w,D,T){var I=t.dataToPoint([w,D]);return I[0]-=h,I[1]-=v,I.push(T),I}),b=a.getExtent(),x=a.type==="visualMap.continuous"?qee(b,a.option.range):Zee(b,a.getPieceList(),a.option.selected);u.update(_,g,y,o.color.getNormalizer(),{inRange:o.color.getColorMapper(),outOfRange:s.color.getColorMapper()},x);var M=new pr({style:{width:g,height:y,x:h,y:v,image:u.canvas},silent:!0});this.group.add(M)},e.type="heatmap",e}(ht),Jee=Xee,Kee=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.getInitialData=function(t,n){return Ua(null,this,{generateCoord:"value"})},e.prototype.preventIncremental=function(){var t=uu.get(this.get("coordinateSystem"));if(t&&t.dimensions)return t.dimensions[0]==="lng"&&t.dimensions[1]==="lat"},e.type="series.heatmap",e.dependencies=["grid","geo","calendar"],e.defaultOption={coordinateSystem:"cartesian2d",z:2,geoIndex:0,blurSize:30,pointSize:20,maxOpacity:1,minOpacity:0,select:{itemStyle:{borderColor:"#212121"}}},e}(bt),ete=Kee;function tte(r){r.registerChartView(Jee),r.registerSeriesModel(ete)}var rte=["itemStyle","borderWidth"],D4=[{xy:"x",wh:"width",index:0,posDesc:["left","right"]},{xy:"y",wh:"height",index:1,posDesc:["top","bottom"]}],EM=new pa,nte=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a){var i=this.group,o=t.getData(),s=this._data,l=t.coordinateSystem,u=l.getBaseAxis(),c=u.isHorizontal(),f=l.master.getRect(),h={ecSize:{width:a.getWidth(),height:a.getHeight()},seriesModel:t,coordSys:l,coordSysExtent:[[f.x,f.x+f.width],[f.y,f.y+f.height]],isHorizontal:c,valueDim:D4[+c],categoryDim:D4[1-+c]};return o.diff(s).add(function(v){if(!!o.hasValue(v)){var d=L4(o,v),p=S4(o,v,d,h),g=E4(o,h,p);o.setItemGraphicEl(v,g),i.add(g),z4(g,h,p)}}).update(function(v,d){var p=s.getItemGraphicEl(d);if(!o.hasValue(v)){i.remove(p);return}var g=L4(o,v),y=S4(o,v,g,h),m=P4(o,y);p&&m!==p.__pictorialShapeStr&&(i.remove(p),o.setItemGraphicEl(v,null),p=null),p?cte(p,h,y):p=E4(o,h,y,!0),o.setItemGraphicEl(v,p),p.__pictorialSymbolMeta=y,i.add(p),z4(p,h,y)}).remove(function(v){var d=s.getItemGraphicEl(v);d&&O4(s,v,d.__pictorialSymbolMeta.animationModel,d)}).execute(),this._data=o,this.group},e.prototype.remove=function(t,n){var a=this.group,i=this._data;t.get("animation")?i&&i.eachItemGraphicEl(function(o){O4(i,Te(o).dataIndex,t,o)}):a.removeAll()},e.type="pictorialBar",e}(ht);function S4(r,e,t,n){var a=r.getItemLayout(e),i=t.get("symbolRepeat"),o=t.get("symbolClip"),s=t.get("symbolPosition")||"start",l=t.get("symbolRotate"),u=(l||0)*Math.PI/180||0,c=t.get("symbolPatternSize")||2,f=t.isAnimationEnabled(),h={dataIndex:e,layout:a,itemModel:t,symbolType:r.getItemVisual(e,"symbol")||"circle",style:r.getItemVisual(e,"style"),symbolClip:o,symbolRepeat:i,symbolRepeatDirection:t.get("symbolRepeatDirection"),symbolPatternSize:c,rotation:u,animationModel:f?t:null,hoverScale:f&&t.get(["emphasis","scale"]),z2:t.getShallow("z",!0)||0};ate(t,i,a,n,h),ite(r,e,a,i,o,h.boundingLength,h.pxSign,c,n,h),ote(t,h.symbolScale,u,n,h);var v=h.symbolSize,d=pu(t.get("symbolOffset"),v);return ste(t,v,a,i,o,d,s,h.valueLineWidth,h.boundingLength,h.repeatCutLength,n,h),h}function ate(r,e,t,n,a){var i=n.valueDim,o=r.get("symbolBoundingData"),s=n.coordSys.getOtherAxis(n.coordSys.getBaseAxis()),l=s.toGlobalCoord(s.dataToCoord(0)),u=1-+(t[i.wh]<=0),c;if(J(o)){var f=[OM(s,o[0])-l,OM(s,o[1])-l];f[1]<f[0]&&f.reverse(),c=f[u]}else o!=null?c=OM(s,o)-l:e?c=n.coordSysExtent[i.index][u]-l:c=t[i.wh];a.boundingLength=c,e&&(a.repeatCutLength=t[i.wh]),a.pxSign=c>0?1:-1}function OM(r,e){return r.toGlobalCoord(r.dataToCoord(r.scale.parse(e)))}function ite(r,e,t,n,a,i,o,s,l,u){var c=l.valueDim,f=l.categoryDim,h=Math.abs(t[f.wh]),v=r.getItemVisual(e,"symbolSize"),d;J(v)?d=v.slice():v==null?d=["100%","100%"]:d=[v,v],d[f.index]=ue(d[f.index],h),d[c.index]=ue(d[c.index],n?h:Math.abs(i)),u.symbolSize=d;var p=u.symbolScale=[d[0]/s,d[1]/s];p[c.index]*=(l.isHorizontal?-1:1)*o}function ote(r,e,t,n,a){var i=r.get(rte)||0;i&&(EM.attr({scaleX:e[0],scaleY:e[1],rotation:t}),EM.updateTransform(),i/=EM.getLineScale(),i*=e[n.valueDim.index]),a.valueLineWidth=i||0}function ste(r,e,t,n,a,i,o,s,l,u,c,f){var h=c.categoryDim,v=c.valueDim,d=f.pxSign,p=Math.max(e[v.index]+s,0),g=p;if(n){var y=Math.abs(l),m=ar(r.get("symbolMargin"),"15%")+"",_=!1;m.lastIndexOf("!")===m.length-1&&(_=!0,m=m.slice(0,m.length-1));var b=ue(m,e[v.index]),x=Math.max(p+b*2,0),M=_?0:b*2,w=A0(n),D=w?n:k4((y+M)/x),T=y-D*p;b=T/2/(_?D:Math.max(D-1,1)),x=p+b*2,M=_?0:b*2,!w&&n!=="fixed"&&(D=u?k4((Math.abs(u)+M)/x):0),g=D*x-M,f.repeatTimes=D,f.symbolMargin=b}var I=d*(g/2),A=f.pathPosition=[];A[h.index]=t[h.wh]/2,A[v.index]=o==="start"?I:o==="end"?l-I:l/2,i&&(A[0]+=i[0],A[1]+=i[1]);var N=f.bundlePosition=[];N[h.index]=t[h.xy],N[v.index]=t[v.xy];var L=f.barRectShape=X({},t);L[v.wh]=d*Math.max(Math.abs(t[v.wh]),Math.abs(A[v.index]+I)),L[h.wh]=t[h.wh];var E=f.clipShape={};E[h.xy]=-t[h.xy],E[h.wh]=c.ecSize[h.wh],E[v.xy]=0,E[v.wh]=t[v.wh]}function I4(r){var e=r.symbolPatternSize,t=Ft(r.symbolType,-e/2,-e/2,e,e);return t.attr({culling:!0}),t.type!=="image"&&t.setStyle({strokeNoScale:!0}),t}function T4(r,e,t,n){var a=r.__pictorialBundle,i=t.symbolSize,o=t.valueLineWidth,s=t.pathPosition,l=e.valueDim,u=t.repeatTimes||0,c=0,f=i[e.valueDim.index]+o+t.symbolMargin*2;for(PM(r,function(p){p.__pictorialAnimationIndex=c,p.__pictorialRepeatTimes=u,c<u?Ou(p,null,d(c),t,n):Ou(p,null,{scaleX:0,scaleY:0},t,n,function(){a.remove(p)}),c++});c<u;c++){var h=I4(t);h.__pictorialAnimationIndex=c,h.__pictorialRepeatTimes=u,a.add(h);var v=d(c);Ou(h,{x:v.x,y:v.y,scaleX:0,scaleY:0},{scaleX:v.scaleX,scaleY:v.scaleY,rotation:v.rotation},t,n)}function d(p){var g=s.slice(),y=t.pxSign,m=p;return(t.symbolRepeatDirection==="start"?y>0:y<0)&&(m=u-1-p),g[l.index]=f*(m-u/2+.5)+s[l.index],{x:g[0],y:g[1],scaleX:t.symbolScale[0],scaleY:t.symbolScale[1],rotation:t.rotation}}}function A4(r,e,t,n){var a=r.__pictorialBundle,i=r.__pictorialMainPath;i?Ou(i,null,{x:t.pathPosition[0],y:t.pathPosition[1],scaleX:t.symbolScale[0],scaleY:t.symbolScale[1],rotation:t.rotation},t,n):(i=r.__pictorialMainPath=I4(t),a.add(i),Ou(i,{x:t.pathPosition[0],y:t.pathPosition[1],scaleX:0,scaleY:0,rotation:t.rotation},{scaleX:t.symbolScale[0],scaleY:t.symbolScale[1]},t,n))}function C4(r,e,t){var n=X({},e.barRectShape),a=r.__pictorialBarRect;a?Ou(a,null,{shape:n},e,t):(a=r.__pictorialBarRect=new We({z2:2,shape:n,silent:!0,style:{stroke:"transparent",fill:"transparent",lineWidth:0}}),a.disableMorphing=!0,r.add(a))}function N4(r,e,t,n){if(t.symbolClip){var a=r.__pictorialClipPath,i=X({},t.clipShape),o=e.valueDim,s=t.animationModel,l=t.dataIndex;if(a)Qe(a,{shape:i},s,l);else{i[o.wh]=0,a=new We({shape:i}),r.__pictorialBundle.setClipPath(a),r.__pictorialClipPath=a;var u={};u[o.wh]=t.clipShape[o.wh],uf[n?"updateProps":"initProps"](a,{shape:u},s,l)}}}function L4(r,e){var t=r.getItemModel(e);return t.getAnimationDelayParams=lte,t.isAnimationEnabled=ute,t}function lte(r){return{index:r.__pictorialAnimationIndex,count:r.__pictorialRepeatTimes}}function ute(){return this.parentModel.isAnimationEnabled()&&!!this.getShallow("animation")}function E4(r,e,t,n){var a=new De,i=new De;return a.add(i),a.__pictorialBundle=i,i.x=t.bundlePosition[0],i.y=t.bundlePosition[1],t.symbolRepeat?T4(a,e,t):A4(a,e,t),C4(a,t,n),N4(a,e,t,n),a.__pictorialShapeStr=P4(r,t),a.__pictorialSymbolMeta=t,a}function cte(r,e,t){var n=t.animationModel,a=t.dataIndex,i=r.__pictorialBundle;Qe(i,{x:t.bundlePosition[0],y:t.bundlePosition[1]},n,a),t.symbolRepeat?T4(r,e,t,!0):A4(r,e,t,!0),C4(r,t,!0),N4(r,e,t,!0)}function O4(r,e,t,n){var a=n.__pictorialBarRect;a&&a.removeTextContent();var i=[];PM(n,function(o){i.push(o)}),n.__pictorialMainPath&&i.push(n.__pictorialMainPath),n.__pictorialClipPath&&(t=null),C(i,function(o){so(o,{scaleX:0,scaleY:0},t,e,function(){n.parent&&n.parent.remove(n)})}),r.setItemGraphicEl(e,null)}function P4(r,e){return[r.getItemVisual(e.dataIndex,"symbol")||"none",!!e.symbolRepeat,!!e.symbolClip].join(":")}function PM(r,e,t){C(r.__pictorialBundle.children(),function(n){n!==r.__pictorialBarRect&&e.call(t,n)})}function Ou(r,e,t,n,a,i){e&&r.attr(e),n.symbolClip&&!a?t&&r.attr(t):t&&uf[a?"updateProps":"initProps"](r,t,n.animationModel,n.dataIndex,i)}function z4(r,e,t){var n=t.dataIndex,a=t.itemModel,i=a.getModel("emphasis"),o=i.getModel("itemStyle").getItemStyle(),s=a.getModel(["blur","itemStyle"]).getItemStyle(),l=a.getModel(["select","itemStyle"]).getItemStyle(),u=a.getShallow("cursor"),c=i.get("focus"),f=i.get("blurScope"),h=i.get("scale");PM(r,function(p){if(p instanceof pr){var g=p.style;p.useStyle(X({image:g.image,x:g.x,y:g.y,width:g.width,height:g.height},t.style))}else p.useStyle(t.style);var y=p.ensureState("emphasis");y.style=o,h&&(y.scaleX=p.scaleX*1.1,y.scaleY=p.scaleY*1.1),p.ensureState("blur").style=s,p.ensureState("select").style=l,u&&(p.cursor=u),p.z2=t.z2});var v=e.valueDim.posDesc[+(t.boundingLength>0)],d=r.__pictorialBarRect;wr(d,sr(a),{labelFetcher:e.seriesModel,labelDataIndex:n,defaultText:wu(e.seriesModel.getData(),n),inheritColor:t.style.fill,defaultOpacity:t.style.opacity,defaultOutsidePosition:v}),Lt(r,c,f,i.get("disabled"))}function k4(r){var e=Math.round(r);return Math.abs(r-e)<1e-4?e:Math.ceil(r)}var fte=nte,hte=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t.defaultSymbol="roundRect",t}return e.prototype.getInitialData=function(t){return t.stack=null,r.prototype.getInitialData.apply(this,arguments)},e.type="series.pictorialBar",e.dependencies=["grid"],e.defaultOption=co(Ep.defaultOption,{symbol:"circle",symbolSize:null,symbolRotate:null,symbolPosition:null,symbolOffset:null,symbolMargin:null,symbolRepeat:!1,symbolRepeatDirection:"end",symbolClip:!1,symbolBoundingData:null,symbolPatternSize:400,barGap:"-100%",progressive:0,emphasis:{scale:!1},select:{itemStyle:{borderColor:"#212121"}}}),e}(Ep),vte=hte;function dte(r){r.registerChartView(fte),r.registerSeriesModel(vte),r.registerLayout(r.PRIORITY.VISUAL.LAYOUT,Ae(ZL,"pictorialBar")),r.registerLayout(r.PRIORITY.VISUAL.PROGRESSIVE_LAYOUT,qL("pictorialBar"))}var pte=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._layers=[],t}return e.prototype.render=function(t,n,a){var i=t.getData(),o=this,s=this.group,l=t.getLayerSeries(),u=i.getLayout("layoutInfo"),c=u.rect,f=u.boundaryGap;s.x=0,s.y=c.y+f[0];function h(g){return g.name}var v=new Mi(this._layersSeries||[],l,h,h),d=[];v.add(fe(p,this,"add")).update(fe(p,this,"update")).remove(fe(p,this,"remove")).execute();function p(g,y,m){var _=o._layers;if(g==="remove"){s.remove(_[y]);return}for(var b=[],x=[],M,w=l[y].indices,D=0;D<w.length;D++){var T=i.getItemLayout(w[D]),I=T.x,A=T.y0,N=T.y;b.push(I,A),x.push(I,A+N),M=i.getItemVisual(w[D],"style")}var L,E=i.getItemLayout(w[0]),O=t.getModel("label"),P=O.get("margin"),H=t.getModel("emphasis");if(g==="add"){var F=d[y]=new De;L=new fE({shape:{points:b,stackedOnPoints:x,smooth:.4,stackedOnSmooth:.4,smoothConstraint:!1},z2:0}),F.add(L),s.add(F),t.isAnimationEnabled()&&L.setClipPath(gte(L.getBoundingRect(),t,function(){L.removeClipPath()}))}else{var F=_[m];L=F.childAt(0),s.add(F),d[y]=F,Qe(L,{shape:{points:b,stackedOnPoints:x}},t),ya(L)}wr(L,sr(t),{labelDataIndex:w[D-1],defaultText:i.getName(w[D-1]),inheritColor:M.fill},{normal:{verticalAlign:"middle"}}),L.setTextConfig({position:null,local:!0});var G=L.getTextContent();G&&(G.x=E.x-P,G.y=E.y0+E.y/2),L.useStyle(M),i.setItemGraphicEl(y,L),xr(L,t),Lt(L,H.get("focus"),H.get("blurScope"),H.get("disabled"))}this._layersSeries=l,this._layers=d},e.type="themeRiver",e}(ht);function gte(r,e,t){var n=new We({shape:{x:r.x-10,y:r.y-10,width:0,height:r.height+20}});return Dt(n,{shape:{x:r.x-50,width:r.width+100,height:r.height+20}},e,t),n}var yte=pte,zM=2,mte=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t){r.prototype.init.apply(this,arguments),this.legendVisualProvider=new Qf(fe(this.getData,this),fe(this.getRawData,this))},e.prototype.fixData=function(t){var n=t.length,a={},i=L0(t,function(h){return a.hasOwnProperty(h[0]+"")||(a[h[0]+""]=-1),h[2]}),o=[];i.buckets.each(function(h,v){o.push({name:v,dataList:h})});for(var s=o.length,l=0;l<s;++l){for(var u=o[l].name,c=0;c<o[l].dataList.length;++c){var f=o[l].dataList[c][0]+"";a[f]=l}for(var f in a)a.hasOwnProperty(f)&&a[f]!==l&&(a[f]=l,t[n]=[f,0,u],n++)}return t},e.prototype.getInitialData=function(t,n){for(var a=this.getReferringComponents("singleAxis",Ut).models[0],i=a.get("type"),o=ot(t.data,function(d){return d[2]!==void 0}),s=this.fixData(o||[]),l=[],u=this.nameMap=ge(),c=0,f=0;f<s.length;++f)l.push(s[f][zM]),u.get(s[f][zM])||(u.set(s[f][zM],c),c++);var h=_u(s,{coordDimensions:["single"],dimensionsDefine:[{name:"time",type:hp(i)},{name:"value",type:"float"},{name:"name",type:"ordinal"}],encodeDefine:{single:0,value:1,itemName:2}}).dimensions,v=new jr(h,this);return v.initData(s),v},e.prototype.getLayerSeries=function(){for(var t=this.getData(),n=t.count(),a=[],i=0;i<n;++i)a[i]=i;var o=t.mapDimension("single"),s=L0(a,function(u){return t.get("name",u)}),l=[];return s.buckets.each(function(u,c){u.sort(function(f,h){return t.get(o,f)-t.get(o,h)}),l.push({name:c,indices:u})}),l},e.prototype.getAxisTooltipData=function(t,n,a){J(t)||(t=t?[t]:[]);for(var i=this.getData(),o=this.getLayerSeries(),s=[],l=o.length,u,c=0;c<l;++c){for(var f=Number.MAX_VALUE,h=-1,v=o[c].indices.length,d=0;d<v;++d){var p=i.get(t[0],o[c].indices[d]),g=Math.abs(p-n);g<=f&&(u=p,f=g,h=o[c].indices[d])}s.push(h)}return{dataIndices:s,nestestValue:u}},e.prototype.formatTooltip=function(t,n,a){var i=this.getData(),o=i.getName(t),s=i.get(i.mapDimension("value"),t);return lr("nameValue",{name:o,value:s})},e.type="series.themeRiver",e.dependencies=["singleAxis"],e.defaultOption={z:2,colorBy:"data",coordinateSystem:"singleAxis",boundaryGap:["10%","10%"],singleAxisIndex:0,animationEasing:"linear",label:{margin:4,show:!0,position:"left",fontSize:11},emphasis:{label:{show:!0}}},e}(bt),_te=mte;function bte(r,e){r.eachSeriesByType("themeRiver",function(t){var n=t.getData(),a=t.coordinateSystem,i={},o=a.getRect();i.rect=o;var s=t.get("boundaryGap"),l=a.getAxis();if(i.boundaryGap=s,l.orient==="horizontal"){s[0]=ue(s[0],o.height),s[1]=ue(s[1],o.height);var u=o.height-s[0]-s[1];R4(n,t,u)}else{s[0]=ue(s[0],o.width),s[1]=ue(s[1],o.width);var c=o.width-s[0]-s[1];R4(n,t,c)}n.setLayout("layoutInfo",i)})}function R4(r,e,t){if(!!r.count())for(var n=e.coordinateSystem,a=e.getLayerSeries(),i=r.mapDimension("single"),o=r.mapDimension("value"),s=K(a,function(g){return K(g.indices,function(y){var m=n.dataToPoint(r.get(i,y));return m[1]=r.get(o,y),m})}),l=Mte(s),u=l.y0,c=t/l.max,f=a.length,h=a[0].indices.length,v,d=0;d<h;++d){v=u[d]*c,r.setItemLayout(a[0].indices[d],{layerIndex:0,x:s[0][d][0],y0:v,y:s[0][d][1]*c});for(var p=1;p<f;++p)v+=s[p-1][d][1]*c,r.setItemLayout(a[p].indices[d],{layerIndex:p,x:s[p][d][0],y0:v,y:s[p][d][1]*c})}}function Mte(r){for(var e=r.length,t=r[0].length,n=[],a=[],i=0,o=0;o<t;++o){for(var s=0,l=0;l<e;++l)s+=r[l][o][1];s>i&&(i=s),n.push(s)}for(var u=0;u<t;++u)a[u]=(i-n[u])/2;i=0;for(var c=0;c<t;++c){var f=n[c]+a[c];f>i&&(i=f)}return{y0:a,max:i}}function xte(r){r.registerChartView(yte),r.registerSeriesModel(_te),r.registerLayout(bte),r.registerProcessor(Yf("themeRiver"))}var wte=2,Dte=4,Ste=function(r){U(e,r);function e(t,n,a,i){var o=r.call(this)||this;o.z2=wte,o.textConfig={inside:!0},Te(o).seriesIndex=n.seriesIndex;var s=new Ge({z2:Dte,silent:t.getModel().get(["label","silent"])});return o.setTextContent(s),o.updateData(!0,t,n,a,i),o}return e.prototype.updateData=function(t,n,a,i,o){this.node=n,n.piece=this,a=a||this._seriesModel,i=i||this._ecModel;var s=this;Te(s).dataIndex=n.dataIndex;var l=n.getModel(),u=l.getModel("emphasis"),c=n.getLayout(),f=X({},c);f.label=null;var h=n.getVisual("style");h.lineJoin="bevel";var v=n.getVisual("decal");v&&(h.decal=yu(v,o));var d=Du(l.getModel("itemStyle"),f,!0);X(f,d),C(Qr,function(m){var _=s.ensureState(m),b=l.getModel([m,"itemStyle"]);_.style=b.getItemStyle();var x=Du(b,f);x&&(_.shape=x)}),t?(s.setShape(f),s.shape.r=c.r0,Qe(s,{shape:{r:c.r}},a,n.dataIndex)):(Qe(s,{shape:f},a),ya(s)),s.useStyle(h),this._updateLabel(a);var p=l.getShallow("cursor");p&&s.attr("cursor",p),this._seriesModel=a||this._seriesModel,this._ecModel=i||this._ecModel;var g=u.get("focus"),y=g==="ancestor"?n.getAncestorsIndices():g==="descendant"?n.getDescendantIndices():g;Lt(this,y,u.get("blurScope"),u.get("disabled"))},e.prototype._updateLabel=function(t){var n=this,a=this.node.getModel(),i=a.getModel("label"),o=this.node.getLayout(),s=o.endAngle-o.startAngle,l=(o.startAngle+o.endAngle)/2,u=Math.cos(l),c=Math.sin(l),f=this,h=f.getTextContent(),v=this.node.dataIndex,d=i.get("minAngle")/180*Math.PI,p=i.get("show")&&!(d!=null&&Math.abs(s)<d);h.ignore=!p,C(Zc,function(y){var m=y==="normal"?a.getModel("label"):a.getModel([y,"label"]),_=y==="normal",b=_?h:h.ensureState(y),x=t.getFormattedLabel(v,y);_&&(x=x||n.node.name),b.style=yt(m,{},null,y!=="normal",!0),x&&(b.style.text=x);var M=m.get("show");M!=null&&!_&&(b.ignore=!M);var w=g(m,"position"),D=_?f:f.states[y],T=D.style.fill;D.textConfig={outsideFill:m.get("color")==="inherit"?T:null,inside:w!=="outside"};var I,A=g(m,"distance")||0,N=g(m,"align");w==="outside"?(I=o.r+A,N=l>Math.PI/2?"right":"left"):!N||N==="center"?(s===2*Math.PI&&o.r0===0?I=0:I=(o.r+o.r0)/2,N="center"):N==="left"?(I=o.r0+A,l>Math.PI/2&&(N="right")):N==="right"&&(I=o.r-A,l>Math.PI/2&&(N="left")),b.style.align=N,b.style.verticalAlign=g(m,"verticalAlign")||"middle",b.x=I*u+o.cx,b.y=I*c+o.cy;var L=g(m,"rotate"),E=0;L==="radial"?(E=-l,E<-Math.PI/2&&(E+=Math.PI)):L==="tangential"?(E=Math.PI/2-l,E>Math.PI/2?E-=Math.PI:E<-Math.PI/2&&(E+=Math.PI)):Ue(L)&&(E=L*Math.PI/180),b.rotation=E});function g(y,m){var _=y.get(m);return _==null?i.get(m):_}h.dirtyStyle()},e}(Zr),j4=Ste,kM="sunburstRootToNode",B4="sunburstHighlight",Ite="sunburstUnhighlight";function Tte(r){r.registerAction({type:kM,update:"updateView"},function(e,t){t.eachComponent({mainType:"series",subType:"sunburst",query:e},n);function n(a,i){var o=th(e,[kM],a);if(o){var s=a.getViewRoot();s&&(e.direction=Rb(s,o.node)?"rollUp":"drillDown"),a.resetViewRoot(o.node)}}}),r.registerAction({type:B4,update:"none"},function(e,t,n){e=X({},e),t.eachComponent({mainType:"series",subType:"sunburst",query:e},a);function a(i){var o=th(e,[B4],i);o&&(e.dataIndex=o.node.dataIndex)}n.dispatchAction(X(e,{type:"highlight"}))}),r.registerAction({type:Ite,update:"updateView"},function(e,t,n){e=X({},e),n.dispatchAction(X(e,{type:"downplay"}))})}var Ate=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a,i){var o=this;this.seriesModel=t,this.api=a,this.ecModel=n;var s=t.getData(),l=s.tree.root,u=t.getViewRoot(),c=this.group,f=t.get("renderLabelForZeroData"),h=[];u.eachNode(function(m){h.push(m)});var v=this._oldChildren||[];d(h,v),y(l,u),this._initEvents(),this._oldChildren=h;function d(m,_){if(m.length===0&&_.length===0)return;new Mi(_,m,b,b).add(x).update(x).remove(Ae(x,null)).execute();function b(M){return M.getId()}function x(M,w){var D=M==null?null:m[M],T=w==null?null:_[w];p(D,T)}}function p(m,_){if(!f&&m&&!m.getValue()&&(m=null),m!==l&&_!==l){if(_&&_.piece)m?(_.piece.updateData(!1,m,t,n,a),s.setItemGraphicEl(m.dataIndex,_.piece)):g(_);else if(m){var b=new j4(m,t,n,a);c.add(b),s.setItemGraphicEl(m.dataIndex,b)}}}function g(m){!m||m.piece&&(c.remove(m.piece),m.piece=null)}function y(m,_){_.depth>0?(o.virtualPiece?o.virtualPiece.updateData(!1,m,t,n,a):(o.virtualPiece=new j4(m,t,n,a),c.add(o.virtualPiece)),_.piece.off("click"),o.virtualPiece.on("click",function(b){o._rootToNode(_.parentNode)})):o.virtualPiece&&(c.remove(o.virtualPiece),o.virtualPiece=null)}},e.prototype._initEvents=function(){var t=this;this.group.off("click"),this.group.on("click",function(n){var a=!1,i=t.seriesModel.getViewRoot();i.eachNode(function(o){if(!a&&o.piece&&o.piece===n.target){var s=o.getModel().get("nodeClick");if(s==="rootToNode")t._rootToNode(o);else if(s==="link"){var l=o.getModel(),u=l.get("link");if(u){var c=l.get("target",!0)||"_blank";Bd(u,c)}}a=!0}})})},e.prototype._rootToNode=function(t){t!==this.seriesModel.getViewRoot()&&this.api.dispatchAction({type:kM,from:this.uid,seriesId:this.seriesModel.id,targetNode:t})},e.prototype.containPoint=function(t,n){var a=n.getData(),i=a.getItemLayout(0);if(i){var o=t[0]-i.cx,s=t[1]-i.cy,l=Math.sqrt(o*o+s*s);return l<=i.r&&l>=i.r0}},e.type="sunburst",e}(ht),Cte=Ate,Nte=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.ignoreStyleOnData=!0,t}return e.prototype.getInitialData=function(t,n){var a={name:t.name,children:t.data};F4(a);var i=this._levelModels=K(t.levels||[],function(l){return new ft(l,this,n)},this),o=kb.createTree(a,this,s);function s(l){l.wrapMethod("getItemModel",function(u,c){var f=o.getNodeByDataIndex(c),h=i[f.depth];return h&&(u.parentModel=h),u})}return o.data},e.prototype.optionUpdated=function(){this.resetViewRoot()},e.prototype.getDataParams=function(t){var n=r.prototype.getDataParams.apply(this,arguments),a=this.getData().tree.getNodeByDataIndex(t);return n.treePathInfo=$p(a,this),n},e.prototype.getLevelModel=function(t){return this._levelModels&&this._levelModels[t.depth]},e.prototype.getViewRoot=function(){return this._viewRoot},e.prototype.resetViewRoot=function(t){t?this._viewRoot=t:t=this._viewRoot;var n=this.getRawData().tree.root;(!t||t!==n&&!n.contains(t))&&(this._viewRoot=n)},e.prototype.enableAriaDecal=function(){XO(this)},e.type="series.sunburst",e.defaultOption={z:2,center:["50%","50%"],radius:[0,"75%"],clockwise:!0,startAngle:90,minAngle:0,stillShowZeroSum:!0,nodeClick:"rootToNode",renderLabelForZeroData:!1,label:{rotate:"radial",show:!0,opacity:1,align:"center",position:"inside",distance:5,silent:!0},itemStyle:{borderWidth:1,borderColor:"white",borderType:"solid",shadowBlur:0,shadowColor:"rgba(0, 0, 0, 0.2)",shadowOffsetX:0,shadowOffsetY:0,opacity:1},emphasis:{focus:"descendant"},blur:{itemStyle:{opacity:.2},label:{opacity:.1}},animationType:"expansion",animationDuration:1e3,animationDurationUpdate:500,data:[],sort:"desc"},e}(bt);function F4(r){var e=0;C(r.children,function(n){F4(n);var a=n.value;J(a)&&(a=a[0]),e+=a});var t=r.value;J(t)&&(t=t[0]),(t==null||isNaN(t))&&(t=e),t<0&&(t=0),J(r.value)?r.value[0]=t:r.value=t}var Lte=Nte,V4=Math.PI/180;function Ete(r,e,t){e.eachSeriesByType(r,function(n){var a=n.get("center"),i=n.get("radius");J(i)||(i=[0,i]),J(a)||(a=[a,a]);var o=t.getWidth(),s=t.getHeight(),l=Math.min(o,s),u=ue(a[0],o),c=ue(a[1],s),f=ue(i[0],l/2),h=ue(i[1],l/2),v=-n.get("startAngle")*V4,d=n.get("minAngle")*V4,p=n.getData().tree.root,g=n.getViewRoot(),y=g.depth,m=n.get("sort");m!=null&&H4(g,m);var _=0;C(g.children,function(P){!isNaN(P.getValue())&&_++});var b=g.getValue(),x=Math.PI/(b||_)*2,M=g.depth>0,w=g.height-(M?-1:1),D=(h-f)/(w||1),T=n.get("clockwise"),I=n.get("stillShowZeroSum"),A=T?1:-1,N=function(P,H){if(!!P){var F=H;if(P!==p){var G=P.getValue(),Z=b===0&&I?x:G*x;Z<d&&(Z=d),F=H+A*Z;var te=P.depth-y-(M?-1:1),V=f+D*te,Y=f+D*(te+1),q=n.getLevelModel(P);if(q){var Q=q.get("r0",!0),ne=q.get("r",!0),oe=q.get("radius",!0);oe!=null&&(Q=oe[0],ne=oe[1]),Q!=null&&(V=ue(Q,l/2)),ne!=null&&(Y=ue(ne,l/2))}P.setLayout({angle:Z,startAngle:H,endAngle:F,clockwise:T,cx:u,cy:c,r0:V,r:Y})}if(P.children&&P.children.length){var ie=0;C(P.children,function(he){ie+=N(he,H+ie)})}return F-H}};if(M){var L=f,E=f+D,O=Math.PI*2;p.setLayout({angle:O,startAngle:v,endAngle:v+O,clockwise:T,cx:u,cy:c,r0:L,r:E})}N(g,v)})}function H4(r,e){var t=r.children||[];r.children=Ote(t,e),t.length&&C(r.children,function(n){H4(n,e)})}function Ote(r,e){if(ye(e)){var t=K(r,function(a,i){var o=a.getValue();return{params:{depth:a.depth,height:a.height,dataIndex:a.dataIndex,getValue:function(){return o}},index:i}});return t.sort(function(a,i){return e(a.params,i.params)}),K(t,function(a){return r[a.index]})}else{var n=e==="asc";return r.sort(function(a,i){var o=(a.getValue()-i.getValue())*(n?1:-1);return o===0?(a.dataIndex-i.dataIndex)*(n?-1:1):o})}}function Pte(r){var e={};function t(n,a,i){for(var o=n;o&&o.depth>1;)o=o.parentNode;var s=a.getColorFromPalette(o.name||o.dataIndex+"",e);return n.depth>1&&ce(s)&&(s=Vv(s,(n.depth-1)/(i-1)*.5)),s}r.eachSeriesByType("sunburst",function(n){var a=n.getData(),i=a.tree;i.eachNode(function(o){var s=o.getModel(),l=s.getModel("itemStyle").getItemStyle();l.fill||(l.fill=t(o,n,i.root.height));var u=a.ensureUniqueItemVisual(o.dataIndex,"style");X(u,l)})})}function zte(r){r.registerChartView(Cte),r.registerSeriesModel(Lte),r.registerLayout(Ae(Ete,"sunburst")),r.registerProcessor(Ae(Yf,"sunburst")),r.registerVisual(Pte),Tte(r)}var W4={color:"fill",borderColor:"stroke"},kte={symbol:1,symbolSize:1,symbolKeepAspect:1,legendIcon:1,visualMeta:1,liftZ:1,decal:1},Ti=Ye(),Rte=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.optionUpdated=function(){this.currentZLevel=this.get("zlevel",!0),this.currentZ=this.get("z",!0)},e.prototype.getInitialData=function(t,n){return Ua(null,this)},e.prototype.getDataParams=function(t,n,a){var i=r.prototype.getDataParams.call(this,t,n);return a&&(i.info=Ti(a).info),i},e.type="series.custom",e.dependencies=["grid","polar","geo","singleAxis","calendar"],e.defaultOption={coordinateSystem:"cartesian2d",z:2,legendHoverLink:!0,clip:!1},e}(bt),jte=Rte;function Bte(r,e){return e=e||[0,0],K(["x","y"],function(t,n){var a=this.getAxis(t),i=e[n],o=r[n]/2;return a.type==="category"?a.getBandWidth():Math.abs(a.dataToCoord(i-o)-a.dataToCoord(i+o))},this)}function Fte(r){var e=r.master.getRect();return{coordSys:{type:"cartesian2d",x:e.x,y:e.y,width:e.width,height:e.height},api:{coord:function(t){return r.dataToPoint(t)},size:fe(Bte,r)}}}function Vte(r,e){return e=e||[0,0],K([0,1],function(t){var n=e[t],a=r[t]/2,i=[],o=[];return i[t]=n-a,o[t]=n+a,i[1-t]=o[1-t]=e[1-t],Math.abs(this.dataToPoint(i)[t]-this.dataToPoint(o)[t])},this)}function Hte(r){var e=r.getBoundingRect();return{coordSys:{type:"geo",x:e.x,y:e.y,width:e.width,height:e.height,zoom:r.getZoom()},api:{coord:function(t){return r.dataToPoint(t)},size:fe(Vte,r)}}}function Wte(r,e){var t=this.getAxis(),n=e instanceof Array?e[0]:e,a=(r instanceof Array?r[0]:r)/2;return t.type==="category"?t.getBandWidth():Math.abs(t.dataToCoord(n-a)-t.dataToCoord(n+a))}function Gte(r){var e=r.getRect();return{coordSys:{type:"singleAxis",x:e.x,y:e.y,width:e.width,height:e.height},api:{coord:function(t){return r.dataToPoint(t)},size:fe(Wte,r)}}}function $te(r,e){return e=e||[0,0],K(["Radius","Angle"],function(t,n){var a="get"+t+"Axis",i=this[a](),o=e[n],s=r[n]/2,l=i.type==="category"?i.getBandWidth():Math.abs(i.dataToCoord(o-s)-i.dataToCoord(o+s));return t==="Angle"&&(l=l*Math.PI/180),l},this)}function Ute(r){var e=r.getRadiusAxis(),t=r.getAngleAxis(),n=e.getExtent();return n[0]>n[1]&&n.reverse(),{coordSys:{type:"polar",cx:r.cx,cy:r.cy,r:n[1],r0:n[0]},api:{coord:function(a){var i=e.dataToRadius(a[0]),o=t.dataToAngle(a[1]),s=r.coordToPoint([i,o]);return s.push(i,o*Math.PI/180),s},size:fe($te,r)}}}function Yte(r){var e=r.getRect(),t=r.getRangeInfo();return{coordSys:{type:"calendar",x:e.x,y:e.y,width:e.width,height:e.height,cellWidth:r.getCellWidth(),cellHeight:r.getCellHeight(),rangeInfo:{start:t.start,end:t.end,weeks:t.weeks,dayCount:t.allDay}},api:{coord:function(n,a){return r.dataToPoint(n,a)}}}}function G4(r,e,t,n){return r&&(r.legacy||r.legacy!==!1&&!t&&!n&&e!=="tspan"&&(e==="text"||ve(r,"text")))}function $4(r,e,t){var n=r,a,i,o;if(e==="text")o=n;else{o={},ve(n,"text")&&(o.text=n.text),ve(n,"rich")&&(o.rich=n.rich),ve(n,"textFill")&&(o.fill=n.textFill),ve(n,"textStroke")&&(o.stroke=n.textStroke),ve(n,"fontFamily")&&(o.fontFamily=n.fontFamily),ve(n,"fontSize")&&(o.fontSize=n.fontSize),ve(n,"fontStyle")&&(o.fontStyle=n.fontStyle),ve(n,"fontWeight")&&(o.fontWeight=n.fontWeight),i={type:"text",style:o,silent:!0},a={};var s=ve(n,"textPosition");t?a.position=s?n.textPosition:"inside":s&&(a.position=n.textPosition),ve(n,"textPosition")&&(a.position=n.textPosition),ve(n,"textOffset")&&(a.offset=n.textOffset),ve(n,"textRotation")&&(a.rotation=n.textRotation),ve(n,"textDistance")&&(a.distance=n.textDistance)}return U4(o,r),C(o.rich,function(l){U4(l,l)}),{textConfig:a,textContent:i}}function U4(r,e){!e||(e.font=e.textFont||e.font,ve(e,"textStrokeWidth")&&(r.lineWidth=e.textStrokeWidth),ve(e,"textAlign")&&(r.align=e.textAlign),ve(e,"textVerticalAlign")&&(r.verticalAlign=e.textVerticalAlign),ve(e,"textLineHeight")&&(r.lineHeight=e.textLineHeight),ve(e,"textWidth")&&(r.width=e.textWidth),ve(e,"textHeight")&&(r.height=e.textHeight),ve(e,"textBackgroundColor")&&(r.backgroundColor=e.textBackgroundColor),ve(e,"textPadding")&&(r.padding=e.textPadding),ve(e,"textBorderColor")&&(r.borderColor=e.textBorderColor),ve(e,"textBorderWidth")&&(r.borderWidth=e.textBorderWidth),ve(e,"textBorderRadius")&&(r.borderRadius=e.textBorderRadius),ve(e,"textBoxShadowColor")&&(r.shadowColor=e.textBoxShadowColor),ve(e,"textBoxShadowBlur")&&(r.shadowBlur=e.textBoxShadowBlur),ve(e,"textBoxShadowOffsetX")&&(r.shadowOffsetX=e.textBoxShadowOffsetX),ve(e,"textBoxShadowOffsetY")&&(r.shadowOffsetY=e.textBoxShadowOffsetY))}function Y4(r,e,t){var n=r;n.textPosition=n.textPosition||t.position||"inside",t.offset!=null&&(n.textOffset=t.offset),t.rotation!=null&&(n.textRotation=t.rotation),t.distance!=null&&(n.textDistance=t.distance);var a=n.textPosition.indexOf("inside")>=0,i=r.fill||"#000";Q4(n,e);var o=n.textFill==null;return a?o&&(n.textFill=t.insideFill||"#fff",!n.textStroke&&t.insideStroke&&(n.textStroke=t.insideStroke),!n.textStroke&&(n.textStroke=i),n.textStrokeWidth==null&&(n.textStrokeWidth=2)):(o&&(n.textFill=r.fill||t.outsideFill||"#000"),!n.textStroke&&t.outsideStroke&&(n.textStroke=t.outsideStroke)),n.text=e.text,n.rich=e.rich,C(e.rich,function(s){Q4(s,s)}),n}function Q4(r,e){!e||(ve(e,"fill")&&(r.textFill=e.fill),ve(e,"stroke")&&(r.textStroke=e.fill),ve(e,"lineWidth")&&(r.textStrokeWidth=e.lineWidth),ve(e,"font")&&(r.font=e.font),ve(e,"fontStyle")&&(r.fontStyle=e.fontStyle),ve(e,"fontWeight")&&(r.fontWeight=e.fontWeight),ve(e,"fontSize")&&(r.fontSize=e.fontSize),ve(e,"fontFamily")&&(r.fontFamily=e.fontFamily),ve(e,"align")&&(r.textAlign=e.align),ve(e,"verticalAlign")&&(r.textVerticalAlign=e.verticalAlign),ve(e,"lineHeight")&&(r.textLineHeight=e.lineHeight),ve(e,"width")&&(r.textWidth=e.width),ve(e,"height")&&(r.textHeight=e.height),ve(e,"backgroundColor")&&(r.textBackgroundColor=e.backgroundColor),ve(e,"padding")&&(r.textPadding=e.padding),ve(e,"borderColor")&&(r.textBorderColor=e.borderColor),ve(e,"borderWidth")&&(r.textBorderWidth=e.borderWidth),ve(e,"borderRadius")&&(r.textBorderRadius=e.borderRadius),ve(e,"shadowColor")&&(r.textBoxShadowColor=e.shadowColor),ve(e,"shadowBlur")&&(r.textBoxShadowBlur=e.shadowBlur),ve(e,"shadowOffsetX")&&(r.textBoxShadowOffsetX=e.shadowOffsetX),ve(e,"shadowOffsetY")&&(r.textBoxShadowOffsetY=e.shadowOffsetY),ve(e,"textShadowColor")&&(r.textShadowColor=e.textShadowColor),ve(e,"textShadowBlur")&&(r.textShadowBlur=e.textShadowBlur),ve(e,"textShadowOffsetX")&&(r.textShadowOffsetX=e.textShadowOffsetX),ve(e,"textShadowOffsetY")&&(r.textShadowOffsetY=e.textShadowOffsetY))}var Z4={position:["x","y"],scale:["scaleX","scaleY"],origin:["originX","originY"]},q4=Fe(Z4);On(ka,function(r,e){return r[e]=1,r},{}),ka.join(", ");var ag=["","style","shape","extra"],Pu=Ye();function RM(r,e,t,n,a){var i=r+"Animation",o=ql(r,n,a)||{},s=Pu(e).userDuring;return o.duration>0&&(o.during=s?fe(Jte,{el:e,userDuring:s}):null,o.setToFinal=!0,o.scope=r),X(o,t[i]),o}function ig(r,e,t,n){n=n||{};var a=n.dataIndex,i=n.isInit,o=n.clearStyle,s=t.isAnimationEnabled(),l=Pu(r),u=e.style;l.userDuring=e.during;var c={},f={};if(ere(r,e,f),K4("shape",e,f),K4("extra",e,f),!i&&s&&(Kte(r,e,c),J4("shape",r,e,c),J4("extra",r,e,c),tre(r,e,u,c)),f.style=u,Qte(r,f,o),qte(r,e),s)if(i){var h={};C(ag,function(d){var p=d?e[d]:e;p&&p.enterFrom&&(d&&(h[d]=h[d]||{}),X(d?h[d]:h,p.enterFrom))});var v=RM("enter",r,e,t,a);v.duration>0&&r.animateFrom(h,v)}else Zte(r,e,a||0,t,c);X4(r,e),u?r.dirty():r.markRedraw()}function X4(r,e){for(var t=Pu(r).leaveToProps,n=0;n<ag.length;n++){var a=ag[n],i=a?e[a]:e;i&&i.leaveTo&&(t||(t=Pu(r).leaveToProps={}),a&&(t[a]=t[a]||{}),X(a?t[a]:t,i.leaveTo))}}function og(r,e,t,n){if(r){var a=r.parent,i=Pu(r).leaveToProps;if(i){var o=RM("update",r,e,t,0);o.done=function(){a.remove(r),n&&n()},r.animateTo(i,o)}else a.remove(r),n&&n()}}function Ks(r){return r==="all"}function Qte(r,e,t){var n=e.style;if(!r.isGroup&&n){if(t){r.useStyle({});for(var a=r.animators,i=0;i<a.length;i++){var o=a[i];o.targetName==="style"&&o.changeTarget(r.style)}}r.setStyle(n)}e&&(e.style=null,e&&r.attr(e),e.style=n)}function Zte(r,e,t,n,a){if(a){var i=RM("update",r,e,n,t);i.duration>0&&r.animateFrom(a,i)}}function qte(r,e){ve(e,"silent")&&(r.silent=e.silent),ve(e,"ignore")&&(r.ignore=e.ignore),r instanceof Bn&&ve(e,"invisible")&&(r.invisible=e.invisible),r instanceof je&&ve(e,"autoBatch")&&(r.autoBatch=e.autoBatch)}var Xa={},Xte={setTransform:function(r,e){return Xa.el[r]=e,this},getTransform:function(r){return Xa.el[r]},setShape:function(r,e){var t=Xa.el,n=t.shape||(t.shape={});return n[r]=e,t.dirtyShape&&t.dirtyShape(),this},getShape:function(r){var e=Xa.el.shape;if(e)return e[r]},setStyle:function(r,e){var t=Xa.el,n=t.style;return n&&(n[r]=e,t.dirtyStyle&&t.dirtyStyle()),this},getStyle:function(r){var e=Xa.el.style;if(e)return e[r]},setExtra:function(r,e){var t=Xa.el.extra||(Xa.el.extra={});return t[r]=e,this},getExtra:function(r){var e=Xa.el.extra;if(e)return e[r]}};function Jte(){var r=this,e=r.el;if(!!e){var t=Pu(e).userDuring,n=r.userDuring;if(t!==n){r.el=r.userDuring=null;return}Xa.el=e,n(Xte)}}function J4(r,e,t,n){var a=t[r];if(!!a){var i=e[r],o;if(i){var s=t.transition,l=a.transition;if(l)if(!o&&(o=n[r]={}),Ks(l))X(o,i);else for(var u=ct(l),c=0;c<u.length;c++){var f=u[c],h=i[f];o[f]=h}else if(Ks(s)||ze(s,r)>=0){!o&&(o=n[r]={});for(var v=Fe(i),c=0;c<v.length;c++){var f=v[c],h=i[f];rre(a[f],h)&&(o[f]=h)}}}}}function K4(r,e,t){var n=e[r];if(!!n)for(var a=t[r]={},i=Fe(n),o=0;o<i.length;o++){var s=i[o];a[s]=zc(n[s])}}function Kte(r,e,t){for(var n=e.transition,a=Ks(n)?ka:ct(n||[]),i=0;i<a.length;i++){var o=a[i];if(!(o==="style"||o==="shape"||o==="extra")){var s=r[o];t[o]=s}}}function ere(r,e,t){for(var n=0;n<q4.length;n++){var a=q4[n],i=Z4[a],o=e[a];o&&(t[i[0]]=o[0],t[i[1]]=o[1])}for(var n=0;n<ka.length;n++){var s=ka[n];e[s]!=null&&(t[s]=e[s])}}function tre(r,e,t,n){if(!!t){var a=r.style,i;if(a){var o=t.transition,s=e.transition;if(o&&!Ks(o)){var l=ct(o);!i&&(i=n.style={});for(var u=0;u<l.length;u++){var c=l[u],f=a[c];i[c]=f}}else if(r.getAnimationStyleProps&&(Ks(s)||Ks(o)||ze(s,"style")>=0)){var h=r.getAnimationStyleProps(),v=h?h.style:null;if(v){!i&&(i=n.style={});for(var d=Fe(t),u=0;u<d.length;u++){var c=d[u];if(v[c]){var f=a[c];i[c]=f}}}}}}}function rre(r,e){return Mr(r)?r!==e:r!=null&&isFinite(r)}var ez=Ye(),nre=["percent","easing","shape","style","extra"];function tz(r){r.stopAnimation("keyframe"),r.attr(ez(r))}function sg(r,e,t){if(!(!t.isAnimationEnabled()||!e)){if(J(e)){C(e,function(s){sg(r,s,t)});return}var n=e.keyframes,a=e.duration;if(t&&a==null){var i=ql("enter",t,0);a=i&&i.duration}if(!(!n||!a)){var o=ez(r);C(ag,function(s){if(!(s&&!r[s])){var l;n.sort(function(u,c){return u.percent-c.percent}),C(n,function(u){var c=r.animators,f=s?u[s]:u;if(!!f){var h=Fe(f);if(s||(h=ot(h,function(p){return ze(nre,p)<0})),!!h.length){l||(l=r.animate(s,e.loop,!0),l.scope="keyframe");for(var v=0;v<c.length;v++)c[v]!==l&&c[v].targetName===l.targetName&&c[v].stopTracks(h);s&&(o[s]=o[s]||{});var d=s?o[s]:o;C(h,function(p){d[p]=((s?r[s]:r)||{})[p]}),l.whenWithKeys(a*u.percent,f,h,u.easing)}}}),l&&l.delay(e.delay||0).duration(a).start(e.easing)}})}}}var Ai="emphasis",Io="normal",jM="blur",BM="select",To=[Io,Ai,jM,BM],FM={normal:["itemStyle"],emphasis:[Ai,"itemStyle"],blur:[jM,"itemStyle"],select:[BM,"itemStyle"]},VM={normal:["label"],emphasis:[Ai,"label"],blur:[jM,"label"],select:[BM,"label"]},are=["x","y"],ire="e\0\0",Xn={normal:{},emphasis:{},blur:{},select:{}},ore={cartesian2d:Fte,geo:Hte,single:Gte,polar:Ute,calendar:Yte};function HM(r){return r instanceof je}function WM(r){return r instanceof Bn}function sre(r,e){e.copyTransform(r),WM(e)&&WM(r)&&(e.setStyle(r.style),e.z=r.z,e.z2=r.z2,e.zlevel=r.zlevel,e.invisible=r.invisible,e.ignore=r.ignore,HM(e)&&HM(r)&&e.setShape(r.shape))}var lre=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a,i){this._progressiveEls=null;var o=this._data,s=t.getData(),l=this.group,u=nz(t,s,n,a);o||l.removeAll(),s.diff(o).add(function(f){UM(a,null,f,u(f,i),t,l,s)}).remove(function(f){var h=o.getItemGraphicEl(f);h&&og(h,Ti(h).option,t)}).update(function(f,h){var v=o.getItemGraphicEl(h);UM(a,v,f,u(f,i),t,l,s)}).execute();var c=t.get("clip",!0)?Lp(t.coordinateSystem,!1,t):null;c?l.setClipPath(c):l.removeClipPath(),this._data=s},e.prototype.incrementalPrepareRender=function(t,n,a){this.group.removeAll(),this._data=null},e.prototype.incrementalRender=function(t,n,a,i,o){var s=n.getData(),l=nz(n,s,a,i),u=this._progressiveEls=[];function c(v){v.isGroup||(v.incremental=!0,v.ensureState("emphasis").hoverLayer=!0)}for(var f=t.start;f<t.end;f++){var h=UM(null,null,f,l(f,o),n,this.group,s);h&&(h.traverse(c),u.push(h))}},e.prototype.eachRendered=function(t){uo(this._progressiveEls||this.group,t)},e.prototype.filterForExposedEvent=function(t,n,a,i){var o=n.element;if(o==null||a.name===o)return!0;for(;(a=a.__hostTarget||a.parent)&&a!==this.group;)if(a.name===o)return!0;return!1},e.type="custom",e}(ht),ure=lre;function GM(r){var e=r.type,t;if(e==="path"){var n=r.shape,a=n.width!=null&&n.height!=null?{x:n.x||0,y:n.y||0,width:n.width,height:n.height}:null,i=lz(n);t=of(i,null,a,n.layout||"center"),Ti(t).customPathData=i}else if(e==="image")t=new pr({}),Ti(t).customImagePath=r.style.image;else if(e==="text")t=new Ge({});else if(e==="group")t=new De;else{if(e==="compoundPath")throw new Error('"compoundPath" is not supported yet.');var o=Td(e);if(!o){var s="";at(s)}t=new o}return Ti(t).customGraphicType=e,t.name=r.name,t.z2EmphasisLift=1,t.z2SelectLift=1,t}function $M(r,e,t,n,a,i,o){tz(e);var s=a&&a.normal.cfg;s&&e.setTextConfig(s),n&&n.transition==null&&(n.transition=are);var l=n&&n.style;if(l){if(e.type==="text"){var u=l;ve(u,"textFill")&&(u.fill=u.textFill),ve(u,"textStroke")&&(u.stroke=u.textStroke)}var c=void 0,f=HM(e)?l.decal:null;r&&f&&(f.dirty=!0,c=yu(f,r)),l.__decalPattern=c}if(WM(e)&&l){var c=l.__decalPattern;c&&(l.decal=c)}ig(e,n,i,{dataIndex:t,isInit:o,clearStyle:!0}),sg(e,n.keyframeAnimation,i)}function rz(r,e,t,n,a){var i=e.isGroup?null:e,o=a&&a[r].cfg;if(i){var s=i.ensureState(r);if(n===!1){var l=i.getState(r);l&&(l.style=null)}else s.style=n||null;o&&(s.textConfig=o),gs(i)}}function cre(r,e,t){if(!r.isGroup){var n=r,a=t.currentZ,i=t.currentZLevel;n.z=a,n.zlevel=i;var o=e.z2;o!=null&&(n.z2=o||0);for(var s=0;s<To.length;s++)fre(n,e,To[s])}}function fre(r,e,t){var n=t===Io,a=n?e:lg(e,t),i=a?a.z2:null,o;i!=null&&(o=n?r:r.ensureState(t),o.z2=i||0)}function nz(r,e,t,n){var a=r.get("renderItem"),i=r.coordinateSystem,o={};i&&(o=i.prepareCustoms?i.prepareCustoms(i):ore[i.type](i));for(var s=me({getWidth:n.getWidth,getHeight:n.getHeight,getZr:n.getZr,getDevicePixelRatio:n.getDevicePixelRatio,value:b,style:M,ordinalRawValue:x,styleEmphasis:w,visual:I,barLayout:A,currentSeriesIndices:N,font:L},o.api||{}),l={context:{},seriesId:r.id,seriesName:r.name,seriesIndex:r.seriesIndex,coordSys:o.coordSys,dataInsideLength:e.count(),encode:hre(r.getData())},u,c,f={},h={},v={},d={},p=0;p<To.length;p++){var g=To[p];v[g]=r.getModel(FM[g]),d[g]=r.getModel(VM[g])}function y(E){return E===u?c||(c=e.getItemModel(E)):e.getItemModel(E)}function m(E,O){return e.hasItemOption?E===u?f[O]||(f[O]=y(E).getModel(FM[O])):y(E).getModel(FM[O]):v[O]}function _(E,O){return e.hasItemOption?E===u?h[O]||(h[O]=y(E).getModel(VM[O])):y(E).getModel(VM[O]):d[O]}return function(E,O){return u=E,c=null,f={},h={},a&&a(me({dataIndexInside:E,dataIndex:e.getRawIndex(E),actionType:O?O.type:null},l),s)};function b(E,O){return O==null&&(O=u),e.getStore().get(e.getDimensionIndex(E||0),O)}function x(E,O){O==null&&(O=u),E=E||0;var P=e.getDimensionInfo(E);if(!P){var H=e.getDimensionIndex(E);return H>=0?e.getStore().get(H,O):void 0}var F=e.get(P.name,O),G=P&&P.ordinalMeta;return G?G.categories[F]:F}function M(E,O){O==null&&(O=u);var P=e.getItemVisual(O,"style"),H=P&&P.fill,F=P&&P.opacity,G=m(O,Io).getItemStyle();H!=null&&(G.fill=H),F!=null&&(G.opacity=F);var Z={inheritColor:ce(H)?H:"#000"},te=_(O,Io),V=yt(te,null,Z,!1,!0);V.text=te.getShallow("show")?Ee(r.getFormattedLabel(O,Io),wu(e,O)):null;var Y=Ld(te,Z,!1);return T(E,G),G=Y4(G,V,Y),E&&D(G,E),G.legacy=!0,G}function w(E,O){O==null&&(O=u);var P=m(O,Ai).getItemStyle(),H=_(O,Ai),F=yt(H,null,null,!0,!0);F.text=H.getShallow("show")?Ea(r.getFormattedLabel(O,Ai),r.getFormattedLabel(O,Io),wu(e,O)):null;var G=Ld(H,null,!0);return T(E,P),P=Y4(P,F,G),E&&D(P,E),P.legacy=!0,P}function D(E,O){for(var P in O)ve(O,P)&&(E[P]=O[P])}function T(E,O){E&&(E.textFill&&(O.textFill=E.textFill),E.textPosition&&(O.textPosition=E.textPosition))}function I(E,O){if(O==null&&(O=u),ve(W4,E)){var P=e.getItemVisual(O,"style");return P?P[W4[E]]:null}if(ve(kte,E))return e.getItemVisual(O,E)}function A(E){if(i.type==="cartesian2d"){var O=i.getBaseAxis();return eQ(me({axis:O},E))}}function N(){return t.getCurrentSeriesIndices()}function L(E){return UA(E,t)}}function hre(r){var e={};return C(r.dimensions,function(t){var n=r.getDimensionInfo(t);if(!n.isExtraCoord){var a=n.coordDim,i=e[a]=e[a]||[];i[n.coordDimIndex]=r.getDimensionIndex(t)}}),e}function UM(r,e,t,n,a,i,o){if(!n){i.remove(e);return}var s=YM(r,e,t,n,a,i);return s&&o.setItemGraphicEl(t,s),s&&Lt(s,n.focus,n.blurScope,n.emphasisDisabled),s}function YM(r,e,t,n,a,i){var o=-1,s=e;e&&az(e,n,a)&&(o=ze(i.childrenRef(),e),e=null);var l=!e,u=e;u?u.clearStates():(u=GM(n),s&&sre(s,u)),n.morph===!1?u.disableMorphing=!0:u.disableMorphing&&(u.disableMorphing=!1),Xn.normal.cfg=Xn.normal.conOpt=Xn.emphasis.cfg=Xn.emphasis.conOpt=Xn.blur.cfg=Xn.blur.conOpt=Xn.select.cfg=Xn.select.conOpt=null,Xn.isLegacy=!1,dre(u,t,n,a,l,Xn),vre(u,t,n,a,l),$M(r,u,t,n,Xn,a,l),ve(n,"info")&&(Ti(u).info=n.info);for(var c=0;c<To.length;c++){var f=To[c];if(f!==Io){var h=lg(n,f),v=QM(n,h,f);rz(f,u,h,v,Xn)}}return cre(u,n,a),n.type==="group"&&pre(r,u,t,n,a),o>=0?i.replaceAt(u,o):i.add(u),u}function az(r,e,t){var n=Ti(r),a=e.type,i=e.shape,o=e.style;return t.isUniversalTransitionEnabled()||a!=null&&a!==n.customGraphicType||a==="path"&&_re(i)&&lz(i)!==n.customPathData||a==="image"&&ve(o,"image")&&o.image!==n.customImagePath}function vre(r,e,t,n,a){var i=t.clipPath;if(i===!1)r&&r.getClipPath()&&r.removeClipPath();else if(i){var o=r.getClipPath();o&&az(o,i,n)&&(o=null),o||(o=GM(i),r.setClipPath(o)),$M(null,o,e,i,null,n,a)}}function dre(r,e,t,n,a,i){if(!r.isGroup){iz(t,null,i),iz(t,Ai,i);var o=i.normal.conOpt,s=i.emphasis.conOpt,l=i.blur.conOpt,u=i.select.conOpt;if(o!=null||s!=null||u!=null||l!=null){var c=r.getTextContent();if(o===!1)c&&r.removeTextContent();else{o=i.normal.conOpt=o||{type:"text"},c?c.clearStates():(c=GM(o),r.setTextContent(c)),$M(null,c,e,o,null,n,a);for(var f=o&&o.style,h=0;h<To.length;h++){var v=To[h];if(v!==Io){var d=i[v].conOpt;rz(v,c,d,QM(o,d,v),null)}}f?c.dirty():c.markRedraw()}}}}function iz(r,e,t){var n=e?lg(r,e):r,a=e?QM(r,n,Ai):r.style,i=r.type,o=n?n.textConfig:null,s=r.textContent,l=s?e?lg(s,e):s:null;if(a&&(t.isLegacy||G4(a,i,!!o,!!l))){t.isLegacy=!0;var u=$4(a,i,!e);!o&&u.textConfig&&(o=u.textConfig),!l&&u.textContent&&(l=u.textContent)}if(!e&&l){var c=l;!c.type&&(c.type="text")}var f=e?t[e]:t.normal;f.cfg=o,f.conOpt=l}function lg(r,e){return e?r?r[e]:null:r}function QM(r,e,t){var n=e&&e.style;return n==null&&t===Ai&&r&&(n=r.styleEmphasis),n}function pre(r,e,t,n,a){var i=n.children,o=i?i.length:0,s=n.$mergeChildren,l=s==="byName"||n.diffChildrenByName,u=s===!1;if(!(!o&&!l&&!u)){if(l){yre({api:r,oldChildren:e.children()||[],newChildren:i||[],dataIndex:t,seriesModel:a,group:e});return}u&&e.removeAll();for(var c=0;c<o;c++){var f=i[c],h=e.childAt(c);f?(f.ignore==null&&(f.ignore=!1),YM(r,h,t,f,a,e)):h.ignore=!0}for(var v=e.childCount()-1;v>=c;v--){var d=e.childAt(v);gre(e,d,a)}}}function gre(r,e,t){e&&og(e,Ti(r).option,t)}function yre(r){new Mi(r.oldChildren,r.newChildren,oz,oz,r).add(sz).update(sz).remove(mre).execute()}function oz(r,e){var t=r&&r.name;return t!=null?t:ire+e}function sz(r,e){var t=this.context,n=r!=null?t.newChildren[r]:null,a=e!=null?t.oldChildren[e]:null;YM(t.api,a,t.dataIndex,n,t.seriesModel,t.group)}function mre(r){var e=this.context,t=e.oldChildren[r];t&&og(t,Ti(t).option,e.seriesModel)}function lz(r){return r&&(r.pathData||r.d)}function _re(r){return r&&(ve(r,"pathData")||ve(r,"d"))}function bre(r){r.registerChartView(ure),r.registerSeriesModel(jte)}var el=Ye(),uz=Me,ZM=fe,Mre=function(){function r(){this._dragging=!1,this.animationThreshold=15}return r.prototype.render=function(e,t,n,a){var i=t.get("value"),o=t.get("status");if(this._axisModel=e,this._axisPointerModel=t,this._api=n,!(!a&&this._lastValue===i&&this._lastStatus===o)){this._lastValue=i,this._lastStatus=o;var s=this._group,l=this._handle;if(!o||o==="hide"){s&&s.hide(),l&&l.hide();return}s&&s.show(),l&&l.show();var u={};this.makeElOption(u,i,e,t,n);var c=u.graphicKey;c!==this._lastGraphicKey&&this.clear(n),this._lastGraphicKey=c;var f=this._moveAnimation=this.determineAnimation(e,t);if(!s)s=this._group=new De,this.createPointerEl(s,u,e,t),this.createLabelEl(s,u,e,t),n.getZr().add(s);else{var h=Ae(cz,t,f);this.updatePointerEl(s,u,h),this.updateLabelEl(s,u,h,t)}vz(s,t,!0),this._renderHandle(i)}},r.prototype.remove=function(e){this.clear(e)},r.prototype.dispose=function(e){this.clear(e)},r.prototype.determineAnimation=function(e,t){var n=t.get("animation"),a=e.axis,i=a.type==="category",o=t.get("snap");if(!o&&!i)return!1;if(n==="auto"||n==null){var s=this.animationThreshold;if(i&&a.getBandWidth()>s)return!0;if(o){var l=bb(e).seriesDataCount,u=a.getExtent();return Math.abs(u[0]-u[1])/l>s}return!1}return n===!0},r.prototype.makeElOption=function(e,t,n,a,i){},r.prototype.createPointerEl=function(e,t,n,a){var i=t.pointer;if(i){var o=el(e).pointerEl=new uf[i.type](uz(t.pointer));e.add(o)}},r.prototype.createLabelEl=function(e,t,n,a){if(t.label){var i=el(e).labelEl=new Ge(uz(t.label));e.add(i),hz(i,a)}},r.prototype.updatePointerEl=function(e,t,n){var a=el(e).pointerEl;a&&t.pointer&&(a.setStyle(t.pointer.style),n(a,{shape:t.pointer.shape}))},r.prototype.updateLabelEl=function(e,t,n,a){var i=el(e).labelEl;i&&(i.setStyle(t.label.style),n(i,{x:t.label.x,y:t.label.y}),hz(i,a))},r.prototype._renderHandle=function(e){if(!(this._dragging||!this.updateHandleTransform)){var t=this._axisPointerModel,n=this._api.getZr(),a=this._handle,i=t.getModel("handle"),o=t.get("status");if(!i.get("show")||!o||o==="hide"){a&&n.remove(a),this._handle=null;return}var s;this._handle||(s=!0,a=this._handle=Kl(i.get("icon"),{cursor:"move",draggable:!0,onmousemove:function(u){hi(u.event)},onmousedown:ZM(this._onHandleDragMove,this,0,0),drift:ZM(this._onHandleDragMove,this),ondragend:ZM(this._onHandleDragEnd,this)}),n.add(a)),vz(a,t,!1),a.setStyle(i.getItemStyle(null,["color","borderColor","borderWidth","opacity","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"]));var l=i.get("size");J(l)||(l=[l,l]),a.scaleX=l[0]/2,a.scaleY=l[1]/2,vu(this,"_doDispatchAxisPointer",i.get("throttle")||0,"fixRate"),this._moveHandleToValue(e,s)}},r.prototype._moveHandleToValue=function(e,t){cz(this._axisPointerModel,!t&&this._moveAnimation,this._handle,qM(this.getHandleTransform(e,this._axisModel,this._axisPointerModel)))},r.prototype._onHandleDragMove=function(e,t){var n=this._handle;if(!!n){this._dragging=!0;var a=this.updateHandleTransform(qM(n),[e,t],this._axisModel,this._axisPointerModel);this._payloadInfo=a,n.stopAnimation(),n.attr(qM(a)),el(n).lastProp=null,this._doDispatchAxisPointer()}},r.prototype._doDispatchAxisPointer=function(){var e=this._handle;if(!!e){var t=this._payloadInfo,n=this._axisModel;this._api.dispatchAction({type:"updateAxisPointer",x:t.cursorPoint[0],y:t.cursorPoint[1],tooltipOption:t.tooltipOption,axesInfo:[{axisDim:n.axis.dim,axisIndex:n.componentIndex}]})}},r.prototype._onHandleDragEnd=function(){this._dragging=!1;var e=this._handle;if(!!e){var t=this._axisPointerModel.get("value");this._moveHandleToValue(t),this._api.dispatchAction({type:"hideTip"})}},r.prototype.clear=function(e){this._lastValue=null,this._lastStatus=null;var t=e.getZr(),n=this._group,a=this._handle;t&&n&&(this._lastGraphicKey=null,n&&t.remove(n),a&&t.remove(a),this._group=null,this._handle=null,this._payloadInfo=null),xf(this,"_doDispatchAxisPointer")},r.prototype.doClear=function(){},r.prototype.buildLabel=function(e,t,n){return n=n||0,{x:e[n],y:e[1-n],width:t[n],height:t[1-n]}},r}();function cz(r,e,t,n){fz(el(t).lastProp,n)||(el(t).lastProp=n,e?Qe(t,n,r):(t.stopAnimation(),t.attr(n)))}function fz(r,e){if(_e(r)&&_e(e)){var t=!0;return C(e,function(n,a){t=t&&fz(r[a],n)}),!!t}else return r===e}function hz(r,e){r[e.get(["label","show"])?"show":"hide"]()}function qM(r){return{x:r.x||0,y:r.y||0,rotation:r.rotation||0}}function vz(r,e,t){var n=e.get("z"),a=e.get("zlevel");r&&r.traverse(function(i){i.type!=="group"&&(n!=null&&(i.z=n),a!=null&&(i.zlevel=a),i.silent=t)})}var XM=Mre;function JM(r){var e=r.get("type"),t=r.getModel(e+"Style"),n;return e==="line"?(n=t.getLineStyle(),n.fill=null):e==="shadow"&&(n=t.getAreaStyle(),n.stroke=null),n}function dz(r,e,t,n,a){var i=t.get("value"),o=pz(i,e.axis,e.ecModel,t.get("seriesDataIndices"),{precision:t.get(["label","precision"]),formatter:t.get(["label","formatter"])}),s=t.getModel("label"),l=xs(s.get("padding")||0),u=s.getFont(),c=jc(o,u),f=a.position,h=c.width+l[1]+l[3],v=c.height+l[0]+l[2],d=a.align;d==="right"&&(f[0]-=h),d==="center"&&(f[0]-=h/2);var p=a.verticalAlign;p==="bottom"&&(f[1]-=v),p==="middle"&&(f[1]-=v/2),xre(f,h,v,n);var g=s.get("backgroundColor");(!g||g==="auto")&&(g=e.get(["axisLine","lineStyle","color"])),r.label={x:f[0],y:f[1],style:yt(s,{text:o,font:u,fill:s.getTextColor(),padding:l,backgroundColor:g}),z2:10}}function xre(r,e,t,n){var a=n.getWidth(),i=n.getHeight();r[0]=Math.min(r[0]+e,a)-e,r[1]=Math.min(r[1]+t,i)-t,r[0]=Math.max(r[0],0),r[1]=Math.max(r[1],0)}function pz(r,e,t,n,a){r=e.scale.parse(r);var i=e.scale.getLabel({value:r},{precision:a.precision}),o=a.formatter;if(o){var s={value:V_(e,{value:r}),axisDimension:e.dim,axisIndex:e.index,seriesData:[]};C(n,function(l){var u=t.getSeriesByIndex(l.seriesIndex),c=l.dataIndexInside,f=u&&u.getDataParams(c);f&&s.seriesData.push(f)}),ce(o)?i=o.replace("{value}",i):ye(o)&&(i=o(s))}return i}function KM(r,e,t){var n=yn();return Zi(n,n,t.rotation),ua(n,n,t.position),ma([r.dataToCoord(e),(t.labelOffset||0)+(t.labelDirection||1)*(t.labelMargin||0)],n)}function gz(r,e,t,n,a,i){var o=Di.innerTextLayout(t.rotation,0,t.labelDirection);t.labelMargin=a.get(["label","margin"]),dz(e,n,a,i,{position:KM(n.axis,r,t),align:o.textAlign,verticalAlign:o.textVerticalAlign})}function ex(r,e,t){return t=t||0,{x1:r[t],y1:r[1-t],x2:e[t],y2:e[1-t]}}function yz(r,e,t){return t=t||0,{x:r[t],y:r[1-t],width:e[t],height:e[1-t]}}function mz(r,e,t,n,a,i){return{cx:r,cy:e,r0:t,r:n,startAngle:a,endAngle:i,clockwise:!0}}var wre=function(r){U(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.makeElOption=function(t,n,a,i,o){var s=a.axis,l=s.grid,u=i.get("type"),c=_z(l,s).getOtherAxis(s).getGlobalExtent(),f=s.toGlobalCoord(s.dataToCoord(n,!0));if(u&&u!=="none"){var h=JM(i),v=Dre[u](s,f,c);v.style=h,t.graphicKey=v.type,t.pointer=v}var d=gb(l.model,a);gz(n,t,d,a,i,o)},e.prototype.getHandleTransform=function(t,n,a){var i=gb(n.axis.grid.model,n,{labelInside:!1});i.labelMargin=a.get(["handle","margin"]);var o=KM(n.axis,t,i);return{x:o[0],y:o[1],rotation:i.rotation+(i.labelDirection<0?Math.PI:0)}},e.prototype.updateHandleTransform=function(t,n,a,i){var o=a.axis,s=o.grid,l=o.getGlobalExtent(!0),u=_z(s,o).getOtherAxis(o).getGlobalExtent(),c=o.dim==="x"?0:1,f=[t.x,t.y];f[c]+=n[c],f[c]=Math.min(l[1],f[c]),f[c]=Math.max(l[0],f[c]);var h=(u[1]+u[0])/2,v=[h,h];v[c]=f[c];var d=[{verticalAlign:"middle"},{align:"center"}];return{x:f[0],y:f[1],rotation:t.rotation,cursorPoint:v,tooltipOption:d[c]}},e}(XM);function _z(r,e){var t={};return t[e.dim+"AxisIndex"]=e.index,r.getCartesian(t)}var Dre={line:function(r,e,t){var n=ex([e,t[0]],[e,t[1]],bz(r));return{type:"Line",subPixelOptimize:!0,shape:n}},shadow:function(r,e,t){var n=Math.max(1,r.getBandWidth()),a=t[1]-t[0];return{type:"Rect",shape:yz([e-n/2,t[0]],[n,a],bz(r))}}};function bz(r){return r.dim==="x"?0:1}var Sre=wre,Ire=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="axisPointer",e.defaultOption={show:"auto",z:50,type:"line",snap:!1,triggerTooltip:!0,value:null,status:null,link:[],animation:null,animationDurationUpdate:200,lineStyle:{color:"#B9BEC9",width:1,type:"dashed"},shadowStyle:{color:"rgba(210,219,238,0.2)"},label:{show:!0,formatter:null,precision:"auto",margin:3,color:"#fff",padding:[5,7,5,7],backgroundColor:"auto",borderColor:null,borderWidth:0,borderRadius:3},handle:{show:!1,icon:"M10.7,11.9v-1.3H9.3v1.3c-4.9,0.3-8.8,4.4-8.8,9.4c0,5,3.9,9.1,8.8,9.4h1.3c4.9-0.3,8.8-4.4,8.8-9.4C19.5,16.3,15.6,12.2,10.7,11.9z M13.3,24.4H6.7v-1.2h6.6z M13.3,22H6.7v-1.2h6.6z M13.3,19.6H6.7v-1.2h6.6z",size:45,margin:50,color:"#333",shadowBlur:3,shadowColor:"#aaa",shadowOffsetX:0,shadowOffsetY:2,throttle:40}},e}(He),Tre=Ire,Ci=Ye(),Are=C;function Mz(r,e,t){if(!$e.node){var n=e.getZr();Ci(n).records||(Ci(n).records={}),Cre(n,e);var a=Ci(n).records[r]||(Ci(n).records[r]={});a.handler=t}}function Cre(r,e){if(Ci(r).initialized)return;Ci(r).initialized=!0,t("click",Ae(xz,"click")),t("mousemove",Ae(xz,"mousemove")),t("globalout",Lre);function t(n,a){r.on(n,function(i){var o=Ere(e);Are(Ci(r).records,function(s){s&&a(s,i,o.dispatchAction)}),Nre(o.pendings,e)})}}function Nre(r,e){var t=r.showTip.length,n=r.hideTip.length,a;t?a=r.showTip[t-1]:n&&(a=r.hideTip[n-1]),a&&(a.dispatchAction=null,e.dispatchAction(a))}function Lre(r,e,t){r.handler("leave",null,t)}function xz(r,e,t,n){e.handler(r,t,n)}function Ere(r){var e={showTip:[],hideTip:[]},t=function(n){var a=e[n.type];a?a.push(n):(n.dispatchAction=t,r.dispatchAction(n))};return{dispatchAction:t,pendings:e}}function tx(r,e){if(!$e.node){var t=e.getZr(),n=(Ci(t).records||{})[r];n&&(Ci(t).records[r]=null)}}var Ore=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a){var i=n.getComponent("tooltip"),o=t.get("triggerOn")||i&&i.get("triggerOn")||"mousemove|click";Mz("axisPointer",a,function(s,l,u){o!=="none"&&(s==="leave"||o.indexOf(s)>=0)&&u({type:"updateAxisPointer",currTrigger:s,x:l&&l.offsetX,y:l&&l.offsetY})})},e.prototype.remove=function(t,n){tx("axisPointer",n)},e.prototype.dispose=function(t,n){tx("axisPointer",n)},e.type="axisPointer",e}(St),Pre=Ore;function wz(r,e){var t=[],n=r.seriesIndex,a;if(n==null||!(a=e.getSeriesByIndex(n)))return{point:[]};var i=a.getData(),o=as(i,r);if(o==null||o<0||J(o))return{point:[]};var s=i.getItemGraphicEl(o),l=a.coordinateSystem;if(a.getTooltipPosition)t=a.getTooltipPosition(o)||[];else if(l&&l.dataToPoint)if(r.isStacked){var u=l.getBaseAxis(),c=l.getOtherAxis(u),f=c.dim,h=u.dim,v=f==="x"||f==="radius"?1:0,d=i.mapDimension(h),p=[];p[v]=i.get(d,o),p[1-v]=i.get(i.getCalculationInfo("stackResultDimension"),o),t=l.dataToPoint(p)||[]}else t=l.dataToPoint(i.getValues(K(l.dimensions,function(y){return i.mapDimension(y)}),o))||[];else if(s){var g=s.getBoundingRect().clone();g.applyTransform(s.transform),t=[g.x+g.width/2,g.y+g.height/2]}return{point:t,el:s}}var Dz=Ye();function zre(r,e,t){var n=r.currTrigger,a=[r.x,r.y],i=r,o=r.dispatchAction||fe(t.dispatchAction,t),s=e.getComponent("axisPointer").coordSysAxesInfo;if(!!s){ug(a)&&(a=wz({seriesIndex:i.seriesIndex,dataIndex:i.dataIndex},e).point);var l=ug(a),u=i.axesInfo,c=s.axesInfo,f=n==="leave"||ug(a),h={},v={},d={list:[],map:{}},p={showPointer:Ae(Rre,v),showTooltip:Ae(jre,d)};C(s.coordSysMap,function(y,m){var _=l||y.containPoint(a);C(s.coordSysAxesInfo[m],function(b,x){var M=b.axis,w=Hre(u,b);if(!f&&_&&(!u||w)){var D=w&&w.value;D==null&&!l&&(D=M.pointToData(a)),D!=null&&Sz(b,D,p,!1,h)}})});var g={};return C(c,function(y,m){var _=y.linkGroup;_&&!v[m]&&C(_.axesInfo,function(b,x){var M=v[x];if(b!==y&&M){var w=M.value;_.mapper&&(w=y.axis.scale.parse(_.mapper(w,Iz(b),Iz(y)))),g[y.key]=w}})}),C(g,function(y,m){Sz(c[m],y,p,!0,h)}),Bre(v,c,h),Fre(d,a,r,o),Vre(c,o,t),h}}function Sz(r,e,t,n,a){var i=r.axis;if(!(i.scale.isBlank()||!i.containData(e))){if(!r.involveSeries){t.showPointer(r,e);return}var o=kre(e,r),s=o.payloadBatch,l=o.snapToValue;s[0]&&a.seriesIndex==null&&X(a,s[0]),!n&&r.snap&&i.containData(l)&&l!=null&&(e=l),t.showPointer(r,e,s),t.showTooltip(r,o,l)}}function kre(r,e){var t=e.axis,n=t.dim,a=r,i=[],o=Number.MAX_VALUE,s=-1;return C(e.seriesModels,function(l,u){var c=l.getData().mapDimensionsAll(n),f,h;if(l.getAxisTooltipData){var v=l.getAxisTooltipData(c,r,t);h=v.dataIndices,f=v.nestestValue}else{if(h=l.getData().indicesOfNearest(c[0],r,t.type==="category"?.5:null),!h.length)return;f=l.getData().get(c[0],h[0])}if(!(f==null||!isFinite(f))){var d=r-f,p=Math.abs(d);p<=o&&((p<o||d>=0&&s<0)&&(o=p,s=d,a=f,i.length=0),C(h,function(g){i.push({seriesIndex:l.seriesIndex,dataIndexInside:g,dataIndex:l.getData().getRawIndex(g)})}))}}),{payloadBatch:i,snapToValue:a}}function Rre(r,e,t,n){r[e.key]={value:t,payloadBatch:n}}function jre(r,e,t,n){var a=t.payloadBatch,i=e.axis,o=i.model,s=e.axisPointerModel;if(!(!e.triggerTooltip||!a.length)){var l=e.coordSys.model,u=Zf(l),c=r.map[u];c||(c=r.map[u]={coordSysId:l.id,coordSysIndex:l.componentIndex,coordSysType:l.type,coordSysMainType:l.mainType,dataByAxis:[]},r.list.push(c)),c.dataByAxis.push({axisDim:i.dim,axisIndex:o.componentIndex,axisType:o.type,axisId:o.id,value:n,valueLabelOpt:{precision:s.get(["label","precision"]),formatter:s.get(["label","formatter"])},seriesDataIndices:a.slice()})}}function Bre(r,e,t){var n=t.axesInfo=[];C(e,function(a,i){var o=a.axisPointerModel.option,s=r[i];s?(!a.useHandle&&(o.status="show"),o.value=s.value,o.seriesDataIndices=(s.payloadBatch||[]).slice()):!a.useHandle&&(o.status="hide"),o.status==="show"&&n.push({axisDim:a.axis.dim,axisIndex:a.axis.model.componentIndex,value:o.value})})}function Fre(r,e,t,n){if(ug(e)||!r.list.length){n({type:"hideTip"});return}var a=((r.list[0].dataByAxis[0]||{}).seriesDataIndices||[])[0]||{};n({type:"showTip",escapeConnect:!0,x:e[0],y:e[1],tooltipOption:t.tooltipOption,position:t.position,dataIndexInside:a.dataIndexInside,dataIndex:a.dataIndex,seriesIndex:a.seriesIndex,dataByCoordSys:r.list})}function Vre(r,e,t){var n=t.getZr(),a="axisPointerLastHighlights",i=Dz(n)[a]||{},o=Dz(n)[a]={};C(r,function(u,c){var f=u.axisPointerModel.option;f.status==="show"&&C(f.seriesDataIndices,function(h){var v=h.seriesIndex+" | "+h.dataIndex;o[v]=h})});var s=[],l=[];C(i,function(u,c){!o[c]&&l.push(u)}),C(o,function(u,c){!i[c]&&s.push(u)}),l.length&&t.dispatchAction({type:"downplay",escapeConnect:!0,notBlur:!0,batch:l}),s.length&&t.dispatchAction({type:"highlight",escapeConnect:!0,notBlur:!0,batch:s})}function Hre(r,e){for(var t=0;t<(r||[]).length;t++){var n=r[t];if(e.axis.dim===n.axisDim&&e.axis.model.componentIndex===n.axisIndex)return n}}function Iz(r){var e=r.axis.model,t={},n=t.axisDim=r.axis.dim;return t.axisIndex=t[n+"AxisIndex"]=e.componentIndex,t.axisName=t[n+"AxisName"]=e.name,t.axisId=t[n+"AxisId"]=e.id,t}function ug(r){return!r||r[0]==null||isNaN(r[0])||r[1]==null||isNaN(r[1])}function vh(r){Gs.registerAxisPointerClass("CartesianAxisPointer",Sre),r.registerComponentModel(Tre),r.registerComponentView(Pre),r.registerPreprocessor(function(e){if(e){(!e.axisPointer||e.axisPointer.length===0)&&(e.axisPointer={});var t=e.axisPointer.link;t&&!J(t)&&(e.axisPointer.link=[t])}}),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,function(e,t){e.getComponent("axisPointer").coordSysAxesInfo=C7(e,t)}),r.registerAction({type:"updateAxisPointer",event:"updateAxisPointer",update:":updateAxisPointer"},zre)}function Wre(r){Re(aO),Re(vh)}var Gre=function(r){U(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.makeElOption=function(t,n,a,i,o){var s=a.axis;s.dim==="angle"&&(this.animationThreshold=Math.PI/18);var l=s.polar,u=l.getOtherAxis(s),c=u.getExtent(),f=s.dataToCoord(n),h=i.get("type");if(h&&h!=="none"){var v=JM(i),d=Ure[h](s,l,f,c);d.style=v,t.graphicKey=d.type,t.pointer=d}var p=i.get(["label","margin"]),g=$re(n,a,i,l,p);dz(t,a,i,o,g)},e}(XM);function $re(r,e,t,n,a){var i=e.axis,o=i.dataToCoord(r),s=n.getAngleAxis().getExtent()[0];s=s/180*Math.PI;var l=n.getRadiusAxis().getExtent(),u,c,f;if(i.dim==="radius"){var h=yn();Zi(h,h,s),ua(h,h,[n.cx,n.cy]),u=ma([o,-a],h);var v=e.getModel("axisLabel").get("rotate")||0,d=Di.innerTextLayout(s,v*Math.PI/180,-1);c=d.textAlign,f=d.textVerticalAlign}else{var p=l[1];u=n.coordToPoint([p+a,o]);var g=n.cx,y=n.cy;c=Math.abs(u[0]-g)/p<.3?"center":u[0]>g?"left":"right",f=Math.abs(u[1]-y)/p<.3?"middle":u[1]>y?"top":"bottom"}return{position:u,align:c,verticalAlign:f}}var Ure={line:function(r,e,t,n){return r.dim==="angle"?{type:"Line",shape:ex(e.coordToPoint([n[0],t]),e.coordToPoint([n[1],t]))}:{type:"Circle",shape:{cx:e.cx,cy:e.cy,r:t}}},shadow:function(r,e,t,n){var a=Math.max(1,r.getBandWidth()),i=Math.PI/180;return r.dim==="angle"?{type:"Sector",shape:mz(e.cx,e.cy,n[0],n[1],(-t-a/2)*i,(-t+a/2)*i)}:{type:"Sector",shape:mz(e.cx,e.cy,t-a/2,t+a/2,0,Math.PI*2)}}},Yre=Gre,Qre=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.findAxisModel=function(t){var n,a=this.ecModel;return a.eachComponent(t,function(i){i.getCoordSysModel()===this&&(n=i)},this),n},e.type="polar",e.dependencies=["radiusAxis","angleAxis"],e.defaultOption={z:0,center:["50%","50%"],radius:"80%"},e}(He),Zre=Qre,rx=function(r){U(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getCoordSysModel=function(){return this.getReferringComponents("polar",Ut).models[0]},e.type="polarAxis",e}(He);Et(rx,Mu);var qre=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="angleAxis",e}(rx),Xre=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="radiusAxis",e}(rx),nx=function(r){U(e,r);function e(t,n){return r.call(this,"radius",t,n)||this}return e.prototype.pointToData=function(t,n){return this.polar.pointToData(t,n)[this.dim==="radius"?0:1]},e}(Yn);nx.prototype.dataToRadius=Yn.prototype.dataToCoord,nx.prototype.radiusToData=Yn.prototype.coordToData;var Jre=nx,Kre=Ye(),ax=function(r){U(e,r);function e(t,n){return r.call(this,"angle",t,n||[0,360])||this}return e.prototype.pointToData=function(t,n){return this.polar.pointToData(t,n)[this.dim==="radius"?0:1]},e.prototype.calculateCategoryInterval=function(){var t=this,n=t.getLabelModel(),a=t.scale,i=a.getExtent(),o=a.count();if(i[1]-i[0]<1)return 0;var s=i[0],l=t.dataToCoord(s+1)-t.dataToCoord(s),u=Math.abs(l),c=jc(s==null?"":s+"",n.getFont(),"center","top"),f=Math.max(c.height,7),h=f/u;isNaN(h)&&(h=1/0);var v=Math.max(0,Math.floor(h)),d=Kre(t.model),p=d.lastAutoInterval,g=d.lastTickCount;return p!=null&&g!=null&&Math.abs(p-v)<=1&&Math.abs(g-o)<=1&&p>v?v=p:(d.lastTickCount=o,d.lastAutoInterval=v),v},e}(Yn);ax.prototype.dataToAngle=Yn.prototype.dataToCoord,ax.prototype.angleToData=Yn.prototype.coordToData;var ene=ax,Tz=["radius","angle"],tne=function(){function r(e){this.dimensions=Tz,this.type="polar",this.cx=0,this.cy=0,this._radiusAxis=new Jre,this._angleAxis=new ene,this.axisPointerEnabled=!0,this.name=e||"",this._radiusAxis.polar=this._angleAxis.polar=this}return r.prototype.containPoint=function(e){var t=this.pointToCoord(e);return this._radiusAxis.contain(t[0])&&this._angleAxis.contain(t[1])},r.prototype.containData=function(e){return this._radiusAxis.containData(e[0])&&this._angleAxis.containData(e[1])},r.prototype.getAxis=function(e){var t="_"+e+"Axis";return this[t]},r.prototype.getAxes=function(){return[this._radiusAxis,this._angleAxis]},r.prototype.getAxesByScale=function(e){var t=[],n=this._angleAxis,a=this._radiusAxis;return n.scale.type===e&&t.push(n),a.scale.type===e&&t.push(a),t},r.prototype.getAngleAxis=function(){return this._angleAxis},r.prototype.getRadiusAxis=function(){return this._radiusAxis},r.prototype.getOtherAxis=function(e){var t=this._angleAxis;return e===t?this._radiusAxis:t},r.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAngleAxis()},r.prototype.getTooltipAxes=function(e){var t=e!=null&&e!=="auto"?this.getAxis(e):this.getBaseAxis();return{baseAxes:[t],otherAxes:[this.getOtherAxis(t)]}},r.prototype.dataToPoint=function(e,t){return this.coordToPoint([this._radiusAxis.dataToRadius(e[0],t),this._angleAxis.dataToAngle(e[1],t)])},r.prototype.pointToData=function(e,t){var n=this.pointToCoord(e);return[this._radiusAxis.radiusToData(n[0],t),this._angleAxis.angleToData(n[1],t)]},r.prototype.pointToCoord=function(e){var t=e[0]-this.cx,n=e[1]-this.cy,a=this.getAngleAxis(),i=a.getExtent(),o=Math.min(i[0],i[1]),s=Math.max(i[0],i[1]);a.inverse?o=s-360:s=o+360;var l=Math.sqrt(t*t+n*n);t/=l,n/=l;for(var u=Math.atan2(-n,t)/Math.PI*180,c=u<o?1:-1;u<o||u>s;)u+=c*360;return[l,u]},r.prototype.coordToPoint=function(e){var t=e[0],n=e[1]/180*Math.PI,a=Math.cos(n)*t+this.cx,i=-Math.sin(n)*t+this.cy;return[a,i]},r.prototype.getArea=function(){var e=this.getAngleAxis(),t=this.getRadiusAxis(),n=t.getExtent().slice();n[0]>n[1]&&n.reverse();var a=e.getExtent(),i=Math.PI/180;return{cx:this.cx,cy:this.cy,r0:n[0],r:n[1],startAngle:-a[0]*i,endAngle:-a[1]*i,clockwise:e.inverse,contain:function(o,s){var l=o-this.cx,u=s-this.cy,c=l*l+u*u-1e-4,f=this.r,h=this.r0;return c<=f*f&&c>=h*h}}},r.prototype.convertToPixel=function(e,t,n){var a=Az(t);return a===this?this.dataToPoint(n):null},r.prototype.convertFromPixel=function(e,t,n){var a=Az(t);return a===this?this.pointToData(n):null},r}();function Az(r){var e=r.seriesModel,t=r.polarModel;return t&&t.coordinateSystem||e&&e.coordinateSystem}var rne=tne;function nne(r,e,t){var n=e.get("center"),a=t.getWidth(),i=t.getHeight();r.cx=ue(n[0],a),r.cy=ue(n[1],i);var o=r.getRadiusAxis(),s=Math.min(a,i)/2,l=e.get("radius");l==null?l=[0,"100%"]:J(l)||(l=[0,l]);var u=[ue(l[0],s),ue(l[1],s)];o.inverse?o.setExtent(u[1],u[0]):o.setExtent(u[0],u[1])}function ane(r,e){var t=this,n=t.getAngleAxis(),a=t.getRadiusAxis();if(n.scale.setExtent(1/0,-1/0),a.scale.setExtent(1/0,-1/0),r.eachSeries(function(s){if(s.coordinateSystem===t){var l=s.getData();C(wp(l,"radius"),function(u){a.scale.unionExtentFromData(l,u)}),C(wp(l,"angle"),function(u){n.scale.unionExtentFromData(l,u)})}}),Ps(n.scale,n.model),Ps(a.scale,a.model),n.type==="category"&&!n.onBand){var i=n.getExtent(),o=360/n.scale.count();n.inverse?i[1]+=o:i[1]-=o,n.setExtent(i[0],i[1])}}function ine(r){return r.mainType==="angleAxis"}function Cz(r,e){if(r.type=e.get("type"),r.scale=kf(e),r.onBand=e.get("boundaryGap")&&r.type==="category",r.inverse=e.get("inverse"),ine(e)){r.inverse=r.inverse!==e.get("clockwise");var t=e.get("startAngle");r.setExtent(t,t+(r.inverse?-360:360))}e.axis=r,r.model=e}var one={dimensions:Tz,create:function(r,e){var t=[];return r.eachComponent("polar",function(n,a){var i=new rne(a+"");i.update=ane;var o=i.getRadiusAxis(),s=i.getAngleAxis(),l=n.findAxisModel("radiusAxis"),u=n.findAxisModel("angleAxis");Cz(o,l),Cz(s,u),nne(i,n,e),t.push(i),n.coordinateSystem=i,i.model=n}),r.eachSeries(function(n){if(n.get("coordinateSystem")==="polar"){var a=n.getReferringComponents("polar",Ut).models[0];n.coordinateSystem=a.coordinateSystem}}),t}},sne=one,lne=["axisLine","axisLabel","axisTick","minorTick","splitLine","minorSplitLine","splitArea"];function cg(r,e,t){e[1]>e[0]&&(e=e.slice().reverse());var n=r.coordToPoint([e[0],t]),a=r.coordToPoint([e[1],t]);return{x1:n[0],y1:n[1],x2:a[0],y2:a[1]}}function fg(r){var e=r.getRadiusAxis();return e.inverse?0:1}function Nz(r){var e=r[0],t=r[r.length-1];e&&t&&Math.abs(Math.abs(e.coord-t.coord)-360)<1e-4&&r.pop()}var une=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.axisPointerClass="PolarAxisPointer",t}return e.prototype.render=function(t,n){if(this.group.removeAll(),!!t.get("show")){var a=t.axis,i=a.polar,o=i.getRadiusAxis().getExtent(),s=a.getTicksCoords(),l=a.getMinorTicksCoords(),u=K(a.getViewLabels(),function(c){c=Me(c);var f=a.scale,h=f.type==="ordinal"?f.getRawOrdinalNumber(c.tickValue):c.tickValue;return c.coord=a.dataToCoord(h),c});Nz(u),Nz(s),C(lne,function(c){t.get([c,"show"])&&(!a.scale.isBlank()||c==="axisLine")&&cne[c](this.group,t,i,s,l,o,u)},this)}},e.type="angleAxis",e}(Gs),cne={axisLine:function(r,e,t,n,a,i){var o=e.getModel(["axisLine","lineStyle"]),s=fg(t),l=s?0:1,u;i[l]===0?u=new pa({shape:{cx:t.cx,cy:t.cy,r:i[s]},style:o.getLineStyle(),z2:1,silent:!0}):u=new rf({shape:{cx:t.cx,cy:t.cy,r:i[s],r0:i[l]},style:o.getLineStyle(),z2:1,silent:!0}),u.style.fill=null,r.add(u)},axisTick:function(r,e,t,n,a,i){var o=e.getModel("axisTick"),s=(o.get("inside")?-1:1)*o.get("length"),l=i[fg(t)],u=K(n,function(c){return new or({shape:cg(t,[l,l+s],c.coord)})});r.add(xn(u,{style:me(o.getModel("lineStyle").getLineStyle(),{stroke:e.get(["axisLine","lineStyle","color"])})}))},minorTick:function(r,e,t,n,a,i){if(!!a.length){for(var o=e.getModel("axisTick"),s=e.getModel("minorTick"),l=(o.get("inside")?-1:1)*s.get("length"),u=i[fg(t)],c=[],f=0;f<a.length;f++)for(var h=0;h<a[f].length;h++)c.push(new or({shape:cg(t,[u,u+l],a[f][h].coord)}));r.add(xn(c,{style:me(s.getModel("lineStyle").getLineStyle(),me(o.getLineStyle(),{stroke:e.get(["axisLine","lineStyle","color"])}))}))}},axisLabel:function(r,e,t,n,a,i,o){var s=e.getCategories(!0),l=e.getModel("axisLabel"),u=l.get("margin"),c=e.get("triggerEvent");C(o,function(f,h){var v=l,d=f.tickValue,p=i[fg(t)],g=t.coordToPoint([p+u,f.coord]),y=t.cx,m=t.cy,_=Math.abs(g[0]-y)/p<.3?"center":g[0]>y?"left":"right",b=Math.abs(g[1]-m)/p<.3?"middle":g[1]>m?"top":"bottom";if(s&&s[d]){var x=s[d];_e(x)&&x.textStyle&&(v=new ft(x.textStyle,l,l.ecModel))}var M=new Ge({silent:Di.isLabelSilent(e),style:yt(v,{x:g[0],y:g[1],fill:v.getTextColor()||e.get(["axisLine","lineStyle","color"]),text:f.formattedLabel,align:_,verticalAlign:b})});if(r.add(M),c){var w=Di.makeAxisEventDataBase(e);w.targetType="axisLabel",w.value=f.rawLabel,Te(M).eventData=w}},this)},splitLine:function(r,e,t,n,a,i){var o=e.getModel("splitLine"),s=o.getModel("lineStyle"),l=s.get("color"),u=0;l=l instanceof Array?l:[l];for(var c=[],f=0;f<n.length;f++){var h=u++%l.length;c[h]=c[h]||[],c[h].push(new or({shape:cg(t,i,n[f].coord)}))}for(var f=0;f<c.length;f++)r.add(xn(c[f],{style:me({stroke:l[f%l.length]},s.getLineStyle()),silent:!0,z:e.get("z")}))},minorSplitLine:function(r,e,t,n,a,i){if(!!a.length){for(var o=e.getModel("minorSplitLine"),s=o.getModel("lineStyle"),l=[],u=0;u<a.length;u++)for(var c=0;c<a[u].length;c++)l.push(new or({shape:cg(t,i,a[u][c].coord)}));r.add(xn(l,{style:s.getLineStyle(),silent:!0,z:e.get("z")}))}},splitArea:function(r,e,t,n,a,i){if(!!n.length){var o=e.getModel("splitArea"),s=o.getModel("areaStyle"),l=s.get("color"),u=0;l=l instanceof Array?l:[l];for(var c=[],f=Math.PI/180,h=-n[0].coord*f,v=Math.min(i[0],i[1]),d=Math.max(i[0],i[1]),p=e.get("clockwise"),g=1,y=n.length;g<=y;g++){var m=g===y?n[0].coord:n[g].coord,_=u++%l.length;c[_]=c[_]||[],c[_].push(new Zr({shape:{cx:t.cx,cy:t.cy,r0:v,r:d,startAngle:h,endAngle:-m*f,clockwise:p},silent:!0})),h=-m*f}for(var g=0;g<c.length;g++)r.add(xn(c[g],{style:me({fill:l[g%l.length]},s.getAreaStyle()),silent:!0}))}}},fne=une,hne=["axisLine","axisTickLabel","axisName"],vne=["splitLine","splitArea","minorSplitLine"],dne=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.axisPointerClass="PolarAxisPointer",t}return e.prototype.render=function(t,n){if(this.group.removeAll(),!!t.get("show")){var a=this._axisGroup,i=this._axisGroup=new De;this.group.add(i);var o=t.axis,s=o.polar,l=s.getAngleAxis(),u=o.getTicksCoords(),c=o.getMinorTicksCoords(),f=l.getExtent()[0],h=o.getExtent(),v=gne(s,t,f),d=new Di(t,v);C(hne,d.add,d),i.add(d.getGroup()),sf(a,i,t),C(vne,function(p){t.get([p,"show"])&&!o.scale.isBlank()&&pne[p](this.group,t,s,f,h,u,c)},this)}},e.type="radiusAxis",e}(Gs),pne={splitLine:function(r,e,t,n,a,i){var o=e.getModel("splitLine"),s=o.getModel("lineStyle"),l=s.get("color"),u=0;l=l instanceof Array?l:[l];for(var c=[],f=0;f<i.length;f++){var h=u++%l.length;c[h]=c[h]||[],c[h].push(new pa({shape:{cx:t.cx,cy:t.cy,r:Math.max(i[f].coord,0)}}))}for(var f=0;f<c.length;f++)r.add(xn(c[f],{style:me({stroke:l[f%l.length],fill:null},s.getLineStyle()),silent:!0}))},minorSplitLine:function(r,e,t,n,a,i,o){if(!!o.length){for(var s=e.getModel("minorSplitLine"),l=s.getModel("lineStyle"),u=[],c=0;c<o.length;c++)for(var f=0;f<o[c].length;f++)u.push(new pa({shape:{cx:t.cx,cy:t.cy,r:o[c][f].coord}}));r.add(xn(u,{style:me({fill:null},l.getLineStyle()),silent:!0}))}},splitArea:function(r,e,t,n,a,i){if(!!i.length){var o=e.getModel("splitArea"),s=o.getModel("areaStyle"),l=s.get("color"),u=0;l=l instanceof Array?l:[l];for(var c=[],f=i[0].coord,h=1;h<i.length;h++){var v=u++%l.length;c[v]=c[v]||[],c[v].push(new Zr({shape:{cx:t.cx,cy:t.cy,r0:f,r:i[h].coord,startAngle:0,endAngle:Math.PI*2},silent:!0})),f=i[h].coord}for(var h=0;h<c.length;h++)r.add(xn(c[h],{style:me({fill:l[h%l.length]},s.getAreaStyle()),silent:!0}))}}};function gne(r,e,t){return{position:[r.cx,r.cy],rotation:t/180*Math.PI,labelDirection:-1,tickDirection:-1,nameDirection:1,labelRotate:e.getModel("axisLabel").get("rotate"),z2:1}}var yne=dne;function Lz(r){return r.get("stack")||"__ec_stack_"+r.seriesIndex}function Ez(r,e){return e.dim+r.model.componentIndex}function mne(r,e,t){var n={},a=_ne(ot(e.getSeriesByType(r),function(i){return!e.isSeriesFiltered(i)&&i.coordinateSystem&&i.coordinateSystem.type==="polar"}));e.eachSeriesByType(r,function(i){if(i.coordinateSystem.type==="polar"){var o=i.getData(),s=i.coordinateSystem,l=s.getBaseAxis(),u=Ez(s,l),c=Lz(i),f=a[u][c],h=f.offset,v=f.width,d=s.getOtherAxis(l),p=i.coordinateSystem.cx,g=i.coordinateSystem.cy,y=i.get("barMinHeight")||0,m=i.get("barMinAngle")||0;n[c]=n[c]||[];for(var _=o.mapDimension(d.dim),b=o.mapDimension(l.dim),x=xi(o,_),M=l.dim!=="radius"||!i.get("roundCap",!0),w=d.dataToCoord(0),D=0,T=o.count();D<T;D++){var I=o.get(_,D),A=o.get(b,D),N=I>=0?"p":"n",L=w;x&&(n[c][A]||(n[c][A]={p:w,n:w}),L=n[c][A][N]);var E=void 0,O=void 0,P=void 0,H=void 0;if(d.dim==="radius"){var F=d.dataToCoord(I)-w,G=l.dataToCoord(A);Math.abs(F)<y&&(F=(F<0?-1:1)*y),E=L,O=L+F,P=G-h,H=P-v,x&&(n[c][A][N]=O)}else{var Z=d.dataToCoord(I,M)-w,te=l.dataToCoord(A);Math.abs(Z)<m&&(Z=(Z<0?-1:1)*m),E=te+h,O=E+v,P=L,H=L+Z,x&&(n[c][A][N]=H)}o.setItemLayout(D,{cx:p,cy:g,r0:E,r:O,startAngle:-P*Math.PI/180,endAngle:-H*Math.PI/180,clockwise:P>=H})}}})}function _ne(r){var e={};C(r,function(n,a){var i=n.getData(),o=n.coordinateSystem,s=o.getBaseAxis(),l=Ez(o,s),u=s.getExtent(),c=s.type==="category"?s.getBandWidth():Math.abs(u[1]-u[0])/i.count(),f=e[l]||{bandWidth:c,remainedWidth:c,autoWidthCount:0,categoryGap:"20%",gap:"30%",stacks:{}},h=f.stacks;e[l]=f;var v=Lz(n);h[v]||f.autoWidthCount++,h[v]=h[v]||{width:0,maxWidth:0};var d=ue(n.get("barWidth"),c),p=ue(n.get("barMaxWidth"),c),g=n.get("barGap"),y=n.get("barCategoryGap");d&&!h[v].width&&(d=Math.min(f.remainedWidth,d),h[v].width=d,f.remainedWidth-=d),p&&(h[v].maxWidth=p),g!=null&&(f.gap=g),y!=null&&(f.categoryGap=y)});var t={};return C(e,function(n,a){t[a]={};var i=n.stacks,o=n.bandWidth,s=ue(n.categoryGap,o),l=ue(n.gap,1),u=n.remainedWidth,c=n.autoWidthCount,f=(u-s)/(c+(c-1)*l);f=Math.max(f,0),C(i,function(p,g){var y=p.maxWidth;y&&y<f&&(y=Math.min(y,u),p.width&&(y=Math.min(y,p.width)),u-=y,p.width=y,c--)}),f=(u-s)/(c+(c-1)*l),f=Math.max(f,0);var h=0,v;C(i,function(p,g){p.width||(p.width=f),v=p,h+=p.width*(1+l)}),v&&(h-=v.width*l);var d=-h/2;C(i,function(p,g){t[a][g]=t[a][g]||{offset:d,width:p.width},d+=p.width*(1+l)})}),t}var bne={startAngle:90,clockwise:!0,splitNumber:12,axisLabel:{rotate:0}},Mne={splitNumber:5},xne=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="polar",e}(St);function wne(r){Re(vh),Gs.registerAxisPointerClass("PolarAxisPointer",Yre),r.registerCoordinateSystem("polar",sne),r.registerComponentModel(Zre),r.registerComponentView(xne),Iu(r,"angle",qre,bne),Iu(r,"radius",Xre,Mne),r.registerComponentView(fne),r.registerComponentView(yne),r.registerLayout(Ae(mne,"bar"))}function ix(r,e){e=e||{};var t=r.coordinateSystem,n=r.axis,a={},i=n.position,o=n.orient,s=t.getRect(),l=[s.x,s.x+s.width,s.y,s.y+s.height],u={horizontal:{top:l[2],bottom:l[3]},vertical:{left:l[0],right:l[1]}};a.position=[o==="vertical"?u.vertical[i]:l[0],o==="horizontal"?u.horizontal[i]:l[3]];var c={horizontal:0,vertical:1};a.rotation=Math.PI/2*c[o];var f={top:-1,bottom:1,right:1,left:-1};a.labelDirection=a.tickDirection=a.nameDirection=f[i],r.get(["axisTick","inside"])&&(a.tickDirection=-a.tickDirection),ar(e.labelInside,r.get(["axisLabel","inside"]))&&(a.labelDirection=-a.labelDirection);var h=e.rotate;return h==null&&(h=r.get(["axisLabel","rotate"])),a.labelRotation=i==="top"?-h:h,a.z2=1,a}var Dne=["axisLine","axisTickLabel","axisName"],Sne=["splitArea","splitLine"],Ine=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.axisPointerClass="SingleAxisPointer",t}return e.prototype.render=function(t,n,a,i){var o=this.group;o.removeAll();var s=this._axisGroup;this._axisGroup=new De;var l=ix(t),u=new Di(t,l);C(Dne,u.add,u),o.add(this._axisGroup),o.add(u.getGroup()),C(Sne,function(c){t.get([c,"show"])&&Tne[c](this,this.group,this._axisGroup,t)},this),sf(s,this._axisGroup,t),r.prototype.render.call(this,t,n,a,i)},e.prototype.remove=function(){eO(this)},e.type="singleAxis",e}(Gs),Tne={splitLine:function(r,e,t,n){var a=n.axis;if(!a.scale.isBlank()){var i=n.getModel("splitLine"),o=i.getModel("lineStyle"),s=o.get("color");s=s instanceof Array?s:[s];for(var l=o.get("width"),u=n.coordinateSystem.getRect(),c=a.isHorizontal(),f=[],h=0,v=a.getTicksCoords({tickModel:i}),d=[],p=[],g=0;g<v.length;++g){var y=a.toGlobalCoord(v[g].coord);c?(d[0]=y,d[1]=u.y,p[0]=y,p[1]=u.y+u.height):(d[0]=u.x,d[1]=y,p[0]=u.x+u.width,p[1]=y);var m=new or({shape:{x1:d[0],y1:d[1],x2:p[0],y2:p[1]},silent:!0});Jl(m.shape,l);var _=h++%s.length;f[_]=f[_]||[],f[_].push(m)}for(var b=o.getLineStyle(["color"]),g=0;g<f.length;++g)e.add(xn(f[g],{style:me({stroke:s[g%s.length]},b),silent:!0}))}},splitArea:function(r,e,t,n){KE(r,t,n,n)}},Ane=Ine,Oz=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.getCoordSysModel=function(){return this},e.type="singleAxis",e.layoutMode="box",e.defaultOption={left:"5%",top:"5%",right:"5%",bottom:"5%",type:"value",position:"bottom",orient:"horizontal",axisLine:{show:!0,lineStyle:{width:1,type:"solid"}},tooltip:{show:!0},axisTick:{show:!0,length:6,lineStyle:{width:1}},axisLabel:{show:!0,interval:"auto"},splitLine:{show:!0,lineStyle:{type:"dashed",opacity:.2}}},e}(He);Et(Oz,Mu.prototype);var ox=Oz,Cne=function(r){U(e,r);function e(t,n,a,i,o){var s=r.call(this,t,n,a)||this;return s.type=i||"value",s.position=o||"bottom",s}return e.prototype.isHorizontal=function(){var t=this.position;return t==="top"||t==="bottom"},e.prototype.pointToData=function(t,n){return this.coordinateSystem.pointToData(t)[0]},e}(Yn),Nne=Cne,Pz=["single"],Lne=function(){function r(e,t,n){this.type="single",this.dimension="single",this.dimensions=Pz,this.axisPointerEnabled=!0,this.model=e,this._init(e,t,n)}return r.prototype._init=function(e,t,n){var a=this.dimension,i=new Nne(a,kf(e),[0,0],e.get("type"),e.get("position")),o=i.type==="category";i.onBand=o&&e.get("boundaryGap"),i.inverse=e.get("inverse"),i.orient=e.get("orient"),e.axis=i,i.model=e,i.coordinateSystem=this,this._axis=i},r.prototype.update=function(e,t){e.eachSeries(function(n){if(n.coordinateSystem===this){var a=n.getData();C(a.mapDimensionsAll(this.dimension),function(i){this._axis.scale.unionExtentFromData(a,i)},this),Ps(this._axis.scale,this._axis.model)}},this)},r.prototype.resize=function(e,t){this._rect=Yt({left:e.get("left"),top:e.get("top"),right:e.get("right"),bottom:e.get("bottom"),width:e.get("width"),height:e.get("height")},{width:t.getWidth(),height:t.getHeight()}),this._adjustAxis()},r.prototype.getRect=function(){return this._rect},r.prototype._adjustAxis=function(){var e=this._rect,t=this._axis,n=t.isHorizontal(),a=n?[0,e.width]:[0,e.height],i=t.inverse?1:0;t.setExtent(a[i],a[1-i]),this._updateAxisTransform(t,n?e.x:e.y)},r.prototype._updateAxisTransform=function(e,t){var n=e.getExtent(),a=n[0]+n[1],i=e.isHorizontal();e.toGlobalCoord=i?function(o){return o+t}:function(o){return a-o+t},e.toLocalCoord=i?function(o){return o-t}:function(o){return a-o+t}},r.prototype.getAxis=function(){return this._axis},r.prototype.getBaseAxis=function(){return this._axis},r.prototype.getAxes=function(){return[this._axis]},r.prototype.getTooltipAxes=function(){return{baseAxes:[this.getAxis()],otherAxes:[]}},r.prototype.containPoint=function(e){var t=this.getRect(),n=this.getAxis(),a=n.orient;return a==="horizontal"?n.contain(n.toLocalCoord(e[0]))&&e[1]>=t.y&&e[1]<=t.y+t.height:n.contain(n.toLocalCoord(e[1]))&&e[0]>=t.y&&e[0]<=t.y+t.height},r.prototype.pointToData=function(e){var t=this.getAxis();return[t.coordToData(t.toLocalCoord(e[t.orient==="horizontal"?0:1]))]},r.prototype.dataToPoint=function(e){var t=this.getAxis(),n=this.getRect(),a=[],i=t.orient==="horizontal"?0:1;return e instanceof Array&&(e=e[0]),a[i]=t.toGlobalCoord(t.dataToCoord(+e)),a[1-i]=i===0?n.y+n.height/2:n.x+n.width/2,a},r.prototype.convertToPixel=function(e,t,n){var a=zz(t);return a===this?this.dataToPoint(n):null},r.prototype.convertFromPixel=function(e,t,n){var a=zz(t);return a===this?this.pointToData(n):null},r}();function zz(r){var e=r.seriesModel,t=r.singleAxisModel;return t&&t.coordinateSystem||e&&e.coordinateSystem}function Ene(r,e){var t=[];return r.eachComponent("singleAxis",function(n,a){var i=new Lne(n,r,e);i.name="single_"+a,i.resize(n,e),n.coordinateSystem=i,t.push(i)}),r.eachSeries(function(n){if(n.get("coordinateSystem")==="singleAxis"){var a=n.getReferringComponents("singleAxis",Ut).models[0];n.coordinateSystem=a&&a.coordinateSystem}}),t}var One={create:Ene,dimensions:Pz},Pne=One,kz=["x","y"],zne=["width","height"],kne=function(r){U(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.makeElOption=function(t,n,a,i,o){var s=a.axis,l=s.coordinateSystem,u=sx(l,1-hg(s)),c=l.dataToPoint(n)[0],f=i.get("type");if(f&&f!=="none"){var h=JM(i),v=Rne[f](s,c,u);v.style=h,t.graphicKey=v.type,t.pointer=v}var d=ix(a);gz(n,t,d,a,i,o)},e.prototype.getHandleTransform=function(t,n,a){var i=ix(n,{labelInside:!1});i.labelMargin=a.get(["handle","margin"]);var o=KM(n.axis,t,i);return{x:o[0],y:o[1],rotation:i.rotation+(i.labelDirection<0?Math.PI:0)}},e.prototype.updateHandleTransform=function(t,n,a,i){var o=a.axis,s=o.coordinateSystem,l=hg(o),u=sx(s,l),c=[t.x,t.y];c[l]+=n[l],c[l]=Math.min(u[1],c[l]),c[l]=Math.max(u[0],c[l]);var f=sx(s,1-l),h=(f[1]+f[0])/2,v=[h,h];return v[l]=c[l],{x:c[0],y:c[1],rotation:t.rotation,cursorPoint:v,tooltipOption:{verticalAlign:"middle"}}},e}(XM),Rne={line:function(r,e,t){var n=ex([e,t[0]],[e,t[1]],hg(r));return{type:"Line",subPixelOptimize:!0,shape:n}},shadow:function(r,e,t){var n=r.getBandWidth(),a=t[1]-t[0];return{type:"Rect",shape:yz([e-n/2,t[0]],[n,a],hg(r))}}};function hg(r){return r.isHorizontal()?0:1}function sx(r,e){var t=r.getRect();return[t[kz[e]],t[kz[e]]+t[zne[e]]]}var jne=kne,Bne=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="single",e}(St);function Fne(r){Re(vh),Gs.registerAxisPointerClass("SingleAxisPointer",jne),r.registerComponentView(Bne),r.registerComponentView(Ane),r.registerComponentModel(ox),Iu(r,"single",ox,ox.defaultOption),r.registerCoordinateSystem("single",Pne)}var Vne=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,n,a){var i=iu(t);r.prototype.init.apply(this,arguments),Rz(t,i)},e.prototype.mergeOption=function(t){r.prototype.mergeOption.apply(this,arguments),Rz(this.option,t)},e.prototype.getCellSize=function(){return this.option.cellSize},e.type="calendar",e.defaultOption={z:2,left:80,top:60,cellSize:20,orient:"horizontal",splitLine:{show:!0,lineStyle:{color:"#000",width:1,type:"solid"}},itemStyle:{color:"#fff",borderWidth:1,borderColor:"#ccc"},dayLabel:{show:!0,firstDay:0,position:"start",margin:"50%",color:"#000"},monthLabel:{show:!0,position:"start",margin:5,align:"center",formatter:null,color:"#000"},yearLabel:{show:!0,position:null,margin:30,formatter:null,color:"#ccc",fontFamily:"sans-serif",fontWeight:"bolder",fontSize:20}},e}(He);function Rz(r,e){var t=r.cellSize,n;J(t)?n=t:n=r.cellSize=[t,t],n.length===1&&(n[1]=n[0]);var a=K([0,1],function(i){return L$(e,i)&&(n[i]="auto"),n[i]!=null&&n[i]!=="auto"});fo(r,e,{type:"box",ignoreSize:a})}var Hne=Vne,Wne=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a){var i=this.group;i.removeAll();var o=t.coordinateSystem,s=o.getRangeInfo(),l=o.getOrient(),u=n.getLocaleModel();this._renderDayRect(t,s,i),this._renderLines(t,s,l,i),this._renderYearText(t,s,l,i),this._renderMonthText(t,u,l,i),this._renderWeekText(t,u,s,l,i)},e.prototype._renderDayRect=function(t,n,a){for(var i=t.coordinateSystem,o=t.getModel("itemStyle").getItemStyle(),s=i.getCellWidth(),l=i.getCellHeight(),u=n.start.time;u<=n.end.time;u=i.getNextNDay(u,1).time){var c=i.dataToRect([u],!1).tl,f=new We({shape:{x:c[0],y:c[1],width:s,height:l},cursor:"default",style:o});a.add(f)}},e.prototype._renderLines=function(t,n,a,i){var o=this,s=t.coordinateSystem,l=t.getModel(["splitLine","lineStyle"]).getLineStyle(),u=t.get(["splitLine","show"]),c=l.lineWidth;this._tlpoints=[],this._blpoints=[],this._firstDayOfMonth=[],this._firstDayPoints=[];for(var f=n.start,h=0;f.time<=n.end.time;h++){d(f.formatedDate),h===0&&(f=s.getDateInfo(n.start.y+"-"+n.start.m));var v=f.date;v.setMonth(v.getMonth()+1),f=s.getDateInfo(v)}d(s.getNextNDay(n.end.time,1).formatedDate);function d(p){o._firstDayOfMonth.push(s.getDateInfo(p)),o._firstDayPoints.push(s.dataToRect([p],!1).tl);var g=o._getLinePointsOfOneWeek(t,p,a);o._tlpoints.push(g[0]),o._blpoints.push(g[g.length-1]),u&&o._drawSplitline(g,l,i)}u&&this._drawSplitline(o._getEdgesPoints(o._tlpoints,c,a),l,i),u&&this._drawSplitline(o._getEdgesPoints(o._blpoints,c,a),l,i)},e.prototype._getEdgesPoints=function(t,n,a){var i=[t[0].slice(),t[t.length-1].slice()],o=a==="horizontal"?0:1;return i[0][o]=i[0][o]-n/2,i[1][o]=i[1][o]+n/2,i},e.prototype._drawSplitline=function(t,n,a){var i=new Xr({z2:20,shape:{points:t},style:n});a.add(i)},e.prototype._getLinePointsOfOneWeek=function(t,n,a){for(var i=t.coordinateSystem,o=i.getDateInfo(n),s=[],l=0;l<7;l++){var u=i.getNextNDay(o.time,l),c=i.dataToRect([u.time],!1);s[2*u.day]=c.tl,s[2*u.day+1]=c[a==="horizontal"?"bl":"tr"]}return s},e.prototype._formatterLabel=function(t,n){return ce(t)&&t?T$(t,n):ye(t)?t(n):n.nameMap},e.prototype._yearTextPositionControl=function(t,n,a,i,o){var s=n[0],l=n[1],u=["center","bottom"];i==="bottom"?(l+=o,u=["center","top"]):i==="left"?s-=o:i==="right"?(s+=o,u=["center","top"]):l-=o;var c=0;return(i==="left"||i==="right")&&(c=Math.PI/2),{rotation:c,x:s,y:l,style:{align:u[0],verticalAlign:u[1]}}},e.prototype._renderYearText=function(t,n,a,i){var o=t.getModel("yearLabel");if(!!o.get("show")){var s=o.get("margin"),l=o.get("position");l||(l=a!=="horizontal"?"top":"left");var u=[this._tlpoints[this._tlpoints.length-1],this._blpoints[0]],c=(u[0][0]+u[1][0])/2,f=(u[0][1]+u[1][1])/2,h=a==="horizontal"?0:1,v={top:[c,u[h][1]],bottom:[c,u[1-h][1]],left:[u[1-h][0],f],right:[u[h][0],f]},d=n.start.y;+n.end.y>+n.start.y&&(d=d+"-"+n.end.y);var p=o.get("formatter"),g={start:n.start.y,end:n.end.y,nameMap:d},y=this._formatterLabel(p,g),m=new Ge({z2:30,style:yt(o,{text:y})});m.attr(this._yearTextPositionControl(m,v[l],a,l,s)),i.add(m)}},e.prototype._monthTextPositionControl=function(t,n,a,i,o){var s="left",l="top",u=t[0],c=t[1];return a==="horizontal"?(c=c+o,n&&(s="center"),i==="start"&&(l="bottom")):(u=u+o,n&&(l="middle"),i==="start"&&(s="right")),{x:u,y:c,align:s,verticalAlign:l}},e.prototype._renderMonthText=function(t,n,a,i){var o=t.getModel("monthLabel");if(!!o.get("show")){var s=o.get("nameMap"),l=o.get("margin"),u=o.get("position"),c=o.get("align"),f=[this._tlpoints,this._blpoints];(!s||ce(s))&&(s&&(n=w1(s)||n),s=n.get(["time","monthAbbr"])||[]);var h=u==="start"?0:1,v=a==="horizontal"?0:1;l=u==="start"?-l:l;for(var d=c==="center",p=0;p<f[h].length-1;p++){var g=f[h][p].slice(),y=this._firstDayOfMonth[p];if(d){var m=this._firstDayPoints[p];g[v]=(m[v]+f[0][p+1][v])/2}var _=o.get("formatter"),b=s[+y.m-1],x={yyyy:y.y,yy:(y.y+"").slice(2),MM:y.m,M:+y.m,nameMap:b},M=this._formatterLabel(_,x),w=new Ge({z2:30,style:X(yt(o,{text:M}),this._monthTextPositionControl(g,d,a,u,l))});i.add(w)}}},e.prototype._weekTextPositionControl=function(t,n,a,i,o){var s="center",l="middle",u=t[0],c=t[1],f=a==="start";return n==="horizontal"?(u=u+i+(f?1:-1)*o[0]/2,s=f?"right":"left"):(c=c+i+(f?1:-1)*o[1]/2,l=f?"bottom":"top"),{x:u,y:c,align:s,verticalAlign:l}},e.prototype._renderWeekText=function(t,n,a,i,o){var s=t.getModel("dayLabel");if(!!s.get("show")){var l=t.coordinateSystem,u=s.get("position"),c=s.get("nameMap"),f=s.get("margin"),h=l.getFirstDayOfWeek();if(!c||ce(c)){c&&(n=w1(c)||n);var v=n.get(["time","dayOfWeekShort"]);c=v||K(n.get(["time","dayOfWeekAbbr"]),function(x){return x[0]})}var d=l.getNextNDay(a.end.time,7-a.lweek).time,p=[l.getCellWidth(),l.getCellHeight()];f=ue(f,Math.min(p[1],p[0])),u==="start"&&(d=l.getNextNDay(a.start.time,-(7+a.fweek)).time,f=-f);for(var g=0;g<7;g++){var y=l.getNextNDay(d,g),m=l.dataToRect([y.time],!1).center,_=g;_=Math.abs((g+h)%7);var b=new Ge({z2:30,style:X(yt(s,{text:c[_]}),this._weekTextPositionControl(m,i,u,f,p))});o.add(b)}}},e.type="calendar",e}(St),Gne=Wne,lx=864e5,$ne=function(){function r(e,t,n){this.type="calendar",this.dimensions=r.dimensions,this.getDimensionsInfo=r.getDimensionsInfo,this._model=e}return r.getDimensionsInfo=function(){return[{name:"time",type:"time"},"value"]},r.prototype.getRangeInfo=function(){return this._rangeInfo},r.prototype.getModel=function(){return this._model},r.prototype.getRect=function(){return this._rect},r.prototype.getCellWidth=function(){return this._sw},r.prototype.getCellHeight=function(){return this._sh},r.prototype.getOrient=function(){return this._orient},r.prototype.getFirstDayOfWeek=function(){return this._firstDayOfWeek},r.prototype.getDateInfo=function(e){e=Mn(e);var t=e.getFullYear(),n=e.getMonth()+1,a=n<10?"0"+n:""+n,i=e.getDate(),o=i<10?"0"+i:""+i,s=e.getDay();return s=Math.abs((s+7-this.getFirstDayOfWeek())%7),{y:t+"",m:a,d:o,day:s,time:e.getTime(),formatedDate:t+"-"+a+"-"+o,date:e}},r.prototype.getNextNDay=function(e,t){return t=t||0,t===0?this.getDateInfo(e):(e=new Date(this.getDateInfo(e).time),e.setDate(e.getDate()+t),this.getDateInfo(e))},r.prototype.update=function(e,t){this._firstDayOfWeek=+this._model.getModel("dayLabel").get("firstDay"),this._orient=this._model.get("orient"),this._lineWidth=this._model.getModel("itemStyle").getItemStyle().lineWidth||0,this._rangeInfo=this._getRangeInfo(this._initRangeOption());var n=this._rangeInfo.weeks||1,a=["width","height"],i=this._model.getCellSize().slice(),o=this._model.getBoxLayoutParams(),s=this._orient==="horizontal"?[n,7]:[7,n];C([0,1],function(f){c(i,f)&&(o[a[f]]=i[f]*s[f])});var l={width:t.getWidth(),height:t.getHeight()},u=this._rect=Yt(o,l);C([0,1],function(f){c(i,f)||(i[f]=u[a[f]]/s[f])});function c(f,h){return f[h]!=null&&f[h]!=="auto"}this._sw=i[0],this._sh=i[1]},r.prototype.dataToPoint=function(e,t){J(e)&&(e=e[0]),t==null&&(t=!0);var n=this.getDateInfo(e),a=this._rangeInfo,i=n.formatedDate;if(t&&!(n.time>=a.start.time&&n.time<a.end.time+lx))return[NaN,NaN];var o=n.day,s=this._getRangeInfo([a.start.time,i]).nthWeek;return this._orient==="vertical"?[this._rect.x+o*this._sw+this._sw/2,this._rect.y+s*this._sh+this._sh/2]:[this._rect.x+s*this._sw+this._sw/2,this._rect.y+o*this._sh+this._sh/2]},r.prototype.pointToData=function(e){var t=this.pointToDate(e);return t&&t.time},r.prototype.dataToRect=function(e,t){var n=this.dataToPoint(e,t);return{contentShape:{x:n[0]-(this._sw-this._lineWidth)/2,y:n[1]-(this._sh-this._lineWidth)/2,width:this._sw-this._lineWidth,height:this._sh-this._lineWidth},center:n,tl:[n[0]-this._sw/2,n[1]-this._sh/2],tr:[n[0]+this._sw/2,n[1]-this._sh/2],br:[n[0]+this._sw/2,n[1]+this._sh/2],bl:[n[0]-this._sw/2,n[1]+this._sh/2]}},r.prototype.pointToDate=function(e){var t=Math.floor((e[0]-this._rect.x)/this._sw)+1,n=Math.floor((e[1]-this._rect.y)/this._sh)+1,a=this._rangeInfo.range;return this._orient==="vertical"?this._getDateByWeeksAndDay(n,t-1,a):this._getDateByWeeksAndDay(t,n-1,a)},r.prototype.convertToPixel=function(e,t,n){var a=jz(t);return a===this?a.dataToPoint(n):null},r.prototype.convertFromPixel=function(e,t,n){var a=jz(t);return a===this?a.pointToData(n):null},r.prototype.containPoint=function(e){return console.warn("Not implemented."),!1},r.prototype._initRangeOption=function(){var e=this._model.get("range"),t;if(J(e)&&e.length===1&&(e=e[0]),J(e))t=e;else{var n=e.toString();if(/^\d{4}$/.test(n)&&(t=[n+"-01-01",n+"-12-31"]),/^\d{4}[\/|-]\d{1,2}$/.test(n)){var a=this.getDateInfo(n),i=a.date;i.setMonth(i.getMonth()+1);var o=this.getNextNDay(i,-1);t=[a.formatedDate,o.formatedDate]}/^\d{4}[\/|-]\d{1,2}[\/|-]\d{1,2}$/.test(n)&&(t=[n,n])}if(!t)return e;var s=this._getRangeInfo(t);return s.start.time>s.end.time&&t.reverse(),t},r.prototype._getRangeInfo=function(e){var t=[this.getDateInfo(e[0]),this.getDateInfo(e[1])],n;t[0].time>t[1].time&&(n=!0,t.reverse());var a=Math.floor(t[1].time/lx)-Math.floor(t[0].time/lx)+1,i=new Date(t[0].time),o=i.getDate(),s=t[1].date.getDate();i.setDate(o+a-1);var l=i.getDate();if(l!==s)for(var u=i.getTime()-t[1].time>0?1:-1;(l=i.getDate())!==s&&(i.getTime()-t[1].time)*u>0;)a-=u,i.setDate(l-u);var c=Math.floor((a+t[0].day+6)/7),f=n?-c+1:c-1;return n&&t.reverse(),{range:[t[0].formatedDate,t[1].formatedDate],start:t[0],end:t[1],allDay:a,weeks:c,nthWeek:f,fweek:t[0].day,lweek:t[1].day}},r.prototype._getDateByWeeksAndDay=function(e,t,n){var a=this._getRangeInfo(n);if(e>a.weeks||e===0&&t<a.fweek||e===a.weeks&&t>a.lweek)return null;var i=(e-1)*7-a.fweek+t,o=new Date(a.start.time);return o.setDate(+a.start.d+i),this.getDateInfo(o)},r.create=function(e,t){var n=[];return e.eachComponent("calendar",function(a){var i=new r(a);n.push(i),a.coordinateSystem=i}),e.eachSeries(function(a){a.get("coordinateSystem")==="calendar"&&(a.coordinateSystem=n[a.get("calendarIndex")||0])}),n},r.dimensions=["time","value"],r}();function jz(r){var e=r.calendarModel,t=r.seriesModel,n=e?e.coordinateSystem:t?t.coordinateSystem:null;return n}var Une=$ne;function Yne(r){r.registerComponentModel(Hne),r.registerComponentView(Gne),r.registerCoordinateSystem("calendar",Une)}function Qne(r,e){var t=r.existing;if(e.id=r.keyInfo.id,!e.type&&t&&(e.type=t.type),e.parentId==null){var n=e.parentOption;n?e.parentId=n.id:t&&(e.parentId=t.parentId)}e.parentOption=null}function Bz(r,e){var t;return C(e,function(n){r[n]!=null&&r[n]!=="auto"&&(t=!0)}),t}function Zne(r,e,t){var n=X({},t),a=r[e],i=t.$action||"merge";i==="merge"?a?(Ne(a,n,!0),fo(a,n,{ignoreSize:!0}),hC(t,a),vg(t,a),vg(t,a,"shape"),vg(t,a,"style"),vg(t,a,"extra"),t.clipPath=a.clipPath):r[e]=n:i==="replace"?r[e]=n:i==="remove"&&a&&(r[e]=null)}var Fz=["transition","enterFrom","leaveTo"],qne=Fz.concat(["enterAnimation","updateAnimation","leaveAnimation"]);function vg(r,e,t){if(t&&(!r[t]&&e[t]&&(r[t]={}),r=r[t],e=e[t]),!(!r||!e))for(var n=t?Fz:qne,a=0;a<n.length;a++){var i=n[a];r[i]==null&&e[i]!=null&&(r[i]=e[i])}}function Xne(r,e){if(!!r&&(r.hv=e.hv=[Bz(e,["left","right"]),Bz(e,["top","bottom"])],r.type==="group")){var t=r,n=e;t.width==null&&(t.width=n.width=0),t.height==null&&(t.height=n.height=0)}}var Jne=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.preventAutoZ=!0,t}return e.prototype.mergeOption=function(t,n){var a=this.option.elements;this.option.elements=null,r.prototype.mergeOption.call(this,t,n),this.option.elements=a},e.prototype.optionUpdated=function(t,n){var a=this.option,i=(n?a:t).elements,o=a.elements=n?[]:a.elements,s=[];this._flatten(i,s,null);var l=oT(o,s,"normalMerge"),u=this._elOptionsToUpdate=[];C(l,function(c,f){var h=c.newOption;!h||(u.push(h),Qne(c,h),Zne(o,f,h),Xne(o[f],h))},this),a.elements=ot(o,function(c){return c&&delete c.$action,c!=null})},e.prototype._flatten=function(t,n,a){C(t,function(i){if(!!i){a&&(i.parentOption=a),n.push(i);var o=i.children;o&&o.length&&this._flatten(o,n,i),delete i.children}},this)},e.prototype.useElOptionsToUpdate=function(){var t=this._elOptionsToUpdate;return this._elOptionsToUpdate=null,t},e.type="graphic",e.defaultOption={elements:[]},e}(He),Vz={path:null,compoundPath:null,group:De,image:pr,text:Ge},Jn=Ye(),Kne=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(){this._elMap=ge()},e.prototype.render=function(t,n,a){t!==this._lastGraphicModel&&this._clear(),this._lastGraphicModel=t,this._updateElements(t),this._relocate(t,a)},e.prototype._updateElements=function(t){var n=t.useElOptionsToUpdate();if(!!n){var a=this._elMap,i=this.group,o=t.get("z"),s=t.get("zlevel");C(n,function(l){var u=Kt(l.id,null),c=u!=null?a.get(u):null,f=Kt(l.parentId,null),h=f!=null?a.get(f):i,v=l.type,d=l.style;v==="text"&&d&&l.hv&&l.hv[1]&&(d.textVerticalAlign=d.textBaseline=d.verticalAlign=d.align=null);var p=l.textContent,g=l.textConfig;if(d&&G4(d,v,!!g,!!p)){var y=$4(d,v,!0);!g&&y.textConfig&&(g=l.textConfig=y.textConfig),!p&&y.textContent&&(p=y.textContent)}var m=eae(l),_=l.$action||"merge",b=_==="merge",x=_==="replace";if(b){var M=!c,w=c;M?w=Hz(u,h,l.type,a):(w&&(Jn(w).isNew=!1),tz(w)),w&&(ig(w,m,t,{isInit:M}),Wz(w,l,o,s))}else if(x){dg(c,l,a,t);var D=Hz(u,h,l.type,a);D&&(ig(D,m,t,{isInit:!0}),Wz(D,l,o,s))}else _==="remove"&&(X4(c,l),dg(c,l,a,t));var T=a.get(u);if(T&&p)if(b){var I=T.getTextContent();I?I.attr(p):T.setTextContent(new Ge(p))}else x&&T.setTextContent(new Ge(p));if(T){var A=l.clipPath;if(A){var N=A.type,L=void 0,M=!1;if(b){var E=T.getClipPath();M=!E||Jn(E).type!==N,L=M?ux(N):E}else x&&(M=!0,L=ux(N));T.setClipPath(L),ig(L,A,t,{isInit:M}),sg(L,A.keyframeAnimation,t)}var O=Jn(T);T.setTextConfig(g),O.option=l,tae(T,t,l),eu({el:T,componentModel:t,itemName:T.name,itemTooltipOption:l.tooltip}),sg(T,l.keyframeAnimation,t)}})}},e.prototype._relocate=function(t,n){for(var a=t.option.elements,i=this.group,o=this._elMap,s=n.getWidth(),l=n.getHeight(),u=["x","y"],c=0;c<a.length;c++){var f=a[c],h=Kt(f.id,null),v=h!=null?o.get(h):null;if(!(!v||!v.isGroup)){var d=v.parent,p=d===i,g=Jn(v),y=Jn(d);g.width=ue(g.option.width,p?s:y.width)||0,g.height=ue(g.option.height,p?l:y.height)||0}}for(var c=a.length-1;c>=0;c--){var f=a[c],h=Kt(f.id,null),v=h!=null?o.get(h):null;if(!!v){var d=v.parent,y=Jn(d),m=d===i?{width:s,height:l}:{width:y.width,height:y.height},_={},b=Vd(v,f,m,null,{hv:f.hv,boundingMode:f.bounding},_);if(!Jn(v).isNew&&b){for(var x=f.transition,M={},w=0;w<u.length;w++){var D=u[w],T=_[D];x&&(Ks(x)||ze(x,D)>=0)?M[D]=T:v[D]=T}Qe(v,M,t,0)}else v.attr(_)}}},e.prototype._clear=function(){var t=this,n=this._elMap;n.each(function(a){dg(a,Jn(a).option,n,t._lastGraphicModel)}),this._elMap=ge()},e.prototype.dispose=function(){this._clear()},e.type="graphic",e}(St);function ux(r){var e=ve(Vz,r)?Vz[r]:Td(r),t=new e({});return Jn(t).type=r,t}function Hz(r,e,t,n){var a=ux(t);return e.add(a),n.set(r,a),Jn(a).id=r,Jn(a).isNew=!0,a}function dg(r,e,t,n){var a=r&&r.parent;a&&(r.type==="group"&&r.traverse(function(i){dg(i,e,t,n)}),og(r,e,n),t.removeKey(Jn(r).id))}function Wz(r,e,t,n){r.isGroup||C([["cursor",Bn.prototype.cursor],["zlevel",n||0],["z",t||0],["z2",0]],function(a){var i=a[0];ve(e,i)?r[i]=Ee(e[i],a[1]):r[i]==null&&(r[i]=a[1])}),C(Fe(e),function(a){if(a.indexOf("on")===0){var i=e[a];r[a]=ye(i)?i:null}}),ve(e,"draggable")&&(r.draggable=e.draggable),e.name!=null&&(r.name=e.name),e.id!=null&&(r.id=e.id)}function eae(r){return r=X({},r),C(["id","parentId","$action","hv","bounding","textContent","clipPath"].concat(fC),function(e){delete r[e]}),r}function tae(r,e,t){var n=Te(r).eventData;!r.silent&&!r.ignore&&!n&&(n=Te(r).eventData={componentType:"graphic",componentIndex:e.componentIndex,name:r.name}),n&&(n.info=t.info)}function rae(r){r.registerComponentModel(Jne),r.registerComponentView(Kne),r.registerPreprocessor(function(e){var t=e.graphic;J(t)?!t[0]||!t[0].elements?e.graphic=[{elements:t}]:e.graphic=[e.graphic[0]]:t&&!t.elements&&(e.graphic=[{elements:[t]}])})}var Gz=["x","y","radius","angle","single"],nae=["cartesian2d","polar","singleAxis"];function aae(r){var e=r.get("coordinateSystem");return ze(nae,e)>=0}function Ao(r){return r+"Axis"}function iae(r,e){var t=ge(),n=[],a=ge();r.eachComponent({mainType:"dataZoom",query:e},function(c){a.get(c.uid)||s(c)});var i;do i=!1,r.eachComponent("dataZoom",o);while(i);function o(c){!a.get(c.uid)&&l(c)&&(s(c),i=!0)}function s(c){a.set(c.uid,!0),n.push(c),u(c)}function l(c){var f=!1;return c.eachTargetAxis(function(h,v){var d=t.get(h);d&&d[v]&&(f=!0)}),f}function u(c){c.eachTargetAxis(function(f,h){(t.get(f)||t.set(f,[]))[h]=!0})}return n}function $z(r){var e=r.ecModel,t={infoList:[],infoMap:ge()};return r.eachTargetAxis(function(n,a){var i=e.getComponent(Ao(n),a);if(!!i){var o=i.getCoordSysModel();if(!!o){var s=o.uid,l=t.infoMap.get(s);l||(l={model:o,axisModels:[]},t.infoList.push(l),t.infoMap.set(s,l)),l.axisModels.push(i)}}}),t}var cx=function(){function r(){this.indexList=[],this.indexMap=[]}return r.prototype.add=function(e){this.indexMap[e]||(this.indexList.push(e),this.indexMap[e]=!0)},r}(),oae=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._autoThrottle=!0,t._noTarget=!0,t._rangePropMode=["percent","percent"],t}return e.prototype.init=function(t,n,a){var i=Uz(t);this.settledOption=i,this.mergeDefaultAndTheme(t,a),this._doInit(i)},e.prototype.mergeOption=function(t){var n=Uz(t);Ne(this.option,t,!0),Ne(this.settledOption,n,!0),this._doInit(n)},e.prototype._doInit=function(t){var n=this.option;this._setDefaultThrottle(t),this._updateRangeUse(t);var a=this.settledOption;C([["start","startValue"],["end","endValue"]],function(i,o){this._rangePropMode[o]==="value"&&(n[i[0]]=a[i[0]]=null)},this),this._resetTarget()},e.prototype._resetTarget=function(){var t=this.get("orient",!0),n=this._targetAxisInfoMap=ge(),a=this._fillSpecifiedTargetAxis(n);a?this._orient=t||this._makeAutoOrientByTargetAxis():(this._orient=t||"horizontal",this._fillAutoTargetAxisByOrient(n,this._orient)),this._noTarget=!0,n.each(function(i){i.indexList.length&&(this._noTarget=!1)},this)},e.prototype._fillSpecifiedTargetAxis=function(t){var n=!1;return C(Gz,function(a){var i=this.getReferringComponents(Ao(a),cW);if(!!i.specified){n=!0;var o=new cx;C(i.models,function(s){o.add(s.componentIndex)}),t.set(a,o)}},this),n},e.prototype._fillAutoTargetAxisByOrient=function(t,n){var a=this.ecModel,i=!0;if(i){var o=n==="vertical"?"y":"x",s=a.findComponents({mainType:o+"Axis"});l(s,o)}if(i){var s=a.findComponents({mainType:"singleAxis",filter:function(c){return c.get("orient",!0)===n}});l(s,"single")}function l(u,c){var f=u[0];if(!!f){var h=new cx;if(h.add(f.componentIndex),t.set(c,h),i=!1,c==="x"||c==="y"){var v=f.getReferringComponents("grid",Ut).models[0];v&&C(u,function(d){f.componentIndex!==d.componentIndex&&v===d.getReferringComponents("grid",Ut).models[0]&&h.add(d.componentIndex)})}}}i&&C(Gz,function(u){if(!!i){var c=a.findComponents({mainType:Ao(u),filter:function(h){return h.get("type",!0)==="category"}});if(c[0]){var f=new cx;f.add(c[0].componentIndex),t.set(u,f),i=!1}}},this)},e.prototype._makeAutoOrientByTargetAxis=function(){var t;return this.eachTargetAxis(function(n){!t&&(t=n)},this),t==="y"?"vertical":"horizontal"},e.prototype._setDefaultThrottle=function(t){if(t.hasOwnProperty("throttle")&&(this._autoThrottle=!1),this._autoThrottle){var n=this.ecModel.option;this.option.throttle=n.animation&&n.animationDurationUpdate>0?100:20}},e.prototype._updateRangeUse=function(t){var n=this._rangePropMode,a=this.get("rangeMode");C([["start","startValue"],["end","endValue"]],function(i,o){var s=t[i[0]]!=null,l=t[i[1]]!=null;s&&!l?n[o]="percent":!s&&l?n[o]="value":a?n[o]=a[o]:s&&(n[o]="percent")})},e.prototype.noTarget=function(){return this._noTarget},e.prototype.getFirstTargetAxisModel=function(){var t;return this.eachTargetAxis(function(n,a){t==null&&(t=this.ecModel.getComponent(Ao(n),a))},this),t},e.prototype.eachTargetAxis=function(t,n){this._targetAxisInfoMap.each(function(a,i){C(a.indexList,function(o){t.call(n,i,o)})})},e.prototype.getAxisProxy=function(t,n){var a=this.getAxisModel(t,n);if(a)return a.__dzAxisProxy},e.prototype.getAxisModel=function(t,n){var a=this._targetAxisInfoMap.get(t);if(a&&a.indexMap[n])return this.ecModel.getComponent(Ao(t),n)},e.prototype.setRawRange=function(t){var n=this.option,a=this.settledOption;C([["start","startValue"],["end","endValue"]],function(i){(t[i[0]]!=null||t[i[1]]!=null)&&(n[i[0]]=a[i[0]]=t[i[0]],n[i[1]]=a[i[1]]=t[i[1]])},this),this._updateRangeUse(t)},e.prototype.setCalculatedRange=function(t){var n=this.option;C(["start","startValue","end","endValue"],function(a){n[a]=t[a]})},e.prototype.getPercentRange=function(){var t=this.findRepresentativeAxisProxy();if(t)return t.getDataPercentWindow()},e.prototype.getValueRange=function(t,n){if(t==null&&n==null){var a=this.findRepresentativeAxisProxy();if(a)return a.getDataValueWindow()}else return this.getAxisProxy(t,n).getDataValueWindow()},e.prototype.findRepresentativeAxisProxy=function(t){if(t)return t.__dzAxisProxy;for(var n,a=this._targetAxisInfoMap.keys(),i=0;i<a.length;i++)for(var o=a[i],s=this._targetAxisInfoMap.get(o),l=0;l<s.indexList.length;l++){var u=this.getAxisProxy(o,s.indexList[l]);if(u.hostedBy(this))return u;n||(n=u)}return n},e.prototype.getRangePropMode=function(){return this._rangePropMode.slice()},e.prototype.getOrient=function(){return this._orient},e.type="dataZoom",e.dependencies=["xAxis","yAxis","radiusAxis","angleAxis","singleAxis","series","toolbox"],e.defaultOption={z:4,filterMode:"filter",start:0,end:100},e}(He);function Uz(r){var e={};return C(["start","end","startValue","endValue","throttle"],function(t){r.hasOwnProperty(t)&&(e[t]=r[t])}),e}var dh=oae,sae=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="dataZoom.select",e}(dh),lae=sae,uae=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a,i){this.dataZoomModel=t,this.ecModel=n,this.api=a},e.type="dataZoom",e}(St),fx=uae,cae=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="dataZoom.select",e}(fx),fae=cae,zu=C,Yz=bn,hae=function(){function r(e,t,n,a){this._dimName=e,this._axisIndex=t,this.ecModel=a,this._dataZoomModel=n}return r.prototype.hostedBy=function(e){return this._dataZoomModel===e},r.prototype.getDataValueWindow=function(){return this._valueWindow.slice()},r.prototype.getDataPercentWindow=function(){return this._percentWindow.slice()},r.prototype.getTargetSeriesModels=function(){var e=[];return this.ecModel.eachSeries(function(t){if(aae(t)){var n=Ao(this._dimName),a=t.getReferringComponents(n,Ut).models[0];a&&this._axisIndex===a.componentIndex&&e.push(t)}},this),e},r.prototype.getAxisModel=function(){return this.ecModel.getComponent(this._dimName+"Axis",this._axisIndex)},r.prototype.getMinMaxSpan=function(){return Me(this._minMaxSpan)},r.prototype.calculateDataWindow=function(e){var t=this._dataExtent,n=this.getAxisModel(),a=n.axis.scale,i=this._dataZoomModel.getRangePropMode(),o=[0,100],s=[],l=[],u;zu(["start","end"],function(h,v){var d=e[h],p=e[h+"Value"];i[v]==="percent"?(d==null&&(d=o[v]),p=a.parse(st(d,o,t))):(u=!0,p=p==null?t[v]:a.parse(p),d=st(p,t,o)),l[v]=p==null||isNaN(p)?t[v]:p,s[v]=d==null||isNaN(d)?o[v]:d}),Yz(l),Yz(s);var c=this._minMaxSpan;u?f(l,s,t,o,!1):f(s,l,o,t,!0);function f(h,v,d,p,g){var y=g?"Span":"ValueSpan";qs(0,h,d,"all",c["min"+y],c["max"+y]);for(var m=0;m<2;m++)v[m]=st(h[m],d,p,!0),g&&(v[m]=a.parse(v[m]))}return{valueWindow:l,percentWindow:s}},r.prototype.reset=function(e){if(e===this._dataZoomModel){var t=this.getTargetSeriesModels();this._dataExtent=vae(this,this._dimName,t),this._updateMinMaxSpan();var n=this.calculateDataWindow(e.settledOption);this._valueWindow=n.valueWindow,this._percentWindow=n.percentWindow,this._setAxisModel()}},r.prototype.filterData=function(e,t){if(e!==this._dataZoomModel)return;var n=this._dimName,a=this.getTargetSeriesModels(),i=e.get("filterMode"),o=this._valueWindow;if(i==="none")return;zu(a,function(l){var u=l.getData(),c=u.mapDimensionsAll(n);if(!!c.length){if(i==="weakFilter"){var f=u.getStore(),h=K(c,function(v){return u.getDimensionIndex(v)},u);u.filterSelf(function(v){for(var d,p,g,y=0;y<c.length;y++){var m=f.get(h[y],v),_=!isNaN(m),b=m<o[0],x=m>o[1];if(_&&!b&&!x)return!0;_&&(g=!0),b&&(d=!0),x&&(p=!0)}return g&&d&&p})}else zu(c,function(v){if(i==="empty")l.setData(u=u.map(v,function(p){return s(p)?p:NaN}));else{var d={};d[v]=o,u.selectRange(d)}});zu(c,function(v){u.setApproximateExtent(o,v)})}});function s(l){return l>=o[0]&&l<=o[1]}},r.prototype._updateMinMaxSpan=function(){var e=this._minMaxSpan={},t=this._dataZoomModel,n=this._dataExtent;zu(["min","max"],function(a){var i=t.get(a+"Span"),o=t.get(a+"ValueSpan");o!=null&&(o=this.getAxisModel().axis.scale.parse(o)),o!=null?i=st(n[0]+o,n,[0,100],!0):i!=null&&(o=st(i,[0,100],n,!0)-n[0]),e[a+"Span"]=i,e[a+"ValueSpan"]=o},this)},r.prototype._setAxisModel=function(){var e=this.getAxisModel(),t=this._percentWindow,n=this._valueWindow;if(!!t){var a=w0(n,[0,500]);a=Math.min(a,20);var i=e.axis.scale.rawExtentInfo;t[0]!==0&&i.setDeterminedMinMax("min",+n[0].toFixed(a)),t[1]!==100&&i.setDeterminedMinMax("max",+n[1].toFixed(a)),i.freeze()}},r}();function vae(r,e,t){var n=[1/0,-1/0];zu(t,function(o){wQ(n,o.getData(),e)});var a=r.getAxisModel(),i=a2(a.axis.scale,a,n).calculate();return[i.min,i.max]}var dae=hae,pae={getTargetSeries:function(r){function e(a){r.eachComponent("dataZoom",function(i){i.eachTargetAxis(function(o,s){var l=r.getComponent(Ao(o),s);a(o,s,l,i)})})}e(function(a,i,o,s){o.__dzAxisProxy=null});var t=[];e(function(a,i,o,s){o.__dzAxisProxy||(o.__dzAxisProxy=new dae(a,i,s,r),t.push(o.__dzAxisProxy))});var n=ge();return C(t,function(a){C(a.getTargetSeriesModels(),function(i){n.set(i.uid,i)})}),n},overallReset:function(r,e){r.eachComponent("dataZoom",function(t){t.eachTargetAxis(function(n,a){t.getAxisProxy(n,a).reset(t)}),t.eachTargetAxis(function(n,a){t.getAxisProxy(n,a).filterData(t,e)})}),r.eachComponent("dataZoom",function(t){var n=t.findRepresentativeAxisProxy();if(n){var a=n.getDataPercentWindow(),i=n.getDataValueWindow();t.setCalculatedRange({start:a[0],end:a[1],startValue:i[0],endValue:i[1]})}})}},gae=pae;function yae(r){r.registerAction("dataZoom",function(e,t){var n=iae(t,e);C(n,function(a){a.setRawRange({start:e.start,end:e.end,startValue:e.startValue,endValue:e.endValue})})})}var Qz=!1;function hx(r){Qz||(Qz=!0,r.registerProcessor(r.PRIORITY.PROCESSOR.FILTER,gae),yae(r),r.registerSubTypeDefaulter("dataZoom",function(){return"slider"}))}function mae(r){r.registerComponentModel(lae),r.registerComponentView(fae),hx(r)}var Kn=function(){function r(){}return r}(),Zz={};function ku(r,e){Zz[r]=e}function qz(r){return Zz[r]}var _ae=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.optionUpdated=function(){r.prototype.optionUpdated.apply(this,arguments);var t=this.ecModel;C(this.option.feature,function(n,a){var i=qz(a);i&&(i.getDefaultOption&&(i.defaultOption=i.getDefaultOption(t)),Ne(n,i.defaultOption))})},e.type="toolbox",e.layoutMode={type:"box",ignoreSize:!0},e.defaultOption={show:!0,z:6,orient:"horizontal",left:"right",top:"top",backgroundColor:"transparent",borderColor:"#ccc",borderRadius:0,borderWidth:0,padding:5,itemSize:15,itemGap:8,showTitle:!0,iconStyle:{borderColor:"#666",color:"none"},emphasis:{iconStyle:{borderColor:"#3E98C5"}},tooltip:{show:!1,position:"bottom"}},e}(He),bae=_ae;function Mae(r,e,t){var n=e.getBoxLayoutParams(),a=e.get("padding"),i={width:t.getWidth(),height:t.getHeight()},o=Yt(n,i,a);Ss(e.get("orient"),r,e.get("itemGap"),o.width,o.height),Vd(r,n,i,a)}function Xz(r,e){var t=xs(e.get("padding")),n=e.getItemStyle(["color","opacity"]);return n.fill=e.get("backgroundColor"),r=new We({shape:{x:r.x-t[3],y:r.y-t[0],width:r.width+t[1]+t[3],height:r.height+t[0]+t[2],r:e.get("borderRadius")},style:n,silent:!0,z2:-1}),r}var xae=function(r){U(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.render=function(t,n,a,i){var o=this.group;if(o.removeAll(),!t.get("show"))return;var s=+t.get("itemSize"),l=t.get("orient")==="vertical",u=t.get("feature")||{},c=this._features||(this._features={}),f=[];C(u,function(d,p){f.push(p)}),new Mi(this._featureNames||[],f).add(h).update(h).remove(Ae(h,null)).execute(),this._featureNames=f;function h(d,p){var g=f[d],y=f[p],m=u[g],_=new ft(m,t,t.ecModel),b;if(i&&i.newTitle!=null&&i.featureName===g&&(m.title=i.newTitle),g&&!y){if(wae(g))b={onclick:_.option.onclick,featureName:g};else{var x=qz(g);if(!x)return;b=new x}c[g]=b}else if(b=c[y],!b)return;b.uid=ru("toolbox-feature"),b.model=_,b.ecModel=n,b.api=a;var M=b instanceof Kn;if(!g&&y){M&&b.dispose&&b.dispose(n,a);return}if(!_.get("show")||M&&b.unusable){M&&b.remove&&b.remove(n,a);return}v(_,b,g),_.setIconStatus=function(w,D){var T=this.option,I=this.iconPaths;T.iconStatus=T.iconStatus||{},T.iconStatus[w]=D,I[w]&&(D==="emphasis"?mi:_i)(I[w])},b instanceof Kn&&b.render&&b.render(_,n,a,i)}function v(d,p,g){var y=d.getModel("iconStyle"),m=d.getModel(["emphasis","iconStyle"]),_=p instanceof Kn&&p.getIcons?p.getIcons():d.get("icon"),b=d.get("title")||{},x,M;ce(_)?(x={},x[g]=_):x=_,ce(b)?(M={},M[g]=b):M=b;var w=d.iconPaths={};C(x,function(D,T){var I=Kl(D,{},{x:-s/2,y:-s/2,width:s,height:s});I.setStyle(y.getItemStyle());var A=I.ensureState("emphasis");A.style=m.getItemStyle();var N=new Ge({style:{text:M[T],align:m.get("textAlign"),borderRadius:m.get("textBorderRadius"),padding:m.get("textPadding"),fill:null},ignore:!0});I.setTextContent(N),eu({el:I,componentModel:t,itemName:T,formatterParamsExtra:{title:M[T]}}),I.__title=M[T],I.on("mouseover",function(){var L=m.getItemStyle(),E=l?t.get("right")==null&&t.get("left")!=="right"?"right":"left":t.get("bottom")==null&&t.get("top")!=="bottom"?"bottom":"top";N.setStyle({fill:m.get("textFill")||L.fill||L.stroke||"#000",backgroundColor:m.get("textBackgroundColor")}),I.setTextConfig({position:m.get("textPosition")||E}),N.ignore=!t.get("showTitle"),a.enterEmphasis(this)}).on("mouseout",function(){d.get(["iconStatus",T])!=="emphasis"&&a.leaveEmphasis(this),N.hide()}),(d.get(["iconStatus",T])==="emphasis"?mi:_i)(I),o.add(I),I.on("click",fe(p.onclick,p,n,a,T)),w[T]=I})}Mae(o,t,a),o.add(Xz(o.getBoundingRect(),t)),l||o.eachChild(function(d){var p=d.__title,g=d.ensureState("emphasis"),y=g.textConfig||(g.textConfig={}),m=d.getTextContent(),_=m&&m.ensureState("emphasis");if(_&&!ye(_)&&p){var b=_.style||(_.style={}),x=jc(p,Ge.makeFont(b)),M=d.x+o.x,w=d.y+o.y+s,D=!1;w+x.height>a.getHeight()&&(y.position="top",D=!0);var T=D?-5-x.height:s+10;M+x.width/2>a.getWidth()?(y.position=["100%",T],b.align="right"):M-x.width/2<0&&(y.position=[0,T],b.align="left")}})},e.prototype.updateView=function(t,n,a,i){C(this._features,function(o){o instanceof Kn&&o.updateView&&o.updateView(o.model,n,a,i)})},e.prototype.remove=function(t,n){C(this._features,function(a){a instanceof Kn&&a.remove&&a.remove(t,n)}),this.group.removeAll()},e.prototype.dispose=function(t,n){C(this._features,function(a){a instanceof Kn&&a.dispose&&a.dispose(t,n)})},e.type="toolbox",e}(St);function wae(r){return r.indexOf("my")===0}var Dae=xae,Sae=function(r){U(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.onclick=function(t,n){var a=this.model,i=a.get("name")||t.get("title.0.text")||"echarts",o=n.getZr().painter.getType()==="svg",s=o?"svg":a.get("type",!0)||"png",l=n.getConnectedDataURL({type:s,backgroundColor:a.get("backgroundColor",!0)||t.get("backgroundColor")||"#fff",connectedBackgroundColor:a.get("connectedBackgroundColor"),excludeComponents:a.get("excludeComponents"),pixelRatio:a.get("pixelRatio")}),u=$e.browser;if(ye(MouseEvent)&&(u.newEdge||!u.ie&&!u.edge)){var c=document.createElement("a");c.download=i+"."+s,c.target="_blank",c.href=l;var f=new MouseEvent("click",{view:document.defaultView,bubbles:!0,cancelable:!1});c.dispatchEvent(f)}else if(window.navigator.msSaveOrOpenBlob||o){var h=l.split(","),v=h[0].indexOf("base64")>-1,d=o?decodeURIComponent(h[1]):h[1];v&&(d=window.atob(d));var p=i+"."+s;if(window.navigator.msSaveOrOpenBlob){for(var g=d.length,y=new Uint8Array(g);g--;)y[g]=d.charCodeAt(g);var m=new Blob([y]);window.navigator.msSaveOrOpenBlob(m,p)}else{var _=document.createElement("iframe");document.body.appendChild(_);var b=_.contentWindow,x=b.document;x.open("image/svg+xml","replace"),x.write(d),x.close(),b.focus(),x.execCommand("SaveAs",!0,p),document.body.removeChild(_)}}else{var M=a.get("lang"),w='<body style="margin:0;"><img src="'+l+'" style="max-width:100%;" title="'+(M&&M[0]||"")+'" /></body>',D=window.open();D.document.write(w),D.document.title=i}},e.getDefaultOption=function(t){var n={show:!0,icon:"M4.7,22.9L29.3,45.5L54.7,23.4M4.6,43.6L4.6,58L53.8,58L53.8,43.6M29.2,45.1L29.2,0",title:t.getLocaleModel().get(["toolbox","saveAsImage","title"]),type:"png",connectedBackgroundColor:"#fff",name:"",excludeComponents:["toolbox"],lang:t.getLocaleModel().get(["toolbox","saveAsImage","lang"])};return n},e}(Kn),Iae=Sae,Jz="__ec_magicType_stack__",Tae=[["line","bar"],["stack"]],Aae=function(r){U(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getIcons=function(){var t=this.model,n=t.get("icon"),a={};return C(t.get("type"),function(i){n[i]&&(a[i]=n[i])}),a},e.getDefaultOption=function(t){var n={show:!0,type:[],icon:{line:"M4.1,28.9h7.1l9.3-22l7.4,38l9.7-19.7l3,12.8h14.9M4.1,58h51.4",bar:"M6.7,22.9h10V48h-10V22.9zM24.9,13h10v35h-10V13zM43.2,2h10v46h-10V2zM3.1,58h53.7",stack:"M8.2,38.4l-8.4,4.1l30.6,15.3L60,42.5l-8.1-4.1l-21.5,11L8.2,38.4z M51.9,30l-8.1,4.2l-13.4,6.9l-13.9-6.9L8.2,30l-8.4,4.2l8.4,4.2l22.2,11l21.5-11l8.1-4.2L51.9,30z M51.9,21.7l-8.1,4.2L35.7,30l-5.3,2.8L24.9,30l-8.4-4.1l-8.3-4.2l-8.4,4.2L8.2,30l8.3,4.2l13.9,6.9l13.4-6.9l8.1-4.2l8.1-4.1L51.9,21.7zM30.4,2.2L-0.2,17.5l8.4,4.1l8.3,4.2l8.4,4.2l5.5,2.7l5.3-2.7l8.1-4.2l8.1-4.2l8.1-4.1L30.4,2.2z"},title:t.getLocaleModel().get(["toolbox","magicType","title"]),option:{},seriesIndex:{}};return n},e.prototype.onclick=function(t,n,a){var i=this.model,o=i.get(["seriesIndex",a]);if(!!Kz[a]){var s={series:[]},l=function(f){var h=f.subType,v=f.id,d=Kz[a](h,v,f,i);d&&(me(d,f.option),s.series.push(d));var p=f.coordinateSystem;if(p&&p.type==="cartesian2d"&&(a==="line"||a==="bar")){var g=p.getAxesByScale("ordinal")[0];if(g){var y=g.dim,m=y+"Axis",_=f.getReferringComponents(m,Ut).models[0],b=_.componentIndex;s[m]=s[m]||[];for(var x=0;x<=b;x++)s[m][b]=s[m][b]||{};s[m][b].boundaryGap=a==="bar"}}};C(Tae,function(f){ze(f,a)>=0&&C(f,function(h){i.setIconStatus(h,"normal")})}),i.setIconStatus(a,"emphasis"),t.eachComponent({mainType:"series",query:o==null?null:{seriesIndex:o}},l);var u,c=a;a==="stack"&&(u=Ne({stack:i.option.title.tiled,tiled:i.option.title.stack},i.option.title),i.get(["iconStatus",a])!=="emphasis"&&(c="tiled")),n.dispatchAction({type:"changeMagicType",currentType:c,newOption:s,newTitle:u,featureName:"magicType"})}},e}(Kn),Kz={line:function(r,e,t,n){if(r==="bar")return Ne({id:e,type:"line",data:t.get("data"),stack:t.get("stack"),markPoint:t.get("markPoint"),markLine:t.get("markLine")},n.get(["option","line"])||{},!0)},bar:function(r,e,t,n){if(r==="line")return Ne({id:e,type:"bar",data:t.get("data"),stack:t.get("stack"),markPoint:t.get("markPoint"),markLine:t.get("markLine")},n.get(["option","bar"])||{},!0)},stack:function(r,e,t,n){var a=t.get("stack")===Jz;if(r==="line"||r==="bar")return n.setIconStatus("stack",a?"normal":"emphasis"),Ne({id:e,stack:a?"":Jz},n.get(["option","stack"])||{},!0)}};Ma({type:"changeMagicType",event:"magicTypeChanged",update:"prepareAndUpdate"},function(r,e){e.mergeOption(r.newOption)});var Cae=Aae,pg=new Array(60).join("-"),Ru=" ";function Nae(r){var e={},t=[],n=[];return r.eachRawSeries(function(a){var i=a.coordinateSystem;if(i&&(i.type==="cartesian2d"||i.type==="polar")){var o=i.getBaseAxis();if(o.type==="category"){var s=o.dim+"_"+o.index;e[s]||(e[s]={categoryAxis:o,valueAxis:i.getOtherAxis(o),series:[]},n.push({axisDim:o.dim,axisIndex:o.index})),e[s].series.push(a)}else t.push(a)}else t.push(a)}),{seriesGroupByCategoryAxis:e,other:t,meta:n}}function Lae(r){var e=[];return C(r,function(t,n){var a=t.categoryAxis,i=t.valueAxis,o=i.dim,s=[" "].concat(K(t.series,function(v){return v.name})),l=[a.model.getCategories()];C(t.series,function(v){var d=v.getRawData();l.push(v.getRawData().mapArray(d.mapDimension(o),function(p){return p}))});for(var u=[s.join(Ru)],c=0;c<l[0].length;c++){for(var f=[],h=0;h<l.length;h++)f.push(l[h][c]);u.push(f.join(Ru))}e.push(u.join(`
|
|
241
|
+
`))}),e.join(`
|
|
242
|
+
|
|
243
|
+
`+pg+`
|
|
244
|
+
|
|
245
|
+
`)}function Eae(r){return K(r,function(e){var t=e.getRawData(),n=[e.name],a=[];return t.each(t.dimensions,function(){for(var i=arguments.length,o=arguments[i-1],s=t.getName(o),l=0;l<i-1;l++)a[l]=arguments[l];n.push((s?s+Ru:"")+a.join(Ru))}),n.join(`
|
|
246
|
+
`)}).join(`
|
|
247
|
+
|
|
248
|
+
`+pg+`
|
|
249
|
+
|
|
250
|
+
`)}function Oae(r){var e=Nae(r);return{value:ot([Lae(e.seriesGroupByCategoryAxis),Eae(e.other)],function(t){return!!t.replace(/[\n\t\s]/g,"")}).join(`
|
|
251
|
+
|
|
252
|
+
`+pg+`
|
|
253
|
+
|
|
254
|
+
`),meta:e.meta}}function gg(r){return r.replace(/^\s\s*/,"").replace(/\s\s*$/,"")}function Pae(r){var e=r.slice(0,r.indexOf(`
|
|
255
|
+
`));if(e.indexOf(Ru)>=0)return!0}var vx=new RegExp("["+Ru+"]+","g");function zae(r){for(var e=r.split(/\n+/g),t=gg(e.shift()).split(vx),n=[],a=K(t,function(l){return{name:l,data:[]}}),i=0;i<e.length;i++){var o=gg(e[i]).split(vx);n.push(o.shift());for(var s=0;s<o.length;s++)a[s]&&(a[s].data[i]=o[s])}return{series:a,categories:n}}function kae(r){for(var e=r.split(/\n+/g),t=gg(e.shift()),n=[],a=0;a<e.length;a++){var i=gg(e[a]);if(!!i){var o=i.split(vx),s="",l=void 0,u=!1;isNaN(o[0])?(u=!0,s=o[0],o=o.slice(1),n[a]={name:s,value:[]},l=n[a].value):l=n[a]=[];for(var c=0;c<o.length;c++)l.push(+o[c]);l.length===1&&(u?n[a].value=l[0]:n[a]=l[0])}}return{name:t,data:n}}function Rae(r,e){var t=r.split(new RegExp(`
|
|
256
|
+
*`+pg+`
|
|
257
|
+
*`,"g")),n={series:[]};return C(t,function(a,i){if(Pae(a)){var o=zae(a),s=e[i],l=s.axisDim+"Axis";s&&(n[l]=n[l]||[],n[l][s.axisIndex]={data:o.categories},n.series=n.series.concat(o.series))}else{var o=kae(a);n.series.push(o)}}),n}var jae=function(r){U(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.onclick=function(t,n){setTimeout(function(){n.dispatchAction({type:"hideTip"})});var a=n.getDom(),i=this.model;this._dom&&a.removeChild(this._dom);var o=document.createElement("div");o.style.cssText="position:absolute;top:0;bottom:0;left:0;right:0;padding:5px",o.style.backgroundColor=i.get("backgroundColor")||"#fff";var s=document.createElement("h4"),l=i.get("lang")||[];s.innerHTML=l[0]||i.get("title"),s.style.cssText="margin:10px 20px",s.style.color=i.get("textColor");var u=document.createElement("div"),c=document.createElement("textarea");u.style.cssText="overflow:auto";var f=i.get("optionToContent"),h=i.get("contentToOption"),v=Oae(t);if(ye(f)){var d=f(n.getOption());ce(d)?u.innerHTML=d:Ll(d)&&u.appendChild(d)}else{c.readOnly=i.get("readOnly");var p=c.style;p.cssText="display:block;width:100%;height:100%;font-family:monospace;font-size:14px;line-height:1.6rem;resize:none;box-sizing:border-box;outline:none",p.color=i.get("textColor"),p.borderColor=i.get("textareaBorderColor"),p.backgroundColor=i.get("textareaColor"),c.value=v.value,u.appendChild(c)}var g=v.meta,y=document.createElement("div");y.style.cssText="position:absolute;bottom:5px;left:0;right:0";var m="float:right;margin-right:20px;border:none;cursor:pointer;padding:2px 5px;font-size:12px;border-radius:3px",_=document.createElement("div"),b=document.createElement("div");m+=";background-color:"+i.get("buttonColor"),m+=";color:"+i.get("buttonTextColor");var x=this;function M(){a.removeChild(o),x._dom=null}Bm(_,"click",M),Bm(b,"click",function(){if(h==null&&f!=null||h!=null&&f==null){M();return}var w;try{ye(h)?w=h(u,n.getOption()):w=Rae(c.value,g)}catch(D){throw M(),new Error("Data view format error "+D)}w&&n.dispatchAction({type:"changeDataView",newOption:w}),M()}),_.innerHTML=l[1],b.innerHTML=l[2],b.style.cssText=_.style.cssText=m,!i.get("readOnly")&&y.appendChild(b),y.appendChild(_),o.appendChild(s),o.appendChild(u),o.appendChild(y),u.style.height=a.clientHeight-80+"px",a.appendChild(o),this._dom=o},e.prototype.remove=function(t,n){this._dom&&n.getDom().removeChild(this._dom)},e.prototype.dispose=function(t,n){this.remove(t,n)},e.getDefaultOption=function(t){var n={show:!0,readOnly:!1,optionToContent:null,contentToOption:null,icon:"M17.5,17.3H33 M17.5,17.3H33 M45.4,29.5h-28 M11.5,2v56H51V14.8L38.4,2H11.5z M38.4,2.2v12.7H51 M45.4,41.7h-28",title:t.getLocaleModel().get(["toolbox","dataView","title"]),lang:t.getLocaleModel().get(["toolbox","dataView","lang"]),backgroundColor:"#fff",textColor:"#000",textareaColor:"#fff",textareaBorderColor:"#333",buttonColor:"#c23531",buttonTextColor:"#fff"};return n},e}(Kn);function Bae(r,e){return K(r,function(t,n){var a=e&&e[n];if(_e(a)&&!J(a)){var i=_e(t)&&!J(t);i||(t={value:t});var o=a.name!=null&&t.name==null;return t=me(t,a),o&&delete t.name,t}else return t})}Ma({type:"changeDataView",event:"dataViewChanged",update:"prepareAndUpdate"},function(r,e){var t=[];C(r.newOption.series,function(n){var a=e.getSeriesByName(n.name)[0];if(!a)t.push(X({type:"scatter"},n));else{var i=a.get("data");t.push({name:n.name,data:Bae(n.data,i)})}}),e.mergeOption(me({series:t},r.newOption))});var Fae=jae,ek=C,tk=Ye();function Vae(r,e){var t=dx(r);ek(e,function(n,a){for(var i=t.length-1;i>=0;i--){var o=t[i];if(o[a])break}if(i<0){var s=r.queryComponents({mainType:"dataZoom",subType:"select",id:a})[0];if(s){var l=s.getPercentRange();t[0][a]={dataZoomId:a,start:l[0],end:l[1]}}}}),t.push(e)}function Hae(r){var e=dx(r),t=e[e.length-1];e.length>1&&e.pop();var n={};return ek(t,function(a,i){for(var o=e.length-1;o>=0;o--)if(a=e[o][i],a){n[i]=a;break}}),n}function Wae(r){tk(r).snapshots=null}function Gae(r){return dx(r).length}function dx(r){var e=tk(r);return e.snapshots||(e.snapshots=[{}]),e.snapshots}var $ae=function(r){U(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.onclick=function(t,n){Wae(t),n.dispatchAction({type:"restore",from:this.uid})},e.getDefaultOption=function(t){var n={show:!0,icon:"M3.8,33.4 M47,18.9h9.8V8.7 M56.3,20.1 C52.1,9,40.5,0.6,26.8,2.1C12.6,3.7,1.6,16.2,2.1,30.6 M13,41.1H3.1v10.2 M3.7,39.9c4.2,11.1,15.8,19.5,29.5,18 c14.2-1.6,25.2-14.1,24.7-28.5",title:t.getLocaleModel().get(["toolbox","restore","title"])};return n},e}(Kn);Ma({type:"restore",event:"restore",update:"prepareAndUpdate"},function(r,e){e.resetOption("recreate")});var Uae=$ae,Yae=["grid","xAxis","yAxis","geo","graph","polar","radiusAxis","angleAxis","bmap"],Qae=function(){function r(e,t,n){var a=this;this._targetInfoList=[];var i=rk(t,e);C(Zae,function(o,s){(!n||!n.include||ze(n.include,s)>=0)&&o(i,a._targetInfoList)})}return r.prototype.setOutputRanges=function(e,t){return this.matchOutputRanges(e,t,function(n,a,i){if((n.coordRanges||(n.coordRanges=[])).push(a),!n.coordRange){n.coordRange=a;var o=gx[n.brushType](0,i,a);n.__rangeOffset={offset:ok[n.brushType](o.values,n.range,[1,1]),xyMinMax:o.xyMinMax}}}),e},r.prototype.matchOutputRanges=function(e,t,n){C(e,function(a){var i=this.findTargetInfo(a,t);i&&i!==!0&&C(i.coordSyses,function(o){var s=gx[a.brushType](1,o,a.range,!0);n(a,s.values,o,t)})},this)},r.prototype.setInputRanges=function(e,t){C(e,function(n){var a=this.findTargetInfo(n,t);if(n.range=n.range||[],a&&a!==!0){n.panelId=a.panelId;var i=gx[n.brushType](0,a.coordSys,n.coordRange),o=n.__rangeOffset;n.range=o?ok[n.brushType](i.values,o.offset,qae(i.xyMinMax,o.xyMinMax)):i.values}},this)},r.prototype.makePanelOpts=function(e,t){return K(this._targetInfoList,function(n){var a=n.getPanelRect();return{panelId:n.panelId,defaultBrushType:t?t(n):null,clipPath:i4(a),isTargetByCursor:s4(a,e,n.coordSysModel),getLinearBrushOtherExtent:o4(a)}})},r.prototype.controlSeries=function(e,t,n){var a=this.findTargetInfo(e,n);return a===!0||a&&ze(a.coordSyses,t.coordinateSystem)>=0},r.prototype.findTargetInfo=function(e,t){for(var n=this._targetInfoList,a=rk(t,e),i=0;i<n.length;i++){var o=n[i],s=e.panelId;if(s){if(o.panelId===s)return o}else for(var l=0;l<nk.length;l++)if(nk[l](a,o))return o}return!0},r}();function px(r){return r[0]>r[1]&&r.reverse(),r}function rk(r,e){return Wc(r,e,{includeMainTypes:Yae})}var Zae={grid:function(r,e){var t=r.xAxisModels,n=r.yAxisModels,a=r.gridModels,i=ge(),o={},s={};!t&&!n&&!a||(C(t,function(l){var u=l.axis.grid.model;i.set(u.id,u),o[u.id]=!0}),C(n,function(l){var u=l.axis.grid.model;i.set(u.id,u),s[u.id]=!0}),C(a,function(l){i.set(l.id,l),o[l.id]=!0,s[l.id]=!0}),i.each(function(l){var u=l.coordinateSystem,c=[];C(u.getCartesians(),function(f,h){(ze(t,f.getAxis("x").model)>=0||ze(n,f.getAxis("y").model)>=0)&&c.push(f)}),e.push({panelId:"grid--"+l.id,gridModel:l,coordSysModel:l,coordSys:c[0],coordSyses:c,getPanelRect:ak.grid,xAxisDeclared:o[l.id],yAxisDeclared:s[l.id]})}))},geo:function(r,e){C(r.geoModels,function(t){var n=t.coordinateSystem;e.push({panelId:"geo--"+t.id,geoModel:t,coordSysModel:t,coordSys:n,coordSyses:[n],getPanelRect:ak.geo})})}},nk=[function(r,e){var t=r.xAxisModel,n=r.yAxisModel,a=r.gridModel;return!a&&t&&(a=t.axis.grid.model),!a&&n&&(a=n.axis.grid.model),a&&a===e.gridModel},function(r,e){var t=r.geoModel;return t&&t===e.geoModel}],ak={grid:function(){return this.coordSys.master.getRect().clone()},geo:function(){var r=this.coordSys,e=r.getBoundingRect().clone();return e.applyTransform(lo(r)),e}},gx={lineX:Ae(ik,0),lineY:Ae(ik,1),rect:function(r,e,t,n){var a=r?e.pointToData([t[0][0],t[1][0]],n):e.dataToPoint([t[0][0],t[1][0]],n),i=r?e.pointToData([t[0][1],t[1][1]],n):e.dataToPoint([t[0][1],t[1][1]],n),o=[px([a[0],i[0]]),px([a[1],i[1]])];return{values:o,xyMinMax:o}},polygon:function(r,e,t,n){var a=[[1/0,-1/0],[1/0,-1/0]],i=K(t,function(o){var s=r?e.pointToData(o,n):e.dataToPoint(o,n);return a[0][0]=Math.min(a[0][0],s[0]),a[1][0]=Math.min(a[1][0],s[1]),a[0][1]=Math.max(a[0][1],s[0]),a[1][1]=Math.max(a[1][1],s[1]),s});return{values:i,xyMinMax:a}}};function ik(r,e,t,n){var a=t.getAxis(["x","y"][r]),i=px(K([0,1],function(s){return e?a.coordToData(a.toLocalCoord(n[s]),!0):a.toGlobalCoord(a.dataToCoord(n[s]))})),o=[];return o[r]=i,o[1-r]=[NaN,NaN],{values:i,xyMinMax:o}}var ok={lineX:Ae(sk,0),lineY:Ae(sk,1),rect:function(r,e,t){return[[r[0][0]-t[0]*e[0][0],r[0][1]-t[0]*e[0][1]],[r[1][0]-t[1]*e[1][0],r[1][1]-t[1]*e[1][1]]]},polygon:function(r,e,t){return K(r,function(n,a){return[n[0]-t[0]*e[a][0],n[1]-t[1]*e[a][1]]})}};function sk(r,e,t,n){return[e[0]-n[r]*t[0],e[1]-n[r]*t[1]]}function qae(r,e){var t=lk(r),n=lk(e),a=[t[0]/n[0],t[1]/n[1]];return isNaN(a[0])&&(a[0]=1),isNaN(a[1])&&(a[1]=1),a}function lk(r){return r?[r[0][1]-r[0][0],r[1][1]-r[1][0]]:[NaN,NaN]}var yx=Qae,mx=C,Xae=iW("toolbox-dataZoom_"),Jae=function(r){U(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.render=function(t,n,a,i){this._brushController||(this._brushController=new SM(a.getZr()),this._brushController.on("brush",fe(this._onBrush,this)).mount()),tie(t,n,this,i,a),eie(t,n)},e.prototype.onclick=function(t,n,a){Kae[a].call(this)},e.prototype.remove=function(t,n){this._brushController&&this._brushController.unmount()},e.prototype.dispose=function(t,n){this._brushController&&this._brushController.dispose()},e.prototype._onBrush=function(t){var n=t.areas;if(!t.isEnd||!n.length)return;var a={},i=this.ecModel;this._brushController.updateCovers([]);var o=new yx(_x(this.model),i,{include:["grid"]});o.matchOutputRanges(n,i,function(u,c,f){if(f.type==="cartesian2d"){var h=u.brushType;h==="rect"?(s("x",f,c[0]),s("y",f,c[1])):s({lineX:"x",lineY:"y"}[h],f,c)}}),Vae(i,a),this._dispatchZoomAction(a);function s(u,c,f){var h=c.getAxis(u),v=h.model,d=l(u,v,i),p=d.findRepresentativeAxisProxy(v).getMinMaxSpan();(p.minValueSpan!=null||p.maxValueSpan!=null)&&(f=qs(0,f.slice(),h.scale.getExtent(),0,p.minValueSpan,p.maxValueSpan)),d&&(a[d.id]={dataZoomId:d.id,startValue:f[0],endValue:f[1]})}function l(u,c,f){var h;return f.eachComponent({mainType:"dataZoom",subType:"select"},function(v){var d=v.getAxisModel(u,c.componentIndex);d&&(h=v)}),h}},e.prototype._dispatchZoomAction=function(t){var n=[];mx(t,function(a,i){n.push(Me(a))}),n.length&&this.api.dispatchAction({type:"dataZoom",from:this.uid,batch:n})},e.getDefaultOption=function(t){var n={show:!0,filterMode:"filter",icon:{zoom:"M0,13.5h26.9 M13.5,26.9V0 M32.1,13.5H58V58H13.5 V32.1",back:"M22,1.4L9.9,13.5l12.3,12.3 M10.3,13.5H54.9v44.6 H10.3v-26"},title:t.getLocaleModel().get(["toolbox","dataZoom","title"]),brushStyle:{borderWidth:0,color:"rgba(210,219,238,0.2)"}};return n},e}(Kn),Kae={zoom:function(){var r=!this._isZoomActive;this.api.dispatchAction({type:"takeGlobalCursor",key:"dataZoomSelect",dataZoomSelectActive:r})},back:function(){this._dispatchZoomAction(Hae(this.ecModel))}};function _x(r){var e={xAxisIndex:r.get("xAxisIndex",!0),yAxisIndex:r.get("yAxisIndex",!0),xAxisId:r.get("xAxisId",!0),yAxisId:r.get("yAxisId",!0)};return e.xAxisIndex==null&&e.xAxisId==null&&(e.xAxisIndex="all"),e.yAxisIndex==null&&e.yAxisId==null&&(e.yAxisIndex="all"),e}function eie(r,e){r.setIconStatus("back",Gae(e)>1?"emphasis":"normal")}function tie(r,e,t,n,a){var i=t._isZoomActive;n&&n.type==="takeGlobalCursor"&&(i=n.key==="dataZoomSelect"?n.dataZoomSelectActive:!1),t._isZoomActive=i,r.setIconStatus("zoom",i?"emphasis":"normal");var o=new yx(_x(r),e,{include:["grid"]}),s=o.makePanelOpts(a,function(l){return l.xAxisDeclared&&!l.yAxisDeclared?"lineX":!l.xAxisDeclared&&l.yAxisDeclared?"lineY":"rect"});t._brushController.setPanels(s).enableBrush(i&&s.length?{brushType:"auto",brushStyle:r.getModel("brushStyle").getItemStyle()}:!1)}R$("dataZoom",function(r){var e=r.getComponent("toolbox",0),t=["feature","dataZoom"];if(!e||e.get(t)==null)return;var n=e.getModel(t),a=[],i=_x(n),o=Wc(r,i);mx(o.xAxisModels,function(l){return s(l,"xAxis","xAxisIndex")}),mx(o.yAxisModels,function(l){return s(l,"yAxis","yAxisIndex")});function s(l,u,c){var f=l.componentIndex,h={type:"select",$fromToolbox:!0,filterMode:n.get("filterMode",!0)||"filter",id:Xae+u+f};h[c]=f,a.push(h)}return a});var rie=Jae;function nie(r){r.registerComponentModel(bae),r.registerComponentView(Dae),ku("saveAsImage",Iae),ku("magicType",Cae),ku("dataView",Fae),ku("dataZoom",rie),ku("restore",Uae),Re(mae)}var aie=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="tooltip",e.dependencies=["axisPointer"],e.defaultOption={z:60,show:!0,showContent:!0,trigger:"item",triggerOn:"mousemove|click",alwaysShowContent:!1,displayMode:"single",renderMode:"auto",confine:null,showDelay:0,hideDelay:100,transitionDuration:.4,enterable:!1,backgroundColor:"#fff",shadowBlur:10,shadowColor:"rgba(0, 0, 0, .2)",shadowOffsetX:1,shadowOffsetY:2,borderRadius:4,borderWidth:1,padding:null,extraCssText:"",axisPointer:{type:"line",axis:"auto",animation:"auto",animationDurationUpdate:200,animationEasingUpdate:"exponentialOut",crossStyle:{color:"#999",width:1,type:"dashed",textStyle:{}}},textStyle:{color:"#666",fontSize:14}},e}(He),iie=aie;function uk(r){var e=r.get("confine");return e!=null?!!e:r.get("renderMode")==="richText"}function ck(r){if(!!$e.domSupported){for(var e=document.documentElement.style,t=0,n=r.length;t<n;t++)if(r[t]in e)return r[t]}}var fk=ck(["transform","webkitTransform","OTransform","MozTransform","msTransform"]),oie=ck(["webkitTransition","transition","OTransition","MozTransition","msTransition"]);function hk(r,e){if(!r)return e;e=C1(e,!0);var t=r.indexOf(e);return r=t===-1?e:"-"+r.slice(0,t)+"-"+e,r.toLowerCase()}function sie(r,e){var t=r.currentStyle||document.defaultView&&document.defaultView.getComputedStyle(r);return t?e?t[e]:t:null}var lie=hk(oie,"transition"),bx=hk(fk,"transform"),uie="position:absolute;display:block;border-style:solid;white-space:nowrap;z-index:9999999;"+($e.transform3dSupported?"will-change:transform;":"");function cie(r){return r=r==="left"?"right":r==="right"?"left":r==="top"?"bottom":"top",r}function fie(r,e,t){if(!ce(t)||t==="inside")return"";var n=r.get("backgroundColor"),a=r.get("borderWidth");e=ws(e);var i=cie(t),o=Math.max(Math.round(a)*1.5,6),s="",l=bx+":",u;ze(["left","right"],i)>-1?(s+="top:50%",l+="translateY(-50%) rotate("+(u=i==="left"?-225:-45)+"deg)"):(s+="left:50%",l+="translateX(-50%) rotate("+(u=i==="top"?225:45)+"deg)");var c=u*Math.PI/180,f=o+a,h=f*Math.abs(Math.cos(c))+f*Math.abs(Math.sin(c)),v=Math.round(((h-Math.SQRT2*a)/2+Math.SQRT2*a-(h-f)/2)*100)/100;s+=";"+i+":-"+v+"px";var d=e+" solid "+a+"px;",p=["position:absolute;width:"+o+"px;height:"+o+"px;z-index:-1;",s+";"+l+";","border-bottom:"+d,"border-right:"+d,"background-color:"+n+";"];return'<div style="'+p.join("")+'"></div>'}function hie(r,e){var t="cubic-bezier(0.23,1,0.32,1)",n=" "+r/2+"s "+t,a="opacity"+n+",visibility"+n;return e||(n=" "+r+"s "+t,a+=$e.transformSupported?","+bx+n:",left"+n+",top"+n),lie+":"+a}function vk(r,e,t){var n=r.toFixed(0)+"px",a=e.toFixed(0)+"px";if(!$e.transformSupported)return t?"top:"+a+";left:"+n+";":[["top",a],["left",n]];var i=$e.transform3dSupported,o="translate"+(i?"3d":"")+"("+n+","+a+(i?",0":"")+")";return t?"top:0;left:0;"+bx+":"+o+";":[["top",0],["left",0],[fk,o]]}function vie(r){var e=[],t=r.get("fontSize"),n=r.getTextColor();n&&e.push("color:"+n),e.push("font:"+r.getFont()),t&&e.push("line-height:"+Math.round(t*3/2)+"px");var a=r.get("textShadowColor"),i=r.get("textShadowBlur")||0,o=r.get("textShadowOffsetX")||0,s=r.get("textShadowOffsetY")||0;return a&&i&&e.push("text-shadow:"+o+"px "+s+"px "+i+"px "+a),C(["decoration","align"],function(l){var u=r.get(l);u&&e.push("text-"+l+":"+u)}),e.join(";")}function die(r,e,t){var n=[],a=r.get("transitionDuration"),i=r.get("backgroundColor"),o=r.get("shadowBlur"),s=r.get("shadowColor"),l=r.get("shadowOffsetX"),u=r.get("shadowOffsetY"),c=r.getModel("textStyle"),f=pN(r,"html"),h=l+"px "+u+"px "+o+"px "+s;return n.push("box-shadow:"+h),e&&a&&n.push(hie(a,t)),i&&n.push("background-color:"+i),C(["width","color","radius"],function(v){var d="border-"+v,p=C1(d),g=r.get(p);g!=null&&n.push(d+":"+g+(v==="color"?"":"px"))}),n.push(vie(c)),f!=null&&n.push("padding:"+xs(f).join("px ")+"px"),n.join(";")+";"}function dk(r,e,t,n,a){var i=e&&e.painter;if(t){var o=i&&i.getViewportRoot();o&&bV(r,o,document.body,n,a)}else{r[0]=n,r[1]=a;var s=i&&i.getViewportRootOffset();s&&(r[0]+=s.offsetLeft,r[1]+=s.offsetTop)}r[2]=r[0]/e.getWidth(),r[3]=r[1]/e.getHeight()}var pie=function(){function r(e,t,n){if(this._show=!1,this._styleCoord=[0,0,0,0],this._enterable=!0,this._firstShow=!0,this._longHide=!0,$e.wxa)return null;var a=document.createElement("div");a.domBelongToZr=!0,this.el=a;var i=this._zr=t.getZr(),o=this._appendToBody=n&&n.appendToBody;dk(this._styleCoord,i,o,t.getWidth()/2,t.getHeight()/2),o?document.body.appendChild(a):e.appendChild(a),this._container=e;var s=this;a.onmouseenter=function(){s._enterable&&(clearTimeout(s._hideTimeout),s._show=!0),s._inContent=!0},a.onmousemove=function(l){if(l=l||window.event,!s._enterable){var u=i.handler,c=i.painter.getViewportRoot();kn(c,l,!0),u.dispatch("mousemove",l)}},a.onmouseleave=function(){s._inContent=!1,s._enterable&&s._show&&s.hideLater(s._hideDelay)}}return r.prototype.update=function(e){var t=this._container,n=sie(t,"position"),a=t.style;a.position!=="absolute"&&n!=="absolute"&&(a.position="relative");var i=e.get("alwaysShowContent");i&&this._moveIfResized(),this.el.className=e.get("className")||""},r.prototype.show=function(e,t){clearTimeout(this._hideTimeout),clearTimeout(this._longHideTimeout);var n=this.el,a=n.style,i=this._styleCoord;n.innerHTML?a.cssText=uie+die(e,!this._firstShow,this._longHide)+vk(i[0],i[1],!0)+("border-color:"+ws(t)+";")+(e.get("extraCssText")||"")+(";pointer-events:"+(this._enterable?"auto":"none")):a.display="none",this._show=!0,this._firstShow=!1,this._longHide=!1},r.prototype.setContent=function(e,t,n,a,i){var o=this.el;if(e==null){o.innerHTML="";return}var s="";if(ce(i)&&n.get("trigger")==="item"&&!uk(n)&&(s=fie(n,a,i)),ce(e))o.innerHTML=e+s;else if(e){o.innerHTML="",J(e)||(e=[e]);for(var l=0;l<e.length;l++)Ll(e[l])&&e[l].parentNode!==o&&o.appendChild(e[l]);if(s&&o.childNodes.length){var u=document.createElement("div");u.innerHTML=s,o.appendChild(u)}}},r.prototype.setEnterable=function(e){this._enterable=e},r.prototype.getSize=function(){var e=this.el;return[e.offsetWidth,e.offsetHeight]},r.prototype.moveTo=function(e,t){var n=this._styleCoord;if(dk(n,this._zr,this._appendToBody,e,t),n[0]!=null&&n[1]!=null){var a=this.el.style,i=vk(n[0],n[1]);C(i,function(o){a[o[0]]=o[1]})}},r.prototype._moveIfResized=function(){var e=this._styleCoord[2],t=this._styleCoord[3];this.moveTo(e*this._zr.getWidth(),t*this._zr.getHeight())},r.prototype.hide=function(){var e=this,t=this.el.style;t.visibility="hidden",t.opacity="0",$e.transform3dSupported&&(t.willChange=""),this._show=!1,this._longHideTimeout=setTimeout(function(){return e._longHide=!0},500)},r.prototype.hideLater=function(e){this._show&&!(this._inContent&&this._enterable)&&(e?(this._hideDelay=e,this._show=!1,this._hideTimeout=setTimeout(fe(this.hide,this),e)):this.hide())},r.prototype.isShow=function(){return this._show},r.prototype.dispose=function(){this.el.parentNode.removeChild(this.el)},r}(),gie=pie,yie=function(){function r(e){this._show=!1,this._styleCoord=[0,0,0,0],this._enterable=!0,this._zr=e.getZr(),gk(this._styleCoord,this._zr,e.getWidth()/2,e.getHeight()/2)}return r.prototype.update=function(e){var t=e.get("alwaysShowContent");t&&this._moveIfResized()},r.prototype.show=function(){this._hideTimeout&&clearTimeout(this._hideTimeout),this.el.show(),this._show=!0},r.prototype.setContent=function(e,t,n,a,i){var o=this;_e(e)&&at(""),this.el&&this._zr.remove(this.el);var s=n.getModel("textStyle");this.el=new Ge({style:{rich:t.richTextStyles,text:e,lineHeight:22,borderWidth:1,borderColor:a,textShadowColor:s.get("textShadowColor"),fill:n.get(["textStyle","color"]),padding:pN(n,"richText"),verticalAlign:"top",align:"left"},z:n.get("z")}),C(["backgroundColor","borderRadius","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"],function(u){o.el.style[u]=n.get(u)}),C(["textShadowBlur","textShadowOffsetX","textShadowOffsetY"],function(u){o.el.style[u]=s.get(u)||0}),this._zr.add(this.el);var l=this;this.el.on("mouseover",function(){l._enterable&&(clearTimeout(l._hideTimeout),l._show=!0),l._inContent=!0}),this.el.on("mouseout",function(){l._enterable&&l._show&&l.hideLater(l._hideDelay),l._inContent=!1})},r.prototype.setEnterable=function(e){this._enterable=e},r.prototype.getSize=function(){var e=this.el,t=this.el.getBoundingRect(),n=pk(e.style);return[t.width+n.left+n.right,t.height+n.top+n.bottom]},r.prototype.moveTo=function(e,t){var n=this.el;if(n){var a=this._styleCoord;gk(a,this._zr,e,t),e=a[0],t=a[1];var i=n.style,o=Co(i.borderWidth||0),s=pk(i);n.x=e+o+s.left,n.y=t+o+s.top,n.markRedraw()}},r.prototype._moveIfResized=function(){var e=this._styleCoord[2],t=this._styleCoord[3];this.moveTo(e*this._zr.getWidth(),t*this._zr.getHeight())},r.prototype.hide=function(){this.el&&this.el.hide(),this._show=!1},r.prototype.hideLater=function(e){this._show&&!(this._inContent&&this._enterable)&&(e?(this._hideDelay=e,this._show=!1,this._hideTimeout=setTimeout(fe(this.hide,this),e)):this.hide())},r.prototype.isShow=function(){return this._show},r.prototype.dispose=function(){this._zr.remove(this.el)},r}();function Co(r){return Math.max(0,r)}function pk(r){var e=Co(r.shadowBlur||0),t=Co(r.shadowOffsetX||0),n=Co(r.shadowOffsetY||0);return{left:Co(e-t),right:Co(e+t),top:Co(e-n),bottom:Co(e+n)}}function gk(r,e,t,n){r[0]=t,r[1]=n,r[2]=r[0]/e.getWidth(),r[3]=r[1]/e.getHeight()}var mie=yie,_ie=new We({shape:{x:-1,y:-1,width:2,height:2}}),bie=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,n){if(!($e.node||!n.getDom())){var a=t.getComponent("tooltip"),i=this._renderMode=hW(a.get("renderMode"));this._tooltipContent=i==="richText"?new mie(n):new gie(n.getDom(),n,{appendToBody:a.get("appendToBody",!0)})}},e.prototype.render=function(t,n,a){if(!($e.node||!a.getDom())){this.group.removeAll(),this._tooltipModel=t,this._ecModel=n,this._api=a,this._alwaysShowContent=t.get("alwaysShowContent");var i=this._tooltipContent;i.update(t),i.setEnterable(t.get("enterable")),this._initGlobalListener(),this._keepShow(),this._renderMode!=="richText"&&t.get("transitionDuration")?vu(this,"_updatePosition",50,"fixRate"):xf(this,"_updatePosition")}},e.prototype._initGlobalListener=function(){var t=this._tooltipModel,n=t.get("triggerOn");Mz("itemTooltip",this._api,fe(function(a,i,o){n!=="none"&&(n.indexOf(a)>=0?this._tryShow(i,o):a==="leave"&&this._hide(o))},this))},e.prototype._keepShow=function(){var t=this._tooltipModel,n=this._ecModel,a=this._api,i=t.get("triggerOn");if(this._lastX!=null&&this._lastY!=null&&i!=="none"&&i!=="click"){var o=this;clearTimeout(this._refreshUpdateTimeout),this._refreshUpdateTimeout=setTimeout(function(){!a.isDisposed()&&o.manuallyShowTip(t,n,a,{x:o._lastX,y:o._lastY,dataByCoordSys:o._lastDataByCoordSys})})}},e.prototype.manuallyShowTip=function(t,n,a,i){if(!(i.from===this.uid||$e.node||!a.getDom())){var o=yk(i,a);this._ticket="";var s=i.dataByCoordSys,l=Die(i,n,a);if(l){var u=l.el.getBoundingRect().clone();u.applyTransform(l.el.transform),this._tryShow({offsetX:u.x+u.width/2,offsetY:u.y+u.height/2,target:l.el,position:i.position,positionDefault:"bottom"},o)}else if(i.tooltip&&i.x!=null&&i.y!=null){var c=_ie;c.x=i.x,c.y=i.y,c.update(),Te(c).tooltipConfig={name:null,option:i.tooltip},this._tryShow({offsetX:i.x,offsetY:i.y,target:c},o)}else if(s)this._tryShow({offsetX:i.x,offsetY:i.y,position:i.position,dataByCoordSys:s,tooltipOption:i.tooltipOption},o);else if(i.seriesIndex!=null){if(this._manuallyAxisShowTip(t,n,a,i))return;var f=wz(i,n),h=f.point[0],v=f.point[1];h!=null&&v!=null&&this._tryShow({offsetX:h,offsetY:v,target:f.el,position:i.position,positionDefault:"bottom"},o)}else i.x!=null&&i.y!=null&&(a.dispatchAction({type:"updateAxisPointer",x:i.x,y:i.y}),this._tryShow({offsetX:i.x,offsetY:i.y,position:i.position,target:a.getZr().findHover(i.x,i.y).target},o))}},e.prototype.manuallyHideTip=function(t,n,a,i){var o=this._tooltipContent;!this._alwaysShowContent&&this._tooltipModel&&o.hideLater(this._tooltipModel.get("hideDelay")),this._lastX=this._lastY=this._lastDataByCoordSys=null,i.from!==this.uid&&this._hide(yk(i,a))},e.prototype._manuallyAxisShowTip=function(t,n,a,i){var o=i.seriesIndex,s=i.dataIndex,l=n.getComponent("axisPointer").coordSysAxesInfo;if(!(o==null||s==null||l==null)){var u=n.getSeriesByIndex(o);if(!!u){var c=u.getData(),f=ph([c.getItemModel(s),u,(u.coordinateSystem||{}).model],this._tooltipModel);if(f.get("trigger")==="axis")return a.dispatchAction({type:"updateAxisPointer",seriesIndex:o,dataIndex:s,position:i.position}),!0}}},e.prototype._tryShow=function(t,n){var a=t.target,i=this._tooltipModel;if(!!i){this._lastX=t.offsetX,this._lastY=t.offsetY;var o=t.dataByCoordSys;if(o&&o.length)this._showAxisTooltip(o,t);else if(a){this._lastDataByCoordSys=null;var s,l;Cs(a,function(u){if(Te(u).dataIndex!=null)return s=u,!0;if(Te(u).tooltipConfig!=null)return l=u,!0},!0),s?this._showSeriesItemTooltip(t,s,n):l?this._showComponentItemTooltip(t,l,n):this._hide(n)}else this._lastDataByCoordSys=null,this._hide(n)}},e.prototype._showOrMove=function(t,n){var a=t.get("showDelay");n=fe(n,this),clearTimeout(this._showTimout),a>0?this._showTimout=setTimeout(n,a):n()},e.prototype._showAxisTooltip=function(t,n){var a=this._ecModel,i=this._tooltipModel,o=[n.offsetX,n.offsetY],s=ph([n.tooltipOption],i),l=this._renderMode,u=[],c=lr("section",{blocks:[],noHeader:!0}),f=[],h=new K1;C(t,function(m){C(m.dataByAxis,function(_){var b=a.getComponent(_.axisDim+"Axis",_.axisIndex),x=_.value;if(!(!b||x==null)){var M=pz(x,b.axis,a,_.seriesDataIndices,_.valueLabelOpt),w=lr("section",{header:M,noHeader:!Pn(M),sortBlocks:!0,blocks:[]});c.blocks.push(w),C(_.seriesDataIndices,function(D){var T=a.getSeriesByIndex(D.seriesIndex),I=D.dataIndexInside,A=T.getDataParams(I);if(!(A.dataIndex<0)){A.axisDim=_.axisDim,A.axisIndex=_.axisIndex,A.axisType=_.axisType,A.axisId=_.axisId,A.axisValue=V_(b.axis,{value:x}),A.axisValueLabel=M,A.marker=h.makeTooltipMarker("item",ws(A.color),l);var N=ZC(T.formatTooltip(I,!0,null)),L=N.frag;if(L){var E=ph([T],i).get("valueFormatter");w.blocks.push(E?X({valueFormatter:E},L):L)}N.text&&f.push(N.text),u.push(A)}})}})}),c.blocks.reverse(),f.reverse();var v=n.position,d=s.get("order"),p=hN(c,h,l,d,a.get("useUTC"),s.get("textStyle"));p&&f.unshift(p);var g=l==="richText"?`
|
|
258
|
+
|
|
259
|
+
`:"<br/>",y=f.join(g);this._showOrMove(s,function(){this._updateContentNotChangedOnAxis(t,u)?this._updatePosition(s,v,o[0],o[1],this._tooltipContent,u):this._showTooltipContent(s,y,u,Math.random()+"",o[0],o[1],v,null,h)})},e.prototype._showSeriesItemTooltip=function(t,n,a){var i=this._ecModel,o=Te(n),s=o.seriesIndex,l=i.getSeriesByIndex(s),u=o.dataModel||l,c=o.dataIndex,f=o.dataType,h=u.getData(f),v=this._renderMode,d=t.positionDefault,p=ph([h.getItemModel(c),u,l&&(l.coordinateSystem||{}).model],this._tooltipModel,d?{position:d}:null),g=p.get("trigger");if(!(g!=null&&g!=="item")){var y=u.getDataParams(c,f),m=new K1;y.marker=m.makeTooltipMarker("item",ws(y.color),v);var _=ZC(u.formatTooltip(c,!1,f)),b=p.get("order"),x=p.get("valueFormatter"),M=_.frag,w=M?hN(x?X({valueFormatter:x},M):M,m,v,b,i.get("useUTC"),p.get("textStyle")):_.text,D="item_"+u.name+"_"+c;this._showOrMove(p,function(){this._showTooltipContent(p,w,y,D,t.offsetX,t.offsetY,t.position,t.target,m)}),a({type:"showTip",dataIndexInside:c,dataIndex:h.getRawIndex(c),seriesIndex:s,from:this.uid})}},e.prototype._showComponentItemTooltip=function(t,n,a){var i=Te(n),o=i.tooltipConfig,s=o.option||{};if(ce(s)){var l=s;s={content:l,formatter:l}}var u=[s],c=this._ecModel.getComponent(i.componentMainType,i.componentIndex);c&&u.push(c),u.push({formatter:s.content});var f=t.positionDefault,h=ph(u,this._tooltipModel,f?{position:f}:null),v=h.get("content"),d=Math.random()+"",p=new K1;this._showOrMove(h,function(){var g=Me(h.get("formatterParams")||{});this._showTooltipContent(h,v,g,d,t.offsetX,t.offsetY,t.position,n,p)}),a({type:"showTip",from:this.uid})},e.prototype._showTooltipContent=function(t,n,a,i,o,s,l,u,c){if(this._ticket="",!(!t.get("showContent")||!t.get("show"))){var f=this._tooltipContent;f.setEnterable(t.get("enterable"));var h=t.get("formatter");l=l||t.get("position");var v=n,d=this._getNearestPoint([o,s],a,t.get("trigger"),t.get("borderColor")),p=d.color;if(h)if(ce(h)){var g=t.ecModel.get("useUTC"),y=J(a)?a[0]:a,m=y&&y.axisType&&y.axisType.indexOf("time")>=0;v=h,m&&(v=vf(y.axisValue,v,g)),v=E1(v,a,!0)}else if(ye(h)){var _=fe(function(b,x){b===this._ticket&&(f.setContent(x,c,t,p,l),this._updatePosition(t,l,o,s,f,a,u))},this);this._ticket=i,v=h(a,i,_)}else v=h;f.setContent(v,c,t,p,l),f.show(t,p),this._updatePosition(t,l,o,s,f,a,u)}},e.prototype._getNearestPoint=function(t,n,a,i){if(a==="axis"||J(n))return{color:i||(this._renderMode==="html"?"#fff":"none")};if(!J(n))return{color:i||n.color||n.borderColor}},e.prototype._updatePosition=function(t,n,a,i,o,s,l){var u=this._api.getWidth(),c=this._api.getHeight();n=n||t.get("position");var f=o.getSize(),h=t.get("align"),v=t.get("verticalAlign"),d=l&&l.getBoundingRect().clone();if(l&&d.applyTransform(l.transform),ye(n)&&(n=n([a,i],s,o.el,d,{viewSize:[u,c],contentSize:f.slice()})),J(n))a=ue(n[0],u),i=ue(n[1],c);else if(_e(n)){var p=n;p.width=f[0],p.height=f[1];var g=Yt(p,{width:u,height:c});a=g.x,i=g.y,h=null,v=null}else if(ce(n)&&l){var y=wie(n,d,f,t.get("borderWidth"));a=y[0],i=y[1]}else{var y=Mie(a,i,o,u,c,h?null:20,v?null:20);a=y[0],i=y[1]}if(h&&(a-=mk(h)?f[0]/2:h==="right"?f[0]:0),v&&(i-=mk(v)?f[1]/2:v==="bottom"?f[1]:0),uk(t)){var y=xie(a,i,o,u,c);a=y[0],i=y[1]}o.moveTo(a,i)},e.prototype._updateContentNotChangedOnAxis=function(t,n){var a=this._lastDataByCoordSys,i=this._cbParamsList,o=!!a&&a.length===t.length;return o&&C(a,function(s,l){var u=s.dataByAxis||[],c=t[l]||{},f=c.dataByAxis||[];o=o&&u.length===f.length,o&&C(u,function(h,v){var d=f[v]||{},p=h.seriesDataIndices||[],g=d.seriesDataIndices||[];o=o&&h.value===d.value&&h.axisType===d.axisType&&h.axisId===d.axisId&&p.length===g.length,o&&C(p,function(y,m){var _=g[m];o=o&&y.seriesIndex===_.seriesIndex&&y.dataIndex===_.dataIndex}),i&&C(h.seriesDataIndices,function(y){var m=y.seriesIndex,_=n[m],b=i[m];_&&b&&b.data!==_.data&&(o=!1)})})}),this._lastDataByCoordSys=t,this._cbParamsList=n,!!o},e.prototype._hide=function(t){this._lastDataByCoordSys=null,t({type:"hideTip",from:this.uid})},e.prototype.dispose=function(t,n){$e.node||!n.getDom()||(xf(this,"_updatePosition"),this._tooltipContent.dispose(),tx("itemTooltip",n))},e.type="tooltip",e}(St);function ph(r,e,t){var n=e.ecModel,a;t?(a=new ft(t,n,n),a=new ft(e.option,a,n)):a=e;for(var i=r.length-1;i>=0;i--){var o=r[i];o&&(o instanceof ft&&(o=o.get("tooltip",!0)),ce(o)&&(o={formatter:o}),o&&(a=new ft(o,a,n)))}return a}function yk(r,e){return r.dispatchAction||fe(e.dispatchAction,e)}function Mie(r,e,t,n,a,i,o){var s=t.getSize(),l=s[0],u=s[1];return i!=null&&(r+l+i+2>n?r-=l+i:r+=i),o!=null&&(e+u+o>a?e-=u+o:e+=o),[r,e]}function xie(r,e,t,n,a){var i=t.getSize(),o=i[0],s=i[1];return r=Math.min(r+o,n)-o,e=Math.min(e+s,a)-s,r=Math.max(r,0),e=Math.max(e,0),[r,e]}function wie(r,e,t,n){var a=t[0],i=t[1],o=Math.ceil(Math.SQRT2*n)+8,s=0,l=0,u=e.width,c=e.height;switch(r){case"inside":s=e.x+u/2-a/2,l=e.y+c/2-i/2;break;case"top":s=e.x+u/2-a/2,l=e.y-i-o;break;case"bottom":s=e.x+u/2-a/2,l=e.y+c+o;break;case"left":s=e.x-a-o,l=e.y+c/2-i/2;break;case"right":s=e.x+u+o,l=e.y+c/2-i/2}return[s,l]}function mk(r){return r==="center"||r==="middle"}function Die(r,e,t){var n=N0(r).queryOptionMap,a=n.keys()[0];if(!(!a||a==="series")){var i=Gc(e,a,n.get(a),{useDefault:!1,enableAll:!1,enableNone:!1}),o=i.models[0];if(!!o){var s=t.getViewOfComponentModel(o),l;if(s.group.traverse(function(u){var c=Te(u).tooltipConfig;if(c&&c.name===r.name)return l=u,!0}),l)return{componentMainType:a,componentIndex:o.componentIndex,el:l}}}}var Sie=bie;function Iie(r){Re(vh),r.registerComponentModel(iie),r.registerComponentView(Sie),r.registerAction({type:"showTip",event:"showTip",update:"tooltip:manuallyShowTip"},Ot),r.registerAction({type:"hideTip",event:"hideTip",update:"tooltip:manuallyHideTip"},Ot)}var Tie=["rect","polygon","keep","clear"];function Aie(r,e){var t=ct(r?r.brush:[]);if(!!t.length){var n=[];C(t,function(l){var u=l.hasOwnProperty("toolbox")?l.toolbox:[];u instanceof Array&&(n=n.concat(u))});var a=r&&r.toolbox;J(a)&&(a=a[0]),a||(a={feature:{}},r.toolbox=[a]);var i=a.feature||(a.feature={}),o=i.brush||(i.brush={}),s=o.type||(o.type=[]);s.push.apply(s,n),Cie(s),e&&!s.length&&s.push.apply(s,Tie)}}function Cie(r){var e={};C(r,function(t){e[t]=1}),r.length=0,C(e,function(t,n){r.push(n)})}var _k=C;function bk(r){if(r){for(var e in r)if(r.hasOwnProperty(e))return!0}}function Mx(r,e,t){var n={};return _k(e,function(i){var o=n[i]=a();_k(r[i],function(s,l){if(!!Sr.isValidType(l)){var u={type:l,visual:s};t&&t(u,i),o[l]=new Sr(u),l==="opacity"&&(u=Me(u),u.type="colorAlpha",o.__hidden.__alphaForOpacity=new Sr(u))}})}),n;function a(){var i=function(){};i.prototype.__hidden=i.prototype;var o=new i;return o}}function Mk(r,e,t){var n;C(t,function(a){e.hasOwnProperty(a)&&bk(e[a])&&(n=!0)}),n&&C(t,function(a){e.hasOwnProperty(a)&&bk(e[a])?r[a]=Me(e[a]):delete r[a]})}function Nie(r,e,t,n,a,i){var o={};C(r,function(f){var h=Sr.prepareVisualTypes(e[f]);o[f]=h});var s;function l(f){return a_(t,s,f)}function u(f,h){RN(t,s,f,h)}i==null?t.each(c):t.each([i],c);function c(f,h){s=i==null?f:h;var v=t.getRawDataItem(s);if(!(v&&v.visualMap===!1))for(var d=n.call(a,f),p=e[d],g=o[d],y=0,m=g.length;y<m;y++){var _=g[y];p[_]&&p[_].applyVisual(f,l,u)}}}function Lie(r,e,t,n){var a={};return C(r,function(i){var o=Sr.prepareVisualTypes(e[i]);a[i]=o}),{progress:function(o,s){var l;n!=null&&(l=s.getDimensionIndex(n));function u(x){return a_(s,f,x)}function c(x,M){RN(s,f,x,M)}for(var f,h=s.getStore();(f=o.next())!=null;){var v=s.getRawDataItem(f);if(!(v&&v.visualMap===!1))for(var d=n!=null?h.get(l,f):f,p=t(d),g=e[p],y=a[p],m=0,_=y.length;m<_;m++){var b=y[m];g[b]&&g[b].applyVisual(d,u,c)}}}}}function Eie(r){var e=r.brushType,t={point:function(n){return xk[e].point(n,t,r)},rect:function(n){return xk[e].rect(n,t,r)}};return t}var xk={lineX:wk(0),lineY:wk(1),rect:{point:function(r,e,t){return r&&t.boundingRect.contain(r[0],r[1])},rect:function(r,e,t){return r&&t.boundingRect.intersect(r)}},polygon:{point:function(r,e,t){return r&&t.boundingRect.contain(r[0],r[1])&&zs(t.range,r[0],r[1])},rect:function(r,e,t){var n=t.range;if(!r||n.length<=1)return!1;var a=r.x,i=r.y,o=r.width,s=r.height,l=n[0];if(zs(n,a,i)||zs(n,a+o,i)||zs(n,a,i+s)||zs(n,a+o,i+s)||Pe.create(r).contain(l[0],l[1])||lf(a,i,a+o,i,n)||lf(a,i,a,i+s,n)||lf(a+o,i,a+o,i+s,n)||lf(a,i+s,a+o,i+s,n))return!0}}};function wk(r){var e=["x","y"],t=["width","height"];return{point:function(n,a,i){if(n){var o=i.range,s=n[r];return gh(s,o)}},rect:function(n,a,i){if(n){var o=i.range,s=[n[e[r]],n[e[r]]+n[t[r]]];return s[1]<s[0]&&s.reverse(),gh(s[0],o)||gh(s[1],o)||gh(o[0],s)||gh(o[1],s)}}}}function gh(r,e){return e[0]<=r&&r<=e[1]}var Dk=["inBrush","outOfBrush"],xx="__ecBrushSelect",Dx="__ecInBrushSelectEvent";function Sk(r){r.eachComponent({mainType:"brush"},function(e){var t=e.brushTargetManager=new yx(e.option,r);t.setInputRanges(e.areas,r)})}function Oie(r,e,t){var n=[],a,i;r.eachComponent({mainType:"brush"},function(o){t&&t.type==="takeGlobalCursor"&&o.setBrushOption(t.key==="brush"?t.brushOption:{brushType:!1})}),Sk(r),r.eachComponent({mainType:"brush"},function(o,s){var l={brushId:o.id,brushIndex:s,brushName:o.name,areas:Me(o.areas),selected:[]};n.push(l);var u=o.option,c=u.brushLink,f=[],h=[],v=[],d=!1;s||(a=u.throttleType,i=u.throttleDelay);var p=K(o.areas,function(x){var M=Rie[x.brushType],w=me({boundingRect:M?M(x):void 0},x);return w.selectors=Eie(w),w}),g=Mx(o.option,Dk,function(x){x.mappingMethod="fixed"});J(c)&&C(c,function(x){f[x]=1});function y(x){return c==="all"||!!f[x]}function m(x){return!!x.length}r.eachSeries(function(x,M){var w=v[M]=[];x.subType==="parallel"?_(x,M):b(x,M,w)});function _(x,M){var w=x.coordinateSystem;d=d||w.hasAxisBrushed(),y(M)&&w.eachActiveState(x.getData(),function(D,T){D==="active"&&(h[T]=1)})}function b(x,M,w){if(!(!x.brushSelector||kie(o,M))&&(C(p,function(T){o.brushTargetManager.controlSeries(T,x,r)&&w.push(T),d=d||m(w)}),y(M)&&m(w))){var D=x.getData();D.each(function(T){Ik(x,w,D,T)&&(h[T]=1)})}}r.eachSeries(function(x,M){var w={seriesId:x.id,seriesIndex:M,seriesName:x.name,dataIndex:[]};l.selected.push(w);var D=v[M],T=x.getData(),I=y(M)?function(A){return h[A]?(w.dataIndex.push(T.getRawIndex(A)),"inBrush"):"outOfBrush"}:function(A){return Ik(x,D,T,A)?(w.dataIndex.push(T.getRawIndex(A)),"inBrush"):"outOfBrush"};(y(M)?d:m(D))&&Nie(Dk,g,T,I)})}),Pie(e,a,i,n,t)}function Pie(r,e,t,n,a){if(!!a){var i=r.getZr();if(!i[Dx]){i[xx]||(i[xx]=zie);var o=vu(i,xx,t,e);o(r,n)}}}function zie(r,e){if(!r.isDisposed()){var t=r.getZr();t[Dx]=!0,r.dispatchAction({type:"brushSelect",batch:e}),t[Dx]=!1}}function Ik(r,e,t,n){for(var a=0,i=e.length;a<i;a++){var o=e[a];if(r.brushSelector(n,t,o.selectors,o))return!0}}function kie(r,e){var t=r.option.seriesIndex;return t!=null&&t!=="all"&&(J(t)?ze(t,e)<0:e!==t)}var Rie={rect:function(r){return Tk(r.range)},polygon:function(r){for(var e,t=r.range,n=0,a=t.length;n<a;n++){e=e||[[1/0,-1/0],[1/0,-1/0]];var i=t[n];i[0]<e[0][0]&&(e[0][0]=i[0]),i[0]>e[0][1]&&(e[0][1]=i[0]),i[1]<e[1][0]&&(e[1][0]=i[1]),i[1]>e[1][1]&&(e[1][1]=i[1])}return e&&Tk(e)}};function Tk(r){return new Pe(r[0][0],r[1][0],r[0][1]-r[0][0],r[1][1]-r[1][0])}var jie=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,n){this.ecModel=t,this.api=n,this.model,(this._brushController=new SM(n.getZr())).on("brush",fe(this._onBrush,this)).mount()},e.prototype.render=function(t,n,a,i){this.model=t,this._updateController(t,n,a,i)},e.prototype.updateTransform=function(t,n,a,i){Sk(n),this._updateController(t,n,a,i)},e.prototype.updateVisual=function(t,n,a,i){this.updateTransform(t,n,a,i)},e.prototype.updateView=function(t,n,a,i){this._updateController(t,n,a,i)},e.prototype._updateController=function(t,n,a,i){(!i||i.$from!==t.id)&&this._brushController.setPanels(t.brushTargetManager.makePanelOpts(a)).enableBrush(t.brushOption).updateCovers(t.areas.slice())},e.prototype.dispose=function(){this._brushController.dispose()},e.prototype._onBrush=function(t){var n=this.model.id,a=this.model.brushTargetManager.setOutputRanges(t.areas,this.ecModel);(!t.isEnd||t.removeOnClick)&&this.api.dispatchAction({type:"brush",brushId:n,areas:Me(a),$from:n}),t.isEnd&&this.api.dispatchAction({type:"brushEnd",brushId:n,areas:Me(a),$from:n})},e.type="brush",e}(St),Bie=jie,Fie="#ddd",Vie=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.areas=[],t.brushOption={},t}return e.prototype.optionUpdated=function(t,n){var a=this.option;!n&&Mk(a,t,["inBrush","outOfBrush"]);var i=a.inBrush=a.inBrush||{};a.outOfBrush=a.outOfBrush||{color:Fie},i.hasOwnProperty("liftZ")||(i.liftZ=5)},e.prototype.setAreas=function(t){!t||(this.areas=K(t,function(n){return Ak(this.option,n)},this))},e.prototype.setBrushOption=function(t){this.brushOption=Ak(this.option,t),this.brushType=this.brushOption.brushType},e.type="brush",e.dependencies=["geo","grid","xAxis","yAxis","parallel","series"],e.defaultOption={seriesIndex:"all",brushType:"rect",brushMode:"single",transformable:!0,brushStyle:{borderWidth:1,color:"rgba(210,219,238,0.3)",borderColor:"#D2DBEE"},throttleType:"fixRate",throttleDelay:0,removeOnClick:!0,z:1e4},e}(He);function Ak(r,e){return Ne({brushType:r.brushType,brushMode:r.brushMode,transformable:r.transformable,brushStyle:new ft(r.brushStyle).getItemStyle(),removeOnClick:r.removeOnClick,z:r.z},e,!0)}var Hie=Vie,Wie=["rect","polygon","lineX","lineY","keep","clear"],Gie=function(r){U(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.render=function(t,n,a){var i,o,s;n.eachComponent({mainType:"brush"},function(l){i=l.brushType,o=l.brushOption.brushMode||"single",s=s||!!l.areas.length}),this._brushType=i,this._brushMode=o,C(t.get("type",!0),function(l){t.setIconStatus(l,(l==="keep"?o==="multiple":l==="clear"?s:l===i)?"emphasis":"normal")})},e.prototype.updateView=function(t,n,a){this.render(t,n,a)},e.prototype.getIcons=function(){var t=this.model,n=t.get("icon",!0),a={};return C(t.get("type",!0),function(i){n[i]&&(a[i]=n[i])}),a},e.prototype.onclick=function(t,n,a){var i=this._brushType,o=this._brushMode;a==="clear"?(n.dispatchAction({type:"axisAreaSelect",intervals:[]}),n.dispatchAction({type:"brush",command:"clear",areas:[]})):n.dispatchAction({type:"takeGlobalCursor",key:"brush",brushOption:{brushType:a==="keep"?i:i===a?!1:a,brushMode:a==="keep"?o==="multiple"?"single":"multiple":o}})},e.getDefaultOption=function(t){var n={show:!0,type:Wie.slice(),icon:{rect:"M7.3,34.7 M0.4,10V-0.2h9.8 M89.6,10V-0.2h-9.8 M0.4,60v10.2h9.8 M89.6,60v10.2h-9.8 M12.3,22.4V10.5h13.1 M33.6,10.5h7.8 M49.1,10.5h7.8 M77.5,22.4V10.5h-13 M12.3,31.1v8.2 M77.7,31.1v8.2 M12.3,47.6v11.9h13.1 M33.6,59.5h7.6 M49.1,59.5 h7.7 M77.5,47.6v11.9h-13",polygon:"M55.2,34.9c1.7,0,3.1,1.4,3.1,3.1s-1.4,3.1-3.1,3.1 s-3.1-1.4-3.1-3.1S53.5,34.9,55.2,34.9z M50.4,51c1.7,0,3.1,1.4,3.1,3.1c0,1.7-1.4,3.1-3.1,3.1c-1.7,0-3.1-1.4-3.1-3.1 C47.3,52.4,48.7,51,50.4,51z M55.6,37.1l1.5-7.8 M60.1,13.5l1.6-8.7l-7.8,4 M59,19l-1,5.3 M24,16.1l6.4,4.9l6.4-3.3 M48.5,11.6 l-5.9,3.1 M19.1,12.8L9.7,5.1l1.1,7.7 M13.4,29.8l1,7.3l6.6,1.6 M11.6,18.4l1,6.1 M32.8,41.9 M26.6,40.4 M27.3,40.2l6.1,1.6 M49.9,52.1l-5.6-7.6l-4.9-1.2",lineX:"M15.2,30 M19.7,15.6V1.9H29 M34.8,1.9H40.4 M55.3,15.6V1.9H45.9 M19.7,44.4V58.1H29 M34.8,58.1H40.4 M55.3,44.4 V58.1H45.9 M12.5,20.3l-9.4,9.6l9.6,9.8 M3.1,29.9h16.5 M62.5,20.3l9.4,9.6L62.3,39.7 M71.9,29.9H55.4",lineY:"M38.8,7.7 M52.7,12h13.2v9 M65.9,26.6V32 M52.7,46.3h13.2v-9 M24.9,12H11.8v9 M11.8,26.6V32 M24.9,46.3H11.8v-9 M48.2,5.1l-9.3-9l-9.4,9.2 M38.9-3.9V12 M48.2,53.3l-9.3,9l-9.4-9.2 M38.9,62.3V46.4",keep:"M4,10.5V1h10.3 M20.7,1h6.1 M33,1h6.1 M55.4,10.5V1H45.2 M4,17.3v6.6 M55.6,17.3v6.6 M4,30.5V40h10.3 M20.7,40 h6.1 M33,40h6.1 M55.4,30.5V40H45.2 M21,18.9h62.9v48.6H21V18.9z",clear:"M22,14.7l30.9,31 M52.9,14.7L22,45.7 M4.7,16.8V4.2h13.1 M26,4.2h7.8 M41.6,4.2h7.8 M70.3,16.8V4.2H57.2 M4.7,25.9v8.6 M70.3,25.9v8.6 M4.7,43.2v12.6h13.1 M26,55.8h7.8 M41.6,55.8h7.8 M70.3,43.2v12.6H57.2"},title:t.getLocaleModel().get(["toolbox","brush","title"])};return n},e}(Kn),$ie=Gie;function Uie(r){r.registerComponentView(Bie),r.registerComponentModel(Hie),r.registerPreprocessor(Aie),r.registerVisual(r.PRIORITY.VISUAL.BRUSH,Oie),r.registerAction({type:"brush",event:"brush",update:"updateVisual"},function(e,t){t.eachComponent({mainType:"brush",query:e},function(n){n.setAreas(e.areas)})}),r.registerAction({type:"brushSelect",event:"brushSelected",update:"none"},Ot),r.registerAction({type:"brushEnd",event:"brushEnd",update:"none"},Ot),ku("brush",$ie)}var Yie=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.layoutMode={type:"box",ignoreSize:!0},t}return e.type="title",e.defaultOption={z:6,show:!0,text:"",target:"blank",subtext:"",subtarget:"blank",left:0,top:0,backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderWidth:0,padding:5,itemGap:10,textStyle:{fontSize:18,fontWeight:"bold",color:"#464646"},subtextStyle:{fontSize:12,color:"#6E7079"}},e}(He),Qie=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a){if(this.group.removeAll(),!!t.get("show")){var i=this.group,o=t.getModel("textStyle"),s=t.getModel("subtextStyle"),l=t.get("textAlign"),u=Ee(t.get("textBaseline"),t.get("textVerticalAlign")),c=new Ge({style:yt(o,{text:t.get("text"),fill:o.getTextColor()},{disableBox:!0}),z2:10}),f=c.getBoundingRect(),h=t.get("subtext"),v=new Ge({style:yt(s,{text:h,fill:s.getTextColor(),y:f.height+t.get("itemGap"),verticalAlign:"top"},{disableBox:!0}),z2:10}),d=t.get("link"),p=t.get("sublink"),g=t.get("triggerEvent",!0);c.silent=!d&&!g,v.silent=!p&&!g,d&&c.on("click",function(){Bd(d,"_"+t.get("target"))}),p&&v.on("click",function(){Bd(p,"_"+t.get("subtarget"))}),Te(c).eventData=Te(v).eventData=g?{componentType:"title",componentIndex:t.componentIndex}:null,i.add(c),h&&i.add(v);var y=i.getBoundingRect(),m=t.getBoxLayoutParams();m.width=y.width,m.height=y.height;var _=Yt(m,{width:a.getWidth(),height:a.getHeight()},t.get("padding"));l||(l=t.get("left")||t.get("right"),l==="middle"&&(l="center"),l==="right"?_.x+=_.width:l==="center"&&(_.x+=_.width/2)),u||(u=t.get("top")||t.get("bottom"),u==="center"&&(u="middle"),u==="bottom"?_.y+=_.height:u==="middle"&&(_.y+=_.height/2),u=u||"top"),i.x=_.x,i.y=_.y,i.markRedraw();var b={align:l,verticalAlign:u};c.setStyle(b),v.setStyle(b),y=i.getBoundingRect();var x=_.margin,M=t.getItemStyle(["color","opacity"]);M.fill=t.get("backgroundColor");var w=new We({shape:{x:y.x-x[3],y:y.y-x[0],width:y.width+x[1]+x[3],height:y.height+x[0]+x[2],r:t.get("borderRadius")},style:M,subPixelOptimize:!0,silent:!0});i.add(w)}},e.type="title",e}(St);function Zie(r){r.registerComponentModel(Yie),r.registerComponentView(Qie)}var qie=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.layoutMode="box",t}return e.prototype.init=function(t,n,a){this.mergeDefaultAndTheme(t,a),this._initData()},e.prototype.mergeOption=function(t){r.prototype.mergeOption.apply(this,arguments),this._initData()},e.prototype.setCurrentIndex=function(t){t==null&&(t=this.option.currentIndex);var n=this._data.count();this.option.loop?t=(t%n+n)%n:(t>=n&&(t=n-1),t<0&&(t=0)),this.option.currentIndex=t},e.prototype.getCurrentIndex=function(){return this.option.currentIndex},e.prototype.isIndexMax=function(){return this.getCurrentIndex()>=this._data.count()-1},e.prototype.setPlayState=function(t){this.option.autoPlay=!!t},e.prototype.getPlayState=function(){return!!this.option.autoPlay},e.prototype._initData=function(){var t=this.option,n=t.data||[],a=t.axisType,i=this._names=[],o;a==="category"?(o=[],C(n,function(u,c){var f=Kt(Wl(u),""),h;_e(u)?(h=Me(u),h.value=c):h=c,o.push(h),i.push(f)})):o=n;var s={category:"ordinal",time:"time",value:"number"}[a]||"number",l=this._data=new jr([{name:"value",type:s}],this);l.initData(o,i)},e.prototype.getData=function(){return this._data},e.prototype.getCategories=function(){if(this.get("axisType")==="category")return this._names.slice()},e.type="timeline",e.defaultOption={z:4,show:!0,axisType:"time",realtime:!0,left:"20%",top:null,right:"20%",bottom:0,width:null,height:40,padding:5,controlPosition:"left",autoPlay:!1,rewind:!1,loop:!0,playInterval:2e3,currentIndex:0,itemStyle:{},label:{color:"#000"},data:[]},e}(He),Ck=qie,Nk=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="timeline.slider",e.defaultOption=co(Ck.defaultOption,{backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderWidth:0,orient:"horizontal",inverse:!1,tooltip:{trigger:"item"},symbol:"circle",symbolSize:12,lineStyle:{show:!0,width:2,color:"#DAE1F5"},label:{position:"auto",show:!0,interval:"auto",rotate:0,color:"#A4B1D7"},itemStyle:{color:"#A4B1D7",borderWidth:1},checkpointStyle:{symbol:"circle",symbolSize:15,color:"#316bf3",borderColor:"#fff",borderWidth:2,shadowBlur:2,shadowOffsetX:1,shadowOffsetY:1,shadowColor:"rgba(0, 0, 0, 0.3)",animation:!0,animationDuration:300,animationEasing:"quinticInOut"},controlStyle:{show:!0,showPlayBtn:!0,showPrevBtn:!0,showNextBtn:!0,itemSize:24,itemGap:12,position:"left",playIcon:"path://M31.6,53C17.5,53,6,41.5,6,27.4S17.5,1.8,31.6,1.8C45.7,1.8,57.2,13.3,57.2,27.4S45.7,53,31.6,53z M31.6,3.3 C18.4,3.3,7.5,14.1,7.5,27.4c0,13.3,10.8,24.1,24.1,24.1C44.9,51.5,55.7,40.7,55.7,27.4C55.7,14.1,44.9,3.3,31.6,3.3z M24.9,21.3 c0-2.2,1.6-3.1,3.5-2l10.5,6.1c1.899,1.1,1.899,2.9,0,4l-10.5,6.1c-1.9,1.1-3.5,0.2-3.5-2V21.3z",stopIcon:"path://M30.9,53.2C16.8,53.2,5.3,41.7,5.3,27.6S16.8,2,30.9,2C45,2,56.4,13.5,56.4,27.6S45,53.2,30.9,53.2z M30.9,3.5C17.6,3.5,6.8,14.4,6.8,27.6c0,13.3,10.8,24.1,24.101,24.1C44.2,51.7,55,40.9,55,27.6C54.9,14.4,44.1,3.5,30.9,3.5z M36.9,35.8c0,0.601-0.4,1-0.9,1h-1.3c-0.5,0-0.9-0.399-0.9-1V19.5c0-0.6,0.4-1,0.9-1H36c0.5,0,0.9,0.4,0.9,1V35.8z M27.8,35.8 c0,0.601-0.4,1-0.9,1h-1.3c-0.5,0-0.9-0.399-0.9-1V19.5c0-0.6,0.4-1,0.9-1H27c0.5,0,0.9,0.4,0.9,1L27.8,35.8L27.8,35.8z",nextIcon:"M2,18.5A1.52,1.52,0,0,1,.92,18a1.49,1.49,0,0,1,0-2.12L7.81,9.36,1,3.11A1.5,1.5,0,1,1,3,.89l8,7.34a1.48,1.48,0,0,1,.49,1.09,1.51,1.51,0,0,1-.46,1.1L3,18.08A1.5,1.5,0,0,1,2,18.5Z",prevIcon:"M10,.5A1.52,1.52,0,0,1,11.08,1a1.49,1.49,0,0,1,0,2.12L4.19,9.64,11,15.89a1.5,1.5,0,1,1-2,2.22L1,10.77A1.48,1.48,0,0,1,.5,9.68,1.51,1.51,0,0,1,1,8.58L9,.92A1.5,1.5,0,0,1,10,.5Z",prevBtnSize:18,nextBtnSize:18,color:"#A4B1D7",borderColor:"#A4B1D7",borderWidth:1},emphasis:{label:{show:!0,color:"#6f778d"},itemStyle:{color:"#316BF3"},controlStyle:{color:"#316BF3",borderColor:"#316BF3",borderWidth:2}},progress:{lineStyle:{color:"#316BF3"},itemStyle:{color:"#316BF3"},label:{color:"#6f778d"}},data:[]}),e}(Ck);Et(Nk,Y1.prototype);var Xie=Nk,Jie=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="timeline",e}(St),Kie=Jie,eoe=function(r){U(e,r);function e(t,n,a,i){var o=r.call(this,t,n,a)||this;return o.type=i||"value",o}return e.prototype.getLabelModel=function(){return this.model.getModel("label")},e.prototype.isHorizontal=function(){return this.model.get("orient")==="horizontal"},e}(Yn),toe=eoe,Sx=Math.PI,Lk=Ye(),roe=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,n){this.api=n},e.prototype.render=function(t,n,a){if(this.model=t,this.api=a,this.ecModel=n,this.group.removeAll(),t.get("show",!0)){var i=this._layout(t,a),o=this._createGroup("_mainGroup"),s=this._createGroup("_labelGroup"),l=this._axis=this._createAxis(i,t);t.formatTooltip=function(u){var c=l.scale.getLabel({value:u});return lr("nameValue",{noName:!0,value:c})},C(["AxisLine","AxisTick","Control","CurrentPointer"],function(u){this["_render"+u](i,o,l,t)},this),this._renderAxisLabel(i,s,l,t),this._position(i,t)}this._doPlayStop(),this._updateTicksStatus()},e.prototype.remove=function(){this._clearTimer(),this.group.removeAll()},e.prototype.dispose=function(){this._clearTimer()},e.prototype._layout=function(t,n){var a=t.get(["label","position"]),i=t.get("orient"),o=aoe(t,n),s;a==null||a==="auto"?s=i==="horizontal"?o.y+o.height/2<n.getHeight()/2?"-":"+":o.x+o.width/2<n.getWidth()/2?"+":"-":ce(a)?s={horizontal:{top:"-",bottom:"+"},vertical:{left:"-",right:"+"}}[i][a]:s=a;var l={horizontal:"center",vertical:s>=0||s==="+"?"left":"right"},u={horizontal:s>=0||s==="+"?"top":"bottom",vertical:"middle"},c={horizontal:0,vertical:Sx/2},f=i==="vertical"?o.height:o.width,h=t.getModel("controlStyle"),v=h.get("show",!0),d=v?h.get("itemSize"):0,p=v?h.get("itemGap"):0,g=d+p,y=t.get(["label","rotate"])||0;y=y*Sx/180;var m,_,b,x=h.get("position",!0),M=v&&h.get("showPlayBtn",!0),w=v&&h.get("showPrevBtn",!0),D=v&&h.get("showNextBtn",!0),T=0,I=f;x==="left"||x==="bottom"?(M&&(m=[0,0],T+=g),w&&(_=[T,0],T+=g),D&&(b=[I-d,0],I-=g)):(M&&(m=[I-d,0],I-=g),w&&(_=[0,0],T+=g),D&&(b=[I-d,0],I-=g));var A=[T,I];return t.get("inverse")&&A.reverse(),{viewRect:o,mainLength:f,orient:i,rotation:c[i],labelRotation:y,labelPosOpt:s,labelAlign:t.get(["label","align"])||l[i],labelBaseline:t.get(["label","verticalAlign"])||t.get(["label","baseline"])||u[i],playPosition:m,prevBtnPosition:_,nextBtnPosition:b,axisExtent:A,controlSize:d,controlGap:p}},e.prototype._position=function(t,n){var a=this._mainGroup,i=this._labelGroup,o=t.viewRect;if(t.orient==="vertical"){var s=yn(),l=o.x,u=o.y+o.height;ua(s,s,[-l,-u]),Zi(s,s,-Sx/2),ua(s,s,[l,u]),o=o.clone(),o.applyTransform(s)}var c=m(o),f=m(a.getBoundingRect()),h=m(i.getBoundingRect()),v=[a.x,a.y],d=[i.x,i.y];d[0]=v[0]=c[0][0];var p=t.labelPosOpt;if(p==null||ce(p)){var g=p==="+"?0:1;_(v,f,c,1,g),_(d,h,c,1,1-g)}else{var g=p>=0?0:1;_(v,f,c,1,g),d[1]=v[1]+p}a.setPosition(v),i.setPosition(d),a.rotation=i.rotation=t.rotation,y(a),y(i);function y(b){b.originX=c[0][0]-b.x,b.originY=c[1][0]-b.y}function m(b){return[[b.x,b.x+b.width],[b.y,b.y+b.height]]}function _(b,x,M,w,D){b[w]+=M[w][D]-x[w][D]}},e.prototype._createAxis=function(t,n){var a=n.getData(),i=n.get("axisType"),o=noe(n,i);o.getTicks=function(){return a.mapArray(["value"],function(u){return{value:u}})};var s=a.getDataExtent("value");o.setExtent(s[0],s[1]),o.calcNiceTicks();var l=new toe("value",o,t.axisExtent,i);return l.model=n,l},e.prototype._createGroup=function(t){var n=this[t]=new De;return this.group.add(n),n},e.prototype._renderAxisLine=function(t,n,a,i){var o=a.getExtent();if(!!i.get(["lineStyle","show"])){var s=new or({shape:{x1:o[0],y1:0,x2:o[1],y2:0},style:X({lineCap:"round"},i.getModel("lineStyle").getLineStyle()),silent:!0,z2:1});n.add(s);var l=this._progressLine=new or({shape:{x1:o[0],x2:this._currentPointer?this._currentPointer.x:o[0],y1:0,y2:0},style:me({lineCap:"round",lineWidth:s.style.lineWidth},i.getModel(["progress","lineStyle"]).getLineStyle()),silent:!0,z2:1});n.add(l)}},e.prototype._renderAxisTick=function(t,n,a,i){var o=this,s=i.getData(),l=a.scale.getTicks();this._tickSymbols=[],C(l,function(u){var c=a.dataToCoord(u.value),f=s.getItemModel(u.value),h=f.getModel("itemStyle"),v=f.getModel(["emphasis","itemStyle"]),d=f.getModel(["progress","itemStyle"]),p={x:c,y:0,onclick:fe(o._changeTimeline,o,u.value)},g=Ek(f,h,n,p);g.ensureState("emphasis").style=v.getItemStyle(),g.ensureState("progress").style=d.getItemStyle(),oo(g);var y=Te(g);f.get("tooltip")?(y.dataIndex=u.value,y.dataModel=i):y.dataIndex=y.dataModel=null,o._tickSymbols.push(g)})},e.prototype._renderAxisLabel=function(t,n,a,i){var o=this,s=a.getLabelModel();if(!!s.get("show")){var l=i.getData(),u=a.getViewLabels();this._tickLabels=[],C(u,function(c){var f=c.tickValue,h=l.getItemModel(f),v=h.getModel("label"),d=h.getModel(["emphasis","label"]),p=h.getModel(["progress","label"]),g=a.dataToCoord(c.tickValue),y=new Ge({x:g,y:0,rotation:t.labelRotation-t.rotation,onclick:fe(o._changeTimeline,o,f),silent:!1,style:yt(v,{text:c.formattedLabel,align:t.labelAlign,verticalAlign:t.labelBaseline})});y.ensureState("emphasis").style=yt(d),y.ensureState("progress").style=yt(p),n.add(y),oo(y),Lk(y).dataIndex=f,o._tickLabels.push(y)})}},e.prototype._renderControl=function(t,n,a,i){var o=t.controlSize,s=t.rotation,l=i.getModel("controlStyle").getItemStyle(),u=i.getModel(["emphasis","controlStyle"]).getItemStyle(),c=i.getPlayState(),f=i.get("inverse",!0);h(t.nextBtnPosition,"next",fe(this._changeTimeline,this,f?"-":"+")),h(t.prevBtnPosition,"prev",fe(this._changeTimeline,this,f?"+":"-")),h(t.playPosition,c?"stop":"play",fe(this._handlePlayClick,this,!c),!0);function h(v,d,p,g){if(!!v){var y=va(Ee(i.get(["controlStyle",d+"BtnSize"]),o),o),m=[0,-y/2,y,y],_=ioe(i,d+"Icon",m,{x:v[0],y:v[1],originX:o/2,originY:0,rotation:g?-s:0,rectHover:!0,style:l,onclick:p});_.ensureState("emphasis").style=u,n.add(_),oo(_)}}},e.prototype._renderCurrentPointer=function(t,n,a,i){var o=i.getData(),s=i.getCurrentIndex(),l=o.getItemModel(s).getModel("checkpointStyle"),u=this,c={onCreate:function(f){f.draggable=!0,f.drift=fe(u._handlePointerDrag,u),f.ondragend=fe(u._handlePointerDragend,u),Ok(f,u._progressLine,s,a,i,!0)},onUpdate:function(f){Ok(f,u._progressLine,s,a,i)}};this._currentPointer=Ek(l,l,this._mainGroup,{},this._currentPointer,c)},e.prototype._handlePlayClick=function(t){this._clearTimer(),this.api.dispatchAction({type:"timelinePlayChange",playState:t,from:this.uid})},e.prototype._handlePointerDrag=function(t,n,a){this._clearTimer(),this._pointerChangeTimeline([a.offsetX,a.offsetY])},e.prototype._handlePointerDragend=function(t){this._pointerChangeTimeline([t.offsetX,t.offsetY],!0)},e.prototype._pointerChangeTimeline=function(t,n){var a=this._toAxisCoord(t)[0],i=this._axis,o=bn(i.getExtent().slice());a>o[1]&&(a=o[1]),a<o[0]&&(a=o[0]),this._currentPointer.x=a,this._currentPointer.markRedraw();var s=this._progressLine;s&&(s.shape.x2=a,s.dirty());var l=this._findNearestTick(a),u=this.model;(n||l!==u.getCurrentIndex()&&u.get("realtime"))&&this._changeTimeline(l)},e.prototype._doPlayStop=function(){var t=this;this._clearTimer(),this.model.getPlayState()&&(this._timer=setTimeout(function(){var n=t.model;t._changeTimeline(n.getCurrentIndex()+(n.get("rewind",!0)?-1:1))},this.model.get("playInterval")))},e.prototype._toAxisCoord=function(t){var n=this._mainGroup.getLocalTransform();return ma(t,n,!0)},e.prototype._findNearestTick=function(t){var n=this.model.getData(),a=1/0,i,o=this._axis;return n.each(["value"],function(s,l){var u=o.dataToCoord(s),c=Math.abs(u-t);c<a&&(a=c,i=l)}),i},e.prototype._clearTimer=function(){this._timer&&(clearTimeout(this._timer),this._timer=null)},e.prototype._changeTimeline=function(t){var n=this.model.getCurrentIndex();t==="+"?t=n+1:t==="-"&&(t=n-1),this.api.dispatchAction({type:"timelineChange",currentIndex:t,from:this.uid})},e.prototype._updateTicksStatus=function(){var t=this.model.getCurrentIndex(),n=this._tickSymbols,a=this._tickLabels;if(n)for(var i=0;i<n.length;i++)n&&n[i]&&n[i].toggleState("progress",i<t);if(a)for(var i=0;i<a.length;i++)a&&a[i]&&a[i].toggleState("progress",Lk(a[i]).dataIndex<=t)},e.type="timeline.slider",e}(Kie);function noe(r,e){if(e=e||r.get("type"),e)switch(e){case"category":return new k_({ordinalMeta:r.getCategories(),extent:[1/0,-1/0]});case"time":return new t2({locale:r.ecModel.getLocaleModel(),useUTC:r.ecModel.get("useUTC")});default:return new _o}}function aoe(r,e){return Yt(r.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()},r.get("padding"))}function ioe(r,e,t,n){var a=n.style,i=Kl(r.get(["controlStyle",e]),n||{},new Pe(t[0],t[1],t[2],t[3]));return a&&i.setStyle(a),i}function Ek(r,e,t,n,a,i){var o=e.get("color");if(a)a.setColor(o),t.add(a),i&&i.onUpdate(a);else{var s=r.get("symbol");a=Ft(s,-1,-1,2,2,o),a.setStyle("strokeNoScale",!0),t.add(a),i&&i.onCreate(a)}var l=e.getItemStyle(["color"]);a.setStyle(l),n=Ne({rectHover:!0,z2:100},n,!0);var u=If(r.get("symbolSize"));n.scaleX=u[0]/2,n.scaleY=u[1]/2;var c=pu(r.get("symbolOffset"),u);c&&(n.x=(n.x||0)+c[0],n.y=(n.y||0)+c[1]);var f=r.get("symbolRotate");return n.rotation=(f||0)*Math.PI/180||0,a.attr(n),a.updateTransform(),a}function Ok(r,e,t,n,a,i){if(!r.dragging){var o=a.getModel("checkpointStyle"),s=n.dataToCoord(a.getData().get("value",t));if(i||!o.get("animation",!0))r.attr({x:s,y:0}),e&&e.attr({shape:{x2:s}});else{var l={duration:o.get("animationDuration",!0),easing:o.get("animationEasing",!0)};r.stopAnimation(null,!0),r.animateTo({x:s,y:0},l),e&&e.animateTo({shape:{x2:s}},l)}}}var ooe=roe;function soe(r){r.registerAction({type:"timelineChange",event:"timelineChanged",update:"prepareAndUpdate"},function(e,t,n){var a=t.getComponent("timeline");return a&&e.currentIndex!=null&&(a.setCurrentIndex(e.currentIndex),!a.get("loop",!0)&&a.isIndexMax()&&a.getPlayState()&&(a.setPlayState(!1),n.dispatchAction({type:"timelinePlayChange",playState:!1,from:e.from}))),t.resetOption("timeline",{replaceMerge:a.get("replaceMerge",!0)}),me({currentIndex:a.option.currentIndex},e)}),r.registerAction({type:"timelinePlayChange",event:"timelinePlayChanged",update:"update"},function(e,t){var n=t.getComponent("timeline");n&&e.playState!=null&&n.setPlayState(e.playState)})}function loe(r){var e=r&&r.timeline;J(e)||(e=e?[e]:[]),C(e,function(t){!t||uoe(t)})}function uoe(r){var e=r.type,t={number:"value",time:"time"};if(t[e]&&(r.axisType=t[e],delete r.type),Pk(r),tl(r,"controlPosition")){var n=r.controlStyle||(r.controlStyle={});tl(n,"position")||(n.position=r.controlPosition),n.position==="none"&&!tl(n,"show")&&(n.show=!1,delete n.position),delete r.controlPosition}C(r.data||[],function(a){_e(a)&&!J(a)&&(!tl(a,"value")&&tl(a,"name")&&(a.value=a.name),Pk(a))})}function Pk(r){var e=r.itemStyle||(r.itemStyle={}),t=e.emphasis||(e.emphasis={}),n=r.label||r.label||{},a=n.normal||(n.normal={}),i={normal:1,emphasis:1};C(n,function(o,s){!i[s]&&!tl(a,s)&&(a[s]=o)}),t.label&&!tl(n,"emphasis")&&(n.emphasis=t.label,delete t.label)}function tl(r,e){return r.hasOwnProperty(e)}function coe(r){r.registerComponentModel(Xie),r.registerComponentView(ooe),r.registerSubTypeDefaulter("timeline",function(){return"slider"}),soe(r),r.registerPreprocessor(loe)}function Ix(r,e){if(!r)return!1;for(var t=J(r)?r:[r],n=0;n<t.length;n++)if(t[n]&&t[n][e])return!0;return!1}function yg(r){ns(r,"label",["show"])}var mg=Ye(),zk=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.createdBySelf=!1,t}return e.prototype.init=function(t,n,a){this.mergeDefaultAndTheme(t,a),this._mergeOption(t,a,!1,!0)},e.prototype.isAnimationEnabled=function(){if($e.node)return!1;var t=this.__hostSeries;return this.getShallow("animation")&&t&&t.isAnimationEnabled()},e.prototype.mergeOption=function(t,n){this._mergeOption(t,n,!1,!1)},e.prototype._mergeOption=function(t,n,a,i){var o=this.mainType;a||n.eachSeries(function(s){var l=s.get(this.mainType,!0),u=mg(s)[o];if(!l||!l.data){mg(s)[o]=null;return}u?u._mergeOption(l,n,!0):(i&&yg(l),C(l.data,function(c){c instanceof Array?(yg(c[0]),yg(c[1])):yg(c)}),u=this.createMarkerModelFromSeries(l,this,n),X(u,{mainType:this.mainType,seriesIndex:s.seriesIndex,name:s.name,createdBySelf:!0}),u.__hostSeries=s),mg(s)[o]=u},this)},e.prototype.formatTooltip=function(t,n,a){var i=this.getData(),o=this.getRawValue(t),s=i.getName(t);return lr("section",{header:this.name,blocks:[lr("nameValue",{name:s,value:o,noName:!s,noValue:o==null})]})},e.prototype.getData=function(){return this._data},e.prototype.setData=function(t){this._data=t},e.getMarkerModelFromSeries=function(t,n){return mg(t)[n]},e.type="marker",e.dependencies=["series","grid","polar","geo"],e}(He);Et(zk,Y1.prototype);var No=zk,foe=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.createMarkerModelFromSeries=function(t,n,a){return new e(t,n,a)},e.type="markPoint",e.defaultOption={z:5,symbol:"pin",symbolSize:50,tooltip:{trigger:"item"},label:{show:!0,position:"inside"},itemStyle:{borderWidth:2},emphasis:{label:{show:!0}}},e}(No),hoe=foe;function Tx(r){return!(isNaN(parseFloat(r.x))&&isNaN(parseFloat(r.y)))}function voe(r){return!isNaN(parseFloat(r.x))&&!isNaN(parseFloat(r.y))}function _g(r,e,t,n,a,i){var o=[],s=xi(e,n),l=s?e.getCalculationInfo("stackResultDimension"):n,u=Cx(e,l,r),c=e.indicesOfNearest(l,u)[0];o[a]=e.get(t,c),o[i]=e.get(l,c);var f=e.get(n,c),h=da(e.get(n,c));return h=Math.min(h,20),h>=0&&(o[i]=+o[i].toFixed(h)),[o,f]}var Ax={min:Ae(_g,"min"),max:Ae(_g,"max"),average:Ae(_g,"average"),median:Ae(_g,"median")};function yh(r,e){if(!!e){var t=r.getData(),n=r.coordinateSystem,a=n.dimensions;if(!voe(e)&&!J(e.coord)&&n){var i=kk(e,t,n,r);if(e=Me(e),e.type&&Ax[e.type]&&i.baseAxis&&i.valueAxis){var o=ze(a,i.baseAxis.dim),s=ze(a,i.valueAxis.dim),l=Ax[e.type](t,i.baseDataDim,i.valueDataDim,o,s);e.coord=l[0],e.value=l[1]}else e.coord=[e.xAxis!=null?e.xAxis:e.radiusAxis,e.yAxis!=null?e.yAxis:e.angleAxis]}if(e.coord==null)e.coord=[];else for(var u=e.coord,c=0;c<2;c++)Ax[u[c]]&&(u[c]=Cx(t,t.mapDimension(a[c]),u[c]));return e}}function kk(r,e,t,n){var a={};return r.valueIndex!=null||r.valueDim!=null?(a.valueDataDim=r.valueIndex!=null?e.getDimension(r.valueIndex):r.valueDim,a.valueAxis=t.getAxis(doe(n,a.valueDataDim)),a.baseAxis=t.getOtherAxis(a.valueAxis),a.baseDataDim=e.mapDimension(a.baseAxis.dim)):(a.baseAxis=n.getBaseAxis(),a.valueAxis=t.getOtherAxis(a.baseAxis),a.baseDataDim=e.mapDimension(a.baseAxis.dim),a.valueDataDim=e.mapDimension(a.valueAxis.dim)),a}function doe(r,e){var t=r.getData().getDimensionInfo(e);return t&&t.coordDim}function mh(r,e){return r&&r.containData&&e.coord&&!Tx(e)?r.containData(e.coord):!0}function poe(r,e,t){return r&&r.containZone&&e.coord&&t.coord&&!Tx(e)&&!Tx(t)?r.containZone(e.coord,t.coord):!0}function Rk(r,e){return r?function(t,n,a,i){var o=i<2?t.coord&&t.coord[i]:t.value;return vo(o,e[i])}:function(t,n,a,i){return vo(t.value,e[i])}}function Cx(r,e,t){if(t==="average"){var n=0,a=0;return r.each(e,function(i,o){isNaN(i)||(n+=i,a++)}),n/a}else return t==="median"?r.getMedian(e):r.getDataExtent(e)[t==="max"?1:0]}var Nx=Ye(),goe=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(){this.markerGroupMap=ge()},e.prototype.render=function(t,n,a){var i=this,o=this.markerGroupMap;o.each(function(s){Nx(s).keep=!1}),n.eachSeries(function(s){var l=No.getMarkerModelFromSeries(s,i.type);l&&i.renderSeries(s,l,n,a)}),o.each(function(s){!Nx(s).keep&&i.group.remove(s.group)})},e.prototype.markKeep=function(t){Nx(t).keep=!0},e.prototype.toggleBlurSeries=function(t,n){var a=this;C(t,function(i){var o=No.getMarkerModelFromSeries(i,a.type);if(o){var s=o.getData();s.eachItemGraphicEl(function(l){l&&(n?eA(l):e1(l))})}})},e.type="marker",e}(St),Lx=goe;function jk(r,e,t){var n=e.coordinateSystem;r.each(function(a){var i=r.getItemModel(a),o,s=ue(i.get("x"),t.getWidth()),l=ue(i.get("y"),t.getHeight());if(!isNaN(s)&&!isNaN(l))o=[s,l];else if(e.getMarkerPosition)o=e.getMarkerPosition(r.getValues(r.dimensions,a));else if(n){var u=r.get(n.dimensions[0],a),c=r.get(n.dimensions[1],a);o=n.dataToPoint([u,c])}isNaN(s)||(o[0]=s),isNaN(l)||(o[1]=l),r.setItemLayout(a,o)})}var yoe=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.updateTransform=function(t,n,a){n.eachSeries(function(i){var o=No.getMarkerModelFromSeries(i,"markPoint");o&&(jk(o.getData(),i,a),this.markerGroupMap.get(i.id).updateLayout())},this)},e.prototype.renderSeries=function(t,n,a,i){var o=t.coordinateSystem,s=t.id,l=t.getData(),u=this.markerGroupMap,c=u.get(s)||u.set(s,new $f),f=moe(o,t,n);n.setData(f),jk(n.getData(),t,i),f.each(function(h){var v=f.getItemModel(h),d=v.getShallow("symbol"),p=v.getShallow("symbolSize"),g=v.getShallow("symbolRotate"),y=v.getShallow("symbolOffset"),m=v.getShallow("symbolKeepAspect");if(ye(d)||ye(p)||ye(g)||ye(y)){var _=n.getRawValue(h),b=n.getDataParams(h);ye(d)&&(d=d(_,b)),ye(p)&&(p=p(_,b)),ye(g)&&(g=g(_,b)),ye(y)&&(y=y(_,b))}var x=v.getModel("itemStyle").getItemStyle(),M=Sf(l,"color");x.fill||(x.fill=M),f.setItemVisual(h,{symbol:d,symbolSize:p,symbolRotate:g,symbolOffset:y,symbolKeepAspect:m,style:x})}),c.updateData(f),this.group.add(c.group),f.eachItemGraphicEl(function(h){h.traverse(function(v){Te(v).dataModel=n})}),this.markKeep(c),c.group.silent=n.get("silent")||t.get("silent")},e.type="markPoint",e}(Lx);function moe(r,e,t){var n;r?n=K(r&&r.dimensions,function(s){var l=e.getData().getDimensionInfo(e.getData().mapDimension(s))||{};return X(X({},l),{name:s,ordinalMeta:null})}):n=[{name:"value",type:"float"}];var a=new jr(n,t),i=K(t.get("data"),Ae(yh,e));r&&(i=ot(i,Ae(mh,r)));var o=Rk(!!r,n);return a.initData(i,null,o),a}var _oe=yoe;function boe(r){r.registerComponentModel(hoe),r.registerComponentView(_oe),r.registerPreprocessor(function(e){Ix(e.series,"markPoint")&&(e.markPoint=e.markPoint||{})})}var Moe=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.createMarkerModelFromSeries=function(t,n,a){return new e(t,n,a)},e.type="markLine",e.defaultOption={z:5,symbol:["circle","arrow"],symbolSize:[8,16],symbolOffset:0,precision:2,tooltip:{trigger:"item"},label:{show:!0,position:"end",distance:5},lineStyle:{type:"dashed"},emphasis:{label:{show:!0},lineStyle:{width:3}},animationEasing:"linear"},e}(No),xoe=Moe,bg=Ye(),woe=function(r,e,t,n){var a=r.getData(),i;if(J(n))i=n;else{var o=n.type;if(o==="min"||o==="max"||o==="average"||o==="median"||n.xAxis!=null||n.yAxis!=null){var s=void 0,l=void 0;if(n.yAxis!=null||n.xAxis!=null)s=e.getAxis(n.yAxis!=null?"y":"x"),l=ar(n.yAxis,n.xAxis);else{var u=kk(n,a,e,r);s=u.valueAxis;var c=E_(a,u.valueDataDim);l=Cx(a,c,o)}var f=s.dim==="x"?0:1,h=1-f,v=Me(n),d={coord:[]};v.type=null,v.coord=[],v.coord[h]=-1/0,d.coord[h]=1/0;var p=t.get("precision");p>=0&&Ue(l)&&(l=+l.toFixed(Math.min(p,20))),v.coord[f]=d.coord[f]=l,i=[v,d,{type:o,valueIndex:n.valueIndex,value:l}]}else i=[]}var g=[yh(r,i[0]),yh(r,i[1]),X({},i[2])];return g[2].type=g[2].type||null,Ne(g[2],g[0]),Ne(g[2],g[1]),g};function Mg(r){return!isNaN(r)&&!isFinite(r)}function Bk(r,e,t,n){var a=1-r,i=n.dimensions[r];return Mg(e[a])&&Mg(t[a])&&e[r]===t[r]&&n.getAxis(i).containData(e[r])}function Doe(r,e){if(r.type==="cartesian2d"){var t=e[0].coord,n=e[1].coord;if(t&&n&&(Bk(1,t,n,r)||Bk(0,t,n,r)))return!0}return mh(r,e[0])&&mh(r,e[1])}function Ex(r,e,t,n,a){var i=n.coordinateSystem,o=r.getItemModel(e),s,l=ue(o.get("x"),a.getWidth()),u=ue(o.get("y"),a.getHeight());if(!isNaN(l)&&!isNaN(u))s=[l,u];else{if(n.getMarkerPosition)s=n.getMarkerPosition(r.getValues(r.dimensions,e));else{var c=i.dimensions,f=r.get(c[0],e),h=r.get(c[1],e);s=i.dataToPoint([f,h])}if(Hs(i,"cartesian2d")){var v=i.getAxis("x"),d=i.getAxis("y"),c=i.dimensions;Mg(r.get(c[0],e))?s[0]=v.toGlobalCoord(v.getExtent()[t?0:1]):Mg(r.get(c[1],e))&&(s[1]=d.toGlobalCoord(d.getExtent()[t?0:1]))}isNaN(l)||(s[0]=l),isNaN(u)||(s[1]=u)}r.setItemLayout(e,s)}var Soe=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.updateTransform=function(t,n,a){n.eachSeries(function(i){var o=No.getMarkerModelFromSeries(i,"markLine");if(o){var s=o.getData(),l=bg(o).from,u=bg(o).to;l.each(function(c){Ex(l,c,!0,i,a),Ex(u,c,!1,i,a)}),s.each(function(c){s.setItemLayout(c,[l.getItemLayout(c),u.getItemLayout(c)])}),this.markerGroupMap.get(i.id).updateLayout()}},this)},e.prototype.renderSeries=function(t,n,a,i){var o=t.coordinateSystem,s=t.id,l=t.getData(),u=this.markerGroupMap,c=u.get(s)||u.set(s,new iM);this.group.add(c.group);var f=Ioe(o,t,n),h=f.from,v=f.to,d=f.line;bg(n).from=h,bg(n).to=v,n.setData(d);var p=n.get("symbol"),g=n.get("symbolSize"),y=n.get("symbolRotate"),m=n.get("symbolOffset");J(p)||(p=[p,p]),J(g)||(g=[g,g]),J(y)||(y=[y,y]),J(m)||(m=[m,m]),f.from.each(function(b){_(h,b,!0),_(v,b,!1)}),d.each(function(b){var x=d.getItemModel(b).getModel("lineStyle").getLineStyle();d.setItemLayout(b,[h.getItemLayout(b),v.getItemLayout(b)]),x.stroke==null&&(x.stroke=h.getItemVisual(b,"style").fill),d.setItemVisual(b,{fromSymbolKeepAspect:h.getItemVisual(b,"symbolKeepAspect"),fromSymbolOffset:h.getItemVisual(b,"symbolOffset"),fromSymbolRotate:h.getItemVisual(b,"symbolRotate"),fromSymbolSize:h.getItemVisual(b,"symbolSize"),fromSymbol:h.getItemVisual(b,"symbol"),toSymbolKeepAspect:v.getItemVisual(b,"symbolKeepAspect"),toSymbolOffset:v.getItemVisual(b,"symbolOffset"),toSymbolRotate:v.getItemVisual(b,"symbolRotate"),toSymbolSize:v.getItemVisual(b,"symbolSize"),toSymbol:v.getItemVisual(b,"symbol"),style:x})}),c.updateData(d),f.line.eachItemGraphicEl(function(b){Te(b).dataModel=n,b.traverse(function(x){Te(x).dataModel=n})});function _(b,x,M){var w=b.getItemModel(x);Ex(b,x,M,t,i);var D=w.getModel("itemStyle").getItemStyle();D.fill==null&&(D.fill=Sf(l,"color")),b.setItemVisual(x,{symbolKeepAspect:w.get("symbolKeepAspect"),symbolOffset:Ee(w.get("symbolOffset",!0),m[M?0:1]),symbolRotate:Ee(w.get("symbolRotate",!0),y[M?0:1]),symbolSize:Ee(w.get("symbolSize"),g[M?0:1]),symbol:Ee(w.get("symbol",!0),p[M?0:1]),style:D})}this.markKeep(c),c.group.silent=n.get("silent")||t.get("silent")},e.type="markLine",e}(Lx);function Ioe(r,e,t){var n;r?n=K(r&&r.dimensions,function(u){var c=e.getData().getDimensionInfo(e.getData().mapDimension(u))||{};return X(X({},c),{name:u,ordinalMeta:null})}):n=[{name:"value",type:"float"}];var a=new jr(n,t),i=new jr(n,t),o=new jr([],t),s=K(t.get("data"),Ae(woe,e,r,t));r&&(s=ot(s,Ae(Doe,r)));var l=Rk(!!r,n);return a.initData(K(s,function(u){return u[0]}),null,l),i.initData(K(s,function(u){return u[1]}),null,l),o.initData(K(s,function(u){return u[2]})),o.hasItemOption=!0,{from:a,to:i,line:o}}var Toe=Soe;function Aoe(r){r.registerComponentModel(xoe),r.registerComponentView(Toe),r.registerPreprocessor(function(e){Ix(e.series,"markLine")&&(e.markLine=e.markLine||{})})}var Coe=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.createMarkerModelFromSeries=function(t,n,a){return new e(t,n,a)},e.type="markArea",e.defaultOption={z:1,tooltip:{trigger:"item"},animation:!1,label:{show:!0,position:"top"},itemStyle:{borderWidth:0},emphasis:{label:{show:!0,position:"top"}}},e}(No),Noe=Coe,xg=Ye(),Loe=function(r,e,t,n){var a=n[0],i=n[1];if(!(!a||!i)){var o=yh(r,a),s=yh(r,i),l=o.coord,u=s.coord;l[0]=ar(l[0],-1/0),l[1]=ar(l[1],-1/0),u[0]=ar(u[0],1/0),u[1]=ar(u[1],1/0);var c=Dv([{},o,s]);return c.coord=[o.coord,s.coord],c.x0=o.x,c.y0=o.y,c.x1=s.x,c.y1=s.y,c}};function wg(r){return!isNaN(r)&&!isFinite(r)}function Fk(r,e,t,n){var a=1-r;return wg(e[a])&&wg(t[a])}function Eoe(r,e){var t=e.coord[0],n=e.coord[1],a={coord:t,x:e.x0,y:e.y0},i={coord:n,x:e.x1,y:e.y1};return Hs(r,"cartesian2d")?t&&n&&(Fk(1,t,n)||Fk(0,t,n))?!0:poe(r,a,i):mh(r,a)||mh(r,i)}function Vk(r,e,t,n,a){var i=n.coordinateSystem,o=r.getItemModel(e),s,l=ue(o.get(t[0]),a.getWidth()),u=ue(o.get(t[1]),a.getHeight());if(!isNaN(l)&&!isNaN(u))s=[l,u];else{if(n.getMarkerPosition){var c=r.getValues(["x0","y0"],e),f=r.getValues(["x1","y1"],e),h=i.clampData(c),v=i.clampData(f),d=[];t[0]==="x0"?d[0]=h[0]>v[0]?f[0]:c[0]:d[0]=h[0]>v[0]?c[0]:f[0],t[1]==="y0"?d[1]=h[1]>v[1]?f[1]:c[1]:d[1]=h[1]>v[1]?c[1]:f[1],s=n.getMarkerPosition(d,t,!0)}else{var p=r.get(t[0],e),g=r.get(t[1],e),y=[p,g];i.clampData&&i.clampData(y,y),s=i.dataToPoint(y,!0)}if(Hs(i,"cartesian2d")){var m=i.getAxis("x"),_=i.getAxis("y"),p=r.get(t[0],e),g=r.get(t[1],e);wg(p)?s[0]=m.toGlobalCoord(m.getExtent()[t[0]==="x0"?0:1]):wg(g)&&(s[1]=_.toGlobalCoord(_.getExtent()[t[1]==="y0"?0:1]))}isNaN(l)||(s[0]=l),isNaN(u)||(s[1]=u)}return s}var Hk=[["x0","y0"],["x1","y0"],["x1","y1"],["x0","y1"]],Ooe=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.updateTransform=function(t,n,a){n.eachSeries(function(i){var o=No.getMarkerModelFromSeries(i,"markArea");if(o){var s=o.getData();s.each(function(l){var u=K(Hk,function(f){return Vk(s,l,f,i,a)});s.setItemLayout(l,u);var c=s.getItemGraphicEl(l);c.setShape("points",u)})}},this)},e.prototype.renderSeries=function(t,n,a,i){var o=t.coordinateSystem,s=t.id,l=t.getData(),u=this.markerGroupMap,c=u.get(s)||u.set(s,{group:new De});this.group.add(c.group),this.markKeep(c);var f=Poe(o,t,n);n.setData(f),f.each(function(h){var v=K(Hk,function(D){return Vk(f,h,D,t,i)}),d=o.getAxis("x").scale,p=o.getAxis("y").scale,g=d.getExtent(),y=p.getExtent(),m=[d.parse(f.get("x0",h)),d.parse(f.get("x1",h))],_=[p.parse(f.get("y0",h)),p.parse(f.get("y1",h))];bn(m),bn(_);var b=!(g[0]>m[1]||g[1]<m[0]||y[0]>_[1]||y[1]<_[0]),x=!b;f.setItemLayout(h,{points:v,allClipped:x});var M=f.getItemModel(h).getModel("itemStyle").getItemStyle(),w=Sf(l,"color");M.fill||(M.fill=w,ce(M.fill)&&(M.fill=Ec(M.fill,.4))),M.stroke||(M.stroke=w),f.setItemVisual(h,"style",M)}),f.diff(xg(c).data).add(function(h){var v=f.getItemLayout(h);if(!v.allClipped){var d=new qr({shape:{points:v.points}});f.setItemGraphicEl(h,d),c.group.add(d)}}).update(function(h,v){var d=xg(c).data.getItemGraphicEl(v),p=f.getItemLayout(h);p.allClipped?d&&c.group.remove(d):(d?Qe(d,{shape:{points:p.points}},n,h):d=new qr({shape:{points:p.points}}),f.setItemGraphicEl(h,d),c.group.add(d))}).remove(function(h){var v=xg(c).data.getItemGraphicEl(h);c.group.remove(v)}).execute(),f.eachItemGraphicEl(function(h,v){var d=f.getItemModel(v),p=f.getItemVisual(v,"style");h.useStyle(f.getItemVisual(v,"style")),wr(h,sr(d),{labelFetcher:n,labelDataIndex:v,defaultText:f.getName(v)||"",inheritColor:ce(p.fill)?Ec(p.fill,1):"#000"}),xr(h,d),Lt(h,null,null,d.get(["emphasis","disabled"])),Te(h).dataModel=n}),xg(c).data=f,c.group.silent=n.get("silent")||t.get("silent")},e.type="markArea",e}(Lx);function Poe(r,e,t){var n,a,i=["x0","y0","x1","y1"];if(r){var o=K(r&&r.dimensions,function(u){var c=e.getData(),f=c.getDimensionInfo(c.mapDimension(u))||{};return X(X({},f),{name:u,ordinalMeta:null})});a=K(i,function(u,c){return{name:u,type:o[c%2].type}}),n=new jr(a,t)}else a=[{name:"value",type:"float"}],n=new jr(a,t);var s=K(t.get("data"),Ae(Loe,e,r,t));r&&(s=ot(s,Ae(Eoe,r)));var l=r?function(u,c,f,h){var v=u.coord[Math.floor(h/2)][h%2];return vo(v,a[h])}:function(u,c,f,h){return vo(u.value,a[h])};return n.initData(s,null,l),n.hasItemOption=!0,n}var zoe=Ooe;function koe(r){r.registerComponentModel(Noe),r.registerComponentView(zoe),r.registerPreprocessor(function(e){Ix(e.series,"markArea")&&(e.markArea=e.markArea||{})})}var Roe=function(r,e){if(e==="all")return{type:"all",title:r.getLocaleModel().get(["legend","selector","all"])};if(e==="inverse")return{type:"inverse",title:r.getLocaleModel().get(["legend","selector","inverse"])}},joe=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.layoutMode={type:"box",ignoreSize:!0},t}return e.prototype.init=function(t,n,a){this.mergeDefaultAndTheme(t,a),t.selected=t.selected||{},this._updateSelector(t)},e.prototype.mergeOption=function(t,n){r.prototype.mergeOption.call(this,t,n),this._updateSelector(t)},e.prototype._updateSelector=function(t){var n=t.selector,a=this.ecModel;n===!0&&(n=t.selector=["all","inverse"]),J(n)&&C(n,function(i,o){ce(i)&&(i={type:i}),n[o]=Ne(i,Roe(a,i.type))})},e.prototype.optionUpdated=function(){this._updateData(this.ecModel);var t=this._data;if(t[0]&&this.get("selectedMode")==="single"){for(var n=!1,a=0;a<t.length;a++){var i=t[a].get("name");if(this.isSelected(i)){this.select(i),n=!0;break}}!n&&this.select(t[0].get("name"))}},e.prototype._updateData=function(t){var n=[],a=[];t.eachRawSeries(function(l){var u=l.name;a.push(u);var c;if(l.legendVisualProvider){var f=l.legendVisualProvider,h=f.getAllNames();t.isSeriesFiltered(l)||(a=a.concat(h)),h.length?n=n.concat(h):c=!0}else c=!0;c&&C0(l)&&n.push(l.name)}),this._availableNames=a;var i=this.get("data")||n,o=ge(),s=K(i,function(l){return(ce(l)||Ue(l))&&(l={name:l}),o.get(l.name)?null:(o.set(l.name,!0),new ft(l,this,this.ecModel))},this);this._data=ot(s,function(l){return!!l})},e.prototype.getData=function(){return this._data},e.prototype.select=function(t){var n=this.option.selected,a=this.get("selectedMode");if(a==="single"){var i=this._data;C(i,function(o){n[o.get("name")]=!1})}n[t]=!0},e.prototype.unSelect=function(t){this.get("selectedMode")!=="single"&&(this.option.selected[t]=!1)},e.prototype.toggleSelected=function(t){var n=this.option.selected;n.hasOwnProperty(t)||(n[t]=!0),this[n[t]?"unSelect":"select"](t)},e.prototype.allSelect=function(){var t=this._data,n=this.option.selected;C(t,function(a){n[a.get("name",!0)]=!0})},e.prototype.inverseSelect=function(){var t=this._data,n=this.option.selected;C(t,function(a){var i=a.get("name",!0);n.hasOwnProperty(i)||(n[i]=!0),n[i]=!n[i]})},e.prototype.isSelected=function(t){var n=this.option.selected;return!(n.hasOwnProperty(t)&&!n[t])&&ze(this._availableNames,t)>=0},e.prototype.getOrient=function(){return this.get("orient")==="vertical"?{index:1,name:"vertical"}:{index:0,name:"horizontal"}},e.type="legend.plain",e.dependencies=["series"],e.defaultOption={z:4,show:!0,orient:"horizontal",left:"center",top:0,align:"auto",backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderRadius:0,borderWidth:0,padding:5,itemGap:10,itemWidth:25,itemHeight:14,symbolRotate:"inherit",symbolKeepAspect:!0,inactiveColor:"#ccc",inactiveBorderColor:"#ccc",inactiveBorderWidth:"auto",itemStyle:{color:"inherit",opacity:"inherit",borderColor:"inherit",borderWidth:"auto",borderCap:"inherit",borderJoin:"inherit",borderDashOffset:"inherit",borderMiterLimit:"inherit"},lineStyle:{width:"auto",color:"inherit",inactiveColor:"#ccc",inactiveWidth:2,opacity:"inherit",type:"inherit",cap:"inherit",join:"inherit",dashOffset:"inherit",miterLimit:"inherit"},textStyle:{color:"#333"},selectedMode:!0,selector:!1,selectorLabel:{show:!0,borderRadius:10,padding:[3,5,3,5],fontSize:12,fontFamily:"sans-serif",color:"#666",borderWidth:1,borderColor:"#666"},emphasis:{selectorLabel:{show:!0,color:"#eee",backgroundColor:"#666"}},selectorPosition:"auto",selectorItemGap:7,selectorButtonGap:10,tooltip:{show:!1}},e}(He),Ox=joe,ju=Ae,Px=C,Dg=De,Boe=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.newlineDisabled=!1,t}return e.prototype.init=function(){this.group.add(this._contentGroup=new Dg),this.group.add(this._selectorGroup=new Dg),this._isFirstRender=!0},e.prototype.getContentGroup=function(){return this._contentGroup},e.prototype.getSelectorGroup=function(){return this._selectorGroup},e.prototype.render=function(t,n,a){var i=this._isFirstRender;if(this._isFirstRender=!1,this.resetInner(),!!t.get("show",!0)){var o=t.get("align"),s=t.get("orient");(!o||o==="auto")&&(o=t.get("left")==="right"&&s==="vertical"?"right":"left");var l=t.get("selector",!0),u=t.get("selectorPosition",!0);l&&(!u||u==="auto")&&(u=s==="horizontal"?"end":"start"),this.renderInner(o,t,n,a,l,s,u);var c=t.getBoxLayoutParams(),f={width:a.getWidth(),height:a.getHeight()},h=t.get("padding"),v=Yt(c,f,h),d=this.layoutInner(t,o,v,i,l,u),p=Yt(me({width:d.width,height:d.height},c),f,h);this.group.x=p.x-d.x,this.group.y=p.y-d.y,this.group.markRedraw(),this.group.add(this._backgroundEl=Xz(d,t))}},e.prototype.resetInner=function(){this.getContentGroup().removeAll(),this._backgroundEl&&this.group.remove(this._backgroundEl),this.getSelectorGroup().removeAll()},e.prototype.renderInner=function(t,n,a,i,o,s,l){var u=this.getContentGroup(),c=ge(),f=n.get("selectedMode"),h=[];a.eachRawSeries(function(v){!v.get("legendHoverLink")&&h.push(v.id)}),Px(n.getData(),function(v,d){var p=v.get("name");if(!this.newlineDisabled&&(p===""||p===`
|
|
260
|
+
`)){var g=new Dg;g.newline=!0,u.add(g);return}var y=a.getSeriesByName(p)[0];if(!c.get(p))if(y){var m=y.getData(),_=m.getVisual("legendLineStyle")||{},b=m.getVisual("legendIcon"),x=m.getVisual("style"),M=this._createItem(y,p,d,v,n,t,_,x,b,f,i);M.on("click",ju(Wk,p,null,i,h)).on("mouseover",ju(zx,y.name,null,i,h)).on("mouseout",ju(kx,y.name,null,i,h)),c.set(p,!0)}else a.eachRawSeries(function(w){if(!c.get(p)&&w.legendVisualProvider){var D=w.legendVisualProvider;if(!D.containName(p))return;var T=D.indexOfName(p),I=D.getItemVisual(T,"style"),A=D.getItemVisual(T,"legendIcon"),N=Ur(I.fill);N&&N[3]===0&&(N[3]=.2,I=X(X({},I),{fill:fa(N,"rgba")}));var L=this._createItem(w,p,d,v,n,t,{},I,A,f,i);L.on("click",ju(Wk,null,p,i,h)).on("mouseover",ju(zx,null,p,i,h)).on("mouseout",ju(kx,null,p,i,h)),c.set(p,!0)}},this)},this),o&&this._createSelector(o,n,i,s,l)},e.prototype._createSelector=function(t,n,a,i,o){var s=this.getSelectorGroup();Px(t,function(u){var c=u.type,f=new Ge({style:{x:0,y:0,align:"center",verticalAlign:"middle"},onclick:function(){a.dispatchAction({type:c==="all"?"legendAllSelect":"legendInverseSelect"})}});s.add(f);var h=n.getModel("selectorLabel"),v=n.getModel(["emphasis","selectorLabel"]);wr(f,{normal:h,emphasis:v},{defaultText:u.title}),oo(f)})},e.prototype._createItem=function(t,n,a,i,o,s,l,u,c,f,h){var v=t.visualDrawType,d=o.get("itemWidth"),p=o.get("itemHeight"),g=o.isSelected(n),y=i.get("symbolRotate"),m=i.get("symbolKeepAspect"),_=i.get("icon");c=_||c||"roundRect";var b=Foe(c,i,l,u,v,g,h),x=new Dg,M=i.getModel("textStyle");if(ye(t.getLegendIcon)&&(!_||_==="inherit"))x.add(t.getLegendIcon({itemWidth:d,itemHeight:p,icon:c,iconRotate:y,itemStyle:b.itemStyle,lineStyle:b.lineStyle,symbolKeepAspect:m}));else{var w=_==="inherit"&&t.getData().getVisual("symbol")?y==="inherit"?t.getData().getVisual("symbolRotate"):y:0;x.add(Voe({itemWidth:d,itemHeight:p,icon:c,iconRotate:w,itemStyle:b.itemStyle,lineStyle:b.lineStyle,symbolKeepAspect:m}))}var D=s==="left"?d+5:-5,T=s,I=o.get("formatter"),A=n;ce(I)&&I?A=I.replace("{name}",n!=null?n:""):ye(I)&&(A=I(n));var N=i.get("inactiveColor");x.add(new Ge({style:yt(M,{text:A,x:D,y:p/2,fill:g?M.getTextColor():N,align:T,verticalAlign:"middle"})}));var L=new We({shape:x.getBoundingRect(),invisible:!0}),E=i.getModel("tooltip");return E.get("show")&&eu({el:L,componentModel:o,itemName:n,itemTooltipOption:E.option}),x.add(L),x.eachChild(function(O){O.silent=!0}),L.silent=!f,this.getContentGroup().add(x),oo(x),x.__legendDataIndex=a,x},e.prototype.layoutInner=function(t,n,a,i,o,s){var l=this.getContentGroup(),u=this.getSelectorGroup();Ss(t.get("orient"),l,t.get("itemGap"),a.width,a.height);var c=l.getBoundingRect(),f=[-c.x,-c.y];if(u.markRedraw(),l.markRedraw(),o){Ss("horizontal",u,t.get("selectorItemGap",!0));var h=u.getBoundingRect(),v=[-h.x,-h.y],d=t.get("selectorButtonGap",!0),p=t.getOrient().index,g=p===0?"width":"height",y=p===0?"height":"width",m=p===0?"y":"x";s==="end"?v[p]+=c[g]+d:f[p]+=h[g]+d,v[1-p]+=c[y]/2-h[y]/2,u.x=v[0],u.y=v[1],l.x=f[0],l.y=f[1];var _={x:0,y:0};return _[g]=c[g]+d+h[g],_[y]=Math.max(c[y],h[y]),_[m]=Math.min(0,h[m]+v[1-p]),_}else return l.x=f[0],l.y=f[1],this.group.getBoundingRect()},e.prototype.remove=function(){this.getContentGroup().removeAll(),this._isFirstRender=!0},e.type="legend.plain",e}(St);function Foe(r,e,t,n,a,i,o){function s(g,y){g.lineWidth==="auto"&&(g.lineWidth=y.lineWidth>0?2:0),Px(g,function(m,_){g[_]==="inherit"&&(g[_]=y[_])})}var l=e.getModel("itemStyle"),u=l.getItemStyle(),c=r.lastIndexOf("empty",0)===0?"fill":"stroke",f=l.getShallow("decal");u.decal=!f||f==="inherit"?n.decal:yu(f,o),u.fill==="inherit"&&(u.fill=n[a]),u.stroke==="inherit"&&(u.stroke=n[c]),u.opacity==="inherit"&&(u.opacity=(a==="fill"?n:t).opacity),s(u,n);var h=e.getModel("lineStyle"),v=h.getLineStyle();if(s(v,t),u.fill==="auto"&&(u.fill=n.fill),u.stroke==="auto"&&(u.stroke=n.fill),v.stroke==="auto"&&(v.stroke=n.fill),!i){var d=e.get("inactiveBorderWidth"),p=u[c];u.lineWidth=d==="auto"?n.lineWidth>0&&p?2:0:u.lineWidth,u.fill=e.get("inactiveColor"),u.stroke=e.get("inactiveBorderColor"),v.stroke=h.get("inactiveColor"),v.lineWidth=h.get("inactiveWidth")}return{itemStyle:u,lineStyle:v}}function Voe(r){var e=r.icon||"roundRect",t=Ft(e,0,0,r.itemWidth,r.itemHeight,r.itemStyle.fill,r.symbolKeepAspect);return t.setStyle(r.itemStyle),t.rotation=(r.iconRotate||0)*Math.PI/180,t.setOrigin([r.itemWidth/2,r.itemHeight/2]),e.indexOf("empty")>-1&&(t.style.stroke=t.style.fill,t.style.fill="#fff",t.style.lineWidth=2),t}function Wk(r,e,t,n){kx(r,e,t,n),t.dispatchAction({type:"legendToggleSelect",name:r!=null?r:e}),zx(r,e,t,n)}function Gk(r){for(var e=r.getZr().storage.getDisplayList(),t,n=0,a=e.length;n<a&&!(t=e[n].states.emphasis);)n++;return t&&t.hoverLayer}function zx(r,e,t,n){Gk(t)||t.dispatchAction({type:"highlight",seriesName:r,name:e,excludeSeriesId:n})}function kx(r,e,t,n){Gk(t)||t.dispatchAction({type:"downplay",seriesName:r,name:e,excludeSeriesId:n})}var $k=Boe;function Hoe(r){var e=r.findComponents({mainType:"legend"});e&&e.length&&r.filterSeries(function(t){for(var n=0;n<e.length;n++)if(!e[n].isSelected(t.name))return!1;return!0})}function _h(r,e,t){var n={},a=r==="toggleSelected",i;return t.eachComponent("legend",function(o){a&&i!=null?o[i?"select":"unSelect"](e.name):r==="allSelect"||r==="inverseSelect"?o[r]():(o[r](e.name),i=o.isSelected(e.name));var s=o.getData();C(s,function(l){var u=l.get("name");if(!(u===`
|
|
261
|
+
`||u==="")){var c=o.isSelected(u);n.hasOwnProperty(u)?n[u]=n[u]&&c:n[u]=c}})}),r==="allSelect"||r==="inverseSelect"?{selected:n}:{name:e.name,selected:n}}function Woe(r){r.registerAction("legendToggleSelect","legendselectchanged",Ae(_h,"toggleSelected")),r.registerAction("legendAllSelect","legendselectall",Ae(_h,"allSelect")),r.registerAction("legendInverseSelect","legendinverseselect",Ae(_h,"inverseSelect")),r.registerAction("legendSelect","legendselected",Ae(_h,"select")),r.registerAction("legendUnSelect","legendunselected",Ae(_h,"unSelect"))}function Uk(r){r.registerComponentModel(Ox),r.registerComponentView($k),r.registerProcessor(r.PRIORITY.PROCESSOR.SERIES_FILTER,Hoe),r.registerSubTypeDefaulter("legend",function(){return"plain"}),Woe(r)}var Goe=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.setScrollDataIndex=function(t){this.option.scrollDataIndex=t},e.prototype.init=function(t,n,a){var i=iu(t);r.prototype.init.call(this,t,n,a),Yk(this,t,i)},e.prototype.mergeOption=function(t,n){r.prototype.mergeOption.call(this,t,n),Yk(this,this.option,t)},e.type="legend.scroll",e.defaultOption=co(Ox.defaultOption,{scrollDataIndex:0,pageButtonItemGap:5,pageButtonGap:null,pageButtonPosition:"end",pageFormatter:"{current}/{total}",pageIcons:{horizontal:["M0,0L12,-10L12,10z","M0,0L-12,-10L-12,10z"],vertical:["M0,0L20,0L10,-20z","M0,0L20,0L10,20z"]},pageIconColor:"#2f4554",pageIconInactiveColor:"#aaa",pageIconSize:15,pageTextStyle:{color:"#333"},animationDurationUpdate:800}),e}(Ox);function Yk(r,e,t){var n=r.getOrient(),a=[1,1];a[n.index]=0,fo(e,t,{type:"box",ignoreSize:!!a})}var $oe=Goe,Qk=De,Rx=["width","height"],jx=["x","y"],Uoe=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.newlineDisabled=!0,t._currentIndex=0,t}return e.prototype.init=function(){r.prototype.init.call(this),this.group.add(this._containerGroup=new Qk),this._containerGroup.add(this.getContentGroup()),this.group.add(this._controllerGroup=new Qk)},e.prototype.resetInner=function(){r.prototype.resetInner.call(this),this._controllerGroup.removeAll(),this._containerGroup.removeClipPath(),this._containerGroup.__rectSize=null},e.prototype.renderInner=function(t,n,a,i,o,s,l){var u=this;r.prototype.renderInner.call(this,t,n,a,i,o,s,l);var c=this._controllerGroup,f=n.get("pageIconSize",!0),h=J(f)?f:[f,f];d("pagePrev",0);var v=n.getModel("pageTextStyle");c.add(new Ge({name:"pageText",style:{text:"xx/xx",fill:v.getTextColor(),font:v.getFont(),verticalAlign:"middle",align:"center"},silent:!0})),d("pageNext",1);function d(p,g){var y=p+"DataIndex",m=Kl(n.get("pageIcons",!0)[n.getOrient().name][g],{onclick:fe(u._pageGo,u,y,n,i)},{x:-h[0]/2,y:-h[1]/2,width:h[0],height:h[1]});m.name=p,c.add(m)}},e.prototype.layoutInner=function(t,n,a,i,o,s){var l=this.getSelectorGroup(),u=t.getOrient().index,c=Rx[u],f=jx[u],h=Rx[1-u],v=jx[1-u];o&&Ss("horizontal",l,t.get("selectorItemGap",!0));var d=t.get("selectorButtonGap",!0),p=l.getBoundingRect(),g=[-p.x,-p.y],y=Me(a);o&&(y[c]=a[c]-p[c]-d);var m=this._layoutContentAndController(t,i,y,u,c,h,v,f);if(o){if(s==="end")g[u]+=m[c]+d;else{var _=p[c]+d;g[u]-=_,m[f]-=_}m[c]+=p[c]+d,g[1-u]+=m[v]+m[h]/2-p[h]/2,m[h]=Math.max(m[h],p[h]),m[v]=Math.min(m[v],p[v]+g[1-u]),l.x=g[0],l.y=g[1],l.markRedraw()}return m},e.prototype._layoutContentAndController=function(t,n,a,i,o,s,l,u){var c=this.getContentGroup(),f=this._containerGroup,h=this._controllerGroup;Ss(t.get("orient"),c,t.get("itemGap"),i?a.width:null,i?null:a.height),Ss("horizontal",h,t.get("pageButtonItemGap",!0));var v=c.getBoundingRect(),d=h.getBoundingRect(),p=this._showController=v[o]>a[o],g=[-v.x,-v.y];n||(g[i]=c[u]);var y=[0,0],m=[-d.x,-d.y],_=Ee(t.get("pageButtonGap",!0),t.get("itemGap",!0));if(p){var b=t.get("pageButtonPosition",!0);b==="end"?m[i]+=a[o]-d[o]:y[i]+=d[o]+_}m[1-i]+=v[s]/2-d[s]/2,c.setPosition(g),f.setPosition(y),h.setPosition(m);var x={x:0,y:0};if(x[o]=p?a[o]:v[o],x[s]=Math.max(v[s],d[s]),x[l]=Math.min(0,d[l]+m[1-i]),f.__rectSize=a[o],p){var M={x:0,y:0};M[o]=Math.max(a[o]-d[o]-_,0),M[s]=x[s],f.setClipPath(new We({shape:M})),f.__rectSize=M[o]}else h.eachChild(function(D){D.attr({invisible:!0,silent:!0})});var w=this._getPageInfo(t);return w.pageIndex!=null&&Qe(c,{x:w.contentPosition[0],y:w.contentPosition[1]},p?t:null),this._updatePageInfoView(t,w),x},e.prototype._pageGo=function(t,n,a){var i=this._getPageInfo(n)[t];i!=null&&a.dispatchAction({type:"legendScroll",scrollDataIndex:i,legendId:n.id})},e.prototype._updatePageInfoView=function(t,n){var a=this._controllerGroup;C(["pagePrev","pageNext"],function(c){var f=c+"DataIndex",h=n[f]!=null,v=a.childOfName(c);v&&(v.setStyle("fill",h?t.get("pageIconColor",!0):t.get("pageIconInactiveColor",!0)),v.cursor=h?"pointer":"default")});var i=a.childOfName("pageText"),o=t.get("pageFormatter"),s=n.pageIndex,l=s!=null?s+1:0,u=n.pageCount;i&&o&&i.setStyle("text",ce(o)?o.replace("{current}",l==null?"":l+"").replace("{total}",u==null?"":u+""):o({current:l,total:u}))},e.prototype._getPageInfo=function(t){var n=t.get("scrollDataIndex",!0),a=this.getContentGroup(),i=this._containerGroup.__rectSize,o=t.getOrient().index,s=Rx[o],l=jx[o],u=this._findTargetItemIndex(n),c=a.children(),f=c[u],h=c.length,v=h?1:0,d={contentPosition:[a.x,a.y],pageCount:v,pageIndex:v-1,pagePrevDataIndex:null,pageNextDataIndex:null};if(!f)return d;var p=b(f);d.contentPosition[o]=-p.s;for(var g=u+1,y=p,m=p,_=null;g<=h;++g)_=b(c[g]),(!_&&m.e>y.s+i||_&&!x(_,y.s))&&(m.i>y.i?y=m:y=_,y&&(d.pageNextDataIndex==null&&(d.pageNextDataIndex=y.i),++d.pageCount)),m=_;for(var g=u-1,y=p,m=p,_=null;g>=-1;--g)_=b(c[g]),(!_||!x(m,_.s))&&y.i<m.i&&(m=y,d.pagePrevDataIndex==null&&(d.pagePrevDataIndex=y.i),++d.pageCount,++d.pageIndex),y=_;return d;function b(M){if(M){var w=M.getBoundingRect(),D=w[l]+M[l];return{s:D,e:D+w[s],i:M.__legendDataIndex}}}function x(M,w){return M.e>=w&&M.s<=w+i}},e.prototype._findTargetItemIndex=function(t){if(!this._showController)return 0;var n,a=this.getContentGroup(),i;return a.eachChild(function(o,s){var l=o.__legendDataIndex;i==null&&l!=null&&(i=s),l===t&&(n=s)}),n!=null?n:i},e.type="legend.scroll",e}($k),Yoe=Uoe;function Qoe(r){r.registerAction("legendScroll","legendscroll",function(e,t){var n=e.scrollDataIndex;n!=null&&t.eachComponent({mainType:"legend",subType:"scroll",query:e},function(a){a.setScrollDataIndex(n)})})}function Zoe(r){Re(Uk),r.registerComponentModel($oe),r.registerComponentView(Yoe),Qoe(r)}function qoe(r){Re(Uk),Re(Zoe)}var Xoe=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="dataZoom.inside",e.defaultOption=co(dh.defaultOption,{disabled:!1,zoomLock:!1,zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}),e}(dh),Joe=Xoe,Bx=Ye();function Koe(r,e,t){Bx(r).coordSysRecordMap.each(function(n){var a=n.dataZoomInfoMap.get(e.uid);a&&(a.getRange=t)})}function ese(r,e){for(var t=Bx(r).coordSysRecordMap,n=t.keys(),a=0;a<n.length;a++){var i=n[a],o=t.get(i),s=o.dataZoomInfoMap;if(s){var l=e.uid,u=s.get(l);u&&(s.removeKey(l),s.keys().length||Zk(t,o))}}}function Zk(r,e){if(e){r.removeKey(e.model.uid);var t=e.controller;t&&t.dispose()}}function tse(r,e){var t={model:e,containsPoint:Ae(nse,e),dispatchAction:Ae(rse,r),dataZoomInfoMap:null,controller:null},n=t.controller=new Xf(r.getZr());return C(["pan","zoom","scrollMove"],function(a){n.on(a,function(i){var o=[];t.dataZoomInfoMap.each(function(s){if(!!i.isAvailableBehavior(s.model.option)){var l=(s.getRange||{})[a],u=l&&l(s.dzReferCoordSysInfo,t.model.mainType,t.controller,i);!s.model.get("disabled",!0)&&u&&o.push({dataZoomId:s.model.id,start:u[0],end:u[1]})}}),o.length&&t.dispatchAction(o)})}),t}function rse(r,e){r.isDisposed()||r.dispatchAction({type:"dataZoom",animation:{easing:"cubicOut",duration:100},batch:e})}function nse(r,e,t,n){return r.coordinateSystem.containPoint([t,n])}function ase(r){var e,t="type_",n={type_true:2,type_move:1,type_false:0,type_undefined:-1},a=!0;return r.each(function(i){var o=i.model,s=o.get("disabled",!0)?!1:o.get("zoomLock",!0)?"move":!0;n[t+s]>n[t+e]&&(e=s),a=a&&o.get("preventDefaultMouseMove",!0)}),{controlType:e,opt:{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!0,preventDefaultMouseMove:!!a}}}function ise(r){r.registerProcessor(r.PRIORITY.PROCESSOR.FILTER,function(e,t){var n=Bx(t),a=n.coordSysRecordMap||(n.coordSysRecordMap=ge());a.each(function(i){i.dataZoomInfoMap=null}),e.eachComponent({mainType:"dataZoom",subType:"inside"},function(i){var o=$z(i);C(o.infoList,function(s){var l=s.model.uid,u=a.get(l)||a.set(l,tse(t,s.model)),c=u.dataZoomInfoMap||(u.dataZoomInfoMap=ge());c.set(i.uid,{dzReferCoordSysInfo:s,model:i,getRange:null})})}),a.each(function(i){var o=i.controller,s,l=i.dataZoomInfoMap;if(l){var u=l.keys()[0];u!=null&&(s=l.get(u))}if(!s){Zk(a,i);return}var c=ase(l);o.enable(c.controlType,c.opt),o.setPointerChecker(i.containsPoint),vu(i,"dispatchAction",s.model.get("throttle",!0),"fixRate")})})}var ose=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="dataZoom.inside",t}return e.prototype.render=function(t,n,a){if(r.prototype.render.apply(this,arguments),t.noTarget()){this._clear();return}this.range=t.getPercentRange(),Koe(a,t,{pan:fe(Fx.pan,this),zoom:fe(Fx.zoom,this),scrollMove:fe(Fx.scrollMove,this)})},e.prototype.dispose=function(){this._clear(),r.prototype.dispose.apply(this,arguments)},e.prototype._clear=function(){ese(this.api,this.dataZoomModel),this.range=null},e.type="dataZoom.inside",e}(fx),Fx={zoom:function(r,e,t,n){var a=this.range,i=a.slice(),o=r.axisModels[0];if(!!o){var s=Vx[e](null,[n.originX,n.originY],o,t,r),l=(s.signal>0?s.pixelStart+s.pixelLength-s.pixel:s.pixel-s.pixelStart)/s.pixelLength*(i[1]-i[0])+i[0],u=Math.max(1/n.scale,0);i[0]=(i[0]-l)*u+l,i[1]=(i[1]-l)*u+l;var c=this.dataZoomModel.findRepresentativeAxisProxy().getMinMaxSpan();if(qs(0,i,[0,100],0,c.minSpan,c.maxSpan),this.range=i,a[0]!==i[0]||a[1]!==i[1])return i}},pan:qk(function(r,e,t,n,a,i){var o=Vx[n]([i.oldX,i.oldY],[i.newX,i.newY],e,a,t);return o.signal*(r[1]-r[0])*o.pixel/o.pixelLength}),scrollMove:qk(function(r,e,t,n,a,i){var o=Vx[n]([0,0],[i.scrollDelta,i.scrollDelta],e,a,t);return o.signal*(r[1]-r[0])*i.scrollDelta})};function qk(r){return function(e,t,n,a){var i=this.range,o=i.slice(),s=e.axisModels[0];if(!!s){var l=r(o,s,e,t,n,a);if(qs(l,o,[0,100],"all"),this.range=o,i[0]!==o[0]||i[1]!==o[1])return o}}}var Vx={grid:function(r,e,t,n,a){var i=t.axis,o={},s=a.model.coordinateSystem.getRect();return r=r||[0,0],i.dim==="x"?(o.pixel=e[0]-r[0],o.pixelLength=s.width,o.pixelStart=s.x,o.signal=i.inverse?1:-1):(o.pixel=e[1]-r[1],o.pixelLength=s.height,o.pixelStart=s.y,o.signal=i.inverse?-1:1),o},polar:function(r,e,t,n,a){var i=t.axis,o={},s=a.model.coordinateSystem,l=s.getRadiusAxis().getExtent(),u=s.getAngleAxis().getExtent();return r=r?s.pointToCoord(r):[0,0],e=s.pointToCoord(e),t.mainType==="radiusAxis"?(o.pixel=e[0]-r[0],o.pixelLength=l[1]-l[0],o.pixelStart=l[0],o.signal=i.inverse?1:-1):(o.pixel=e[1]-r[1],o.pixelLength=u[1]-u[0],o.pixelStart=u[0],o.signal=i.inverse?-1:1),o},singleAxis:function(r,e,t,n,a){var i=t.axis,o=a.model.coordinateSystem.getRect(),s={};return r=r||[0,0],i.orient==="horizontal"?(s.pixel=e[0]-r[0],s.pixelLength=o.width,s.pixelStart=o.x,s.signal=i.inverse?1:-1):(s.pixel=e[1]-r[1],s.pixelLength=o.height,s.pixelStart=o.y,s.signal=i.inverse?-1:1),s}},sse=ose;function Xk(r){hx(r),r.registerComponentModel(Joe),r.registerComponentView(sse),ise(r)}var lse=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="dataZoom.slider",e.layoutMode="box",e.defaultOption=co(dh.defaultOption,{show:!0,right:"ph",top:"ph",width:"ph",height:"ph",left:null,bottom:null,borderColor:"#d2dbee",borderRadius:3,backgroundColor:"rgba(47,69,84,0)",dataBackground:{lineStyle:{color:"#d2dbee",width:.5},areaStyle:{color:"#d2dbee",opacity:.2}},selectedDataBackground:{lineStyle:{color:"#8fb0f7",width:.5},areaStyle:{color:"#8fb0f7",opacity:.2}},fillerColor:"rgba(135,175,274,0.2)",handleIcon:"path://M-9.35,34.56V42m0-40V9.5m-2,0h4a2,2,0,0,1,2,2v21a2,2,0,0,1-2,2h-4a2,2,0,0,1-2-2v-21A2,2,0,0,1-11.35,9.5Z",handleSize:"100%",handleStyle:{color:"#fff",borderColor:"#ACB8D1"},moveHandleSize:7,moveHandleIcon:"path://M-320.9-50L-320.9-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-348-41-339-50-320.9-50z M-212.3-50L-212.3-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-239.4-41-230.4-50-212.3-50z M-103.7-50L-103.7-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-130.9-41-121.8-50-103.7-50z",moveHandleStyle:{color:"#D2DBEE",opacity:.7},showDetail:!0,showDataShadow:"auto",realtime:!0,zoomLock:!1,textStyle:{color:"#6E7079"},brushSelect:!0,brushStyle:{color:"rgba(135,175,274,0.15)"},emphasis:{handleStyle:{borderColor:"#8FB0F7"},moveHandleStyle:{color:"#8FB0F7"}}}),e}(dh),use=lse,bh=We,Jk=7,cse=1,Hx=30,fse=7,Mh="horizontal",Kk="vertical",hse=5,vse=["line","bar","candlestick","scatter"],dse={easing:"cubicOut",duration:100,delay:0},pse=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._displayables={},t}return e.prototype.init=function(t,n){this.api=n,this._onBrush=fe(this._onBrush,this),this._onBrushEnd=fe(this._onBrushEnd,this)},e.prototype.render=function(t,n,a,i){if(r.prototype.render.apply(this,arguments),vu(this,"_dispatchZoomAction",t.get("throttle"),"fixRate"),this._orient=t.getOrient(),t.get("show")===!1){this.group.removeAll();return}if(t.noTarget()){this._clear(),this.group.removeAll();return}(!i||i.type!=="dataZoom"||i.from!==this.uid)&&this._buildView(),this._updateView()},e.prototype.dispose=function(){this._clear(),r.prototype.dispose.apply(this,arguments)},e.prototype._clear=function(){xf(this,"_dispatchZoomAction");var t=this.api.getZr();t.off("mousemove",this._onBrush),t.off("mouseup",this._onBrushEnd)},e.prototype._buildView=function(){var t=this.group;t.removeAll(),this._brushing=!1,this._displayables.brushRect=null,this._resetLocation(),this._resetInterval();var n=this._displayables.sliderGroup=new De;this._renderBackground(),this._renderHandle(),this._renderDataShadow(),t.add(n),this._positionGroup()},e.prototype._resetLocation=function(){var t=this.dataZoomModel,n=this.api,a=t.get("brushSelect"),i=a?fse:0,o=this._findCoordRect(),s={width:n.getWidth(),height:n.getHeight()},l=this._orient===Mh?{right:s.width-o.x-o.width,top:s.height-Hx-Jk-i,width:o.width,height:Hx}:{right:Jk,top:o.y,width:Hx,height:o.height},u=iu(t.option);C(["right","top","width","height"],function(f){u[f]==="ph"&&(u[f]=l[f])});var c=Yt(u,s);this._location={x:c.x,y:c.y},this._size=[c.width,c.height],this._orient===Kk&&this._size.reverse()},e.prototype._positionGroup=function(){var t=this.group,n=this._location,a=this._orient,i=this.dataZoomModel.getFirstTargetAxisModel(),o=i&&i.get("inverse"),s=this._displayables.sliderGroup,l=(this._dataShadowInfo||{}).otherAxisInverse;s.attr(a===Mh&&!o?{scaleY:l?1:-1,scaleX:1}:a===Mh&&o?{scaleY:l?1:-1,scaleX:-1}:a===Kk&&!o?{scaleY:l?-1:1,scaleX:1,rotation:Math.PI/2}:{scaleY:l?-1:1,scaleX:-1,rotation:Math.PI/2});var u=t.getBoundingRect([s]);t.x=n.x-u.x,t.y=n.y-u.y,t.markRedraw()},e.prototype._getViewExtent=function(){return[0,this._size[0]]},e.prototype._renderBackground=function(){var t=this.dataZoomModel,n=this._size,a=this._displayables.sliderGroup,i=t.get("brushSelect");a.add(new bh({silent:!0,shape:{x:0,y:0,width:n[0],height:n[1]},style:{fill:t.get("backgroundColor")},z2:-40}));var o=new bh({shape:{x:0,y:0,width:n[0],height:n[1]},style:{fill:"transparent"},z2:0,onclick:fe(this._onClickPanel,this)}),s=this.api.getZr();i?(o.on("mousedown",this._onBrushStart,this),o.cursor="crosshair",s.on("mousemove",this._onBrush),s.on("mouseup",this._onBrushEnd)):(s.off("mousemove",this._onBrush),s.off("mouseup",this._onBrushEnd)),a.add(o)},e.prototype._renderDataShadow=function(){var t=this._dataShadowInfo=this._prepareDataShadowInfo();if(this._displayables.dataShadowSegs=[],!t)return;var n=this._size,a=this._shadowSize||[],i=t.series,o=i.getRawData(),s=i.getShadowDim&&i.getShadowDim(),l=s&&o.getDimensionInfo(s)?i.getShadowDim():t.otherDim;if(l==null)return;var u=this._shadowPolygonPts,c=this._shadowPolylinePts;if(o!==this._shadowData||l!==this._shadowDim||n[0]!==a[0]||n[1]!==a[1]){var f=o.getDataExtent(l),h=(f[1]-f[0])*.3;f=[f[0]-h,f[1]+h];var v=[0,n[1]],d=[0,n[0]],p=[[n[0],0],[0,0]],g=[],y=d[1]/(o.count()-1),m=0,_=Math.round(o.count()/n[0]),b;o.each([l],function(T,I){if(_>0&&I%_){m+=y;return}var A=T==null||isNaN(T)||T==="",N=A?0:st(T,f,v,!0);A&&!b&&I?(p.push([p[p.length-1][0],0]),g.push([g[g.length-1][0],0])):!A&&b&&(p.push([m,0]),g.push([m,0])),p.push([m,N]),g.push([m,N]),m+=y,b=A}),u=this._shadowPolygonPts=p,c=this._shadowPolylinePts=g}this._shadowData=o,this._shadowDim=l,this._shadowSize=[n[0],n[1]];var x=this.dataZoomModel;function M(T){var I=x.getModel(T?"selectedDataBackground":"dataBackground"),A=new De,N=new qr({shape:{points:u},segmentIgnoreThreshold:1,style:I.getModel("areaStyle").getAreaStyle(),silent:!0,z2:-20}),L=new Xr({shape:{points:c},segmentIgnoreThreshold:1,style:I.getModel("lineStyle").getLineStyle(),silent:!0,z2:-19});return A.add(N),A.add(L),A}for(var w=0;w<3;w++){var D=M(w===1);this._displayables.sliderGroup.add(D),this._displayables.dataShadowSegs.push(D)}},e.prototype._prepareDataShadowInfo=function(){var t=this.dataZoomModel,n=t.get("showDataShadow");if(n!==!1){var a,i=this.ecModel;return t.eachTargetAxis(function(o,s){var l=t.getAxisProxy(o,s).getTargetSeriesModels();C(l,function(u){if(!a&&!(n!==!0&&ze(vse,u.get("type"))<0)){var c=i.getComponent(Ao(o),s).axis,f=gse(o),h,v=u.coordinateSystem;f!=null&&v.getOtherAxis&&(h=v.getOtherAxis(c).inverse),f=u.getData().mapDimension(f),a={thisAxis:c,series:u,thisDim:o,otherDim:f,otherAxisInverse:h}}},this)},this),a}},e.prototype._renderHandle=function(){var t=this.group,n=this._displayables,a=n.handles=[null,null],i=n.handleLabels=[null,null],o=this._displayables.sliderGroup,s=this._size,l=this.dataZoomModel,u=this.api,c=l.get("borderRadius")||0,f=l.get("brushSelect"),h=n.filler=new bh({silent:f,style:{fill:l.get("fillerColor")},textConfig:{position:"inside"}});o.add(h),o.add(new bh({silent:!0,subPixelOptimize:!0,shape:{x:0,y:0,width:s[0],height:s[1],r:c},style:{stroke:l.get("dataBackgroundColor")||l.get("borderColor"),lineWidth:cse,fill:"rgba(0,0,0,0)"}})),C([0,1],function(_){var b=l.get("handleIcon");!ep[b]&&b.indexOf("path://")<0&&b.indexOf("image://")<0&&(b="path://"+b);var x=Ft(b,-1,0,2,2,null,!0);x.attr({cursor:eR(this._orient),draggable:!0,drift:fe(this._onDragMove,this,_),ondragend:fe(this._onDragEnd,this),onmouseover:fe(this._showDataInfo,this,!0),onmouseout:fe(this._showDataInfo,this,!1),z2:5});var M=x.getBoundingRect(),w=l.get("handleSize");this._handleHeight=ue(w,this._size[1]),this._handleWidth=M.width/M.height*this._handleHeight,x.setStyle(l.getModel("handleStyle").getItemStyle()),x.style.strokeNoScale=!0,x.rectHover=!0,x.ensureState("emphasis").style=l.getModel(["emphasis","handleStyle"]).getItemStyle(),oo(x);var D=l.get("handleColor");D!=null&&(x.style.fill=D),o.add(a[_]=x);var T=l.getModel("textStyle");t.add(i[_]=new Ge({silent:!0,invisible:!0,style:yt(T,{x:0,y:0,text:"",verticalAlign:"middle",align:"center",fill:T.getTextColor(),font:T.getFont()}),z2:10}))},this);var v=h;if(f){var d=ue(l.get("moveHandleSize"),s[1]),p=n.moveHandle=new We({style:l.getModel("moveHandleStyle").getItemStyle(),silent:!0,shape:{r:[0,0,2,2],y:s[1]-.5,height:d}}),g=d*.8,y=n.moveHandleIcon=Ft(l.get("moveHandleIcon"),-g/2,-g/2,g,g,"#fff",!0);y.silent=!0,y.y=s[1]+d/2-.5,p.ensureState("emphasis").style=l.getModel(["emphasis","moveHandleStyle"]).getItemStyle();var m=Math.min(s[1]/2,Math.max(d,10));v=n.moveZone=new We({invisible:!0,shape:{y:s[1]-m,height:d+m}}),v.on("mouseover",function(){u.enterEmphasis(p)}).on("mouseout",function(){u.leaveEmphasis(p)}),o.add(p),o.add(y),o.add(v)}v.attr({draggable:!0,cursor:eR(this._orient),drift:fe(this._onDragMove,this,"all"),ondragstart:fe(this._showDataInfo,this,!0),ondragend:fe(this._onDragEnd,this),onmouseover:fe(this._showDataInfo,this,!0),onmouseout:fe(this._showDataInfo,this,!1)})},e.prototype._resetInterval=function(){var t=this._range=this.dataZoomModel.getPercentRange(),n=this._getViewExtent();this._handleEnds=[st(t[0],[0,100],n,!0),st(t[1],[0,100],n,!0)]},e.prototype._updateInterval=function(t,n){var a=this.dataZoomModel,i=this._handleEnds,o=this._getViewExtent(),s=a.findRepresentativeAxisProxy().getMinMaxSpan(),l=[0,100];qs(n,i,o,a.get("zoomLock")?"all":t,s.minSpan!=null?st(s.minSpan,l,o,!0):null,s.maxSpan!=null?st(s.maxSpan,l,o,!0):null);var u=this._range,c=this._range=bn([st(i[0],o,l,!0),st(i[1],o,l,!0)]);return!u||u[0]!==c[0]||u[1]!==c[1]},e.prototype._updateView=function(t){var n=this._displayables,a=this._handleEnds,i=bn(a.slice()),o=this._size;C([0,1],function(v){var d=n.handles[v],p=this._handleHeight;d.attr({scaleX:p/2,scaleY:p/2,x:a[v]+(v?-1:1),y:o[1]/2-p/2})},this),n.filler.setShape({x:i[0],y:0,width:i[1]-i[0],height:o[1]});var s={x:i[0],width:i[1]-i[0]};n.moveHandle&&(n.moveHandle.setShape(s),n.moveZone.setShape(s),n.moveZone.getBoundingRect(),n.moveHandleIcon&&n.moveHandleIcon.attr("x",s.x+s.width/2));for(var l=n.dataShadowSegs,u=[0,i[0],i[1],o[0]],c=0;c<l.length;c++){var f=l[c],h=f.getClipPath();h||(h=new We,f.setClipPath(h)),h.setShape({x:u[c],y:0,width:u[c+1]-u[c],height:o[1]})}this._updateDataInfo(t)},e.prototype._updateDataInfo=function(t){var n=this.dataZoomModel,a=this._displayables,i=a.handleLabels,o=this._orient,s=["",""];if(n.get("showDetail")){var l=n.findRepresentativeAxisProxy();if(l){var u=l.getAxisModel().axis,c=this._range,f=t?l.calculateDataWindow({start:c[0],end:c[1]}).valueWindow:l.getDataValueWindow();s=[this._formatLabel(f[0],u),this._formatLabel(f[1],u)]}}var h=bn(this._handleEnds.slice());v.call(this,0),v.call(this,1);function v(d){var p=lo(a.handles[d].parent,this.group),g=Cd(d===0?"right":"left",p),y=this._handleWidth/2+hse,m=ma([h[d]+(d===0?-y:y),this._size[1]/2],p);i[d].setStyle({x:m[0],y:m[1],verticalAlign:o===Mh?"middle":g,align:o===Mh?g:"center",text:s[d]})}},e.prototype._formatLabel=function(t,n){var a=this.dataZoomModel,i=a.get("labelFormatter"),o=a.get("labelPrecision");(o==null||o==="auto")&&(o=n.getPixelPrecision());var s=t==null||isNaN(t)?"":n.type==="category"||n.type==="time"?n.scale.getLabel({value:Math.round(t)}):t.toFixed(Math.min(o,20));return ye(i)?i(t,s):ce(i)?i.replace("{value}",s):s},e.prototype._showDataInfo=function(t){t=this._dragging||t;var n=this._displayables,a=n.handleLabels;a[0].attr("invisible",!t),a[1].attr("invisible",!t),n.moveHandle&&this.api[t?"enterEmphasis":"leaveEmphasis"](n.moveHandle,1)},e.prototype._onDragMove=function(t,n,a,i){this._dragging=!0,hi(i.event);var o=this._displayables.sliderGroup.getLocalTransform(),s=ma([n,a],o,!0),l=this._updateInterval(t,s[0]),u=this.dataZoomModel.get("realtime");this._updateView(!u),l&&u&&this._dispatchZoomAction(!0)},e.prototype._onDragEnd=function(){this._dragging=!1,this._showDataInfo(!1);var t=this.dataZoomModel.get("realtime");!t&&this._dispatchZoomAction(!1)},e.prototype._onClickPanel=function(t){var n=this._size,a=this._displayables.sliderGroup.transformCoordToLocal(t.offsetX,t.offsetY);if(!(a[0]<0||a[0]>n[0]||a[1]<0||a[1]>n[1])){var i=this._handleEnds,o=(i[0]+i[1])/2,s=this._updateInterval("all",a[0]-o);this._updateView(),s&&this._dispatchZoomAction(!1)}},e.prototype._onBrushStart=function(t){var n=t.offsetX,a=t.offsetY;this._brushStart=new Oe(n,a),this._brushing=!0,this._brushStartTime=+new Date},e.prototype._onBrushEnd=function(t){if(!!this._brushing){var n=this._displayables.brushRect;if(this._brushing=!1,!!n){n.attr("ignore",!0);var a=n.shape,i=+new Date;if(!(i-this._brushStartTime<200&&Math.abs(a.width)<5)){var o=this._getViewExtent(),s=[0,100];this._range=bn([st(a.x,o,s,!0),st(a.x+a.width,o,s,!0)]),this._handleEnds=[a.x,a.x+a.width],this._updateView(),this._dispatchZoomAction(!1)}}}},e.prototype._onBrush=function(t){this._brushing&&(hi(t.event),this._updateBrushRect(t.offsetX,t.offsetY))},e.prototype._updateBrushRect=function(t,n){var a=this._displayables,i=this.dataZoomModel,o=a.brushRect;o||(o=a.brushRect=new bh({silent:!0,style:i.getModel("brushStyle").getItemStyle()}),a.sliderGroup.add(o)),o.attr("ignore",!1);var s=this._brushStart,l=this._displayables.sliderGroup,u=l.transformCoordToLocal(t,n),c=l.transformCoordToLocal(s.x,s.y),f=this._size;u[0]=Math.max(Math.min(f[0],u[0]),0),o.setShape({x:c[0],y:0,width:u[0]-c[0],height:f[1]})},e.prototype._dispatchZoomAction=function(t){var n=this._range;this.api.dispatchAction({type:"dataZoom",from:this.uid,dataZoomId:this.dataZoomModel.id,animation:t?dse:null,start:n[0],end:n[1]})},e.prototype._findCoordRect=function(){var t,n=$z(this.dataZoomModel).infoList;if(!t&&n.length){var a=n[0].model.coordinateSystem;t=a.getRect&&a.getRect()}if(!t){var i=this.api.getWidth(),o=this.api.getHeight();t={x:i*.2,y:o*.2,width:i*.6,height:o*.6}}return t},e.type="dataZoom.slider",e}(fx);function gse(r){var e={x:"y",y:"x",radius:"angle",angle:"radius"};return e[r]}function eR(r){return r==="vertical"?"ns-resize":"ew-resize"}var yse=pse;function tR(r){r.registerComponentModel(use),r.registerComponentView(yse),hx(r)}function mse(r){Re(Xk),Re(tR)}var _se={get:function(r,e,t){var n=Me((bse[r]||{})[e]);return t&&J(n)?n[n.length-1]:n}},bse={color:{active:["#006edd","#e0ffff"],inactive:["rgba(0,0,0,0)"]},colorHue:{active:[0,360],inactive:[0,0]},colorSaturation:{active:[.3,1],inactive:[0,0]},colorLightness:{active:[.9,.5],inactive:[0,0]},colorAlpha:{active:[.3,1],inactive:[0,0]},opacity:{active:[.3,1],inactive:[0,0]},symbol:{active:["circle","roundRect","diamond"],inactive:["none"]},symbolSize:{active:[10,50],inactive:[0,0]}},rR=_se,nR=Sr.mapVisual,Mse=Sr.eachVisual,xse=J,aR=C,wse=bn,Dse=st,Sse=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.stateList=["inRange","outOfRange"],t.replacableOptionKeys=["inRange","outOfRange","target","controller","color"],t.layoutMode={type:"box",ignoreSize:!0},t.dataBound=[-1/0,1/0],t.targetVisuals={},t.controllerVisuals={},t}return e.prototype.init=function(t,n,a){this.mergeDefaultAndTheme(t,a)},e.prototype.optionUpdated=function(t,n){var a=this.option;!n&&Mk(a,t,this.replacableOptionKeys),this.textStyleModel=this.getModel("textStyle"),this.resetItemSize(),this.completeVisualOption()},e.prototype.resetVisual=function(t){var n=this.stateList;t=fe(t,this),this.controllerVisuals=Mx(this.option.controller,n,t),this.targetVisuals=Mx(this.option.target,n,t)},e.prototype.getItemSymbol=function(){return null},e.prototype.getTargetSeriesIndices=function(){var t=this.option.seriesIndex,n=[];return t==null||t==="all"?this.ecModel.eachSeries(function(a,i){n.push(i)}):n=ct(t),n},e.prototype.eachTargetSeries=function(t,n){C(this.getTargetSeriesIndices(),function(a){var i=this.ecModel.getSeriesByIndex(a);i&&t.call(n,i)},this)},e.prototype.isTargetSeries=function(t){var n=!1;return this.eachTargetSeries(function(a){a===t&&(n=!0)}),n},e.prototype.formatValueText=function(t,n,a){var i=this.option,o=i.precision,s=this.dataBound,l=i.formatter,u;a=a||["<",">"],J(t)&&(t=t.slice(),u=!0);var c=n?t:u?[f(t[0]),f(t[1])]:f(t);if(ce(l))return l.replace("{value}",u?c[0]:c).replace("{value2}",u?c[1]:c);if(ye(l))return u?l(t[0],t[1]):l(t);if(u)return t[0]===s[0]?a[0]+" "+c[1]:t[1]===s[1]?a[1]+" "+c[0]:c[0]+" - "+c[1];return c;function f(h){return h===s[0]?"min":h===s[1]?"max":(+h).toFixed(Math.min(o,20))}},e.prototype.resetExtent=function(){var t=this.option,n=wse([t.min,t.max]);this._dataExtent=n},e.prototype.getDataDimensionIndex=function(t){var n=this.option.dimension;if(n!=null)return t.getDimensionIndex(n);for(var a=t.dimensions,i=a.length-1;i>=0;i--){var o=a[i],s=t.getDimensionInfo(o);if(!s.isCalculationCoord)return s.storeDimIndex}},e.prototype.getExtent=function(){return this._dataExtent.slice()},e.prototype.completeVisualOption=function(){var t=this.ecModel,n=this.option,a={inRange:n.inRange,outOfRange:n.outOfRange},i=n.target||(n.target={}),o=n.controller||(n.controller={});Ne(i,a),Ne(o,a);var s=this.isCategory();l.call(this,i),l.call(this,o),u.call(this,i,"inRange","outOfRange"),c.call(this,o);function l(f){xse(n.color)&&!f.inRange&&(f.inRange={color:n.color.slice().reverse()}),f.inRange=f.inRange||{color:t.get("gradientColor")}}function u(f,h,v){var d=f[h],p=f[v];d&&!p&&(p=f[v]={},aR(d,function(g,y){if(!!Sr.isValidType(y)){var m=rR.get(y,"inactive",s);m!=null&&(p[y]=m,y==="color"&&!p.hasOwnProperty("opacity")&&!p.hasOwnProperty("colorAlpha")&&(p.opacity=[0,0]))}}))}function c(f){var h=(f.inRange||{}).symbol||(f.outOfRange||{}).symbol,v=(f.inRange||{}).symbolSize||(f.outOfRange||{}).symbolSize,d=this.get("inactiveColor"),p=this.getItemSymbol(),g=p||"roundRect";aR(this.stateList,function(y){var m=this.itemSize,_=f[y];_||(_=f[y]={color:s?d:[d]}),_.symbol==null&&(_.symbol=h&&Me(h)||(s?g:[g])),_.symbolSize==null&&(_.symbolSize=v&&Me(v)||(s?m[0]:[m[0],m[0]])),_.symbol=nR(_.symbol,function(M){return M==="none"?g:M});var b=_.symbolSize;if(b!=null){var x=-1/0;Mse(b,function(M){M>x&&(x=M)}),_.symbolSize=nR(b,function(M){return Dse(M,[0,x],[0,m[0]],!0)})}},this)}},e.prototype.resetItemSize=function(){this.itemSize=[parseFloat(this.get("itemWidth")),parseFloat(this.get("itemHeight"))]},e.prototype.isCategory=function(){return!!this.option.categories},e.prototype.setSelected=function(t){},e.prototype.getSelected=function(){return null},e.prototype.getValueState=function(t){return null},e.prototype.getVisualMeta=function(t){return null},e.type="visualMap",e.dependencies=["series"],e.defaultOption={show:!0,z:4,seriesIndex:"all",min:0,max:200,left:0,right:null,top:null,bottom:0,itemWidth:null,itemHeight:null,inverse:!1,orient:"vertical",backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",contentColor:"#5793f3",inactiveColor:"#aaa",borderWidth:0,padding:5,textGap:10,precision:0,textStyle:{color:"#333"}},e}(He),Sg=Sse,iR=[20,140],Ise=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.optionUpdated=function(t,n){r.prototype.optionUpdated.apply(this,arguments),this.resetExtent(),this.resetVisual(function(a){a.mappingMethod="linear",a.dataExtent=this.getExtent()}),this._resetRange()},e.prototype.resetItemSize=function(){r.prototype.resetItemSize.apply(this,arguments);var t=this.itemSize;(t[0]==null||isNaN(t[0]))&&(t[0]=iR[0]),(t[1]==null||isNaN(t[1]))&&(t[1]=iR[1])},e.prototype._resetRange=function(){var t=this.getExtent(),n=this.option.range;!n||n.auto?(t.auto=1,this.option.range=t):J(n)&&(n[0]>n[1]&&n.reverse(),n[0]=Math.max(n[0],t[0]),n[1]=Math.min(n[1],t[1]))},e.prototype.completeVisualOption=function(){r.prototype.completeVisualOption.apply(this,arguments),C(this.stateList,function(t){var n=this.option.controller[t].symbolSize;n&&n[0]!==n[1]&&(n[0]=n[1]/3)},this)},e.prototype.setSelected=function(t){this.option.range=t.slice(),this._resetRange()},e.prototype.getSelected=function(){var t=this.getExtent(),n=bn((this.get("range")||[]).slice());return n[0]>t[1]&&(n[0]=t[1]),n[1]>t[1]&&(n[1]=t[1]),n[0]<t[0]&&(n[0]=t[0]),n[1]<t[0]&&(n[1]=t[0]),n},e.prototype.getValueState=function(t){var n=this.option.range,a=this.getExtent();return(n[0]<=a[0]||n[0]<=t)&&(n[1]>=a[1]||t<=n[1])?"inRange":"outOfRange"},e.prototype.findTargetDataIndices=function(t){var n=[];return this.eachTargetSeries(function(a){var i=[],o=a.getData();o.each(this.getDataDimensionIndex(o),function(s,l){t[0]<=s&&s<=t[1]&&i.push(l)},this),n.push({seriesId:a.id,dataIndex:i})},this),n},e.prototype.getVisualMeta=function(t){var n=oR(this,"outOfRange",this.getExtent()),a=oR(this,"inRange",this.option.range.slice()),i=[];function o(v,d){i.push({value:v,color:t(v,d)})}for(var s=0,l=0,u=a.length,c=n.length;l<c&&(!a.length||n[l]<=a[0]);l++)n[l]<a[s]&&o(n[l],"outOfRange");for(var f=1;s<u;s++,f=0)f&&i.length&&o(a[s],"outOfRange"),o(a[s],"inRange");for(var f=1;l<c;l++)(!a.length||a[a.length-1]<n[l])&&(f&&(i.length&&o(i[i.length-1].value,"outOfRange"),f=0),o(n[l],"outOfRange"));var h=i.length;return{stops:i,outerColors:[h?i[0].color:"transparent",h?i[h-1].color:"transparent"]}},e.type="visualMap.continuous",e.defaultOption=co(Sg.defaultOption,{align:"auto",calculable:!1,hoverLink:!0,realtime:!0,handleIcon:"path://M-11.39,9.77h0a3.5,3.5,0,0,1-3.5,3.5h-22a3.5,3.5,0,0,1-3.5-3.5h0a3.5,3.5,0,0,1,3.5-3.5h22A3.5,3.5,0,0,1-11.39,9.77Z",handleSize:"120%",handleStyle:{borderColor:"#fff",borderWidth:1},indicatorIcon:"circle",indicatorSize:"50%",indicatorStyle:{borderColor:"#fff",borderWidth:2,shadowBlur:2,shadowOffsetX:1,shadowOffsetY:1,shadowColor:"rgba(0,0,0,0.2)"}}),e}(Sg);function oR(r,e,t){if(t[0]===t[1])return t.slice();for(var n=200,a=(t[1]-t[0])/n,i=t[0],o=[],s=0;s<=n&&i<t[1];s++)o.push(i),i+=a;return o.push(t[1]),o}var Tse=Ise,Ase=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.autoPositionValues={left:1,right:1,top:1,bottom:1},t}return e.prototype.init=function(t,n){this.ecModel=t,this.api=n},e.prototype.render=function(t,n,a,i){if(this.visualMapModel=t,t.get("show")===!1){this.group.removeAll();return}this.doRender(t,n,a,i)},e.prototype.renderBackground=function(t){var n=this.visualMapModel,a=xs(n.get("padding")||0),i=t.getBoundingRect();t.add(new We({z2:-1,silent:!0,shape:{x:i.x-a[3],y:i.y-a[0],width:i.width+a[3]+a[1],height:i.height+a[0]+a[2]},style:{fill:n.get("backgroundColor"),stroke:n.get("borderColor"),lineWidth:n.get("borderWidth")}}))},e.prototype.getControllerVisual=function(t,n,a){a=a||{};var i=a.forceState,o=this.visualMapModel,s={};if(n==="color"){var l=o.get("contentColor");s.color=l}function u(v){return s[v]}function c(v,d){s[v]=d}var f=o.controllerVisuals[i||o.getValueState(t)],h=Sr.prepareVisualTypes(f);return C(h,function(v){var d=f[v];a.convertOpacityToAlpha&&v==="opacity"&&(v="colorAlpha",d=f.__alphaForOpacity),Sr.dependsOn(v,n)&&d&&d.applyVisual(t,u,c)}),s[n]},e.prototype.positionGroup=function(t){var n=this.visualMapModel,a=this.api;Vd(t,n.getBoxLayoutParams(),{width:a.getWidth(),height:a.getHeight()})},e.prototype.doRender=function(t,n,a,i){},e.type="visualMap",e}(St),sR=Ase,lR=[["left","right","width"],["top","bottom","height"]];function uR(r,e,t){var n=r.option,a=n.align;if(a!=null&&a!=="auto")return a;for(var i={width:e.getWidth(),height:e.getHeight()},o=n.orient==="horizontal"?1:0,s=lR[o],l=[0,null,10],u={},c=0;c<3;c++)u[lR[1-o][c]]=l[c],u[s[c]]=c===2?t[0]:n[s[c]];var f=[["x","width",3],["y","height",0]][o],h=Yt(u,i,n.padding);return s[(h.margin[f[2]]||0)+h[f[0]]+h[f[1]]*.5<i[f[1]]*.5?0:1]}function Ig(r,e){return C(r||[],function(t){t.dataIndex!=null&&(t.dataIndexInside=t.dataIndex,t.dataIndex=null),t.highlightKey="visualMap"+(e?e.componentIndex:"")}),r}var Ja=st,Cse=C,cR=Math.min,Wx=Math.max,Nse=12,Lse=6,Ese=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._shapes={},t._dataInterval=[],t._handleEnds=[],t._hoverLinkDataIndices=[],t}return e.prototype.doRender=function(t,n,a,i){this._api=a,(!i||i.type!=="selectDataRange"||i.from!==this.uid)&&this._buildView()},e.prototype._buildView=function(){this.group.removeAll();var t=this.visualMapModel,n=this.group;this._orient=t.get("orient"),this._useHandle=t.get("calculable"),this._resetInterval(),this._renderBar(n);var a=t.get("text");this._renderEndsText(n,a,0),this._renderEndsText(n,a,1),this._updateView(!0),this.renderBackground(n),this._updateView(),this._enableHoverLinkToSeries(),this._enableHoverLinkFromSeries(),this.positionGroup(n)},e.prototype._renderEndsText=function(t,n,a){if(!!n){var i=n[1-a];i=i!=null?i+"":"";var o=this.visualMapModel,s=o.get("textGap"),l=o.itemSize,u=this._shapes.mainGroup,c=this._applyTransform([l[0]/2,a===0?-s:l[1]+s],u),f=this._applyTransform(a===0?"bottom":"top",u),h=this._orient,v=this.visualMapModel.textStyleModel;this.group.add(new Ge({style:yt(v,{x:c[0],y:c[1],verticalAlign:h==="horizontal"?"middle":f,align:h==="horizontal"?f:"center",text:i})}))}},e.prototype._renderBar=function(t){var n=this.visualMapModel,a=this._shapes,i=n.itemSize,o=this._orient,s=this._useHandle,l=uR(n,this.api,i),u=a.mainGroup=this._createBarGroup(l),c=new De;u.add(c),c.add(a.outOfRange=fR()),c.add(a.inRange=fR(null,s?vR(this._orient):null,fe(this._dragHandle,this,"all",!1),fe(this._dragHandle,this,"all",!0))),c.setClipPath(new We({shape:{x:0,y:0,width:i[0],height:i[1],r:3}}));var f=n.textStyleModel.getTextRect("\u56FD"),h=Wx(f.width,f.height);s&&(a.handleThumbs=[],a.handleLabels=[],a.handleLabelPoints=[],this._createHandle(n,u,0,i,h,o),this._createHandle(n,u,1,i,h,o)),this._createIndicator(n,u,i,h,o),t.add(u)},e.prototype._createHandle=function(t,n,a,i,o,s){var l=fe(this._dragHandle,this,a,!1),u=fe(this._dragHandle,this,a,!0),c=va(t.get("handleSize"),i[0]),f=Ft(t.get("handleIcon"),-c/2,-c/2,c,c,null,!0),h=vR(this._orient);f.attr({cursor:h,draggable:!0,drift:l,ondragend:u,onmousemove:function(y){hi(y.event)}}),f.x=i[0]/2,f.useStyle(t.getModel("handleStyle").getItemStyle()),f.setStyle({strokeNoScale:!0,strokeFirst:!0}),f.style.lineWidth*=2,f.ensureState("emphasis").style=t.getModel(["emphasis","handleStyle"]).getItemStyle(),ys(f,!0),n.add(f);var v=this.visualMapModel.textStyleModel,d=new Ge({cursor:h,draggable:!0,drift:l,onmousemove:function(y){hi(y.event)},ondragend:u,style:yt(v,{x:0,y:0,text:""})});d.ensureState("blur").style={opacity:.1},d.stateTransition={duration:200},this.group.add(d);var p=[c,0],g=this._shapes;g.handleThumbs[a]=f,g.handleLabelPoints[a]=p,g.handleLabels[a]=d},e.prototype._createIndicator=function(t,n,a,i,o){var s=va(t.get("indicatorSize"),a[0]),l=Ft(t.get("indicatorIcon"),-s/2,-s/2,s,s,null,!0);l.attr({cursor:"move",invisible:!0,silent:!0,x:a[0]/2});var u=t.getModel("indicatorStyle").getItemStyle();if(l instanceof pr){var c=l.style;l.useStyle(X({image:c.image,x:c.x,y:c.y,width:c.width,height:c.height},u))}else l.useStyle(u);n.add(l);var f=this.visualMapModel.textStyleModel,h=new Ge({silent:!0,invisible:!0,style:yt(f,{x:0,y:0,text:""})});this.group.add(h);var v=[(o==="horizontal"?i/2:Lse)+a[0]/2,0],d=this._shapes;d.indicator=l,d.indicatorLabel=h,d.indicatorLabelPoint=v,this._firstShowIndicator=!0},e.prototype._dragHandle=function(t,n,a,i){if(!!this._useHandle){if(this._dragging=!n,!n){var o=this._applyTransform([a,i],this._shapes.mainGroup,!0);this._updateInterval(t,o[1]),this._hideIndicator(),this._updateView()}n===!this.visualMapModel.get("realtime")&&this.api.dispatchAction({type:"selectDataRange",from:this.uid,visualMapId:this.visualMapModel.id,selected:this._dataInterval.slice()}),n?!this._hovering&&this._clearHoverLinkToSeries():hR(this.visualMapModel)&&this._doHoverLinkToSeries(this._handleEnds[t],!1)}},e.prototype._resetInterval=function(){var t=this.visualMapModel,n=this._dataInterval=t.getSelected(),a=t.getExtent(),i=[0,t.itemSize[1]];this._handleEnds=[Ja(n[0],a,i,!0),Ja(n[1],a,i,!0)]},e.prototype._updateInterval=function(t,n){n=n||0;var a=this.visualMapModel,i=this._handleEnds,o=[0,a.itemSize[1]];qs(n,i,o,t,0);var s=a.getExtent();this._dataInterval=[Ja(i[0],o,s,!0),Ja(i[1],o,s,!0)]},e.prototype._updateView=function(t){var n=this.visualMapModel,a=n.getExtent(),i=this._shapes,o=[0,n.itemSize[1]],s=t?o:this._handleEnds,l=this._createBarVisual(this._dataInterval,a,s,"inRange"),u=this._createBarVisual(a,a,o,"outOfRange");i.inRange.setStyle({fill:l.barColor}).setShape("points",l.barPoints),i.outOfRange.setStyle({fill:u.barColor}).setShape("points",u.barPoints),this._updateHandle(s,l)},e.prototype._createBarVisual=function(t,n,a,i){var o={forceState:i,convertOpacityToAlpha:!0},s=this._makeColorGradient(t,o),l=[this.getControllerVisual(t[0],"symbolSize",o),this.getControllerVisual(t[1],"symbolSize",o)],u=this._createBarPoints(a,l);return{barColor:new Zl(0,0,0,1,s),barPoints:u,handlesColor:[s[0].color,s[s.length-1].color]}},e.prototype._makeColorGradient=function(t,n){var a=100,i=[],o=(t[1]-t[0])/a;i.push({color:this.getControllerVisual(t[0],"color",n),offset:0});for(var s=1;s<a;s++){var l=t[0]+o*s;if(l>t[1])break;i.push({color:this.getControllerVisual(l,"color",n),offset:s/a})}return i.push({color:this.getControllerVisual(t[1],"color",n),offset:1}),i},e.prototype._createBarPoints=function(t,n){var a=this.visualMapModel.itemSize;return[[a[0]-n[0],t[0]],[a[0],t[0]],[a[0],t[1]],[a[0]-n[1],t[1]]]},e.prototype._createBarGroup=function(t){var n=this._orient,a=this.visualMapModel.get("inverse");return new De(n==="horizontal"&&!a?{scaleX:t==="bottom"?1:-1,rotation:Math.PI/2}:n==="horizontal"&&a?{scaleX:t==="bottom"?-1:1,rotation:-Math.PI/2}:n==="vertical"&&!a?{scaleX:t==="left"?1:-1,scaleY:-1}:{scaleX:t==="left"?1:-1})},e.prototype._updateHandle=function(t,n){if(!!this._useHandle){var a=this._shapes,i=this.visualMapModel,o=a.handleThumbs,s=a.handleLabels,l=i.itemSize,u=i.getExtent();Cse([0,1],function(c){var f=o[c];f.setStyle("fill",n.handlesColor[c]),f.y=t[c];var h=Ja(t[c],[0,l[1]],u,!0),v=this.getControllerVisual(h,"symbolSize");f.scaleX=f.scaleY=v/l[0],f.x=l[0]-v/2;var d=ma(a.handleLabelPoints[c],lo(f,this.group));s[c].setStyle({x:d[0],y:d[1],text:i.formatValueText(this._dataInterval[c]),verticalAlign:"middle",align:this._orient==="vertical"?this._applyTransform("left",a.mainGroup):"center"})},this)}},e.prototype._showIndicator=function(t,n,a,i){var o=this.visualMapModel,s=o.getExtent(),l=o.itemSize,u=[0,l[1]],c=this._shapes,f=c.indicator;if(!!f){f.attr("invisible",!1);var h={convertOpacityToAlpha:!0},v=this.getControllerVisual(t,"color",h),d=this.getControllerVisual(t,"symbolSize"),p=Ja(t,s,u,!0),g=l[0]-d/2,y={x:f.x,y:f.y};f.y=p,f.x=g;var m=ma(c.indicatorLabelPoint,lo(f,this.group)),_=c.indicatorLabel;_.attr("invisible",!1);var b=this._applyTransform("left",c.mainGroup),x=this._orient,M=x==="horizontal";_.setStyle({text:(a||"")+o.formatValueText(n),verticalAlign:M?b:"middle",align:M?"center":b});var w={x:g,y:p,style:{fill:v}},D={style:{x:m[0],y:m[1]}};if(o.ecModel.isAnimationEnabled()&&!this._firstShowIndicator){var T={duration:100,easing:"cubicInOut",additive:!0};f.x=y.x,f.y=y.y,f.animateTo(w,T),_.animateTo(D,T)}else f.attr(w),_.attr(D);this._firstShowIndicator=!1;var I=this._shapes.handleLabels;if(I)for(var A=0;A<I.length;A++)this._api.enterBlur(I[A])}},e.prototype._enableHoverLinkToSeries=function(){var t=this;this._shapes.mainGroup.on("mousemove",function(n){if(t._hovering=!0,!t._dragging){var a=t.visualMapModel.itemSize,i=t._applyTransform([n.offsetX,n.offsetY],t._shapes.mainGroup,!0,!0);i[1]=cR(Wx(0,i[1]),a[1]),t._doHoverLinkToSeries(i[1],0<=i[0]&&i[0]<=a[0])}}).on("mouseout",function(){t._hovering=!1,!t._dragging&&t._clearHoverLinkToSeries()})},e.prototype._enableHoverLinkFromSeries=function(){var t=this.api.getZr();this.visualMapModel.option.hoverLink?(t.on("mouseover",this._hoverLinkFromSeriesMouseOver,this),t.on("mouseout",this._hideIndicator,this)):this._clearHoverLinkFromSeries()},e.prototype._doHoverLinkToSeries=function(t,n){var a=this.visualMapModel,i=a.itemSize;if(!!a.option.hoverLink){var o=[0,i[1]],s=a.getExtent();t=cR(Wx(o[0],t),o[1]);var l=Ose(a,s,o),u=[t-l,t+l],c=Ja(t,o,s,!0),f=[Ja(u[0],o,s,!0),Ja(u[1],o,s,!0)];u[0]<o[0]&&(f[0]=-1/0),u[1]>o[1]&&(f[1]=1/0),n&&(f[0]===-1/0?this._showIndicator(c,f[1],"< ",l):f[1]===1/0?this._showIndicator(c,f[0],"> ",l):this._showIndicator(c,c,"\u2248 ",l));var h=this._hoverLinkDataIndices,v=[];(n||hR(a))&&(v=this._hoverLinkDataIndices=a.findTargetDataIndices(f));var d=lW(h,v);this._dispatchHighDown("downplay",Ig(d[0],a)),this._dispatchHighDown("highlight",Ig(d[1],a))}},e.prototype._hoverLinkFromSeriesMouseOver=function(t){var n;if(Cs(t.target,function(l){var u=Te(l);if(u.dataIndex!=null)return n=u,!0},!0),!!n){var a=this.ecModel.getSeriesByIndex(n.seriesIndex),i=this.visualMapModel;if(!!i.isTargetSeries(a)){var o=a.getData(n.dataType),s=o.getStore().get(i.getDataDimensionIndex(o),n.dataIndex);isNaN(s)||this._showIndicator(s,s)}}},e.prototype._hideIndicator=function(){var t=this._shapes;t.indicator&&t.indicator.attr("invisible",!0),t.indicatorLabel&&t.indicatorLabel.attr("invisible",!0);var n=this._shapes.handleLabels;if(n)for(var a=0;a<n.length;a++)this._api.leaveBlur(n[a])},e.prototype._clearHoverLinkToSeries=function(){this._hideIndicator();var t=this._hoverLinkDataIndices;this._dispatchHighDown("downplay",Ig(t,this.visualMapModel)),t.length=0},e.prototype._clearHoverLinkFromSeries=function(){this._hideIndicator();var t=this.api.getZr();t.off("mouseover",this._hoverLinkFromSeriesMouseOver),t.off("mouseout",this._hideIndicator)},e.prototype._applyTransform=function(t,n,a,i){var o=lo(n,i?null:this.group);return J(t)?ma(t,o,a):Cd(t,o,a)},e.prototype._dispatchHighDown=function(t,n){n&&n.length&&this.api.dispatchAction({type:t,batch:n})},e.prototype.dispose=function(){this._clearHoverLinkFromSeries(),this._clearHoverLinkToSeries()},e.prototype.remove=function(){this._clearHoverLinkFromSeries(),this._clearHoverLinkToSeries()},e.type="visualMap.continuous",e}(sR);function fR(r,e,t,n){return new qr({shape:{points:r},draggable:!!t,cursor:e,drift:t,onmousemove:function(a){hi(a.event)},ondragend:n})}function Ose(r,e,t){var n=Nse/2,a=r.get("hoverLinkDataSize");return a&&(n=Ja(a,e,t,!0)/2),n}function hR(r){var e=r.get("hoverLinkOnHandle");return!!(e==null?r.get("realtime"):e)}function vR(r){return r==="vertical"?"ns-resize":"ew-resize"}var Pse=Ese,zse={type:"selectDataRange",event:"dataRangeSelected",update:"update"},kse=function(r,e){e.eachComponent({mainType:"visualMap",query:r},function(t){t.setSelected(r.selected)})},Rse=[{createOnAllSeries:!0,reset:function(r,e){var t=[];return e.eachComponent("visualMap",function(n){var a=r.pipelineContext;!n.isTargetSeries(r)||a&&a.large||t.push(Lie(n.stateList,n.targetVisuals,fe(n.getValueState,n),n.getDataDimensionIndex(r.getData())))}),t}},{createOnAllSeries:!0,reset:function(r,e){var t=r.getData(),n=[];e.eachComponent("visualMap",function(a){if(a.isTargetSeries(r)){var i=a.getVisualMeta(fe(jse,null,r,a))||{stops:[],outerColors:[]},o=a.getDataDimensionIndex(t);o>=0&&(i.dimension=o,n.push(i))}}),r.getData().setVisual("visualMeta",n)}}];function jse(r,e,t,n){for(var a=e.targetVisuals[n],i=Sr.prepareVisualTypes(a),o={color:Sf(r.getData(),"color")},s=0,l=i.length;s<l;s++){var u=i[s],c=a[u==="opacity"?"__alphaForOpacity":u];c&&c.applyVisual(t,f,h)}return o.color;function f(v){return o[v]}function h(v,d){o[v]=d}}var dR=C;function Bse(r){var e=r&&r.visualMap;J(e)||(e=e?[e]:[]),dR(e,function(t){if(!!t){Bu(t,"splitList")&&!Bu(t,"pieces")&&(t.pieces=t.splitList,delete t.splitList);var n=t.pieces;n&&J(n)&&dR(n,function(a){_e(a)&&(Bu(a,"start")&&!Bu(a,"min")&&(a.min=a.start),Bu(a,"end")&&!Bu(a,"max")&&(a.max=a.end))})}})}function Bu(r,e){return r&&r.hasOwnProperty&&r.hasOwnProperty(e)}var pR=!1;function gR(r){pR||(pR=!0,r.registerSubTypeDefaulter("visualMap",function(e){return!e.categories&&(!(e.pieces?e.pieces.length>0:e.splitNumber>0)||e.calculable)?"continuous":"piecewise"}),r.registerAction(zse,kse),C(Rse,function(e){r.registerVisual(r.PRIORITY.VISUAL.COMPONENT,e)}),r.registerPreprocessor(Bse))}function yR(r){r.registerComponentModel(Tse),r.registerComponentView(Pse),gR(r)}var Fse=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._pieceList=[],t}return e.prototype.optionUpdated=function(t,n){r.prototype.optionUpdated.apply(this,arguments),this.resetExtent();var a=this._mode=this._determineMode();this._pieceList=[],Vse[this._mode].call(this,this._pieceList),this._resetSelected(t,n);var i=this.option.categories;this.resetVisual(function(o,s){a==="categories"?(o.mappingMethod="category",o.categories=Me(i)):(o.dataExtent=this.getExtent(),o.mappingMethod="piecewise",o.pieceList=K(this._pieceList,function(l){return l=Me(l),s!=="inRange"&&(l.visual=null),l}))})},e.prototype.completeVisualOption=function(){var t=this.option,n={},a=Sr.listVisualTypes(),i=this.isCategory();C(t.pieces,function(s){C(a,function(l){s.hasOwnProperty(l)&&(n[l]=1)})}),C(n,function(s,l){var u=!1;C(this.stateList,function(c){u=u||o(t,c,l)||o(t.target,c,l)},this),!u&&C(this.stateList,function(c){(t[c]||(t[c]={}))[l]=rR.get(l,c==="inRange"?"active":"inactive",i)})},this);function o(s,l,u){return s&&s[l]&&s[l].hasOwnProperty(u)}r.prototype.completeVisualOption.apply(this,arguments)},e.prototype._resetSelected=function(t,n){var a=this.option,i=this._pieceList,o=(n?a:t).selected||{};if(a.selected=o,C(i,function(l,u){var c=this.getSelectedMapKey(l);o.hasOwnProperty(c)||(o[c]=!0)},this),a.selectedMode==="single"){var s=!1;C(i,function(l,u){var c=this.getSelectedMapKey(l);o[c]&&(s?o[c]=!1:s=!0)},this)}},e.prototype.getItemSymbol=function(){return this.get("itemSymbol")},e.prototype.getSelectedMapKey=function(t){return this._mode==="categories"?t.value+"":t.index+""},e.prototype.getPieceList=function(){return this._pieceList},e.prototype._determineMode=function(){var t=this.option;return t.pieces&&t.pieces.length>0?"pieces":this.option.categories?"categories":"splitNumber"},e.prototype.setSelected=function(t){this.option.selected=Me(t)},e.prototype.getValueState=function(t){var n=Sr.findPieceIndex(t,this._pieceList);return n!=null&&this.option.selected[this.getSelectedMapKey(this._pieceList[n])]?"inRange":"outOfRange"},e.prototype.findTargetDataIndices=function(t){var n=[],a=this._pieceList;return this.eachTargetSeries(function(i){var o=[],s=i.getData();s.each(this.getDataDimensionIndex(s),function(l,u){var c=Sr.findPieceIndex(l,a);c===t&&o.push(u)},this),n.push({seriesId:i.id,dataIndex:o})},this),n},e.prototype.getRepresentValue=function(t){var n;if(this.isCategory())n=t.value;else if(t.value!=null)n=t.value;else{var a=t.interval||[];n=a[0]===-1/0&&a[1]===1/0?0:(a[0]+a[1])/2}return n},e.prototype.getVisualMeta=function(t){if(this.isCategory())return;var n=[],a=["",""],i=this;function o(c,f){var h=i.getRepresentValue({interval:c});f||(f=i.getValueState(h));var v=t(h,f);c[0]===-1/0?a[0]=v:c[1]===1/0?a[1]=v:n.push({value:c[0],color:v},{value:c[1],color:v})}var s=this._pieceList.slice();if(!s.length)s.push({interval:[-1/0,1/0]});else{var l=s[0].interval[0];l!==-1/0&&s.unshift({interval:[-1/0,l]}),l=s[s.length-1].interval[1],l!==1/0&&s.push({interval:[l,1/0]})}var u=-1/0;return C(s,function(c){var f=c.interval;f&&(f[0]>u&&o([u,f[0]],"outOfRange"),o(f.slice()),u=f[1])},this),{stops:n,outerColors:a}},e.type="visualMap.piecewise",e.defaultOption=co(Sg.defaultOption,{selected:null,minOpen:!1,maxOpen:!1,align:"auto",itemWidth:20,itemHeight:14,itemSymbol:"roundRect",pieces:null,categories:null,splitNumber:5,selectedMode:"multiple",itemGap:10,hoverLink:!0}),e}(Sg),Vse={splitNumber:function(r){var e=this.option,t=Math.min(e.precision,20),n=this.getExtent(),a=e.splitNumber;a=Math.max(parseInt(a,10),1),e.splitNumber=a;for(var i=(n[1]-n[0])/a;+i.toFixed(t)!==i&&t<5;)t++;e.precision=t,i=+i.toFixed(t),e.minOpen&&r.push({interval:[-1/0,n[0]],close:[0,0]});for(var o=0,s=n[0];o<a;s+=i,o++){var l=o===a-1?n[1]:s+i;r.push({interval:[s,l],close:[1,1]})}e.maxOpen&&r.push({interval:[n[1],1/0],close:[0,0]}),T0(r),C(r,function(u,c){u.index=c,u.text=this.formatValueText(u.interval)},this)},categories:function(r){var e=this.option;C(e.categories,function(t){r.push({text:this.formatValueText(t,!0),value:t})},this),mR(e,r)},pieces:function(r){var e=this.option;C(e.pieces,function(t,n){_e(t)||(t={value:t});var a={text:"",index:n};if(t.label!=null&&(a.text=t.label),t.hasOwnProperty("value")){var i=a.value=t.value;a.interval=[i,i],a.close=[1,1]}else{for(var o=a.interval=[],s=a.close=[0,0],l=[1,0,1],u=[-1/0,1/0],c=[],f=0;f<2;f++){for(var h=[["gte","gt","min"],["lte","lt","max"]][f],v=0;v<3&&o[f]==null;v++)o[f]=t[h[v]],s[f]=l[v],c[f]=v===2;o[f]==null&&(o[f]=u[f])}c[0]&&o[1]===1/0&&(s[0]=0),c[1]&&o[0]===-1/0&&(s[1]=0),o[0]===o[1]&&s[0]&&s[1]&&(a.value=o[0])}a.visual=Sr.retrieveVisuals(t),r.push(a)},this),mR(e,r),T0(r),C(r,function(t){var n=t.close,a=[["<","\u2264"][n[1]],[">","\u2265"][n[0]]];t.text=t.text||this.formatValueText(t.value!=null?t.value:t.interval,!1,a)},this)}};function mR(r,e){var t=r.inverse;(r.orient==="vertical"?!t:t)&&e.reverse()}var Hse=Fse,Wse=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.doRender=function(){var t=this.group;t.removeAll();var n=this.visualMapModel,a=n.get("textGap"),i=n.textStyleModel,o=i.getFont(),s=i.getTextColor(),l=this._getItemAlign(),u=n.itemSize,c=this._getViewData(),f=c.endsText,h=ar(n.get("showLabel",!0),!f);f&&this._renderEndsText(t,f[0],u,h,l),C(c.viewPieceList,function(v){var d=v.piece,p=new De;p.onclick=fe(this._onItemClick,this,d),this._enableHoverLink(p,v.indexInModelPieceList);var g=n.getRepresentValue(d);if(this._createItemSymbol(p,g,[0,0,u[0],u[1]]),h){var y=this.visualMapModel.getValueState(g);p.add(new Ge({style:{x:l==="right"?-a:u[0]+a,y:u[1]/2,text:d.text,verticalAlign:"middle",align:l,font:o,fill:s,opacity:y==="outOfRange"?.5:1}}))}t.add(p)},this),f&&this._renderEndsText(t,f[1],u,h,l),Ss(n.get("orient"),t,n.get("itemGap")),this.renderBackground(t),this.positionGroup(t)},e.prototype._enableHoverLink=function(t,n){var a=this;t.on("mouseover",function(){return i("highlight")}).on("mouseout",function(){return i("downplay")});var i=function(o){var s=a.visualMapModel;s.option.hoverLink&&a.api.dispatchAction({type:o,batch:Ig(s.findTargetDataIndices(n),s)})}},e.prototype._getItemAlign=function(){var t=this.visualMapModel,n=t.option;if(n.orient==="vertical")return uR(t,this.api,t.itemSize);var a=n.align;return(!a||a==="auto")&&(a="left"),a},e.prototype._renderEndsText=function(t,n,a,i,o){if(!!n){var s=new De,l=this.visualMapModel.textStyleModel;s.add(new Ge({style:yt(l,{x:i?o==="right"?a[0]:0:a[0]/2,y:a[1]/2,verticalAlign:"middle",align:i?o:"center",text:n})})),t.add(s)}},e.prototype._getViewData=function(){var t=this.visualMapModel,n=K(t.getPieceList(),function(s,l){return{piece:s,indexInModelPieceList:l}}),a=t.get("text"),i=t.get("orient"),o=t.get("inverse");return(i==="horizontal"?o:!o)?n.reverse():a&&(a=a.slice().reverse()),{viewPieceList:n,endsText:a}},e.prototype._createItemSymbol=function(t,n,a){t.add(Ft(this.getControllerVisual(n,"symbol"),a[0],a[1],a[2],a[3],this.getControllerVisual(n,"color")))},e.prototype._onItemClick=function(t){var n=this.visualMapModel,a=n.option,i=a.selectedMode;if(!!i){var o=Me(a.selected),s=n.getSelectedMapKey(t);i==="single"||i===!0?(o[s]=!0,C(o,function(l,u){o[u]=u===s})):o[s]=!o[s],this.api.dispatchAction({type:"selectDataRange",from:this.uid,visualMapId:this.visualMapModel.id,selected:o})}},e.type="visualMap.piecewise",e}(sR),Gse=Wse;function _R(r){r.registerComponentModel(Hse),r.registerComponentView(Gse),gR(r)}function $se(r){Re(yR),Re(_R)}var Use={label:{enabled:!0},decal:{show:!1}},bR=Ye(),Yse={};function Qse(r,e){var t=r.getModel("aria");if(!t.get("enabled"))return;var n=Me(Use);Ne(n.label,r.getLocaleModel().get("aria"),!1),Ne(t.option,n,!1),a(),i();function a(){var u=t.getModel("decal"),c=u.get("show");if(c){var f=ge();r.eachSeries(function(h){if(!h.isColorBySeries()){var v=f.get(h.type);v||(v={},f.set(h.type,v)),bR(h).scope=v}}),r.eachRawSeries(function(h){if(r.isSeriesFiltered(h))return;if(ye(h.enableAriaDecal)){h.enableAriaDecal();return}var v=h.getData();if(h.isColorBySeries()){var m=j1(h.ecModel,h.name,Yse,r.getSeriesCount()),_=v.getVisual("decal");v.setVisual("decal",b(_,m))}else{var d=h.getRawData(),p={},g=bR(h).scope;v.each(function(x){var M=v.getRawIndex(x);p[M]=x});var y=d.count();d.each(function(x){var M=p[x],w=d.getName(x)||x+"",D=j1(h.ecModel,w,g,y),T=v.getItemVisual(M,"decal");v.setItemVisual(M,"decal",b(T,D))})}function b(x,M){var w=x?X(X({},M),x):M;return w.dirty=!0,w}})}}function i(){var u=r.getLocaleModel().get("aria"),c=t.getModel("label");if(c.option=me(c.option,u),!!c.get("enabled")){var f=e.getZr().dom;if(c.get("description")){f.setAttribute("aria-label",c.get("description"));return}var h=r.getSeriesCount(),v=c.get(["data","maxCount"])||10,d=c.get(["series","maxCount"])||10,p=Math.min(h,d),g;if(!(h<1)){var y=s();if(y){var m=c.get(["general","withTitle"]);g=o(m,{title:y})}else g=c.get(["general","withoutTitle"]);var _=[],b=h>1?c.get(["series","multiple","prefix"]):c.get(["series","single","prefix"]);g+=o(b,{seriesCount:h}),r.eachSeries(function(D,T){if(T<p){var I=void 0,A=D.get("name"),N=A?"withName":"withoutName";I=h>1?c.get(["series","multiple",N]):c.get(["series","single",N]),I=o(I,{seriesId:D.seriesIndex,seriesName:D.get("name"),seriesType:l(D.subType)});var L=D.getData();if(L.count()>v){var E=c.get(["data","partialData"]);I+=o(E,{displayCnt:v})}else I+=c.get(["data","allData"]);for(var O=c.get(["data","separator","middle"]),P=c.get(["data","separator","end"]),H=[],F=0;F<L.count();F++)if(F<v){var G=L.getName(F),Z=L.getValues(F),te=c.get(["data",G?"withName":"withoutName"]);H.push(o(te,{name:G,value:Z.join(O)}))}I+=H.join(O)+P,_.push(I)}});var x=c.getModel(["series","multiple","separator"]),M=x.get("middle"),w=x.get("end");g+=_.join(M)+w,f.setAttribute("aria-label",g)}}}function o(u,c){if(!ce(u))return u;var f=u;return C(c,function(h,v){f=f.replace(new RegExp("\\{\\s*"+v+"\\s*\\}","g"),h)}),f}function s(){var u=r.get("title");return u&&u.length&&(u=u[0]),u&&u.text}function l(u){return r.getLocaleModel().get(["series","typeNames"])[u]||"\u81EA\u5B9A\u4E49\u56FE"}}function Zse(r){if(!(!r||!r.aria)){var e=r.aria;e.show!=null&&(e.enabled=e.show),e.label=e.label||{},C(["description","general","series","data"],function(t){e[t]!=null&&(e.label[t]=e[t])})}}function qse(r){r.registerPreprocessor(Zse),r.registerVisual(r.PRIORITY.VISUAL.ARIA,Qse)}var MR={value:"eq","<":"lt","<=":"lte",">":"gt",">=":"gte","=":"eq","!=":"ne","<>":"ne"},Xse=function(){function r(e){var t=this._condVal=ce(e)?new RegExp(e):VS(e)?e:null;if(t==null){var n="";at(n)}}return r.prototype.evaluate=function(e){var t=typeof e;return ce(t)?this._condVal.test(e):Ue(t)?this._condVal.test(e+""):!1},r}(),Jse=function(){function r(){}return r.prototype.evaluate=function(){return this.value},r}(),Kse=function(){function r(){}return r.prototype.evaluate=function(){for(var e=this.children,t=0;t<e.length;t++)if(!e[t].evaluate())return!1;return!0},r}(),ele=function(){function r(){}return r.prototype.evaluate=function(){for(var e=this.children,t=0;t<e.length;t++)if(e[t].evaluate())return!0;return!1},r}(),tle=function(){function r(){}return r.prototype.evaluate=function(){return!this.child.evaluate()},r}(),rle=function(){function r(){}return r.prototype.evaluate=function(){for(var e=!!this.valueParser,t=this.getValue,n=t(this.valueGetterParam),a=e?this.valueParser(n):null,i=0;i<this.subCondList.length;i++)if(!this.subCondList[i].evaluate(e?a:n))return!1;return!0},r}();function Gx(r,e){if(r===!0||r===!1){var t=new Jse;return t.value=r,t}var n="";return wR(r)||at(n),r.and?xR("and",r,e):r.or?xR("or",r,e):r.not?nle(r,e):ale(r,e)}function xR(r,e,t){var n=e[r],a="";J(n)||at(a),n.length||at(a);var i=r==="and"?new Kse:new ele;return i.children=K(n,function(o){return Gx(o,t)}),i.children.length||at(a),i}function nle(r,e){var t=r.not,n="";wR(t)||at(n);var a=new tle;return a.child=Gx(t,e),a.child||at(n),a}function ale(r,e){for(var t="",n=e.prepareGetValue(r),a=[],i=Fe(r),o=r.parser,s=o?XC(o):null,l=0;l<i.length;l++){var u=i[l];if(!(u==="parser"||e.valueGetterAttrMap.get(u))){var c=ve(MR,u)?MR[u]:u,f=r[u],h=s?s(f):f,v=MU(c,h)||c==="reg"&&new Xse(h);v||at(t),a.push(v)}}a.length||at(t);var d=new rle;return d.valueGetterParam=n,d.valueParser=s,d.getValue=e.getValue,d.subCondList=a,d}function wR(r){return _e(r)&&!Mr(r)}var ile=function(){function r(e,t){this._cond=Gx(e,t)}return r.prototype.evaluate=function(){return this._cond.evaluate()},r}();function ole(r,e){return new ile(r,e)}var sle={type:"echarts:filter",transform:function(r){for(var e=r.upstream,t,n=ole(r.config,{valueGetterAttrMap:ge({dimension:!0}),prepareGetValue:function(s){var l="",u=s.dimension;ve(s,"dimension")||at(l);var c=e.getDimensionInfo(u);return c||at(l),{dimIdx:c.index}},getValue:function(s){return e.retrieveValueFromItem(t,s.dimIdx)}}),a=[],i=0,o=e.count();i<o;i++)t=e.getRawDataItem(i),n.evaluate()&&a.push(t);return{data:a}}},lle={type:"echarts:sort",transform:function(r){var e=r.upstream,t=r.config,n="",a=ct(t);a.length||at(n);var i=[];C(a,function(c){var f=c.dimension,h=c.order,v=c.parser,d=c.incomparable;if(f==null&&at(n),h!=="asc"&&h!=="desc"&&at(n),d&&d!=="min"&&d!=="max"){var p="";at(p)}if(h!=="asc"&&h!=="desc"){var g="";at(g)}var y=e.getDimensionInfo(f);y||at(n);var m=v?XC(v):null;v&&!m&&at(n),i.push({dimIdx:y.index,parser:m,comparator:new KC(h,d)})});var o=e.sourceFormat;o!==zr&&o!==Gn&&at(n);for(var s=[],l=0,u=e.count();l<u;l++)s.push(e.getRawDataItem(l));return s.sort(function(c,f){for(var h=0;h<i.length;h++){var v=i[h],d=e.retrieveValueFromItem(c,v.dimIdx),p=e.retrieveValueFromItem(f,v.dimIdx);v.parser&&(d=v.parser(d),p=v.parser(p));var g=v.comparator.evaluate(d,p);if(g!==0)return g}return 0}),{data:s}}};function ule(r){r.registerTransform(sle),r.registerTransform(lle)}var cle=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="dataset",t}return e.prototype.init=function(t,n,a){r.prototype.init.call(this,t,n,a),this._sourceManager=new iN(this),oN(this)},e.prototype.mergeOption=function(t,n){r.prototype.mergeOption.call(this,t,n),oN(this)},e.prototype.optionUpdated=function(){this._sourceManager.dirty()},e.prototype.getSourceManager=function(){return this._sourceManager},e.type="dataset",e.defaultOption={seriesLayoutBy:$a},e}(He),fle=function(r){U(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="dataset",t}return e.type="dataset",e}(St);function hle(r){r.registerComponentModel(cle),r.registerComponentView(fle)}var Ka=Ha.CMD;function Fu(r,e){return Math.abs(r-e)<1e-5}function $x(r){var e=r.data,t=r.len(),n=[],a,i=0,o=0,s=0,l=0;function u(L,E){a&&a.length>2&&n.push(a),a=[L,E]}function c(L,E,O,P){Fu(L,O)&&Fu(E,P)||a.push(L,E,O,P,O,P)}function f(L,E,O,P,H,F){var G=Math.abs(E-L),Z=Math.tan(G/4)*4/3,te=E<L?-1:1,V=Math.cos(L),Y=Math.sin(L),q=Math.cos(E),Q=Math.sin(E),ne=V*H+O,oe=Y*F+P,ie=q*H+O,he=Q*F+P,k=H*Z*te,j=F*Z*te;a.push(ne-k*Y,oe+j*V,ie+k*Q,he-j*q,ie,he)}for(var h,v,d,p,g=0;g<t;){var y=e[g++],m=g===1;switch(m&&(i=e[g],o=e[g+1],s=i,l=o,(y===Ka.L||y===Ka.C||y===Ka.Q)&&(a=[s,l])),y){case Ka.M:i=s=e[g++],o=l=e[g++],u(s,l);break;case Ka.L:h=e[g++],v=e[g++],c(i,o,h,v),i=h,o=v;break;case Ka.C:a.push(e[g++],e[g++],e[g++],e[g++],i=e[g++],o=e[g++]);break;case Ka.Q:h=e[g++],v=e[g++],d=e[g++],p=e[g++],a.push(i+2/3*(h-i),o+2/3*(v-o),d+2/3*(h-d),p+2/3*(v-p),d,p),i=d,o=p;break;case Ka.A:var _=e[g++],b=e[g++],x=e[g++],M=e[g++],w=e[g++],D=e[g++]+w;g+=1;var T=!e[g++];h=Math.cos(w)*x+_,v=Math.sin(w)*M+b,m?(s=h,l=v,u(s,l)):c(i,o,h,v),i=Math.cos(D)*x+_,o=Math.sin(D)*M+b;for(var I=(T?-1:1)*Math.PI/2,A=w;T?A>D:A<D;A+=I){var N=T?Math.max(A+I,D):Math.min(A+I,D);f(A,N,_,b,x,M)}break;case Ka.R:s=i=e[g++],l=o=e[g++],h=s+e[g++],v=l+e[g++],u(h,l),c(h,l,h,v),c(h,v,s,v),c(s,v,s,l),c(s,l,h,l);break;case Ka.Z:a&&c(i,o,s,l),i=s,o=l;break}}return a&&a.length>2&&n.push(a),n}function Ux(r,e,t,n,a,i,o,s,l,u){if(Fu(r,t)&&Fu(e,n)&&Fu(a,o)&&Fu(i,s)){l.push(o,s);return}var c=2/u,f=c*c,h=o-r,v=s-e,d=Math.sqrt(h*h+v*v);h/=d,v/=d;var p=t-r,g=n-e,y=a-o,m=i-s,_=p*p+g*g,b=y*y+m*m;if(_<f&&b<f){l.push(o,s);return}var x=h*p+v*g,M=-h*y-v*m,w=_-x*x,D=b-M*M;if(w<f&&x>=0&&D<f&&M>=0){l.push(o,s);return}var T=[],I=[];Ji(r,t,a,o,.5,T),Ji(e,n,i,s,.5,I),Ux(T[0],I[0],T[1],I[1],T[2],I[2],T[3],I[3],l,u),Ux(T[4],I[4],T[5],I[5],T[6],I[6],T[7],I[7],l,u)}function vle(r,e){var t=$x(r),n=[];e=e||1;for(var a=0;a<t.length;a++){var i=t[a],o=[],s=i[0],l=i[1];o.push(s,l);for(var u=2;u<i.length;){var c=i[u++],f=i[u++],h=i[u++],v=i[u++],d=i[u++],p=i[u++];Ux(s,l,c,f,h,v,d,p,o,e),s=d,l=p}n.push(o)}return n}function DR(r,e,t){var n=r[e],a=r[1-e],i=Math.abs(n/a),o=Math.ceil(Math.sqrt(i*t)),s=Math.floor(t/o);s===0&&(s=1,o=t);for(var l=[],u=0;u<o;u++)l.push(s);var c=o*s,f=t-c;if(f>0)for(var u=0;u<f;u++)l[u%o]+=1;return l}function SR(r,e,t){for(var n=r.r0,a=r.r,i=r.startAngle,o=r.endAngle,s=Math.abs(o-i),l=s*a,u=a-n,c=l>Math.abs(u),f=DR([l,u],c?0:1,e),h=(c?s:u)/f.length,v=0;v<f.length;v++)for(var d=(c?u:s)/f[v],p=0;p<f[v];p++){var g={};c?(g.startAngle=i+h*v,g.endAngle=i+h*(v+1),g.r0=n+d*p,g.r=n+d*(p+1)):(g.startAngle=i+d*p,g.endAngle=i+d*(p+1),g.r0=n+h*v,g.r=n+h*(v+1)),g.clockwise=r.clockwise,g.cx=r.cx,g.cy=r.cy,t.push(g)}}function dle(r,e,t){for(var n=r.width,a=r.height,i=n>a,o=DR([n,a],i?0:1,e),s=i?"width":"height",l=i?"height":"width",u=i?"x":"y",c=i?"y":"x",f=r[s]/o.length,h=0;h<o.length;h++)for(var v=r[l]/o[h],d=0;d<o[h];d++){var p={};p[u]=h*f,p[c]=d*v,p[s]=f,p[l]=v,p.x+=r.x,p.y+=r.y,t.push(p)}}function IR(r,e,t,n){return r*n-t*e}function ple(r,e,t,n,a,i,o,s){var l=t-r,u=n-e,c=o-a,f=s-i,h=IR(c,f,l,u);if(Math.abs(h)<1e-6)return null;var v=r-a,d=e-i,p=IR(v,d,c,f)/h;return p<0||p>1?null:new Oe(p*l+r,p*u+e)}function gle(r,e,t){var n=new Oe;Oe.sub(n,t,e),n.normalize();var a=new Oe;Oe.sub(a,r,e);var i=a.dot(n);return i}function Vu(r,e){var t=r[r.length-1];t&&t[0]===e[0]&&t[1]===e[1]||r.push(e)}function yle(r,e,t){for(var n=r.length,a=[],i=0;i<n;i++){var o=r[i],s=r[(i+1)%n],l=ple(o[0],o[1],s[0],s[1],e.x,e.y,t.x,t.y);l&&a.push({projPt:gle(l,e,t),pt:l,idx:i})}if(a.length<2)return[{points:r},{points:r}];a.sort(function(g,y){return g.projPt-y.projPt});var u=a[0],c=a[a.length-1];if(c.idx<u.idx){var f=u;u=c,c=f}for(var h=[u.pt.x,u.pt.y],v=[c.pt.x,c.pt.y],d=[h],p=[v],i=u.idx+1;i<=c.idx;i++)Vu(d,r[i].slice());Vu(d,v),Vu(d,h);for(var i=c.idx+1;i<=u.idx+n;i++)Vu(p,r[i%n].slice());return Vu(p,h),Vu(p,v),[{points:d},{points:p}]}function TR(r){var e=r.points,t=[],n=[];ud(e,t,n);var a=new Pe(t[0],t[1],n[0]-t[0],n[1]-t[1]),i=a.width,o=a.height,s=a.x,l=a.y,u=new Oe,c=new Oe;return i>o?(u.x=c.x=s+i/2,u.y=l,c.y=l+o):(u.y=c.y=l+o/2,u.x=s,c.x=s+i),yle(e,u,c)}function Tg(r,e,t,n){if(t===1)n.push(e);else{var a=Math.floor(t/2),i=r(e);Tg(r,i[0],a,n),Tg(r,i[1],t-a,n)}return n}function mle(r,e){for(var t=[],n=0;n<e;n++)t.push(l1(r));return t}function _le(r,e){e.setStyle(r.style),e.z=r.z,e.z2=r.z2,e.zlevel=r.zlevel}function ble(r){for(var e=[],t=0;t<r.length;)e.push([r[t++],r[t++]]);return e}function Mle(r,e){var t=[],n=r.shape,a;switch(r.type){case"rect":dle(n,e,t),a=We;break;case"sector":SR(n,e,t),a=Zr;break;case"circle":SR({r0:0,r:n.r,startAngle:0,endAngle:Math.PI*2,cx:n.cx,cy:n.cy},e,t),a=Zr;break;default:var i=r.getComputedTransform(),o=i?Math.sqrt(Math.max(i[0]*i[0]+i[1]*i[1],i[2]*i[2]+i[3]*i[3])):1,s=K(vle(r.getUpdatedPathProxy(),o),function(y){return ble(y)}),l=s.length;if(l===0)Tg(TR,{points:s[0]},e,t);else if(l===e)for(var u=0;u<l;u++)t.push({points:s[u]});else{var c=0,f=K(s,function(y){var m=[],_=[];ud(y,m,_);var b=(_[1]-m[1])*(_[0]-m[0]);return c+=b,{poly:y,area:b}});f.sort(function(y,m){return m.area-y.area});for(var h=e,u=0;u<l;u++){var v=f[u];if(h<=0)break;var d=u===l-1?h:Math.ceil(v.area/c*e);d<0||(Tg(TR,{points:v.poly},d,t),h-=d)}}a=qr;break}if(!a)return mle(r,e);for(var p=[],u=0;u<t.length;u++){var g=new a;g.setShape(t[u]),_le(r,g),p.push(g)}return p}function xle(r,e){var t=r.length,n=e.length;if(t===n)return[r,e];for(var a=[],i=[],o=t<n?r:e,s=Math.min(t,n),l=Math.abs(n-t)/6,u=(s-2)/6,c=Math.ceil(l/u)+1,f=[o[0],o[1]],h=l,v=2;v<s;){var d=o[v-2],p=o[v-1],g=o[v++],y=o[v++],m=o[v++],_=o[v++],b=o[v++],x=o[v++];if(h<=0){f.push(g,y,m,_,b,x);continue}for(var M=Math.min(h,c-1)+1,w=1;w<=M;w++){var D=w/M;Ji(d,g,m,b,D,a),Ji(p,y,_,x,D,i),d=a[3],p=i[3],f.push(a[1],i[1],a[2],i[2],d,p),g=a[5],y=i[5],m=a[6],_=i[6]}h-=M-1}return o===r?[f,e]:[r,f]}function AR(r,e){for(var t=r.length,n=r[t-2],a=r[t-1],i=[],o=0;o<e.length;)i[o++]=n,i[o++]=a;return i}function wle(r,e){for(var t,n,a,i=[],o=[],s=0;s<Math.max(r.length,e.length);s++){var l=r[s],u=e[s],c=void 0,f=void 0;l?u?(t=xle(l,u),c=t[0],f=t[1],n=c,a=f):(f=AR(a||l,l),c=l):(c=AR(n||u,u),f=u),i.push(c),o.push(f)}return[i,o]}function CR(r){for(var e=0,t=0,n=0,a=r.length,i=0,o=a-2;i<a;o=i,i+=2){var s=r[o],l=r[o+1],u=r[i],c=r[i+1],f=s*c-u*l;e+=f,t+=(s+u)*f,n+=(l+c)*f}return e===0?[r[0]||0,r[1]||0]:[t/e/3,n/e/3,e]}function Dle(r,e,t,n){for(var a=(r.length-2)/6,i=1/0,o=0,s=r.length,l=s-2,u=0;u<a;u++){for(var c=u*6,f=0,h=0;h<s;h+=2){var v=h===0?c:(c+h-2)%l+2,d=r[v]-t[0],p=r[v+1]-t[1],g=e[h]-n[0],y=e[h+1]-n[1],m=g-d,_=y-p;f+=m*m+_*_}f<i&&(i=f,o=u)}return o}function Sle(r){for(var e=[],t=r.length,n=0;n<t;n+=2)e[n]=r[t-n-2],e[n+1]=r[t-n-1];return e}function Ile(r,e,t,n){for(var a=[],i,o=0;o<r.length;o++){var s=r[o],l=e[o],u=CR(s),c=CR(l);i==null&&(i=u[2]<0!=c[2]<0);var f=[],h=[],v=0,d=1/0,p=[],g=s.length;i&&(s=Sle(s));for(var y=Dle(s,l,u,c)*6,m=g-2,_=0;_<m;_+=2){var b=(y+_)%m+2;f[_+2]=s[b]-u[0],f[_+3]=s[b+1]-u[1]}if(f[0]=s[y]-u[0],f[1]=s[y+1]-u[1],t>0)for(var x=n/t,M=-n/2;M<=n/2;M+=x){for(var w=Math.sin(M),D=Math.cos(M),T=0,_=0;_<s.length;_+=2){var I=f[_],A=f[_+1],N=l[_]-c[0],L=l[_+1]-c[1],E=N*D-L*w,O=N*w+L*D;p[_]=E,p[_+1]=O;var P=E-I,H=O-A;T+=P*P+H*H}if(T<d){d=T,v=M;for(var F=0;F<p.length;F++)h[F]=p[F]}}else for(var G=0;G<g;G+=2)h[G]=l[G]-c[0],h[G+1]=l[G+1]-c[1];a.push({from:f,to:h,fromCp:u,toCp:c,rotation:-v})}return a}function Ag(r){return r.__isCombineMorphing}var NR="__mOriginal_";function Cg(r,e,t){var n=NR+e,a=r[n]||r[e];r[n]||(r[n]=r[e]);var i=t.replace,o=t.after,s=t.before;r[e]=function(){var l=arguments,u;return s&&s.apply(this,l),i?u=i.apply(this,l):u=a.apply(this,l),o&&o.apply(this,l),u}}function xh(r,e){var t=NR+e;r[t]&&(r[e]=r[t],r[t]=null)}function LR(r,e){for(var t=0;t<r.length;t++)for(var n=r[t],a=0;a<n.length;){var i=n[a],o=n[a+1];n[a++]=e[0]*i+e[2]*o+e[4],n[a++]=e[1]*i+e[3]*o+e[5]}}function ER(r,e){var t=r.getUpdatedPathProxy(),n=e.getUpdatedPathProxy(),a=wle($x(t),$x(n)),i=a[0],o=a[1],s=r.getComputedTransform(),l=e.getComputedTransform();function u(){this.transform=null}s&&LR(i,s),l&&LR(o,l),Cg(e,"updateTransform",{replace:u}),e.transform=null;var c=Ile(i,o,10,Math.PI),f=[];Cg(e,"buildPath",{replace:function(h){for(var v=e.__morphT,d=1-v,p=[],g=0;g<c.length;g++){var y=c[g],m=y.from,_=y.to,b=y.rotation*v,x=y.fromCp,M=y.toCp,w=Math.sin(b),D=Math.cos(b);Mc(p,x,M,v);for(var T=0;T<m.length;T+=2){var I=m[T],A=m[T+1],N=_[T],L=_[T+1],E=I*d+N*v,O=A*d+L*v;f[T]=E*D-O*w+p[0],f[T+1]=E*w+O*D+p[1]}var P=f[0],H=f[1];h.moveTo(P,H);for(var T=2;T<m.length;){var N=f[T++],L=f[T++],F=f[T++],G=f[T++],Z=f[T++],te=f[T++];P===N&&H===L&&F===Z&&G===te?h.lineTo(Z,te):h.bezierCurveTo(N,L,F,G,Z,te),P=Z,H=te}}}})}function Yx(r,e,t){if(!r||!e)return e;var n=t.done,a=t.during;ER(r,e),e.__morphT=0;function i(){xh(e,"buildPath"),xh(e,"updateTransform"),e.__morphT=-1,e.createPathProxy(),e.dirtyShape()}return e.animateTo({__morphT:1},me({during:function(o){e.dirtyShape(),a&&a(o)},done:function(){i(),n&&n()}},t)),e}function Tle(r,e,t,n,a,i){var o=16;r=a===t?0:Math.round(32767*(r-t)/(a-t)),e=i===n?0:Math.round(32767*(e-n)/(i-n));for(var s=0,l,u=(1<<o)/2;u>0;u/=2){var c=0,f=0;(r&u)>0&&(c=1),(e&u)>0&&(f=1),s+=u*u*(3*c^f),f===0&&(c===1&&(r=u-1-r,e=u-1-e),l=r,r=e,e=l)}return s}function Ng(r){var e=1/0,t=1/0,n=-1/0,a=-1/0,i=K(r,function(s){var l=s.getBoundingRect(),u=s.getComputedTransform(),c=l.x+l.width/2+(u?u[4]:0),f=l.y+l.height/2+(u?u[5]:0);return e=Math.min(c,e),t=Math.min(f,t),n=Math.max(c,n),a=Math.max(f,a),[c,f]}),o=K(i,function(s,l){return{cp:s,z:Tle(s[0],s[1],e,t,n,a),path:r[l]}});return o.sort(function(s,l){return s.z-l.z}).map(function(s){return s.path})}function OR(r){return Mle(r.path,r.count)}function Qx(){return{fromIndividuals:[],toIndividuals:[],count:0}}function Ale(r,e,t){var n=[];function a(x){for(var M=0;M<x.length;M++){var w=x[M];Ag(w)?a(w.childrenRef()):w instanceof je&&n.push(w)}}a(r);var i=n.length;if(!i)return Qx();var o=t.dividePath||OR,s=o({path:e,count:i});if(s.length!==i)return console.error("Invalid morphing: unmatched splitted path"),Qx();n=Ng(n),s=Ng(s);for(var l=t.done,u=t.during,c=t.individualDelay,f=new di,h=0;h<i;h++){var v=n[h],d=s[h];d.parent=e,d.copyTransform(f),c||ER(v,d)}e.__isCombineMorphing=!0,e.childrenRef=function(){return s};function p(x){for(var M=0;M<s.length;M++)s[M].addSelfToZr(x)}Cg(e,"addSelfToZr",{after:function(x){p(x)}}),Cg(e,"removeSelfFromZr",{after:function(x){for(var M=0;M<s.length;M++)s[M].removeSelfFromZr(x)}});function g(){e.__isCombineMorphing=!1,e.__morphT=-1,e.childrenRef=null,xh(e,"addSelfToZr"),xh(e,"removeSelfFromZr")}var y=s.length;if(c)for(var m=y,_=function(){m--,m===0&&(g(),l&&l())},h=0;h<y;h++){var b=c?me({delay:(t.delay||0)+c(h,y,n[h],s[h]),done:_},t):t;Yx(n[h],s[h],b)}else e.__morphT=0,e.animateTo({__morphT:1},me({during:function(x){for(var M=0;M<y;M++){var w=s[M];w.__morphT=e.__morphT,w.dirtyShape()}u&&u(x)},done:function(){g();for(var x=0;x<r.length;x++)xh(r[x],"updateTransform");l&&l()}},t));return e.__zr&&p(e.__zr),{fromIndividuals:n,toIndividuals:s,count:y}}function Cle(r,e,t){var n=e.length,a=[],i=t.dividePath||OR;function o(v){for(var d=0;d<v.length;d++){var p=v[d];Ag(p)?o(p.childrenRef()):p instanceof je&&a.push(p)}}if(Ag(r)){o(r.childrenRef());var s=a.length;if(s<n)for(var l=0,u=s;u<n;u++)a.push(l1(a[l++%s]));a.length=n}else{a=i({path:r,count:n});for(var c=r.getComputedTransform(),u=0;u<a.length;u++)a[u].setLocalTransform(c);if(a.length!==n)return console.error("Invalid morphing: unmatched splitted path"),Qx()}a=Ng(a),e=Ng(e);for(var f=t.individualDelay,u=0;u<n;u++){var h=f?me({delay:(t.delay||0)+f(u,n,a[u],e[u])},t):t;Yx(a[u],e[u],h)}return{fromIndividuals:a,toIndividuals:e,count:e.length}}function PR(r){return J(r[0])}function zR(r,e){for(var t=[],n=r.length,a=0;a<n;a++)t.push({one:r[a],many:[]});for(var a=0;a<e.length;a++){var i=e[a].length,o=void 0;for(o=0;o<i;o++)t[o%n].many.push(e[a][o])}for(var s=0,a=n-1;a>=0;a--)if(!t[a].many.length){var l=t[s].many;if(l.length<=1)if(s)s=0;else return t;var i=l.length,u=Math.ceil(i/2);t[a].many=l.slice(u,i),t[s].many=l.slice(0,u),s++}return t}var Nle={clone:function(r){for(var e=[],t=1-Math.pow(1-r.path.style.opacity,1/r.count),n=0;n<r.count;n++){var a=l1(r.path);a.setStyle("opacity",t),e.push(a)}return e},split:null};function Zx(r,e,t,n,a,i){if(!r.length||!e.length)return;var o=ql("update",n,a);if(!(o&&o.duration>0))return;var s=n.getModel("universalTransition").get("delay"),l=Object.assign({setToFinal:!0},o),u,c;PR(r)&&(u=r,c=e),PR(e)&&(u=e,c=r);function f(y,m,_,b,x){var M=y.many,w=y.one;if(M.length===1&&!x){var D=m?M[0]:w,T=m?w:M[0];if(Ag(D))f({many:[D],one:T},!0,_,b,!0);else{var I=s?me({delay:s(_,b)},l):l;Yx(D,T,I),i(D,T,D,T,I)}}else for(var A=me({dividePath:Nle[t],individualDelay:s&&function(H,F,G,Z){return s(H+_,b)}},l),N=m?Ale(M,w,A):Cle(w,M,A),L=N.fromIndividuals,E=N.toIndividuals,O=L.length,P=0;P<O;P++){var I=s?me({delay:s(P,O)},l):l;i(L[P],E[P],m?M[P]:y.one,m?y.one:M[P],I)}}for(var h=u?u===r:r.length>e.length,v=u?zR(c,u):zR(h?e:r,[h?r:e]),d=0,p=0;p<v.length;p++)d+=v[p].many.length;for(var g=0,p=0;p<v.length;p++)f(v[p],h,g,d),g+=v[p].many.length}function rl(r){if(!r)return[];if(J(r)){for(var e=[],t=0;t<r.length;t++)e.push(rl(r[t]));return e}var n=[];return r.traverse(function(a){a instanceof je&&!a.disableMorphing&&!a.invisible&&!a.ignore&&n.push(a)}),n}var kR=1e4,Lle=Ye();function Ele(r){for(var e=r.dimensions,t=0;t<e.length;t++){var n=r.getDimensionInfo(e[t]);if(n&&n.otherDims.itemGroupId===0)return e[t]}}function RR(r){var e=[];return C(r,function(t){var n=t.data;if(!(n.count()>kR))for(var a=n.getIndices(),i=Ele(n),o=0;o<a.length;o++)e.push({dataGroupId:t.dataGroupId,data:n,dim:t.dim||i,divide:t.divide,dataIndex:o})}),e}function qx(r,e,t){r.traverse(function(n){n instanceof je&&Dt(n,{style:{opacity:0}},e,{dataIndex:t,isFrom:!0})})}function Xx(r){if(r.parent){var e=r.getComputedTransform();r.setLocalTransform(e),r.parent.remove(r)}}function Hu(r){r.stopAnimation(),r.isGroup&&r.traverse(function(e){e.stopAnimation()})}function Ole(r,e,t){var n=ql("update",t,e);n&&r.traverse(function(a){if(a instanceof Bn){var i=t$(a);i&&a.animateFrom({style:i},n)}})}function Ple(r,e){var t=r.length;if(t!==e.length)return!1;for(var n=0;n<t;n++){var a=r[n],i=e[n];if(a.data.getId(a.dataIndex)!==i.data.getId(i.dataIndex))return!1}return!0}function jR(r,e,t){var n=RR(r),a=RR(e);function i(y,m,_,b,x){(_||y)&&m.animateFrom({style:_&&_!==y?X(X({},_.style),y.style):y.style},x)}function o(y){for(var m=0;m<y.length;m++)if(y[m].dim)return y[m].dim}var s=o(n),l=o(a),u=!1;function c(y,m){return function(_){var b=_.data,x=_.dataIndex;if(m)return b.getId(x);var M=_.dataGroupId,w=y?s||l:l||s,D=w&&b.getDimensionInfo(w),T=D&&D.ordinalMeta;if(D){var I=b.get(D.name,x);return T&&T.categories[I]||I+""}var A=b.getRawDataItem(x);return A&&A.groupId?A.groupId+"":M||b.getId(x)}}var f=Ple(n,a),h={};if(!f)for(var v=0;v<a.length;v++){var d=a[v],p=d.data.getItemGraphicEl(d.dataIndex);p&&(h[p.id]=!0)}function g(y,m){var _=n[m],b=a[y],x=b.data.hostModel,M=_.data.getItemGraphicEl(_.dataIndex),w=b.data.getItemGraphicEl(b.dataIndex);if(M===w){w&&Ole(w,b.dataIndex,x);return}M&&h[M.id]||w&&(Hu(w),M?(Hu(M),Xx(M),u=!0,Zx(rl(M),rl(w),b.divide,x,y,i)):qx(w,x,y))}new Mi(n,a,c(!0,f),c(!1,f),null,"multiple").update(g).updateManyToOne(function(y,m){var _=a[y],b=_.data,x=b.hostModel,M=b.getItemGraphicEl(_.dataIndex),w=ot(K(m,function(D){return n[D].data.getItemGraphicEl(n[D].dataIndex)}),function(D){return D&&D!==M&&!h[D.id]});M&&(Hu(M),w.length?(C(w,function(D){Hu(D),Xx(D)}),u=!0,Zx(rl(w),rl(M),_.divide,x,y,i)):qx(M,x,_.dataIndex))}).updateOneToMany(function(y,m){var _=n[m],b=_.data.getItemGraphicEl(_.dataIndex);if(!(b&&h[b.id])){var x=ot(K(y,function(w){return a[w].data.getItemGraphicEl(a[w].dataIndex)}),function(w){return w&&w!==b}),M=a[y[0]].data.hostModel;x.length&&(C(x,function(w){return Hu(w)}),b?(Hu(b),Xx(b),u=!0,Zx(rl(b),rl(x),_.divide,M,y[0],i)):C(x,function(w){return qx(w,M,y[0])}))}}).updateManyToMany(function(y,m){new Mi(m,y,function(_){return n[_].data.getId(n[_].dataIndex)},function(_){return a[_].data.getId(a[_].dataIndex)}).update(function(_,b){g(y[_],m[b])}).execute()}).execute(),u&&C(e,function(y){var m=y.data,_=m.hostModel,b=_&&t.getViewOfSeriesModel(_),x=ql("update",_,0);b&&_.isAnimationEnabled()&&x&&x.duration>0&&b.group.traverse(function(M){M instanceof je&&!M.animators.length&&M.animateFrom({style:{opacity:0}},x)})})}function BR(r){var e=r.getModel("universalTransition").get("seriesKey");return e||r.id}function FR(r){return J(r)?r.sort().join(","):r}function Lo(r){if(r.hostModel)return r.hostModel.getModel("universalTransition").get("divideShape")}function zle(r,e){var t=ge(),n=ge(),a=ge();return C(r.oldSeries,function(i,o){var s=r.oldDataGroupIds[o],l=r.oldData[o],u=BR(i),c=FR(u);n.set(c,{dataGroupId:s,data:l}),J(u)&&C(u,function(f){a.set(f,{key:c,dataGroupId:s,data:l})})}),C(e.updatedSeries,function(i){if(i.isUniversalTransitionEnabled()&&i.isAnimationEnabled()){var o=i.get("dataGroupId"),s=i.getData(),l=BR(i),u=FR(l),c=n.get(u);if(c)t.set(u,{oldSeries:[{dataGroupId:c.dataGroupId,divide:Lo(c.data),data:c.data}],newSeries:[{dataGroupId:o,divide:Lo(s),data:s}]});else if(J(l)){var f=[];C(l,function(d){var p=n.get(d);p.data&&f.push({dataGroupId:p.dataGroupId,divide:Lo(p.data),data:p.data})}),f.length&&t.set(u,{oldSeries:f,newSeries:[{dataGroupId:o,data:s,divide:Lo(s)}]})}else{var h=a.get(l);if(h){var v=t.get(h.key);v||(v={oldSeries:[{dataGroupId:h.dataGroupId,data:h.data,divide:Lo(h.data)}],newSeries:[]},t.set(h.key,v)),v.newSeries.push({dataGroupId:o,data:s,divide:Lo(s)})}}}}),t}function VR(r,e){for(var t=0;t<r.length;t++){var n=e.seriesIndex!=null&&e.seriesIndex===r[t].seriesIndex||e.seriesId!=null&&e.seriesId===r[t].id;if(n)return t}}function kle(r,e,t,n){var a=[],i=[];C(ct(r.from),function(o){var s=VR(e.oldSeries,o);s>=0&&a.push({dataGroupId:e.oldDataGroupIds[s],data:e.oldData[s],divide:Lo(e.oldData[s]),dim:o.dimension})}),C(ct(r.to),function(o){var s=VR(t.updatedSeries,o);if(s>=0){var l=t.updatedSeries[s].getData();i.push({dataGroupId:e.oldDataGroupIds[s],data:l,divide:Lo(l),dim:o.dimension})}}),a.length>0&&i.length>0&&jR(a,i,n)}function Rle(r){r.registerUpdateLifecycle("series:beforeupdate",function(e,t,n){C(ct(n.seriesTransition),function(a){C(ct(a.to),function(i){for(var o=n.updatedSeries,s=0;s<o.length;s++)(i.seriesIndex!=null&&i.seriesIndex===o[s].seriesIndex||i.seriesId!=null&&i.seriesId===o[s].id)&&(o[s][Yd]=!0)})})}),r.registerUpdateLifecycle("series:transition",function(e,t,n){var a=Lle(t);if(a.oldSeries&&n.updatedSeries&&n.optionChanged){var i=n.seriesTransition;if(i)C(ct(i),function(v){kle(v,a,n,t)});else{var o=zle(a,n);C(o.keys(),function(v){var d=o.get(v);jR(d.oldSeries,d.newSeries,t)})}C(n.updatedSeries,function(v){v[Yd]&&(v[Yd]=!1)})}for(var s=e.getSeries(),l=a.oldSeries=[],u=a.oldDataGroupIds=[],c=a.oldData=[],f=0;f<s.length;f++){var h=s[f].getData();h.count()<kR&&(l.push(s[f]),u.push(s[f].get("dataGroupId")),c.push(h))}})}Re([eZ]),Re([Y8]),Re([DZ,HZ,t7,H7,i6,K6,Nq,gX,GX,KX,cJ,dK,VK,eee,bee,Tee,$ee,tte,dte,xte,zte,bre]),Re(Wre),Re(wne),Re(FO),Re(Fne),Re(l4),Re(Yne),Re(rae),Re(nie),Re(Iie),Re(vh),Re(Uie),Re(Zie),Re(coe),Re(boe),Re(Aoe),Re(koe),Re(qoe),Re(mse),Re(Xk),Re(tR),Re($se),Re(yR),Re(_R),Re(qse),Re(ule),Re(hle),Re(Rle),Re(v8);var jle=Object.freeze(Object.defineProperty({__proto__:null,registerLocale:x1,version:q9,dependencies:X9,PRIORITY:sL,init:dY,connect:pY,disConnect:xL,disconnect:gY,dispose:yY,getInstanceByDom:w_,getInstanceById:mY,registerTheme:D_,registerPreprocessor:S_,registerProcessor:I_,registerPostInit:wL,registerPostUpdate:DL,registerUpdateLifecycle:fp,registerAction:Ma,registerCoordinateSystem:SL,getCoordinateSystemDimensions:_Y,registerLayout:IL,registerVisual:yo,registerLoading:A_,setCanvasCreator:bY,registerMap:AL,getMap:MY,registerTransform:CL,dataTool:xY,throttle:qd,use:Re,setPlatformAPI:zS,parseGeoJSON:$_,parseGeoJson:$_,env:$e,Model:ft,Axis:Yn,innerDrawElementOnCanvas:l_,zrender:GH,matrix:LV,vector:pV,zrUtil:lV,color:iH,helper:CQ,number:zQ,time:kQ,graphic:RQ,format:jQ,util:BQ,List:jr,ComponentModel:He,ComponentView:St,SeriesModel:bt,ChartView:ht,extendComponentModel:qQ,extendComponentView:XQ,extendSeriesModel:JQ,extendChartView:KQ},Symbol.toStringTag,{value:"Module"})),nl={},Wu={},HR={};(function(r){Object.defineProperty(r,"__esModule",{value:!0}),r.default=void 0;var e=1,t=function(){return"".concat(e++)};r.default=t})(HR);var Lg={},Eg={},Jx={};(function(r){Object.defineProperty(r,"__esModule",{value:!0}),r.default=void 0;var e=function(n){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:60,i=null;return function(){for(var o=this,s=arguments.length,l=new Array(s),u=0;u<s;u++)l[u]=arguments[u];clearTimeout(i),i=setTimeout(function(){n.apply(o,l)},a)}};r.default=e})(Jx);var Ni={};Object.defineProperty(Ni,"__esModule",{value:!0}),Ni.SensorTabIndex=Ni.SensorClassName=Ni.SizeSensorId=void 0;var Ble="size-sensor-id";Ni.SizeSensorId=Ble;var Fle="size-sensor-object";Ni.SensorClassName=Fle;var Vle="-1";Ni.SensorTabIndex=Vle,Object.defineProperty(Eg,"__esModule",{value:!0}),Eg.createSensor=void 0;var Hle=Wle(Jx),WR=Ni;function Wle(r){return r&&r.__esModule?r:{default:r}}var Gle=function(e){var t=void 0,n=[],a=function(){getComputedStyle(e).position==="static"&&(e.style.position="relative");var c=document.createElement("object");return c.onload=function(){c.contentDocument.defaultView.addEventListener("resize",i),i()},c.style.display="block",c.style.position="absolute",c.style.top="0",c.style.left="0",c.style.height="100%",c.style.width="100%",c.style.overflow="hidden",c.style.pointerEvents="none",c.style.zIndex="-1",c.style.opacity="0",c.setAttribute("class",WR.SensorClassName),c.setAttribute("tabindex",WR.SensorTabIndex),c.type="text/html",e.appendChild(c),c.data="about:blank",c},i=(0,Hle.default)(function(){n.forEach(function(u){u(e)})}),o=function(c){t||(t=a()),n.indexOf(c)===-1&&n.push(c)},s=function(){t&&t.parentNode&&(t.contentDocument&&t.contentDocument.defaultView.removeEventListener("resize",i),t.parentNode.removeChild(t),t=void 0,n=[])},l=function(c){var f=n.indexOf(c);f!==-1&&n.splice(f,1),n.length===0&&t&&s()};return{element:e,bind:o,destroy:s,unbind:l}};Eg.createSensor=Gle;var Og={};Object.defineProperty(Og,"__esModule",{value:!0}),Og.createSensor=void 0;var $le=Ule(Jx);function Ule(r){return r&&r.__esModule?r:{default:r}}var Yle=function(e){var t=void 0,n=[],a=(0,$le.default)(function(){n.forEach(function(u){u(e)})}),i=function(){var c=new ResizeObserver(a);return c.observe(e),a(),c},o=function(c){t||(t=i()),n.indexOf(c)===-1&&n.push(c)},s=function(){t.disconnect(),n=[],t=void 0},l=function(c){var f=n.indexOf(c);f!==-1&&n.splice(f,1),n.length===0&&t&&s()};return{element:e,bind:o,destroy:s,unbind:l}};Og.createSensor=Yle,Object.defineProperty(Lg,"__esModule",{value:!0}),Lg.createSensor=void 0;var Qle=Eg,Zle=Og,qle=typeof ResizeObserver!="undefined"?Zle.createSensor:Qle.createSensor;Lg.createSensor=qle,Object.defineProperty(Wu,"__esModule",{value:!0}),Wu.removeSensor=Wu.getSensor=void 0;var Xle=Kle(HR),Jle=Lg,Pg=Ni;function Kle(r){return r&&r.__esModule?r:{default:r}}var wh={},eue=function(e){var t=e.getAttribute(Pg.SizeSensorId);if(t&&wh[t])return wh[t];var n=(0,Xle.default)();e.setAttribute(Pg.SizeSensorId,n);var a=(0,Jle.createSensor)(e);return wh[n]=a,a};Wu.getSensor=eue;var tue=function(e){var t=e.element.getAttribute(Pg.SizeSensorId);e.element.removeAttribute(Pg.SizeSensorId),e.destroy(),t&&wh[t]&&delete wh[t]};Wu.removeSensor=tue,Object.defineProperty(nl,"__esModule",{value:!0}),nl.ver=$R=nl.clear=GR=nl.bind=void 0;var Kx=Wu,rue=function(e,t){var n=(0,Kx.getSensor)(e);return n.bind(t),function(){n.unbind(t)}},GR=nl.bind=rue,nue=function(e){var t=(0,Kx.getSensor)(e);(0,Kx.removeSensor)(t)},$R=nl.clear=nue,aue="1.0.1";nl.ver=aue;function UR(r,e){var t={};return e.forEach(function(n){t[n]=r[n]}),t}function ew(r){return typeof r=="function"}function iue(r){return typeof r=="string"}var Gu=function r(e,t){if(e===t)return!0;if(e&&t&&typeof e=="object"&&typeof t=="object"){if(e.constructor!==t.constructor)return!1;var n,a,i;if(Array.isArray(e)){if(n=e.length,n!=t.length)return!1;for(a=n;a--!==0;)if(!r(e[a],t[a]))return!1;return!0}if(e.constructor===RegExp)return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===t.toString();if(i=Object.keys(e),n=i.length,n!==Object.keys(t).length)return!1;for(a=n;a--!==0;)if(!Object.prototype.hasOwnProperty.call(t,i[a]))return!1;for(a=n;a--!==0;){var o=i[a];if(!r(e[o],t[o]))return!1}return!0}return e!==e&&t!==t},oue=function(r){OS(e,r);function e(t){var n=r.call(this,t)||this;return n.echarts=t.echarts,n.ele=null,n.isInitialResize=!0,n}return e.prototype.componentDidMount=function(){this.renderNewEcharts()},e.prototype.componentDidUpdate=function(t){var n=this.props.shouldSetOption;if(!(ew(n)&&!n(t,this.props))){if(!Gu(t.theme,this.props.theme)||!Gu(t.opts,this.props.opts)||!Gu(t.onEvents,this.props.onEvents)){this.dispose(),this.renderNewEcharts();return}var a=["option","notMerge","lazyUpdate","showLoading","loadingOption"];Gu(UR(this.props,a),UR(t,a))||this.updateEChartsOption(),(!Gu(t.style,this.props.style)||!Gu(t.className,this.props.className))&&this.resize()}},e.prototype.componentWillUnmount=function(){this.dispose()},e.prototype.getEchartsInstance=function(){return this.echarts.getInstanceByDom(this.ele)||this.echarts.init(this.ele,this.props.theme,this.props.opts)},e.prototype.dispose=function(){if(this.ele){try{$R(this.ele)}catch(t){console.warn(t)}this.echarts.dispose(this.ele)}},e.prototype.renderNewEcharts=function(){var t=this,n=this.props,a=n.onEvents,i=n.onChartReady,o=this.updateEChartsOption();this.bindEvents(o,a||{}),ew(i)&&i(o),this.ele&&GR(this.ele,function(){t.resize()})},e.prototype.bindEvents=function(t,n){function a(o,s){iue(o)&&ew(s)&&t.on(o,function(l){s(l,t)})}for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&a(i,n[i])},e.prototype.updateEChartsOption=function(){var t=this.props,n=t.option,a=t.notMerge,i=a===void 0?!1:a,o=t.lazyUpdate,s=o===void 0?!1:o,l=t.showLoading,u=t.loadingOption,c=u===void 0?null:u,f=this.getEchartsInstance();return f.setOption(n,i,s),l?f.showLoading(c):f.hideLoading(),f},e.prototype.resize=function(){var t=this.getEchartsInstance();if(!this.isInitialResize)try{t.resize()}catch(n){console.warn(n)}this.isInitialResize=!1},e.prototype.render=function(){var t=this,n=this.props,a=n.style,i=n.className,o=i===void 0?"":i,s=Mm({height:300},a);return S("div",{ref:function(l){t.ele=l},style:s,className:"echarts-for-react "+o})},e}(R.PureComponent),ut=function(r){OS(e,r);function e(t){var n=r.call(this,t)||this;return n.echarts=jle,n}return e}(oue);const zg=(r,e)=>{r==="external"?window.open(e,"_blank"):window.location.replace(e)},YR=(r,e,t)=>{const{card:n}=r;switch(!0){case!n.isEnable:return;case n.dynamic==="metricId":{const a=n.route.replace("{{metric.metricId}}",e);zg(n.routeType,a);break}case n.dynamic==="uuid":{const a=n.route.replace("{{metric.uuid}}",t);zg(n.routeType,a);break}case n.dynamic==="none":{zg(n.routeType,n.route);break}default:console.warn("Unhandled click behaviour configuration");break}},Zt=(r,e)=>{if(r.isEnable){const t=r.route.replace("{{value}}",`${e}`.replace(/"/g,""));zg(r.routeType,t)}},sue=({data:r,margins:e,legendSettings:t,labelSettings:n,axisSettings:a,enableSaveAs:i,colors:o,updateGroup:s,isEnableGroupBy:l,backGroundColor:u,customSettings:c,chartClickConfig:f})=>{var v;const h={toolbox:{feature:{saveAsImage:i&&{name:"databrain"}},emphasis:{iconStyle:{borderColor:"#5865F6"}}},...o!=null&&o.length?{color:o}:{},tooltip:{trigger:"axis",backgroundColor:"black",textStyle:{color:"white"},axisPointer:{type:"cross",label:{backgroundColor:"#6a7985"}}},legend:{show:t.show,top:t.top,left:t.left,right:t.right,bottom:t.bottom,orient:t.position,data:r.datasets.map(d=>d.label)},grid:{left:`${e.marginLeft}%`,bottom:`${e.marginBottom}%`,top:`${e.marginTop}%`,right:`${e.marginRight}%`,containLabel:!0},xAxis:[{type:"category",boundaryGap:!1,data:r.labels,splitLine:{show:(c==null?void 0:c.hideSplitLines)==="horizontal"||(c==null?void 0:c.hideSplitLines)==="none"},axisLine:{show:(c==null?void 0:c.hideAxisLines)==="y"||(c==null?void 0:c.hideAxisLines)==="none"},axisLabel:{show:(c==null?void 0:c.axisLabels)==="y"||(c==null?void 0:c.axisLabels)==="none"}}],yAxis:[{type:"value",position:a.axis,splitLine:{show:(c==null?void 0:c.hideSplitLines)==="vertical"||(c==null?void 0:c.hideSplitLines)==="none"},axisLine:{show:(c==null?void 0:c.hideAxisLines)==="x"||(c==null?void 0:c.hideAxisLines)==="none"},axisLabel:{show:(c==null?void 0:c.axisLabels)==="x"||(c==null?void 0:c.axisLabels)==="none"}}],series:(v=r.datasets)==null?void 0:v.map(d=>({data:d.data,type:"line",name:d.label,stack:"Total",areaStyle:{},emphasis:{focus:"series"},label:{show:n.show,position:n.position},showBackground:u==null?void 0:u.show,backgroundStyle:{color:"rgba(180, 180, 180, 0.2)"}}))};return B(we,{children:[!l&&S(ut,{style:{width:"100%",height:"90%"},option:h,onEvents:{click:d=>{var p;Zt(f,((p=d==null?void 0:d.name)==null?void 0:p.split(" ").join("_"))||"undefined")}}}),l&&s&&S(ut,{style:{width:"100%",height:"90%"},option:h,onEvents:{click:d=>{s(d.name)}}})]})},lue=({data:r,colors:e,updateGroup:t,isEnableGroupBy:n,backGroundColor:a,legendSettings:i,labelSettings:o,axisSettings:s,margins:l,customSettings:u,chartClickConfig:c})=>{var h,v;const f={toolbox:{feature:{saveAsImage:{name:"databrain"}},emphasis:{iconStyle:{borderColor:"#5865F6"}}},tooltip:{trigger:"axis",backgroundColor:"black",textStyle:{color:"white"},axisPointer:{type:"shadow"}},...e!=null&&e.length?{color:e}:{},grid:{left:`${l.marginLeft}%`,bottom:`${l.marginBottom}%`,top:`${l.marginTop}%`,right:`${l.marginRight}%`,containLabel:!0},xAxis:{type:"category",data:r.labels,axisTick:{alignWithLabel:!0},axisLabel:{show:(u==null?void 0:u.axisLabels)==="y"||(u==null?void 0:u.axisLabels)==="none",interval:0,rotate:50,hideOverlap:!0,overflow:"truncate"},splitLine:{show:(u==null?void 0:u.hideSplitLines)==="horizontal"||(u==null?void 0:u.hideSplitLines)==="none"},axisLine:{show:(u==null?void 0:u.hideAxisLines)==="y"||(u==null?void 0:u.hideAxisLines)==="none"}},yAxis:{type:"value",position:s.axis,splitLine:{show:(u==null?void 0:u.hideSplitLines)==="vertical"||(u==null?void 0:u.hideSplitLines)==="none"},axisLine:{show:(u==null?void 0:u.hideAxisLines)==="x"||(u==null?void 0:u.hideAxisLines)==="none"},axisLabel:{show:(u==null?void 0:u.axisLabels)==="x"||(u==null?void 0:u.axisLabels)==="none"}},legend:{data:(h=r.datasets)==null?void 0:h.map(d=>d.label),show:i.show,top:i.top,left:i.left,right:i.right,bottom:i.bottom,orient:i.position},series:(v=r.datasets)==null?void 0:v.map(d=>({data:d.data,type:"bar",name:d.label,barWidth:`${(u==null?void 0:u.barWidth)||0}%`,label:{show:o.show,position:o.position},showBackground:a==null?void 0:a.show,backgroundStyle:{color:"rgba(180, 180, 180, 0.2)"},itemStyle:{borderRadius:u==null?void 0:u.barRadius}}))};return B(we,{children:[!n&&S(ut,{style:{width:"100%",height:"90%"},option:f,onEvents:{click:d=>{var p;Zt(c,((p=d==null?void 0:d.name)==null?void 0:p.split(" ").join("_"))||"undefined")}}}),n&&t&&S(ut,{style:{width:"100%",height:"90%"},option:f,onEvents:{click:d=>{t(d.name)}}})]})},uue=({data:r,margins:e,legendSettings:t,labelSettings:n,enableSaveAs:a,colors:i,updateGroup:o,isEnableGroupBy:s,backGroundColor:l,customSettings:u,chartClickConfig:c})=>{var d;const f=["bar","line"];let h=1;const v={grid:{left:`${e.marginLeft}%`,bottom:`${e.marginBottom}%`,top:`${e.marginTop}%`,right:`${e.marginRight}%`,containLabel:!0},...i!=null&&i.length?{color:i}:{},toolbox:{feature:{saveAsImage:a&&{name:"databrain"}},emphasis:{iconStyle:{borderColor:"#5865F6"}}},tooltip:{trigger:"axis",backgroundColor:"black",textStyle:{color:"white"},axisPointer:{type:"cross",crossStyle:{color:"#999"}}},legend:{show:t.show,top:t.top,left:t.left,right:t.right,bottom:t.bottom,orient:t.position,data:r.datasets.map(p=>p.label)},xAxis:[{type:"category",data:r.labels,axisPointer:{type:"shadow"},splitLine:{show:(u==null?void 0:u.hideSplitLines)==="horizontal"||(u==null?void 0:u.hideSplitLines)==="none"},axisLine:{show:(u==null?void 0:u.hideAxisLines)==="y"||(u==null?void 0:u.hideAxisLines)==="none"},axisLabel:{show:(u==null?void 0:u.axisLabels)==="y"||(u==null?void 0:u.axisLabels)==="none"}}],yAxis:[{type:"value",min:0,max:9e3,interval:3e3,splitLine:{show:(u==null?void 0:u.hideSplitLines)==="vertical"||(u==null?void 0:u.hideSplitLines)==="none"},axisLine:{show:(u==null?void 0:u.hideAxisLines)==="x"||(u==null?void 0:u.hideAxisLines)==="none"},axisLabel:{show:(u==null?void 0:u.axisLabels)==="x"||(u==null?void 0:u.axisLabels)==="none"}},{type:"value",min:0,max:25,interval:5,splitLine:{show:(u==null?void 0:u.hideSplitLines)==="vertical"||(u==null?void 0:u.hideSplitLines)==="none"},axisLine:{show:(u==null?void 0:u.hideAxisLines)==="x"||(u==null?void 0:u.hideAxisLines)==="none"},axisLabel:{show:(u==null?void 0:u.axisLabels)==="x"||(u==null?void 0:u.axisLabels)==="none"}}],series:(d=r.datasets)==null?void 0:d.map(p=>(h===0?h=1:h=0,{name:p.label,type:f[h],tooltip:{valueFormatter(g){return`${g}`}},data:p.data,label:{show:n.show,position:n.position},showBackground:l.show,backgroundStyle:{color:"rgba(180, 180, 180, 0.2)"}}))};return B(we,{children:[!s&&S(ut,{style:{width:"100%",height:"90%"},option:v,onEvents:{click:p=>{var g;Zt(c,((g=p==null?void 0:p.name)==null?void 0:g.split(" ").join("_"))||"undefined")}}}),s&&o&&S(ut,{style:{width:"100%",height:"90%"},option:v,onEvents:{click:p=>{o(p.name)}}})]})},cue=({data:r,margins:e,legendSettings:t,labelSettings:n,axisSettings:a,enableSaveAs:i,colors:o,updateGroup:s,isEnableGroupBy:l,customSettings:u,chartClickConfig:c})=>{var h,v;const f={tooltip:{trigger:"axis",backgroundColor:"black",textStyle:{color:"white"},axisPointer:{type:"line",lineStyle:{color:"rgba(0,0,0,0.2)",width:1,type:"solid"}}},...o!=null&&o.length?{color:o}:{},grid:{left:`${e.marginLeft}%`,bottom:`${e.marginBottom}%`,top:`${e.marginTop}%`,right:`${e.marginRight}%`,containLabel:!0},toolbox:{feature:{saveAsImage:i&&{name:"databrain"}},emphasis:{iconStyle:{borderColor:"#5865F6"}}},xAxis:{type:"category",boundaryGap:!1,data:r.labels,splitLine:{show:u.hideSplitLines==="horizontal"||u.hideSplitLines==="none"},axisLine:{show:u.hideAxisLines==="y"||u.hideAxisLines==="none"},axisLabel:{show:u.axisLabels==="y"||u.axisLabels==="none"}},yAxis:{type:"value",position:a.axis,splitLine:{show:u.hideSplitLines==="vertical"||u.hideSplitLines==="none"},axisLine:{show:u.hideAxisLines==="x"||u.hideAxisLines==="none"},axisLabel:{show:u.axisLabels==="x"||u.axisLabels==="none"}},legend:{show:t.show,top:t.top,left:t.left,right:t.right,bottom:t.bottom,orient:t.position,data:(h=r.datasets)==null?void 0:h.map(d=>d.label)},series:(v=r.datasets)==null?void 0:v.map(d=>({data:d.data,type:"line",name:d.label,label:{show:n.show,position:n.position},emphasis:{focus:"series"}}))};return B(we,{children:[!l&&S(ut,{style:{width:"100%",height:"90%"},option:f}),l&&s&&S(ut,{style:{width:"100%",height:"90%"},option:f,onEvents:{click:d=>{Zt(c,d.name)}}})]})},fue=({data:r,margins:e,legendSettings:t,labelSettings:n,enableSaveAs:a,colors:i,updateGroup:o,isEnableGroupBy:s,chartClickConfig:l})=>{var f,h,v;if(((h=(f=r==null?void 0:r.datasets[0])==null?void 0:f.data)==null?void 0:h.length)>1){const d=[];let p=100;(v=r==null?void 0:r.datasets)==null||v.map(y=>{const m=[];let _=0;y.data.map(b=>{const x={value:b,name:r.labels[_]};m.push(x),_+=1}),d.push([y.label,m])});const g={toolbox:{feature:{saveAsImage:a&&{name:"databrain"}},emphasis:{iconStyle:{borderColor:"#5865F6"}}},tooltip:{trigger:"item",backgroundColor:"black",textStyle:{color:"white"}},...i!=null&&i.length?{color:i}:{},legend:{show:t.show,top:t.position==="horizontal"?"420px":t.top,left:t.left,right:t.right,bottom:t.bottom,orient:t.position,type:"scroll"},grid:{left:`${e.marginLeft}%`,bottom:`${e.marginBottom}%`,top:`${e.marginTop}%`,right:`${e.marginRight}%`,containLabel:!0},series:d.map(y=>(p-=20,{name:y[0],type:"pie",radius:`${p}%`,data:y[1],emphasis:{itemStyle:{shadowBlur:10,shadowOffsetX:0,shadowColor:"rgba(0, 0, 0, 0.5)"}},label:{show:n.show,position:n.position},labelLine:{show:!1}}))};return B(we,{children:[s&&S(we,{children:S(ut,{style:{width:"100%",height:"100%"},option:g,onEvents:{click:y=>{o(y.name)}}})}),!s&&S(we,{children:S(ut,{style:{width:"100%",height:"100%"},option:g,onEvents:{click:y=>{var m;Zt(l,((m=y==null?void 0:y.name)==null?void 0:m.split(" ").join("_"))||"undefined")}}})})]})}const u=r==null?void 0:r.datasets.map((d,p)=>({value:d.data,name:r==null?void 0:r.labels[p]})),c={toolbox:{feature:{saveAsImage:a&&{name:"databrain"}},emphasis:{iconStyle:{borderColor:"#5865F6"}}},tooltip:{trigger:"item",backgroundColor:"black",textStyle:{color:"white"}},...i!=null&&i.length?{color:i}:{},grid:{left:`${e.marginLeft}%`,bottom:`${e.marginBottom}%`,top:`${e.marginTop}%`,right:`${e.marginRight}%`,containLabel:!0},legend:{data:r==null?void 0:r.labels,show:t.show,top:t.position==="horizontal"?"420px":t.top,left:t.left,right:t.right,bottom:t.bottom,orient:t.position,type:"scroll"},series:{type:"pie",radius:"80%",data:u,label:{show:!1},labelLine:{show:!1}}};return S(we,{children:B(we,{children:[s&&S(we,{children:S(ut,{style:{width:"100%",height:"100%"},option:c,onEvents:{click:d=>{o(d.name)}}})}),!s&&S(we,{children:S(ut,{style:{width:"100%",height:"100%"},option:c,onEvents:{click:d=>{var p;Zt(l,((p=d==null?void 0:d.name)==null?void 0:p.split(" ").join("_"))||"undefined")}}})})]})})},hue=({data:r,margins:e,legendSettings:t,labelSettings:n,enableSaveAs:a,colors:i,updateGroup:o,isEnableGroupBy:s,backGroundColor:l,customSettings:u,chartClickConfig:c})=>{var h;const f={toolbox:{feature:{saveAsImage:a&&{name:"databrain"}},emphasis:{iconStyle:{borderColor:"#5865F6"}}},...i!=null&&i.length?{color:i}:{},tooltip:{trigger:"axis",backgroundColor:"black",textStyle:{color:"white"},axisPointer:{type:"cross",label:{backgroundColor:"#6a7985"}}},legend:{show:t.show,top:t.top,left:t.left,right:t.right,bottom:t.bottom,orient:t.position,data:r.datasets.map(v=>v.label)},grid:{left:`${e.marginLeft}%`,bottom:`${e.marginBottom}%`,top:`${e.marginTop}%`,right:`${e.marginRight}%`,containLabel:!0},xAxis:{type:"value",boundaryGap:[0,.01],splitLine:{show:(u==null?void 0:u.hideSplitLines)==="horizontal"||(u==null?void 0:u.hideSplitLines)==="none"},axisLine:{show:(u==null?void 0:u.hideAxisLines)==="y"||(u==null?void 0:u.hideAxisLines)==="none"},axisLabel:{show:(u==null?void 0:u.axisLabels)==="y"||(u==null?void 0:u.axisLabels)==="none"}},yAxis:{type:"category",data:r.labels,splitLine:{show:(u==null?void 0:u.hideSplitLines)==="vertical"||(u==null?void 0:u.hideSplitLines)==="none"},axisLine:{show:(u==null?void 0:u.hideAxisLines)==="x"||(u==null?void 0:u.hideAxisLines)==="none"},axisLabel:{show:(u==null?void 0:u.axisLabels)==="x"||(u==null?void 0:u.axisLabels)==="none"}},series:(h=r.datasets)==null?void 0:h.map(v=>({data:v.data,type:"bar",name:v.label,barWidth:`${u==null?void 0:u.barWidth}%`,emphasis:{focus:"series"},label:{show:n.show,position:n.position},showBackground:l.show,backgroundStyle:{color:"rgba(180, 180, 180, 0.2)"},itemStyle:{borderRadius:u==null?void 0:u.barRadius}}))};return B(we,{children:[!s&&S(ut,{style:{width:"100%",height:"90%"},option:f,onEvents:{click:v=>{var d;Zt(c,((d=v==null?void 0:v.name)==null?void 0:d.split(" ").join("_"))||"undefined")}}}),s&&o&&S(ut,{style:{width:"100%",height:"90%"},option:f,onEvents:{click:v=>{o(v.name)}}})]})},vue=({data:r,margins:e,legendSettings:t,labelSettings:n,axisSettings:a,enableSaveAs:i,colors:o,updateGroup:s,isEnableGroupBy:l,backGroundColor:u,customSettings:c,chartClickConfig:f})=>{var v;const h={toolbox:{feature:{saveAsImage:i&&{name:"databrain"}},emphasis:{iconStyle:{borderColor:"#5865F6"}}},...o!=null&&o.length?{color:o}:{},grid:{left:`${e.marginLeft}%`,bottom:`${e.marginBottom}%`,top:`${e.marginTop}%`,right:`${e.marginRight}%`,containLabel:!0},tooltip:{trigger:"axis",backgroundColor:"black",textStyle:{color:"white"},axisPointer:{type:"shadow"},formatter:d=>`${d.map(p=>`${p.seriesName}: ${p.value}<br />`).join("")}`},xAxis:{type:"category",data:r.labels,splitLine:{show:(c==null?void 0:c.hideSplitLines)==="horizontal"||(c==null?void 0:c.hideSplitLines)==="none"},axisLine:{show:(c==null?void 0:c.hideAxisLines)==="y"||(c==null?void 0:c.hideAxisLines)==="none"},axisLabel:{show:(c==null?void 0:c.axisLabels)==="y"||(c==null?void 0:c.axisLabels)==="none"}},yAxis:{type:"value",position:a.axis,splitLine:{show:(c==null?void 0:c.hideSplitLines)==="vertical"||(c==null?void 0:c.hideSplitLines)==="none"},axisLine:{show:(c==null?void 0:c.hideAxisLines)==="x"||(c==null?void 0:c.hideAxisLines)==="none"},axisLabel:{show:(c==null?void 0:c.axisLabels)==="x"||(c==null?void 0:c.axisLabels)==="none"}},legend:{show:t.show,top:t.top,left:t.left,right:t.right,bottom:t.bottom,orient:t.position,data:r.datasets.map(d=>d.label)},series:(v=r.datasets)==null?void 0:v.map(d=>({symbolSize:10,data:d.data,type:"scatter",name:d.label,label:{show:n.show,position:n.position},showBackground:u.show,backgroundStyle:{color:"rgba(180, 180, 180, 0.2)"}}))};return B(we,{children:[!l&&S(ut,{style:{width:"100%",height:"90%"},option:h,onEvents:{click:d=>{var p;Zt(f,((p=d==null?void 0:d.name)==null?void 0:p.split(" ").join("_"))||"undefined")}}}),l&&s&&S(ut,{style:{width:"100%",height:"90%"},option:h,onEvents:{click:d=>{s(d.name)}}})]})},due=({data:r,margins:e,labelSettings:t,axisSettings:n,enableSaveAs:a,colors:i,updateGroup:o,isEnableGroupBy:s,backGroundColor:l,customSettings:u,chartClickConfig:c})=>{var h,v;const f={toolbox:{feature:{saveAsImage:a&&{name:"databrain"}},emphasis:{iconStyle:{borderColor:"#5865F6"}}},...i!=null&&i.length?{color:i}:{},tooltip:{trigger:"axis",backgroundColor:"black",textStyle:{color:"white"},axisPointer:{type:"shadow"},formatter(d){const p=d[1];return`${p.name}<br/>${p.value}`}},grid:{left:`${e.marginLeft}%`,bottom:`${e.marginBottom}%`,top:`${e.marginTop}%`,right:`${e.marginRight}%`,containLabel:!0},xAxis:{type:"category",data:r.labels,splitLine:{show:(u==null?void 0:u.hideSplitLines)==="horizontal"||(u==null?void 0:u.hideSplitLines)==="none"},axisLine:{show:(u==null?void 0:u.hideAxisLines)==="y"||(u==null?void 0:u.hideAxisLines)==="none"},axisLabel:{show:(u==null?void 0:u.axisLabels)==="y"||(u==null?void 0:u.axisLabels)==="none"}},yAxis:{type:"value",position:n.axis,splitLine:{show:(u==null?void 0:u.hideSplitLines)==="vertical"||(u==null?void 0:u.hideSplitLines)==="none"},axisLine:{show:(u==null?void 0:u.hideAxisLines)==="x"||(u==null?void 0:u.hideAxisLines)==="none"},axisLabel:{show:(u==null?void 0:u.axisLabels)==="x"||(u==null?void 0:u.axisLabels)==="none"}},series:[{name:"Placeholder",type:"bar",stack:"Total",itemStyle:{borderColor:"transparent",color:"transparent"},emphasis:{itemStyle:{borderColor:"transparent",color:"transparent"}},data:(h=r.datasets)==null?void 0:h[1],showBackground:l.show,backgroundStyle:{color:"rgba(180, 180, 180, 0.2)"}},{name:"Life Cost",type:"bar",stack:"Total",label:{show:t.show,position:t.position},data:(v=r.datasets)==null?void 0:v[0]}]};return B(we,{children:[!s&&S(ut,{style:{width:"100%",height:"90%"},option:f,onEvents:{click:d=>{var p;Zt(c,((p=d==null?void 0:d.name)==null?void 0:p.split(" ").join("_"))||"undefined")}}}),s&&o&&S(ut,{style:{width:"100%",height:"90%"},option:f,onEvents:{click:d=>{o(d.name)}}})]})},pue=({funnelData:r,margins:e,legendSettings:t,labelSettings:n,colors:a,chartClickConfig:i})=>{const o={tooltip:{trigger:"item",formatter:"{b} : {c}k",backgroundColor:"black",textStyle:{color:"white"}},...a!=null&&a.length?{color:a}:{},legend:{show:t.show,top:t.top,left:t.left,right:t.right,bottom:t.bottom,orient:t.position,data:r==null?void 0:r.name},grid:{left:`${e.marginLeft}%`,bottom:`${e.marginBottom}%`,top:`${e.marginTop}%`,right:`${e.marginRight}%`,containLabel:!0},series:[{name:"Funnel",type:"funnel",left:"10%",top:60,bottom:60,width:"80%",height:"60%",min:0,max:100,minSize:"0%",maxSize:"100%",sort:"descending",gap:3,label:{show:n.show,position:n.position},labelLine:{length:10,lineStyle:{width:1,type:"solid"}},itemStyle:{borderColor:"#fff",borderWidth:1},emphasis:{label:{fontSize:20}},data:r}]};return S(we,{children:S(ut,{style:{width:"100%",height:"90%"},option:o,onEvents:{click:s=>{var l;Zt(i,((l=s==null?void 0:s.name)==null?void 0:l.split(" ").join("_"))||"undefined")}}})})},gue=({data:r,margins:e,legendSettings:t,labelSettings:n,axisSettings:a,enableSaveAs:i,colors:o,updateGroup:s,isEnableGroupBy:l,customSettings:u,chartClickConfig:c})=>{var d;const f=[];let h=8;(d=r==null?void 0:r.datasets)==null||d.map(p=>{const g=[];let y=0;const m=p.label;p.data.map(_=>{g.push([r.labels[y],_,m]),y+=1}),f.push(g)});const v={tooltip:{backgroundColor:"black",textStyle:{color:"white"}},...o!=null&&o.length?{color:o}:{},toolbox:{feature:{saveAsImage:i&&{name:"databrain"}},emphasis:{iconStyle:{borderColor:"#5865F6"}}},legend:{show:t.show,top:t.top,left:t.left,right:t.right,bottom:t.bottom,orient:t.position,data:f.map(p=>p[0][2])},grid:{left:`${e.marginLeft}%`,bottom:`${e.marginBottom}%`,top:`${e.marginTop}%`,right:`${e.marginRight}%`,containLabel:!0},xAxis:{splitLine:{show:(u==null?void 0:u.hideSplitLines)==="horizontal"||(u==null?void 0:u.hideSplitLines)==="none",lineStyle:{type:"dashed"}},axisLine:{show:(u==null?void 0:u.hideAxisLines)==="y"||(u==null?void 0:u.hideAxisLines)==="none"},axisLabel:{show:(u==null?void 0:u.axisLabels)==="y"||(u==null?void 0:u.axisLabels)==="none"}},yAxis:{position:a.axis,scale:!0,splitLine:{show:(u==null?void 0:u.hideSplitLines)==="vertical"||(u==null?void 0:u.hideSplitLines)==="none",lineStyle:{type:"dashed"}},axisLine:{show:(u==null?void 0:u.hideAxisLines)==="x"||(u==null?void 0:u.hideAxisLines)==="none"},axisLabel:{show:(u==null?void 0:u.axisLabels)==="x"||(u==null?void 0:u.axisLabels)==="none"}},series:f.map(p=>{h+=3;const g="0123456789ABCDEF";let y="#";for(let m=0;m<6;m+=1)y+=g[Math.floor(Math.random()*16)];return{name:p[0][2],data:p.map(m=>({name:m[0],value:m[1]})),type:"scatter",symbolSize:h,emphasis:{focus:"series"},itemStyle:{shadowBlur:10,shadowColor:"rgba(120, 36, 50, 0.5)",shadowOffsetY:5,color:y},label:{show:n.show,position:n.position}}})};return B(we,{children:[!l&&S(ut,{style:{width:"100%",height:"90%"},option:v,onEvents:{click:p=>{var g;Zt(c,((g=p==null?void 0:p.name)==null?void 0:g.split(" ").join("_"))||"undefined")}}}),l&&s&&S(ut,{style:{width:"100%",height:"90%"},option:v,onEvents:{click:p=>{s(p.name)}}})]})},yue=({data:r,margins:e,legendSettings:t,labelSettings:n,enableSaveAs:a,colors:i,updateGroup:o,isEnableGroupBy:s,chartClickConfig:l})=>{var f,h;if(((f=r==null?void 0:r.labels)==null?void 0:f.length)>1){const v=[];let d=70,p=100;(h=r==null?void 0:r.datasets)==null||h.map(y=>{const m=[];let _=0;y.data.map(b=>{const x={value:b,name:r.labels[_]};m.push(x),_+=1}),v.push([y.label,m])});const g={toolbox:{feature:{saveAsImage:a&&{name:"databrain"}},emphasis:{iconStyle:{borderColor:"#5865F6"}}},...i!=null&&i.length?{color:i}:{},tooltip:{trigger:"item",backgroundColor:"black",textStyle:{color:"white"}},legend:{show:t.show,top:t.position==="horizontal"?"420px":t.top,left:t.left,right:t.right,bottom:t.bottom,orient:t.position,type:"scroll"},grid:{left:`${e.marginLeft}%`,bottom:`${e.marginBottom}%`,top:`${e.marginTop}%`,right:`${e.marginRight}%`,containLabel:!0},series:v.map(y=>(d-=20,p-=20,{name:y[0],type:"pie",radius:[`${d}%`,`${p}%`],avoidLabelOverlap:!1,label:{show:n.show,position:n.position},data:y[1],labelLine:{show:!1}}))};return B(we,{children:[!s&&S(ut,{style:{width:"100%",height:"90%"},option:g}),s&&o&&S(ut,{style:{width:"100%",height:"90%"},option:g,onEvents:{click:y=>{o(y.name)}}})]})}const u=r==null?void 0:r.datasets.map((v,d)=>({value:v.data,name:r==null?void 0:r.labels[d]})),c={toolbox:{feature:{saveAsImage:a&&{name:"databrain"}},emphasis:{iconStyle:{borderColor:"#5865F6"}}},...i!=null&&i.length?{color:i}:{},tooltip:{trigger:"item",backgroundColor:"black",textStyle:{color:"white"}},legend:{data:r==null?void 0:r.labels,orient:"vertical",left:"left",type:"scroll"},grid:{left:`${e.marginLeft}%`,bottom:`${e.marginBottom}%`,top:`${e.marginTop}%`,right:`${e.marginRight}%`,containLabel:!0},series:{type:"pie",radius:["30%","70%"],avoidLabelOverlap:!1,label:{show:n.show,position:n.position},data:u,labelLine:{show:!1}}};return B(we,{children:[!s&&S(ut,{style:{width:"100%",height:"90%"},option:c,onEvents:{click:v=>{var d;Zt(l,((d=v==null?void 0:v.name)==null?void 0:d.split(" ").join("_"))||"undefined")}}}),s&&o&&S(ut,{style:{width:"100%",height:"90%"},option:c,onEvents:{click:v=>{o(v.name)}}})]})},mue=({data:r,margins:e,legendSettings:t,labelSettings:n,axisSettings:a,enableSaveAs:i,colors:o,updateGroup:s,isEnableGroupBy:l,backGroundColor:u,customSettings:c,chartClickConfig:f})=>{var p;const h=["start","middle","end"];let v=2;const d={toolbox:{feature:{saveAsImage:i&&{name:"databrain"}},emphasis:{iconStyle:{borderColor:"#5865F6"}}},...o!=null&&o.length?{color:o}:{},tooltip:{trigger:"axis",backgroundColor:"black",textStyle:{color:"white"}},legend:{show:t.show,top:t.top,left:t.left,right:t.right,bottom:t.bottom,orient:t.position,data:r.datasets.map(g=>g.label)},grid:{left:`${e.marginLeft}%`,bottom:`${e.marginBottom}%`,top:`${e.marginTop}%`,right:`${e.marginRight}%`,containLabel:!0},xAxis:{type:"category",data:r.labels,splitLine:{show:(c==null?void 0:c.hideSplitLines)==="horizontal"||(c==null?void 0:c.hideSplitLines)==="none"},axisLine:{show:(c==null?void 0:c.hideAxisLines)==="y"||(c==null?void 0:c.hideAxisLines)==="none"},axisLabel:{show:(c==null?void 0:c.axisLabels)==="y"||(c==null?void 0:c.axisLabels)==="none"}},yAxis:{type:"value",position:a.axis,splitLine:{show:(c==null?void 0:c.hideSplitLines)==="vertical"||(c==null?void 0:c.hideSplitLines)==="none"},axisLine:{show:(c==null?void 0:c.hideAxisLines)==="x"||(c==null?void 0:c.hideAxisLines)==="none"},axisLabel:{show:(c==null?void 0:c.axisLabels)==="x"||(c==null?void 0:c.axisLabels)==="none"}},series:(p=r.datasets)==null?void 0:p.map(g=>(v===0?v=1:v===1?v=2:v=0,{name:g.label,type:"line",step:h[v],data:g.data,areaStyle:{},label:{show:n.show,position:n.position},showBackground:u.show,backgroundStyle:{color:"rgba(180, 180, 180, 0.2)"}}))};return B(we,{children:[!l&&S(ut,{style:{width:"100%",height:"90%"},option:d,onEvents:{click:g=>{var y;Zt(f,((y=g==null?void 0:g.name)==null?void 0:y.split(" ").join("_"))||"undefined")}}}),l&&s&&S(ut,{style:{width:"100%",height:"90%"},option:d,onEvents:{click:g=>{s(g.name)}}})]})},_ue=({data:r,margins:e,legendSettings:t,labelSettings:n,axisSettings:a,enableSaveAs:i,colors:o,updateGroup:s,isEnableGroupBy:l,backGroundColor:u,customSettings:c,chartClickConfig:f})=>{var v,d;const h={toolbox:{feature:{saveAsImage:i&&{name:"databrain"}},emphasis:{iconStyle:{borderColor:"#5865F6"}}},tooltip:{trigger:"axis",backgroundColor:"black",textStyle:{color:"white"},axisPointer:{type:"shadow"}},...o!=null&&o.length?{color:o}:{},grid:{left:`${e.marginLeft}%`,bottom:`${e.marginBottom}%`,top:`${e.marginTop}%`,right:`${e.marginRight}%`,containLabel:!0},legend:{show:t.show,top:t.top,left:t.left,right:t.right,bottom:t.bottom,orient:t.position,data:r.datasets.map(p=>p.label)},xAxis:[{type:"category",data:r.labels,axisTick:{alignWithLabel:!0},splitLine:{show:(c==null?void 0:c.hideSplitLines)==="horizontal"||(c==null?void 0:c.hideSplitLines)==="none"},axisLine:{show:(c==null?void 0:c.hideAxisLines)==="y"||(c==null?void 0:c.hideAxisLines)==="none"},axisLabel:{show:(c==null?void 0:c.axisLabels)==="y"||(c==null?void 0:c.axisLabels)==="none"}}],yAxis:[{type:"value",position:a.axis,splitLine:{show:(c==null?void 0:c.hideSplitLines)==="vertical"||(c==null?void 0:c.hideSplitLines)==="none"},axisLine:{show:(c==null?void 0:c.hideAxisLines)==="x"||(c==null?void 0:c.hideAxisLines)==="none"},axisLabel:{show:(c==null?void 0:c.axisLabels)==="x"||(c==null?void 0:c.axisLabels)==="none"}}],series:[{name:(v=r.datasets[0])==null?void 0:v.label,type:"bar",barWidth:"100%",data:(d=r.datasets[0])==null?void 0:d.data,label:{show:n.show,position:n.position},showBackground:u.show,backgroundStyle:{color:"rgba(180, 180, 180, 0.2)"}}]};return B(we,{children:[!l&&S(ut,{style:{width:"100%",height:"90%"},option:h,onEvents:{click:p=>{var g;Zt(f,((g=p==null?void 0:p.name)==null?void 0:g.split(" ").join("_"))||"undefined")}}}),l&&s&&S(ut,{style:{width:"100%",height:"90%"},option:h,onEvents:{click:p=>{s(p.name)}}})]})},bue=({gaugeData:r,margins:e,legendSettings:t,enableSaveAs:n,colors:a,chartClickConfig:i})=>{const o=Array.isArray(r)?r:[],s=o.reduce((c,f)=>c+f.value,0),l=Math.floor(s/o.length),u={toolbox:{feature:{saveAsImage:n&&{name:"databrain"}},emphasis:{iconStyle:{borderColor:"#5865F6"}}},...a!=null&&a.length?{color:a}:{},grid:{left:`${e.marginLeft}%`,bottom:`${e.marginBottom}%`,top:`${e.marginTop}%`,right:`${e.marginRight}%`,containLabel:!0},legend:{show:t.show,top:t.top,left:t.left,right:t.right,bottom:t.bottom,orient:t.position},series:[{type:"gauge",center:["50%","60%"],startAngle:200,endAngle:-20,min:0,max:l+100,splitNumber:12,itemStyle:{color:"blue"},progress:{show:!0,width:20},pointer:{show:!0},axisLine:{lineStyle:{width:30}},axisTick:{distance:-45,splitNumber:5,lineStyle:{width:2,color:"#999"}},splitLine:{distance:-52,length:14,lineStyle:{width:3,color:"#999"}},axisLabel:{distance:-8,color:"black",fontSize:10},anchor:{show:!1},data:[{value:l}]}]};return S(ut,{style:{width:"100%",height:"113%"},option:u,onEvents:{click:c=>{var f;Zt(i,((f=c==null?void 0:c.name)==null?void 0:f.split(" ").join("_"))||"undefined")}}})},Mue=({data:r,margins:e,enableSaveAs:t,colors:n,backGroundColor:a,chartClickConfig:i})=>{var u,c,f;const o=[],s=[];if((r==null?void 0:r.length)&&((u=r==null?void 0:r[0])==null?void 0:u[0])!==((c=r==null?void 0:r[1])==null?void 0:c[0])){const h=[r==null?void 0:r[0],r==null?void 0:r[1]];h==null||h.map(v=>{v.map(d=>{o.includes(d)||o.push(d)})});for(let v=0;v<((f=r==null?void 0:r[0])==null?void 0:f.length);v+=1)s.push({source:r[0][v],target:r[1][v],value:r[2][v]})}const l={toolbox:{feature:{saveAsImage:t&&{name:"databrain"}},emphasis:{iconStyle:{borderColor:"#5865F6"}}},...n!=null&&n.length?{color:n}:{},tooltip:{trigger:"item",triggerOn:"mousemove",backgroundColor:"black",textStyle:{color:"white"}},grid:{left:`${e.marginLeft}%`,bottom:`${e.marginBottom}%`,top:`${e.marginTop}%`,right:`${e.marginRight}%`,containLabel:!0},series:{type:"sankey",layout:"none",emphasis:{focus:"adjacency"},data:o==null?void 0:o.map(h=>({name:h})),links:s,showBackground:a.show,backgroundStyle:{color:"rgba(180, 180, 180, 0.2)"}}};return S(we,{children:S(ut,{style:{width:"100%",height:"100%"},option:l,onEvents:{click:h=>{var v;Zt(i,((v=h==null?void 0:h.name)==null?void 0:v.split(" ").join("_"))||"undefined")}}})})},xue=({data:r,margins:e,legendSettings:t,labelSettings:n,axisSettings:a,enableSaveAs:i,colors:o,updateGroup:s,isEnableGroupBy:l,backGroundColor:u,customSettings:c,chartClickConfig:f})=>{var v,d;const h={toolbox:{feature:{saveAsImage:i&&{name:"databrain"}},emphasis:{iconStyle:{borderColor:"#5865F6"}}},grid:{left:`${e.marginLeft}%`,bottom:`${e.marginBottom}%`,top:`${e.marginTop}%`,right:`${e.marginRight}%`,containLabel:!0},...o!=null&&o.length?{color:o}:{},tooltip:{trigger:"axis",backgroundColor:"black",textStyle:{color:"white"},axisPointer:{type:"shadow"},formatter:p=>`${p.map(g=>`${g.seriesName}: ${g.value}<br />`).join("")}`},xAxis:{type:"category",data:r==null?void 0:r.labels,splitLine:{show:(c==null?void 0:c.hideSplitLines)==="horizontal"||(c==null?void 0:c.hideSplitLines)==="none"},axisLine:{show:(c==null?void 0:c.hideAxisLines)==="y"||(c==null?void 0:c.hideAxisLines)==="none"},axisLabel:{show:(c==null?void 0:c.axisLabels)==="y"||(c==null?void 0:c.axisLabels)==="none"}},yAxis:{type:"value",position:a.axis,splitLine:{show:(c==null?void 0:c.hideSplitLines)==="vertical"||(c==null?void 0:c.hideSplitLines)==="none"},axisLine:{show:(c==null?void 0:c.hideAxisLines)==="x"||(c==null?void 0:c.hideAxisLines)==="none"},axisLabel:{show:(c==null?void 0:c.axisLabels)==="x"||(c==null?void 0:c.axisLabels)==="none"}},legend:{show:t.show,top:t.top,left:t.left,right:t.right,bottom:t.bottom,orient:t.position,data:(v=r==null?void 0:r.datasets)==null?void 0:v.map(p=>p.label)},series:(d=r==null?void 0:r.datasets)==null?void 0:d.map(p=>({data:p.data,type:"bar",name:p.label,stack:"x",barWidth:`${c==null?void 0:c.barWidth}%`,emphasis:{focus:"series"},label:{show:n.show,position:n.position},showBackground:u.show,backgroundStyle:{color:"rgba(180, 180, 180, 0.2)"},itemStyle:{borderRadius:c==null?void 0:c.barRadius}}))};return B(we,{children:[!l&&S(ut,{style:{width:"100%",height:"90%"},option:h,onEvents:{click:p=>{var g;Zt(f,((g=p==null?void 0:p.name)==null?void 0:g.split(" ").join("_"))||"undefined")}}}),l&&s&&S(ut,{style:{width:"100%",height:"90%"},option:h,onEvents:{click:p=>{s(p.name)}}})]})};var QR={container:"_container_qiww4_1",borderLessContainer:"_borderLessContainer_qiww4_7",label:"_label_qiww4_13",sync:"_sync_qiww4_19"};const ZR=({data:r,customSettings:e,chartClickConfig:t,hideBorder:n})=>{var h,v,d,p;const a={fontSize:`${e.subHeaderFontSize}px`||"14px"},i={fontSize:`${e.fontSize}px`||"30px"},o=t.isEnable?"hover:cursor-pointer":"hover:cursor-text",s=new Intl.NumberFormat,l=(g,y)=>{let m="";if(y)switch(parseInt(g,10).toString().length){case 1:case 2:case 3:m=g;break;case 4:m=`${g.toString().slice(0,1)}.${g.toString().slice(1,3)}k`;break;case 5:m=`${g.toString().slice(0,2)}.${g.toString().slice(2,4)}k`;break;case 6:m=`${g.toString().slice(0,3)}.${g.toString().slice(3,5)}k`;break;case 7:m=`${g.toString().slice(0,1)}.${g.toString().slice(1,3)}M`;break;case 8:m=`${g.toString().slice(0,2)}.${g.toString().slice(2,4)}M`;break;case 9:m=`${g.toString().slice(0,3)}.${g.toString().slice(3,5)}M`;break;case 10:m=`${g.toString().slice(0,1)}.${g.toString().slice(1,3)}B`;break}else switch(parseInt(g,10).toString().length){case 1:case 2:case 3:m=g;break;case 4:m=`${g.toString().slice(0,1)}k`;break;case 5:m=`${g.toString().slice(0,2)}k`;break;case 6:m=`${g.toString().slice(0,3)}k`;break;case 7:m=`${g.toString().slice(0,1)}M`;break;case 8:m=`${g.toString().slice(0,2)}M`;break;case 9:m=`${g.toString().slice(0,3)}M`;break;case 10:m=`${g.toString().slice(0,1)}B`;break}return m},u=(g,y)=>{switch(y){case"original":return g;case"3s":case"adaptive":return l(g,!0);case"d":return parseInt(g,10).toLocaleString();case"1s":{let m=g.toString().slice(0,1);const _=Math.floor(parseFloat(g));for(let x=1;x<_.toString().length;x+=1)m+=0;return l(m,!1)}case"1f":{const m=parseFloat(g).toFixed(1),_=s.format(m);return g.toString().includes(".")?_:`${_}.${Array(2).join("0")}`}case"2f":{const m=parseFloat(g).toFixed(2),_=s.format(m);return g.toString().includes(".")?g.toString().split(".")[1].length>1?_:`${_}${Array(2).join("0")}`:`${_}.${Array(3).join("0")}`}case"3f":{const m=parseFloat(g).toFixed(3),_=s.format(m);if(g.toString().includes(".")){const b=g.toString().split(".");return b[1].length>2?_:b[1].length===2?`${_}${Array(2).join("0")}`:`${_}${Array(3).join("0")}`}return`${_}.${Array(4).join("0")}`}case"+":return`+${s.format(g)}`;case"$":{const m=parseFloat(g).toFixed(2),_=s.format(m);return g.toString().includes(".")?g.toString().split(".")[1].length>1?`$${_}`:`$${_}${Array(2).join("0")}`:`$${_}.${Array(3).join("0")}`}case"1%":{const m=parseFloat(g)*100,_=parseFloat(m).toFixed(1),b=s.format(_);return m.toString().includes(".")?`${b}%`:`${b}.${Array(2).join("0")}%`}case"2%":{const m=parseFloat(g)*100,_=parseFloat(m).toFixed(2),b=s.format(_);return m.toString().includes(".")?g.toString().split(".")[1].length>1?`${b}%`:`${b}.${Array(2).join("0")}`:`${b}.${Array(3).join("0")}%`}case"3%":{const m=g*100,_=parseFloat(m).toFixed(3),b=s.format(_);return m.toString().includes(".")?g.toString().split(".")[1].length>1?`${b}%`:`${b}.${Array(3).join("0")}`:`${b}.${Array(4).join("0")}%`}case"ms1":{const m=Math.floor(parseFloat(g)/1e3),_=parseFloat(g)%1e3;return`${m}.${_.toString().slice(0,1)}s`}case"ms2":{const m=Math.floor(parseFloat(g)/1e3),_=Math.floor(parseFloat(g)%1e3),b=parseFloat(g)-Math.floor(parseFloat(g)),x=Math.floor(b*1e3),M=b*1e3-x,w=Math.floor(M*1e3);let D="";return m&&(D+=`${m}s `),_&&(D+=`${_}ms `),x&&(D+=`${x}\xB5s`),w&&(D+=`${w}ns`),D}case"4r":return Math.floor(Math.round(parseFloat(g)));default:return g}},c=(g,y)=>{const m=g.toString().slice(0,4),_=g.toString().slice(5,7),b=g.toString().slice(8,10),x=g.toString().slice(11,19);switch(y){case"dd-mm-yyyy":return`${b}-${_}-${m}`;case"mm-dd-yyyy":return`${_}-${b}-${m}`;case"yyyy-mm-dd":return`${m}-${_}-${b}`;case"dd/mm/yyyy":return`${b}/${_}/${m}`;case"mm/dd/yyyy":return`${_}/${b}/${m}`;case"yyyy/mm/dd":return`${m}/${_}/${b}`;case"hh:mm:ss":return x;default:return g}},f=((h=r[0])==null?void 0:h.value)&&((v=r[0])==null?void 0:v.value.toString().length)>16?c((d=r[0])==null?void 0:d.value,e.dateFormatter):u((p=r[0])==null?void 0:p.value,e.numberFormatter);return B("div",{className:n?QR.borderLessContainer:QR.container,children:[S("div",{style:i,onClick:()=>{Zt(t,f||"")},className:o,children:(r==null?void 0:r.length)&&S(we,{children:f})}),S("div",{style:a,onClick:()=>{Zt(t,e.displayText||"")},children:e.subHeaderShow&&e.displayText})]})},wue=({data:r,margins:e,legendSettings:t,axisSettings:n,enableSaveAs:a,colors:i,customSettings:o,chartClickConfig:s})=>{var f;const l=[],u=[];(f=r==null?void 0:r.datasets)==null||f.map(h=>{l.push(h.data),u.push(h.label)});const c={toolbox:{feature:{saveAsImage:a&&{name:"databrain"}},emphasis:{iconStyle:{borderColor:"#5865F6"}}},...i!=null&&i.length?{color:i}:{},title:[{text:"Box Plot",left:"center"}],legend:{show:t.show,top:t.top,left:t.left,right:t.right,bottom:t.bottom,orient:t.position,data:r.datasets.map(h=>h.label)},dataset:[{source:l},{transform:{type:"boxplot",config:{itemNameFormatter:"expr {value}"}}},{fromDatasetIndex:1,fromTransformResult:1}],tooltip:{trigger:"item",backgroundColor:"black",textStyle:{color:"white"},axisPointer:{type:"shadow"}},grid:{left:`${e.marginLeft}%`,bottom:`${e.marginBottom}%`,top:`${e.marginTop}%`,right:`${e.marginRight}%`,containLabel:!0},xAxis:{type:"category",boundaryGap:!0,nameGap:30,splitArea:{show:!1},splitLine:{show:(o==null?void 0:o.hideSplitLines)==="horizontal"||(o==null?void 0:o.hideSplitLines)==="none"},axisLine:{show:(o==null?void 0:o.hideAxisLines)==="y"||(o==null?void 0:o.hideAxisLines)==="none"},axisLabel:{show:(o==null?void 0:o.axisLabels)==="y"||(o==null?void 0:o.axisLabels)==="none"}},yAxis:{type:"value",position:n.axis,splitArea:{show:!0},splitLine:{show:(o==null?void 0:o.hideSplitLines)==="vertical"||(o==null?void 0:o.hideSplitLines)==="none"},axisLine:{show:(o==null?void 0:o.hideAxisLines)==="x"||(o==null?void 0:o.hideAxisLines)==="none"},axisLabel:{show:(o==null?void 0:o.axisLabels)==="x"||(o==null?void 0:o.axisLabels)==="none"}},series:[{name:"boxplot",type:"boxplot",datasetIndex:1},{name:"outlier",type:"scatter",datasetIndex:2}]};return S(we,{children:S(ut,{style:{width:"100%",height:"90%"},option:c,onEvents:{click:h=>{var v;Zt(s,((v=h==null?void 0:h.name)==null?void 0:v.split(" ").join("_"))||"undefined")}}})})};var Sn={tableSection:"_tableSection_rwcfo_1",tableContainer:"_tableContainer_rwcfo_5",tableDiv:"_tableDiv_rwcfo_9",table:"_table_rwcfo_1",tableHead:"_tableHead_rwcfo_17",tableHeadColHash:"_tableHeadColHash_rwcfo_21",tableCol:"_tableCol_rwcfo_25",tableColLabel:"_tableColLabel_rwcfo_29",data:"_data_rwcfo_33",tableBodyColHash:"_tableBodyColHash_rwcfo_37",tableBodyColHashLabel:"_tableBodyColHashLabel_rwcfo_41","table-loader-container":"_table-loader-container_rwcfo_45","table-error-message":"_table-error-message_rwcfo_49",noData:"_noData_rwcfo_53"};const Due=({data:r,chartClickConfig:e})=>{var a,i,o;let t=0;const n=[];if(r)for(let s=0;s<((i=(a=r==null?void 0:r.datasets[0])==null?void 0:a.data)==null?void 0:i.length);s+=1){const l=[];for(let u=0;u<(r==null?void 0:r.datasets.length);u+=1){const c=(o=r==null?void 0:r.datasets[u])==null?void 0:o.data[t];l.push(c)}n.push(l),t+=1}return S("div",{className:Sn.tableSection,children:S("div",{className:Sn.tableContainer,children:S("div",{className:Sn.tableDiv,children:B("table",{className:Sn.table,children:[S("thead",{children:B("tr",{className:`${Sn.tableHead}`,children:[S("th",{className:Sn.tableHeadColHash,scope:"col",children:S(de,{styleClass:"font-14c",variant:"h1",children:"#"})},"num"),r==null?void 0:r.datasets.map((s,l)=>S("th",{className:Sn.tableCol,scope:"col",children:S(de,{styleClass:"font-14c",variant:"h1",className:Sn.tableColLabel,children:s.label})},s+l))]})}),S("tbody",{children:n.map((s,l)=>B("tr",{className:Sn.data,children:[S("td",{className:Sn.tableBodyColHash,children:S(de,{styleClass:"font-14",variant:"p",className:Sn.tableBodyColHashLabel,children:l+1})},l),s.map((u,c)=>S(we,{children:S("td",{className:Sn.tableCol,children:S(Ce,{variant:"custom",type:"button",className:Sn.tableColLabel,isDisabled:!e.isEnable,onClick:()=>Zt(e,JSON.stringify(u)),children:JSON.stringify(u)})},u+c)}))]},l))})]})})})})},kg=({labels:r,data:e,chartType:t,funnelData:n,sankeyData:a,singleValueData:i,margins:o,legendSettings:s,labelSettings:l,axisSettings:u,customSettings:c,enableSaveAs:f,colors:h,updateGroup:v,isEnableGroupBy:d,backGroundColor:p,chartClickConfig:g})=>{var y,m,_,b;if(t===At.line)return S(cue,{data:e,margins:o,legendSettings:s,labelSettings:l,axisSettings:u,customSettings:c,enableSaveAs:f,updateGroup:v,isEnableGroupBy:d,chartClickConfig:g});if(t===At.stepped)return S(mue,{labels:r,data:e,margins:o,legendSettings:s,labelSettings:l,axisSettings:u,customSettings:c,enableSaveAs:f,colors:h,updateGroup:v,isEnableGroupBy:d,backGroundColor:p,chartClickConfig:g});if(t===At.bar)return S(lue,{data:e,updateGroup:v,isEnableGroupBy:d,colors:h,backGroundColor:p,legendSettings:s,labelSettings:l,axisSettings:u,customSettings:c,margins:o,chartClickConfig:g});if(t===At.stack)return S(xue,{data:e,margins:o,legendSettings:s,labelSettings:l,axisSettings:u,enableSaveAs:f,colors:h,updateGroup:v,isEnableGroupBy:d,backGroundColor:p,customSettings:c,chartClickConfig:g});if(t===At.histogram)return S(_ue,{data:e,margins:o,legendSettings:s,labelSettings:l,axisSettings:u,enableSaveAs:f,colors:h,updateGroup:v,isEnableGroupBy:d,backGroundColor:p,customSettings:c,chartClickConfig:g});if(t===At.bubble)return S(gue,{data:e,margins:o,legendSettings:s,labelSettings:l,axisSettings:u,enableSaveAs:f,colors:h,updateGroup:v,isEnableGroupBy:d,backGroundColor:p,customSettings:c,chartClickConfig:g});if(t===At.scatter)return S(vue,{data:e,margins:o,legendSettings:s,labelSettings:l,axisSettings:u,enableSaveAs:f,colors:h,updateGroup:v,isEnableGroupBy:d,backGroundColor:p,customSettings:c,chartClickConfig:g});if(t===At.row)return S(hue,{data:e,margins:o,legendSettings:s,labelSettings:l,enableSaveAs:f,colors:h,updateGroup:v,isEnableGroupBy:d,backGroundColor:p,customSettings:c,chartClickConfig:g});if(t===At.area)return(y=e.datasets)==null||y.map(x=>Object.assign(x,{fill:!0})),S(sue,{data:e,margins:o,legendSettings:s,labelSettings:l,axisSettings:u,enableSaveAs:f,colors:h,updateGroup:v,isEnableGroupBy:d,backGroundColor:p,customSettings:c,chartClickConfig:g});if(t===At.combo){if((m=e.datasets)!=null&&m.length){const x=e.datasets[0];Object.assign(x,{type:"line"})}return S(uue,{data:e,margins:o,legendSettings:s,labelSettings:l,enableSaveAs:f,colors:h,updateGroup:v,isEnableGroupBy:d,backGroundColor:p,customSettings:c,chartClickConfig:g})}if(t===At.pie)return S(fue,{data:e,margins:o,legendSettings:s,labelSettings:l,enableSaveAs:f,colors:h,updateGroup:v,isEnableGroupBy:d,chartClickConfig:g});if(t===At.doughnut)return S(yue,{data:e,margins:o,legendSettings:s,labelSettings:l,enableSaveAs:f,colors:h,updateGroup:v,isEnableGroupBy:d,chartClickConfig:g});if(t===At.waterfall){let x;if((_=e.datasets)!=null&&_.length){const M=(b=e.datasets[0])==null?void 0:b.data,w=[M==null?void 0:M[0]];if(M!=null&&M.length)for(let D=1;D<M.length-1;D++)w.push(w[D-1]-M[D]);w.push(M==null?void 0:M[M.length-1]),x={labels:e.labels,datasets:[M,w]}}return S(due,{data:x||e,margins:o,legendSettings:s,labelSettings:l,axisSettings:u,enableSaveAs:f,colors:h,updateGroup:v,isEnableGroupBy:d,backGroundColor:p,customSettings:c,chartClickConfig:g})}return t===At.funnel?S(pue,{funnelData:n,margins:o,legendSettings:s,labelSettings:l,colors:h,chartClickConfig:g}):t===At.gauge?S(bue,{gaugeData:n,margins:o,legendSettings:s,labelSettings:l,enableSaveAs:f,colors:h,chartClickConfig:g}):t===At.sankey?S(Mue,{data:a,margins:o,legendSettings:s,labelSettings:l,enableSaveAs:f,colors:h,backGroundColor:p,chartClickConfig:g}):t===At.singleValue?S(ZR,{data:i,margins:o,labelSettings:l,customSettings:c,chartClickConfig:g}):t===At.boxplot?S(wue,{data:e,margins:o,legendSettings:s,labelSettings:l,axisSettings:u,enableSaveAs:f,colors:h,customSettings:c,chartClickConfig:g}):t===At.table?S(Due,{data:e,margins:o,legendSettings:s,labelSettings:l,chartClickConfig:g}):S("div",{className:TS.noChart,children:"No chart selected"})},tw=({isShow:r,onCancel:e,chart:t})=>S(li,{isOpen:r,onClose:e,headerTitle:"Chart Preview",children:S("div",{className:GF.fullscreen,children:t&&S(kg,{labels:t.labels,data:t.data,chartType:t.chartType,funnelData:t.funnelData,sankeyData:t.sankeyData,singleValueData:t.singleValueData,margins:t.margins,colors:t.colors,legendSettings:t.legendSettings,labelSettings:t.labelSettings,axisSettings:t.axisSettings,backGroundColor:t.backGroundColor,enableSaveAs:!0,customSettings:t.customSettings,chartClickConfig:{isEnable:!1,baseUrl:"",dynamic:"{{value}}",route:"/{{value}}",routeType:"internal"}})})});var Li={button:"_button_1ecv1_1",menu:"_menu_1ecv1_7",menuContainer:"_menuContainer_1ecv1_13",buttonText:"_buttonText_1ecv1_19",buttonIcon:"_buttonIcon_1ecv1_25",filterName:"_filterName_1ecv1_31",filterDropdown:"_filterDropdown_1ecv1_37"},ea={container:"_container_1qflp_1",popover:"_popover_1qflp_9",button:"_button_1qflp_17",buttonOpen:"_buttonOpen_1qflp_25",menu:"_menu_1qflp_33",enter:"_enter_1qflp_41",enterFrom:"_enterFrom_1qflp_49",enterTo:"_enterTo_1qflp_57",leave:"_leave_1qflp_65",leaveFrom:"_leaveFrom_1qflp_73",leaveTo:"_leaveTo_1qflp_81",center:"_center_1qflp_89",top:"_top_1qflp_97",bottom:"_bottom_1qflp_105",left:"_left_1qflp_113",right:"_right_1qflp_121","left-top-end":"_left-top-end_1qflp_129","right-top-end":"_right-top-end_1qflp_137","left-bottom-end":"_left-bottom-end_1qflp_145","right-bottom-end":"_right-bottom-end_1qflp_153","top-left":"_top-left_1qflp_161","top-right":"_top-right_1qflp_169","bottom-left":"_bottom-left_1qflp_177","bottom-right":"_bottom-right_1qflp_185","left-top":"_left-top_1qflp_129","left-bottom":"_left-bottom_1qflp_145","right-top":"_right-top_1qflp_137","right-bottom":"_right-bottom_1qflp_153"};const Rg=({className:r="",menuClass:e="",menuContainerClass:t="",buttonClass:n="",children:a,button:i,position:o="bottom",isDisabled:s})=>{const[l,u]=R.useState(!1),c=R.useRef(null);return _v({wrapRef:c,onOutsideClick:()=>u(!1)}),S(we,{children:B("div",{className:`${ea.container} ${r}`,ref:c,children:[S(Ce,{className:`${n} ${l?ea.buttonOpen:""} ${ea.button}`,type:"button",variant:"custom",onClick:()=>!s&&u(f=>!f),children:i}),s?null:S("div",{className:`${ea.popover} ${ea[o]} ${t}`,children:S(dv,{as:"div",className:`${ea.menu} ${e}`,show:l,enter:ea.enter,enterFrom:ea.enterFrom,enterTo:ea.enterTo,leave:ea.leave,leaveFrom:ea.leaveFrom,leaveTo:ea.leaveTo,children:a})})]})})},rw=r=>["IN","NOT IN"].includes(r),Dh=r=>["IS NULL","IS NOT NULL"].includes(r),qR=({filter:r,onChange:e,isResetted:t,companyId:n,tableName:a})=>{const[i,o]=R.useState({value:"",label:""}),[s,l]=R.useState({value:"",label:""}),[u,c]=R.useState([]),f=R.useMemo(()=>NS(r.dataType),[r.dataType]);return R.useEffect(()=>{!i.value||s.value!==""&&u.length||e({column:r.name,operator:i.value,value:Dh(i.value)?null:s.value||u.map(h=>h.value)})},[i,s.value,u]),R.useEffect(()=>{!t||(o({label:"",value:""}),l({label:"",value:""}),c([]))},[t]),S(we,{children:B(Rg,{buttonClass:Li.button,menuClass:Li.menu,position:"bottom-left",menuContainerClass:Li.menuContainer,button:B(we,{children:[B("span",{className:Li.buttonText,children:[S(dm,{datatype:r.as||f}),r.name]}),S("span",{className:Li.buttonIcon,children:S(bv,{})})]}),children:[S(de,{variant:"p",styleClass:"font-14",className:Li.filterName,children:r.name}),S(br,{label:"Operator",labelVariant:"static",selectedOption:i,onChange:h=>o(h),options:yv}),i.value&&!Dh(i.value)?S(we,{children:f==="boolean"?S(br,{options:[{value:"true",label:"TRUE"},{value:"false",label:"FALSE"}],selectedOption:s,onChange:l,label:"Filter Value",labelVariant:"static",className:Li.filterDropdown}):S(we,{children:rw(i.value)?S(IS,{selectedOptions:u,onChange:c,filter:{tableName:a,columnName:r.name},companyId:n,isSearchEnabled:!0,label:"Filter Value",labelVariant:"static",className:Li.filterDropdown,autoSelected:!1}):S(SS,{selectedOption:s,onChange:l,filter:{tableName:a,columnName:r.name},companyId:n,isSearchEnabled:!0,label:"Filter Value",labelVariant:"static",className:Li.filterDropdown,autoSelected:!1})})}):null]})})};var en={container:"_container_9vrf0_1",form:"_form_9vrf0_7",filterHeader:"_filterHeader_9vrf0_13",titleContent:"_titleContent_9vrf0_19",title:"_title_9vrf0_19",buttons:"_buttons_9vrf0_31",apply:"_apply_9vrf0_37",applyIcon:"_applyIcon_9vrf0_43",reset:"_reset_9vrf0_49",filterFields:"_filterFields_9vrf0_55",filters:"_filters_9vrf0_61",filterItem:"_filterItem_9vrf0_67",filterItemOperator:"_filterItemOperator_9vrf0_73",remove:"_remove_9vrf0_79"};const Sue=r=>rw(r.operator)?r.value.map(e=>["true","false"].includes(e)?e==="true":!Number.isNaN(e)&&Number(e)?Number(e):`'${e}'`):Dh(r.operator)?null:["true","false"].includes(r.value)?r.value==="true":!Number.isNaN(r.value)&&Number(r.value)?Number(r.value):`'${r.value}'`,XR=({filters:r,onApply:e,companyId:t,renderAdditionalHeaderContent:n})=>{const[a,i]=R.useState([]),o=()=>{i([]),e({tableName:"",filters:[]})},s=l=>{l.preventDefault();const u=a.map(c=>{const f={column:c.column,operator:c.operator},h=Sue({operator:c.operator,value:c.value});return h!=null&&Object.assign(f,{...f,value:h}),f});e({tableName:r[0].tableName,filters:u})};return S(we,{children:B("div",{className:en.container,children:[B("form",{className:en.form,onSubmit:s,onReset:o,children:[B("div",{className:en.filterHeader,children:[B("div",{className:en.titleContent,children:[S(de,{variant:"p",styleClass:"primary",className:en.title,children:"Filters:"}),n?n():null]}),B("div",{className:en.buttons,children:[B(Ce,{type:"submit",variant:"outlined",className:en.apply,children:[S(lt,{name:"filter-icon",className:en.applyIcon})," Apply"]}),B(Ce,{type:"reset",variant:"secondary",className:en.reset,children:[S(lt,{name:"reset-icon",className:en.applyIcon})," Reset Filters"]})]})]}),S("div",{className:en.filterFields,children:r[0].columns.map(l=>S(qR,{tableName:r[0].tableName,filter:l,isResetted:!a.find(u=>u.column===l.name),onChange:u=>i(c=>{const f=c.findIndex(v=>v.column===u.column);if(f===-1)return[...c,u];const h=[...c];return h[f]=u,h}),companyId:t},l.name))})]}),a.length?S("ul",{className:en.filters,children:a.map(l=>{var u;return B("li",{className:en.filterItem,children:[l.column,S("span",{className:en.filterItemOperator,children:((u=yv.find(c=>c.value===l.operator))==null?void 0:u.label)||""}),Dh(l.operator)?null:S(we,{children:Array.isArray(l.value)?`[${l.value.map(c=>c).join(",")}]`:l.value}),S(Ce,{type:"button",variant:"custom",className:en.remove,onClick:()=>i(c=>c.filter(f=>f.column!==l.column)),children:S(lt,{name:"close-icon"})})]},l.column)})}):null]})})};var JR={container:"_container_17x7x_1",tooltip:"_tooltip_17x7x_7"};const KR=({children:r,content:e,className:t=""})=>B("span",{className:`${JR.container} ${t}`,children:[e,S("span",{className:JR.tooltip,children:r})]}),Ei=({children:r,className:e,iconClass:t})=>S(KR,{className:e,content:S(lt,{name:"info-icon",className:t}),children:r});var al={"header-container":"_header-container_t2r6v_1","btn-container":"_btn-container_t2r6v_5","back-btn":"_back-btn_t2r6v_9","sql-btn":"_sql-btn_t2r6v_13","save-btn":"_save-btn_t2r6v_17","save-btn-icon":"_save-btn-icon_t2r6v_21"};const e3=R.createContext(null),il=()=>R.useContext(e3),Iue=({children:r})=>{const[e,t]=R.useState();return S(e3.Provider,{value:{globalTheme:e,setGlobalTheme:t},children:r})},t3=({setShowMetricCreateModal:r,isDisableSaveBtn:e,Heading:t,isDisableSqlBtn:n,setShowSaveMetricModal:a,setShowSqlModal:i})=>{const{globalTheme:o}=il();return B("div",{className:al["header-container"],children:[B("div",{className:al["btn-container"],children:[S(Ce,{type:"button",variant:"custom",size:"default",onClick:()=>r(!1),className:al["back-btn"],children:S(lt,{name:"arrow-back-icon"})}),S(de,{variant:"h1",styleClass:"primary",children:t})]}),B("div",{className:al["btn-container"],children:[B(Ce,{type:"button",variant:"custom",className:al["sql-btn"],onClick:()=>i(!0),isDisabled:n,children:[S(lt,{name:"sql-query-icon"}),"SQL"]}),B(Ce,{type:"submit",variant:"primary",className:al["save-btn"],isDisabled:e,onClick:()=>a(!0),style:o?{backgroundColor:`${o.dashboard.ctaColor} !important`,color:`${o.dashboard.ctaTextColor} !important`}:void 0,children:[S(lt,{name:"save-icon",className:al["save-btn-icon"]}),"Save to Dashboard"]})]})]})};var jg={"create-btn":"_create-btn_6ovk2_1","modal-container":"_modal-container_6ovk2_5","query-modal":"_query-modal_6ovk2_9",floatingCreateButton:"_floatingCreateButton_6ovk2_13",floatingCreateButtonIcon:"_floatingCreateButtonIcon_6ovk2_17"},$u={container:"_container_1q2ss_1",header:"_header_1q2ss_5",wrapper:"_wrapper_1q2ss_9","col-container":"_col-container_1q2ss_13",column:"_column_1q2ss_17",columnText:"_columnText_1q2ss_21"};const r3=({setselectTable:r,selectTable:e,tableList:t,columnList:n})=>B("div",{className:$u.container,children:[S("div",{className:$u.header,children:S(br,{onChange:r,selectedOption:e,options:t,icon:S(lt,{name:"table-icon"}),labelVariant:"static"})}),B("div",{className:$u.wrapper,children:[S(de,{variant:"h1",styleClass:"primary",children:"Columns"}),S("div",{className:$u["col-container"],children:n.map(({as:a,datatype:i})=>B("div",{className:$u.column,children:[S(dm,{datatype:i}),S(de,{variant:"p",styleClass:"font-14",className:$u.columnText,children:a})]},a))})]})]});var Be={container:"_container_1cslw_1",header:"_header_1cslw_7",headerText:"_headerText_1cslw_13",tab:"_tab_1cslw_19",tabText:"_tabText_1cslw_25",tabHeading:"_tabHeading_1cslw_31",form:"_form_1cslw_37",inputWrapper:"_inputWrapper_1cslw_43",input:"_input_1cslw_43",selectWrapper:"_selectWrapper_1cslw_55",select:"_select_1cslw_55",label:"_label_1cslw_67",series:"_series_1cslw_73",legendWrapper:"_legendWrapper_1cslw_79",seriesWrapper:"_seriesWrapper_1cslw_85",valueLabelWrapper:"_valueLabelWrapper_1cslw_91",singleCheckBox:"_singleCheckBox_1cslw_97"},nw={tab:"_tab_1imil_1",button:"_button_1imil_7",activeTab:"_activeTab_1imil_15"};const aw=({options:r,activeTab:e,setActiveTab:t,className:n="",tabText:a=""})=>S("div",{className:`${nw.tab} ${n}`,children:r.map(i=>S(Ce,{variant:"custom",type:"button",className:`${nw.button} ${e===i&&nw.activeTab} ${a}`,onClick:()=>t(i),children:i},i))}),Tue=({setMargins:r,margins:e,legendSettings:t,setLegendSettings:n,labelSettings:a,setLabelSettings:i,axisSettings:o,setAxisSettings:s,chartType:l,setChartType:u,customSettings:c,setCustomSettings:f,backGroundColor:h,setBackGroundColor:v})=>{const d=["Margins","Legend","Custom"],p=["Custom"],[g,y]=R.useState("Custom");return B("div",{className:Be.container,children:[S("div",{className:"h-[10%]",children:S(aw,{options:l!=="single value"?d:p,activeTab:g,setActiveTab:y,className:Be.tab,tabText:Be.tabText})}),B("form",{className:Be.form,children:[g==="Margins"&&B("div",{className:Be.inputWrapper,children:[S("div",{className:Be.input,children:S(Ct,{type:"number",label:"Top",onChange:m=>r(_=>({..._,marginTop:parseInt(m.target.value,10)})),defaultValue:e.marginTop})}),S("div",{className:Be.input,children:S(Ct,{type:"number",label:"Bottom",onChange:m=>r(_=>({..._,marginBottom:parseInt(m.target.value,10)})),defaultValue:e.marginBottom})}),S("div",{className:Be.input,children:S(Ct,{type:"number",label:"Left",defaultValue:e.marginLeft,onChange:m=>r(_=>({..._,marginLeft:parseInt(m.target.value,10)}))})}),S("div",{className:Be.input,children:S(Ct,{type:"number",label:"Right",defaultValue:e.marginRight,onChange:m=>r(_=>({..._,marginRight:parseInt(m.target.value,10)}))})})]}),g==="Legend"&&B("div",{className:Be.legendWrapper,children:[S(Ct,{type:"checkbox",label:"Show Legend",checked:t.show,onChange:m=>n(_=>({..._,show:m.target.checked}))}),B("div",{children:[S(de,{variant:"h1",styleClass:"primary",children:"Position"}),B("div",{className:Be.inputWrapper,children:[S("div",{className:Be.input,children:S(Ct,{type:"number",label:"Top",defaultValue:t.top,onChange:m=>n(_=>({..._,top:parseInt(m.target.value,10)}))})}),S("div",{className:Be.input,children:S(Ct,{type:"number",label:"Bottom",defaultValue:t.bottom,onChange:m=>n(_=>({..._,bottom:parseInt(m.target.value,10)}))})}),S("div",{className:Be.input,children:S(Ct,{type:"number",label:"Left",defaultValue:t.left,onChange:m=>n(_=>({..._,left:parseInt(m.target.value,10)}))})}),S("div",{className:Be.input,children:S(Ct,{type:"number",label:"Right",defaultValue:t.right,onChange:m=>n(_=>({..._,right:parseInt(m.target.value,10)}))})})]})]}),B("div",{className:Be.selectWrapper,children:[S(de,{variant:"h1",styleClass:"primary",children:"Appearance"}),S("div",{className:Be.select,children:S(Jt,{value:t.position,options:[{label:"Horizontal",value:"horizontal"},{label:"Vertical",value:"vertical"}],onChange:m=>n(_=>({..._,position:m}))})})]})]}),g==="Custom"&&B("div",{className:Be.series,children:[S(de,{styleClass:"font-14c",variant:"p",className:Be.tabHeading,children:"Chart preferences"}),l!=="single value"&&B(we,{children:[B("div",{className:Be.seriesWrapper,children:[S(de,{variant:"h1",styleClass:"font-14",children:"Value labels"}),S("div",{className:Be.valueLabelWrapper,children:S(Jt,{value:a.position,options:[{label:"Hidden",value:"hidden"},{label:"Top",value:"top"},{label:"Bottom",value:"bottom"},{label:"Right",value:"right"},{label:"Left",value:"left"},{label:"Inside",value:"inside"}],onChange:m=>i(m==="hidden"?_=>({..._,show:!1,position:m}):_=>({..._,show:!0,position:m}))})})]}),l!=="pie"&&l!=="doughnut"&&l!=="funnel"&&l!=="gauge"&&l!=="sankey"&&l!=="singleValue"&&l!=="table"&&B(we,{children:[B("div",{className:Be.seriesWrapper,children:[S(de,{variant:"h1",styleClass:"font-14",className:"font-medium",children:"Axis"}),S("div",{className:Be.select,children:S(Jt,{value:o.axis,options:[{label:"Left",value:"left"},{label:"Right",value:"right"}],onChange:m=>s(_=>({..._,axis:m}))})})]}),l==="bar"||l==="row"||l==="stack"||l==="histogram"?S(Ct,{type:"checkbox",label:"Show Bar Background",checked:h.show,onChange:m=>v(_=>({..._,show:m.target.checked}))}):null,B("div",{className:Be.seriesWrapper,children:[B(de,{variant:"h1",styleClass:"font-14",className:Be.label,children:["Hide Axis labels",S(Ei,{children:"Axis labels represents the x and y axis values"})]}),S("div",{className:Be.select,children:S(Jt,{value:c.axisLabels,options:[{label:"Hide X-axis labels",value:"x"},{label:"Hide Y-axis labels",value:"y"},{label:"Hide both X and Y(axis) labels",value:"both"},{label:"None",value:"none"}],onChange:m=>f(_=>({..._,axisLabels:m}))})})]}),B("div",{className:Be.seriesWrapper,children:[B(de,{variant:"h1",styleClass:"font-14",className:Be.label,children:["Hide Splitlines",S(Ei,{children:"Splitline is the reference lines that run along the directional x and y axis which act as reference markers"})]}),S("div",{className:Be.select,children:S(Jt,{value:c.hideSplitLines,options:[{label:"Hide horizontal splitline",value:"horizontal"},{label:"Hide vertical splitline",value:"vertical"},{label:"Hide both splitline",value:"both"},{label:"None",value:"none"}],onChange:m=>f(_=>({..._,hideSplitLines:m}))})})]}),B("div",{className:Be.seriesWrapper,children:[B(de,{variant:"h1",styleClass:"font-14",className:Be.label,children:["Hide Axis Line",S(Ei,{children:"The x-axis and y-axis lines act as a graph base from which the chart starts"})]}),S("div",{className:Be.select,children:S(Jt,{value:c.hideAxisLines,options:[{label:"Hide X-axis line",value:"x"},{label:"Hide Y-axis line",value:"y"},{label:"Hide both X and Y(axis) lines",value:"both"},{label:"None",value:"none"}],onChange:m=>f(_=>({..._,hideAxisLines:m}))})})]}),l==="bar"||l==="row"||l==="stack"?B(we,{children:[B("div",{className:Be.seriesWrapper,children:[B(de,{variant:"h1",styleClass:"font-14",className:Be.label,children:["Modify Bar width",S(Ei,{children:"The width of each individual bar rectangle of the graph"})]}),S(Ct,{type:"number",label:"",onChange:m=>f(_=>({..._,barWidth:parseInt(m.target.value,10)})),defaultValue:c.barWidth})]}),B("div",{className:Be.seriesWrapper,children:[B(de,{variant:"h1",styleClass:"font-14",className:Be.label,children:["Modify Bar radius",S(Ei,{children:"The property that rounds the corners of the element's outer border edge"})]}),S(Ct,{type:"number",label:"",onChange:m=>f(_=>({..._,barRadius:parseInt(m.target.value,10)})),defaultValue:c.barRadius})]})]}):null]})]}),l==="single value"&&B(we,{children:[B("div",{className:Be.seriesWrapper,children:[S(de,{variant:"h1",styleClass:"font-14",className:Be.label,children:"Single Value Chart Font Size"}),S(Ct,{type:"number",label:"",onChange:m=>f(_=>({..._,fontSize:parseInt(m.target.value,10)})),defaultValue:c.fontSize})]}),B("div",{className:Be.singleCheckBox,children:[S(Ct,{type:"checkbox",label:"",checked:c.subHeaderShow,onChange:m=>f(_=>({..._,subHeaderShow:m.target.checked}))}),B(de,{variant:"h1",styleClass:"font-14",className:Be.label,children:["Single Value Sub-Header",S(Ei,{children:"Single Value Sub-Header"})]})]}),c.subHeaderShow&&B(we,{children:[B("div",{className:Be.seriesWrapper,children:[S(de,{variant:"h1",styleClass:"font-14",className:Be.label,children:"Sub-Header Display Text"}),S(Ct,{type:"text",label:"",placeholder:"Enter the text to display",onChange:m=>f(_=>({..._,displayText:m.target.value})),defaultValue:c.displayText})]}),B("div",{className:Be.seriesWrapper,children:[S(de,{variant:"h1",styleClass:"font-14",className:Be.label,children:"Sub-Header Font Size"}),S(Ct,{type:"number",label:"",onChange:m=>f(_=>({..._,subHeaderFontSize:parseInt(m.target.value,10)})),defaultValue:c.subHeaderFontSize})]})]}),B("div",{className:Be.seriesWrapper,children:[S(de,{variant:"h1",styleClass:"primary",children:"Date formatting"}),S("div",{className:Be.valueLabelWrapper,children:S(Jt,{value:c.dateFormatter,options:[{label:"None",value:"none"},{label:"dd-mm-yyyy",value:"dd-mm-yyyy"},{label:"mm-dd-yyyy",value:"mm-dd-yyyy"},{label:"yyyy-mm-dd",value:"yyyy-mm-dd"},{label:"dd/mm/yyyy",value:"dd/mm/yyyy"},{label:"mm/dd/yyyy",value:"mm/dd/yyyy"},{label:"yyyy/mm/dd",value:"yyyy/mm/dd"},{label:"hh:mm:ss",value:"hh:mm:ss"}],onChange:m=>f(_=>({..._,dateFormatter:m}))})})]}),B("div",{className:Be.seriesWrapper,children:[S(de,{variant:"h1",styleClass:"primary",children:"Number formatting"}),S("div",{className:Be.valueLabelWrapper,children:S(Jt,{value:c.numberFormatter,textSize:"12px",options:[{label:"Original value",value:"original"},{label:"Adaptive formatting",value:"adaptive"},{label:",d (12345.432 => 12,345)",value:"d"},{label:".1s (12345.432 => 10k)",value:"1s"},{label:".3s (12345.432 => 12.3k)",value:"3s"},{label:",.1% (12345.432 => 1,234,543.2%)",value:"1%"},{label:",.2% (12345.432 => 1234543.20%)",value:"2%"},{label:",.3% (12345.432 => 1234543.200%)",value:"3%"},{label:".4r (12345.432 => 12350)",value:"4r"},{label:",.1f (12345.432 => 12,345.4)",value:"1f"},{label:",.2f (12345.432 => 12,345.43)",value:"2f"},{label:",.3f (12345.432 => 12,345.432)",value:"3f"},{label:"+, (12345.432 => +12,345.432)",value:"+"},{label:"$,.2f (12345.432 => $12,345.43)",value:"$"},{label:"Duration in ms (66000 => 1m 6s)",value:"ms1"},{label:"Duration in ms (1.40008 => 1ms 400\u03BCs 80ns)",value:"ms2"}],onChange:m=>f(_=>({..._,numberFormatter:m}))})})]})]})]})]})]})};var tn={chartButtonContainer:"_chartButtonContainer_1fmoa_1","chartButton-header":"_chartButton-header_1fmoa_7","settingsTab-header-control":"_settingsTab-header-control_1fmoa_15",tabContainer:"_tabContainer_1fmoa_23",tab:"_tab_1fmoa_23",tabText:"_tabText_1fmoa_39",chartButtons:"_chartButtons_1fmoa_47",chartButton:"_chartButton_1fmoa_1",chartButtonSelected:"_chartButtonSelected_1fmoa_63",chartTypesButton:"_chartTypesButton_1fmoa_71",button:"_button_1fmoa_79",propertyButton:"_propertyButton_1fmoa_87",settings:"_settings_1fmoa_15",crossIcon:"_crossIcon_1fmoa_103"};const Aue=r=>S("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",...r,children:S("path",{fill:"currentColor",d:"M7 3H5v6h2V3m12 0h-2v10h2V3M3 13h2v8h2v-8h2v-2H3v2m12-6h-2V3h-2v4H9v2h6V7m-4 14h2V11h-2v10m4-6v2h2v4h2v-4h2v-2h-6Z"})}),Cue=r=>S("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",...r,children:S("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeWidth:2,d:"M20 20L4 4m16 0L4 20"})}),Nue=({chartType:r,setChartType:e,data:t,setXAxis:n,setYAxisList:a,xAxis:i,setMeasure:o,setStep:s,step:l,measure:u,setSankeyValues:c,singleValue:f,setSingleValue:h,setSettingsShow:v,setMargins:d,margins:p,legendSettings:g,setLegendSettings:y,labelSettings:m,setLabelSettings:_,axisSettings:b,setAxisSettings:x,customSettings:M,setCustomSettings:w,backGroundColor:D,setBackGroundColor:T})=>{const[I,A]=R.useState($o),N="Chart types",L="Chart properties",[E,O]=R.useState(N),P={background:"#e5e7eb",width:"100%",height:"100%",paddingTop:"8px",paddingBottom:"8px",display:"flex",alignItems:"center",justifyContent:"center"};return B("div",{className:tn.chartButtonContainer,children:[B("div",{className:tn["chartButton-header"],children:[B(de,{styleClass:"font-14c",variant:"h1",className:tn.settings,children:[S(Aue,{}),"Chart Settings"]}),S("div",{className:tn.crossIcon,children:S(Cue,{onClick:()=>v(!1)})})]}),B("div",{className:tn.chartButtons,children:[B("div",{className:tn["settingsTab-header-control"],children:[B(Ce,{type:"button",variant:"custom",className:`${tn.chartButton} ${I===$o&&tn.chartButtonSelected}`,onClick:()=>A($o),children:[I===$o&&S("div",{style:P,children:"General"}),I!==$o&&"General"]}),B(Ce,{type:"button",variant:"custom",className:`${tn.chartButton} ${I===Tl&&tn.chartButtonSelected}`,onClick:()=>A(Tl),children:[I===Tl&&S("div",{style:P,children:"Configuration"}),I!==Tl&&"Configuration"]})]}),I===$o&&B(we,{children:[S("div",{className:tn.tabContainer,children:S(aw,{activeTab:E,options:[N,L],setActiveTab:O,className:tn.tab,tabText:tn.tabText})}),E===N&&S("div",{className:tn.button,children:S(dS,{setChartType:e})}),E===L&&S(we,{children:r&&S("div",{className:tn.button,children:S(vS,{data:t,setXAxis:n,xAxis:i,setYAxisList:a,chartType:r,setStep:s,setMeasure:o,step:l,measure:u,setSankeyValues:c,singleValue:f,setSingleValue:h,setSettingsShow:v})})})]}),I===Tl&&S(Tue,{setMargins:d,margins:p,legendSettings:g,setLegendSettings:y,labelSettings:m,setLabelSettings:_,axisSettings:b,setAxisSettings:x,customSettings:M,setCustomSettings:w,chartType:r,setChartType:e,backGroundColor:D,setBackGroundColor:T})]})]})};var Pt={searchCommand:"_searchCommand_1cvrv_3","chartTab-container":"_chartTab-container_1cvrv_11",chartText:"_chartText_1cvrv_19",charts:"_charts_1cvrv_27",metricChart:"_metricChart_1cvrv_35",metricChartHeader:"_metricChartHeader_1cvrv_43",metricChartEmpty:"_metricChartEmpty_1cvrv_51","chartTab-wrapper":"_chartTab-wrapper_1cvrv_59","chartTab-wrapper-head":"_chartTab-wrapper-head_1cvrv_67",fullQuery:"_fullQuery_1cvrv_75",fullQueryIcon:"_fullQueryIcon_1cvrv_83",noQuery:"_noQuery_1cvrv_91","tableTab-header":"_tableTab-header_1cvrv_99","chartButton-header":"_chartButton-header_1cvrv_107",chartButtonContainer:"_chartButtonContainer_1cvrv_115",searchWrapper:"_searchWrapper_1cvrv_123",searchIcon:"_searchIcon_1cvrv_131",chartConfigure:"_chartConfigure_1cvrv_139",chartSettings:"_chartSettings_1cvrv_147",labels:"_labels_1cvrv_155",chartButtons:"_chartButtons_1cvrv_163",chartButton:"_chartButton_1cvrv_107"};const n3=r=>S("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",...r,children:S("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeWidth:2,d:"m21 21l-4.486-4.494M19 10.5a8.5 8.5 0 1 1-17 0a8.5 8.5 0 0 1 17 0Z"})}),Uu=r=>B("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",...r,children:[S("path",{fill:"currentColor",d:"M12 2A10 10 0 1 0 22 12A10 10 0 0 0 12 2Zm0 18a8 8 0 1 1 8-8A8 8 0 0 1 12 20Z",opacity:.5}),S("path",{fill:"currentColor",d:"M20 12h2A10 10 0 0 0 12 2V4A8 8 0 0 1 20 12Z",children:S("animateTransform",{attributeName:"transform",dur:"1s",from:"0 12 12",repeatCount:"indefinite",to:"360 12 12",type:"rotate"})})]}),a3=({labels:r,datasets:e,funnelData:t,chartType:n,setChartType:a,data:i,setXAxis:o,setYAxisList:s,xAxis:l,setMeasure:u,setStep:c,step:f,measure:h,setSankeyValues:v,sankeyData:d,singleValue:p,setSingleValue:g,singleValueData:y,setMargins:m,margins:_,legendSettings:b,setLegendSettings:x,labelSettings:M,setLabelSettings:w,customSettings:D,setCustomSettings:T,axisSettings:I,setAxisSettings:A,updateGroup:N,isLoading:L,isEnableGroupBy:E,backGroundColor:O,setBackGroundColor:P,headerChild:H})=>{var Y,q,Q,ne;const{globalTheme:F}=il(),[G,Z]=R.useState(!1),[te,V]=R.useState(!1);return B("div",{className:Pt["chartTab-container"],children:[B("div",{className:Pt.metricChartHeader,children:[S(de,{styleClass:"primary",variant:"p",className:"",children:"Preview"}),H]}),!(i!=null&&i.length)&&L&&S("div",{className:Pt["loader-container"],children:S(Uu,{style:{width:"50px",height:"50px",color:"blue"}})}),!(i!=null&&i.length)&&!L&&B("div",{className:Pt.metricChartEmpty,children:[S("div",{className:Pt.searchWrapper,children:S(n3,{className:Pt.searchIcon})}),S("div",{className:Pt.message,children:S(de,{styleClass:"font-14b",variant:"p",children:"Uh-oh, Nothing to display"})}),S("div",{className:Pt.chartButton,children:S(de,{styleClass:"font-14a",variant:"p",children:"No data found! Run a query to display charts"})})]}),!!(i!=null&&i.length)&&!L&&S("div",{className:Pt.metricChart,children:B("div",{className:Pt["chartTab-wrapper"],children:[B("div",{className:Pt["chartTab-wrapper-head"],children:[S(de,{styleClass:"primary",variant:"p",className:"",children:"Charts"}),B("div",{className:Pt.chartButtons,children:[S(Ce,{type:"button",variant:"custom",className:Pt.chartButton,onClick:()=>{Z(!G)},children:"Chart Settings"}),S(Ce,{type:"button",variant:"custom",className:r!=null&&r.length?Pt.fullQuery:Pt.noQuery,onClick:r!=null&&r.length?()=>V(!0):void 0,children:S(lt,{name:"fullscreen-icon",className:Pt.fullQueryIcon})})]})]}),G&&S("div",{className:Pt.chartSettings,children:S(Nue,{chartType:n,setChartType:a,data:i,setXAxis:o,setYAxisList:s,xAxis:l,setMeasure:u,setStep:c,step:f,measure:h,setSankeyValues:v,singleValue:p,setSingleValue:g,setSettingsShow:Z,setMargins:m,margins:_,legendSettings:b,setLegendSettings:x,labelSettings:M,setLabelSettings:w,axisSettings:I,setAxisSettings:A,customSettings:D,setCustomSettings:T,backGroundColor:O,setBackGroundColor:P})}),r!=null&&r.length?S("div",{className:Pt.labels,children:S(kg,{labels:r,data:{labels:r,datasets:e},chartType:n,funnelData:t,sankeyData:d,singleValueData:y,margins:_,colors:F?(q=(Y=F.chart.palettes)==null?void 0:Y.find(oe=>oe.name===F.chart.selected))==null?void 0:q.colors:void 0,legendSettings:b,labelSettings:M,axisSettings:I,customSettings:D,backGroundColor:O,updateGroup:N,isEnableGroupBy:E,chartClickConfig:{isEnable:!1,baseUrl:"",dynamic:"{{value}}",route:"/{{value}}",routeType:"internal"},enableSaveAs:!0})}):B("div",{className:Pt.metricChartEmpty,children:[S("div",{className:Pt.searchWrapper,children:S(n3,{className:Pt.searchIcon})}),S("div",{className:Pt.message,children:S(de,{styleClass:"font-14b",variant:"p",children:"Uh-oh, Nothing to display"})}),S("div",{className:Pt.chartButton,children:S(de,{styleClass:"font-14a",variant:"p",children:"Choose an appropriate chart type and start visulaizing your data"})})]})]})}),S(tw,{isShow:te,onCancel:()=>V(!1),chart:{labels:r,data:{labels:r,datasets:e},chartType:n,funnelData:t,sankeyData:d,singleValueData:y,margins:_,colors:F?(ne=(Q=F.chart.palettes)==null?void 0:Q.find(oe=>oe===F.chart.selected))==null?void 0:ne.colors:void 0,legendSettings:b,labelSettings:M,axisSettings:I,customSettings:D,backGroundColor:O,enableSaveAs:!0,chartClickConfig:{isEnable:!1,baseUrl:"",dynamic:"{{value}}",route:"/{{value}}",routeType:"internal"}}})]})};var Bg={container:"_container_yjeiv_1",wrapper:"_wrapper_yjeiv_5",text:"_text_yjeiv_9",table:"_table_yjeiv_12"},ei={container:"_container_1jkce_1",table:"_table_1jkce_9",tableHead:"_tableHead_1jkce_17",tableRow:"_tableRow_1jkce_25",tableHeadCol:"_tableHeadCol_1jkce_33",tableHeadColText:"_tableHeadColText_1jkce_41",tableRowCol:"_tableRowCol_1jkce_49",tableColText:"_tableColText_1jkce_57",empty:"_empty_1jkce_65",error:"_error_1jkce_73"};const i3=({data:r,isError:e})=>B("div",{className:ei.container,children:[!!(r!=null&&r.length)&&!e&&B("table",{className:ei.table,children:[S("thead",{className:ei.tableHead,children:S("tr",{className:ei.tableRow,children:Object.keys(r[0]).map(t=>S("th",{className:ei.tableHeadCol,scope:"col",children:S(de,{styleClass:"font-14c",variant:"h1",className:ei.tableHeadColText,children:t})},t))})}),S("tbody",{children:r==null?void 0:r.map((t,n)=>S("tr",{children:Object.keys(r[0]).map((a,i)=>S("td",{className:ei.tableRowCol,children:S(de,{styleClass:"font-14",variant:"p",className:ei.tableColText,children:JSON.stringify(t[a])})},i))},n))})]}),!(r!=null&&r.length)&&!e&&S("div",{className:ei.empty,children:"Table is empty"}),e&&S("div",{className:ei.error,children:r.message})]}),Lue=({previewTableDataList:r})=>S("div",{className:Bg.container,children:S("div",{className:Bg.wrapper,children:r==null?void 0:r.map(e=>B("div",{className:Bg.text,children:[S(de,{variant:"h1",styleClass:"primary",className:"",children:e.name}),S("div",{className:Bg.table,children:S(i3,{data:e.data,isError:e.isError})})]},e.name))})});var ol={container:"_container_38zl3_1",header:"_header_38zl3_5","text-container":"_text-container_38zl3_9","btn-container":"_btn-container_38zl3_13",tabButton:"_tabButton_38zl3_16",selectedTab:"_selectedTab_38zl3_19",table:"_table_38zl3_22"},rn={"table-loader-container":"_table-loader-container_o6rhd_1",tableData:"_tableData_o6rhd_7",tableHeadCol:"_tableHeadCol_o6rhd_13",tableRow:"_tableRow_o6rhd_19",tableRowCol:"_tableRowCol_o6rhd_25",row:"_row_o6rhd_31",container:"_container_o6rhd_37",table:"_table_o6rhd_1",previewTable:"_previewTable_o6rhd_49",preview:"_preview_o6rhd_49",previewText:"_previewText_o6rhd_61",noData:"_noData_o6rhd_67",error:"_error_o6rhd_73",errorMsg:"_errorMsg_o6rhd_79",tableIcon:"_tableIcon_o6rhd_85"};const Eue=r=>S("svg",{viewBox:"0 0 15 15",width:"1.2em",height:"1.2em",...r,children:S("path",{fill:"none",stroke:"currentColor",d:"M.5 4.5h14m-10-4v14m-3-14h12a1 1 0 0 1 1 1v12a1 1 0 0 1-1 1h-12a1 1 0 0 1-1-1v-12a1 1 0 0 1 1-1Z"})}),o3=({data:r,isLoading:e,error:t})=>S("div",{className:rn.container,children:B("div",{className:rn.previewTable,children:[S("div",{className:rn.preview,children:S(de,{styleClass:"font-14c",variant:"h1",className:rn.previewText,children:"Preview"})}),B("div",{className:rn.tableData,children:[e&&!(r!=null&&r.length)&&S("div",{className:rn["table-loader-container"],children:S(Uu,{style:{width:"50px",height:"50px",color:"blue"}})}),!!(r!=null&&r.length)&&!e&&B("table",{className:rn.table,children:[S("thead",{children:S("tr",{className:rn.row,children:Object.keys(r[0]).map(n=>S("th",{className:rn.tableHeadCol,scope:"col",children:S(de,{styleClass:"font-14c",variant:"h1",children:n})},n))})}),S("tbody",{children:r.map((n,a)=>S("tr",{className:rn.tableRow,children:Object.keys(r[0]).map((i,o)=>S("td",{className:rn.tableRowCol,children:S(de,{styleClass:"font-14",variant:"p",children:JSON.stringify(n[i])})},o))},a))})]}),!(r!=null&&r.length)&&!e&&!t.length&&B("div",{className:rn.noData,children:[S(Eue,{className:rn.tableIcon,width:"60px",height:"60px"}),S(de,{styleClass:"font-14b",variant:"p",children:"No data available to preview"}),S(de,{styleClass:"font-14a",variant:"p",children:"Run your query to preview data"})]}),t&&S("div",{className:rn.error,children:S(de,{styleClass:"primary",className:rn.errorMsg,variant:"p",children:t})})]})]})}),s3=({outpuTableData:r,outputError:e,isOutputLoading:t,previewTableDataList:n})=>{const[a,i]=R.useState(Il),o={background:"#e5e7eb",width:"100%",height:"100%",paddingTop:"4px",paddingBottom:"4px",display:"flex",alignItems:"center",justifyContent:"center"};return B("div",{className:ol.container,children:[B("div",{className:ol.header,children:[B("div",{className:ol["text-container"],children:[S(de,{styleClass:"font-14c",variant:"h1",children:"Tables"}),S(de,{styleClass:"font-14",variant:"p",children:"Preview your selected table & output table values"})]}),B("div",{className:ol["btn-container"],children:[B(Ce,{type:"button",variant:"custom",className:ol.tabButton,onClick:()=>i(vc),children:[a===vc&&S("div",{style:o,children:"Input Table"}),a!==vc&&"Input Table"]}),B(Ce,{type:"button",variant:"custom",className:ol.tabButton,onClick:()=>i(Il),children:[a===Il&&S("div",{style:o,children:"Output Table"}),a!==Il&&"Output Table"]})]})]}),a===vc&&S(Lue,{previewTableDataList:n}),a===Il&&S("div",{className:ol.table,children:S(o3,{data:r,isLoading:t,error:e})})]})};var Oi={"main-container":"_main-container_wy97p_1","outputTab-header":"_outputTab-header_wy97p_5",wrapper:"_wrapper_wy97p_9",searchCommand:"_searchCommand_wy97p_12",tabButton:"_tabButton_wy97p_15",tabActive:"_tabActive_wy97p_18"};const l3=({data:r,error:e,isLoading:t,labels:n,funnelData:a,chartType:i,datasets:o,setChartType:s,setXAxis:l,setYAxisList:u,xAxis:c,setMeasure:f,setStep:h,step:v,measure:d,setSankeyValues:p,sankeyData:g,previewTableDataList:y,singleValue:m,setSingleValue:_,singleValueData:b,setMargins:x,margins:M,legendSettings:w,setLegendSettings:D,labelSettings:T,setLabelSettings:I,axisSettings:A,setAxisSettings:N,customSettings:L,setCustomSettings:E,updateGroup:O,isEnableGroupBy:P,backGroundColor:H,setBackGroundColor:F,moreTabs:G})=>{var V;const[Z,te]=R.useState(hc);return B("div",{className:Oi["main-container"],children:[B("div",{className:Oi["outputTab-header"],children:[B(Ce,{type:"button",variant:"custom",className:`${Oi.tabButton} ${Z===hc&&Oi.tabActive}`,onClick:()=>te(hc),children:[S(lt,{name:"table-tab-icon"})," Tables"]}),B(Ce,{type:"button",variant:"custom",className:`${Oi.tabButton} ${Z===gv&&Oi.tabActive}`,onClick:()=>te(gv),children:[S(lt,{name:"visualization-icon"}),"Visualizations"]}),G==null?void 0:G.map(Y=>S(Ce,{type:"button",variant:"custom",className:`${Oi.tabButton} ${Z===Y.name&&Oi.tabActive}`,onClick:()=>te(Y.name),children:Y.tab},Y.name))]}),B("div",{className:Oi.wrapper,children:[Z===hc&&S(s3,{outpuTableData:r,isOutputLoading:t,outputError:e,previewTableDataList:y}),Z===gv&&S(a3,{labels:n,funnelData:a,chartType:i,datasets:o,data:r,setChartType:s,setXAxis:l,setYAxisList:u,xAxis:c,setMeasure:f,setStep:h,step:v,measure:d,setSankeyValues:p,sankeyData:g,singleValue:m,setSingleValue:_,singleValueData:b,setMargins:x,margins:M,legendSettings:w,setLegendSettings:D,labelSettings:T,setLabelSettings:I,axisSettings:A,setAxisSettings:N,customSettings:L,setCustomSettings:E,updateGroup:O,isEnableGroupBy:P,isLoading:t,backGroundColor:H,setBackGroundColor:F}),(V=G==null?void 0:G.find(Y=>Y.name===Z))==null?void 0:V.tabContent]})]})};var ke={"form-container":"_form-container_z8ldj_1","field-container":"_field-container_z8ldj_5","field-label":"_field-label_z8ldj_9","field-wrapper":"_field-wrapper_z8ldj_13","field-inner-container":"_field-inner-container_z8ldj_17","field-value":"_field-value_z8ldj_21",fieldValueIcon:"_fieldValueIcon_z8ldj_25","field-add-btn":"_field-add-btn_z8ldj_29",fieldAddBtnIcon:"_fieldAddBtnIcon_z8ldj_33","field-value-container":"_field-value-container_z8ldj_37","field-prompt":"_field-prompt_z8ldj_41",group:"_group_z8ldj_1",tooltipWrapper:"_tooltipWrapper_z8ldj_45",tooltip:"_tooltip_z8ldj_45",dropdown:"_dropdown_z8ldj_57",filterDropdown:"_filterDropdown_z8ldj_61",filterValues:"_filterValues_z8ldj_65",columnText:"_columnText_z8ldj_69",disabled:"_disabled_z8ldj_73",checkIcon:"_checkIcon_z8ldj_77",generateButton:"_generateButton_z8ldj_81"},sl={button:"_button_18a2n_1",menu:"_menu_18a2n_7",inputLabel:"_inputLabel_18a2n_13",input:"_input_18a2n_13",label:"_label_18a2n_25",menuContainer:"_menuContainer_18a2n_31",icon:"_icon_18a2n_37",container:"_container_18a2n_43"};const Oue=[{label:"Last Week",value:"Last Week"},{label:"This Week",value:"This Week"},{label:"Last Month",value:"Last Month"},{label:"This Month",value:"This Month"},{label:"Last Year",value:"Last Year"},{label:"This Year",value:"This Year"},{label:"Yesterday",value:"Yesterday"},{label:"Today",value:"Today"},{label:"Custom",value:"Custom"}],Fg={value:"",from:"",to:""},Pue=r=>{if(!r)return Fg;if(r.includes(" - ")){const[e,t]=r.split(" - ");return{...Fg,value:r,from:e,to:t}}return{...Fg,value:r}},u3=({isShowlabel:r,timeGrainValue:e="",setTimeGrainValue:t,register:n,className:a="",isDisabled:i,containerClass:o=""})=>{const[s,l]=R.useState(Pue(e));return R.useEffect(()=>{s.value&&s.value!=="Custom"?t(s.value):s.from&&s.to&&t(`${s.from} - ${s.to}`)},[t,s]),R.useEffect(()=>{!s.value||t(s.value)},[s.value]),R.useEffect(()=>{e||l(Fg)},[e]),S(we,{children:B("div",{className:o,children:[r?S(de,{styleClass:"font-14c",variant:"p",className:sl.label,children:"Time Grain"}):null,S(Rg,{className:a,buttonClass:sl.button,isDisabled:i,menuClass:sl.menu,menuContainerClass:sl.menuContainer,button:S(Ct,{inputClass:sl.input,type:"text",placeholder:"time range",register:n==null?void 0:n("timeGrain"),value:e,onChange:({target:{value:u}})=>l(c=>({...c,value:u})),isDisabled:!0,icon:S("span",{className:sl.icon,children:S(bv,{})})}),children:B("div",{className:sl.container,children:[S(Jt,{options:Oue,label:"Select Time Range",value:s.value,onChange:u=>l(c=>({...c,value:u}))}),s.value==="Custom"?B(we,{children:[S(Ct,{label:"From Date",type:"date",value:s.from,onChange:({target:{value:u}})=>l(c=>({...c,from:u}))}),S(Ct,{label:"To Date",type:"date",value:s.to,onChange:({target:{value:u}})=>l(c=>({...c,to:u}))})]}):null]})})]})})},zue=r=>S("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",...r,children:S("path",{fill:"currentColor",d:"M12 2A10 10 0 0 0 2 12a10 10 0 0 0 10 10a10 10 0 0 0 10-10h-2a8 8 0 0 1-8 8a8 8 0 0 1-8-8a8 8 0 0 1 8-8V2m6.78 1a.69.69 0 0 0-.48.2l-1.22 1.21l2.5 2.5L20.8 5.7c.26-.26.26-.7 0-.95L19.25 3.2c-.13-.13-.3-.2-.47-.2m-2.41 2.12L9 12.5V15h2.5l7.37-7.38l-2.5-2.5Z"})}),c3=(r,e)=>r.reduce((t,n)=>{const a=n[e];return a&&(t[a]||(t[a]=[]),t[a].push(n)),t},{}),kue=(r,e,t)=>{const n=t.toLowerCase(),a=e==="number",i=e==="string",o=e==="date";let s="";a?s=n==="mongodb"||n==="mysql"?"AS SIGNED":"AS BIGINT":i?n==="postgres"||n==="redshift"||n==="snowflake"?s="AS VARCHAR":n==="mongodb"||n==="mysql"?s="AS CHAR":s="AS STRING":o&&(s="AS DATE");let l="";return n==="mongodb"?l=`\`${r}\``:n==="bigquery"||n==="mysql"?l=`${r}`:l=`"${r}"`,s?`CAST(${l} ${s})`:l},Rue=(r,e,t)=>{const n=Object.keys(e).map(s=>`${e[s][0].tableName.split(".").join("_")}_filter`),a=Object.keys(e).map((s,l)=>`${n[l]} AS (
|
|
262
|
+
SELECT * FROM ${e[s][0].tableName} WHERE ${e[s].map(u=>u.datatype==="date"?`${u.value}`:`${kue(u.columnName,u.datatype,t)} = ${typeof u.value=="string"?`'${u.value}'`:u.value}`).join(" AND ")}
|
|
263
|
+
)`);let i=r;for(let s=0;s<n.length;s++)i=i.replace(new RegExp(e[Object.keys(e)[s]][0].tableName,"g"),n[s]);return`WITH ${a.join(`,
|
|
264
|
+
`)} ${i}`},jue=({rlsConditions:r,dbName:e,query:t})=>{const n=c3(r.filter(i=>i.isAddOnMetrics),"tableName");return Rue(t,n,e)},f3=({timeGrainValue:r,isTimeStamp:e,col:t,database:n})=>{if(n===sm.Redshift||n.toUpperCase()==="POSTGRES"||n===sm.Snowflake||n==="Bigquery"){if(r==="Today")return e?`date_trunc('day', ${t}) = date_trunc('day', CURRENT_TIMESTAMP)`:`${t} = CURRENT_DATE`;if(r==="Last Week")return e?`extract(week from ${t}) = case when extract(week from current_date) = 1 then 4 else extract(week from current_date) - 1 end
|
|
265
|
+
AND extract(year from ${t}) = case when extract(week from current_date) = 1 and extract(month from current_date) = 1 then extract(year from current_date) -1 else extract(year from current_date) end
|
|
266
|
+
AND extract(month from ${t}) = case when extract(week from current_date) = 1 then case when extract(week from current_date) - 1 = 0 then 12 else extract(week from current_date) - 1 end else extract(month from current_date) end
|
|
267
|
+
`:`extract(week from ${t}) = case when extract(week from current_date) = 1 then 4 else extract(week from current_date) - 1 end
|
|
268
|
+
AND extract(year from ${t}) = case when extract(week from current_date) = 1 and extract(month from current_date) = 1 then extract(year from current_date) -1 else extract(year from current_date) end
|
|
269
|
+
AND extract(month from ${t}) = case when extract(week from current_date) = 1 then case when extract(week from current_date) - 1 = 0 then 12 else extract(week from current_date) - 1 end else extract(month from current_date) end
|
|
270
|
+
`;if(r==="This Week")return e?`extract(week from ${t}) = extract(week from current_date)
|
|
271
|
+
AND extract(year from ${t}) = extract(year from current_date) AND extract(month from ${t}) = extract(month from current_date)`:`extract(week from ${t}) = extract(week from current_date)
|
|
272
|
+
AND extract(year from ${t}) = extract(year from current_date) AND extract(month from ${t}) = extract(month from current_date)`;if(r==="Yesterday")return e?`date_trunc('day', ${t}) = date_trunc('day', CURRENT_TIMESTAMP - INTERVAL '1 day')`:`${t} = CURRENT_DATE - INTERVAL '1 day'`;if(r==="This Year")return e?`extract(year from ${t}) = extract(year from current_date)`:`extract(year from ${t}) = extract(year from current_date)`;if(r==="Last Year")return e?`extract(year from ${t}) = extract(year from current_date) - 1`:`extract(year from ${t}) = extract(year from current_date) - 1`;if(r==="Last Month")return e?`extract(month from ${t}) = case when extract(month from current_date) = 1 then 12 else extract(month from current_date) - 1 end AND extract(year from ${t}) = case when extract(month from current_date) = 1 then extract(year from current_date) - 1 else extract(year from current_date) end`:`extract(month from ${t}) = case when extract(month from current_date) = 1 then 12 else extract(month from current_date) - 1 end AND extract(year from ${t}) = case when extract(month from current_date) = 1 then extract(year from current_date) - 1 else extract(year from current_date) end`;if(r==="This Month")return e?`extract(month from ${t}) = extract(month from current_date) AND extract(year from ${t}) = extract(year from current_date)`:`extract(month from ${t}) = extract(month from current_date) AND extract(year from ${t}) = extract(year from current_date)`;const s=r.split(" - ")[0],l=r.split(" - ")[1];return e?`${t} BETWEEN '${s} 00:00:00' AND '${l} 23:59:59'`:`${t} BETWEEN '${s}' AND '${l}'`}if(r==="Today")return e?`DATE(${t}) = CURDATE()`:`${t} = CURDATE()`;if(r==="Last Week")return e?`WEEK(${t}) =
|
|
273
|
+
CASE
|
|
274
|
+
WHEN WEEK(${t}) = 1 THEN 4
|
|
275
|
+
ELSE WEEK(CURRENT_DATE) - 1
|
|
276
|
+
END
|
|
277
|
+
AND
|
|
278
|
+
MONTH(${t}) =
|
|
279
|
+
CASE
|
|
280
|
+
WHEN WEEK(CURRENT_DATE) = 1
|
|
281
|
+
THEN
|
|
282
|
+
CASE
|
|
283
|
+
WHEN MONTH(CURRENT_DATE) -1 = 0 THEN 12
|
|
284
|
+
ELSE MONTH(CURRENT_DATE) -1
|
|
285
|
+
END
|
|
286
|
+
ELSE MONTH(CURRENT_DATE)
|
|
287
|
+
END
|
|
288
|
+
AND YEAR(${t}) = CASE WHEN MONTH(CURRENT_DATE) = 1 AND WEEK(CURRENT_DATE) = 1 THEN YEAR(CURRENT_DATE) - 1
|
|
289
|
+
ELSE YEAR(CURRENT_DATE) END`:`WEEK(${t}) =
|
|
290
|
+
CASE
|
|
291
|
+
WHEN WEEK(${t}) = 1 THEN 4
|
|
292
|
+
ELSE WEEK(CURRENT_DATE) - 1
|
|
293
|
+
END
|
|
294
|
+
AND
|
|
295
|
+
MONTH(${t}) =
|
|
296
|
+
CASE
|
|
297
|
+
WHEN WEEK(CURRENT_DATE) = 1
|
|
298
|
+
THEN
|
|
299
|
+
CASE
|
|
300
|
+
WHEN MONTH(CURRENT_DATE) -1 = 0 THEN 12
|
|
301
|
+
ELSE MONTH(CURRENT_DATE) -1
|
|
302
|
+
END
|
|
303
|
+
ELSE MONTH(CURRENT_DATE)
|
|
304
|
+
END
|
|
305
|
+
AND YEAR(${t}) = CASE WHEN MONTH(CURRENT_DATE) = 1 AND WEEK(CURRENT_DATE) = 1 THEN YEAR(CURRENT_DATE) - 1
|
|
306
|
+
ELSE YEAR(CURRENT_DATE) END`;if(r==="This Week")return e?`WEEK(${t}) = WEEK(CURRENT_DATE)
|
|
307
|
+
AND
|
|
308
|
+
MONTH(${t}) = MONTH(CURRENT_DATE)
|
|
309
|
+
AND
|
|
310
|
+
YEAR(${t}) = YEAR(CURRENT_DATE)`:`WEEK(${t}) = WEEK(CURRENT_DATE)
|
|
311
|
+
AND
|
|
312
|
+
MONTH(${t}) = MONTH(CURRENT_DATE)
|
|
313
|
+
AND
|
|
314
|
+
YEAR(${t}) = YEAR(CURRENT_DATE)`;if(r==="Yesterday")return e?`DATE(${t}) = CURDATE() - INTERVAL 1 DAY`:`${t} = DATE(NOW() - INTERVAL 1 DAY)`;if(r==="This Year")return e?`YEAR(${t}) = YEAR(NOW())`:`YEAR(${t}) = YEAR(NOW())`;if(r==="Last Year")return e?`YEAR(${t}) = YEAR(NOW()) - 1`:`YEAR(${t}) = YEAR(NOW()) - 1`;if(r==="Last Month")return e?`MONTH(${t}) =
|
|
315
|
+
CASE
|
|
316
|
+
WHEN MONTH(NOW()) = 1 THEN 12
|
|
317
|
+
ELSE MONTH(NOW()) -1
|
|
318
|
+
END
|
|
319
|
+
AND
|
|
320
|
+
YEAR(${t}) =
|
|
321
|
+
CASE
|
|
322
|
+
WHEN MONTH(NOW()) = 1 THEN YEAR(NOW())-1
|
|
323
|
+
ELSE YEAR(NOW())
|
|
324
|
+
END`:`MONTH(${t}) =
|
|
325
|
+
CASE
|
|
326
|
+
WHEN MONTH(NOW()) = 1 THEN 12
|
|
327
|
+
ELSE MONTH(NOW()) -1
|
|
328
|
+
END
|
|
329
|
+
AND
|
|
330
|
+
YEAR(${t}) =
|
|
331
|
+
CASE
|
|
332
|
+
WHEN MONTH(NOW()) = 1 THEN YEAR(NOW())-1
|
|
333
|
+
ELSE YEAR(NOW())
|
|
334
|
+
END`;if(r==="This Month")return e?`MONTH(${t}) = MONTH(NOW()) AND YEAR(${t}) = YEAR(NOW())`:`MONTH(${t}) = MONTH(NOW()) AND YEAR(${t}) = YEAR(NOW())`;const a=r.split(" - ")[0],i=r.split(" - ")[1];return e?`${t} BETWEEN '${a} 00:00:00' AND '${i} 23:59:59'`:`${t} BETWEEN '${a}' AND '${i}'`},h3=(r,e,t)=>{const n=r==null?void 0:r.map(a=>({...a,[t]:parseInt(a[t],10)}));return n==null?void 0:n.reduce((a,i)=>{const o=e.reduce((s,l)=>s+=i[l],"");return a[o]||(a[o]={[t]:0},e.forEach(s=>a[o][s]=i[s])),a[o][t]+=i[t],a},{})},Sa=(r,e,t,n)=>{var o;const a=Object.keys((o=r==null?void 0:r[0])!=null?o:[]).filter(s=>!t.includes(s)),i=h3(r,e,a[0]);n(Object.values(i))},iw=r=>{const e=Object.entries(r).filter(([,n])=>Number(n)||Number(n)===0),t=Object.entries(r).filter(([,n])=>typeof n=="string"&&!Number(n)||n===null);return{numberKeys:e.map(([n])=>n),stringKeys:t.map(([n])=>n)}};var Bue=Object.freeze(Object.defineProperty({__proto__:null,getModifiedQuery:jue,getTimeFilterValue:f3,groupArray:c3,groupByMultipleKeys:h3,updateGroupData:Sa,findKeys:iw},Symbol.toStringTag,{value:"Module"}));const v3=r=>S("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",...r,children:S("path",{fill:"currentColor",d:"M5 21q-.825 0-1.413-.587Q3 19.825 3 19V5q0-.825.587-1.413Q4.175 3 5 3h14q.825 0 1.413.587Q21 4.175 21 5v14q0 .825-.587 1.413Q19.825 21 19 21Zm5.6-5.225q.2 0 .375-.062q.175-.063.325-.213l5.675-5.675q.275-.275.275-.675t-.3-.7q-.275-.275-.7-.275q-.425 0-.7.275L10.6 13.4l-2.175-2.175q-.275-.275-.675-.275t-.7.3q-.275.275-.275.7q0 .425.275.7L9.9 15.5q.15.15.325.213q.175.062.375.062Z"})}),d3=({dateTimeColumnList:r,columnList:e,database:t,companyId:n,tableName:a,setData:i,setError:o,setLoading:s,setQuery:l,isEnableGroupBy:u,setSelectedGroupBy:c,clientId:f,clientColumn:h})=>{const{globalTheme:v}=il(),[d,p]=R.useState([]),[g,y]=R.useState(""),[m,_]=R.useState({value:"",label:""}),[b,x]=R.useState([]),[M,w]=R.useState([]),[D,T]=R.useState(""),[I,A]=R.useState(""),[N,L]=R.useState([]),[E,O]=R.useState([]),[P,H]=R.useState(!1),[F,G]=R.useState(!1),[Z,te]=R.useState(!1),[V,Y]=R.useState(!1),[q,Q]=R.useState(!1),[ne,oe]=R.useState(!1),[ie,he]=R.useState([]),[k,j]=R.useState(""),[W,ae]=R.useState({value:"",label:""}),[re,ee]=R.useState({value:"",label:""}),[se,Le]=R.useState({value:"",label:""}),[dt,pt]=R.useState({value:"10",label:"10"}),[_t,zt]=R.useState({value:"",label:""}),[qt,Cn]=R.useState({value:"",label:""}),[nn,na]=R.useState({value:"",label:""}),[cr,Xe]=R.useState({value:"",label:""}),[Wt,fr]=R.useState({value:"",label:""});R.useEffect(()=>{e.length&&(L(Ie=>Ie.filter(nt=>e.map(wt=>wt.value).includes(nt))),p(Ie=>Ie.filter(nt=>{var wt;return e.map(Ke=>Ke.value).includes(((wt=nt.as.match(/\((.*?)\)/))==null?void 0:wt[1])||"")})),ae(e[0]),x(Ie=>Ie.filter(nt=>e.map(wt=>wt.value).includes(nt.value))),ee(e[0]),zt(e[0]),T(Ie=>e.find(nt=>Ie.includes(nt.value))?Ie:""),Le(e[0]),w(Ie=>Ie.filter(nt=>e.find(wt=>nt.includes(wt.value)))),Q(!1),A(Ie=>e.find(nt=>Ie.includes(nt.value))?Ie:""),I||y(""))},[e]),R.useEffect(()=>{r.length?_({value:r[0].name,label:r[0].as}):_({value:"",label:""})},[r]);const{generateDatasetMetric:Xt,isGeneratingDataset:dl,generateError:pl,fetchColumnValues:kh}=mv();R.useEffect(()=>{_t.value&&(O([]),fr({value:"",label:""}),kh({companyId:n,tableName:a,columnName:_t.value},{onSuccess(Ie){var wt;const nt=(wt=Ie.fetchColumnData)==null?void 0:wt.data;if(nt!=null&&nt.length){const Ke=nt.map(rr=>({value:(rr==null?void 0:rr.value)||"",label:(rr==null?void 0:rr.label)||""}));he(Ke)}}}))},[_t]);const Ku=!d.length&&!b.length,Ri=!r.length,ec=!m.value,gl=!!d.length,tc=!!b.length,er=t==="Bigquery",Nn=t==="MySql",Aa=t==="MongoDB",Po=cr.value==="IS NULL"||cr.value==="IS NOT NULL",rt=cr.value==="IN"||cr.value==="NOT IN",gr=Po?!0:rt?!!E.length:!!Wt.value,tr=b.length?!1:!nn.value;return R.useEffect(()=>{var Ie;if(g&&m.value&&r.length){const nt=(Ie=r.find(Ke=>Ke.name===m.value))==null?void 0:Ie.datatype,wt=f3({timeGrainValue:g,isTimeStamp:(nt==null?void 0:nt.toLowerCase())!=="date",col:m.value,database:t});A(wt)}},[g,m]),R.useEffect(()=>{b.length&&(Q(!1),L([]),T(""))},[b]),R.useEffect(()=>{Po&&fr({value:"",label:""})},[cr]),R.useEffect(()=>{u&&c(N)},[N,u]),B("div",{className:ke["form-container"],children:[!Ri&&B("div",{className:ke["field-container"],children:[S(de,{variant:"h1",styleClass:"custom",className:ke["field-label"],children:"Time Filter"}),S("div",{className:ke["field-wrapper"],children:B("div",{className:ke["field-inner-container"],children:[S(br,{onChange:_,selectedOption:m,options:r.map(({name:Ie,as:nt})=>({value:Ie,label:nt})),isDisabled:Ri,labelVariant:"static",label:"Time Column"}),S(u3,{setTimeGrainValue:y,timeGrainValue:g,isShowlabel:!0,isDisabled:ec}),g&&B(Ce,{type:"button",variant:"custom",className:ke["field-value"],onClick:()=>y(""),children:[g," ",S(lt,{name:"close-icon",className:ke.fieldValueIcon})]})]})})]}),!tc&&B("div",{className:ke["field-container"],children:[B(de,{variant:"h1",styleClass:"custom",className:ke["field-label"],children:["Metric Creation",S(Ei,{children:"configure metric columns"})]}),S("div",{className:ke["field-wrapper"],children:B("div",{className:ke["field-inner-container"],children:[S(de,{variant:"p",styleClass:"font-14",children:"Metric Fields"}),B(Ce,{type:"button",variant:"secondary",className:ke["field-add-btn"],onClick:()=>{H(!0),j("")},isDisabled:tc,children:[S(lt,{name:"plus-icon",className:ke.fieldAddBtnIcon})," ","Add Aggregate Column"]}),S("div",{className:ke["field-value-container"],children:d.map(Ie=>B(Ce,{type:"button",variant:"custom",className:ke["field-value"],onClick:()=>p(nt=>nt.filter(wt=>wt.as!==Ie.as)),children:[Ie.as," ",S(lt,{name:"close-icon",className:ke.fieldValueIcon})]},Ie.as))}),B(li,{headerTitle:W.value&&qt.value?`${qt.value}(${W.value})`:"Create metric",isOpen:P,onClose:()=>H(!1),children:[B("div",{className:ke.dropdown,children:[S(br,{onChange:ae,selectedOption:W,options:e,labelVariant:"static",label:"Columns"}),S(br,{onChange:Cn,selectedOption:qt,options:um,labelVariant:"static",label:"Aggregate"}),S(Ct,{label:"As",type:"text",placeholder:"Save as",name:"alias",onChange:Ie=>j(Ie.target.value)})]}),S(Cl,{children:S(Ce,{type:"button",variant:"primary",size:"small",className:ke.disabled,isDisabled:!qt.value||!W.value,onClick:()=>{p(Ie=>[...Ie,{value:`${qt.value}(${er||Nn?`${W.value}`:Aa?`\`${W.value}\``:`"${W.value}"`})`,as:er?k||"_result":k||`${qt.value}(${W.label})`}]),H(!1)},children:"Save"})})]}),S(de,{variant:"p",styleClass:"font-14",children:"Group By"}),S(fc,{options:e,onChange:L,value:N,name:"Dimensions",placeHolder:"Select Columns"})]})})]}),!gl&&B("div",{className:ke["field-container"],children:[B(de,{variant:"h1",styleClass:"custom",className:ke["field-label"],children:["Columns",S(Ei,{children:"select columns for raw records query"})]}),S("div",{className:ke["field-wrapper"],children:B("div",{className:ke["field-inner-container"],children:[S(de,{variant:"p",styleClass:"font-14",children:"Select Columns"}),B(Ce,{type:"button",variant:"secondary",className:ke["field-add-btn"],onClick:()=>{G(!0),j("")},isDisabled:gl,children:[S(lt,{name:"plus-icon",className:ke.fieldAddBtnIcon})," ","Add Column"]}),S("div",{className:ke["field-value-container"],children:b.map(Ie=>B(Ce,{type:"button",variant:"custom",className:ke["field-value"],onClick:()=>x(nt=>nt.filter(wt=>wt.as!==Ie.as)),children:[Ie.as," ",S(lt,{name:"close-icon",className:ke.fieldValueIcon})]},Ie.as))}),B(li,{headerTitle:re.value?`${re.value}`:"Select Column",isOpen:F,onClose:()=>G(!1),children:[B("div",{className:ke.dropdown,children:[S(br,{onChange:ee,selectedOption:re,options:e,labelVariant:"static",label:"Columns"}),S(Ct,{label:"As",type:"text",placeholder:"Save as",name:"alias",onChange:Ie=>j(Ie.target.value)})]}),S(Cl,{children:S(Ce,{type:"button",variant:"primary",size:"small",className:ke.disabled,isDisabled:!re.value,onClick:()=>{b.find(Ie=>Ie.as===k)||x(Ie=>[...Ie,{value:`${re.value}`,as:k||`${re.label}`}]),G(!1)},children:"Save"})})]})]})})]}),B("div",{className:ke["field-container"],children:[S(de,{variant:"h1",styleClass:"custom",className:ke["field-label"],children:"category filters"}),S("div",{className:ke["field-wrapper"],children:B("div",{className:ke["field-inner-container"],children:[S(de,{variant:"p",styleClass:"font-14",children:"Filter by"}),B(Ce,{type:"button",variant:"secondary",className:ke["field-add-btn"],onClick:()=>Y(!0),children:[S(lt,{name:"plus-icon",className:ke.fieldAddBtnIcon})," Add Filter Category"]}),S("div",{className:ke["field-value-container"],children:M.map(Ie=>B(Ce,{type:"button",variant:"custom",className:ke["field-value"],onClick:()=>w(nt=>nt.filter(wt=>wt!==Ie)),children:[Ie," ",S(lt,{name:"close-icon",className:ke.fieldValueIcon})]},Ie))}),B(li,{headerTitle:_t.value&&cr.value?`${_t.value} ${cr.value} ${rt?`(${E.map(Ie=>`'${Ie}'`).join(", ")})`:`${Wt.value?`'${Wt.value}'`:""}`}`:"Add Filter",isOpen:V,onClose:()=>Y(!1),children:[B("div",{className:ke.filterDropdown,children:[S(br,{onChange:zt,selectedOption:_t,options:e,labelVariant:"static",label:"Column"}),S(br,{onChange:Xe,selectedOption:cr,options:yv,labelVariant:"static",label:"Operator"}),rt?B("div",{className:ke.filterValue,children:[S(de,{variant:"p",styleClass:"font-14",children:"Filter Value"}),S(fc,{options:ie,onChange:O,value:E,name:"Filters",placeHolder:"Select Multiple Filters"})]}):S(br,{onChange:fr,selectedOption:Wt,options:ie,isDisabled:Po,labelVariant:"static",label:"Filter Value"})]}),S(Cl,{children:S(Ce,{type:"button",variant:"primary",size:"small",isDisabled:!_t.value||!cr.value||!gr,className:ke.disabled,onClick:()=>{w(Ie=>[...Ie,`${er||Nn?`${_t.value}`:Aa?`\`${_t.value}\``:`"${_t.value}"`} ${cr.value} ${rt?`(${E.map(nt=>`'${nt}'`).join(", ")})`:`${Wt.value?`'${Wt.value}'`:""}`}`]),Y(!1)},children:"Save"})})]}),S(de,{variant:"p",styleClass:"font-14",children:"Sort By"}),B(Ce,{type:"button",variant:"secondary",className:ke["field-add-btn"],onClick:()=>te(!0),children:[D?S(zue,{}):S(lt,{name:"plus-icon",className:ke.fieldAddBtnIcon})," ",D?"Edit":"Add"," Sort Category"]}),D&&B(Ce,{type:"button",variant:"custom",className:ke["field-value"],onClick:()=>T(""),children:[D," ",S(lt,{name:"close-icon",className:ke.fieldValueIcon})]}),B(li,{headerTitle:b.length?se.value?`${se.value}`:"Create sort":se.value&&nn.value?`${nn.value}(${se.value})`:"Create sort",isOpen:Z,onClose:()=>te(!1),children:[B("div",{className:ke.dropdown,children:[S(br,{onChange:Le,selectedOption:se,options:e,labelVariant:"static",label:"Column"}),!b.length&&S(br,{onChange:na,selectedOption:nn,options:um,labelVariant:"static",label:"Aggregate"})]}),S(Cl,{children:S(Ce,{type:"button",variant:"primary",size:"small",isDisabled:!se.value||tr,className:ke.disabled,onClick:()=>{b.length?T(`${er||Nn?`${se.value}`:`${se.value}`}`):T(`${nn.value}(${er||Nn?`${se.value}`:Aa?`\`${se.value}\``:`"${se.value}"`})`),te(!1)},children:"Save"})})]})]})})]}),S(br,{onChange:pt,options:pS,selectedOption:dt,labelVariant:"static",label:"Row Limit"}),!b.length&&!!r.length&&B(de,{styleClass:"font-14",variant:"p",className:ke.columnText,children:[S(Ce,{type:"button",variant:"custom",onClick:()=>Q(Ie=>!Ie),isDisabled:!m.value||!!b.length,children:q?S(v3,{className:ke.checkIcon}):S(mm,{})}),"Include Time"]}),B(de,{styleClass:"font-14",variant:"p",className:ke.columnText,children:[S(Ce,{type:"button",variant:"custom",onClick:()=>oe(Ie=>!Ie),children:ne?S(v3,{className:ke.checkIcon}):S(mm,{})}),"Sort Descending"]}),S(Ce,{type:"button",variant:"primary",className:ke.generateButton,isDisabled:dl||Ku,style:v?{backgroundColor:`${v.dashboard.ctaColor} !important`,color:`${v.dashboard.ctaTextColor} !important`}:void 0,onClick:()=>{var Ie,nt,wt;o(""),s(!0),i([]),l(""),dl&&s(!0),Xt({companyId:n,userInputs:{columns:b.map(Ke=>er||Nn?`${Ke.value} AS ${Ke.as} `:Aa?`\`${Ke.value}\` AS "${Ke.as}"`:`"${Ke.value}" AS "${Ke.as}"`),dimensions:er||Nn?N.map(Ke=>{var rr,dn;return{name:(rr=e.find(Vr=>Vr.value===Ke))==null?void 0:rr.value,as:(dn=e.find(Vr=>Vr.value===Ke))==null?void 0:dn.label}}):Aa?N.map(Ke=>{var rr,dn;return{name:`\`${(rr=e.find(Vr=>Vr.value===Ke))==null?void 0:rr.value}\``,as:(dn=e.find(Vr=>Vr.value===Ke))==null?void 0:dn.label}}):N.map(Ke=>{var rr,dn;return{name:`"${(rr=e.find(Vr=>Vr.value===Ke))==null?void 0:rr.value}"`,as:(dn=e.find(Vr=>Vr.value===Ke))==null?void 0:dn.label}}),metrics:d.map(Ke=>er?`${Ke.value} AS ${Ke.as}`:`${Ke.value} AS "${Ke.as}"`),sort:D,isSortDescending:ne,filters:M,tableName:a,rowLimit:dt.value,timeFilter:{filter:I,column:er||Nn?{name:m.value,as:(Ie=e.find(Ke=>Ke.value===m.value))==null?void 0:Ie.label}:Aa?{name:`\`${m.value}\``,as:(nt=e.find(Ke=>Ke.value===m.value))==null?void 0:nt.label}:{name:`"${m.value}"`,as:(wt=e.find(Ke=>Ke.value===m.value))==null?void 0:wt.label},isInclude:q},clientColumnFilter:h?{value:Number(f)||f,column:er||Nn?`${h}`:Aa?`\`${h}\``:`"${h}"`}:void 0}},{onSuccess(Ke){var vy,Rh,rc;const rr=(vy=Ke.generateDatasetMetrics)==null?void 0:vy.error,dn=(Rh=Ke.generateDatasetMetrics)==null?void 0:Rh.result,Vr=(rc=Ke.generateDatasetMetrics)==null?void 0:rc.query;(rr||pl)&&(o(rr.message||am),s(!1),i([]),l("")),dn&&Vr&&(o(""),s(!1),i(Array.isArray(dn)?dn:[]),l(Vr))}})},children:"Generate"})]})};var p3={container:"_container_rofqe_1",header:"_header_rofqe_5",enableGroupBy:"_enableGroupBy_rofqe_8",enableGroupButton:"_enableGroupButton_rofqe_11"};const g3=({dateTimeColumnList:r,columnList:e,database:t,companyId:n,tableName:a,setData:i,setError:o,setLoading:s,setQuery:l,isEnableGroupBy:u,setEnableGroupBy:c,setSelectedGroupBy:f,clientId:h,clientColumn:v})=>B("div",{className:p3.container,children:[B("div",{className:p3.header,children:["Data",c&&S(ym,{enabled:u,onChange:d=>c(d),placeholder:"Group By"})]}),S(d3,{dateTimeColumnList:r,columnList:e,database:t,companyId:n,tableName:a,setData:i,setError:o,setQuery:l,setLoading:s,isEnableGroupBy:u,setSelectedGroupBy:f,clientId:h,clientColumn:v})]}),Fue=r=>S("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",...r,children:S("path",{fill:"currentColor",d:"M19 13h-6v6h-2v-6H5v-2h6V5h2v6h6v2Z"})}),y3=({clientId:r,companyId:e,mode:t,externalDashboardId:n,variant:a="static"})=>{var Po;const{globalTheme:i}=il(),[o,s]=R.useState(!1),[l,u]=R.useState(""),[c,f]=R.useState(),[h,v]=R.useState([]),[d,p]=R.useState(""),[g,y]=R.useState(!1),[m,_]=R.useState([]),[b,x]=R.useState(),[M,w]=R.useState(!1),[D,T]=R.useState(!1),[I,A]=R.useState(!1),[N,L]=R.useState({value:"",label:""}),[E,O]=R.useState([]);R.useEffect(()=>{m.length&&x({column:m[0]})},[m]);const{mutate:P}=DF(),H=R.useMemo(()=>E.map(rt=>({value:rt.tableName,label:rt.tableName})),[E]),F=R.useMemo(()=>E.find(rt=>rt.tableName===N.value),[N.value,E]),G=R.useMemo(()=>F==null?void 0:F.clientColumn,[F]),Z=R.useMemo(()=>(F==null?void 0:F.columns.map(({name:rt,as:gr})=>({value:rt,label:gr})))||[],[F]);R.useEffect(()=>{H.length&&L(H[0])},[H]);const te=R.useMemo(()=>(F==null?void 0:F.columns.filter(({datatype:rt})=>hm.includes(rt.toLowerCase())))||[],[F]),[V,Y]=R.useState();R.useEffect(()=>{r&&e&&P({clientId:r,companyId:e},{onSuccess(rt){var Ie;const gr=(Ie=rt.companySubsetTableData)==null?void 0:Ie.error,tr=rt.companySubsetTableData;gr?u(gr.message):(Y({id:tr==null?void 0:tr.companyIntegrationId,name:tr==null?void 0:tr.dbName}),O(tr==null?void 0:tr.tableList))}})},[r,e,P]);const[q,Q]=R.useState("bar"),[ne,oe]=R.useState(),[ie,he]=R.useState(),[k,j]=R.useState(),[W,ae]=R.useState({marginTop:20,marginBottom:20,marginLeft:5,marginRight:5}),[re,ee]=R.useState({show:!0,top:0,left:0,right:0,bottom:0,position:"horizontal"}),[se,Le]=R.useState({hideSplitLines:"none",hideAxisLines:"none",barWidth:40,barRadius:0,axisLabels:"none",fontSize:14,subHeaderShow:!1,displayText:"",subHeaderFontSize:0,dateFormatter:"none",numberFormatter:"original"}),[dt,pt]=R.useState({axis:"left",show:!1,position:"hidden"}),[_t,zt]=R.useState({axis:"left"}),[qt,Cn]=R.useState({show:!1}),[nn]=R.useState(),[na,cr]=R.useState(),[Xe,Wt]=R.useState(),[fr,Xt]=R.useState(),[dl,pl]=R.useState(),{datasets:kh,funnelData:Ku,labels:Ri,sankeyData:ec,singleValueData:gl}=_m({data:g?h:c,measure:fr,sankeyValues:k,singleValue:Xe,step:ie,xAxis:ne,yAxisList:na});R.useEffect(()=>{if(h.length&&g){const rt=iw(h[0]);oe(rt.stringKeys[0]),cr(rt.numberKeys),he(rt.stringKeys[0]),Xt(rt.numberKeys[0])}},[h]),R.useEffect(()=>{if((c==null?void 0:c.length)&&!g){const rt=Object.keys(c[0]);oe(rt[0]),cr(rt.slice(1))}},[c,g]);const{createExternalMetric:tc,error:er}=wS({query:d,xAxis:ne,backGroundColor:qt,customSettings:se,chartType:q,yAxisList:na,step:ie,measure:fr,sankeyValues:k,singleValue:Xe,companyIntegrationId:V==null?void 0:V.id,integrationName:V==null?void 0:V.name,margins:W,legendSettings:re,labelSettings:dt,axisSettings:_t,metricQuery:nn,outputColumns:void 0,selectedColumns:void 0,clientId:r,isEmbedded:!0,companyId:e,mode:t,dashboardIds:[n],isEnableGroupBy:g,groupBy:b,selectedGroupBy:m}),{mutate:Nn}=jF();R.useEffect(()=>{N.value&&Nn({companyId:e,tableName:N.value,limit:10},{onSuccess(rt){var tr;const gr=(tr=rt.previewTable)==null?void 0:tr.data;pl(gr?[gr]:void 0)}})},[N]),R.useEffect(()=>{(c==null?void 0:c.length)&&m.length&&Sa(c,[m[0]],m,v)},[c]);const Aa=rt=>{if((b==null?void 0:b.column)&&rt&&rt!=="undefined"){if(m.lastIndexOf(b.column)!==m.length-1){const gr=m.indexOf(b.column),tr=b.column;x({column:m[gr+1],parentColumn:{column:b.column,value:rt}}),Sa(c==null?void 0:c.filter(Ie=>Ie[tr]===rt),[m[gr+1]],m,v)}m.lastIndexOf(b.column)===m.length-1&&(x({column:m[0]}),Sa(c,[m[0]],m,v))}else x({column:m[0]}),Sa(c,[m[0]],m,v)};return R.useEffect(()=>{h.length===0&&g&&m.length&&(c==null?void 0:c.length)&&(x({column:m[0]}),Sa(c,[m[0]],m,v))},[h,g,m]),B(we,{children:[S(Ce,{type:"button",variant:a==="floating"?"custom":"primary",size:"large",className:a==="floating"?jg.floatingCreateButton:"",onClick:()=>w(!0),style:i?{backgroundColor:`${i.dashboard.ctaColor} !important`,color:`${i.dashboard.ctaTextColor} !important`}:void 0,children:a==="floating"?S(Fue,{className:jg.floatingCreateButtonIcon}):"Create Metric"}),S(li,{headerTitle:"Create Metric",isOpen:M,onClose:()=>w(!1),customHeader:S(t3,{Heading:"Create Metric",setShowMetricCreateModal:w,isDisableSqlBtn:!d,isDisableSaveBtn:!(fr!=null&&fr.length)&&!((Po=na==null?void 0:na.filter(rt=>rt))!=null&&Po.length)&&!Xe,setShowSqlModal:T,setShowSaveMetricModal:A}),children:B("div",{className:jg["modal-container"],children:[S(r3,{setselectTable:L,selectTable:N,tableList:H,columnList:(F==null?void 0:F.columns)||[]}),S(g3,{dateTimeColumnList:te,columnList:Z,database:(V==null?void 0:V.name)||"",companyId:e,tableName:N.value,setData:f,setError:u,setQuery:p,setLoading:s,isEnableGroupBy:g,setEnableGroupBy:y,setSelectedGroupBy:_,clientId:r,clientColumn:G}),S(l3,{data:g?h:c,error:l,isLoading:o,labels:Ri,funnelData:Ku,chartType:q,datasets:kh,setChartType:Q,setXAxis:oe,setYAxisList:cr,xAxis:ne,setMeasure:Xt,setStep:he,step:ie,measure:fr,setSankeyValues:j,sankeyData:ec,previewTableDataList:dl,singleValue:Xe,setSingleValue:Wt,singleValueData:gl,setMargins:ae,margins:W,legendSettings:re,setLegendSettings:ee,labelSettings:dt,setLabelSettings:pt,axisSettings:_t,setAxisSettings:zt,updateGroup:Aa,isEnableGroupBy:g,backGroundColor:qt,setBackGroundColor:Cn,customSettings:se,setCustomSettings:Le})]})}),S(li,{headerTitle:"Generated Query",isOpen:D,onClose:()=>T(!1),children:S("div",{className:jg["query-modal"],children:d})}),S(li,{isOpen:I,onClose:()=>A(!1),headerTitle:"Save To Dashboard",children:S(MS,{onCancel:()=>A(!1),onSubmit:tc,dashboardIds:[n],onDashboardChange:()=>{},companyId:e,error:er,isEmbedded:!0})})]})};var ow={exports:{}},Sh={},Ih={exports:{}};(function(r,e){var t=200,n="__lodash_hash_undefined__",a=1,i=2,o=9007199254740991,s="[object Arguments]",l="[object Array]",u="[object AsyncFunction]",c="[object Boolean]",f="[object Date]",h="[object Error]",v="[object Function]",d="[object GeneratorFunction]",p="[object Map]",g="[object Number]",y="[object Null]",m="[object Object]",_="[object Promise]",b="[object Proxy]",x="[object RegExp]",M="[object Set]",w="[object String]",D="[object Symbol]",T="[object Undefined]",I="[object WeakMap]",A="[object ArrayBuffer]",N="[object DataView]",L="[object Float32Array]",E="[object Float64Array]",O="[object Int8Array]",P="[object Int16Array]",H="[object Int32Array]",F="[object Uint8Array]",G="[object Uint8ClampedArray]",Z="[object Uint16Array]",te="[object Uint32Array]",V=/[\\^$.*+?()[\]{}|]/g,Y=/^\[object .+?Constructor\]$/,q=/^(?:0|[1-9]\d*)$/,Q={};Q[L]=Q[E]=Q[O]=Q[P]=Q[H]=Q[F]=Q[G]=Q[Z]=Q[te]=!0,Q[s]=Q[l]=Q[A]=Q[c]=Q[N]=Q[f]=Q[h]=Q[v]=Q[p]=Q[g]=Q[m]=Q[x]=Q[M]=Q[w]=Q[I]=!1;var ne=typeof qh=="object"&&qh&&qh.Object===Object&&qh,oe=typeof self=="object"&&self&&self.Object===Object&&self,ie=ne||oe||Function("return this")(),he=e&&!e.nodeType&&e,k=he&&!0&&r&&!r.nodeType&&r,j=k&&k.exports===he,W=j&&ne.process,ae=function(){try{return W&&W.binding&&W.binding("util")}catch{}}(),re=ae&&ae.isTypedArray;function ee(z,$){for(var le=-1,xe=z==null?0:z.length,It=0,Ze=[];++le<xe;){var Gt=z[le];$(Gt,le,z)&&(Ze[It++]=Gt)}return Ze}function se(z,$){for(var le=-1,xe=$.length,It=z.length;++le<xe;)z[It+le]=$[le];return z}function Le(z,$){for(var le=-1,xe=z==null?0:z.length;++le<xe;)if($(z[le],le,z))return!0;return!1}function dt(z,$){for(var le=-1,xe=Array(z);++le<z;)xe[le]=$(le);return xe}function pt(z){return function($){return z($)}}function _t(z,$){return z.has($)}function zt(z,$){return z==null?void 0:z[$]}function qt(z){var $=-1,le=Array(z.size);return z.forEach(function(xe,It){le[++$]=[It,xe]}),le}function Cn(z,$){return function(le){return z($(le))}}function nn(z){var $=-1,le=Array(z.size);return z.forEach(function(xe){le[++$]=xe}),le}var na=Array.prototype,cr=Function.prototype,Xe=Object.prototype,Wt=ie["__core-js_shared__"],fr=cr.toString,Xt=Xe.hasOwnProperty,dl=function(){var z=/[^.]+$/.exec(Wt&&Wt.keys&&Wt.keys.IE_PROTO||"");return z?"Symbol(src)_1."+z:""}(),pl=Xe.toString,kh=RegExp("^"+fr.call(Xt).replace(V,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Ku=j?ie.Buffer:void 0,Ri=ie.Symbol,ec=ie.Uint8Array,gl=Xe.propertyIsEnumerable,tc=na.splice,er=Ri?Ri.toStringTag:void 0,Nn=Object.getOwnPropertySymbols,Aa=Ku?Ku.isBuffer:void 0,Po=Cn(Object.keys,Object),rt=nc(ie,"DataView"),gr=nc(ie,"Map"),tr=nc(ie,"Promise"),Ie=nc(ie,"Set"),nt=nc(ie,"WeakMap"),wt=nc(Object,"create"),Ke=_l(rt),rr=_l(gr),dn=_l(tr),Vr=_l(Ie),vy=_l(nt),Rh=Ri?Ri.prototype:void 0,rc=Rh?Rh.valueOf:void 0;function yl(z){var $=-1,le=z==null?0:z.length;for(this.clear();++$<le;){var xe=z[$];this.set(xe[0],xe[1])}}function Ehe(){this.__data__=wt?wt(null):{},this.size=0}function Ohe(z){var $=this.has(z)&&delete this.__data__[z];return this.size-=$?1:0,$}function Phe(z){var $=this.__data__;if(wt){var le=$[z];return le===n?void 0:le}return Xt.call($,z)?$[z]:void 0}function zhe(z){var $=this.__data__;return wt?$[z]!==void 0:Xt.call($,z)}function khe(z,$){var le=this.__data__;return this.size+=this.has(z)?0:1,le[z]=wt&&$===void 0?n:$,this}yl.prototype.clear=Ehe,yl.prototype.delete=Ohe,yl.prototype.get=Phe,yl.prototype.has=zhe,yl.prototype.set=khe;function ji(z){var $=-1,le=z==null?0:z.length;for(this.clear();++$<le;){var xe=z[$];this.set(xe[0],xe[1])}}function Rhe(){this.__data__=[],this.size=0}function jhe(z){var $=this.__data__,le=py($,z);if(le<0)return!1;var xe=$.length-1;return le==xe?$.pop():tc.call($,le,1),--this.size,!0}function Bhe(z){var $=this.__data__,le=py($,z);return le<0?void 0:$[le][1]}function Fhe(z){return py(this.__data__,z)>-1}function Vhe(z,$){var le=this.__data__,xe=py(le,z);return xe<0?(++this.size,le.push([z,$])):le[xe][1]=$,this}ji.prototype.clear=Rhe,ji.prototype.delete=jhe,ji.prototype.get=Bhe,ji.prototype.has=Fhe,ji.prototype.set=Vhe;function ml(z){var $=-1,le=z==null?0:z.length;for(this.clear();++$<le;){var xe=z[$];this.set(xe[0],xe[1])}}function Hhe(){this.size=0,this.__data__={hash:new yl,map:new(gr||ji),string:new yl}}function Whe(z){var $=gy(this,z).delete(z);return this.size-=$?1:0,$}function Ghe(z){return gy(this,z).get(z)}function $he(z){return gy(this,z).has(z)}function Uhe(z,$){var le=gy(this,z),xe=le.size;return le.set(z,$),this.size+=le.size==xe?0:1,this}ml.prototype.clear=Hhe,ml.prototype.delete=Whe,ml.prototype.get=Ghe,ml.prototype.has=$he,ml.prototype.set=Uhe;function dy(z){var $=-1,le=z==null?0:z.length;for(this.__data__=new ml;++$<le;)this.add(z[$])}function Yhe(z){return this.__data__.set(z,n),this}function Qhe(z){return this.__data__.has(z)}dy.prototype.add=dy.prototype.push=Yhe,dy.prototype.has=Qhe;function zo(z){var $=this.__data__=new ji(z);this.size=$.size}function Zhe(){this.__data__=new ji,this.size=0}function qhe(z){var $=this.__data__,le=$.delete(z);return this.size=$.size,le}function Xhe(z){return this.__data__.get(z)}function Jhe(z){return this.__data__.has(z)}function Khe(z,$){var le=this.__data__;if(le instanceof ji){var xe=le.__data__;if(!gr||xe.length<t-1)return xe.push([z,$]),this.size=++le.size,this;le=this.__data__=new ml(xe)}return le.set(z,$),this.size=le.size,this}zo.prototype.clear=Zhe,zo.prototype.delete=qhe,zo.prototype.get=Xhe,zo.prototype.has=Jhe,zo.prototype.set=Khe;function eve(z,$){var le=yy(z),xe=!le&&pve(z),It=!le&&!xe&&Xw(z),Ze=!le&&!xe&&!It&&Fj(z),Gt=le||xe||It||Ze,yr=Gt?dt(z.length,String):[],Ar=yr.length;for(var kt in z)($||Xt.call(z,kt))&&!(Gt&&(kt=="length"||It&&(kt=="offset"||kt=="parent")||Ze&&(kt=="buffer"||kt=="byteLength"||kt=="byteOffset")||cve(kt,Ar)))&&yr.push(kt);return yr}function py(z,$){for(var le=z.length;le--;)if(kj(z[le][0],$))return le;return-1}function tve(z,$,le){var xe=$(z);return yy(z)?xe:se(xe,le(z))}function jh(z){return z==null?z===void 0?T:y:er&&er in Object(z)?lve(z):dve(z)}function Ej(z){return Bh(z)&&jh(z)==s}function Oj(z,$,le,xe,It){return z===$?!0:z==null||$==null||!Bh(z)&&!Bh($)?z!==z&&$!==$:rve(z,$,le,xe,Oj,It)}function rve(z,$,le,xe,It,Ze){var Gt=yy(z),yr=yy($),Ar=Gt?l:ko(z),kt=yr?l:ko($);Ar=Ar==s?m:Ar,kt=kt==s?m:kt;var Ln=Ar==m,Ca=kt==m,Hr=Ar==kt;if(Hr&&Xw(z)){if(!Xw($))return!1;Gt=!0,Ln=!1}if(Hr&&!Ln)return Ze||(Ze=new zo),Gt||Fj(z)?Pj(z,$,le,xe,It,Ze):ove(z,$,Ar,le,xe,It,Ze);if(!(le&a)){var aa=Ln&&Xt.call(z,"__wrapped__"),ia=Ca&&Xt.call($,"__wrapped__");if(aa||ia){var Ro=aa?z.value():z,Bi=ia?$.value():$;return Ze||(Ze=new zo),It(Ro,Bi,le,xe,Ze)}}return Hr?(Ze||(Ze=new zo),sve(z,$,le,xe,It,Ze)):!1}function nve(z){if(!Bj(z)||hve(z))return!1;var $=Rj(z)?kh:Y;return $.test(_l(z))}function ave(z){return Bh(z)&&jj(z.length)&&!!Q[jh(z)]}function ive(z){if(!vve(z))return Po(z);var $=[];for(var le in Object(z))Xt.call(z,le)&&le!="constructor"&&$.push(le);return $}function Pj(z,$,le,xe,It,Ze){var Gt=le&a,yr=z.length,Ar=$.length;if(yr!=Ar&&!(Gt&&Ar>yr))return!1;var kt=Ze.get(z);if(kt&&Ze.get($))return kt==$;var Ln=-1,Ca=!0,Hr=le&i?new dy:void 0;for(Ze.set(z,$),Ze.set($,z);++Ln<yr;){var aa=z[Ln],ia=$[Ln];if(xe)var Ro=Gt?xe(ia,aa,Ln,$,z,Ze):xe(aa,ia,Ln,z,$,Ze);if(Ro!==void 0){if(Ro)continue;Ca=!1;break}if(Hr){if(!Le($,function(Bi,bl){if(!_t(Hr,bl)&&(aa===Bi||It(aa,Bi,le,xe,Ze)))return Hr.push(bl)})){Ca=!1;break}}else if(!(aa===ia||It(aa,ia,le,xe,Ze))){Ca=!1;break}}return Ze.delete(z),Ze.delete($),Ca}function ove(z,$,le,xe,It,Ze,Gt){switch(le){case N:if(z.byteLength!=$.byteLength||z.byteOffset!=$.byteOffset)return!1;z=z.buffer,$=$.buffer;case A:return!(z.byteLength!=$.byteLength||!Ze(new ec(z),new ec($)));case c:case f:case g:return kj(+z,+$);case h:return z.name==$.name&&z.message==$.message;case x:case w:return z==$+"";case p:var yr=qt;case M:var Ar=xe&a;if(yr||(yr=nn),z.size!=$.size&&!Ar)return!1;var kt=Gt.get(z);if(kt)return kt==$;xe|=i,Gt.set(z,$);var Ln=Pj(yr(z),yr($),xe,It,Ze,Gt);return Gt.delete(z),Ln;case D:if(rc)return rc.call(z)==rc.call($)}return!1}function sve(z,$,le,xe,It,Ze){var Gt=le&a,yr=zj(z),Ar=yr.length,kt=zj($),Ln=kt.length;if(Ar!=Ln&&!Gt)return!1;for(var Ca=Ar;Ca--;){var Hr=yr[Ca];if(!(Gt?Hr in $:Xt.call($,Hr)))return!1}var aa=Ze.get(z);if(aa&&Ze.get($))return aa==$;var ia=!0;Ze.set(z,$),Ze.set($,z);for(var Ro=Gt;++Ca<Ar;){Hr=yr[Ca];var Bi=z[Hr],bl=$[Hr];if(xe)var Vj=Gt?xe(bl,Bi,Hr,$,z,Ze):xe(Bi,bl,Hr,z,$,Ze);if(!(Vj===void 0?Bi===bl||It(Bi,bl,le,xe,Ze):Vj)){ia=!1;break}Ro||(Ro=Hr=="constructor")}if(ia&&!Ro){var my=z.constructor,_y=$.constructor;my!=_y&&"constructor"in z&&"constructor"in $&&!(typeof my=="function"&&my instanceof my&&typeof _y=="function"&&_y instanceof _y)&&(ia=!1)}return Ze.delete(z),Ze.delete($),ia}function zj(z){return tve(z,mve,uve)}function gy(z,$){var le=z.__data__;return fve($)?le[typeof $=="string"?"string":"hash"]:le.map}function nc(z,$){var le=zt(z,$);return nve(le)?le:void 0}function lve(z){var $=Xt.call(z,er),le=z[er];try{z[er]=void 0;var xe=!0}catch{}var It=pl.call(z);return xe&&($?z[er]=le:delete z[er]),It}var uve=Nn?function(z){return z==null?[]:(z=Object(z),ee(Nn(z),function($){return gl.call(z,$)}))}:_ve,ko=jh;(rt&&ko(new rt(new ArrayBuffer(1)))!=N||gr&&ko(new gr)!=p||tr&&ko(tr.resolve())!=_||Ie&&ko(new Ie)!=M||nt&&ko(new nt)!=I)&&(ko=function(z){var $=jh(z),le=$==m?z.constructor:void 0,xe=le?_l(le):"";if(xe)switch(xe){case Ke:return N;case rr:return p;case dn:return _;case Vr:return M;case vy:return I}return $});function cve(z,$){return $=$==null?o:$,!!$&&(typeof z=="number"||q.test(z))&&z>-1&&z%1==0&&z<$}function fve(z){var $=typeof z;return $=="string"||$=="number"||$=="symbol"||$=="boolean"?z!=="__proto__":z===null}function hve(z){return!!dl&&dl in z}function vve(z){var $=z&&z.constructor,le=typeof $=="function"&&$.prototype||Xe;return z===le}function dve(z){return pl.call(z)}function _l(z){if(z!=null){try{return fr.call(z)}catch{}try{return z+""}catch{}}return""}function kj(z,$){return z===$||z!==z&&$!==$}var pve=Ej(function(){return arguments}())?Ej:function(z){return Bh(z)&&Xt.call(z,"callee")&&!gl.call(z,"callee")},yy=Array.isArray;function gve(z){return z!=null&&jj(z.length)&&!Rj(z)}var Xw=Aa||bve;function yve(z,$){return Oj(z,$)}function Rj(z){if(!Bj(z))return!1;var $=jh(z);return $==v||$==d||$==u||$==b}function jj(z){return typeof z=="number"&&z>-1&&z%1==0&&z<=o}function Bj(z){var $=typeof z;return z!=null&&($=="object"||$=="function")}function Bh(z){return z!=null&&typeof z=="object"}var Fj=re?pt(re):ave;function mve(z){return gve(z)?eve(z):ive(z)}function _ve(){return[]}function bve(){return!1}r.exports=yve})(Ih,Ih.exports);function m3(r){var e,t,n="";if(typeof r=="string"||typeof r=="number")n+=r;else if(typeof r=="object")if(Array.isArray(r))for(e=0;e<r.length;e++)r[e]&&(t=m3(r[e]))&&(n&&(n+=" "),n+=t);else for(e in r)r[e]&&(n&&(n+=" "),n+=e);return n}function _3(){for(var r,e,t=0,n="";t<arguments.length;)(r=arguments[t++])&&(e=m3(r))&&(n&&(n+=" "),n+=e);return n}var Vue=Object.freeze(Object.defineProperty({__proto__:null,clsx:_3,default:_3},Symbol.toStringTag,{value:"Module"})),Vg=M5(Vue),et={},Hue=function(e,t,n){return e===t?!0:e.className===t.className&&n(e.style,t.style)&&e.width===t.width&&e.autoSize===t.autoSize&&e.cols===t.cols&&e.draggableCancel===t.draggableCancel&&e.draggableHandle===t.draggableHandle&&n(e.verticalCompact,t.verticalCompact)&&n(e.compactType,t.compactType)&&n(e.layout,t.layout)&&n(e.margin,t.margin)&&n(e.containerPadding,t.containerPadding)&&e.rowHeight===t.rowHeight&&e.maxRows===t.maxRows&&e.isBounded===t.isBounded&&e.isDraggable===t.isDraggable&&e.isResizable===t.isResizable&&e.allowOverlap===t.allowOverlap&&e.preventCollision===t.preventCollision&&e.useCSSTransforms===t.useCSSTransforms&&e.transformScale===t.transformScale&&e.isDroppable===t.isDroppable&&n(e.resizeHandles,t.resizeHandles)&&n(e.resizeHandle,t.resizeHandle)&&e.onLayoutChange===t.onLayoutChange&&e.onDragStart===t.onDragStart&&e.onDrag===t.onDrag&&e.onDragStop===t.onDragStop&&e.onResizeStart===t.onResizeStart&&e.onResize===t.onResize&&e.onResizeStop===t.onResizeStop&&e.onDrop===t.onDrop&&n(e.droppingItem,t.droppingItem)&&n(e.innerRef,t.innerRef)};Object.defineProperty(et,"__esModule",{value:!0}),et.bottom=lw,et.childrenEqual=Uue,et.cloneLayout=w3,et.cloneLayoutItem=ll,et.collides=Hg,et.compact=S3,et.compactItem=I3,et.compactType=tce,et.correctBounds=T3,et.fastPositionEqual=Que,et.fastRGLPropsEqual=void 0,et.getAllCollisions=A3,et.getFirstCollision=Yu,et.getLayoutItem=cw,et.getStatics=fw,et.modifyLayout=D3,et.moveElement=hw,et.moveElementAwayFromCollision=vw,et.noop=void 0,et.perc=que,et.setTopLeft=Jue,et.setTransform=Xue,et.sortLayoutItems=dw,et.sortLayoutItemsByColRow=N3,et.sortLayoutItemsByRowCol=C3,et.synchronizeLayoutWithChildren=Kue,et.validateLayout=ece,et.withLayoutItem=$ue;var Wue=b3(Ih.exports),sw=b3(pe.default);function b3(r){return r&&r.__esModule?r:{default:r}}function M3(r,e){var t=Object.keys(r);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(r);e&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(r,a).enumerable})),t.push.apply(t,n)}return t}function x3(r){for(var e=1;e<arguments.length;e++){var t=arguments[e]!=null?arguments[e]:{};e%2?M3(Object(t),!0).forEach(function(n){Gue(r,n,t[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(t)):M3(Object(t)).forEach(function(n){Object.defineProperty(r,n,Object.getOwnPropertyDescriptor(t,n))})}return r}function Gue(r,e,t){return e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}function lw(r){for(var e=0,t,n=0,a=r.length;n<a;n++)t=r[n].y+r[n].h,t>e&&(e=t);return e}function w3(r){for(var e=Array(r.length),t=0,n=r.length;t<n;t++)e[t]=ll(r[t]);return e}function D3(r,e){for(var t=Array(r.length),n=0,a=r.length;n<a;n++)e.i===r[n].i?t[n]=e:t[n]=r[n];return t}function $ue(r,e,t){var n=cw(r,e);return n?(n=t(ll(n)),r=D3(r,n),[r,n]):[r,null]}function ll(r){return{w:r.w,h:r.h,x:r.x,y:r.y,i:r.i,minW:r.minW,maxW:r.maxW,minH:r.minH,maxH:r.maxH,moved:Boolean(r.moved),static:Boolean(r.static),isDraggable:r.isDraggable,isResizable:r.isResizable,resizeHandles:r.resizeHandles,isBounded:r.isBounded}}function Uue(r,e){return(0,Wue.default)(sw.default.Children.map(r,function(t){return t==null?void 0:t.key}),sw.default.Children.map(e,function(t){return t==null?void 0:t.key}))}var Yue=Hue;et.fastRGLPropsEqual=Yue;function Que(r,e){return r.left===e.left&&r.top===e.top&&r.width===e.width&&r.height===e.height}function Hg(r,e){return!(r.i===e.i||r.x+r.w<=e.x||r.x>=e.x+e.w||r.y+r.h<=e.y||r.y>=e.y+e.h)}function S3(r,e,t){for(var n=fw(r),a=dw(r,e),i=Array(r.length),o=0,s=a.length;o<s;o++){var l=ll(a[o]);l.static||(l=I3(n,l,e,t,a),n.push(l)),i[r.indexOf(a[o])]=l,l.moved=!1}return i}var Zue={x:"w",y:"h"};function uw(r,e,t,n){var a=Zue[n];e[n]+=1;for(var i=r.map(function(l){return l.i}).indexOf(e.i),o=i+1;o<r.length;o++){var s=r[o];if(!s.static){if(s.y>e.y+e.h)break;Hg(e,s)&&uw(r,s,t+e[a],n)}}e[n]=t}function I3(r,e,t,n,a){var i=t==="vertical",o=t==="horizontal";if(i)for(e.y=Math.min(lw(r),e.y);e.y>0&&!Yu(r,e);)e.y--;else if(o)for(;e.x>0&&!Yu(r,e);)e.x--;for(var s;s=Yu(r,e);)o?uw(a,e,s.x+s.w,"x"):uw(a,e,s.y+s.h,"y"),o&&e.x+e.w>n&&(e.x=n-e.w,e.y++);return e.y=Math.max(e.y,0),e.x=Math.max(e.x,0),e}function T3(r,e){for(var t=fw(r),n=0,a=r.length;n<a;n++){var i=r[n];if(i.x+i.w>e.cols&&(i.x=e.cols-i.w),i.x<0&&(i.x=0,i.w=e.cols),!i.static)t.push(i);else for(;Yu(t,i);)i.y++}return r}function cw(r,e){for(var t=0,n=r.length;t<n;t++)if(r[t].i===e)return r[t]}function Yu(r,e){for(var t=0,n=r.length;t<n;t++)if(Hg(r[t],e))return r[t]}function A3(r,e){return r.filter(function(t){return Hg(t,e)})}function fw(r){return r.filter(function(e){return e.static})}function hw(r,e,t,n,a,i,o,s,l){if(e.static&&e.isDraggable!==!0||e.y===n&&e.x===t)return r;"Moving element ".concat(e.i," to [").concat(String(t),",").concat(String(n),"] from [").concat(e.x,",").concat(e.y,"]");var u=e.x,c=e.y;typeof t=="number"&&(e.x=t),typeof n=="number"&&(e.y=n),e.moved=!0;var f=dw(r,o),h=o==="vertical"&&typeof n=="number"?c>=n:o==="horizontal"&&typeof t=="number"?u>=t:!1;h&&(f=f.reverse());var v=A3(f,e),d=v.length>0;if(d&&l)return w3(r);if(d&&i)return"Collision prevented on ".concat(e.i,", reverting."),e.x=u,e.y=c,e.moved=!1,r;for(var p=0,g=v.length;p<g;p++){var y=v[p];"Resolving collision between ".concat(e.i," at [").concat(e.x,",").concat(e.y,"] and ").concat(y.i," at [").concat(y.x,",").concat(y.y,"]"),!y.moved&&(y.static?r=vw(r,y,e,a,o):r=vw(r,e,y,a,o))}return r}function vw(r,e,t,n,a,i){var o=a==="horizontal",s=a!=="horizontal",l=e.static;if(n){n=!1;var u={x:o?Math.max(e.x-t.w,0):t.x,y:s?Math.max(e.y-t.h,0):t.y,w:t.w,h:t.h,i:"-1"};if(!Yu(r,u))return"Doing reverse collision on ".concat(t.i," up to [").concat(u.x,",").concat(u.y,"]."),hw(r,t,o?u.x:void 0,s?u.y:void 0,n,l,a)}return hw(r,t,o?t.x+1:void 0,s?t.y+1:void 0,n,l,a)}function que(r){return r*100+"%"}function Xue(r){var e=r.top,t=r.left,n=r.width,a=r.height,i="translate(".concat(t,"px,").concat(e,"px)");return{transform:i,WebkitTransform:i,MozTransform:i,msTransform:i,OTransform:i,width:"".concat(n,"px"),height:"".concat(a,"px"),position:"absolute"}}function Jue(r){var e=r.top,t=r.left,n=r.width,a=r.height;return{top:"".concat(e,"px"),left:"".concat(t,"px"),width:"".concat(n,"px"),height:"".concat(a,"px"),position:"absolute"}}function dw(r,e){return e==="horizontal"?N3(r):e==="vertical"?C3(r):r}function C3(r){return r.slice(0).sort(function(e,t){return e.y>t.y||e.y===t.y&&e.x>t.x?1:e.y===t.y&&e.x===t.x?0:-1})}function N3(r){return r.slice(0).sort(function(e,t){return e.x>t.x||e.x===t.x&&e.y>t.y?1:-1})}function Kue(r,e,t,n,a){r=r||[];var i=[];sw.default.Children.forEach(e,function(s){if((s==null?void 0:s.key)!=null){var l=cw(r,String(s.key));if(l)i.push(ll(l));else{var u=s.props["data-grid"]||s.props._grid;u?i.push(ll(x3(x3({},u),{},{i:s.key}))):i.push(ll({w:1,h:1,x:0,y:lw(i),i:String(s.key)}))}}});var o=T3(i,{cols:t});return a?o:S3(o,n,t)}function ece(r){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"Layout",t=["x","y","w","h"];if(!Array.isArray(r))throw new Error(e+" must be an array!");for(var n=0,a=r.length;n<a;n++)for(var i=r[n],o=0;o<t.length;o++)if(typeof i[t[o]]!="number")throw new Error("ReactGridLayout: "+e+"["+n+"]."+t[o]+" must be a number!")}function tce(r){var e=r||{},t=e.verticalCompact,n=e.compactType;return t===!1?null:n}function Vme(){}var rce=function(){};et.noop=rce;var Pi={};Object.defineProperty(Pi,"__esModule",{value:!0}),Pi.calcGridColWidth=Wg,Pi.calcGridItemPosition=nce,Pi.calcGridItemWHPx=pw,Pi.calcWH=ice,Pi.calcXY=ace,Pi.clamp=Th;function Wg(r){var e=r.margin,t=r.containerPadding,n=r.containerWidth,a=r.cols;return(n-e[0]*(a-1)-t[0]*2)/a}function pw(r,e,t){return Number.isFinite(r)?Math.round(e*r+Math.max(0,r-1)*t):r}function nce(r,e,t,n,a,i){var o=r.margin,s=r.containerPadding,l=r.rowHeight,u=Wg(r),c={};return i&&i.resizing?(c.width=Math.round(i.resizing.width),c.height=Math.round(i.resizing.height)):(c.width=pw(n,u,o[0]),c.height=pw(a,l,o[1])),i&&i.dragging?(c.top=Math.round(i.dragging.top),c.left=Math.round(i.dragging.left)):(c.top=Math.round((l+o[1])*t+s[1]),c.left=Math.round((u+o[0])*e+s[0])),c}function ace(r,e,t,n,a){var i=r.margin,o=r.cols,s=r.rowHeight,l=r.maxRows,u=Wg(r),c=Math.round((t-i[0])/(u+i[0])),f=Math.round((e-i[1])/(s+i[1]));return c=Th(c,0,o-n),f=Th(f,0,l-a),{x:c,y:f}}function ice(r,e,t,n,a){var i=r.margin,o=r.maxRows,s=r.cols,l=r.rowHeight,u=Wg(r),c=Math.round((e+i[0])/(u+i[0])),f=Math.round((t+i[1])/(l+i[1]));return c=Th(c,0,s-n),f=Th(f,0,o-a),{w:c,h:f}}function Th(r,e,t){return Math.max(Math.min(r,t),e)}var Gg={},zi={exports:{}},oce="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",sce=oce,lce=sce;function L3(){}function E3(){}E3.resetWarningCache=L3;var uce=function(){function r(n,a,i,o,s,l){if(l!==lce){var u=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw u.name="Invariant Violation",u}}r.isRequired=r;function e(){return r}var t={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:e,element:r,elementType:r,instanceOf:e,node:r,objectOf:e,oneOf:e,oneOfType:e,shape:e,exact:e,checkPropTypes:E3,resetWarningCache:L3};return t.PropTypes=t,t};zi.exports=uce();var Ah={exports:{}},O3={},Ht={},ti={};Object.defineProperty(ti,"__esModule",{value:!0}),ti.dontSetMe=dce,ti.findInArray=cce,ti.int=vce,ti.isFunction=fce,ti.isNum=hce;function cce(r,e){for(var t=0,n=r.length;t<n;t++)if(e.apply(e,[r[t],t,r]))return r[t]}function fce(r){return typeof r=="function"||Object.prototype.toString.call(r)==="[object Function]"}function hce(r){return typeof r=="number"&&!isNaN(r)}function vce(r){return parseInt(r,10)}function dce(r,e,t){if(r[e])return new Error("Invalid prop ".concat(e," passed to ").concat(t," - do not set this, set it on the child."))}var ul={};Object.defineProperty(ul,"__esModule",{value:!0}),ul.browserPrefixToKey=z3,ul.browserPrefixToStyle=pce,ul.default=void 0,ul.getPrefix=P3;var gw=["Moz","Webkit","O","ms"];function P3(){var r,e,t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"transform";if(typeof window=="undefined")return"";var n=(r=window.document)===null||r===void 0||(e=r.documentElement)===null||e===void 0?void 0:e.style;if(!n||t in n)return"";for(var a=0;a<gw.length;a++)if(z3(t,gw[a])in n)return gw[a];return""}function z3(r,e){return e?"".concat(e).concat(gce(r)):r}function pce(r,e){return e?"-".concat(e.toLowerCase(),"-").concat(r):r}function gce(r){for(var e="",t=!0,n=0;n<r.length;n++)t?(e+=r[n].toUpperCase(),t=!1):r[n]==="-"?t=!0:e+=r[n];return e}var yce=P3();ul.default=yce;function yw(r){return yw=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},yw(r)}Object.defineProperty(Ht,"__esModule",{value:!0}),Ht.addClassName=H3,Ht.addEvent=bce,Ht.addUserSelectStyles=Lce,Ht.createCSSTransform=Tce,Ht.createSVGTransform=Ace,Ht.getTouch=Cce,Ht.getTouchIdentifier=Nce,Ht.getTranslation=mw,Ht.innerHeight=Dce,Ht.innerWidth=Sce,Ht.matchesSelector=V3,Ht.matchesSelectorAndParentsTo=_ce,Ht.offsetXYFromParent=Ice,Ht.outerHeight=xce,Ht.outerWidth=wce,Ht.removeClassName=W3,Ht.removeEvent=Mce,Ht.removeUserSelectStyles=Ece;var In=ti,k3=mce(ul);function R3(r){if(typeof WeakMap!="function")return null;var e=new WeakMap,t=new WeakMap;return(R3=function(a){return a?t:e})(r)}function mce(r,e){if(!e&&r&&r.__esModule)return r;if(r===null||yw(r)!=="object"&&typeof r!="function")return{default:r};var t=R3(e);if(t&&t.has(r))return t.get(r);var n={},a=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in r)if(i!=="default"&&Object.prototype.hasOwnProperty.call(r,i)){var o=a?Object.getOwnPropertyDescriptor(r,i):null;o&&(o.get||o.set)?Object.defineProperty(n,i,o):n[i]=r[i]}return n.default=r,t&&t.set(r,n),n}function j3(r,e){var t=Object.keys(r);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(r);e&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(r,a).enumerable})),t.push.apply(t,n)}return t}function B3(r){for(var e=1;e<arguments.length;e++){var t=arguments[e]!=null?arguments[e]:{};e%2?j3(Object(t),!0).forEach(function(n){F3(r,n,t[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(t)):j3(Object(t)).forEach(function(n){Object.defineProperty(r,n,Object.getOwnPropertyDescriptor(t,n))})}return r}function F3(r,e,t){return e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}var $g="";function V3(r,e){return $g||($g=(0,In.findInArray)(["matches","webkitMatchesSelector","mozMatchesSelector","msMatchesSelector","oMatchesSelector"],function(t){return(0,In.isFunction)(r[t])})),(0,In.isFunction)(r[$g])?r[$g](e):!1}function _ce(r,e,t){var n=r;do{if(V3(n,e))return!0;if(n===t)return!1;n=n.parentNode}while(n);return!1}function bce(r,e,t,n){if(!!r){var a=B3({capture:!0},n);r.addEventListener?r.addEventListener(e,t,a):r.attachEvent?r.attachEvent("on"+e,t):r["on"+e]=t}}function Mce(r,e,t,n){if(!!r){var a=B3({capture:!0},n);r.removeEventListener?r.removeEventListener(e,t,a):r.detachEvent?r.detachEvent("on"+e,t):r["on"+e]=null}}function xce(r){var e=r.clientHeight,t=r.ownerDocument.defaultView.getComputedStyle(r);return e+=(0,In.int)(t.borderTopWidth),e+=(0,In.int)(t.borderBottomWidth),e}function wce(r){var e=r.clientWidth,t=r.ownerDocument.defaultView.getComputedStyle(r);return e+=(0,In.int)(t.borderLeftWidth),e+=(0,In.int)(t.borderRightWidth),e}function Dce(r){var e=r.clientHeight,t=r.ownerDocument.defaultView.getComputedStyle(r);return e-=(0,In.int)(t.paddingTop),e-=(0,In.int)(t.paddingBottom),e}function Sce(r){var e=r.clientWidth,t=r.ownerDocument.defaultView.getComputedStyle(r);return e-=(0,In.int)(t.paddingLeft),e-=(0,In.int)(t.paddingRight),e}function Ice(r,e,t){var n=e===e.ownerDocument.body,a=n?{left:0,top:0}:e.getBoundingClientRect(),i=(r.clientX+e.scrollLeft-a.left)/t,o=(r.clientY+e.scrollTop-a.top)/t;return{x:i,y:o}}function Tce(r,e){var t=mw(r,e,"px");return F3({},(0,k3.browserPrefixToKey)("transform",k3.default),t)}function Ace(r,e){var t=mw(r,e,"");return t}function mw(r,e,t){var n=r.x,a=r.y,i="translate(".concat(n).concat(t,",").concat(a).concat(t,")");if(e){var o="".concat(typeof e.x=="string"?e.x:e.x+t),s="".concat(typeof e.y=="string"?e.y:e.y+t);i="translate(".concat(o,", ").concat(s,")")+i}return i}function Cce(r,e){return r.targetTouches&&(0,In.findInArray)(r.targetTouches,function(t){return e===t.identifier})||r.changedTouches&&(0,In.findInArray)(r.changedTouches,function(t){return e===t.identifier})}function Nce(r){if(r.targetTouches&&r.targetTouches[0])return r.targetTouches[0].identifier;if(r.changedTouches&&r.changedTouches[0])return r.changedTouches[0].identifier}function Lce(r){if(!!r){var e=r.getElementById("react-draggable-style-el");e||(e=r.createElement("style"),e.type="text/css",e.id="react-draggable-style-el",e.innerHTML=`.react-draggable-transparent-selection *::-moz-selection {all: inherit;}
|
|
335
|
+
`,e.innerHTML+=`.react-draggable-transparent-selection *::selection {all: inherit;}
|
|
336
|
+
`,r.getElementsByTagName("head")[0].appendChild(e)),r.body&&H3(r.body,"react-draggable-transparent-selection")}}function Ece(r){if(!!r)try{if(r.body&&W3(r.body,"react-draggable-transparent-selection"),r.selection)r.selection.empty();else{var e=(r.defaultView||window).getSelection();e&&e.type!=="Caret"&&e.removeAllRanges()}}catch{}}function H3(r,e){r.classList?r.classList.add(e):r.className.match(new RegExp("(?:^|\\s)".concat(e,"(?!\\S)")))||(r.className+=" ".concat(e))}function W3(r,e){r.classList?r.classList.remove(e):r.className=r.className.replace(new RegExp("(?:^|\\s)".concat(e,"(?!\\S)"),"g"),"")}var ri={};Object.defineProperty(ri,"__esModule",{value:!0}),ri.canDragX=zce,ri.canDragY=kce,ri.createCoreData=jce,ri.createDraggableData=Bce,ri.getBoundPosition=Oce,ri.getControlPosition=Rce,ri.snapToGrid=Pce;var Tn=ti,Qu=Ht;function Oce(r,e,t){if(!r.props.bounds)return[e,t];var n=r.props.bounds;n=typeof n=="string"?n:Fce(n);var a=_w(r);if(typeof n=="string"){var i=a.ownerDocument,o=i.defaultView,s;if(n==="parent"?s=a.parentNode:s=i.querySelector(n),!(s instanceof o.HTMLElement))throw new Error('Bounds selector "'+n+'" could not find an element.');var l=s,u=o.getComputedStyle(a),c=o.getComputedStyle(l);n={left:-a.offsetLeft+(0,Tn.int)(c.paddingLeft)+(0,Tn.int)(u.marginLeft),top:-a.offsetTop+(0,Tn.int)(c.paddingTop)+(0,Tn.int)(u.marginTop),right:(0,Qu.innerWidth)(l)-(0,Qu.outerWidth)(a)-a.offsetLeft+(0,Tn.int)(c.paddingRight)-(0,Tn.int)(u.marginRight),bottom:(0,Qu.innerHeight)(l)-(0,Qu.outerHeight)(a)-a.offsetTop+(0,Tn.int)(c.paddingBottom)-(0,Tn.int)(u.marginBottom)}}return(0,Tn.isNum)(n.right)&&(e=Math.min(e,n.right)),(0,Tn.isNum)(n.bottom)&&(t=Math.min(t,n.bottom)),(0,Tn.isNum)(n.left)&&(e=Math.max(e,n.left)),(0,Tn.isNum)(n.top)&&(t=Math.max(t,n.top)),[e,t]}function Pce(r,e,t){var n=Math.round(e/r[0])*r[0],a=Math.round(t/r[1])*r[1];return[n,a]}function zce(r){return r.props.axis==="both"||r.props.axis==="x"}function kce(r){return r.props.axis==="both"||r.props.axis==="y"}function Rce(r,e,t){var n=typeof e=="number"?(0,Qu.getTouch)(r,e):null;if(typeof e=="number"&&!n)return null;var a=_w(t),i=t.props.offsetParent||a.offsetParent||a.ownerDocument.body;return(0,Qu.offsetXYFromParent)(n||r,i,t.props.scale)}function jce(r,e,t){var n=r.state,a=!(0,Tn.isNum)(n.lastX),i=_w(r);return a?{node:i,deltaX:0,deltaY:0,lastX:e,lastY:t,x:e,y:t}:{node:i,deltaX:e-n.lastX,deltaY:t-n.lastY,lastX:n.lastX,lastY:n.lastY,x:e,y:t}}function Bce(r,e){var t=r.props.scale;return{node:e.node,x:r.state.x+e.deltaX/t,y:r.state.y+e.deltaY/t,deltaX:e.deltaX/t,deltaY:e.deltaY/t,lastX:r.state.x,lastY:r.state.y}}function Fce(r){return{left:r.left,top:r.top,right:r.right,bottom:r.bottom}}function _w(r){var e=r.findDOMNode();if(!e)throw new Error("<DraggableCore>: Unmounted during event!");return e}var Ug={},Yg={};Object.defineProperty(Yg,"__esModule",{value:!0}),Yg.default=Vce;function Vce(){}function Qg(r){return Qg=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Qg(r)}Object.defineProperty(Ug,"__esModule",{value:!0}),Ug.default=void 0;var bw=Wce(pe.default),An=xw(zi.exports),Hce=xw(Fh.default),Br=Ht,Eo=ri,Mw=ti,Ch=xw(Yg);function xw(r){return r&&r.__esModule?r:{default:r}}function G3(r){if(typeof WeakMap!="function")return null;var e=new WeakMap,t=new WeakMap;return(G3=function(a){return a?t:e})(r)}function Wce(r,e){if(!e&&r&&r.__esModule)return r;if(r===null||Qg(r)!=="object"&&typeof r!="function")return{default:r};var t=G3(e);if(t&&t.has(r))return t.get(r);var n={},a=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in r)if(i!=="default"&&Object.prototype.hasOwnProperty.call(r,i)){var o=a?Object.getOwnPropertyDescriptor(r,i):null;o&&(o.get||o.set)?Object.defineProperty(n,i,o):n[i]=r[i]}return n.default=r,t&&t.set(r,n),n}function $3(r,e){return Yce(r)||Uce(r,e)||$ce(r,e)||Gce()}function Gce(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
337
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function $ce(r,e){if(!!r){if(typeof r=="string")return U3(r,e);var t=Object.prototype.toString.call(r).slice(8,-1);if(t==="Object"&&r.constructor&&(t=r.constructor.name),t==="Map"||t==="Set")return Array.from(r);if(t==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return U3(r,e)}}function U3(r,e){(e==null||e>r.length)&&(e=r.length);for(var t=0,n=new Array(e);t<e;t++)n[t]=r[t];return n}function Uce(r,e){var t=r==null?null:typeof Symbol!="undefined"&&r[Symbol.iterator]||r["@@iterator"];if(t!=null){var n=[],a=!0,i=!1,o,s;try{for(t=t.call(r);!(a=(o=t.next()).done)&&(n.push(o.value),!(e&&n.length===e));a=!0);}catch(l){i=!0,s=l}finally{try{!a&&t.return!=null&&t.return()}finally{if(i)throw s}}return n}}function Yce(r){if(Array.isArray(r))return r}function Qce(r,e){if(!(r instanceof e))throw new TypeError("Cannot call a class as a function")}function Y3(r,e){for(var t=0;t<e.length;t++){var n=e[t];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(r,n.key,n)}}function Zce(r,e,t){return e&&Y3(r.prototype,e),t&&Y3(r,t),Object.defineProperty(r,"prototype",{writable:!1}),r}function qce(r,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");r.prototype=Object.create(e&&e.prototype,{constructor:{value:r,writable:!0,configurable:!0}}),Object.defineProperty(r,"prototype",{writable:!1}),e&&ww(r,e)}function ww(r,e){return ww=Object.setPrototypeOf||function(n,a){return n.__proto__=a,n},ww(r,e)}function Xce(r){var e=Kce();return function(){var n=Zg(r),a;if(e){var i=Zg(this).constructor;a=Reflect.construct(n,arguments,i)}else a=n.apply(this,arguments);return Jce(this,a)}}function Jce(r,e){if(e&&(Qg(e)==="object"||typeof e=="function"))return e;if(e!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Fr(r)}function Fr(r){if(r===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return r}function Kce(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Zg(r){return Zg=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},Zg(r)}function ta(r,e,t){return e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}var Ia={touch:{start:"touchstart",move:"touchmove",stop:"touchend"},mouse:{start:"mousedown",move:"mousemove",stop:"mouseup"}},Oo=Ia.mouse,qg=function(r){qce(t,r);var e=Xce(t);function t(){var n;Qce(this,t);for(var a=arguments.length,i=new Array(a),o=0;o<a;o++)i[o]=arguments[o];return n=e.call.apply(e,[this].concat(i)),ta(Fr(n),"state",{dragging:!1,lastX:NaN,lastY:NaN,touchIdentifier:null}),ta(Fr(n),"mounted",!1),ta(Fr(n),"handleDragStart",function(s){if(n.props.onMouseDown(s),!n.props.allowAnyClick&&typeof s.button=="number"&&s.button!==0)return!1;var l=n.findDOMNode();if(!l||!l.ownerDocument||!l.ownerDocument.body)throw new Error("<DraggableCore> not mounted on DragStart!");var u=l.ownerDocument;if(!(n.props.disabled||!(s.target instanceof u.defaultView.Node)||n.props.handle&&!(0,Br.matchesSelectorAndParentsTo)(s.target,n.props.handle,l)||n.props.cancel&&(0,Br.matchesSelectorAndParentsTo)(s.target,n.props.cancel,l))){s.type==="touchstart"&&s.preventDefault();var c=(0,Br.getTouchIdentifier)(s);n.setState({touchIdentifier:c});var f=(0,Eo.getControlPosition)(s,c,Fr(n));if(f!=null){var h=f.x,v=f.y,d=(0,Eo.createCoreData)(Fr(n),h,v);(0,Ch.default)("DraggableCore: handleDragStart: %j",d),(0,Ch.default)("calling",n.props.onStart);var p=n.props.onStart(s,d);p===!1||n.mounted===!1||(n.props.enableUserSelectHack&&(0,Br.addUserSelectStyles)(u),n.setState({dragging:!0,lastX:h,lastY:v}),(0,Br.addEvent)(u,Oo.move,n.handleDrag),(0,Br.addEvent)(u,Oo.stop,n.handleDragStop))}}}),ta(Fr(n),"handleDrag",function(s){var l=(0,Eo.getControlPosition)(s,n.state.touchIdentifier,Fr(n));if(l!=null){var u=l.x,c=l.y;if(Array.isArray(n.props.grid)){var f=u-n.state.lastX,h=c-n.state.lastY,v=(0,Eo.snapToGrid)(n.props.grid,f,h),d=$3(v,2);if(f=d[0],h=d[1],!f&&!h)return;u=n.state.lastX+f,c=n.state.lastY+h}var p=(0,Eo.createCoreData)(Fr(n),u,c);(0,Ch.default)("DraggableCore: handleDrag: %j",p);var g=n.props.onDrag(s,p);if(g===!1||n.mounted===!1){try{n.handleDragStop(new MouseEvent("mouseup"))}catch{var y=document.createEvent("MouseEvents");y.initMouseEvent("mouseup",!0,!0,window,0,0,0,0,0,!1,!1,!1,!1,0,null),n.handleDragStop(y)}return}n.setState({lastX:u,lastY:c})}}),ta(Fr(n),"handleDragStop",function(s){if(!!n.state.dragging){var l=(0,Eo.getControlPosition)(s,n.state.touchIdentifier,Fr(n));if(l!=null){var u=l.x,c=l.y;if(Array.isArray(n.props.grid)){var f=u-n.state.lastX||0,h=c-n.state.lastY||0,v=(0,Eo.snapToGrid)(n.props.grid,f,h),d=$3(v,2);f=d[0],h=d[1],u=n.state.lastX+f,c=n.state.lastY+h}var p=(0,Eo.createCoreData)(Fr(n),u,c),g=n.props.onStop(s,p);if(g===!1||n.mounted===!1)return!1;var y=n.findDOMNode();y&&n.props.enableUserSelectHack&&(0,Br.removeUserSelectStyles)(y.ownerDocument),(0,Ch.default)("DraggableCore: handleDragStop: %j",p),n.setState({dragging:!1,lastX:NaN,lastY:NaN}),y&&((0,Ch.default)("DraggableCore: Removing handlers"),(0,Br.removeEvent)(y.ownerDocument,Oo.move,n.handleDrag),(0,Br.removeEvent)(y.ownerDocument,Oo.stop,n.handleDragStop))}}}),ta(Fr(n),"onMouseDown",function(s){return Oo=Ia.mouse,n.handleDragStart(s)}),ta(Fr(n),"onMouseUp",function(s){return Oo=Ia.mouse,n.handleDragStop(s)}),ta(Fr(n),"onTouchStart",function(s){return Oo=Ia.touch,n.handleDragStart(s)}),ta(Fr(n),"onTouchEnd",function(s){return Oo=Ia.touch,n.handleDragStop(s)}),n}return Zce(t,[{key:"componentDidMount",value:function(){this.mounted=!0;var a=this.findDOMNode();a&&(0,Br.addEvent)(a,Ia.touch.start,this.onTouchStart,{passive:!1})}},{key:"componentWillUnmount",value:function(){this.mounted=!1;var a=this.findDOMNode();if(a){var i=a.ownerDocument;(0,Br.removeEvent)(i,Ia.mouse.move,this.handleDrag),(0,Br.removeEvent)(i,Ia.touch.move,this.handleDrag),(0,Br.removeEvent)(i,Ia.mouse.stop,this.handleDragStop),(0,Br.removeEvent)(i,Ia.touch.stop,this.handleDragStop),(0,Br.removeEvent)(a,Ia.touch.start,this.onTouchStart,{passive:!1}),this.props.enableUserSelectHack&&(0,Br.removeUserSelectStyles)(i)}}},{key:"findDOMNode",value:function(){var a,i,o;return(a=this.props)!==null&&a!==void 0&&a.nodeRef?(i=this.props)===null||i===void 0||(o=i.nodeRef)===null||o===void 0?void 0:o.current:Hce.default.findDOMNode(this)}},{key:"render",value:function(){return bw.cloneElement(bw.Children.only(this.props.children),{onMouseDown:this.onMouseDown,onMouseUp:this.onMouseUp,onTouchEnd:this.onTouchEnd})}}]),t}(bw.Component);Ug.default=qg,ta(qg,"displayName","DraggableCore"),ta(qg,"propTypes",{allowAnyClick:An.default.bool,disabled:An.default.bool,enableUserSelectHack:An.default.bool,offsetParent:function(e,t){if(e[t]&&e[t].nodeType!==1)throw new Error("Draggable's offsetParent must be a DOM Node.")},grid:An.default.arrayOf(An.default.number),handle:An.default.string,cancel:An.default.string,nodeRef:An.default.object,onStart:An.default.func,onDrag:An.default.func,onStop:An.default.func,onMouseDown:An.default.func,scale:An.default.number,className:Mw.dontSetMe,style:Mw.dontSetMe,transform:Mw.dontSetMe}),ta(qg,"defaultProps",{allowAnyClick:!1,disabled:!1,enableUserSelectHack:!0,onStart:function(){},onDrag:function(){},onStop:function(){},onMouseDown:function(){},scale:1}),function(r){function e(V){return e=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(Y){return typeof Y}:function(Y){return Y&&typeof Symbol=="function"&&Y.constructor===Symbol&&Y!==Symbol.prototype?"symbol":typeof Y},e(V)}Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"DraggableCore",{enumerable:!0,get:function(){return u.default}}),r.default=void 0;var t=d(pe.default),n=h(zi.exports),a=h(Fh.default),i=h(Vg),o=Ht,s=ri,l=ti,u=h(Ug),c=h(Yg),f=["axis","bounds","children","defaultPosition","defaultClassName","defaultClassNameDragging","defaultClassNameDragged","position","positionOffset","scale"];function h(V){return V&&V.__esModule?V:{default:V}}function v(V){if(typeof WeakMap!="function")return null;var Y=new WeakMap,q=new WeakMap;return(v=function(ne){return ne?q:Y})(V)}function d(V,Y){if(!Y&&V&&V.__esModule)return V;if(V===null||e(V)!=="object"&&typeof V!="function")return{default:V};var q=v(Y);if(q&&q.has(V))return q.get(V);var Q={},ne=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var oe in V)if(oe!=="default"&&Object.prototype.hasOwnProperty.call(V,oe)){var ie=ne?Object.getOwnPropertyDescriptor(V,oe):null;ie&&(ie.get||ie.set)?Object.defineProperty(Q,oe,ie):Q[oe]=V[oe]}return Q.default=V,q&&q.set(V,Q),Q}function p(){return p=Object.assign||function(V){for(var Y=1;Y<arguments.length;Y++){var q=arguments[Y];for(var Q in q)Object.prototype.hasOwnProperty.call(q,Q)&&(V[Q]=q[Q])}return V},p.apply(this,arguments)}function g(V,Y){if(V==null)return{};var q=y(V,Y),Q,ne;if(Object.getOwnPropertySymbols){var oe=Object.getOwnPropertySymbols(V);for(ne=0;ne<oe.length;ne++)Q=oe[ne],!(Y.indexOf(Q)>=0)&&(!Object.prototype.propertyIsEnumerable.call(V,Q)||(q[Q]=V[Q]))}return q}function y(V,Y){if(V==null)return{};var q={},Q=Object.keys(V),ne,oe;for(oe=0;oe<Q.length;oe++)ne=Q[oe],!(Y.indexOf(ne)>=0)&&(q[ne]=V[ne]);return q}function m(V,Y){var q=Object.keys(V);if(Object.getOwnPropertySymbols){var Q=Object.getOwnPropertySymbols(V);Y&&(Q=Q.filter(function(ne){return Object.getOwnPropertyDescriptor(V,ne).enumerable})),q.push.apply(q,Q)}return q}function _(V){for(var Y=1;Y<arguments.length;Y++){var q=arguments[Y]!=null?arguments[Y]:{};Y%2?m(Object(q),!0).forEach(function(Q){Z(V,Q,q[Q])}):Object.getOwnPropertyDescriptors?Object.defineProperties(V,Object.getOwnPropertyDescriptors(q)):m(Object(q)).forEach(function(Q){Object.defineProperty(V,Q,Object.getOwnPropertyDescriptor(q,Q))})}return V}function b(V,Y){return T(V)||D(V,Y)||M(V,Y)||x()}function x(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
338
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function M(V,Y){if(!!V){if(typeof V=="string")return w(V,Y);var q=Object.prototype.toString.call(V).slice(8,-1);if(q==="Object"&&V.constructor&&(q=V.constructor.name),q==="Map"||q==="Set")return Array.from(V);if(q==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(q))return w(V,Y)}}function w(V,Y){(Y==null||Y>V.length)&&(Y=V.length);for(var q=0,Q=new Array(Y);q<Y;q++)Q[q]=V[q];return Q}function D(V,Y){var q=V==null?null:typeof Symbol!="undefined"&&V[Symbol.iterator]||V["@@iterator"];if(q!=null){var Q=[],ne=!0,oe=!1,ie,he;try{for(q=q.call(V);!(ne=(ie=q.next()).done)&&(Q.push(ie.value),!(Y&&Q.length===Y));ne=!0);}catch(k){oe=!0,he=k}finally{try{!ne&&q.return!=null&&q.return()}finally{if(oe)throw he}}return Q}}function T(V){if(Array.isArray(V))return V}function I(V,Y){if(!(V instanceof Y))throw new TypeError("Cannot call a class as a function")}function A(V,Y){for(var q=0;q<Y.length;q++){var Q=Y[q];Q.enumerable=Q.enumerable||!1,Q.configurable=!0,"value"in Q&&(Q.writable=!0),Object.defineProperty(V,Q.key,Q)}}function N(V,Y,q){return Y&&A(V.prototype,Y),q&&A(V,q),Object.defineProperty(V,"prototype",{writable:!1}),V}function L(V,Y){if(typeof Y!="function"&&Y!==null)throw new TypeError("Super expression must either be null or a function");V.prototype=Object.create(Y&&Y.prototype,{constructor:{value:V,writable:!0,configurable:!0}}),Object.defineProperty(V,"prototype",{writable:!1}),Y&&E(V,Y)}function E(V,Y){return E=Object.setPrototypeOf||function(Q,ne){return Q.__proto__=ne,Q},E(V,Y)}function O(V){var Y=F();return function(){var Q=G(V),ne;if(Y){var oe=G(this).constructor;ne=Reflect.construct(Q,arguments,oe)}else ne=Q.apply(this,arguments);return P(this,ne)}}function P(V,Y){if(Y&&(e(Y)==="object"||typeof Y=="function"))return Y;if(Y!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return H(V)}function H(V){if(V===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return V}function F(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function G(V){return G=Object.setPrototypeOf?Object.getPrototypeOf:function(q){return q.__proto__||Object.getPrototypeOf(q)},G(V)}function Z(V,Y,q){return Y in V?Object.defineProperty(V,Y,{value:q,enumerable:!0,configurable:!0,writable:!0}):V[Y]=q,V}var te=function(V){L(q,V);var Y=O(q);function q(Q){var ne;return I(this,q),ne=Y.call(this,Q),Z(H(ne),"onDragStart",function(oe,ie){(0,c.default)("Draggable: onDragStart: %j",ie);var he=ne.props.onStart(oe,(0,s.createDraggableData)(H(ne),ie));if(he===!1)return!1;ne.setState({dragging:!0,dragged:!0})}),Z(H(ne),"onDrag",function(oe,ie){if(!ne.state.dragging)return!1;(0,c.default)("Draggable: onDrag: %j",ie);var he=(0,s.createDraggableData)(H(ne),ie),k={x:he.x,y:he.y};if(ne.props.bounds){var j=k.x,W=k.y;k.x+=ne.state.slackX,k.y+=ne.state.slackY;var ae=(0,s.getBoundPosition)(H(ne),k.x,k.y),re=b(ae,2),ee=re[0],se=re[1];k.x=ee,k.y=se,k.slackX=ne.state.slackX+(j-k.x),k.slackY=ne.state.slackY+(W-k.y),he.x=k.x,he.y=k.y,he.deltaX=k.x-ne.state.x,he.deltaY=k.y-ne.state.y}var Le=ne.props.onDrag(oe,he);if(Le===!1)return!1;ne.setState(k)}),Z(H(ne),"onDragStop",function(oe,ie){if(!ne.state.dragging)return!1;var he=ne.props.onStop(oe,(0,s.createDraggableData)(H(ne),ie));if(he===!1)return!1;(0,c.default)("Draggable: onDragStop: %j",ie);var k={dragging:!1,slackX:0,slackY:0},j=Boolean(ne.props.position);if(j){var W=ne.props.position,ae=W.x,re=W.y;k.x=ae,k.y=re}ne.setState(k)}),ne.state={dragging:!1,dragged:!1,x:Q.position?Q.position.x:Q.defaultPosition.x,y:Q.position?Q.position.y:Q.defaultPosition.y,prevPropsPosition:_({},Q.position),slackX:0,slackY:0,isElementSVG:!1},Q.position&&!(Q.onDrag||Q.onStop)&&console.warn("A `position` was applied to this <Draggable>, without drag handlers. This will make this component effectively undraggable. Please attach `onDrag` or `onStop` handlers so you can adjust the `position` of this element."),ne}return N(q,[{key:"componentDidMount",value:function(){typeof window.SVGElement!="undefined"&&this.findDOMNode()instanceof window.SVGElement&&this.setState({isElementSVG:!0})}},{key:"componentWillUnmount",value:function(){this.setState({dragging:!1})}},{key:"findDOMNode",value:function(){var ne,oe,ie;return(ne=(oe=this.props)===null||oe===void 0||(ie=oe.nodeRef)===null||ie===void 0?void 0:ie.current)!==null&&ne!==void 0?ne:a.default.findDOMNode(this)}},{key:"render",value:function(){var ne,oe=this.props;oe.axis,oe.bounds;var ie=oe.children,he=oe.defaultPosition,k=oe.defaultClassName,j=oe.defaultClassNameDragging,W=oe.defaultClassNameDragged,ae=oe.position,re=oe.positionOffset;oe.scale;var ee=g(oe,f),se={},Le=null,dt=Boolean(ae),pt=!dt||this.state.dragging,_t=ae||he,zt={x:(0,s.canDragX)(this)&&pt?this.state.x:_t.x,y:(0,s.canDragY)(this)&&pt?this.state.y:_t.y};this.state.isElementSVG?Le=(0,o.createSVGTransform)(zt,re):se=(0,o.createCSSTransform)(zt,re);var qt=(0,i.default)(ie.props.className||"",k,(ne={},Z(ne,j,this.state.dragging),Z(ne,W,this.state.dragged),ne));return t.createElement(u.default,p({},ee,{onStart:this.onDragStart,onDrag:this.onDrag,onStop:this.onDragStop}),t.cloneElement(t.Children.only(ie),{className:qt,style:_(_({},ie.props.style),se),transform:Le}))}}],[{key:"getDerivedStateFromProps",value:function(ne,oe){var ie=ne.position,he=oe.prevPropsPosition;return ie&&(!he||ie.x!==he.x||ie.y!==he.y)?((0,c.default)("Draggable: getDerivedStateFromProps %j",{position:ie,prevPropsPosition:he}),{x:ie.x,y:ie.y,prevPropsPosition:_({},ie)}):null}}]),q}(t.Component);r.default=te,Z(te,"displayName","Draggable"),Z(te,"propTypes",_(_({},u.default.propTypes),{},{axis:n.default.oneOf(["both","x","y","none"]),bounds:n.default.oneOfType([n.default.shape({left:n.default.number,right:n.default.number,top:n.default.number,bottom:n.default.number}),n.default.string,n.default.oneOf([!1])]),defaultClassName:n.default.string,defaultClassNameDragging:n.default.string,defaultClassNameDragged:n.default.string,defaultPosition:n.default.shape({x:n.default.number,y:n.default.number}),positionOffset:n.default.shape({x:n.default.oneOfType([n.default.number,n.default.string]),y:n.default.oneOfType([n.default.number,n.default.string])}),position:n.default.shape({x:n.default.number,y:n.default.number}),className:l.dontSetMe,style:l.dontSetMe,transform:l.dontSetMe})),Z(te,"defaultProps",_(_({},u.default.defaultProps),{},{axis:"both",bounds:!1,defaultClassName:"react-draggable",defaultClassNameDragging:"react-draggable-dragging",defaultClassNameDragged:"react-draggable-dragged",defaultPosition:{x:0,y:0},scale:1}))}(O3);var Q3=O3,Z3=Q3.default,efe=Q3.DraggableCore;Ah.exports=Z3,Ah.exports.default=Z3,Ah.exports.DraggableCore=efe;var Xg={exports:{}},Nh={},Dw={};Dw.__esModule=!0,Dw.cloneElement=afe;var tfe=rfe(pe.default);function rfe(r){return r&&r.__esModule?r:{default:r}}function q3(r,e){var t=Object.keys(r);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(r);e&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(r,a).enumerable})),t.push.apply(t,n)}return t}function X3(r){for(var e=1;e<arguments.length;e++){var t=arguments[e]!=null?arguments[e]:{};e%2?q3(Object(t),!0).forEach(function(n){nfe(r,n,t[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(t)):q3(Object(t)).forEach(function(n){Object.defineProperty(r,n,Object.getOwnPropertyDescriptor(t,n))})}return r}function nfe(r,e,t){return e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}function afe(r,e){return e.style&&r.props.style&&(e.style=X3(X3({},r.props.style),e.style)),e.className&&r.props.className&&(e.className=r.props.className+" "+e.className),tfe.default.cloneElement(r,e)}var Lh={};Lh.__esModule=!0,Lh.resizableProps=void 0;var tt=ife(zi.exports);function ife(r){return r&&r.__esModule?r:{default:r}}var ofe={axis:tt.default.oneOf(["both","x","y","none"]),className:tt.default.string,children:tt.default.element.isRequired,draggableOpts:tt.default.shape({allowAnyClick:tt.default.bool,cancel:tt.default.string,children:tt.default.node,disabled:tt.default.bool,enableUserSelectHack:tt.default.bool,offsetParent:tt.default.node,grid:tt.default.arrayOf(tt.default.number),handle:tt.default.string,nodeRef:tt.default.object,onStart:tt.default.func,onDrag:tt.default.func,onStop:tt.default.func,onMouseDown:tt.default.func,scale:tt.default.number}),height:tt.default.number.isRequired,handle:tt.default.oneOfType([tt.default.node,tt.default.func]),handleSize:tt.default.arrayOf(tt.default.number),lockAspectRatio:tt.default.bool,maxConstraints:tt.default.arrayOf(tt.default.number),minConstraints:tt.default.arrayOf(tt.default.number),onResizeStop:tt.default.func,onResizeStart:tt.default.func,onResize:tt.default.func,resizeHandles:tt.default.arrayOf(tt.default.oneOf(["s","w","e","n","sw","nw","se","ne"])),transformScale:tt.default.number,width:tt.default.number.isRequired};Lh.resizableProps=ofe,Nh.__esModule=!0,Nh.default=void 0;var Eh=ffe(pe.default),sfe=Ah.exports,lfe=Dw,ufe=Lh,cfe=["children","className","draggableOpts","width","height","handle","handleSize","lockAspectRatio","axis","minConstraints","maxConstraints","onResize","onResizeStop","onResizeStart","resizeHandles","transformScale"];function J3(r){if(typeof WeakMap!="function")return null;var e=new WeakMap,t=new WeakMap;return(J3=function(a){return a?t:e})(r)}function ffe(r,e){if(!e&&r&&r.__esModule)return r;if(r===null||typeof r!="object"&&typeof r!="function")return{default:r};var t=J3(e);if(t&&t.has(r))return t.get(r);var n={},a=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in r)if(i!=="default"&&Object.prototype.hasOwnProperty.call(r,i)){var o=a?Object.getOwnPropertyDescriptor(r,i):null;o&&(o.get||o.set)?Object.defineProperty(n,i,o):n[i]=r[i]}return n.default=r,t&&t.set(r,n),n}function Sw(){return Sw=Object.assign||function(r){for(var e=1;e<arguments.length;e++){var t=arguments[e];for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(r[n]=t[n])}return r},Sw.apply(this,arguments)}function hfe(r,e){if(r==null)return{};var t={},n=Object.keys(r),a,i;for(i=0;i<n.length;i++)a=n[i],!(e.indexOf(a)>=0)&&(t[a]=r[a]);return t}function K3(r,e){var t=Object.keys(r);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(r);e&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(r,a).enumerable})),t.push.apply(t,n)}return t}function Iw(r){for(var e=1;e<arguments.length;e++){var t=arguments[e]!=null?arguments[e]:{};e%2?K3(Object(t),!0).forEach(function(n){vfe(r,n,t[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(t)):K3(Object(t)).forEach(function(n){Object.defineProperty(r,n,Object.getOwnPropertyDescriptor(t,n))})}return r}function vfe(r,e,t){return e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}function dfe(r,e){r.prototype=Object.create(e.prototype),r.prototype.constructor=r,Tw(r,e)}function Tw(r,e){return Tw=Object.setPrototypeOf||function(n,a){return n.__proto__=a,n},Tw(r,e)}var Aw=function(r){dfe(e,r);function e(){for(var n,a=arguments.length,i=new Array(a),o=0;o<a;o++)i[o]=arguments[o];return n=r.call.apply(r,[this].concat(i))||this,n.handleRefs={},n.lastHandleRect=null,n.slack=null,n}var t=e.prototype;return t.componentWillUnmount=function(){this.resetData()},t.resetData=function(){this.lastHandleRect=this.slack=null},t.runConstraints=function(a,i){var o=this.props,s=o.minConstraints,l=o.maxConstraints,u=o.lockAspectRatio;if(!s&&!l&&!u)return[a,i];if(u){var c=this.props.width/this.props.height,f=a-this.props.width,h=i-this.props.height;Math.abs(f)>Math.abs(h*c)?i=a/c:a=i*c}var v=a,d=i,p=this.slack||[0,0],g=p[0],y=p[1];return a+=g,i+=y,s&&(a=Math.max(s[0],a),i=Math.max(s[1],i)),l&&(a=Math.min(l[0],a),i=Math.min(l[1],i)),this.slack=[g+(v-a),y+(d-i)],[a,i]},t.resizeHandler=function(a,i){var o=this;return function(s,l){var u=l.node,c=l.deltaX,f=l.deltaY;a==="onResizeStart"&&o.resetData();var h=(o.props.axis==="both"||o.props.axis==="x")&&i!=="n"&&i!=="s",v=(o.props.axis==="both"||o.props.axis==="y")&&i!=="e"&&i!=="w";if(!(!h&&!v)){var d=i[0],p=i[i.length-1],g=u.getBoundingClientRect();if(o.lastHandleRect!=null){if(p==="w"){var y=g.left-o.lastHandleRect.left;c+=y}if(d==="n"){var m=g.top-o.lastHandleRect.top;f+=m}}o.lastHandleRect=g,p==="w"&&(c=-c),d==="n"&&(f=-f);var _=o.props.width+(h?c/o.props.transformScale:0),b=o.props.height+(v?f/o.props.transformScale:0),x=o.runConstraints(_,b);_=x[0],b=x[1];var M=_!==o.props.width||b!==o.props.height,w=typeof o.props[a]=="function"?o.props[a]:null,D=a==="onResize"&&!M;w&&!D&&(s.persist==null||s.persist(),w(s,{node:u,size:{width:_,height:b},handle:i})),a==="onResizeStop"&&o.resetData()}}},t.renderResizeHandle=function(a,i){var o=this.props.handle;if(!o)return Eh.createElement("span",{className:"react-resizable-handle react-resizable-handle-"+a,ref:i});if(typeof o=="function")return o(a,i);var s=typeof o.type=="string",l=Iw({ref:i},s?{}:{handleAxis:a});return Eh.cloneElement(o,l)},t.render=function(){var a=this,i=this.props,o=i.children,s=i.className,l=i.draggableOpts;i.width,i.height,i.handle,i.handleSize,i.lockAspectRatio,i.axis,i.minConstraints,i.maxConstraints,i.onResize,i.onResizeStop,i.onResizeStart;var u=i.resizeHandles;i.transformScale;var c=hfe(i,cfe);return(0,lfe.cloneElement)(o,Iw(Iw({},c),{},{className:(s?s+" ":"")+"react-resizable",children:[].concat(o.props.children,u.map(function(f){var h,v=(h=a.handleRefs[f])!=null?h:a.handleRefs[f]=Eh.createRef();return Eh.createElement(sfe.DraggableCore,Sw({},l,{nodeRef:v,key:"resizableHandle-"+f,onStop:a.resizeHandler("onResizeStop",f),onStart:a.resizeHandler("onResizeStart",f),onDrag:a.resizeHandler("onResize",f)}),a.renderResizeHandle(f,v))}))}))},e}(Eh.Component);Nh.default=Aw,Aw.propTypes=ufe.resizableProps,Aw.defaultProps={axis:"both",handleSize:[20,20],lockAspectRatio:!1,minConstraints:[20,20],maxConstraints:[1/0,1/0],resizeHandles:["se"],transformScale:1};var Jg={};Jg.__esModule=!0,Jg.default=void 0;var Cw=_fe(pe.default),pfe=ej(zi.exports),gfe=ej(Nh),yfe=Lh,mfe=["handle","handleSize","onResize","onResizeStart","onResizeStop","draggableOpts","minConstraints","maxConstraints","lockAspectRatio","axis","width","height","resizeHandles","style","transformScale"];function ej(r){return r&&r.__esModule?r:{default:r}}function tj(r){if(typeof WeakMap!="function")return null;var e=new WeakMap,t=new WeakMap;return(tj=function(a){return a?t:e})(r)}function _fe(r,e){if(!e&&r&&r.__esModule)return r;if(r===null||typeof r!="object"&&typeof r!="function")return{default:r};var t=tj(e);if(t&&t.has(r))return t.get(r);var n={},a=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in r)if(i!=="default"&&Object.prototype.hasOwnProperty.call(r,i)){var o=a?Object.getOwnPropertyDescriptor(r,i):null;o&&(o.get||o.set)?Object.defineProperty(n,i,o):n[i]=r[i]}return n.default=r,t&&t.set(r,n),n}function Nw(){return Nw=Object.assign||function(r){for(var e=1;e<arguments.length;e++){var t=arguments[e];for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(r[n]=t[n])}return r},Nw.apply(this,arguments)}function rj(r,e){var t=Object.keys(r);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(r);e&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(r,a).enumerable})),t.push.apply(t,n)}return t}function Kg(r){for(var e=1;e<arguments.length;e++){var t=arguments[e]!=null?arguments[e]:{};e%2?rj(Object(t),!0).forEach(function(n){bfe(r,n,t[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(t)):rj(Object(t)).forEach(function(n){Object.defineProperty(r,n,Object.getOwnPropertyDescriptor(t,n))})}return r}function bfe(r,e,t){return e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}function Mfe(r,e){if(r==null)return{};var t={},n=Object.keys(r),a,i;for(i=0;i<n.length;i++)a=n[i],!(e.indexOf(a)>=0)&&(t[a]=r[a]);return t}function xfe(r,e){r.prototype=Object.create(e.prototype),r.prototype.constructor=r,Lw(r,e)}function Lw(r,e){return Lw=Object.setPrototypeOf||function(n,a){return n.__proto__=a,n},Lw(r,e)}var nj=function(r){xfe(e,r);function e(){for(var n,a=arguments.length,i=new Array(a),o=0;o<a;o++)i[o]=arguments[o];return n=r.call.apply(r,[this].concat(i))||this,n.state={width:n.props.width,height:n.props.height,propsWidth:n.props.width,propsHeight:n.props.height},n.onResize=function(s,l){var u=l.size;n.props.onResize?(s.persist==null||s.persist(),n.setState(u,function(){return n.props.onResize&&n.props.onResize(s,l)})):n.setState(u)},n}e.getDerivedStateFromProps=function(a,i){return i.propsWidth!==a.width||i.propsHeight!==a.height?{width:a.width,height:a.height,propsWidth:a.width,propsHeight:a.height}:null};var t=e.prototype;return t.render=function(){var a=this.props,i=a.handle,o=a.handleSize;a.onResize;var s=a.onResizeStart,l=a.onResizeStop,u=a.draggableOpts,c=a.minConstraints,f=a.maxConstraints,h=a.lockAspectRatio,v=a.axis;a.width,a.height;var d=a.resizeHandles,p=a.style,g=a.transformScale,y=Mfe(a,mfe);return Cw.createElement(gfe.default,{axis:v,draggableOpts:u,handle:i,handleSize:o,height:this.state.height,lockAspectRatio:h,maxConstraints:f,minConstraints:c,onResizeStart:s,onResize:this.onResize,onResizeStop:l,resizeHandles:d,transformScale:g,width:this.state.width},Cw.createElement("div",Nw({},y,{style:Kg(Kg({},p),{},{width:this.state.width+"px",height:this.state.height+"px"})})))},e}(Cw.Component);Jg.default=nj,nj.propTypes=Kg(Kg({},yfe.resizableProps),{},{children:pfe.default.element}),Xg.exports=function(){throw new Error("Don't instantiate Resizable directly! Use require('react-resizable').Resizable")},Xg.exports.Resizable=Nh.default,Xg.exports.ResizableBox=Jg.default;var ki={};Object.defineProperty(ki,"__esModule",{value:!0}),ki.resizeHandleType=ki.resizeHandleAxesType=ki.default=void 0;var qe=aj(zi.exports),wfe=aj(pe.default);function aj(r){return r&&r.__esModule?r:{default:r}}var ij=qe.default.arrayOf(qe.default.oneOf(["s","w","e","n","sw","nw","se","ne"]));ki.resizeHandleAxesType=ij;var oj=qe.default.oneOfType([qe.default.node,qe.default.func]);ki.resizeHandleType=oj;var Dfe={className:qe.default.string,style:qe.default.object,width:qe.default.number,autoSize:qe.default.bool,cols:qe.default.number,draggableCancel:qe.default.string,draggableHandle:qe.default.string,verticalCompact:function(e){e.verticalCompact},compactType:qe.default.oneOf(["vertical","horizontal"]),layout:function(e){var t=e.layout;t!==void 0&&et.validateLayout(t,"layout")},margin:qe.default.arrayOf(qe.default.number),containerPadding:qe.default.arrayOf(qe.default.number),rowHeight:qe.default.number,maxRows:qe.default.number,isBounded:qe.default.bool,isDraggable:qe.default.bool,isResizable:qe.default.bool,allowOverlap:qe.default.bool,preventCollision:qe.default.bool,useCSSTransforms:qe.default.bool,transformScale:qe.default.number,isDroppable:qe.default.bool,resizeHandles:ij,resizeHandle:oj,onLayoutChange:qe.default.func,onDragStart:qe.default.func,onDrag:qe.default.func,onDragStop:qe.default.func,onResizeStart:qe.default.func,onResize:qe.default.func,onResizeStop:qe.default.func,onDrop:qe.default.func,droppingItem:qe.default.shape({i:qe.default.string.isRequired,w:qe.default.number.isRequired,h:qe.default.number.isRequired}),children:function(e,t){var n=e[t],a={};wfe.default.Children.forEach(n,function(i){if((i==null?void 0:i.key)!=null){if(a[i.key])throw new Error('Duplicate child key "'+i.key+'" found! This will cause problems in ReactGridLayout.');a[i.key]=!0}})},innerRef:qe.default.any};ki.default=Dfe;function Ew(r){return Ew=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Ew(r)}Object.defineProperty(Gg,"__esModule",{value:!0}),Gg.default=void 0;var Zu=Ow(pe.default),vt=Ow(zi.exports),Sfe=Ah.exports,Ife=Xg.exports,Oh=et,Ir=Pi,sj=ki,Tfe=Ow(Vg);function Ow(r){return r&&r.__esModule?r:{default:r}}function lj(r,e){var t=Object.keys(r);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(r);e&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(r,a).enumerable})),t.push.apply(t,n)}return t}function Pw(r){for(var e=1;e<arguments.length;e++){var t=arguments[e]!=null?arguments[e]:{};e%2?lj(Object(t),!0).forEach(function(n){Ta(r,n,t[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(t)):lj(Object(t)).forEach(function(n){Object.defineProperty(r,n,Object.getOwnPropertyDescriptor(t,n))})}return r}function Afe(r,e){if(!(r instanceof e))throw new TypeError("Cannot call a class as a function")}function uj(r,e){for(var t=0;t<e.length;t++){var n=e[t];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(r,n.key,n)}}function Cfe(r,e,t){return e&&uj(r.prototype,e),t&&uj(r,t),Object.defineProperty(r,"prototype",{writable:!1}),r}function Nfe(r,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");r.prototype=Object.create(e&&e.prototype,{constructor:{value:r,writable:!0,configurable:!0}}),Object.defineProperty(r,"prototype",{writable:!1}),e&&zw(r,e)}function zw(r,e){return zw=Object.setPrototypeOf||function(n,a){return n.__proto__=a,n},zw(r,e)}function Lfe(r){var e=Ofe();return function(){var n=ey(r),a;if(e){var i=ey(this).constructor;a=Reflect.construct(n,arguments,i)}else a=n.apply(this,arguments);return Efe(this,a)}}function Efe(r,e){if(e&&(Ew(e)==="object"||typeof e=="function"))return e;if(e!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return ra(r)}function ra(r){if(r===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return r}function Ofe(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function ey(r){return ey=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},ey(r)}function Ta(r,e,t){return e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}var kw=function(r){Nfe(t,r);var e=Lfe(t);function t(){var n;Afe(this,t);for(var a=arguments.length,i=new Array(a),o=0;o<a;o++)i[o]=arguments[o];return n=e.call.apply(e,[this].concat(i)),Ta(ra(n),"state",{resizing:null,dragging:null,className:""}),Ta(ra(n),"elementRef",Zu.default.createRef()),Ta(ra(n),"onDragStart",function(s,l){var u=l.node,c=n.props,f=c.onDragStart,h=c.transformScale;if(!!f){var v={top:0,left:0},d=u.offsetParent;if(!!d){var p=d.getBoundingClientRect(),g=u.getBoundingClientRect(),y=g.left/h,m=p.left/h,_=g.top/h,b=p.top/h;v.left=y-m+d.scrollLeft,v.top=_-b+d.scrollTop,n.setState({dragging:v});var x=(0,Ir.calcXY)(n.getPositionParams(),v.top,v.left,n.props.w,n.props.h),M=x.x,w=x.y;return f.call(ra(n),n.props.i,M,w,{e:s,node:u,newPosition:v})}}}),Ta(ra(n),"onDrag",function(s,l){var u=l.node,c=l.deltaX,f=l.deltaY,h=n.props.onDrag;if(!!h){if(!n.state.dragging)throw new Error("onDrag called before onDragStart.");var v=n.state.dragging.top+f,d=n.state.dragging.left+c,p=n.props,g=p.isBounded,y=p.i,m=p.w,_=p.h,b=p.containerWidth,x=n.getPositionParams();if(g){var M=u.offsetParent;if(M){var w=n.props,D=w.margin,T=w.rowHeight,I=M.clientHeight-(0,Ir.calcGridItemWHPx)(_,T,D[1]);v=(0,Ir.clamp)(v,0,I);var A=(0,Ir.calcGridColWidth)(x),N=b-(0,Ir.calcGridItemWHPx)(m,A,D[0]);d=(0,Ir.clamp)(d,0,N)}}var L={top:v,left:d};n.setState({dragging:L});var E=(0,Ir.calcXY)(x,v,d,m,_),O=E.x,P=E.y;return h.call(ra(n),y,O,P,{e:s,node:u,newPosition:L})}}),Ta(ra(n),"onDragStop",function(s,l){var u=l.node,c=n.props.onDragStop;if(!!c){if(!n.state.dragging)throw new Error("onDragEnd called before onDragStart.");var f=n.props,h=f.w,v=f.h,d=f.i,p=n.state.dragging,g=p.left,y=p.top,m={top:y,left:g};n.setState({dragging:null});var _=(0,Ir.calcXY)(n.getPositionParams(),y,g,h,v),b=_.x,x=_.y;return c.call(ra(n),d,b,x,{e:s,node:u,newPosition:m})}}),Ta(ra(n),"onResizeStop",function(s,l){n.onResizeHandler(s,l,"onResizeStop")}),Ta(ra(n),"onResizeStart",function(s,l){n.onResizeHandler(s,l,"onResizeStart")}),Ta(ra(n),"onResize",function(s,l){n.onResizeHandler(s,l,"onResize")}),n}return Cfe(t,[{key:"shouldComponentUpdate",value:function(a,i){if(this.props.children!==a.children||this.props.droppingPosition!==a.droppingPosition)return!0;var o=(0,Ir.calcGridItemPosition)(this.getPositionParams(this.props),this.props.x,this.props.y,this.props.w,this.props.h,this.state),s=(0,Ir.calcGridItemPosition)(this.getPositionParams(a),a.x,a.y,a.w,a.h,i);return!(0,Oh.fastPositionEqual)(o,s)||this.props.useCSSTransforms!==a.useCSSTransforms}},{key:"componentDidMount",value:function(){this.moveDroppingItem({})}},{key:"componentDidUpdate",value:function(a){this.moveDroppingItem(a)}},{key:"moveDroppingItem",value:function(a){var i=this.props.droppingPosition;if(!!i){var o=this.elementRef.current;if(!!o){var s=a.droppingPosition||{left:0,top:0},l=this.state.dragging,u=l&&i.left!==s.left||i.top!==s.top;if(!l)this.onDragStart(i.e,{node:o,deltaX:i.left,deltaY:i.top});else if(u){var c=i.left-l.left,f=i.top-l.top;this.onDrag(i.e,{node:o,deltaX:c,deltaY:f})}}}}},{key:"getPositionParams",value:function(){var a=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.props;return{cols:a.cols,containerPadding:a.containerPadding,containerWidth:a.containerWidth,margin:a.margin,maxRows:a.maxRows,rowHeight:a.rowHeight}}},{key:"createStyle",value:function(a){var i=this.props,o=i.usePercentages,s=i.containerWidth,l=i.useCSSTransforms,u;return l?u=(0,Oh.setTransform)(a):(u=(0,Oh.setTopLeft)(a),o&&(u.left=(0,Oh.perc)(a.left/s),u.width=(0,Oh.perc)(a.width/s))),u}},{key:"mixinDraggable",value:function(a,i){return Zu.default.createElement(Sfe.DraggableCore,{disabled:!i,onStart:this.onDragStart,onDrag:this.onDrag,onStop:this.onDragStop,handle:this.props.handle,cancel:".react-resizable-handle"+(this.props.cancel?","+this.props.cancel:""),scale:this.props.transformScale,nodeRef:this.elementRef},a)}},{key:"mixinResizable",value:function(a,i,o){var s=this.props,l=s.cols,u=s.x,c=s.minW,f=s.minH,h=s.maxW,v=s.maxH,d=s.transformScale,p=s.resizeHandles,g=s.resizeHandle,y=this.getPositionParams(),m=(0,Ir.calcGridItemPosition)(y,0,0,l-u,0).width,_=(0,Ir.calcGridItemPosition)(y,0,0,c,f),b=(0,Ir.calcGridItemPosition)(y,0,0,h,v),x=[_.width,_.height],M=[Math.min(b.width,m),Math.min(b.height,1/0)];return Zu.default.createElement(Ife.Resizable,{draggableOpts:{disabled:!o},className:o?void 0:"react-resizable-hide",width:i.width,height:i.height,minConstraints:x,maxConstraints:M,onResizeStop:this.onResizeStop,onResizeStart:this.onResizeStart,onResize:this.onResize,transformScale:d,resizeHandles:p,handle:g},a)}},{key:"onResizeHandler",value:function(a,i,o){var s=i.node,l=i.size,u=this.props[o];if(!!u){var c=this.props,f=c.cols,h=c.x,v=c.y,d=c.i,p=c.maxH,g=c.minH,y=this.props,m=y.minW,_=y.maxW,b=(0,Ir.calcWH)(this.getPositionParams(),l.width,l.height,h,v),x=b.w,M=b.h;m=Math.max(m,1),_=Math.min(_,f-h),x=(0,Ir.clamp)(x,m,_),M=(0,Ir.clamp)(M,g,p),this.setState({resizing:o==="onResizeStop"?null:l}),u.call(this,d,x,M,{e:a,node:s,size:l})}}},{key:"render",value:function(){var a=this.props,i=a.x,o=a.y,s=a.w,l=a.h,u=a.isDraggable,c=a.isResizable,f=a.droppingPosition,h=a.useCSSTransforms,v=(0,Ir.calcGridItemPosition)(this.getPositionParams(),i,o,s,l,this.state),d=Zu.default.Children.only(this.props.children),p=Zu.default.cloneElement(d,{ref:this.elementRef,className:(0,Tfe.default)("react-grid-item",d.props.className,this.props.className,{static:this.props.static,resizing:Boolean(this.state.resizing),"react-draggable":u,"react-draggable-dragging":Boolean(this.state.dragging),dropping:Boolean(f),cssTransforms:h}),style:Pw(Pw(Pw({},this.props.style),d.props.style),this.createStyle(v))});return p=this.mixinResizable(p,v,c),p=this.mixinDraggable(p,u),p}}]),t}(Zu.default.Component);Gg.default=kw,Ta(kw,"propTypes",{children:vt.default.element,cols:vt.default.number.isRequired,containerWidth:vt.default.number.isRequired,rowHeight:vt.default.number.isRequired,margin:vt.default.array.isRequired,maxRows:vt.default.number.isRequired,containerPadding:vt.default.array.isRequired,x:vt.default.number.isRequired,y:vt.default.number.isRequired,w:vt.default.number.isRequired,h:vt.default.number.isRequired,minW:function(e,t){var n=e[t];if(typeof n!="number")return new Error("minWidth not Number");if(n>e.w||n>e.maxW)return new Error("minWidth larger than item width/maxWidth")},maxW:function(e,t){var n=e[t];if(typeof n!="number")return new Error("maxWidth not Number");if(n<e.w||n<e.minW)return new Error("maxWidth smaller than item width/minWidth")},minH:function(e,t){var n=e[t];if(typeof n!="number")return new Error("minHeight not Number");if(n>e.h||n>e.maxH)return new Error("minHeight larger than item height/maxHeight")},maxH:function(e,t){var n=e[t];if(typeof n!="number")return new Error("maxHeight not Number");if(n<e.h||n<e.minH)return new Error("maxHeight smaller than item height/minHeight")},i:vt.default.string.isRequired,resizeHandles:sj.resizeHandleAxesType,resizeHandle:sj.resizeHandleType,onDragStop:vt.default.func,onDragStart:vt.default.func,onDrag:vt.default.func,onResizeStop:vt.default.func,onResizeStart:vt.default.func,onResize:vt.default.func,isDraggable:vt.default.bool.isRequired,isResizable:vt.default.bool.isRequired,isBounded:vt.default.bool.isRequired,static:vt.default.bool,useCSSTransforms:vt.default.bool.isRequired,transformScale:vt.default.number,className:vt.default.string,handle:vt.default.string,cancel:vt.default.string,droppingPosition:vt.default.shape({e:vt.default.object.isRequired,left:vt.default.number.isRequired,top:vt.default.number.isRequired})}),Ta(kw,"defaultProps",{className:"",cancel:"",handle:"",minH:1,minW:1,maxH:1/0,maxW:1/0,transformScale:1});function ty(r){return ty=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},ty(r)}Object.defineProperty(Sh,"__esModule",{value:!0}),Sh.default=void 0;var cl=Rfe(pe.default),Rw=ry(Ih.exports),Pfe=ry(Vg),Ve=et,zfe=Pi,cj=ry(Gg),kfe=ry(ki);function ry(r){return r&&r.__esModule?r:{default:r}}function fj(r){if(typeof WeakMap!="function")return null;var e=new WeakMap,t=new WeakMap;return(fj=function(a){return a?t:e})(r)}function Rfe(r,e){if(!e&&r&&r.__esModule)return r;if(r===null||ty(r)!=="object"&&typeof r!="function")return{default:r};var t=fj(e);if(t&&t.has(r))return t.get(r);var n={},a=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in r)if(i!=="default"&&Object.prototype.hasOwnProperty.call(r,i)){var o=a?Object.getOwnPropertyDescriptor(r,i):null;o&&(o.get||o.set)?Object.defineProperty(n,i,o):n[i]=r[i]}return n.default=r,t&&t.set(r,n),n}function jfe(r){return Vfe(r)||Ffe(r)||vj(r)||Bfe()}function Bfe(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
339
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Ffe(r){if(typeof Symbol!="undefined"&&r[Symbol.iterator]!=null||r["@@iterator"]!=null)return Array.from(r)}function Vfe(r){if(Array.isArray(r))return jw(r)}function hj(r,e){var t=Object.keys(r);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(r);e&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(r,a).enumerable})),t.push.apply(t,n)}return t}function fl(r){for(var e=1;e<arguments.length;e++){var t=arguments[e]!=null?arguments[e]:{};e%2?hj(Object(t),!0).forEach(function(n){Tr(r,n,t[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(t)):hj(Object(t)).forEach(function(n){Object.defineProperty(r,n,Object.getOwnPropertyDescriptor(t,n))})}return r}function Hfe(r,e){return $fe(r)||Gfe(r,e)||vj(r,e)||Wfe()}function Wfe(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
340
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function vj(r,e){if(!!r){if(typeof r=="string")return jw(r,e);var t=Object.prototype.toString.call(r).slice(8,-1);if(t==="Object"&&r.constructor&&(t=r.constructor.name),t==="Map"||t==="Set")return Array.from(r);if(t==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return jw(r,e)}}function jw(r,e){(e==null||e>r.length)&&(e=r.length);for(var t=0,n=new Array(e);t<e;t++)n[t]=r[t];return n}function Gfe(r,e){var t=r==null?null:typeof Symbol!="undefined"&&r[Symbol.iterator]||r["@@iterator"];if(t!=null){var n=[],a=!0,i=!1,o,s;try{for(t=t.call(r);!(a=(o=t.next()).done)&&(n.push(o.value),!(e&&n.length===e));a=!0);}catch(l){i=!0,s=l}finally{try{!a&&t.return!=null&&t.return()}finally{if(i)throw s}}return n}}function $fe(r){if(Array.isArray(r))return r}function Ufe(r,e){if(!(r instanceof e))throw new TypeError("Cannot call a class as a function")}function dj(r,e){for(var t=0;t<e.length;t++){var n=e[t];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(r,n.key,n)}}function Yfe(r,e,t){return e&&dj(r.prototype,e),t&&dj(r,t),Object.defineProperty(r,"prototype",{writable:!1}),r}function Qfe(r,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");r.prototype=Object.create(e&&e.prototype,{constructor:{value:r,writable:!0,configurable:!0}}),Object.defineProperty(r,"prototype",{writable:!1}),e&&Bw(r,e)}function Bw(r,e){return Bw=Object.setPrototypeOf||function(n,a){return n.__proto__=a,n},Bw(r,e)}function Zfe(r){var e=Xfe();return function(){var n=ny(r),a;if(e){var i=ny(this).constructor;a=Reflect.construct(n,arguments,i)}else a=n.apply(this,arguments);return qfe(this,a)}}function qfe(r,e){if(e&&(ty(e)==="object"||typeof e=="function"))return e;if(e!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return hn(r)}function hn(r){if(r===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return r}function Xfe(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function ny(r){return ny=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},ny(r)}function Tr(r,e,t){return e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}var pj="react-grid-layout",gj=!1;try{gj=/firefox/i.test(navigator.userAgent)}catch{}var ay=function(r){Qfe(t,r);var e=Zfe(t);function t(){var n;Ufe(this,t);for(var a=arguments.length,i=new Array(a),o=0;o<a;o++)i[o]=arguments[o];return n=e.call.apply(e,[this].concat(i)),Tr(hn(n),"state",{activeDrag:null,layout:(0,Ve.synchronizeLayoutWithChildren)(n.props.layout,n.props.children,n.props.cols,(0,Ve.compactType)(n.props),n.props.allowOverlap),mounted:!1,oldDragItem:null,oldLayout:null,oldResizeItem:null,droppingDOMNode:null,children:[]}),Tr(hn(n),"dragEnterCounter",0),Tr(hn(n),"onDragStart",function(s,l,u,c){var f=c.e,h=c.node,v=n.state.layout,d=(0,Ve.getLayoutItem)(v,s);if(!!d)return n.setState({oldDragItem:(0,Ve.cloneLayoutItem)(d),oldLayout:v}),n.props.onDragStart(v,d,d,null,f,h)}),Tr(hn(n),"onDrag",function(s,l,u,c){var f=c.e,h=c.node,v=n.state.oldDragItem,d=n.state.layout,p=n.props,g=p.cols,y=p.allowOverlap,m=p.preventCollision,_=(0,Ve.getLayoutItem)(d,s);if(!!_){var b={w:_.w,h:_.h,x:_.x,y:_.y,placeholder:!0,i:s},x=!0;d=(0,Ve.moveElement)(d,_,l,u,x,m,(0,Ve.compactType)(n.props),g,y),n.props.onDrag(d,v,_,b,f,h),n.setState({layout:y?d:(0,Ve.compact)(d,(0,Ve.compactType)(n.props),g),activeDrag:b})}}),Tr(hn(n),"onDragStop",function(s,l,u,c){var f=c.e,h=c.node;if(!!n.state.activeDrag){var v=n.state.oldDragItem,d=n.state.layout,p=n.props,g=p.cols,y=p.preventCollision,m=p.allowOverlap,_=(0,Ve.getLayoutItem)(d,s);if(!!_){var b=!0;d=(0,Ve.moveElement)(d,_,l,u,b,y,(0,Ve.compactType)(n.props),g,m),n.props.onDragStop(d,v,_,null,f,h);var x=m?d:(0,Ve.compact)(d,(0,Ve.compactType)(n.props),g),M=n.state.oldLayout;n.setState({activeDrag:null,layout:x,oldDragItem:null,oldLayout:null}),n.onLayoutMaybeChanged(x,M)}}}),Tr(hn(n),"onResizeStart",function(s,l,u,c){var f=c.e,h=c.node,v=n.state.layout,d=(0,Ve.getLayoutItem)(v,s);!d||(n.setState({oldResizeItem:(0,Ve.cloneLayoutItem)(d),oldLayout:n.state.layout}),n.props.onResizeStart(v,d,d,null,f,h))}),Tr(hn(n),"onResize",function(s,l,u,c){var f=c.e,h=c.node,v=n.state,d=v.layout,p=v.oldResizeItem,g=n.props,y=g.cols,m=g.preventCollision,_=g.allowOverlap,b=(0,Ve.withLayoutItem)(d,s,function(T){var I;if(m&&!_){var A=(0,Ve.getAllCollisions)(d,fl(fl({},T),{},{w:l,h:u})).filter(function(E){return E.i!==T.i});if(I=A.length>0,I){var N=1/0,L=1/0;A.forEach(function(E){E.x>T.x&&(N=Math.min(N,E.x)),E.y>T.y&&(L=Math.min(L,E.y))}),Number.isFinite(N)&&(T.w=N-T.x),Number.isFinite(L)&&(T.h=L-T.y)}}return I||(T.w=l,T.h=u),T}),x=Hfe(b,2),M=x[0],w=x[1];if(!!w){var D={w:w.w,h:w.h,x:w.x,y:w.y,static:!0,i:s};n.props.onResize(M,p,w,D,f,h),n.setState({layout:_?M:(0,Ve.compact)(M,(0,Ve.compactType)(n.props),y),activeDrag:D})}}),Tr(hn(n),"onResizeStop",function(s,l,u,c){var f=c.e,h=c.node,v=n.state,d=v.layout,p=v.oldResizeItem,g=n.props,y=g.cols,m=g.allowOverlap,_=(0,Ve.getLayoutItem)(d,s);n.props.onResizeStop(d,p,_,null,f,h);var b=m?d:(0,Ve.compact)(d,(0,Ve.compactType)(n.props),y),x=n.state.oldLayout;n.setState({activeDrag:null,layout:b,oldResizeItem:null,oldLayout:null}),n.onLayoutMaybeChanged(b,x)}),Tr(hn(n),"onDragOver",function(s){var l;if(s.preventDefault(),s.stopPropagation(),gj&&!((l=s.nativeEvent.target)!==null&&l!==void 0&&l.classList.contains(pj)))return!1;var u=n.props,c=u.droppingItem,f=u.onDropDragOver,h=u.margin,v=u.cols,d=u.rowHeight,p=u.maxRows,g=u.width,y=u.containerPadding,m=u.transformScale,_=f==null?void 0:f(s);if(_===!1)return n.state.droppingDOMNode&&n.removeDroppingPlaceholder(),!1;var b=fl(fl({},c),_),x=n.state.layout,M=s.nativeEvent,w=M.layerX,D=M.layerY,T={left:w/m,top:D/m,e:s};if(n.state.droppingDOMNode){if(n.state.droppingPosition){var N=n.state.droppingPosition,L=N.left,E=N.top,O=L!=w||E!=D;O&&n.setState({droppingPosition:T})}}else{var I={cols:v,margin:h,maxRows:p,rowHeight:d,containerWidth:g,containerPadding:y||h},A=(0,zfe.calcXY)(I,D,w,b.w,b.h);n.setState({droppingDOMNode:cl.createElement("div",{key:b.i}),droppingPosition:T,layout:[].concat(jfe(x),[fl(fl({},b),{},{x:A.x,y:A.y,static:!1,isDraggable:!0})])})}}),Tr(hn(n),"removeDroppingPlaceholder",function(){var s=n.props,l=s.droppingItem,u=s.cols,c=n.state.layout,f=(0,Ve.compact)(c.filter(function(h){return h.i!==l.i}),(0,Ve.compactType)(n.props),u);n.setState({layout:f,droppingDOMNode:null,activeDrag:null,droppingPosition:void 0})}),Tr(hn(n),"onDragLeave",function(s){s.preventDefault(),s.stopPropagation(),n.dragEnterCounter--,n.dragEnterCounter===0&&n.removeDroppingPlaceholder()}),Tr(hn(n),"onDragEnter",function(s){s.preventDefault(),s.stopPropagation(),n.dragEnterCounter++}),Tr(hn(n),"onDrop",function(s){s.preventDefault(),s.stopPropagation();var l=n.props.droppingItem,u=n.state.layout,c=u.find(function(f){return f.i===l.i});n.dragEnterCounter=0,n.removeDroppingPlaceholder(),n.props.onDrop(u,c,s)}),n}return Yfe(t,[{key:"componentDidMount",value:function(){this.setState({mounted:!0}),this.onLayoutMaybeChanged(this.state.layout,this.props.layout)}},{key:"shouldComponentUpdate",value:function(a,i){return this.props.children!==a.children||!(0,Ve.fastRGLPropsEqual)(this.props,a,Rw.default)||this.state.activeDrag!==i.activeDrag||this.state.mounted!==i.mounted||this.state.droppingPosition!==i.droppingPosition}},{key:"componentDidUpdate",value:function(a,i){if(!this.state.activeDrag){var o=this.state.layout,s=i.layout;this.onLayoutMaybeChanged(o,s)}}},{key:"containerHeight",value:function(){if(!!this.props.autoSize){var a=(0,Ve.bottom)(this.state.layout),i=this.props.containerPadding?this.props.containerPadding[1]:this.props.margin[1];return a*this.props.rowHeight+(a-1)*this.props.margin[1]+i*2+"px"}}},{key:"onLayoutMaybeChanged",value:function(a,i){i||(i=this.state.layout),(0,Rw.default)(i,a)||this.props.onLayoutChange(a)}},{key:"placeholder",value:function(){var a=this.state.activeDrag;if(!a)return null;var i=this.props,o=i.width,s=i.cols,l=i.margin,u=i.containerPadding,c=i.rowHeight,f=i.maxRows,h=i.useCSSTransforms,v=i.transformScale;return cl.createElement(cj.default,{w:a.w,h:a.h,x:a.x,y:a.y,i:a.i,className:"react-grid-placeholder",containerWidth:o,cols:s,margin:l,containerPadding:u||l,maxRows:f,rowHeight:c,isDraggable:!1,isResizable:!1,isBounded:!1,useCSSTransforms:h,transformScale:v},cl.createElement("div",null))}},{key:"processGridItem",value:function(a,i){if(!(!a||!a.key)){var o=(0,Ve.getLayoutItem)(this.state.layout,String(a.key));if(!o)return null;var s=this.props,l=s.width,u=s.cols,c=s.margin,f=s.containerPadding,h=s.rowHeight,v=s.maxRows,d=s.isDraggable,p=s.isResizable,g=s.isBounded,y=s.useCSSTransforms,m=s.transformScale,_=s.draggableCancel,b=s.draggableHandle,x=s.resizeHandles,M=s.resizeHandle,w=this.state,D=w.mounted,T=w.droppingPosition,I=typeof o.isDraggable=="boolean"?o.isDraggable:!o.static&&d,A=typeof o.isResizable=="boolean"?o.isResizable:!o.static&&p,N=o.resizeHandles||x,L=I&&g&&o.isBounded!==!1;return cl.createElement(cj.default,{containerWidth:l,cols:u,margin:c,containerPadding:f||c,maxRows:v,rowHeight:h,cancel:_,handle:b,onDragStop:this.onDragStop,onDragStart:this.onDragStart,onDrag:this.onDrag,onResizeStart:this.onResizeStart,onResize:this.onResize,onResizeStop:this.onResizeStop,isDraggable:I,isResizable:A,isBounded:L,useCSSTransforms:y&&D,usePercentages:!D,transformScale:m,w:o.w,h:o.h,x:o.x,y:o.y,i:o.i,minH:o.minH,minW:o.minW,maxH:o.maxH,maxW:o.maxW,static:o.static,droppingPosition:i?T:void 0,resizeHandles:N,resizeHandle:M},a)}}},{key:"render",value:function(){var a=this,i=this.props,o=i.className,s=i.style,l=i.isDroppable,u=i.innerRef,c=(0,Pfe.default)(pj,o),f=fl({height:this.containerHeight()},s);return cl.createElement("div",{ref:u,className:c,style:f,onDrop:l?this.onDrop:Ve.noop,onDragLeave:l?this.onDragLeave:Ve.noop,onDragEnter:l?this.onDragEnter:Ve.noop,onDragOver:l?this.onDragOver:Ve.noop},cl.Children.map(this.props.children,function(h){return a.processGridItem(h)}),l&&this.state.droppingDOMNode&&this.processGridItem(this.state.droppingDOMNode,!0),this.placeholder())}}],[{key:"getDerivedStateFromProps",value:function(a,i){var o;if(i.activeDrag)return null;if(!(0,Rw.default)(a.layout,i.propsLayout)||a.compactType!==i.compactType?o=a.layout:(0,Ve.childrenEqual)(a.children,i.children)||(o=i.layout),o){var s=(0,Ve.synchronizeLayoutWithChildren)(o,a.children,a.cols,(0,Ve.compactType)(a),a.allowOverlap);return{layout:s,compactType:a.compactType,children:a.children,propsLayout:a.layout}}return null}}]),t}(cl.Component);Sh.default=ay,Tr(ay,"displayName","ReactGridLayout"),Tr(ay,"propTypes",kfe.default),Tr(ay,"defaultProps",{autoSize:!0,cols:12,className:"",style:{},draggableHandle:"",draggableCancel:"",containerPadding:null,rowHeight:150,maxRows:1/0,layout:[],margin:[10,10],isBounded:!1,isDraggable:!0,isResizable:!0,allowOverlap:!1,isDroppable:!1,useCSSTransforms:!0,transformScale:1,verticalCompact:!0,compactType:"vertical",preventCollision:!1,droppingItem:{i:"__dropping-elem__",h:1,w:1},resizeHandles:["se"],onLayoutChange:Ve.noop,onDragStart:Ve.noop,onDrag:Ve.noop,onDragStop:Ve.noop,onResizeStart:Ve.noop,onResize:Ve.noop,onResizeStop:Ve.noop,onDrop:Ve.noop,onDropDragOver:Ve.noop});var iy={},hl={};Object.defineProperty(hl,"__esModule",{value:!0}),hl.findOrGenerateResponsiveLayout=ehe,hl.getBreakpointFromWidth=Jfe,hl.getColsFromBreakpoint=Kfe,hl.sortBreakpoints=Fw;var oy=et;function Jfe(r,e){for(var t=Fw(r),n=t[0],a=1,i=t.length;a<i;a++){var o=t[a];e>r[o]&&(n=o)}return n}function Kfe(r,e){if(!e[r])throw new Error("ResponsiveReactGridLayout: `cols` entry for breakpoint "+r+" is missing!");return e[r]}function ehe(r,e,t,n,a,i){if(r[t])return(0,oy.cloneLayout)(r[t]);for(var o=r[n],s=Fw(e),l=s.slice(s.indexOf(t)),u=0,c=l.length;u<c;u++){var f=l[u];if(r[f]){o=r[f];break}}return o=(0,oy.cloneLayout)(o||[]),(0,oy.compact)((0,oy.correctBounds)(o,{cols:a}),i,a)}function Fw(r){var e=Object.keys(r);return e.sort(function(t,n){return r[t]-r[n]})}function sy(r){return sy=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},sy(r)}Object.defineProperty(iy,"__esModule",{value:!0}),iy.default=void 0;var yj=nhe(pe.default),vn=Hw(zi.exports),Vw=Hw(Ih.exports),qu=et,vl=hl,the=Hw(Sh),rhe=["breakpoint","breakpoints","cols","layouts","margin","containerPadding","onBreakpointChange","onLayoutChange","onWidthChange"];function Hw(r){return r&&r.__esModule?r:{default:r}}function mj(r){if(typeof WeakMap!="function")return null;var e=new WeakMap,t=new WeakMap;return(mj=function(a){return a?t:e})(r)}function nhe(r,e){if(!e&&r&&r.__esModule)return r;if(r===null||sy(r)!=="object"&&typeof r!="function")return{default:r};var t=mj(e);if(t&&t.has(r))return t.get(r);var n={},a=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in r)if(i!=="default"&&Object.prototype.hasOwnProperty.call(r,i)){var o=a?Object.getOwnPropertyDescriptor(r,i):null;o&&(o.get||o.set)?Object.defineProperty(n,i,o):n[i]=r[i]}return n.default=r,t&&t.set(r,n),n}function Ww(){return Ww=Object.assign||function(r){for(var e=1;e<arguments.length;e++){var t=arguments[e];for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(r[n]=t[n])}return r},Ww.apply(this,arguments)}function ahe(r,e){if(r==null)return{};var t=ihe(r,e),n,a;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(r);for(a=0;a<i.length;a++)n=i[a],!(e.indexOf(n)>=0)&&(!Object.prototype.propertyIsEnumerable.call(r,n)||(t[n]=r[n]))}return t}function ihe(r,e){if(r==null)return{};var t={},n=Object.keys(r),a,i;for(i=0;i<n.length;i++)a=n[i],!(e.indexOf(a)>=0)&&(t[a]=r[a]);return t}function _j(r,e){var t=Object.keys(r);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(r);e&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(r,a).enumerable})),t.push.apply(t,n)}return t}function Gw(r){for(var e=1;e<arguments.length;e++){var t=arguments[e]!=null?arguments[e]:{};e%2?_j(Object(t),!0).forEach(function(n){Xu(r,n,t[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(t)):_j(Object(t)).forEach(function(n){Object.defineProperty(r,n,Object.getOwnPropertyDescriptor(t,n))})}return r}function ohe(r,e){if(!(r instanceof e))throw new TypeError("Cannot call a class as a function")}function bj(r,e){for(var t=0;t<e.length;t++){var n=e[t];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(r,n.key,n)}}function she(r,e,t){return e&&bj(r.prototype,e),t&&bj(r,t),Object.defineProperty(r,"prototype",{writable:!1}),r}function lhe(r,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");r.prototype=Object.create(e&&e.prototype,{constructor:{value:r,writable:!0,configurable:!0}}),Object.defineProperty(r,"prototype",{writable:!1}),e&&$w(r,e)}function $w(r,e){return $w=Object.setPrototypeOf||function(n,a){return n.__proto__=a,n},$w(r,e)}function uhe(r){var e=fhe();return function(){var n=ly(r),a;if(e){var i=ly(this).constructor;a=Reflect.construct(n,arguments,i)}else a=n.apply(this,arguments);return che(this,a)}}function che(r,e){if(e&&(sy(e)==="object"||typeof e=="function"))return e;if(e!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Uw(r)}function Uw(r){if(r===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return r}function fhe(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function ly(r){return ly=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},ly(r)}function Xu(r,e,t){return e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}var Mj=function(e){return Object.prototype.toString.call(e)};function uy(r,e){return r==null?null:Array.isArray(r)?r:r[e]}var Yw=function(r){lhe(t,r);var e=uhe(t);function t(){var n;ohe(this,t);for(var a=arguments.length,i=new Array(a),o=0;o<a;o++)i[o]=arguments[o];return n=e.call.apply(e,[this].concat(i)),Xu(Uw(n),"state",n.generateInitialState()),Xu(Uw(n),"onLayoutChange",function(s){n.props.onLayoutChange(s,Gw(Gw({},n.props.layouts),{},Xu({},n.state.breakpoint,s)))}),n}return she(t,[{key:"generateInitialState",value:function(){var a=this.props,i=a.width,o=a.breakpoints,s=a.layouts,l=a.cols,u=(0,vl.getBreakpointFromWidth)(o,i),c=(0,vl.getColsFromBreakpoint)(u,l),f=this.props.verticalCompact===!1?null:this.props.compactType,h=(0,vl.findOrGenerateResponsiveLayout)(s,o,u,u,c,f);return{layout:h,breakpoint:u,cols:c}}},{key:"componentDidUpdate",value:function(a){(this.props.width!=a.width||this.props.breakpoint!==a.breakpoint||!(0,Vw.default)(this.props.breakpoints,a.breakpoints)||!(0,Vw.default)(this.props.cols,a.cols))&&this.onWidthChange(a)}},{key:"onWidthChange",value:function(a){var i=this.props,o=i.breakpoints,s=i.cols,l=i.layouts,u=i.compactType,c=this.props.breakpoint||(0,vl.getBreakpointFromWidth)(this.props.breakpoints,this.props.width),f=this.state.breakpoint,h=(0,vl.getColsFromBreakpoint)(c,s),v=Gw({},l);if(f!==c||a.breakpoints!==o||a.cols!==s){f in v||(v[f]=(0,qu.cloneLayout)(this.state.layout));var d=(0,vl.findOrGenerateResponsiveLayout)(v,o,c,f,h,u);d=(0,qu.synchronizeLayoutWithChildren)(d,this.props.children,h,u,this.props.allowOverlap),v[c]=d,this.props.onLayoutChange(d,v),this.props.onBreakpointChange(c,h),this.setState({breakpoint:c,layout:d,cols:h})}var p=uy(this.props.margin,c),g=uy(this.props.containerPadding,c);this.props.onWidthChange(this.props.width,p,h,g)}},{key:"render",value:function(){var a=this.props;a.breakpoint,a.breakpoints,a.cols,a.layouts;var i=a.margin,o=a.containerPadding;a.onBreakpointChange,a.onLayoutChange,a.onWidthChange;var s=ahe(a,rhe);return yj.createElement(the.default,Ww({},s,{margin:uy(i,this.state.breakpoint),containerPadding:uy(o,this.state.breakpoint),onLayoutChange:this.onLayoutChange,layout:this.state.layout,cols:this.state.cols}))}}],[{key:"getDerivedStateFromProps",value:function(a,i){if(!(0,Vw.default)(a.layouts,i.layouts)){var o=i.breakpoint,s=i.cols,l=(0,vl.findOrGenerateResponsiveLayout)(a.layouts,a.breakpoints,o,o,s,a.compactType);return{layout:l,layouts:a.layouts}}return null}}]),t}(yj.Component);iy.default=Yw,Xu(Yw,"propTypes",{breakpoint:vn.default.string,breakpoints:vn.default.object,allowOverlap:vn.default.bool,cols:vn.default.object,margin:vn.default.oneOfType([vn.default.array,vn.default.object]),containerPadding:vn.default.oneOfType([vn.default.array,vn.default.object]),layouts:function(e,t){if(Mj(e[t])!=="[object Object]")throw new Error("Layout property must be an object. Received: "+Mj(e[t]));Object.keys(e[t]).forEach(function(n){if(!(n in e.breakpoints))throw new Error("Each key in layouts must align with a key in breakpoints.");(0,qu.validateLayout)(e.layouts[n],"layouts."+n)})},width:vn.default.number.isRequired,onBreakpointChange:vn.default.func,onLayoutChange:vn.default.func,onWidthChange:vn.default.func}),Xu(Yw,"defaultProps",{breakpoints:{lg:1200,md:996,sm:768,xs:480,xxs:0},cols:{lg:12,md:10,sm:6,xs:4,xxs:2},containerPadding:{lg:null,md:null,sm:null,xs:null,xxs:null},layouts:{},margin:[10,10],allowOverlap:!1,onBreakpointChange:qu.noop,onLayoutChange:qu.noop,onWidthChange:qu.noop});var Qw={};function cy(r){return cy=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},cy(r)}Object.defineProperty(Qw,"__esModule",{value:!0}),Qw.default=She;var fy=phe(pe.default),hhe=xj(zi.exports),vhe=xj(Vg),dhe=["measureBeforeMount"];function xj(r){return r&&r.__esModule?r:{default:r}}function wj(r){if(typeof WeakMap!="function")return null;var e=new WeakMap,t=new WeakMap;return(wj=function(a){return a?t:e})(r)}function phe(r,e){if(!e&&r&&r.__esModule)return r;if(r===null||cy(r)!=="object"&&typeof r!="function")return{default:r};var t=wj(e);if(t&&t.has(r))return t.get(r);var n={},a=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in r)if(i!=="default"&&Object.prototype.hasOwnProperty.call(r,i)){var o=a?Object.getOwnPropertyDescriptor(r,i):null;o&&(o.get||o.set)?Object.defineProperty(n,i,o):n[i]=r[i]}return n.default=r,t&&t.set(r,n),n}function Zw(){return Zw=Object.assign||function(r){for(var e=1;e<arguments.length;e++){var t=arguments[e];for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(r[n]=t[n])}return r},Zw.apply(this,arguments)}function ghe(r,e){if(r==null)return{};var t=yhe(r,e),n,a;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(r);for(a=0;a<i.length;a++)n=i[a],!(e.indexOf(n)>=0)&&(!Object.prototype.propertyIsEnumerable.call(r,n)||(t[n]=r[n]))}return t}function yhe(r,e){if(r==null)return{};var t={},n=Object.keys(r),a,i;for(i=0;i<n.length;i++)a=n[i],!(e.indexOf(a)>=0)&&(t[a]=r[a]);return t}function mhe(r,e){if(!(r instanceof e))throw new TypeError("Cannot call a class as a function")}function Dj(r,e){for(var t=0;t<e.length;t++){var n=e[t];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(r,n.key,n)}}function _he(r,e,t){return e&&Dj(r.prototype,e),t&&Dj(r,t),Object.defineProperty(r,"prototype",{writable:!1}),r}function bhe(r,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");r.prototype=Object.create(e&&e.prototype,{constructor:{value:r,writable:!0,configurable:!0}}),Object.defineProperty(r,"prototype",{writable:!1}),e&&qw(r,e)}function qw(r,e){return qw=Object.setPrototypeOf||function(n,a){return n.__proto__=a,n},qw(r,e)}function Mhe(r){var e=whe();return function(){var n=hy(r),a;if(e){var i=hy(this).constructor;a=Reflect.construct(n,arguments,i)}else a=n.apply(this,arguments);return xhe(this,a)}}function xhe(r,e){if(e&&(cy(e)==="object"||typeof e=="function"))return e;if(e!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Ph(r)}function Ph(r){if(r===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return r}function whe(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function hy(r){return hy=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},hy(r)}function Ju(r,e,t){return e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}var Dhe="react-grid-layout";function She(r){var e;return e=function(t){bhe(a,t);var n=Mhe(a);function a(){var i;mhe(this,a);for(var o=arguments.length,s=new Array(o),l=0;l<o;l++)s[l]=arguments[l];return i=n.call.apply(n,[this].concat(s)),Ju(Ph(i),"state",{width:1280}),Ju(Ph(i),"elementRef",fy.createRef()),Ju(Ph(i),"mounted",!1),Ju(Ph(i),"onWindowResize",function(){if(!!i.mounted){var u=i.elementRef.current;u instanceof HTMLElement&&u.offsetWidth&&i.setState({width:u.offsetWidth})}}),i}return _he(a,[{key:"componentDidMount",value:function(){this.mounted=!0,window.addEventListener("resize",this.onWindowResize),this.onWindowResize()}},{key:"componentWillUnmount",value:function(){this.mounted=!1,window.removeEventListener("resize",this.onWindowResize)}},{key:"render",value:function(){var o=this.props,s=o.measureBeforeMount,l=ghe(o,dhe);return s&&!this.mounted?fy.createElement("div",{className:(0,vhe.default)(this.props.className,Dhe),style:this.props.style,ref:this.elementRef}):fy.createElement(r,Zw({innerRef:this.elementRef},l,this.state))}}]),a}(fy.Component),Ju(e,"defaultProps",{measureBeforeMount:!1}),Ju(e,"propTypes",{measureBeforeMount:hhe.default.bool}),e}(function(r){r.exports=Sh.default,r.exports.utils=et,r.exports.Responsive=iy.default,r.exports.Responsive.utils=hl,r.exports.WidthProvider=Qw.default})(ow);var Hme="",zh={"MetricList-container":"_MetricList-container_1b506_1","MetricList-wrapper":"_MetricList-wrapper_1b506_9","noMetric-container":"_noMetric-container_1b506_17","noMetric-wrapper":"_noMetric-wrapper_1b506_25","alt-container":"_alt-container_1b506_33"},mt={cardContainer:"_cardContainer_1ihqw_1",listHeader:"_listHeader_1ihqw_9",metricName:"_metricName_1ihqw_17",metricDescription:"_metricDescription_1ihqw_25",popup:"_popup_1ihqw_33",metricFilter:"_metricFilter_1ihqw_41",popupIcon:"_popupIcon_1ihqw_49",popupMenu:"_popupMenu_1ihqw_57",popupItem:"_popupItem_1ihqw_65",popupItemIcon:"_popupItemIcon_1ihqw_73",csvBtn:"_csvBtn_1ihqw_81",metricData:"_metricData_1ihqw_89",singleValueData:"_singleValueData_1ihqw_97",singleValue:"_singleValue_1ihqw_97",noData:"_noData_1ihqw_113",noDataContent:"_noDataContent_1ihqw_121",noDataText:"_noDataText_1ihqw_129",loading:"_loading_1ihqw_137",features:"_features_1ihqw_145"},Sj="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz48c3ZnIGlkPSJMYXllcl8xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAzMDAgMzAwIj48ZGVmcz48c3R5bGU+LmNscy0xe3N0cm9rZTojMTgyYzYwO30uY2xzLTEsLmNscy0ye2ZpbGw6bm9uZTtzdHJva2UtbGluZWNhcDpyb3VuZDtzdHJva2UtbGluZWpvaW46cm91bmQ7fS5jbHMtM3tmaWxsOiM1ODY1ZjY7b3BhY2l0eTouMTt9LmNscy00e2ZpbGw6I2YyZjNmNDt9LmNscy01e2ZpbGw6I2MxYzdjOTt9LmNscy02e2ZpbGw6I2RhZGVkZjt9LmNscy03e2ZpbGw6IzE4MmM2MDt9LmNscy0ye3N0cm9rZTojNTg2NWY2O3N0cm9rZS13aWR0aDo0cHg7fTwvc3R5bGU+PC9kZWZzPjxwYXRoIGNsYXNzPSJjbHMtMSIgZD0ibTIxMC41LDIwMC44M2MuNC0uNjYuNjgtMS40LjgyLTIuMiwxLjU4LTguODcsMy4xNS0xNy43NSw0LjczLTI2LjYyLDIuMDMtMTEuNDQsNC4wNi0yMi44OCw2LjA5LTM0LjMyLjcyLTQuMDgsMS43Ny04LjI1LDIuMTYtMTIuMzguNDMtNC41Ni0yLjA5LTkuNjgtNi44Ni0xMC42Ni0uMDEsMC0uMDMsMC0uMDQsMC0yLjQtLjQ5LTUuMDItLjIyLTcuNDUtLjIyaC00NC4yMmMtLjUyLDAtMi4zMy0uMzEtMi43NywwbC0yNC4yOCwxNy4yMmgtNjEuNjFjLTMuOTcsMC02Ljk5LDMuNTYtNi4zNCw3LjQ3bDkuNzUsNTkuNDJjLjUxLDMuMTEsMy4yLDUuMzksNi4zNCw1LjM5aDExNy44NiIvPjxwYXRoIGNsYXNzPSJjbHMtMSIgZD0ibTIwNywxMTQuNDN2LTguNTRjMC0zLjU1LTIuODgtNi40My02LjQzLTYuNDNoLTE3LjE5Ii8+PHBhdGggY2xhc3M9ImNscy0xIiBkPSJtMTAzLjQ3LDk5LjQ2aC0xNS4xMmMtMy41NSwwLTYuNDMsMi44OC02LjQzLDYuNDN2MjUuNDgiLz48Zz48bGluZSBjbGFzcz0iY2xzLTIiIHgxPSIxMTQuMTIiIHkxPSI5NC4wOCIgeDI9IjE0NC44NCIgeTI9Ijk0LjA4Ii8+PGc+PHJlY3QgY2xhc3M9ImNscy02IiB4PSIxMTIuNjEiIHk9IjEwMi40MyIgd2lkdGg9IjE4Ljk3IiBoZWlnaHQ9IjMuMiIvPjxyZWN0IGNsYXNzPSJjbHMtNCIgeD0iMTM3LjYxIiB5PSIxMDIuNDMiIHdpZHRoPSI4LjkiIGhlaWdodD0iMy4yIi8+PC9nPjwvZz48cGF0aCBjbGFzcz0iY2xzLTMiIGQ9Im0xNjQuOTgsODEuNDZsLS4wOCwxNi4yOHMuMTUsMy4yNC4zLDMuNjIuNiwxLjUxLDEuMTMsMS44OCwxLjAyLjc5LDEuNzcsMS4wNi45NC40OSwyLjExLjQ5LDE4LjE3LjA0LDE4LjE3LjA0bC0yMy40MS0yMy4zN1oiLz48cGF0aCBjbGFzcz0iY2xzLTEiIGQ9Im0xODguNTEsMTA0LjkxdjkuNTIiLz48cGF0aCBjbGFzcz0iY2xzLTEiIGQ9Im0xMDMuNTMsMTMxLjM3di00NC45NWMwLTIuODQsMi4zLTUuMTUsNS4xNS01LjE1LDE4Ljc3LDAsMzcuNTQsMCw1Ni4zMSwwIi8+PHBhdGggY2xhc3M9ImNscy0xIiBkPSJtMTY1LjAxLDgxLjI3djE4LjM1YzAsMi44NCwyLjMxLDUuMTUsNS4xNSw1LjE1aDE4LjM1cy0yMy41LTIzLjYyLTIzLjUtMjMuNVoiLz48Y2lyY2xlIGNsYXNzPSJjbHMtMSIgY3g9IjE2OC4yMSIgY3k9IjE2My4yNyIgcj0iMjQuOTYiLz48Y2lyY2xlIGNsYXNzPSJjbHMtMSIgY3g9IjE2OC4yMSIgY3k9IjE2My4yNyIgcj0iMzEuMjUiLz48cGF0aCBjbGFzcz0iY2xzLTEiIGQ9Im0xOTIuNTcsMTgzLjMzYzkuNjIsOS42MiwzMC4yOCwzMC4yOCwzMC4yOCwzMC4yOCwxLjE3LDEuMTcsMS4xNywzLjA3LDAsNC4yNHMtMy4wNywxLjE3LTQuMjQsMGMwLDAtMjAuNTgtMjAuNTgtMzAuMjItMzAuMjIiLz48Zz48cGF0aCBjbGFzcz0iY2xzLTUiIGQ9Im0xNjguNjYsMTcwLjkzYy0uNzQsMC0xLjM0LjI0LTEuODEuNzItLjQ3LjQ4LS43MSwxLjA5LS43MSwxLjgzcy4yNCwxLjMyLjcxLDEuODFjLjQ3LjQ5LDEuMDcuNzQsMS44MS43NHMxLjM0LS4yNSwxLjgxLS43NGMuNDctLjQ5LjcxLTEuMS43MS0xLjgxcy0uMjQtMS4zNC0uNzEtMS44M2MtLjQ3LS40OC0xLjA4LS43Mi0xLjgxLS43MloiLz48cGF0aCBjbGFzcz0iY2xzLTUiIGQ9Im0xNzQuNjksMTUzLjc3Yy0uNjItMS4wMi0xLjQ5LTEuODItMi42LTIuNC0xLjEyLS41Ny0yLjQtLjg2LTMuODUtLjg2LTEuNjgsMC0zLjE3LjQtNC40NywxLjE5cy0yLjI5LDEuOTQtMi45OCwzLjQzbDIuNzYsMi4yOGMuNDYtMS4wNiwxLjA3LTEuODYsMS44NS0yLjQuNzctLjU0LDEuNjUtLjgxLDIuNjQtLjgxLjc2LDAsMS40MS4xNCwxLjk3LjQxLjU1LjI4Ljk4LjY3LDEuMjgsMS4xNy4zLjUxLjQ1LDEuMS40NSwxLjc5cy0uMTYsMS4yOS0uNDcsMS44MWMtLjMxLjUyLS43NS45Mi0xLjMxLDEuMjEtLjU2LjI5LTEuMjIuNDMtMS45OC40M2gtLjkzdjYuNjZoMy4yOGwuMjYtMy43M2MuNzEtLjI0LDEuMzctLjU1LDEuOTUtLjkzLjk5LS42NCwxLjc1LTEuNDUsMi4yOS0yLjQxLjU0LS45Ny44MS0yLjA3LjgxLTMuMzEsMC0xLjMzLS4zMS0yLjUxLS45My0zLjU0WiIvPjwvZz48cGF0aCBjbGFzcz0iY2xzLTEiIGQ9Im04NS41NSwyMDMuOTdjLjY4LDIuODksMy4yNiw0Ljk2LDYuMjYsNC45NmgxMTcuNzMiLz48cGF0aCBjbGFzcz0iY2xzLTEiIGQ9Im0yMTUuMzcsMjA2LjA0Yy40Ny0uNzEuOC0xLjUyLjk1LTIuNCwxLjU4LTguODcsMy4xNS0xNy43NSw0LjczLTI2LjYyLDIuMDMtMTEuNDQsNC4wNi0yMi44OCw2LjA5LTM0LjMyLjcyLTQuMDgsMS43Ny04LjI1LDIuMTYtMTIuMzguMzktNC4xNi0xLjY4LTguNzktNS42Ny0xMC4zMSIvPjxwYXRoIGNsYXNzPSJjbHMtNyIgZD0ibTIyMy41MSwxMjAuMDhzLjQ5LDEuNjIuNTMsMS43My4zMiwyLjQ0LjMyLDIuNDRsLS4wNCwxLjkxLTEuMzgsNy4xMy0zLjM5LDE5LjMxLTIuODksMTUuOTItMi45NiwxNi43Ni0yLjQ0LDEzLjE2LS45MiwyLjY1LDQuOTgsNS4xNS44NS0yLjE1LjgxLTQuMDYsMS40OC04LjMzLDIuODItMTUuNzEsMi4xNS0xMi4xMSwxLjk0LTExLjM2LDIuNzUtMTQuNzUuODgtNC42OS4yOC0yLjU4LjA3LTIuMTItLjYtMi43NS0xLjI0LTIuMzYtMS4wOS0xLjU5LTIuMDEtMS4zMS0uOTItLjI4WiIvPjxwb2x5Z29uIGNsYXNzPSJjbHMtNyIgcG9pbnRzPSI4NS42OCAyMDMuOTMgMjA0LjU1IDIwMy44NCAyMDkuMzUgMjA4LjczIDE0OC40OCAyMDguODggOTAuOTUgMjA5LjAyIDg5LjUgMjA4LjY2IDg3Ljk4IDIwNy45MiA4Ni44MiAyMDYuNTggODYuMDEgMjA1LjAzIDg1LjY4IDIwMy45MyIvPjwvc3ZnPg==";const Ij=({globalFilters:r={tableName:"",filters:[]},metricItem:e,onMaximize:t,client:n,colors:a,param:i,companyTenancyType:o,renderHeaderName:s})=>{var nn,na,cr;const{globalTheme:l}=il(),u={};if(i!=null&&i.values)for(const Xe in i.values){const Wt=`${Xe}_variable`;u[Wt]=i.values[Xe]}const[c,f]=R.useState(""),[h,v]=R.useState(""),[d,p]=R.useState([]),[g,y]=R.useState(""),[m,_]=R.useState(""),[b,x]=R.useState([]),[M,w]=R.useState(""),[D,T]=R.useState([]),[I,A]=R.useState([]),[N,L]=R.useState({card:{isEnable:!1,baseUrl:"",dynamic:"none",route:"",routeType:"internal"},chart:{isEnable:!1,baseUrl:"",dynamic:"{{value}}",route:"/{{value}}",routeType:"internal"}}),{data:E,isLoading:O}=bS({id:e==null?void 0:e.id,clientId:n,tenancyLevel:o,rlsConditions:o==="DATABASE"?I.map(Xe=>({...Xe,tableName:`${n}.${Xe.tableName.split(".").slice(1).join(".")}`,dimensionColumn:h||"",measureColumn:d[0]||""})):I.map(Xe=>({...Xe,dimensionColumn:h||"",measureColumn:d[0]||""})),globalFilters:o==="DATABASE"?{...r,tableName:`${n}.${r.tableName.split(".").slice(1).join(".")}`}:r,filterValues:u}),P=(nn=E==null?void 0:E.externalMetricQuery)==null?void 0:nn.data,[H,F]=R.useState({marginTop:20,marginBottom:20,marginLeft:5,marginRight:5}),[G,Z]=R.useState({show:!0,top:0,left:0,right:0,bottom:0,position:"horizontal"}),[te,V]=R.useState({axis:"left",show:!1,position:"hidden"}),[Y,q]=R.useState({axis:"left"}),[Q,ne]=R.useState({hideSplitLines:"none",hideAxisLines:"none",barWidth:40,barRadius:0,axisLabels:"none",fontSize:14,subHeaderShow:!1,displayText:"",subHeaderFontSize:0,dateFormatter:"none",numberFormatter:"original"}),[oe,ie]=R.useState({show:!1}),[he,k]=R.useState(!1),[j,W]=R.useState([]),[ae,re]=R.useState(),[ee,se]=R.useState([]);R.useEffect(()=>{p(e==null?void 0:e.chartOptions.yAxisList),v(e==null?void 0:e.chartOptions.xAxis),y(e==null?void 0:e.chartOptions.step),_(e==null?void 0:e.chartOptions.measure),f(e==null?void 0:e.chartOptions.chartType),x(e==null?void 0:e.chartOptions.sankeyValues),w(e==null?void 0:e.chartOptions.singleValue),F(e==null?void 0:e.chartOptions.margins),Z(e==null?void 0:e.chartOptions.legendSettings),V(e==null?void 0:e.chartOptions.labelSettings),q(e!=null&&e.chartOptions.axisSettings?e==null?void 0:e.chartOptions.axisSettings:"left"),ie(e!=null&&e.chartOptions.backGroundColor?e==null?void 0:e.chartOptions.backGroundColor:"false"),ne(e!=null&&e.chartOptions.customSettings?e==null?void 0:e.chartOptions.customSettings:{hideSplitLines:"none",hideAxisLines:"none",barWidth:40,barRadius:0,axisLabels:"none",fontSize:14,subHeaderShow:!1,displayText:"",subHeaderFontSize:0,dateFormatter:"none",numberFormatter:"original"}),k(e==null?void 0:e.isEnableGroupBy),W(e==null?void 0:e.selectedGroupBy),re(e==null?void 0:e.groupBy),A((e==null?void 0:e.rlsConditions)||[]),L(e.clickActions||{card:{isEnable:!1,baseUrl:"",dynamic:"none",route:"",routeType:"internal"},chart:{isEnable:!1,baseUrl:"",dynamic:"{{value}}",route:"/{{value}}",routeType:"internal"}})},[e]),R.useEffect(()=>{T(P!=null?P:[])},[P]);const{labels:Le,datasets:dt,funnelData:pt,sankeyData:_t,singleValueData:zt}=_m({data:he?ee:D,measure:m,sankeyValues:b,singleValue:M,step:g,xAxis:h,yAxisList:d});R.useEffect(()=>{if(ee.length&&he){const Xe=iw(ee[0]);v(Xe.stringKeys[0]),p(Xe.numberKeys)}},[ee,he]),R.useEffect(()=>{ee.length===0&&he&&j.length&&(D==null?void 0:D.length)&&(re({column:j[0]}),Sa(D,[j[0]],j,se))},[ee,he,j]),R.useEffect(()=>{(D==null?void 0:D.length)&&j.length&&he&&Sa(D,[j[0]],j,se)},[D,j,he]);const qt=Xe=>{if((ae==null?void 0:ae.column)&&Xe&&Xe!=="undefined"){if(j.lastIndexOf(ae.column)!==j.length-1){const Wt=j.indexOf(ae.column),fr=ae.column;re({column:j[Wt+1],parentColumn:{column:ae.column,value:Xe}}),Sa(D==null?void 0:D.filter(Xt=>Xt[fr]===Xe),[j[Wt+1]],j,se)}j.lastIndexOf(ae.column)===j.length-1&&(re({column:j[0]}),Sa(D,[j[0]],j,se))}else re({column:j[0]}),Sa(D,[j[0]],j,se)},Cn=(Xe,Wt)=>A(fr=>fr.map(Xt=>Xt.name===Xe?{...Xt,value:Wt}:Xt));return S(we,{children:B("div",{className:mt.cardContainer,children:[B("div",{className:mt.listHeader,children:[B(de,{variant:"h3",styleClass:"primary",className:mt.metricName,style:l?{color:l.cardTitle.color,fontWeight:l.cardTitle.fontWeight,fontSize:l.cardTitle.fontSize}:void 0,children:[s?s(e.name):S(Ce,{type:"button",variant:"custom",isDisabled:!N.card.isEnable,className:"disabled:cursor-text",onClick:()=>YR(N,e.metricId,e.id),style:l?{color:l.cardTitle.color,fontWeight:l.cardTitle.fontWeight,fontSize:l.cardTitle.fontSize}:void 0,children:e.name}),e.description&&S("span",{className:mt.metricDescription,style:l?{color:l.cardDescription.color,fontWeight:l.cardDescription.fontWeight,fontSize:l.cardDescription.fontSize}:void 0,children:e.description})]}),B("div",{className:mt.features,children:[!!I.length&&S("div",{className:mt.metricFilter,children:S(br,{label:I[0].name,selectedOption:{value:I[0].value||I[0].options[0],label:I[0].value||I[0].options[0]},options:I[0].options.map(Xe=>({value:Xe,label:Xe})),onChange:Xe=>Cn(I[0].name,Xe.value)})}),B(Rg,{buttonClass:mt.popup,button:S(lt,{name:"more-icon",className:mt.popupIcon}),menuClass:mt.popupMenu,position:"bottom-right",children:[B(Ce,{type:"button",variant:"custom",className:mt.popupItem,onClick:()=>{var Xe,Wt;return t({labels:Le,data:{labels:Le,datasets:dt},chartType:c,funnelData:pt,sankeyData:_t,singleValueData:zt,margins:H,colors:l?(Wt=(Xe=l.chart.palettes)==null?void 0:Xe.find(fr=>fr.name===l.chart.selected))==null?void 0:Wt.colors:a,legendSettings:G,labelSettings:te,axisSettings:Y,customSettings:Q,backGroundColor:oe,enableSaveAs:!0,chartClickConfig:N.chart})},children:[S(lt,{name:"fullscreen-icon",className:mt.popupItemIcon}),"Enter Fullscreen"]}),S(ES,{data:D,fileName:e.name,className:`${mt.popupItem} ${mt.csvBtn}`,text:"Save As CSV",iconClass:mt.popupItemIcon})]})]})]}),c&&B("div",{className:mt.metricData,children:[!O&&!D.length?S("div",{className:mt.noData,children:B("div",{className:mt.noDataContent,children:[S("img",{src:Sj,alt:"",width:"300px",height:"300px"}),S("div",{className:mt.noDataText,children:"No Data Available"})]})}):null,O&&S("div",{className:mt.loading,children:S(Uu,{style:{width:"50px",height:"50px",color:"blue"}})}),D!=null&&D.length?S(kg,{labels:Le,data:{labels:Le,datasets:dt},chartType:c,funnelData:pt,sankeyData:_t,singleValueData:zt,margins:H,legendSettings:G,labelSettings:te,axisSettings:Y,enableSaveAs:!0,colors:l?(cr=(na=l.chart.palettes)==null?void 0:na.find(Xe=>Xe.name===l.chart.selected))==null?void 0:cr.colors:a,updateGroup:qt,isEnableGroupBy:he,customSettings:Q,backGroundColor:oe,chartClickConfig:N.chart}):null]})]})})},Tj=({globalFilters:r={tableName:"",filters:[]},metricItem:e,client:t,param:n,companyTenancyType:a,renderHeaderName:i})=>{var A;const{globalTheme:o}=il(),s={};if(n!=null&&n.values)for(const N in n.values){const L=`${N}_variable`;s[L]=n.values[N]}const[l,u]=R.useState(""),[c,f]=R.useState(""),[h,v]=R.useState([]),[d,p]=R.useState([]),[g,y]=R.useState({card:{isEnable:!1,baseUrl:"",dynamic:"none",route:"",routeType:"internal"},chart:{isEnable:!1,baseUrl:"",dynamic:"{{value}}",route:"/{{value}}",routeType:"internal"}}),[m,_]=R.useState({hideSplitLines:"none",hideAxisLines:"none",barWidth:40,barRadius:0,axisLabels:"none",fontSize:14,subHeaderShow:!1,displayText:"",subHeaderFontSize:0,dateFormatter:"none",numberFormatter:"original"}),{data:b,isLoading:x}=bS({id:e==null?void 0:e.id,clientId:t,tenancyLevel:a,rlsConditions:a==="DATABASE"?d.map(N=>({...N,tableName:`${t}.${N.tableName.split(".").slice(1).join(".")}`})):d,globalFilters:a==="DATABASE"?{...r,tableName:`${t}.${r.tableName.split(".").slice(1).join(".")}`}:r,filterValues:s}),M=(A=b==null?void 0:b.externalMetricQuery)==null?void 0:A.data;R.useEffect(()=>{u(e==null?void 0:e.chartOptions.chartType),f(e==null?void 0:e.chartOptions.singleValue),p((e==null?void 0:e.rlsConditions)||[]),_(e!=null&&e.chartOptions.customSettings?e==null?void 0:e.chartOptions.customSettings:{hideSplitLines:"none",hideAxisLines:"none",barWidth:40,barRadius:0,axisLabels:"none",fontSize:14,subHeaderShow:!1,displayText:"",subHeaderFontSize:0,dateFormatter:"none",numberFormatter:"original"}),y(e.clickActions||{card:{isEnable:!1,baseUrl:"",dynamic:"none",route:"",routeType:"internal"},chart:{isEnable:!1,baseUrl:"",dynamic:"{{value}}",route:"/{{value}}",routeType:"internal"}})},[e]),R.useEffect(()=>{v(M!=null?M:[])},[M]);const w=h,D=w!=null&&w.length?w==null?void 0:w.map(N=>N[c]):"",T=[{value:D[0]}],I=(N,L)=>p(E=>E.map(O=>O.name===N?{...O,value:L}:O));return S(we,{children:B("div",{className:mt.cardContainer,children:[B("div",{className:mt.listHeader,children:[B(de,{variant:"h3",styleClass:"primary",className:mt.metricName,style:o?{color:o.cardTitle.color,fontWeight:o.cardTitle.fontWeight,fontSize:o.cardTitle.fontSize}:void 0,children:[i?i(e.name):S(Ce,{type:"button",variant:"custom",isDisabled:!g.card.isEnable,className:"disabled:cursor-text",onClick:()=>YR(g,e.metricId,e.id),style:o?{color:o.cardTitle.color,fontWeight:o.cardTitle.fontWeight,fontSize:o.cardTitle.fontSize}:void 0,children:e.name}),e.description&&S("span",{className:mt.metricDescription,style:o?{color:o.cardDescription.color,fontWeight:o.cardDescription.fontWeight,fontSize:o.cardDescription.fontSize}:void 0,children:e.description})]}),S("div",{className:mt.features,children:!!(d!=null&&d.length)&&S("div",{className:mt.metricFilter,children:S(br,{label:d[0].name,selectedOption:{value:d[0].value||d[0].options[0],label:d[0].value||d[0].options[0]},options:d[0].options.map(N=>({value:N,label:N})),onChange:N=>I(d[0].name,N.value)})})})]}),l&&S("div",{className:`${mt.metricData} ${mt.singleValueData}`,children:x?S(Uu,{style:{width:"50px",height:"50px",color:"blue"}}):S(we,{children:D.length?S(ZR,{data:T,customSettings:m,chartClickConfig:g.chart,hideBorder:!0}):S("div",{className:mt.noData,children:B("div",{className:mt.noDataContent,children:[S("img",{src:Sj,alt:"",width:"300px",height:"300px"}),S("div",{className:mt.noDataText,children:"No Data Available"})]})})})})]})})},Aj=ow.exports.WidthProvider(ow.exports.Responsive),Cj=({chartColors:r,globalFilters:e,client:t,isLiveMode:n,externalDashboardMetrics:a,isMetricListLoading:i,breakpoint:o,layoutCols:s,params:l,companyTenancyType:u="TABLE"})=>{const[c,f]=R.useState(!1),[h,v]=R.useState(),d=a==null?void 0:a.map(m=>m.externalMetric),p=d==null?void 0:d.filter(m=>!m.isCreatedByClient),g=d==null?void 0:d.filter(m=>m.isCreatedByClient&&m.clientId===t),y=[...p||[],...g||[]].filter(m=>n?m.isLive===n:!0);return S(we,{children:y.length?B(we,{children:[S("div",{className:zh["MetricList-container"],children:S(Aj,{layouts:{lg:y.map(({resizeAttributes:m,id:_})=>({i:_,w:m.width,h:m.height,x:m.xAxis,y:m.yAxis,minW:3,minH:6,maxH:15}))},isResizable:!1,isDraggable:!1,isDroppable:!1,rowHeight:30,width:1200,breakpoints:o!=null?o:{lg:1200,md:996,sm:768,xs:480,xxs:0},cols:s!=null?s:{lg:12,md:10,sm:6,xs:4,xxs:2},children:y.map(m=>S("div",{className:zh["MetricList-wrapper"],children:m.chartOptions.chartType==="single value"?S(Tj,{metricItem:m,client:t,globalFilters:e,param:l==null?void 0:l.find(_=>_.metricId===m.metricId),companyTenancyType:u}):S(Ij,{metricItem:m,onMaximize:_=>{v(_),f(!0)},client:t,colors:r,globalFilters:e,param:l==null?void 0:l.find(_=>_.metricId===m.metricId),companyTenancyType:u})},m.id))})}),S(tw,{onCancel:()=>f(!1),isShow:c,chart:h})]}):S(we,{children:i?S("div",{className:zh["alt-container"],children:S(Uu,{style:{width:"50px",height:"50px",color:"blue"}})}):S("div",{className:zh["noMetric-container"],children:S("div",{className:zh["noMetric-wrapper"],children:S(de,{variant:"h2",styleClass:"primary",children:"No metrics created yet"})})})})})};var Ihe=Object.freeze(Object.defineProperty({__proto__:null,Button:Ce,ChartConfig:vS,ChartModalOptions:dS,SelectField:pv,DataType:dm,Error:pm,ErrorFallback:mS,ExternalMetricForm:MS,FilterDropDown:SS,MultiFilterDropdown:IS,FloatingDropDown:br,MultiFloatingDropDown:DS,FullScreenChart:tw,isInFilterOperator:rw,isNullFilterOperator:Dh,FilterField:qR,GlobalFilters:XR,Tooltip:KR,InfoTooltip:Ei,InputField:Ct,CsvDownloadButton:ES,MetricChart:kg,EmbeddedMetricCreation:y3,MetricForm:d3,ConstructMetric:g3,Dataset:r3,Header:t3,MetricOutput:l3,ChartTab:a3,TableTab:s3,GridLayout:Aj,ExternalMetricList:Cj,MetricCard:Ij,SingleValueCard:Tj,MetricTable:i3,Modal:li,ModalFooter:Cl,PopoverMenu:Rg,SearchTab:cc,Select:Jt,HookSelect:uS,SelectWithSubValue:cS,DropDown:jB,MultiSelect:fc,HookMultiSelect:BB,Tab:aw,Table:o3,Text:de,TextAreaField:_S,TimeGrainField:u3,ToggleButton:ym,Icons:lt},Symbol.toStringTag,{value:"Module"}));const The=r=>S("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",...r,children:S("path",{fill:"currentColor",d:"m16.95 6l-3.57 4.55l1.43 1.43c1.03-1.31 4.98-6.37 4.98-6.37A.998.998 0 0 0 19 4H6.83l2 2h8.12zM2.81 2.81L1.39 4.22L10 13v6c0 .55.45 1 1 1h2c.55 0 1-.45 1-1v-2.17l5.78 5.78l1.41-1.41L2.81 2.81z"})}),Nj=pe.default.memo(({token:r,options:e,theme:t})=>{var f,h;const{data:n,isLoading:a}=xS(r),{globalTheme:i,setGlobalTheme:o}=il(),[s,l]=R.useState(!1),[u,c]=R.useState({tableName:"",filters:[]});return kF({companyId:n.companyId},{enabled:!!n.companyId,onSuccess:v=>{o(v.themes[0])}}),S(we,{children:B("div",{className:pn["embedDashboard-container"],style:i?{backgroundColor:`${i.dashboard.backgroundColor} !important`,fontFamily:`${i.general.fontFamily} !important`}:void 0,children:[((f=n.externalDashboard)==null?void 0:f.id)&&!a&&B(we,{children:[!(e!=null&&e.disableMetricCreation)&&!n.externalDashboard.filters.length&&!n.isAllowedToCreateMetrics?null:B("div",{className:(e==null?void 0:e.headerVariant)==="floating"?pn["embedDashboard-header-floating"]:pn["embedDashboard-header-static"],children:[(e==null?void 0:e.headerVariant)==="floating"&&S("span",{className:pn.floatingButton,children:S(lt,{name:"setup-icon",className:pn.floatingButton})}),B("div",{className:(e==null?void 0:e.headerVariant)==="floating"?pn.floatingContainer:pn.staticContainer,children:[n.externalDashboard.filters.length?S(Ce,{type:"button",variant:"custom",size:"large",className:(e==null?void 0:e.headerVariant)==="floating"?pn.floatingFilterButton:pn.filter,onClick:()=>l(v=>!v),children:s?S(The,{}):S(lt,{name:"filter-icon",className:pn.floatingFilterButtonIcon})}):null,!(e!=null&&e.disableMetricCreation)&&n.isAllowedToCreateMetrics&&S(y3,{clientId:n.clientId,companyId:n.companyId,mode:n.mode,externalDashboardId:n.externalDashboard.id,variant:e==null?void 0:e.headerVariant})]})]}),B("div",{className:pn["embedDashboard-wrapper"],children:[n.externalDashboard.filters.length&&s?S(XR,{companyId:n.companyId,filters:n.externalDashboard.filters,onApply:v=>c(v)}):null,S(Cj,{client:n.clientId,isLiveMode:n.mode,externalDashboardMetrics:n.externalDashboardMetrics,isMetricListLoading:a,globalFilters:u,breakpoint:t==null?void 0:t.breakpoint,layoutCols:t==null?void 0:t.metricLayoutCols,chartColors:e==null?void 0:e.chartColors,params:Array.isArray(n.rlsSettings)?n.rlsSettings:[],companyTenancyType:n.companyTenancyType})]})]}),a&&S("div",{className:pn["alt-container"],children:S(Uu,{style:{width:"50px",height:"50px",color:"blue"}})}),!a&&!((h=n.externalDashboard)!=null&&h.id)&&S("div",{className:pn["alt-container"],children:"Invalid token or Dashboard id"})]})})}),Ahe=new c5,Lj=({children:r,theme:e})=>(R.useEffect(()=>{!e||!Object.keys(e).length||AS(e)},[e]),S($j,{FallbackComponent:mS,children:S(g5,{client:Ahe,children:S(Iue,{children:r})})})),Che=pe.default.memo(({token:r,options:e,theme:t})=>S(Lj,{theme:t,children:S(Nj,{token:r,options:e})}));var Nhe=Object.freeze(Object.defineProperty({__proto__:null,SOMETHING_WENT_WRONG:am,CHART_TYPES:At,STATUS_TAB:FB,STREAM_TAB:VB,CLIENT_NAME_VAR:HB,RLS_CONDITIONS:WB,CHART_TAB:gv,TABLE_TAB:hc,QUERY_TAB:GB,INPUT_TABLE:vc,OUTPUT_TABLE:Il,DOUGHNUT:im,PIE:om,SANKEY:fS,BOXPLOT:hS,TABLE:$B,GENERAL:$o,CONFIG:Tl,DESTINATIONS:sm,operatorList:yv,RowLimitList:pS,AggregateList:um,NUMBER_TYPES:cm,STRING_TYPES:fm,DATE_TYPES:hm,ARRAY_TYPES:gS,BOOLEAN_TYPES:vm},Symbol.toStringTag,{value:"Module"})),Lhe=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"}));Cr.Dashboard=Che,Cr.EmbeddedDashboard=Nj,Cr.PluginProvider=Lj,Cr.Ui=Ihe,Cr.consts=Nhe,Cr.helpers=Bue,Cr.hooks=HF,Cr.types=Lhe,Cr.utils=$F,Object.defineProperties(Cr,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
|