The Ultimate Video Player For WordPress – by Presto Player - Version 1.11.0-beta1

Version Description

Download this release

Release Info

Developer 2winfactor
Plugin Icon 128x128 The Ultimate Video Player For WordPress – by Presto Player
Version 1.11.0-beta1
Comparing to
See all releases

Code changes from version 1.10.2 to 1.11.0-beta1

.gitattributes DELETED
@@ -1,7 +0,0 @@
1
- # Directories
2
- /.wordpress-org export-ignore
3
- /.github export-ignore
4
-
5
- # Files
6
- /.gitattributes export-ignore
7
- /.gitignore export-ignore
 
 
 
 
 
 
 
dist/analytics.asset.php ADDED
@@ -0,0 +1 @@
 
1
+ <?php return array('dependencies' => array('react', 'wp-api-fetch', 'wp-components', 'wp-element', 'wp-polyfill'), 'version' => 'c47e65522b4cbb069f7a');
dist/{analytics/admin-7f8d2917.css → analytics.css} RENAMED
@@ -1,20 +1 @@
1
- /*!
2
- *
3
- * Presto Player
4
- *
5
- * @author Presto Made, Inc
6
- * @version 0.1.0
7
- * @link undefined
8
- * @license GPL
9
- *
10
- * Copyright (c) 2022 Presto Made, Inc
11
- *
12
- * This software is released under the GPL License
13
- * https://opensource.org/licenses/GPL
14
- *
15
- * Compiled with the help of https://wpack.io
16
- * A zero setup Webpack Bundler Script for WordPress
17
- */
18
- *{box-sizing:inherit}.presto-inline-edit__text{display:inline;margin:0 8px 0 0}.presto-inline-edit__input{flex-grow:1;max-width:640px}.presto-inline-edit__input input{height:36px}.presto-inline-edit .presto-inline-edit__button{margin-right:4px}.presto-inline-edit__edit{cursor:pointer;display:inline-flex;justify-content:center;align-items:center;width:28px;height:28px;border-radius:50%;border:none;opacity:.5;color:#fff;background-color:var(--wp-admin-theme-color)}.presto-inline-edit__edit:hover{opacity:1;background-color:var(--wp-admin-theme-color-darker-10)}.presto-inline-edit--editing{align-items:stretch}.datatable{display:flex;flex-direction:column;background:#fff;border:1px solid #e2e4e7}.datatable .table-card{border-bottom-left-radius:0;border-bottom-right-radius:0;border:none}.datatable .pagination{border-top-left-radius:0;border-top-right-radius:0;margin-top:auto;border:none}.presto-flow>*+*{margin-top:var(--presto-flow-space,2em)}.presto-loading{display:flex;align-items:center;justify-content:center;min-height:100px}table.presto-table{width:100%;border-collapse:collapse}table.presto-table td h2,table.presto-table td h3{margin:0 0 8px}table.presto-table.is-clickable td{cursor:pointer;transition:background-color .25s ease}table.presto-table.is-clickable tr:hover td{background-color:#f3f3f3}table.presto-table td,table.presto-table th{text-align:left;padding:.65rem;border-top:1px solid #e2e4e7}table.presto-table tr:first-child td{border-top:none}table.presto-table th{color:#757575;background-color:#f7f7f7;border:none;font-size:10px;font-weight:700;text-transform:uppercase;letter-spacing:1px}@media (min-device-width:768px)and (max-device-width:1024px),only screen and (max-width:760px){table.presto-table,table.presto-table tbody,table.presto-table td,table.presto-table th,table.presto-table thead,table.presto-table tr{display:block}table.presto-table thead tr{position:absolute;top:-9999px;left:-9999px}table.presto-table tr{margin:0 0 1rem}table.presto-table tr:nth-child(odd){background:#f3f3f3}table.presto-table td{border:none;border-bottom:1px solid #fff;position:relative;padding:10px 10px 10px 50%}table.presto-table td:before{position:absolute;top:10px;left:10px;width:45%;padding-right:10px;white-space:nowrap;content:attr(data-title);font-weight:700}}.presto-dashboard__row{--spacing:1rem;--column-count:2;display:flex;flex-wrap:wrap;margin:0 calc(var(--spacing)*-0.5);align-items:stretch;justify-content:space-between}.presto-dashboard__item{flex:0 1 33.33%;padding:calc(var(--spacing)/3);width:33.33%}.presto-dashboard__item>*{height:100%}.presto-dashboard__item.is-large{flex:1}.presto-dashboard__header{background:#fff;padding:20px;display:flex;align-items:center;justify-content:space-between}.presto-dashboard__logo{max-width:175px}.presto-dashboard__content{margin:25px 0;width:calc(100% - 20px)}.presto-dashboard__body{max-width:800px;margin-left:auto;margin-right:auto}@media(max-width:767px){.presto-dashboard__row{display:block}.presto-dashboard__item{width:100%}}.presto-dashboard__title{line-height:1em}.presto-settings-page-notices.components-snackbar-list{position:fixed!important;left:auto;right:40px;bottom:40px;width:auto}.presto-card__title{opacity:.75;font-size:1rem;clear:both;margin:.75rem 0}.presto-player-dashboard__version{line-height:1;padding:6px 12px;background:#f1f1f1;color:#666;font-weight:500;border-radius:999px}.presto-player-dashboard__header{background:#fff;margin-left:-20px;margin-right:-20px;padding:20px;display:flex;align-items:center;justify-content:space-between;max-width:calc(100% + 20px)}.presto-player-dashboard__logo{max-height:30px;max-width:200px}.presto-module-tabs [role=tablist]{border-bottom:1px solid #e2e4e7}.presto-badge{border-radius:9999px;border:1px solid var(--wp-admin-theme-color,#007cba);color:var(--wp-admin-theme-color,#007cba);padding:5px 10px;line-height:1;white-space:nowrap;display:inline-block}.apexcharts-xaxis text,.apexcharts-yaxis text{opacity:.35}:root{--wp-admin-theme-color:#7c3aed!important;--wp-admin-theme-color-darker-10:#6127c7!important;--wp-admin-theme-color-darker-20:#501ea5!important;--litepickerDayIsInRange:#f3f3f3;--litepicker-container-months-color-bg:#fff;--litepicker-container-months-box-shadow-color:#ddd;--litepicker-footer-color-bg:#fafafa;--litepicker-footer-box-shadow-color:#ddd;--litepicker-tooltip-color-bg:#fff;--litepicker-month-header-color:#333;--litepicker-button-prev-month-color:#9e9e9e;--litepicker-button-next-month-color:#9e9e9e;--litepicker-button-prev-month-color-hover:var(--wp-admin-theme-color,#7c3aed);--litepicker-button-next-month-color-hover:var(--wp-admin-theme-color,#7c3aed);--litepicker-month-width:calc(var(--litepicker-day-width)*7);--litepicker-month-weekday-color:#9e9e9e;--litepicker-month-week-number-color:#9e9e9e;--litepicker-day-width:38px;--litepicker-day-color:#333;--litepicker-day-color-hover:var(--wp-admin-theme-color,#7c3aed);--litepicker-is-today-color:#f44336;--litepicker-is-in-range-color:rgba(124,58,237,0.12156862745098039);--litepicker-is-locked-color:#9e9e9e;--litepicker-is-start-color:#fff;--litepicker-is-start-color-bg:var(--wp-admin-theme-color,#7c3aed);--litepicker-is-end-color:#fff;--litepicker-is-end-color-bg:var(--wp-admin-theme-color,#7c3aed);--litepicker-button-cancel-color:#fff;--litepicker-button-cancel-color-bg:#9e9e9e;--litepicker-button-apply-color:#fff;--litepicker-button-apply-color-bg:var(--wp-admin-theme-color,#7c3aed);--litepicker-button-reset-color:#909090;--litepicker-button-reset-color-hover:var(--wp-admin-theme-color,#7c3aed);--litepicker-highlighted-day-color:#333;--litepicker-highlighted-day-color-bg:#ffeb3b}.presto-player__stat-card{display:flex;align-items:center;justify-content:center;text-align:center}.presto-player__stat-card h1{font-size:3rem;margin-bottom:.4em}.presto-options__pro-badge{margin:0 4px;line-height:1;background:var(--wp-admin-theme-color);color:#fff;padding:3px 6px;border-radius:9999px;font-size:10px;display:inline-block}.presto-options__disabled-overlay{position:absolute;top:0;left:0;right:0;bottom:0;display:flex;align-items:center;justify-self:center;z-index:99}.presto-options__card{position:relative}.litepicker{font-size:1em}.litepicker .container__days>a,.litepicker .container__days>div{margin-bottom:5px}.litepicker .container__footer,.litepicker .container__main .container__predefined-ranges,.litepicker .container__months{border:1px solid #e0e0e0;box-shadow:none;border-radius:0;margin:0}.litepicker .container__main .container__predefined-ranges{margin-right:-1px;padding:16px;max-width:125px;width:125px;border-radius:0}.litepicker .container__main .container__predefined-ranges>div{color:var(--wp-admin-theme-color,#007cba)}.litepicker .container__months .month-item-header div>.month-item-year{padding:0 24px 0 8px}.litepicker .container__footer{margin-top:-1px;padding:8px}.litepicker .container__footer .button-apply,.litepicker .container__footer .button-cancel{display:inline-flex;text-decoration:none;font-size:13px;margin:0;border:0;cursor:pointer;-webkit-appearance:none;background:none;transition:box-shadow .1s linear;height:36px;align-items:center;box-sizing:border-box;padding:6px 12px;border-radius:2px;color:#1e1e1e;white-space:nowrap}.litepicker .container__footer .button-apply{background:#007cba;background:var(--wp-admin-theme-color);color:#fff;text-decoration:none;text-shadow:none}.presto-settings__page{margin:25px 25px 25px auto}.presto-settings__loading{min-height:200px;width:100%;display:flex;align-items:center;justify-content:center}.presto-settings__body .components-card,.presto-settings__setting{max-width:800px}.presto-settings__navigation{margin-left:-20px;margin-right:-20px;padding-right:20px;position:-webkit-sticky;position:sticky;top:32px;z-index:99}@media screen and (max-width:782px){.presto-settings__navigation{top:46px}}.presto-settings .components-snackbar.is-snackbar-error{background:#cc1818}.presto-settings__date-select,.presto-settings__date-select:disabled{padding-right:30px;background:#fff url(data:image/svg+xml;charset=US-ASCII,%3Csvg%20width%3D%2220%22%20height%3D%2220%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M5%206l5%205%205-5%202%201-7%207-7-7%202-1z%22%20fill%3D%22%23555%22%2F%3E%3C%2Fsvg%3E) no-repeat right 5px top 55%;background-size:16px 16px;cursor:pointer;vertical-align:middle;opacity:1;box-shadow:none;color:#444;border-color:#757575;-webkit-user-select:none;-ms-user-select:none;user-select:none}.is-color-control{max-width:250px}
19
-
20
- /*# sourceMappingURL=admin-7f8d2917.css.map*/
1
+ *{box-sizing:inherit}.presto-inline-edit__text{display:inline;margin:0 8px 0 0}.presto-inline-edit__input{flex-grow:1;max-width:640px}.presto-inline-edit__input input{height:36px}.presto-inline-edit .presto-inline-edit__button{margin-right:4px}.presto-inline-edit__edit{cursor:pointer;display:inline-flex;justify-content:center;align-items:center;width:28px;height:28px;border-radius:50%;border:none;opacity:.5;color:#fff;background-color:var(--wp-admin-theme-color)}.presto-inline-edit__edit:hover{opacity:1;background-color:var(--wp-admin-theme-color-darker-10)}.presto-inline-edit--editing{align-items:stretch}.datatable{display:flex;flex-direction:column;background:#fff;border:1px solid #e2e4e7}.datatable .table-card{border-bottom-left-radius:0;border-bottom-right-radius:0;border:none}.datatable .pagination{border-top-left-radius:0;border-top-right-radius:0;margin-top:auto;border:none}.presto-flow>*+*{margin-top:var(--presto-flow-space,2em)}.presto-loading{display:flex;align-items:center;justify-content:center;min-height:100px}table.presto-table{width:100%;border-collapse:collapse}table.presto-table td h2,table.presto-table td h3{margin:0 0 8px}table.presto-table.is-clickable td{cursor:pointer;transition:background-color .25s ease}table.presto-table.is-clickable tr:hover td{background-color:#f3f3f3}table.presto-table td,table.presto-table th{text-align:left;padding:.65rem;border-top:1px solid #e2e4e7}table.presto-table tr:first-child td{border-top:none}table.presto-table th{color:#757575;background-color:#f7f7f7;border:none;font-size:10px;font-weight:700;text-transform:uppercase;letter-spacing:1px}@media (min-device-width:768px)and (max-device-width:1024px),only screen and (max-width:760px){table.presto-table,table.presto-table tbody,table.presto-table td,table.presto-table th,table.presto-table thead,table.presto-table tr{display:block}table.presto-table thead tr{position:absolute;top:-9999px;left:-9999px}table.presto-table tr{margin:0 0 1rem}table.presto-table tr:nth-child(odd){background:#f3f3f3}table.presto-table td{border:none;border-bottom:1px solid #fff;position:relative;padding:10px 10px 10px 50%}table.presto-table td:before{position:absolute;top:10px;left:10px;width:45%;padding-right:10px;white-space:nowrap;content:attr(data-title);font-weight:700}}.presto-dashboard__row{--spacing:1rem;--column-count:2;display:flex;flex-wrap:wrap;margin:0 calc(var(--spacing)*-0.5);align-items:stretch;justify-content:space-between}.presto-dashboard__item{flex:0 1 33.33%;padding:calc(var(--spacing)/3);width:33.33%}.presto-dashboard__item>*{height:100%}.presto-dashboard__item.is-large{flex:1}.presto-dashboard__header{background:#fff;padding:20px;display:flex;align-items:center;justify-content:space-between}.presto-dashboard__logo{max-width:175px}.presto-dashboard__content{margin:25px 0;width:calc(100% - 20px)}.presto-dashboard__body{max-width:800px;margin-left:auto;margin-right:auto}@media(max-width:767px){.presto-dashboard__row{display:block}.presto-dashboard__item{width:100%}}.presto-dashboard__title{line-height:1em}.presto-settings-page-notices.components-snackbar-list{position:fixed!important;left:auto;right:40px;bottom:40px;width:auto}.presto-card__title{opacity:.75;font-size:1rem;clear:both;margin:.75rem 0}.presto-player-dashboard__version{line-height:1;padding:6px 12px;background:#f1f1f1;color:#666;font-weight:500;border-radius:999px}.presto-player-dashboard__header{background:#fff;margin-left:-20px;margin-right:-20px;padding:20px;display:flex;align-items:center;justify-content:space-between;max-width:calc(100% + 20px)}.presto-player-dashboard__logo{max-height:30px;max-width:200px}.presto-module-tabs [role=tablist]{border-bottom:1px solid #e2e4e7}.presto-badge{border-radius:9999px;border:1px solid var(--wp-admin-theme-color,#007cba);color:var(--wp-admin-theme-color,#007cba);padding:5px 10px;line-height:1;white-space:nowrap;display:inline-block}.apexcharts-xaxis text,.apexcharts-yaxis text{opacity:.35}:root{--wp-admin-theme-color:#7c3aed!important;--wp-admin-theme-color-darker-10:#6127c7!important;--wp-admin-theme-color-darker-20:#501ea5!important;--litepickerDayIsInRange:#f3f3f3;--litepicker-container-months-color-bg:#fff;--litepicker-container-months-box-shadow-color:#ddd;--litepicker-footer-color-bg:#fafafa;--litepicker-footer-box-shadow-color:#ddd;--litepicker-tooltip-color-bg:#fff;--litepicker-month-header-color:#333;--litepicker-button-prev-month-color:#9e9e9e;--litepicker-button-next-month-color:#9e9e9e;--litepicker-button-prev-month-color-hover:var(--wp-admin-theme-color,#7c3aed);--litepicker-button-next-month-color-hover:var(--wp-admin-theme-color,#7c3aed);--litepicker-month-width:calc(var(--litepicker-day-width)*7);--litepicker-month-weekday-color:#9e9e9e;--litepicker-month-week-number-color:#9e9e9e;--litepicker-day-width:38px;--litepicker-day-color:#333;--litepicker-day-color-hover:var(--wp-admin-theme-color,#7c3aed);--litepicker-is-today-color:#f44336;--litepicker-is-in-range-color:rgba(124,58,237,0.12156862745098039);--litepicker-is-locked-color:#9e9e9e;--litepicker-is-start-color:#fff;--litepicker-is-start-color-bg:var(--wp-admin-theme-color,#7c3aed);--litepicker-is-end-color:#fff;--litepicker-is-end-color-bg:var(--wp-admin-theme-color,#7c3aed);--litepicker-button-cancel-color:#fff;--litepicker-button-cancel-color-bg:#9e9e9e;--litepicker-button-apply-color:#fff;--litepicker-button-apply-color-bg:var(--wp-admin-theme-color,#7c3aed);--litepicker-button-reset-color:#909090;--litepicker-button-reset-color-hover:var(--wp-admin-theme-color,#7c3aed);--litepicker-highlighted-day-color:#333;--litepicker-highlighted-day-color-bg:#ffeb3b}.presto-player__stat-card{display:flex;align-items:center;justify-content:center;text-align:center}.presto-player__stat-card h1{font-size:3rem;margin-bottom:.4em}.presto-options__pro-badge{margin:0 4px;line-height:1;background:var(--wp-admin-theme-color);color:#fff;padding:3px 6px;border-radius:9999px;font-size:10px;display:inline-block}.presto-options__disabled-overlay{position:absolute;top:0;left:0;right:0;bottom:0;display:flex;align-items:center;justify-self:center;z-index:99}.presto-options__card{position:relative}.litepicker{font-size:1em}.litepicker .container__days>a,.litepicker .container__days>div{margin-bottom:5px}.litepicker .container__footer,.litepicker .container__main .container__predefined-ranges,.litepicker .container__months{border:1px solid #e0e0e0;box-shadow:none;border-radius:0;margin:0}.litepicker .container__main .container__predefined-ranges{margin-right:-1px;padding:16px;max-width:125px;width:125px;border-radius:0}.litepicker .container__main .container__predefined-ranges>div{color:var(--wp-admin-theme-color,#007cba)}.litepicker .container__months .month-item-header div>.month-item-year{padding:0 24px 0 8px}.litepicker .container__footer{margin-top:-1px;padding:8px}.litepicker .container__footer .button-apply,.litepicker .container__footer .button-cancel{display:inline-flex;text-decoration:none;font-size:13px;margin:0;border:0;cursor:pointer;-webkit-appearance:none;background:none;transition:box-shadow .1s linear;height:36px;align-items:center;box-sizing:border-box;padding:6px 12px;border-radius:2px;color:#1e1e1e;white-space:nowrap}.litepicker .container__footer .button-apply{background:#007cba;background:var(--wp-admin-theme-color);color:#fff;text-decoration:none;text-shadow:none}.presto-settings__page{margin:25px 25px 25px auto}.presto-settings__loading{min-height:200px;width:100%;display:flex;align-items:center;justify-content:center}.presto-settings__body .components-card,.presto-settings__setting{max-width:800px}.presto-settings__navigation{margin-left:-20px;margin-right:-20px;padding-right:20px;position:-webkit-sticky;position:sticky;top:32px;z-index:99}@media screen and (max-width:782px){.presto-settings__navigation{top:46px}}.presto-settings .components-snackbar.is-snackbar-error{background:#cc1818}.presto-settings__date-select,.presto-settings__date-select:disabled{padding-right:30px;background:#fff url("data:image/svg+xml;charset=US-ASCII,%3Csvg%20width%3D%2220%22%20height%3D%2220%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M5%206l5%205%205-5%202%201-7%207-7-7%202-1z%22%20fill%3D%22%23555%22%2F%3E%3C%2Fsvg%3E") no-repeat right 5px top 55%;background-size:16px 16px;cursor:pointer;vertical-align:middle;opacity:1;box-shadow:none;color:#444;border-color:#757575;-webkit-user-select:none;user-select:none}.is-color-control{max-width:250px}
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
dist/analytics.js ADDED
@@ -0,0 +1 @@
 
1
+ !function(){var t={5927:function(t,e,i){"use strict";var a;function s(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),i.push.apply(i,a)}return i}function r(t){for(var e=1;e<arguments.length;e++){var i=null!=arguments[e]?arguments[e]:{};e%2?s(Object(i),!0).forEach((function(e){h(t,e,i[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):s(Object(i)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(i,e))}))}return t}function n(t){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},n(t)}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function l(t,e){for(var i=0;i<e.length;i++){var a=e[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(t,a.key,a)}}function c(t,e,i){return e&&l(t.prototype,e),i&&l(t,i),t}function h(t,e,i){return e in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}function d(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&p(t,e)}function u(t){return u=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},u(t)}function p(t,e){return p=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},p(t,e)}function f(t,e){if(e&&("object"==typeof e||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}function g(t){var e=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}();return function(){var i,a=u(t);if(e){var s=u(this).constructor;i=Reflect.construct(a,arguments,s)}else i=a.apply(this,arguments);return f(this,i)}}function x(t){return function(t){if(Array.isArray(t))return b(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||m(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function m(t,e){if(t){if("string"==typeof t)return b(t,e);var i=Object.prototype.toString.call(t).slice(8,-1);return"Object"===i&&t.constructor&&(i=t.constructor.name),"Map"===i||"Set"===i?Array.from(t):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?b(t,e):void 0}}function b(t,e){(null==e||e>t.length)&&(e=t.length);for(var i=0,a=new Array(e);i<e;i++)a[i]=t[i];return a}var v=function(){function t(){o(this,t)}return c(t,[{key:"shadeRGBColor",value:function(t,e){var i=e.split(","),a=t<0?0:255,s=t<0?-1*t:t,r=parseInt(i[0].slice(4),10),n=parseInt(i[1],10),o=parseInt(i[2],10);return"rgb("+(Math.round((a-r)*s)+r)+","+(Math.round((a-n)*s)+n)+","+(Math.round((a-o)*s)+o)+")"}},{key:"shadeHexColor",value:function(t,e){var i=parseInt(e.slice(1),16),a=t<0?0:255,s=t<0?-1*t:t,r=i>>16,n=i>>8&255,o=255&i;return"#"+(16777216+65536*(Math.round((a-r)*s)+r)+256*(Math.round((a-n)*s)+n)+(Math.round((a-o)*s)+o)).toString(16).slice(1)}},{key:"shadeColor",value:function(e,i){return t.isColorHex(i)?this.shadeHexColor(e,i):this.shadeRGBColor(e,i)}}],[{key:"bind",value:function(t,e){return function(){return t.apply(e,arguments)}}},{key:"isObject",value:function(t){return t&&"object"===n(t)&&!Array.isArray(t)&&null!=t}},{key:"is",value:function(t,e){return Object.prototype.toString.call(e)==="[object "+t+"]"}},{key:"listToArray",value:function(t){var e,i=[];for(e=0;e<t.length;e++)i[e]=t[e];return i}},{key:"extend",value:function(t,e){var i=this;"function"!=typeof Object.assign&&(Object.assign=function(t){if(null==t)throw new TypeError("Cannot convert undefined or null to object");for(var e=Object(t),i=1;i<arguments.length;i++){var a=arguments[i];if(null!=a)for(var s in a)a.hasOwnProperty(s)&&(e[s]=a[s])}return e});var a=Object.assign({},t);return this.isObject(t)&&this.isObject(e)&&Object.keys(e).forEach((function(s){i.isObject(e[s])&&s in t?a[s]=i.extend(t[s],e[s]):Object.assign(a,h({},s,e[s]))})),a}},{key:"extendArray",value:function(e,i){var a=[];return e.map((function(e){a.push(t.extend(i,e))})),a}},{key:"monthMod",value:function(t){return t%12}},{key:"clone",value:function(e){if(t.is("Array",e)){for(var i=[],a=0;a<e.length;a++)i[a]=this.clone(e[a]);return i}if(t.is("Null",e))return null;if(t.is("Date",e))return e;if("object"===n(e)){var s={};for(var r in e)e.hasOwnProperty(r)&&(s[r]=this.clone(e[r]));return s}return e}},{key:"log10",value:function(t){return Math.log(t)/Math.LN10}},{key:"roundToBase10",value:function(t){return Math.pow(10,Math.floor(Math.log10(t)))}},{key:"roundToBase",value:function(t,e){return Math.pow(e,Math.floor(Math.log(t)/Math.log(e)))}},{key:"parseNumber",value:function(t){return null===t?t:parseFloat(t)}},{key:"randomId",value:function(){return(Math.random()+1).toString(36).substring(4)}},{key:"noExponents",value:function(t){var e=String(t).split(/[eE]/);if(1===e.length)return e[0];var i="",a=t<0?"-":"",s=e[0].replace(".",""),r=Number(e[1])+1;if(r<0){for(i=a+"0.";r++;)i+="0";return i+s.replace(/^-/,"")}for(r-=s.length;r--;)i+="0";return s+i}},{key:"getDimensions",value:function(t){var e=getComputedStyle(t,null),i=t.clientHeight,a=t.clientWidth;return i-=parseFloat(e.paddingTop)+parseFloat(e.paddingBottom),[a-=parseFloat(e.paddingLeft)+parseFloat(e.paddingRight),i]}},{key:"getBoundingClientRect",value:function(t){var e=t.getBoundingClientRect();return{top:e.top,right:e.right,bottom:e.bottom,left:e.left,width:t.clientWidth,height:t.clientHeight,x:e.left,y:e.top}}},{key:"getLargestStringFromArr",value:function(t){return t.reduce((function(t,e){return Array.isArray(e)&&(e=e.reduce((function(t,e){return t.length>e.length?t:e}))),t.length>e.length?t:e}),0)}},{key:"hexToRgba",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"#999999",e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:.6;"#"!==t.substring(0,1)&&(t="#999999");var i=t.replace("#","");i=i.match(new RegExp("(.{"+i.length/3+"})","g"));for(var a=0;a<i.length;a++)i[a]=parseInt(1===i[a].length?i[a]+i[a]:i[a],16);return void 0!==e&&i.push(e),"rgba("+i.join(",")+")"}},{key:"getOpacityFromRGBA",value:function(t){return parseFloat(t.replace(/^.*,(.+)\)/,"$1"))}},{key:"rgb2hex",value:function(t){return(t=t.match(/^rgba?[\s+]?\([\s+]?(\d+)[\s+]?,[\s+]?(\d+)[\s+]?,[\s+]?(\d+)[\s+]?/i))&&4===t.length?"#"+("0"+parseInt(t[1],10).toString(16)).slice(-2)+("0"+parseInt(t[2],10).toString(16)).slice(-2)+("0"+parseInt(t[3],10).toString(16)).slice(-2):""}},{key:"isColorHex",value:function(t){return/(^#[0-9A-F]{6}$)|(^#[0-9A-F]{3}$)|(^#[0-9A-F]{8}$)/i.test(t)}},{key:"getPolygonPos",value:function(t,e){for(var i=[],a=2*Math.PI/e,s=0;s<e;s++){var r={};r.x=t*Math.sin(s*a),r.y=-t*Math.cos(s*a),i.push(r)}return i}},{key:"polarToCartesian",value:function(t,e,i,a){var s=(a-90)*Math.PI/180;return{x:t+i*Math.cos(s),y:e+i*Math.sin(s)}}},{key:"escapeString",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"x",i=t.toString().slice();return i.replace(/[` ~!@#$%^&*()|+\=?;:'",.<>{}[\]\\/]/gi,e)}},{key:"negToZero",value:function(t){return t<0?0:t}},{key:"moveIndexInArray",value:function(t,e,i){if(i>=t.length)for(var a=i-t.length+1;a--;)t.push(void 0);return t.splice(i,0,t.splice(e,1)[0]),t}},{key:"extractNumber",value:function(t){return parseFloat(t.replace(/[^\d.]*/g,""))}},{key:"findAncestor",value:function(t,e){for(;(t=t.parentElement)&&!t.classList.contains(e););return t}},{key:"setELstyles",value:function(t,e){for(var i in e)e.hasOwnProperty(i)&&(t.style.key=e[i])}},{key:"isNumber",value:function(t){return!isNaN(t)&&parseFloat(Number(t))===t&&!isNaN(parseInt(t,10))}},{key:"isFloat",value:function(t){return Number(t)===t&&t%1!=0}},{key:"isSafari",value:function(){return/^((?!chrome|android).)*safari/i.test(navigator.userAgent)}},{key:"isFirefox",value:function(){return navigator.userAgent.toLowerCase().indexOf("firefox")>-1}},{key:"isIE11",value:function(){if(-1!==window.navigator.userAgent.indexOf("MSIE")||window.navigator.appVersion.indexOf("Trident/")>-1)return!0}},{key:"isIE",value:function(){var t=window.navigator.userAgent,e=t.indexOf("MSIE ");if(e>0)return parseInt(t.substring(e+5,t.indexOf(".",e)),10);if(t.indexOf("Trident/")>0){var i=t.indexOf("rv:");return parseInt(t.substring(i+3,t.indexOf(".",i)),10)}var a=t.indexOf("Edge/");return a>0&&parseInt(t.substring(a+5,t.indexOf(".",a)),10)}}]),t}(),y=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w,this.setEasingFunctions()}return c(t,[{key:"setEasingFunctions",value:function(){var t;if(!this.w.globals.easing){switch(this.w.config.chart.animations.easing){case"linear":t="-";break;case"easein":t="<";break;case"easeout":t=">";break;case"easeinout":default:t="<>";break;case"swing":t=function(t){var e=1.70158;return(t-=1)*t*((e+1)*t+e)+1};break;case"bounce":t=function(t){return t<1/2.75?7.5625*t*t:t<2/2.75?7.5625*(t-=1.5/2.75)*t+.75:t<2.5/2.75?7.5625*(t-=2.25/2.75)*t+.9375:7.5625*(t-=2.625/2.75)*t+.984375};break;case"elastic":t=function(t){return t===!!t?t:Math.pow(2,-10*t)*Math.sin((t-.075)*(2*Math.PI)/.3)+1}}this.w.globals.easing=t}}},{key:"animateLine",value:function(t,e,i,a){t.attr(e).animate(a).attr(i)}},{key:"animateMarker",value:function(t,e,i,a,s,r){e||(e=0),t.attr({r:e,width:e,height:e}).animate(a,s).attr({r:i,width:i.width,height:i.height}).afterAll((function(){r()}))}},{key:"animateCircle",value:function(t,e,i,a,s){t.attr({r:e.r,cx:e.cx,cy:e.cy}).animate(a,s).attr({r:i.r,cx:i.cx,cy:i.cy})}},{key:"animateRect",value:function(t,e,i,a,s){t.attr(e).animate(a).attr(i).afterAll((function(){return s()}))}},{key:"animatePathsGradually",value:function(t){var e=t.el,i=t.realIndex,a=t.j,s=t.fill,r=t.pathFrom,n=t.pathTo,o=t.speed,l=t.delay,c=this.w,h=0;c.config.chart.animations.animateGradually.enabled&&(h=c.config.chart.animations.animateGradually.delay),c.config.chart.animations.dynamicAnimation.enabled&&c.globals.dataChanged&&"bar"!==c.config.chart.type&&(h=0),this.morphSVG(e,i,a,"line"!==c.config.chart.type||c.globals.comboCharts?s:"stroke",r,n,o,l*h)}},{key:"showDelayedElements",value:function(){this.w.globals.delayedElements.forEach((function(t){t.el.classList.remove("apexcharts-element-hidden")}))}},{key:"animationCompleted",value:function(t){var e=this.w;e.globals.animationEnded||(e.globals.animationEnded=!0,this.showDelayedElements(),"function"==typeof e.config.chart.events.animationEnd&&e.config.chart.events.animationEnd(this.ctx,{el:t,w:e}))}},{key:"morphSVG",value:function(t,e,i,a,s,r,n,o){var l=this,c=this.w;s||(s=t.attr("pathFrom")),r||(r=t.attr("pathTo"));var h=function(t){return"radar"===c.config.chart.type&&(n=1),"M 0 ".concat(c.globals.gridHeight)};(!s||s.indexOf("undefined")>-1||s.indexOf("NaN")>-1)&&(s=h()),(!r||r.indexOf("undefined")>-1||r.indexOf("NaN")>-1)&&(r=h()),c.globals.shouldAnimate||(n=1),t.plot(s).animate(1,c.globals.easing,o).plot(s).animate(n,c.globals.easing,o).plot(r).afterAll((function(){v.isNumber(i)?i===c.globals.series[c.globals.maxValsInArrayIndex].length-2&&c.globals.shouldAnimate&&l.animationCompleted(t):"none"!==a&&c.globals.shouldAnimate&&(!c.globals.comboCharts&&e===c.globals.series.length-1||c.globals.comboCharts)&&l.animationCompleted(t),l.showDelayedElements()}))}}]),t}(),w=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w}return c(t,[{key:"getDefaultFilter",value:function(t,e){var i=this.w;t.unfilter(!0),(new window.SVG.Filter).size("120%","180%","-5%","-40%"),"none"!==i.config.states.normal.filter?this.applyFilter(t,e,i.config.states.normal.filter.type,i.config.states.normal.filter.value):i.config.chart.dropShadow.enabled&&this.dropShadow(t,i.config.chart.dropShadow,e)}},{key:"addNormalFilter",value:function(t,e){var i=this.w;i.config.chart.dropShadow.enabled&&!t.node.classList.contains("apexcharts-marker")&&this.dropShadow(t,i.config.chart.dropShadow,e)}},{key:"addLightenFilter",value:function(t,e,i){var a=this,s=this.w,r=i.intensity;t.unfilter(!0),new window.SVG.Filter,t.filter((function(t){var i=s.config.chart.dropShadow;(i.enabled?a.addShadow(t,e,i):t).componentTransfer({rgb:{type:"linear",slope:1.5,intercept:r}})})),t.filterer.node.setAttribute("filterUnits","userSpaceOnUse"),this._scaleFilterSize(t.filterer.node)}},{key:"addDarkenFilter",value:function(t,e,i){var a=this,s=this.w,r=i.intensity;t.unfilter(!0),new window.SVG.Filter,t.filter((function(t){var i=s.config.chart.dropShadow;(i.enabled?a.addShadow(t,e,i):t).componentTransfer({rgb:{type:"linear",slope:r}})})),t.filterer.node.setAttribute("filterUnits","userSpaceOnUse"),this._scaleFilterSize(t.filterer.node)}},{key:"applyFilter",value:function(t,e,i){var a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:.5;switch(i){case"none":this.addNormalFilter(t,e);break;case"lighten":this.addLightenFilter(t,e,{intensity:a});break;case"darken":this.addDarkenFilter(t,e,{intensity:a})}}},{key:"addShadow",value:function(t,e,i){var a=i.blur,s=i.top,r=i.left,n=i.color,o=i.opacity,l=t.flood(Array.isArray(n)?n[e]:n,o).composite(t.sourceAlpha,"in").offset(r,s).gaussianBlur(a).merge(t.source);return t.blend(t.source,l)}},{key:"dropShadow",value:function(t,e){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,a=e.top,s=e.left,r=e.blur,n=e.color,o=e.opacity,l=e.noUserSpaceOnUse,c=this.w;return t.unfilter(!0),v.isIE()&&"radialBar"===c.config.chart.type||(n=Array.isArray(n)?n[i]:n,t.filter((function(t){var e;e=v.isSafari()||v.isFirefox()||v.isIE()?t.flood(n,o).composite(t.sourceAlpha,"in").offset(s,a).gaussianBlur(r):t.flood(n,o).composite(t.sourceAlpha,"in").offset(s,a).gaussianBlur(r).merge(t.source),t.blend(t.source,e)})),l||t.filterer.node.setAttribute("filterUnits","userSpaceOnUse"),this._scaleFilterSize(t.filterer.node)),t}},{key:"setSelectionFilter",value:function(t,e,i){var a=this.w;if(void 0!==a.globals.selectedDataPoints[e]&&a.globals.selectedDataPoints[e].indexOf(i)>-1){t.node.setAttribute("selected",!0);var s=a.config.states.active.filter;"none"!==s&&this.applyFilter(t,e,s.type,s.value)}}},{key:"_scaleFilterSize",value:function(t){!function(e){for(var i in e)e.hasOwnProperty(i)&&t.setAttribute(i,e[i])}({width:"200%",height:"200%",x:"-50%",y:"-50%"})}}]),t}(),k=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w}return c(t,[{key:"roundPathCorners",value:function(t,e){function i(t,e,i){var s=e.x-t.x,r=e.y-t.y,n=Math.sqrt(s*s+r*r);return a(t,e,Math.min(1,i/n))}function a(t,e,i){return{x:t.x+(e.x-t.x)*i,y:t.y+(e.y-t.y)*i}}function s(t,e){t.length>2&&(t[t.length-2]=e.x,t[t.length-1]=e.y)}function r(t){return{x:parseFloat(t[t.length-2]),y:parseFloat(t[t.length-1])}}var n=t.split(/[,\s]/).reduce((function(t,e){var i=e.match("([a-zA-Z])(.+)");return i?(t.push(i[1]),t.push(i[2])):t.push(e),t}),[]).reduce((function(t,e){return parseFloat(e)==e&&t.length?t[t.length-1].push(e):t.push([e]),t}),[]),o=[];if(n.length>1){var l=r(n[0]),c=null;"Z"==n[n.length-1][0]&&n[0].length>2&&(c=["L",l.x,l.y],n[n.length-1]=c),o.push(n[0]);for(var h=1;h<n.length;h++){var d=o[o.length-1],u=n[h],p=u==c?n[1]:n[h+1];if(p&&d&&d.length>2&&"L"==u[0]&&p.length>2&&"L"==p[0]){var f,g,x=r(d),m=r(u),b=r(p);f=i(m,x,e),g=i(m,b,e),s(u,f),u.origPoint=m,o.push(u);var v=a(f,m,.5),y=a(m,g,.5),w=["C",v.x,v.y,y.x,y.y,g.x,g.y];w.origPoint=m,o.push(w)}else o.push(u)}if(c){var k=r(o[o.length-1]);o.push(["Z"]),s(o[0],k)}}else o=n;return o.reduce((function(t,e){return t+e.join(" ")+" "}),"")}},{key:"drawLine",value:function(t,e,i,a){var s=arguments.length>4&&void 0!==arguments[4]?arguments[4]:"#a8a8a8",r=arguments.length>5&&void 0!==arguments[5]?arguments[5]:0,n=arguments.length>6&&void 0!==arguments[6]?arguments[6]:null,o=arguments.length>7&&void 0!==arguments[7]?arguments[7]:"butt",l=this.w,c=l.globals.dom.Paper.line().attr({x1:t,y1:e,x2:i,y2:a,stroke:s,"stroke-dasharray":r,"stroke-width":n,"stroke-linecap":o});return c}},{key:"drawRect",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,s=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0,r=arguments.length>5&&void 0!==arguments[5]?arguments[5]:"#fefefe",n=arguments.length>6&&void 0!==arguments[6]?arguments[6]:1,o=arguments.length>7&&void 0!==arguments[7]?arguments[7]:null,l=arguments.length>8&&void 0!==arguments[8]?arguments[8]:null,c=arguments.length>9&&void 0!==arguments[9]?arguments[9]:0,h=this.w,d=h.globals.dom.Paper.rect();return d.attr({x:t,y:e,width:i>0?i:0,height:a>0?a:0,rx:s,ry:s,opacity:n,"stroke-width":null!==o?o:0,stroke:null!==l?l:"none","stroke-dasharray":c}),d.node.setAttribute("fill",r),d}},{key:"drawPolygon",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"#e1e1e1",i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"none",s=this.w,r=s.globals.dom.Paper.polygon(t).attr({fill:a,stroke:e,"stroke-width":i});return r}},{key:"drawCircle",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,i=this.w;t<0&&(t=0);var a=i.globals.dom.Paper.circle(2*t);return null!==e&&a.attr(e),a}},{key:"drawPath",value:function(t){var e=t.d,i=void 0===e?"":e,a=t.stroke,s=void 0===a?"#a8a8a8":a,r=t.strokeWidth,n=void 0===r?1:r,o=t.fill,l=t.fillOpacity,c=void 0===l?1:l,h=t.strokeOpacity,d=void 0===h?1:h,u=t.classes,p=t.strokeLinecap,f=void 0===p?null:p,g=t.strokeDashArray,x=void 0===g?0:g,m=this.w;return null===f&&(f=m.config.stroke.lineCap),(i.indexOf("undefined")>-1||i.indexOf("NaN")>-1)&&(i="M 0 ".concat(m.globals.gridHeight)),m.globals.dom.Paper.path(i).attr({fill:o,"fill-opacity":c,stroke:s,"stroke-opacity":d,"stroke-linecap":f,"stroke-width":n,"stroke-dasharray":x,class:u})}},{key:"group",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,e=this.w,i=e.globals.dom.Paper.group();return null!==t&&i.attr(t),i}},{key:"move",value:function(t,e){return["M",t,e].join(" ")}},{key:"line",value:function(t,e){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,a=null;return null===i?a=[" L",t,e].join(" "):"H"===i?a=[" H",t].join(" "):"V"===i&&(a=[" V",e].join(" ")),a}},{key:"curve",value:function(t,e,i,a,s,r){return["C",t,e,i,a,s,r].join(" ")}},{key:"quadraticCurve",value:function(t,e,i,a){return["Q",t,e,i,a].join(" ")}},{key:"arc",value:function(t,e,i,a,s,r,n){var o=arguments.length>7&&void 0!==arguments[7]&&arguments[7],l="A";o&&(l="a");var c=[l,t,e,i,a,s,r,n].join(" ");return c}},{key:"renderPaths",value:function(t){var e,i=t.j,a=t.realIndex,s=t.pathFrom,n=t.pathTo,o=t.stroke,l=t.strokeWidth,c=t.strokeLinecap,h=t.fill,d=t.animationDelay,u=t.initialSpeed,p=t.dataChangeSpeed,f=t.className,g=t.shouldClipToGrid,x=void 0===g||g,m=t.bindEventsOnPaths,b=void 0===m||m,v=t.drawShadow,k=void 0===v||v,A=this.w,S=new w(this.ctx),C=new y(this.ctx),P=this.w.config.chart.animations.enabled,L=P&&this.w.config.chart.animations.dynamicAnimation.enabled,D=!!(P&&!A.globals.resized||L&&A.globals.dataChanged&&A.globals.shouldAnimate);D?e=s:(e=n,A.globals.animationEnded=!0);var T,M=A.config.stroke.dashArray;T=Array.isArray(M)?M[a]:A.config.stroke.dashArray;var E=this.drawPath({d:e,stroke:o,strokeWidth:l,fill:h,fillOpacity:1,classes:f,strokeLinecap:c,strokeDashArray:T});if(E.attr("index",a),x&&E.attr({"clip-path":"url(#gridRectMask".concat(A.globals.cuid,")")}),"none"!==A.config.states.normal.filter.type)S.getDefaultFilter(E,a);else if(A.config.chart.dropShadow.enabled&&k&&(!A.config.chart.dropShadow.enabledOnSeries||A.config.chart.dropShadow.enabledOnSeries&&-1!==A.config.chart.dropShadow.enabledOnSeries.indexOf(a))){var I=A.config.chart.dropShadow;S.dropShadow(E,I,a)}b&&(E.node.addEventListener("mouseenter",this.pathMouseEnter.bind(this,E)),E.node.addEventListener("mouseleave",this.pathMouseLeave.bind(this,E)),E.node.addEventListener("mousedown",this.pathMouseDown.bind(this,E))),E.attr({pathTo:n,pathFrom:s});var O={el:E,j:i,realIndex:a,pathFrom:s,pathTo:n,fill:h,strokeWidth:l,delay:d};return!P||A.globals.resized||A.globals.dataChanged?!A.globals.resized&&A.globals.dataChanged||C.showDelayedElements():C.animatePathsGradually(r(r({},O),{},{speed:u})),A.globals.dataChanged&&L&&D&&C.animatePathsGradually(r(r({},O),{},{speed:p})),E}},{key:"drawPattern",value:function(t,e,i){var a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"#a8a8a8",s=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0,r=this.w,n=r.globals.dom.Paper.pattern(e,i,(function(r){"horizontalLines"===t?r.line(0,0,i,0).stroke({color:a,width:s+1}):"verticalLines"===t?r.line(0,0,0,e).stroke({color:a,width:s+1}):"slantedLines"===t?r.line(0,0,e,i).stroke({color:a,width:s}):"squares"===t?r.rect(e,i).fill("none").stroke({color:a,width:s}):"circles"===t&&r.circle(e).fill("none").stroke({color:a,width:s})}));return n}},{key:"drawGradient",value:function(t,e,i,a,s){var r,n=arguments.length>5&&void 0!==arguments[5]?arguments[5]:null,o=arguments.length>6&&void 0!==arguments[6]?arguments[6]:null,l=arguments.length>7&&void 0!==arguments[7]?arguments[7]:null,c=arguments.length>8&&void 0!==arguments[8]?arguments[8]:0,h=this.w;e.length<9&&0===e.indexOf("#")&&(e=v.hexToRgba(e,a)),i.length<9&&0===i.indexOf("#")&&(i=v.hexToRgba(i,s));var d=0,u=1,p=1,f=null;null!==o&&(d=void 0!==o[0]?o[0]/100:0,u=void 0!==o[1]?o[1]/100:1,p=void 0!==o[2]?o[2]/100:1,f=void 0!==o[3]?o[3]/100:null);var g=!("donut"!==h.config.chart.type&&"pie"!==h.config.chart.type&&"polarArea"!==h.config.chart.type&&"bubble"!==h.config.chart.type);if(r=null===l||0===l.length?h.globals.dom.Paper.gradient(g?"radial":"linear",(function(t){t.at(d,e,a),t.at(u,i,s),t.at(p,i,s),null!==f&&t.at(f,e,a)})):h.globals.dom.Paper.gradient(g?"radial":"linear",(function(t){(Array.isArray(l[c])?l[c]:l).forEach((function(e){t.at(e.offset/100,e.color,e.opacity)}))})),g){var x=h.globals.gridWidth/2,m=h.globals.gridHeight/2;"bubble"!==h.config.chart.type?r.attr({gradientUnits:"userSpaceOnUse",cx:x,cy:m,r:n}):r.attr({cx:.5,cy:.5,r:.8,fx:.2,fy:.2})}else"vertical"===t?r.from(0,0).to(0,1):"diagonal"===t?r.from(0,0).to(1,1):"horizontal"===t?r.from(0,1).to(1,1):"diagonal2"===t&&r.from(1,0).to(0,1);return r}},{key:"getTextBasedOnMaxWidth",value:function(t){var e=t.text,i=t.maxWidth,a=t.fontSize,s=t.fontFamily,r=this.getTextRects(e,a,s),n=r.width/e.length,o=Math.floor(i/n);return i<r.width?e.slice(0,o-3)+"...":e}},{key:"drawText",value:function(t){var e=this,i=t.x,a=t.y,s=t.text,n=t.textAnchor,o=t.fontSize,l=t.fontFamily,c=t.fontWeight,h=t.foreColor,d=t.opacity,u=t.maxWidth,p=t.cssClass,f=void 0===p?"":p,g=t.isPlainText,x=void 0===g||g,m=this.w;void 0===s&&(s="");var b=s;n||(n="start"),h&&h.length||(h=m.config.chart.foreColor),l=l||m.config.chart.fontFamily,c=c||"regular";var v,y={maxWidth:u,fontSize:o=o||"11px",fontFamily:l};return Array.isArray(s)?v=m.globals.dom.Paper.text((function(t){for(var i=0;i<s.length;i++)b=s[i],u&&(b=e.getTextBasedOnMaxWidth(r({text:s[i]},y))),0===i?t.tspan(b):t.tspan(b).newLine()})):(u&&(b=this.getTextBasedOnMaxWidth(r({text:s},y))),v=x?m.globals.dom.Paper.plain(s):m.globals.dom.Paper.text((function(t){return t.tspan(b)}))),v.attr({x:i,y:a,"text-anchor":n,"dominant-baseline":"auto","font-size":o,"font-family":l,"font-weight":c,fill:h,class:"apexcharts-text "+f}),v.node.style.fontFamily=l,v.node.style.opacity=d,v}},{key:"drawMarker",value:function(t,e,i){t=t||0;var a=i.pSize||0,s=null;if("square"===i.shape||"rect"===i.shape){var r=void 0===i.pRadius?a/2:i.pRadius;null!==e&&a||(a=0,r=0);var n=1.2*a+r,o=this.drawRect(n,n,n,n,r);o.attr({x:t-n/2,y:e-n/2,cx:t,cy:e,class:i.class?i.class:"",fill:i.pointFillColor,"fill-opacity":i.pointFillOpacity?i.pointFillOpacity:1,stroke:i.pointStrokeColor,"stroke-width":i.pointStrokeWidth?i.pointStrokeWidth:0,"stroke-opacity":i.pointStrokeOpacity?i.pointStrokeOpacity:1}),s=o}else"circle"!==i.shape&&i.shape||(v.isNumber(e)||(a=0,e=0),s=this.drawCircle(a,{cx:t,cy:e,class:i.class?i.class:"",stroke:i.pointStrokeColor,fill:i.pointFillColor,"fill-opacity":i.pointFillOpacity?i.pointFillOpacity:1,"stroke-width":i.pointStrokeWidth?i.pointStrokeWidth:0,"stroke-opacity":i.pointStrokeOpacity?i.pointStrokeOpacity:1}));return s}},{key:"pathMouseEnter",value:function(t,e){var i=this.w,a=new w(this.ctx),s=parseInt(t.node.getAttribute("index"),10),r=parseInt(t.node.getAttribute("j"),10);if("function"==typeof i.config.chart.events.dataPointMouseEnter&&i.config.chart.events.dataPointMouseEnter(e,this.ctx,{seriesIndex:s,dataPointIndex:r,w:i}),this.ctx.events.fireEvent("dataPointMouseEnter",[e,this.ctx,{seriesIndex:s,dataPointIndex:r,w:i}]),("none"===i.config.states.active.filter.type||"true"!==t.node.getAttribute("selected"))&&"none"!==i.config.states.hover.filter.type&&!i.globals.isTouchDevice){var n=i.config.states.hover.filter;a.applyFilter(t,s,n.type,n.value)}}},{key:"pathMouseLeave",value:function(t,e){var i=this.w,a=new w(this.ctx),s=parseInt(t.node.getAttribute("index"),10),r=parseInt(t.node.getAttribute("j"),10);"function"==typeof i.config.chart.events.dataPointMouseLeave&&i.config.chart.events.dataPointMouseLeave(e,this.ctx,{seriesIndex:s,dataPointIndex:r,w:i}),this.ctx.events.fireEvent("dataPointMouseLeave",[e,this.ctx,{seriesIndex:s,dataPointIndex:r,w:i}]),"none"!==i.config.states.active.filter.type&&"true"===t.node.getAttribute("selected")||"none"!==i.config.states.hover.filter.type&&a.getDefaultFilter(t,s)}},{key:"pathMouseDown",value:function(t,e){var i=this.w,a=new w(this.ctx),s=parseInt(t.node.getAttribute("index"),10),r=parseInt(t.node.getAttribute("j"),10),n="false";if("true"===t.node.getAttribute("selected")){if(t.node.setAttribute("selected","false"),i.globals.selectedDataPoints[s].indexOf(r)>-1){var o=i.globals.selectedDataPoints[s].indexOf(r);i.globals.selectedDataPoints[s].splice(o,1)}}else{if(!i.config.states.active.allowMultipleDataPointsSelection&&i.globals.selectedDataPoints.length>0){i.globals.selectedDataPoints=[];var l=i.globals.dom.Paper.select(".apexcharts-series path").members,c=i.globals.dom.Paper.select(".apexcharts-series circle, .apexcharts-series rect").members,h=function(t){Array.prototype.forEach.call(t,(function(t){t.node.setAttribute("selected","false"),a.getDefaultFilter(t,s)}))};h(l),h(c)}t.node.setAttribute("selected","true"),n="true",void 0===i.globals.selectedDataPoints[s]&&(i.globals.selectedDataPoints[s]=[]),i.globals.selectedDataPoints[s].push(r)}if("true"===n){var d=i.config.states.active.filter;if("none"!==d)a.applyFilter(t,s,d.type,d.value);else if("none"!==i.config.states.hover.filter&&!i.globals.isTouchDevice){var u=i.config.states.hover.filter;a.applyFilter(t,s,u.type,u.value)}}else"none"!==i.config.states.active.filter.type&&("none"===i.config.states.hover.filter.type||i.globals.isTouchDevice?a.getDefaultFilter(t,s):(u=i.config.states.hover.filter,a.applyFilter(t,s,u.type,u.value)));"function"==typeof i.config.chart.events.dataPointSelection&&i.config.chart.events.dataPointSelection(e,this.ctx,{selectedDataPoints:i.globals.selectedDataPoints,seriesIndex:s,dataPointIndex:r,w:i}),e&&this.ctx.events.fireEvent("dataPointSelection",[e,this.ctx,{selectedDataPoints:i.globals.selectedDataPoints,seriesIndex:s,dataPointIndex:r,w:i}])}},{key:"rotateAroundCenter",value:function(t){var e={};return t&&"function"==typeof t.getBBox&&(e=t.getBBox()),{x:e.x+e.width/2,y:e.y+e.height/2}}},{key:"getTextRects",value:function(t,e,i,a){var s=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],r=this.w,n=this.drawText({x:-200,y:-200,text:t,textAnchor:"start",fontSize:e,fontFamily:i,foreColor:"#fff",opacity:0});a&&n.attr("transform",a),r.globals.dom.Paper.add(n);var o=n.bbox();return s||(o=n.node.getBoundingClientRect()),n.remove(),{width:o.width,height:o.height}}},{key:"placeTextWithEllipsis",value:function(t,e,i){if("function"==typeof t.getComputedTextLength&&(t.textContent=e,e.length>0&&t.getComputedTextLength()>=i/1.1)){for(var a=e.length-3;a>0;a-=3)if(t.getSubStringLength(0,a)<=i/1.1)return void(t.textContent=e.substring(0,a)+"...");t.textContent="."}}}],[{key:"setAttrs",value:function(t,e){for(var i in e)e.hasOwnProperty(i)&&t.setAttribute(i,e[i])}}]),t}(),A=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w}return c(t,[{key:"getStackedSeriesTotals",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],e=this.w,i=[];if(0===e.globals.series.length)return i;for(var a=0;a<e.globals.series[e.globals.maxValsInArrayIndex].length;a++){for(var s=0,r=0;r<e.globals.series.length;r++)void 0!==e.globals.series[r][a]&&-1===t.indexOf(r)&&(s+=e.globals.series[r][a]);i.push(s)}return i}},{key:"getSeriesTotalByIndex",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;return null===t?this.w.config.series.reduce((function(t,e){return t+e}),0):this.w.globals.series[t].reduce((function(t,e){return t+e}),0)}},{key:"isSeriesNull",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;return 0===(null===t?this.w.config.series.filter((function(t){return null!==t})):this.w.config.series[t].data.filter((function(t){return null!==t}))).length}},{key:"seriesHaveSameValues",value:function(t){return this.w.globals.series[t].every((function(t,e,i){return t===i[0]}))}},{key:"getCategoryLabels",value:function(t){var e=this.w,i=t.slice();return e.config.xaxis.convertedCatToNumeric&&(i=t.map((function(t,i){return e.config.xaxis.labels.formatter(t-e.globals.minX+1)}))),i}},{key:"getLargestSeries",value:function(){var t=this.w;t.globals.maxValsInArrayIndex=t.globals.series.map((function(t){return t.length})).indexOf(Math.max.apply(Math,t.globals.series.map((function(t){return t.length}))))}},{key:"getLargestMarkerSize",value:function(){var t=this.w,e=0;return t.globals.markers.size.forEach((function(t){e=Math.max(e,t)})),t.config.markers.discrete&&t.config.markers.discrete.length&&t.config.markers.discrete.forEach((function(t){e=Math.max(e,t.size)})),e>0&&(e+=t.config.markers.hover.sizeOffset+1),t.globals.markers.largestSize=e,e}},{key:"getSeriesTotals",value:function(){var t=this.w;t.globals.seriesTotals=t.globals.series.map((function(t,e){var i=0;if(Array.isArray(t))for(var a=0;a<t.length;a++)i+=t[a];else i+=t;return i}))}},{key:"getSeriesTotalsXRange",value:function(t,e){var i=this.w;return i.globals.series.map((function(a,s){for(var r=0,n=0;n<a.length;n++)i.globals.seriesX[s][n]>t&&i.globals.seriesX[s][n]<e&&(r+=a[n]);return r}))}},{key:"getPercentSeries",value:function(){var t=this.w;t.globals.seriesPercent=t.globals.series.map((function(e,i){var a=[];if(Array.isArray(e))for(var s=0;s<e.length;s++){var r=t.globals.stackedSeriesTotals[s],n=0;r&&(n=100*e[s]/r),a.push(n)}else{var o=100*e/t.globals.seriesTotals.reduce((function(t,e){return t+e}),0);a.push(o)}return a}))}},{key:"getCalculatedRatios",value:function(){var t,e,i,a,s=this.w.globals,r=[],n=0,o=[],l=.1,c=0;if(s.yRange=[],s.isMultipleYAxis)for(var h=0;h<s.minYArr.length;h++)s.yRange.push(Math.abs(s.minYArr[h]-s.maxYArr[h])),o.push(0);else s.yRange.push(Math.abs(s.minY-s.maxY));s.xRange=Math.abs(s.maxX-s.minX),s.zRange=Math.abs(s.maxZ-s.minZ);for(var d=0;d<s.yRange.length;d++)r.push(s.yRange[d]/s.gridHeight);if(e=s.xRange/s.gridWidth,i=Math.abs(s.initialMaxX-s.initialMinX)/s.gridWidth,t=s.yRange/s.gridWidth,a=s.xRange/s.gridHeight,(n=s.zRange/s.gridHeight*16)||(n=1),s.minY!==Number.MIN_VALUE&&0!==Math.abs(s.minY)&&(s.hasNegs=!0),s.isMultipleYAxis){o=[];for(var u=0;u<r.length;u++)o.push(-s.minYArr[u]/r[u])}else o.push(-s.minY/r[0]),s.minY!==Number.MIN_VALUE&&0!==Math.abs(s.minY)&&(l=-s.minY/t,c=s.minX/e);return{yRatio:r,invertedYRatio:t,zRatio:n,xRatio:e,initialXRatio:i,invertedXRatio:a,baseLineInvertedY:l,baseLineY:o,baseLineX:c}}},{key:"getLogSeries",value:function(t){var e=this,i=this.w;return i.globals.seriesLog=t.map((function(t,a){return i.config.yaxis[a]&&i.config.yaxis[a].logarithmic?t.map((function(t){return null===t?null:e.getLogVal(i.config.yaxis[a].logBase,t,a)})):t})),i.globals.invalidLogScale?t:i.globals.seriesLog}},{key:"getBaseLog",value:function(t,e){return Math.log(e)/Math.log(t)}},{key:"getLogVal",value:function(t,e,i){if(0===e)return 0;var a=this.w,s=0===a.globals.minYArr[i]?-1:this.getBaseLog(t,a.globals.minYArr[i]),r=(0===a.globals.maxYArr[i]?0:this.getBaseLog(t,a.globals.maxYArr[i]))-s;return e<1?e/r:(this.getBaseLog(t,e)-s)/r}},{key:"getLogYRatios",value:function(t){var e=this,i=this.w,a=this.w.globals;return a.yLogRatio=t.slice(),a.logYRange=a.yRange.map((function(t,s){if(i.config.yaxis[s]&&e.w.config.yaxis[s].logarithmic){var r,n=-Number.MAX_VALUE,o=Number.MIN_VALUE;return a.seriesLog.forEach((function(t,e){t.forEach((function(t){i.config.yaxis[e]&&i.config.yaxis[e].logarithmic&&(n=Math.max(t,n),o=Math.min(t,o))}))})),r=Math.pow(a.yRange[s],Math.abs(o-n)/a.yRange[s]),a.yLogRatio[s]=r/a.gridHeight,r}})),a.invalidLogScale?t.slice():a.yLogRatio}}],[{key:"checkComboSeries",value:function(t){var e=!1,i=0,a=0;return t.length&&void 0!==t[0].type&&t.forEach((function(t){"bar"!==t.type&&"column"!==t.type&&"candlestick"!==t.type&&"boxPlot"!==t.type||i++,void 0!==t.type&&a++})),a>0&&(e=!0),{comboBarCount:i,comboCharts:e}}},{key:"extendArrayProps",value:function(t,e,i){return e.yaxis&&(e=t.extendYAxis(e,i)),e.annotations&&(e.annotations.yaxis&&(e=t.extendYAxisAnnotations(e)),e.annotations.xaxis&&(e=t.extendXAxisAnnotations(e)),e.annotations.points&&(e=t.extendPointAnnotations(e))),e}}]),t}(),S=function(){function t(e){o(this,t),this.w=e.w,this.annoCtx=e}return c(t,[{key:"setOrientations",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,i=this.w;if("vertical"===t.label.orientation){var a=null!==e?e:0,s=i.globals.dom.baseEl.querySelector(".apexcharts-xaxis-annotations .apexcharts-xaxis-annotation-label[rel='".concat(a,"']"));if(null!==s){var r=s.getBoundingClientRect();s.setAttribute("x",parseFloat(s.getAttribute("x"))-r.height+4),"top"===t.label.position?s.setAttribute("y",parseFloat(s.getAttribute("y"))+r.width):s.setAttribute("y",parseFloat(s.getAttribute("y"))-r.width);var n=this.annoCtx.graphics.rotateAroundCenter(s),o=n.x,l=n.y;s.setAttribute("transform","rotate(-90 ".concat(o," ").concat(l,")"))}}}},{key:"addBackgroundToAnno",value:function(t,e){var i=this.w;if(!t||void 0===e.label.text||void 0!==e.label.text&&!String(e.label.text).trim())return null;var a=i.globals.dom.baseEl.querySelector(".apexcharts-grid").getBoundingClientRect(),s=t.getBoundingClientRect(),r=e.label.style.padding.left,n=e.label.style.padding.right,o=e.label.style.padding.top,l=e.label.style.padding.bottom;"vertical"===e.label.orientation&&(o=e.label.style.padding.left,l=e.label.style.padding.right,r=e.label.style.padding.top,n=e.label.style.padding.bottom);var c=s.left-a.left-r,h=s.top-a.top-o,d=this.annoCtx.graphics.drawRect(c-i.globals.barPadForNumericAxis,h,s.width+r+n,s.height+o+l,e.label.borderRadius,e.label.style.background,1,e.label.borderWidth,e.label.borderColor,0);return e.id&&d.node.classList.add(e.id),d}},{key:"annotationsBackground",value:function(){var t=this,e=this.w,i=function(i,a,s){var r=e.globals.dom.baseEl.querySelector(".apexcharts-".concat(s,"-annotations .apexcharts-").concat(s,"-annotation-label[rel='").concat(a,"']"));if(r){var n=r.parentNode,o=t.addBackgroundToAnno(r,i);o&&(n.insertBefore(o.node,r),i.label.mouseEnter&&o.node.addEventListener("mouseenter",i.label.mouseEnter.bind(t,i)),i.label.mouseLeave&&o.node.addEventListener("mouseleave",i.label.mouseLeave.bind(t,i)),i.label.click&&o.node.addEventListener("click",i.label.click.bind(t,i)))}};e.config.annotations.xaxis.map((function(t,e){i(t,e,"xaxis")})),e.config.annotations.yaxis.map((function(t,e){i(t,e,"yaxis")})),e.config.annotations.points.map((function(t,e){i(t,e,"point")}))}},{key:"getY1Y2",value:function(t,e){var i,a="y1"===t?e.y:e.y2,s=this.w;if(this.annoCtx.invertAxis){var r=s.globals.labels.indexOf(a);s.config.xaxis.convertedCatToNumeric&&(r=s.globals.categoryLabels.indexOf(a));var n=s.globals.dom.baseEl.querySelector(".apexcharts-yaxis-texts-g text:nth-child("+(r+1)+")");n&&(i=parseFloat(n.getAttribute("y")))}else{var o;o=s.config.yaxis[e.yAxisIndex].logarithmic?(a=new A(this.annoCtx.ctx).getLogVal(a,e.yAxisIndex))/s.globals.yLogRatio[e.yAxisIndex]:(a-s.globals.minYArr[e.yAxisIndex])/(s.globals.yRange[e.yAxisIndex]/s.globals.gridHeight),i=s.globals.gridHeight-o,!e.marker||void 0!==e.y&&null!==e.y||(i=0),s.config.yaxis[e.yAxisIndex]&&s.config.yaxis[e.yAxisIndex].reversed&&(i=o)}return"string"==typeof a&&a.indexOf("px")>-1&&(i=parseFloat(a)),i}},{key:"getX1X2",value:function(t,e){var i=this.w,a=this.annoCtx.invertAxis?i.globals.minY:i.globals.minX,s=this.annoCtx.invertAxis?i.globals.maxY:i.globals.maxX,r=this.annoCtx.invertAxis?i.globals.yRange[0]:i.globals.xRange,n=(e.x-a)/(r/i.globals.gridWidth);this.annoCtx.inversedReversedAxis&&(n=(s-e.x)/(r/i.globals.gridWidth)),"category"!==i.config.xaxis.type&&!i.config.xaxis.convertedCatToNumeric||this.annoCtx.invertAxis||i.globals.dataFormatXNumeric||(n=this.getStringX(e.x));var o=(e.x2-a)/(r/i.globals.gridWidth);return this.annoCtx.inversedReversedAxis&&(o=(s-e.x2)/(r/i.globals.gridWidth)),"category"!==i.config.xaxis.type&&!i.config.xaxis.convertedCatToNumeric||this.annoCtx.invertAxis||i.globals.dataFormatXNumeric||(o=this.getStringX(e.x2)),void 0!==e.x&&null!==e.x||!e.marker||(n=i.globals.gridWidth),"x1"===t&&"string"==typeof e.x&&e.x.indexOf("px")>-1&&(n=parseFloat(e.x)),"x2"===t&&"string"==typeof e.x2&&e.x2.indexOf("px")>-1&&(o=parseFloat(e.x2)),"x1"===t?n:o}},{key:"getStringX",value:function(t){var e=this.w,i=t;e.config.xaxis.convertedCatToNumeric&&e.globals.categoryLabels.length&&(t=e.globals.categoryLabels.indexOf(t)+1);var a=e.globals.labels.indexOf(t),s=e.globals.dom.baseEl.querySelector(".apexcharts-xaxis-texts-g text:nth-child("+(a+1)+")");return s&&(i=parseFloat(s.getAttribute("x"))),i}}]),t}(),C=function(){function t(e){o(this,t),this.w=e.w,this.annoCtx=e,this.invertAxis=this.annoCtx.invertAxis,this.helpers=new S(this.annoCtx)}return c(t,[{key:"addXaxisAnnotation",value:function(t,e,i){var a,s=this.w,r=this.helpers.getX1X2("x1",t),n=t.label.text,o=t.strokeDashArray;if(v.isNumber(r)){if(null===t.x2||void 0===t.x2){var l=this.annoCtx.graphics.drawLine(r+t.offsetX,0+t.offsetY,r+t.offsetX,s.globals.gridHeight+t.offsetY,t.borderColor,o,t.borderWidth);e.appendChild(l.node),t.id&&l.node.classList.add(t.id)}else{if((a=this.helpers.getX1X2("x2",t))<r){var c=r;r=a,a=c}var h=this.annoCtx.graphics.drawRect(r+t.offsetX,0+t.offsetY,a-r,s.globals.gridHeight+t.offsetY,0,t.fillColor,t.opacity,1,t.borderColor,o);h.node.classList.add("apexcharts-annotation-rect"),h.attr("clip-path","url(#gridRectMask".concat(s.globals.cuid,")")),e.appendChild(h.node),t.id&&h.node.classList.add(t.id)}var d=this.annoCtx.graphics.getTextRects(n,parseFloat(t.label.style.fontSize)),u="top"===t.label.position?4:"center"===t.label.position?s.globals.gridHeight/2+("vertical"===t.label.orientation?d.width/2:0):s.globals.gridHeight,p=this.annoCtx.graphics.drawText({x:r+t.label.offsetX,y:u+t.label.offsetY-("vertical"===t.label.orientation?"top"===t.label.position?d.width/2-12:-d.width/2:0),text:n,textAnchor:t.label.textAnchor,fontSize:t.label.style.fontSize,fontFamily:t.label.style.fontFamily,fontWeight:t.label.style.fontWeight,foreColor:t.label.style.color,cssClass:"apexcharts-xaxis-annotation-label ".concat(t.label.style.cssClass," ").concat(t.id?t.id:"")});p.attr({rel:i}),e.appendChild(p.node),this.annoCtx.helpers.setOrientations(t,i)}}},{key:"drawXAxisAnnotations",value:function(){var t=this,e=this.w,i=this.annoCtx.graphics.group({class:"apexcharts-xaxis-annotations"});return e.config.annotations.xaxis.map((function(e,a){t.addXaxisAnnotation(e,i.node,a)})),i}}]),t}(),P=function(){function t(e){o(this,t),this.w=e.w,this.annoCtx=e,this.helpers=new S(this.annoCtx)}return c(t,[{key:"addYaxisAnnotation",value:function(t,e,i){var a,s=this.w,r=t.strokeDashArray,n=this.helpers.getY1Y2("y1",t),o=t.label.text;if(null===t.y2||void 0===t.y2){var l=this.annoCtx.graphics.drawLine(0+t.offsetX,n+t.offsetY,this._getYAxisAnnotationWidth(t),n+t.offsetY,t.borderColor,r,t.borderWidth);e.appendChild(l.node),t.id&&l.node.classList.add(t.id)}else{if((a=this.helpers.getY1Y2("y2",t))>n){var c=n;n=a,a=c}var h=this.annoCtx.graphics.drawRect(0+t.offsetX,a+t.offsetY,this._getYAxisAnnotationWidth(t),n-a,0,t.fillColor,t.opacity,1,t.borderColor,r);h.node.classList.add("apexcharts-annotation-rect"),h.attr("clip-path","url(#gridRectMask".concat(s.globals.cuid,")")),e.appendChild(h.node),t.id&&h.node.classList.add(t.id)}var d="right"===t.label.position?s.globals.gridWidth:"center"===t.label.position?s.globals.gridWidth/2:0,u=this.annoCtx.graphics.drawText({x:d+t.label.offsetX,y:(null!=a?a:n)+t.label.offsetY-3,text:o,textAnchor:t.label.textAnchor,fontSize:t.label.style.fontSize,fontFamily:t.label.style.fontFamily,fontWeight:t.label.style.fontWeight,foreColor:t.label.style.color,cssClass:"apexcharts-yaxis-annotation-label ".concat(t.label.style.cssClass," ").concat(t.id?t.id:"")});u.attr({rel:i}),e.appendChild(u.node)}},{key:"_getYAxisAnnotationWidth",value:function(t){var e=this.w;return e.globals.gridWidth,(t.width.indexOf("%")>-1?e.globals.gridWidth*parseInt(t.width,10)/100:parseInt(t.width,10))+t.offsetX}},{key:"drawYAxisAnnotations",value:function(){var t=this,e=this.w,i=this.annoCtx.graphics.group({class:"apexcharts-yaxis-annotations"});return e.config.annotations.yaxis.map((function(e,a){t.addYaxisAnnotation(e,i.node,a)})),i}}]),t}(),L=function(){function t(e){o(this,t),this.w=e.w,this.annoCtx=e,this.helpers=new S(this.annoCtx)}return c(t,[{key:"addPointAnnotation",value:function(t,e,i){this.w;var a=this.helpers.getX1X2("x1",t),s=this.helpers.getY1Y2("y1",t);if(v.isNumber(a)){var r={pSize:t.marker.size,pointStrokeWidth:t.marker.strokeWidth,pointFillColor:t.marker.fillColor,pointStrokeColor:t.marker.strokeColor,shape:t.marker.shape,pRadius:t.marker.radius,class:"apexcharts-point-annotation-marker ".concat(t.marker.cssClass," ").concat(t.id?t.id:"")},n=this.annoCtx.graphics.drawMarker(a+t.marker.offsetX,s+t.marker.offsetY,r);e.appendChild(n.node);var o=t.label.text?t.label.text:"",l=this.annoCtx.graphics.drawText({x:a+t.label.offsetX,y:s+t.label.offsetY-t.marker.size-parseFloat(t.label.style.fontSize)/1.6,text:o,textAnchor:t.label.textAnchor,fontSize:t.label.style.fontSize,fontFamily:t.label.style.fontFamily,fontWeight:t.label.style.fontWeight,foreColor:t.label.style.color,cssClass:"apexcharts-point-annotation-label ".concat(t.label.style.cssClass," ").concat(t.id?t.id:"")});if(l.attr({rel:i}),e.appendChild(l.node),t.customSVG.SVG){var c=this.annoCtx.graphics.group({class:"apexcharts-point-annotations-custom-svg "+t.customSVG.cssClass});c.attr({transform:"translate(".concat(a+t.customSVG.offsetX,", ").concat(s+t.customSVG.offsetY,")")}),c.node.innerHTML=t.customSVG.SVG,e.appendChild(c.node)}if(t.image.path){var h=t.image.width?t.image.width:20,d=t.image.height?t.image.height:20;n=this.annoCtx.addImage({x:a+t.image.offsetX-h/2,y:s+t.image.offsetY-d/2,width:h,height:d,path:t.image.path,appendTo:".apexcharts-point-annotations"})}t.mouseEnter&&n.node.addEventListener("mouseenter",t.mouseEnter.bind(this,t)),t.mouseLeave&&n.node.addEventListener("mouseleave",t.mouseLeave.bind(this,t)),t.click&&n.node.addEventListener("click",t.click.bind(this,t))}}},{key:"drawPointAnnotations",value:function(){var t=this,e=this.w,i=this.annoCtx.graphics.group({class:"apexcharts-point-annotations"});return e.config.annotations.points.map((function(e,a){t.addPointAnnotation(e,i.node,a)})),i}}]),t}(),D={name:"en",options:{months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],toolbar:{exportToSVG:"Download SVG",exportToPNG:"Download PNG",exportToCSV:"Download CSV",menu:"Menu",selection:"Selection",selectionZoom:"Selection Zoom",zoomIn:"Zoom In",zoomOut:"Zoom Out",pan:"Panning",reset:"Reset Zoom"}}},T=function(){function t(){o(this,t),this.yAxis={show:!0,showAlways:!1,showForNullSeries:!0,seriesName:void 0,opposite:!1,reversed:!1,logarithmic:!1,logBase:10,tickAmount:void 0,forceNiceScale:!1,max:void 0,min:void 0,floating:!1,decimalsInFloat:void 0,labels:{show:!0,minWidth:0,maxWidth:160,offsetX:0,offsetY:0,align:void 0,rotate:0,padding:20,style:{colors:[],fontSize:"11px",fontWeight:400,fontFamily:void 0,cssClass:""},formatter:void 0},axisBorder:{show:!1,color:"#e0e0e0",width:1,offsetX:0,offsetY:0},axisTicks:{show:!1,color:"#e0e0e0",width:6,offsetX:0,offsetY:0},title:{text:void 0,rotate:-90,offsetY:0,offsetX:0,style:{color:void 0,fontSize:"11px",fontWeight:900,fontFamily:void 0,cssClass:""}},tooltip:{enabled:!1,offsetX:0},crosshairs:{show:!0,position:"front",stroke:{color:"#b6b6b6",width:1,dashArray:0}}},this.pointAnnotation={id:void 0,x:0,y:null,yAxisIndex:0,seriesIndex:0,mouseEnter:void 0,mouseLeave:void 0,click:void 0,marker:{size:4,fillColor:"#fff",strokeWidth:2,strokeColor:"#333",shape:"circle",offsetX:0,offsetY:0,radius:2,cssClass:""},label:{borderColor:"#c2c2c2",borderWidth:1,borderRadius:2,text:void 0,textAnchor:"middle",offsetX:0,offsetY:0,mouseEnter:void 0,mouseLeave:void 0,click:void 0,style:{background:"#fff",color:void 0,fontSize:"11px",fontFamily:void 0,fontWeight:400,cssClass:"",padding:{left:5,right:5,top:2,bottom:2}}},customSVG:{SVG:void 0,cssClass:void 0,offsetX:0,offsetY:0},image:{path:void 0,width:20,height:20,offsetX:0,offsetY:0}},this.yAxisAnnotation={id:void 0,y:0,y2:null,strokeDashArray:1,fillColor:"#c2c2c2",borderColor:"#c2c2c2",borderWidth:1,opacity:.3,offsetX:0,offsetY:0,width:"100%",yAxisIndex:0,label:{borderColor:"#c2c2c2",borderWidth:1,borderRadius:2,text:void 0,textAnchor:"end",position:"right",offsetX:0,offsetY:-3,mouseEnter:void 0,mouseLeave:void 0,click:void 0,style:{background:"#fff",color:void 0,fontSize:"11px",fontFamily:void 0,fontWeight:400,cssClass:"",padding:{left:5,right:5,top:2,bottom:2}}}},this.xAxisAnnotation={id:void 0,x:0,x2:null,strokeDashArray:1,fillColor:"#c2c2c2",borderColor:"#c2c2c2",borderWidth:1,opacity:.3,offsetX:0,offsetY:0,label:{borderColor:"#c2c2c2",borderWidth:1,borderRadius:2,text:void 0,textAnchor:"middle",orientation:"vertical",position:"top",offsetX:0,offsetY:0,mouseEnter:void 0,mouseLeave:void 0,click:void 0,style:{background:"#fff",color:void 0,fontSize:"11px",fontFamily:void 0,fontWeight:400,cssClass:"",padding:{left:5,right:5,top:2,bottom:2}}}},this.text={x:0,y:0,text:"",textAnchor:"start",foreColor:void 0,fontSize:"13px",fontFamily:void 0,fontWeight:400,appendTo:".apexcharts-annotations",backgroundColor:"transparent",borderColor:"#c2c2c2",borderRadius:0,borderWidth:0,paddingLeft:4,paddingRight:4,paddingTop:2,paddingBottom:2}}return c(t,[{key:"init",value:function(){return{annotations:{position:"front",yaxis:[this.yAxisAnnotation],xaxis:[this.xAxisAnnotation],points:[this.pointAnnotation],texts:[],images:[],shapes:[]},chart:{animations:{enabled:!0,easing:"easeinout",speed:800,animateGradually:{delay:150,enabled:!0},dynamicAnimation:{enabled:!0,speed:350}},background:"transparent",locales:[D],defaultLocale:"en",dropShadow:{enabled:!1,enabledOnSeries:void 0,top:2,left:2,blur:4,color:"#000",opacity:.35},events:{animationEnd:void 0,beforeMount:void 0,mounted:void 0,updated:void 0,click:void 0,mouseMove:void 0,mouseLeave:void 0,xAxisLabelClick:void 0,legendClick:void 0,markerClick:void 0,selection:void 0,dataPointSelection:void 0,dataPointMouseEnter:void 0,dataPointMouseLeave:void 0,beforeZoom:void 0,beforeResetZoom:void 0,zoomed:void 0,scrolled:void 0,brushScrolled:void 0},foreColor:"#373d3f",fontFamily:"Helvetica, Arial, sans-serif",height:"auto",parentHeightOffset:15,redrawOnParentResize:!0,redrawOnWindowResize:!0,id:void 0,group:void 0,offsetX:0,offsetY:0,selection:{enabled:!1,type:"x",fill:{color:"#24292e",opacity:.1},stroke:{width:1,color:"#24292e",opacity:.4,dashArray:3},xaxis:{min:void 0,max:void 0},yaxis:{min:void 0,max:void 0}},sparkline:{enabled:!1},brush:{enabled:!1,autoScaleYaxis:!0,target:void 0},stacked:!1,stackType:"normal",toolbar:{show:!0,offsetX:0,offsetY:0,tools:{download:!0,selection:!0,zoom:!0,zoomin:!0,zoomout:!0,pan:!0,reset:!0,customIcons:[]},export:{csv:{filename:void 0,columnDelimiter:",",headerCategory:"category",headerValue:"value",dateFormatter:function(t){return new Date(t).toDateString()}},png:{filename:void 0},svg:{filename:void 0}},autoSelected:"zoom"},type:"line",width:"100%",zoom:{enabled:!0,type:"x",autoScaleYaxis:!1,zoomedArea:{fill:{color:"#90CAF9",opacity:.4},stroke:{color:"#0D47A1",opacity:.4,width:1}}}},plotOptions:{area:{fillTo:"origin"},bar:{horizontal:!1,columnWidth:"70%",barHeight:"70%",distributed:!1,borderRadius:0,borderRadiusApplication:"around",borderRadiusWhenStacked:"last",rangeBarOverlap:!0,rangeBarGroupRows:!1,colors:{ranges:[],backgroundBarColors:[],backgroundBarOpacity:1,backgroundBarRadius:0},dataLabels:{position:"top",maxItems:100,hideOverflowingLabels:!0,orientation:"horizontal",total:{enabled:!1,formatter:void 0,offsetX:0,offsetY:0,style:{color:"#373d3f",fontSize:"12px",fontFamily:void 0,fontWeight:600}}}},bubble:{zScaling:!0,minBubbleRadius:void 0,maxBubbleRadius:void 0},candlestick:{colors:{upward:"#00B746",downward:"#EF403C"},wick:{useFillColor:!0}},boxPlot:{colors:{upper:"#00E396",lower:"#008FFB"}},heatmap:{radius:2,enableShades:!0,shadeIntensity:.5,reverseNegativeShade:!1,distributed:!1,useFillColorAsStroke:!1,colorScale:{inverse:!1,ranges:[],min:void 0,max:void 0}},treemap:{enableShades:!0,shadeIntensity:.5,distributed:!1,reverseNegativeShade:!1,useFillColorAsStroke:!1,colorScale:{inverse:!1,ranges:[],min:void 0,max:void 0}},radialBar:{inverseOrder:!1,startAngle:0,endAngle:360,offsetX:0,offsetY:0,hollow:{margin:5,size:"50%",background:"transparent",image:void 0,imageWidth:150,imageHeight:150,imageOffsetX:0,imageOffsetY:0,imageClipped:!0,position:"front",dropShadow:{enabled:!1,top:0,left:0,blur:3,color:"#000",opacity:.5}},track:{show:!0,startAngle:void 0,endAngle:void 0,background:"#f2f2f2",strokeWidth:"97%",opacity:1,margin:5,dropShadow:{enabled:!1,top:0,left:0,blur:3,color:"#000",opacity:.5}},dataLabels:{show:!0,name:{show:!0,fontSize:"16px",fontFamily:void 0,fontWeight:600,color:void 0,offsetY:0,formatter:function(t){return t}},value:{show:!0,fontSize:"14px",fontFamily:void 0,fontWeight:400,color:void 0,offsetY:16,formatter:function(t){return t+"%"}},total:{show:!1,label:"Total",fontSize:"16px",fontWeight:600,fontFamily:void 0,color:void 0,formatter:function(t){return t.globals.seriesTotals.reduce((function(t,e){return t+e}),0)/t.globals.series.length+"%"}}}},pie:{customScale:1,offsetX:0,offsetY:0,startAngle:0,endAngle:360,expandOnClick:!0,dataLabels:{offset:0,minAngleToShowLabel:10},donut:{size:"65%",background:"transparent",labels:{show:!1,name:{show:!0,fontSize:"16px",fontFamily:void 0,fontWeight:600,color:void 0,offsetY:-10,formatter:function(t){return t}},value:{show:!0,fontSize:"20px",fontFamily:void 0,fontWeight:400,color:void 0,offsetY:10,formatter:function(t){return t}},total:{show:!1,showAlways:!1,label:"Total",fontSize:"16px",fontWeight:400,fontFamily:void 0,color:void 0,formatter:function(t){return t.globals.seriesTotals.reduce((function(t,e){return t+e}),0)}}}}},polarArea:{rings:{strokeWidth:1,strokeColor:"#e8e8e8"},spokes:{strokeWidth:1,connectorColors:"#e8e8e8"}},radar:{size:void 0,offsetX:0,offsetY:0,polygons:{strokeWidth:1,strokeColors:"#e8e8e8",connectorColors:"#e8e8e8",fill:{colors:void 0}}}},colors:void 0,dataLabels:{enabled:!0,enabledOnSeries:void 0,formatter:function(t){return null!==t?t:""},textAnchor:"middle",distributed:!1,offsetX:0,offsetY:0,style:{fontSize:"12px",fontFamily:void 0,fontWeight:600,colors:void 0},background:{enabled:!0,foreColor:"#fff",borderRadius:2,padding:4,opacity:.9,borderWidth:1,borderColor:"#fff",dropShadow:{enabled:!1,top:1,left:1,blur:1,color:"#000",opacity:.45}},dropShadow:{enabled:!1,top:1,left:1,blur:1,color:"#000",opacity:.45}},fill:{type:"solid",colors:void 0,opacity:.85,gradient:{shade:"dark",type:"horizontal",shadeIntensity:.5,gradientToColors:void 0,inverseColors:!0,opacityFrom:1,opacityTo:1,stops:[0,50,100],colorStops:[]},image:{src:[],width:void 0,height:void 0},pattern:{style:"squares",width:6,height:6,strokeWidth:2}},forecastDataPoints:{count:0,fillOpacity:.5,strokeWidth:void 0,dashArray:4},grid:{show:!0,borderColor:"#e0e0e0",strokeDashArray:0,position:"back",xaxis:{lines:{show:!1}},yaxis:{lines:{show:!0}},row:{colors:void 0,opacity:.5},column:{colors:void 0,opacity:.5},padding:{top:0,right:10,bottom:0,left:12}},labels:[],legend:{show:!0,showForSingleSeries:!1,showForNullSeries:!0,showForZeroSeries:!0,floating:!1,position:"bottom",horizontalAlign:"center",inverseOrder:!1,fontSize:"12px",fontFamily:void 0,fontWeight:400,width:void 0,height:void 0,formatter:void 0,tooltipHoverFormatter:void 0,offsetX:-20,offsetY:4,customLegendItems:[],labels:{colors:void 0,useSeriesColors:!1},markers:{width:12,height:12,strokeWidth:0,fillColors:void 0,strokeColor:"#fff",radius:12,customHTML:void 0,offsetX:0,offsetY:0,onClick:void 0},itemMargin:{horizontal:5,vertical:2},onItemClick:{toggleDataSeries:!0},onItemHover:{highlightDataSeries:!0}},markers:{discrete:[],size:0,colors:void 0,strokeColors:"#fff",strokeWidth:2,strokeOpacity:.9,strokeDashArray:0,fillOpacity:1,shape:"circle",width:8,height:8,radius:2,offsetX:0,offsetY:0,onClick:void 0,onDblClick:void 0,showNullDataPoints:!0,hover:{size:void 0,sizeOffset:3}},noData:{text:void 0,align:"center",verticalAlign:"middle",offsetX:0,offsetY:0,style:{color:void 0,fontSize:"14px",fontFamily:void 0}},responsive:[],series:void 0,states:{normal:{filter:{type:"none",value:0}},hover:{filter:{type:"lighten",value:.1}},active:{allowMultipleDataPointsSelection:!1,filter:{type:"darken",value:.5}}},title:{text:void 0,align:"left",margin:5,offsetX:0,offsetY:0,floating:!1,style:{fontSize:"14px",fontWeight:900,fontFamily:void 0,color:void 0}},subtitle:{text:void 0,align:"left",margin:5,offsetX:0,offsetY:30,floating:!1,style:{fontSize:"12px",fontWeight:400,fontFamily:void 0,color:void 0}},stroke:{show:!0,curve:"smooth",lineCap:"butt",width:2,colors:void 0,dashArray:0,fill:{type:"solid",colors:void 0,opacity:.85,gradient:{shade:"dark",type:"horizontal",shadeIntensity:.5,gradientToColors:void 0,inverseColors:!0,opacityFrom:1,opacityTo:1,stops:[0,50,100],colorStops:[]}}},tooltip:{enabled:!0,enabledOnSeries:void 0,shared:!0,followCursor:!1,intersect:!1,inverseOrder:!1,custom:void 0,fillSeriesColor:!1,theme:"light",cssClass:"",style:{fontSize:"12px",fontFamily:void 0},onDatasetHover:{highlightDataSeries:!1},x:{show:!0,format:"dd MMM",formatter:void 0},y:{formatter:void 0,title:{formatter:function(t){return t?t+": ":""}}},z:{formatter:void 0,title:"Size: "},marker:{show:!0,fillColors:void 0},items:{display:"flex"},fixed:{enabled:!1,position:"topRight",offsetX:0,offsetY:0}},xaxis:{type:"category",categories:[],convertedCatToNumeric:!1,offsetX:0,offsetY:0,overwriteCategories:void 0,labels:{show:!0,rotate:-45,rotateAlways:!1,hideOverlappingLabels:!0,trim:!1,minHeight:void 0,maxHeight:120,showDuplicates:!0,style:{colors:[],fontSize:"12px",fontWeight:400,fontFamily:void 0,cssClass:""},offsetX:0,offsetY:0,format:void 0,formatter:void 0,datetimeUTC:!0,datetimeFormatter:{year:"yyyy",month:"MMM 'yy",day:"dd MMM",hour:"HH:mm",minute:"HH:mm:ss",second:"HH:mm:ss"}},group:{groups:[],style:{colors:[],fontSize:"12px",fontWeight:400,fontFamily:void 0,cssClass:""}},axisBorder:{show:!0,color:"#e0e0e0",width:"100%",height:1,offsetX:0,offsetY:0},axisTicks:{show:!0,color:"#e0e0e0",height:6,offsetX:0,offsetY:0},tickAmount:void 0,tickPlacement:"on",min:void 0,max:void 0,range:void 0,floating:!1,decimalsInFloat:void 0,position:"bottom",title:{text:void 0,offsetX:0,offsetY:0,style:{color:void 0,fontSize:"12px",fontWeight:900,fontFamily:void 0,cssClass:""}},crosshairs:{show:!0,width:1,position:"back",opacity:.9,stroke:{color:"#b6b6b6",width:1,dashArray:3},fill:{type:"solid",color:"#B1B9C4",gradient:{colorFrom:"#D8E3F0",colorTo:"#BED1E6",stops:[0,100],opacityFrom:.4,opacityTo:.5}},dropShadow:{enabled:!1,left:0,top:0,blur:1,opacity:.4}},tooltip:{enabled:!0,offsetY:0,formatter:void 0,style:{fontSize:"12px",fontFamily:void 0}}},yaxis:this.yAxis,theme:{mode:"light",palette:"palette1",monochrome:{enabled:!1,color:"#008FFB",shadeTo:"light",shadeIntensity:.65}}}}}]),t}(),M=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w,this.graphics=new k(this.ctx),this.w.globals.isBarHorizontal&&(this.invertAxis=!0),this.helpers=new S(this),this.xAxisAnnotations=new C(this),this.yAxisAnnotations=new P(this),this.pointsAnnotations=new L(this),this.w.globals.isBarHorizontal&&this.w.config.yaxis[0].reversed&&(this.inversedReversedAxis=!0),this.xDivision=this.w.globals.gridWidth/this.w.globals.dataPoints}return c(t,[{key:"drawAxesAnnotations",value:function(){var t=this.w;if(t.globals.axisCharts){for(var e=this.yAxisAnnotations.drawYAxisAnnotations(),i=this.xAxisAnnotations.drawXAxisAnnotations(),a=this.pointsAnnotations.drawPointAnnotations(),s=t.config.chart.animations.enabled,r=[e,i,a],n=[i.node,e.node,a.node],o=0;o<3;o++)t.globals.dom.elGraphical.add(r[o]),!s||t.globals.resized||t.globals.dataChanged||"scatter"!==t.config.chart.type&&"bubble"!==t.config.chart.type&&t.globals.dataPoints>1&&n[o].classList.add("apexcharts-element-hidden"),t.globals.delayedElements.push({el:n[o],index:0});this.helpers.annotationsBackground()}}},{key:"drawImageAnnos",value:function(){var t=this;this.w.config.annotations.images.map((function(e,i){t.addImage(e,i)}))}},{key:"drawTextAnnos",value:function(){var t=this;this.w.config.annotations.texts.map((function(e,i){t.addText(e,i)}))}},{key:"addXaxisAnnotation",value:function(t,e,i){this.xAxisAnnotations.addXaxisAnnotation(t,e,i)}},{key:"addYaxisAnnotation",value:function(t,e,i){this.yAxisAnnotations.addYaxisAnnotation(t,e,i)}},{key:"addPointAnnotation",value:function(t,e,i){this.pointsAnnotations.addPointAnnotation(t,e,i)}},{key:"addText",value:function(t,e){var i=t.x,a=t.y,s=t.text,r=t.textAnchor,n=t.foreColor,o=t.fontSize,l=t.fontFamily,c=t.fontWeight,h=t.cssClass,d=t.backgroundColor,u=t.borderWidth,p=t.strokeDashArray,f=t.borderRadius,g=t.borderColor,x=t.appendTo,m=void 0===x?".apexcharts-annotations":x,b=t.paddingLeft,v=void 0===b?4:b,y=t.paddingRight,w=void 0===y?4:y,k=t.paddingBottom,A=void 0===k?2:k,S=t.paddingTop,C=void 0===S?2:S,P=this.w,L=this.graphics.drawText({x:i,y:a,text:s,textAnchor:r||"start",fontSize:o||"12px",fontWeight:c||"regular",fontFamily:l||P.config.chart.fontFamily,foreColor:n||P.config.chart.foreColor,cssClass:h}),D=P.globals.dom.baseEl.querySelector(m);D&&D.appendChild(L.node);var T=L.bbox();if(s){var M=this.graphics.drawRect(T.x-v,T.y-C,T.width+v+w,T.height+A+C,f,d||"transparent",1,u,g,p);D.insertBefore(M.node,L.node)}}},{key:"addImage",value:function(t,e){var i=this.w,a=t.path,s=t.x,r=void 0===s?0:s,n=t.y,o=void 0===n?0:n,l=t.width,c=void 0===l?20:l,h=t.height,d=void 0===h?20:h,u=t.appendTo,p=void 0===u?".apexcharts-annotations":u,f=i.globals.dom.Paper.image(a);f.size(c,d).move(r,o);var g=i.globals.dom.baseEl.querySelector(p);return g&&g.appendChild(f.node),f}},{key:"addXaxisAnnotationExternal",value:function(t,e,i){return this.addAnnotationExternal({params:t,pushToMemory:e,context:i,type:"xaxis",contextMethod:i.addXaxisAnnotation}),i}},{key:"addYaxisAnnotationExternal",value:function(t,e,i){return this.addAnnotationExternal({params:t,pushToMemory:e,context:i,type:"yaxis",contextMethod:i.addYaxisAnnotation}),i}},{key:"addPointAnnotationExternal",value:function(t,e,i){return void 0===this.invertAxis&&(this.invertAxis=i.w.globals.isBarHorizontal),this.addAnnotationExternal({params:t,pushToMemory:e,context:i,type:"point",contextMethod:i.addPointAnnotation}),i}},{key:"addAnnotationExternal",value:function(t){var e=t.params,i=t.pushToMemory,a=t.context,s=t.type,r=t.contextMethod,n=a,o=n.w,l=o.globals.dom.baseEl.querySelector(".apexcharts-".concat(s,"-annotations")),c=l.childNodes.length+1,h=new T,d=Object.assign({},"xaxis"===s?h.xAxisAnnotation:"yaxis"===s?h.yAxisAnnotation:h.pointAnnotation),u=v.extend(d,e);switch(s){case"xaxis":this.addXaxisAnnotation(u,l,c);break;case"yaxis":this.addYaxisAnnotation(u,l,c);break;case"point":this.addPointAnnotation(u,l,c)}var p=o.globals.dom.baseEl.querySelector(".apexcharts-".concat(s,"-annotations .apexcharts-").concat(s,"-annotation-label[rel='").concat(c,"']")),f=this.helpers.addBackgroundToAnno(p,u);return f&&l.insertBefore(f.node,p),i&&o.globals.memory.methodsToExec.push({context:n,id:u.id?u.id:v.randomId(),method:r,label:"addAnnotation",params:e}),a}},{key:"clearAnnotations",value:function(t){var e=t.w,i=e.globals.dom.baseEl.querySelectorAll(".apexcharts-yaxis-annotations, .apexcharts-xaxis-annotations, .apexcharts-point-annotations");e.globals.memory.methodsToExec.map((function(t,i){"addText"!==t.label&&"addAnnotation"!==t.label||e.globals.memory.methodsToExec.splice(i,1)})),i=v.listToArray(i),Array.prototype.forEach.call(i,(function(t){for(;t.firstChild;)t.removeChild(t.firstChild)}))}},{key:"removeAnnotation",value:function(t,e){var i=t.w,a=i.globals.dom.baseEl.querySelectorAll(".".concat(e));a&&(i.globals.memory.methodsToExec.map((function(t,a){t.id===e&&i.globals.memory.methodsToExec.splice(a,1)})),Array.prototype.forEach.call(a,(function(t){t.parentElement.removeChild(t)})))}}]),t}(),E=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w,this.months31=[1,3,5,7,8,10,12],this.months30=[2,4,6,9,11],this.daysCntOfYear=[0,31,59,90,120,151,181,212,243,273,304,334]}return c(t,[{key:"isValidDate",value:function(t){return!isNaN(this.parseDate(t))}},{key:"getTimeStamp",value:function(t){return Date.parse(t)?this.w.config.xaxis.labels.datetimeUTC?new Date(new Date(t).toISOString().substr(0,25)).getTime():new Date(t).getTime():t}},{key:"getDate",value:function(t){return this.w.config.xaxis.labels.datetimeUTC?new Date(new Date(t).toUTCString()):new Date(t)}},{key:"parseDate",value:function(t){var e=Date.parse(t);if(!isNaN(e))return this.getTimeStamp(t);var i=Date.parse(t.replace(/-/g,"/").replace(/[a-z]+/gi," "));return this.getTimeStamp(i)}},{key:"parseDateWithTimezone",value:function(t){return Date.parse(t.replace(/-/g,"/").replace(/[a-z]+/gi," "))}},{key:"formatDate",value:function(t,e){var i=this.w.globals.locale,a=this.w.config.xaxis.labels.datetimeUTC,s=["\0"].concat(x(i.months)),r=[""].concat(x(i.shortMonths)),n=[""].concat(x(i.days)),o=[""].concat(x(i.shortDays));function l(t,e){var i=t+"";for(e=e||2;i.length<e;)i="0"+i;return i}var c=a?t.getUTCFullYear():t.getFullYear();e=(e=(e=e.replace(/(^|[^\\])yyyy+/g,"$1"+c)).replace(/(^|[^\\])yy/g,"$1"+c.toString().substr(2,2))).replace(/(^|[^\\])y/g,"$1"+c);var h=(a?t.getUTCMonth():t.getMonth())+1;e=(e=(e=(e=e.replace(/(^|[^\\])MMMM+/g,"$1"+s[0])).replace(/(^|[^\\])MMM/g,"$1"+r[0])).replace(/(^|[^\\])MM/g,"$1"+l(h))).replace(/(^|[^\\])M/g,"$1"+h);var d=a?t.getUTCDate():t.getDate();e=(e=(e=(e=e.replace(/(^|[^\\])dddd+/g,"$1"+n[0])).replace(/(^|[^\\])ddd/g,"$1"+o[0])).replace(/(^|[^\\])dd/g,"$1"+l(d))).replace(/(^|[^\\])d/g,"$1"+d);var u=a?t.getUTCHours():t.getHours(),p=u>12?u-12:0===u?12:u;e=(e=(e=(e=e.replace(/(^|[^\\])HH+/g,"$1"+l(u))).replace(/(^|[^\\])H/g,"$1"+u)).replace(/(^|[^\\])hh+/g,"$1"+l(p))).replace(/(^|[^\\])h/g,"$1"+p);var f=a?t.getUTCMinutes():t.getMinutes();e=(e=e.replace(/(^|[^\\])mm+/g,"$1"+l(f))).replace(/(^|[^\\])m/g,"$1"+f);var g=a?t.getUTCSeconds():t.getSeconds();e=(e=e.replace(/(^|[^\\])ss+/g,"$1"+l(g))).replace(/(^|[^\\])s/g,"$1"+g);var m=a?t.getUTCMilliseconds():t.getMilliseconds();e=e.replace(/(^|[^\\])fff+/g,"$1"+l(m,3)),m=Math.round(m/10),e=e.replace(/(^|[^\\])ff/g,"$1"+l(m)),m=Math.round(m/10);var b=u<12?"AM":"PM";e=(e=(e=e.replace(/(^|[^\\])f/g,"$1"+m)).replace(/(^|[^\\])TT+/g,"$1"+b)).replace(/(^|[^\\])T/g,"$1"+b.charAt(0));var v=b.toLowerCase();e=(e=e.replace(/(^|[^\\])tt+/g,"$1"+v)).replace(/(^|[^\\])t/g,"$1"+v.charAt(0));var y=-t.getTimezoneOffset(),w=a||!y?"Z":y>0?"+":"-";if(!a){var k=(y=Math.abs(y))%60;w+=l(Math.floor(y/60))+":"+l(k)}e=e.replace(/(^|[^\\])K/g,"$1"+w);var A=(a?t.getUTCDay():t.getDay())+1;return(e=(e=(e=(e=e.replace(new RegExp(n[0],"g"),n[A])).replace(new RegExp(o[0],"g"),o[A])).replace(new RegExp(s[0],"g"),s[h])).replace(new RegExp(r[0],"g"),r[h])).replace(/\\(.)/g,"$1")}},{key:"getTimeUnitsfromTimestamp",value:function(t,e,i){var a=this.w;void 0!==a.config.xaxis.min&&(t=a.config.xaxis.min),void 0!==a.config.xaxis.max&&(e=a.config.xaxis.max);var s=this.getDate(t),r=this.getDate(e),n=this.formatDate(s,"yyyy MM dd HH mm ss fff").split(" "),o=this.formatDate(r,"yyyy MM dd HH mm ss fff").split(" ");return{minMillisecond:parseInt(n[6],10),maxMillisecond:parseInt(o[6],10),minSecond:parseInt(n[5],10),maxSecond:parseInt(o[5],10),minMinute:parseInt(n[4],10),maxMinute:parseInt(o[4],10),minHour:parseInt(n[3],10),maxHour:parseInt(o[3],10),minDate:parseInt(n[2],10),maxDate:parseInt(o[2],10),minMonth:parseInt(n[1],10)-1,maxMonth:parseInt(o[1],10)-1,minYear:parseInt(n[0],10),maxYear:parseInt(o[0],10)}}},{key:"isLeapYear",value:function(t){return t%4==0&&t%100!=0||t%400==0}},{key:"calculcateLastDaysOfMonth",value:function(t,e,i){return this.determineDaysOfMonths(t,e)-i}},{key:"determineDaysOfYear",value:function(t){var e=365;return this.isLeapYear(t)&&(e=366),e}},{key:"determineRemainingDaysOfYear",value:function(t,e,i){var a=this.daysCntOfYear[e]+i;return e>1&&this.isLeapYear()&&a++,a}},{key:"determineDaysOfMonths",value:function(t,e){var i=30;switch(t=v.monthMod(t),!0){case this.months30.indexOf(t)>-1:2===t&&(i=this.isLeapYear(e)?29:28);break;case this.months31.indexOf(t)>-1:default:i=31}return i}}]),t}(),I=function(t){var e,i=t.ctx,a=t.seriesIndex,s=t.dataPointIndex,r=t.y1,n=t.y2,o=t.w,l=o.globals.seriesRangeStart[a][s],c=o.globals.seriesRangeEnd[a][s],h=o.globals.labels[s],d=o.config.series[a].name?o.config.series[a].name:"",u=o.config.tooltip.y.formatter,p=o.config.tooltip.y.title.formatter,f={w:o,seriesIndex:a,dataPointIndex:s,start:l,end:c};"function"==typeof p&&(d=p(d,f)),null!==(e=o.config.series[a].data[s])&&void 0!==e&&e.x&&(h=o.config.series[a].data[s].x+":"),"function"==typeof u&&(h=u(h,f)),Number.isFinite(r)&&Number.isFinite(n)&&(l=r,c=n);var g="",x="",m=o.globals.colors[a];if(void 0===o.config.tooltip.x.formatter)if("datetime"===o.config.xaxis.type){var b=new E(i);g=b.formatDate(b.getDate(l),o.config.tooltip.x.format),x=b.formatDate(b.getDate(c),o.config.tooltip.x.format)}else g=l,x=c;else g=o.config.tooltip.x.formatter(l),x=o.config.tooltip.x.formatter(c);return{start:l,end:c,startVal:g,endVal:x,ylabel:h,color:m,seriesName:d}},O=function(t){var e=t.color,i=t.seriesName,a=t.ylabel,s=t.start,r=t.end,n=t.seriesIndex,o=t.dataPointIndex,l=t.ctx.tooltip.tooltipLabels.getFormatters(n);s=l.yLbFormatter(s),r=l.yLbFormatter(r);var c=l.yLbFormatter(t.w.globals.series[n][o]),h='<span class="value start-value">\n '.concat(s,'\n </span> <span class="separator">-</span> <span class="value end-value">\n ').concat(r,"\n </span>");return'<div class="apexcharts-tooltip-rangebar"><div> <span class="series-name" style="color: '+e+'">'+(i||"")+'</span></div><div> <span class="category">'+a+" </span> "+(t.w.globals.comboCharts?"rangeArea"===t.w.config.series[n].type||"rangeBar"===t.w.config.series[n].type?h:"<span>".concat(c,"</span>"):h)+" </div></div>"},z=function(){function t(e){o(this,t),this.opts=e}return c(t,[{key:"line",value:function(){return{chart:{animations:{easing:"swing"}},dataLabels:{enabled:!1},stroke:{width:5,curve:"straight"},markers:{size:0,hover:{sizeOffset:6}},xaxis:{crosshairs:{width:1}}}}},{key:"sparkline",value:function(t){return this.opts.yaxis[0].show=!1,this.opts.yaxis[0].title.text="",this.opts.yaxis[0].axisBorder.show=!1,this.opts.yaxis[0].axisTicks.show=!1,this.opts.yaxis[0].floating=!0,v.extend(t,{grid:{show:!1,padding:{left:0,right:0,top:0,bottom:0}},legend:{show:!1},xaxis:{labels:{show:!1},tooltip:{enabled:!1},axisBorder:{show:!1},axisTicks:{show:!1}},chart:{toolbar:{show:!1},zoom:{enabled:!1}},dataLabels:{enabled:!1}})}},{key:"bar",value:function(){return{chart:{stacked:!1,animations:{easing:"swing"}},plotOptions:{bar:{dataLabels:{position:"center"}}},dataLabels:{style:{colors:["#fff"]},background:{enabled:!1}},stroke:{width:0,lineCap:"round"},fill:{opacity:.85},legend:{markers:{shape:"square",radius:2,size:8}},tooltip:{shared:!1,intersect:!0},xaxis:{tooltip:{enabled:!1},tickPlacement:"between",crosshairs:{width:"barWidth",position:"back",fill:{type:"gradient"},dropShadow:{enabled:!1},stroke:{width:0}}}}}},{key:"candlestick",value:function(){var t=this;return{stroke:{width:1,colors:["#333"]},fill:{opacity:1},dataLabels:{enabled:!1},tooltip:{shared:!0,custom:function(e){var i=e.seriesIndex,a=e.dataPointIndex,s=e.w;return t._getBoxTooltip(s,i,a,["Open","High","","Low","Close"],"candlestick")}},states:{active:{filter:{type:"none"}}},xaxis:{crosshairs:{width:1}}}}},{key:"boxPlot",value:function(){var t=this;return{chart:{animations:{dynamicAnimation:{enabled:!1}}},stroke:{width:1,colors:["#24292e"]},dataLabels:{enabled:!1},tooltip:{shared:!0,custom:function(e){var i=e.seriesIndex,a=e.dataPointIndex,s=e.w;return t._getBoxTooltip(s,i,a,["Minimum","Q1","Median","Q3","Maximum"],"boxPlot")}},markers:{size:5,strokeWidth:1,strokeColors:"#111"},xaxis:{crosshairs:{width:1}}}}},{key:"rangeBar",value:function(){return{stroke:{width:0,lineCap:"square"},plotOptions:{bar:{borderRadius:0,dataLabels:{position:"center"}}},dataLabels:{enabled:!1,formatter:function(t,e){e.ctx;var i=e.seriesIndex,a=e.dataPointIndex,s=e.w,r=function(){var t=s.globals.seriesRangeStart[i][a];return s.globals.seriesRangeEnd[i][a]-t};return s.globals.comboCharts?"rangeBar"===s.config.series[i].type||"rangeArea"===s.config.series[i].type?r():t:r()},background:{enabled:!1},style:{colors:["#fff"]}},tooltip:{shared:!1,followCursor:!0,custom:function(t){return t.w.config.plotOptions&&t.w.config.plotOptions.bar&&t.w.config.plotOptions.bar.horizontal?function(t){var e=I(t),i=e.color,a=e.seriesName,s=e.ylabel,n=e.startVal,o=e.endVal;return O(r(r({},t),{},{color:i,seriesName:a,ylabel:s,start:n,end:o}))}(t):function(t){var e=I(t),i=e.color,a=e.seriesName,s=e.ylabel,n=e.start,o=e.end;return O(r(r({},t),{},{color:i,seriesName:a,ylabel:s,start:n,end:o}))}(t)}},xaxis:{tickPlacement:"between",tooltip:{enabled:!1},crosshairs:{stroke:{width:0}}}}}},{key:"area",value:function(){return{stroke:{width:4,fill:{type:"solid",gradient:{inverseColors:!1,shade:"light",type:"vertical",opacityFrom:.65,opacityTo:.5,stops:[0,100,100]}}},fill:{type:"gradient",gradient:{inverseColors:!1,shade:"light",type:"vertical",opacityFrom:.65,opacityTo:.5,stops:[0,100,100]}},markers:{size:0,hover:{sizeOffset:6}},tooltip:{followCursor:!1}}}},{key:"rangeArea",value:function(){return{stroke:{curve:"straight",width:0},fill:{type:"solid",opacity:.6},markers:{size:0},states:{hover:{filter:{type:"none"}},active:{filter:{type:"none"}}},tooltip:{intersect:!1,shared:!0,followCursor:!0,custom:function(t){return function(t){var e=I(t),i=e.color,a=e.seriesName,s=e.ylabel,n=e.start,o=e.end;return O(r(r({},t),{},{color:i,seriesName:a,ylabel:s,start:n,end:o}))}(t)}}}}},{key:"brush",value:function(t){return v.extend(t,{chart:{toolbar:{autoSelected:"selection",show:!1},zoom:{enabled:!1}},dataLabels:{enabled:!1},stroke:{width:1},tooltip:{enabled:!1},xaxis:{tooltip:{enabled:!1}}})}},{key:"stacked100",value:function(t){t.dataLabels=t.dataLabels||{},t.dataLabels.formatter=t.dataLabels.formatter||void 0;var e=t.dataLabels.formatter;return t.yaxis.forEach((function(e,i){t.yaxis[i].min=0,t.yaxis[i].max=100})),"bar"===t.chart.type&&(t.dataLabels.formatter=e||function(t){return"number"==typeof t&&t?t.toFixed(0)+"%":t}),t}},{key:"convertCatToNumeric",value:function(t){return t.xaxis.convertedCatToNumeric=!0,t}},{key:"convertCatToNumericXaxis",value:function(t,e,i){t.xaxis.type="numeric",t.xaxis.labels=t.xaxis.labels||{},t.xaxis.labels.formatter=t.xaxis.labels.formatter||function(t){return v.isNumber(t)?Math.floor(t):t};var a=t.xaxis.labels.formatter,s=t.xaxis.categories&&t.xaxis.categories.length?t.xaxis.categories:t.labels;return i&&i.length&&(s=i.map((function(t){return Array.isArray(t)?t:String(t)}))),s&&s.length&&(t.xaxis.labels.formatter=function(t){return v.isNumber(t)?a(s[Math.floor(t)-1]):a(t)}),t.xaxis.categories=[],t.labels=[],t.xaxis.tickAmount=t.xaxis.tickAmount||"dataPoints",t}},{key:"bubble",value:function(){return{dataLabels:{style:{colors:["#fff"]}},tooltip:{shared:!1,intersect:!0},xaxis:{crosshairs:{width:0}},fill:{type:"solid",gradient:{shade:"light",inverse:!0,shadeIntensity:.55,opacityFrom:.4,opacityTo:.8}}}}},{key:"scatter",value:function(){return{dataLabels:{enabled:!1},tooltip:{shared:!1,intersect:!0},markers:{size:6,strokeWidth:1,hover:{sizeOffset:2}}}}},{key:"heatmap",value:function(){return{chart:{stacked:!1},fill:{opacity:1},dataLabels:{style:{colors:["#fff"]}},stroke:{colors:["#fff"]},tooltip:{followCursor:!0,marker:{show:!1},x:{show:!1}},legend:{position:"top",markers:{shape:"square",size:10,offsetY:2}},grid:{padding:{right:20}}}}},{key:"treemap",value:function(){return{chart:{zoom:{enabled:!1}},dataLabels:{style:{fontSize:14,fontWeight:600,colors:["#fff"]}},stroke:{show:!0,width:2,colors:["#fff"]},legend:{show:!1},fill:{gradient:{stops:[0,100]}},tooltip:{followCursor:!0,x:{show:!1}},grid:{padding:{left:0,right:0}},xaxis:{crosshairs:{show:!1},tooltip:{enabled:!1}}}}},{key:"pie",value:function(){return{chart:{toolbar:{show:!1}},plotOptions:{pie:{donut:{labels:{show:!1}}}},dataLabels:{formatter:function(t){return t.toFixed(1)+"%"},style:{colors:["#fff"]},background:{enabled:!1},dropShadow:{enabled:!0}},stroke:{colors:["#fff"]},fill:{opacity:1,gradient:{shade:"light",stops:[0,100]}},tooltip:{theme:"dark",fillSeriesColor:!0},legend:{position:"right"}}}},{key:"donut",value:function(){return{chart:{toolbar:{show:!1}},dataLabels:{formatter:function(t){return t.toFixed(1)+"%"},style:{colors:["#fff"]},background:{enabled:!1},dropShadow:{enabled:!0}},stroke:{colors:["#fff"]},fill:{opacity:1,gradient:{shade:"light",shadeIntensity:.35,stops:[80,100],opacityFrom:1,opacityTo:1}},tooltip:{theme:"dark",fillSeriesColor:!0},legend:{position:"right"}}}},{key:"polarArea",value:function(){return this.opts.yaxis[0].tickAmount=this.opts.yaxis[0].tickAmount?this.opts.yaxis[0].tickAmount:6,{chart:{toolbar:{show:!1}},dataLabels:{formatter:function(t){return t.toFixed(1)+"%"},enabled:!1},stroke:{show:!0,width:2},fill:{opacity:.7},tooltip:{theme:"dark",fillSeriesColor:!0},legend:{position:"right"}}}},{key:"radar",value:function(){return this.opts.yaxis[0].labels.offsetY=this.opts.yaxis[0].labels.offsetY?this.opts.yaxis[0].labels.offsetY:6,{dataLabels:{enabled:!1,style:{fontSize:"11px"}},stroke:{width:2},markers:{size:3,strokeWidth:1,strokeOpacity:1},fill:{opacity:.2},tooltip:{shared:!1,intersect:!0,followCursor:!0},grid:{show:!1},xaxis:{labels:{formatter:function(t){return t},style:{colors:["#a8a8a8"],fontSize:"11px"}},tooltip:{enabled:!1},crosshairs:{show:!1}}}}},{key:"radialBar",value:function(){return{chart:{animations:{dynamicAnimation:{enabled:!0,speed:800}},toolbar:{show:!1}},fill:{gradient:{shade:"dark",shadeIntensity:.4,inverseColors:!1,type:"diagonal2",opacityFrom:1,opacityTo:1,stops:[70,98,100]}},legend:{show:!1,position:"right"},tooltip:{enabled:!1,fillSeriesColor:!0}}}},{key:"_getBoxTooltip",value:function(t,e,i,a,s){var r=t.globals.seriesCandleO[e][i],n=t.globals.seriesCandleH[e][i],o=t.globals.seriesCandleM[e][i],l=t.globals.seriesCandleL[e][i],c=t.globals.seriesCandleC[e][i];return t.config.series[e].type&&t.config.series[e].type!==s?'<div class="apexcharts-custom-tooltip">\n '.concat(t.config.series[e].name?t.config.series[e].name:"series-"+(e+1),": <strong>").concat(t.globals.series[e][i],"</strong>\n </div>"):'<div class="apexcharts-tooltip-box apexcharts-tooltip-'.concat(t.config.chart.type,'">')+"<div>".concat(a[0],': <span class="value">')+r+"</span></div>"+"<div>".concat(a[1],': <span class="value">')+n+"</span></div>"+(o?"<div>".concat(a[2],': <span class="value">')+o+"</span></div>":"")+"<div>".concat(a[3],': <span class="value">')+l+"</span></div>"+"<div>".concat(a[4],': <span class="value">')+c+"</span></div></div>"}}]),t}(),R=function(){function t(e){o(this,t),this.opts=e}return c(t,[{key:"init",value:function(t){var e=t.responsiveOverride,i=this.opts,a=new T,s=new z(i);this.chartType=i.chart.type,"histogram"===this.chartType&&(i.chart.type="bar",i=v.extend({plotOptions:{bar:{columnWidth:"99.99%"}}},i)),i=this.extendYAxis(i),i=this.extendAnnotations(i);var r=a.init(),o={};if(i&&"object"===n(i)){var l={};l=-1!==["line","area","bar","candlestick","boxPlot","rangeBar","rangeArea","histogram","bubble","scatter","heatmap","treemap","pie","polarArea","donut","radar","radialBar"].indexOf(i.chart.type)?s[i.chart.type]():s.line(),i.chart.brush&&i.chart.brush.enabled&&(l=s.brush(l)),i.chart.stacked&&"100%"===i.chart.stackType&&(i=s.stacked100(i)),this.checkForDarkTheme(window.Apex),this.checkForDarkTheme(i),i.xaxis=i.xaxis||window.Apex.xaxis||{},e||(i.xaxis.convertedCatToNumeric=!1),((i=this.checkForCatToNumericXAxis(this.chartType,l,i)).chart.sparkline&&i.chart.sparkline.enabled||window.Apex.chart&&window.Apex.chart.sparkline&&window.Apex.chart.sparkline.enabled)&&(l=s.sparkline(l)),o=v.extend(r,l)}var c=v.extend(o,window.Apex);return r=v.extend(c,i),this.handleUserInputErrors(r)}},{key:"checkForCatToNumericXAxis",value:function(t,e,i){var a=new z(i),s=("bar"===t||"boxPlot"===t)&&i.plotOptions&&i.plotOptions.bar&&i.plotOptions.bar.horizontal,r="pie"===t||"polarArea"===t||"donut"===t||"radar"===t||"radialBar"===t||"heatmap"===t,n="datetime"!==i.xaxis.type&&"numeric"!==i.xaxis.type,o=i.xaxis.tickPlacement?i.xaxis.tickPlacement:e.xaxis&&e.xaxis.tickPlacement;return s||r||!n||"between"===o||(i=a.convertCatToNumeric(i)),i}},{key:"extendYAxis",value:function(t,e){var i=new T;(void 0===t.yaxis||!t.yaxis||Array.isArray(t.yaxis)&&0===t.yaxis.length)&&(t.yaxis={}),t.yaxis.constructor!==Array&&window.Apex.yaxis&&window.Apex.yaxis.constructor!==Array&&(t.yaxis=v.extend(t.yaxis,window.Apex.yaxis)),t.yaxis.constructor!==Array?t.yaxis=[v.extend(i.yAxis,t.yaxis)]:t.yaxis=v.extendArray(t.yaxis,i.yAxis);var a=!1;t.yaxis.forEach((function(t){t.logarithmic&&(a=!0)}));var s=t.series;return e&&!s&&(s=e.config.series),a&&s.length!==t.yaxis.length&&s.length&&(t.yaxis=s.map((function(e,a){if(e.name||(s[a].name="series-".concat(a+1)),t.yaxis[a])return t.yaxis[a].seriesName=s[a].name,t.yaxis[a];var r=v.extend(i.yAxis,t.yaxis[0]);return r.show=!1,r}))),a&&s.length>1&&s.length!==t.yaxis.length&&console.warn("A multi-series logarithmic chart should have equal number of series and y-axes. Please make sure to equalize both."),t}},{key:"extendAnnotations",value:function(t){return void 0===t.annotations&&(t.annotations={},t.annotations.yaxis=[],t.annotations.xaxis=[],t.annotations.points=[]),t=this.extendYAxisAnnotations(t),t=this.extendXAxisAnnotations(t),this.extendPointAnnotations(t)}},{key:"extendYAxisAnnotations",value:function(t){var e=new T;return t.annotations.yaxis=v.extendArray(void 0!==t.annotations.yaxis?t.annotations.yaxis:[],e.yAxisAnnotation),t}},{key:"extendXAxisAnnotations",value:function(t){var e=new T;return t.annotations.xaxis=v.extendArray(void 0!==t.annotations.xaxis?t.annotations.xaxis:[],e.xAxisAnnotation),t}},{key:"extendPointAnnotations",value:function(t){var e=new T;return t.annotations.points=v.extendArray(void 0!==t.annotations.points?t.annotations.points:[],e.pointAnnotation),t}},{key:"checkForDarkTheme",value:function(t){t.theme&&"dark"===t.theme.mode&&(t.tooltip||(t.tooltip={}),"light"!==t.tooltip.theme&&(t.tooltip.theme="dark"),t.chart.foreColor||(t.chart.foreColor="#f6f7f8"),t.chart.background||(t.chart.background="#424242"),t.theme.palette||(t.theme.palette="palette4"))}},{key:"handleUserInputErrors",value:function(t){var e=t;if(e.tooltip.shared&&e.tooltip.intersect)throw new Error("tooltip.shared cannot be enabled when tooltip.intersect is true. Turn off any other option by setting it to false.");if("bar"===e.chart.type&&e.plotOptions.bar.horizontal){if(e.yaxis.length>1)throw new Error("Multiple Y Axis for bars are not supported. Switch to column chart by setting plotOptions.bar.horizontal=false");e.yaxis[0].reversed&&(e.yaxis[0].opposite=!0),e.xaxis.tooltip.enabled=!1,e.yaxis[0].tooltip.enabled=!1,e.chart.zoom.enabled=!1}return"bar"!==e.chart.type&&"rangeBar"!==e.chart.type||e.tooltip.shared&&"barWidth"===e.xaxis.crosshairs.width&&e.series.length>1&&(e.xaxis.crosshairs.width="tickWidth"),"candlestick"!==e.chart.type&&"boxPlot"!==e.chart.type||e.yaxis[0].reversed&&(console.warn("Reversed y-axis in ".concat(e.chart.type," chart is not supported.")),e.yaxis[0].reversed=!1),e}}]),t}(),Y=function(){function t(){o(this,t)}return c(t,[{key:"initGlobalVars",value:function(t){t.series=[],t.seriesCandleO=[],t.seriesCandleH=[],t.seriesCandleM=[],t.seriesCandleL=[],t.seriesCandleC=[],t.seriesRangeStart=[],t.seriesRangeEnd=[],t.seriesRange=[],t.seriesPercent=[],t.seriesGoals=[],t.seriesX=[],t.seriesZ=[],t.seriesNames=[],t.seriesTotals=[],t.seriesLog=[],t.seriesColors=[],t.stackedSeriesTotals=[],t.seriesXvalues=[],t.seriesYvalues=[],t.labels=[],t.hasGroups=!1,t.groups=[],t.categoryLabels=[],t.timescaleLabels=[],t.noLabelsProvided=!1,t.resizeTimer=null,t.selectionResizeTimer=null,t.delayedElements=[],t.pointsArray=[],t.dataLabelsRects=[],t.isXNumeric=!1,t.xaxisLabelsCount=0,t.skipLastTimelinelabel=!1,t.skipFirstTimelinelabel=!1,t.isDataXYZ=!1,t.isMultiLineX=!1,t.isMultipleYAxis=!1,t.maxY=-Number.MAX_VALUE,t.minY=Number.MIN_VALUE,t.minYArr=[],t.maxYArr=[],t.maxX=-Number.MAX_VALUE,t.minX=Number.MAX_VALUE,t.initialMaxX=-Number.MAX_VALUE,t.initialMinX=Number.MAX_VALUE,t.maxDate=0,t.minDate=Number.MAX_VALUE,t.minZ=Number.MAX_VALUE,t.maxZ=-Number.MAX_VALUE,t.minXDiff=Number.MAX_VALUE,t.yAxisScale=[],t.xAxisScale=null,t.xAxisTicksPositions=[],t.yLabelsCoords=[],t.yTitleCoords=[],t.barPadForNumericAxis=0,t.padHorizontal=0,t.xRange=0,t.yRange=[],t.zRange=0,t.dataPoints=0,t.xTickAmount=0}},{key:"globalVars",value:function(t){return{chartID:null,cuid:null,events:{beforeMount:[],mounted:[],updated:[],clicked:[],selection:[],dataPointSelection:[],zoomed:[],scrolled:[]},colors:[],clientX:null,clientY:null,fill:{colors:[]},stroke:{colors:[]},dataLabels:{style:{colors:[]}},radarPolygons:{fill:{colors:[]}},markers:{colors:[],size:t.markers.size,largestSize:0},animationEnded:!1,isTouchDevice:"ontouchstart"in window||navigator.msMaxTouchPoints,isDirty:!1,isExecCalled:!1,initialConfig:null,initialSeries:[],lastXAxis:[],lastYAxis:[],columnSeries:null,labels:[],timescaleLabels:[],noLabelsProvided:!1,allSeriesCollapsed:!1,collapsedSeries:[],collapsedSeriesIndices:[],ancillaryCollapsedSeries:[],ancillaryCollapsedSeriesIndices:[],risingSeries:[],dataFormatXNumeric:!1,capturedSeriesIndex:-1,capturedDataPointIndex:-1,selectedDataPoints:[],goldenPadding:35,invalidLogScale:!1,ignoreYAxisIndexes:[],yAxisSameScaleIndices:[],maxValsInArrayIndex:0,radialSize:0,selection:void 0,zoomEnabled:"zoom"===t.chart.toolbar.autoSelected&&t.chart.toolbar.tools.zoom&&t.chart.zoom.enabled,panEnabled:"pan"===t.chart.toolbar.autoSelected&&t.chart.toolbar.tools.pan,selectionEnabled:"selection"===t.chart.toolbar.autoSelected&&t.chart.toolbar.tools.selection,yaxis:null,mousedown:!1,lastClientPosition:{},visibleXRange:void 0,yValueDecimal:0,total:0,SVGNS:"http://www.w3.org/2000/svg",svgWidth:0,svgHeight:0,noData:!1,locale:{},dom:{},memory:{methodsToExec:[]},shouldAnimate:!0,skipLastTimelinelabel:!1,skipFirstTimelinelabel:!1,delayedElements:[],axisCharts:!0,isDataXYZ:!1,resized:!1,resizeTimer:null,comboCharts:!1,dataChanged:!1,previousPaths:[],allSeriesHasEqualX:!0,pointsArray:[],dataLabelsRects:[],lastDrawnDataLabelsIndexes:[],hasNullValues:!1,easing:null,zoomed:!1,gridWidth:0,gridHeight:0,rotateXLabels:!1,defaultLabels:!1,xLabelFormatter:void 0,yLabelFormatters:[],xaxisTooltipFormatter:void 0,ttKeyFormatter:void 0,ttVal:void 0,ttZFormatter:void 0,LINE_HEIGHT_RATIO:1.618,xAxisLabelsHeight:0,xAxisGroupLabelsHeight:0,xAxisLabelsWidth:0,yAxisLabelsWidth:0,scaleX:1,scaleY:1,translateX:0,translateY:0,translateYAxisX:[],yAxisWidths:[],translateXAxisY:0,translateXAxisX:0,tooltip:null}}},{key:"init",value:function(t){var e=this.globalVars(t);return this.initGlobalVars(e),e.initialConfig=v.extend({},t),e.initialSeries=v.clone(t.series),e.lastXAxis=v.clone(e.initialConfig.xaxis),e.lastYAxis=v.clone(e.initialConfig.yaxis),e}}]),t}(),F=function(){function t(e){o(this,t),this.opts=e}return c(t,[{key:"init",value:function(){var t=new R(this.opts).init({responsiveOverride:!1});return{config:t,globals:(new Y).init(t)}}}]),t}(),N=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w,this.opts=null,this.seriesIndex=0}return c(t,[{key:"clippedImgArea",value:function(t){var e=this.w,i=e.config,a=parseInt(e.globals.gridWidth,10),s=parseInt(e.globals.gridHeight,10),r=a>s?a:s,n=t.image,o=0,l=0;void 0===t.width&&void 0===t.height?void 0!==i.fill.image.width&&void 0!==i.fill.image.height?(o=i.fill.image.width+1,l=i.fill.image.height):(o=r+1,l=r):(o=t.width,l=t.height);var c=document.createElementNS(e.globals.SVGNS,"pattern");k.setAttrs(c,{id:t.patternID,patternUnits:t.patternUnits?t.patternUnits:"userSpaceOnUse",width:o+"px",height:l+"px"});var h=document.createElementNS(e.globals.SVGNS,"image");c.appendChild(h),h.setAttributeNS(window.SVG.xlink,"href",n),k.setAttrs(h,{x:0,y:0,preserveAspectRatio:"none",width:o+"px",height:l+"px"}),h.style.opacity=t.opacity,e.globals.dom.elDefs.node.appendChild(c)}},{key:"getSeriesIndex",value:function(t){var e=this.w;return("bar"===e.config.chart.type||"rangeBar"===e.config.chart.type)&&e.config.plotOptions.bar.distributed||"heatmap"===e.config.chart.type||"treemap"===e.config.chart.type?this.seriesIndex=t.seriesNumber:this.seriesIndex=t.seriesNumber%e.globals.series.length,this.seriesIndex}},{key:"fillPath",value:function(t){var e=this.w;this.opts=t;var i,a,s,r=this.w.config;this.seriesIndex=this.getSeriesIndex(t);var n=this.getFillColors()[this.seriesIndex];void 0!==e.globals.seriesColors[this.seriesIndex]&&(n=e.globals.seriesColors[this.seriesIndex]),"function"==typeof n&&(n=n({seriesIndex:this.seriesIndex,dataPointIndex:t.dataPointIndex,value:t.value,w:e}));var o=t.fillType?t.fillType:this.getFillType(this.seriesIndex),l=Array.isArray(r.fill.opacity)?r.fill.opacity[this.seriesIndex]:r.fill.opacity;t.color&&(n=t.color);var c=n;if(-1===n.indexOf("rgb")?n.length<9&&(c=v.hexToRgba(n,l)):n.indexOf("rgba")>-1&&(l=v.getOpacityFromRGBA(n)),t.opacity&&(l=t.opacity),"pattern"===o&&(a=this.handlePatternFill({fillConfig:t.fillConfig,patternFill:a,fillColor:n,fillOpacity:l,defaultColor:c})),"gradient"===o&&(s=this.handleGradientFill({fillConfig:t.fillConfig,fillColor:n,fillOpacity:l,i:this.seriesIndex})),"image"===o){var h=r.fill.image.src,d=t.patternID?t.patternID:"";this.clippedImgArea({opacity:l,image:Array.isArray(h)?t.seriesNumber<h.length?h[t.seriesNumber]:h[0]:h,width:t.width?t.width:void 0,height:t.height?t.height:void 0,patternUnits:t.patternUnits,patternID:"pattern".concat(e.globals.cuid).concat(t.seriesNumber+1).concat(d)}),i="url(#pattern".concat(e.globals.cuid).concat(t.seriesNumber+1).concat(d,")")}else i="gradient"===o?s:"pattern"===o?a:c;return t.solid&&(i=c),i}},{key:"getFillType",value:function(t){var e=this.w;return Array.isArray(e.config.fill.type)?e.config.fill.type[t]:e.config.fill.type}},{key:"getFillColors",value:function(){var t=this.w,e=t.config,i=this.opts,a=[];return t.globals.comboCharts?"line"===t.config.series[this.seriesIndex].type?Array.isArray(t.globals.stroke.colors)?a=t.globals.stroke.colors:a.push(t.globals.stroke.colors):Array.isArray(t.globals.fill.colors)?a=t.globals.fill.colors:a.push(t.globals.fill.colors):"line"===e.chart.type?Array.isArray(t.globals.stroke.colors)?a=t.globals.stroke.colors:a.push(t.globals.stroke.colors):Array.isArray(t.globals.fill.colors)?a=t.globals.fill.colors:a.push(t.globals.fill.colors),void 0!==i.fillColors&&(a=[],Array.isArray(i.fillColors)?a=i.fillColors.slice():a.push(i.fillColors)),a}},{key:"handlePatternFill",value:function(t){var e=t.fillConfig,i=(t.patternFill,t.fillColor),a=t.fillOpacity,s=t.defaultColor,r=this.w.config.fill;e&&(r=e);var n=this.opts,o=new k(this.ctx),l=Array.isArray(r.pattern.strokeWidth)?r.pattern.strokeWidth[this.seriesIndex]:r.pattern.strokeWidth,c=i;return Array.isArray(r.pattern.style)?void 0!==r.pattern.style[n.seriesNumber]?o.drawPattern(r.pattern.style[n.seriesNumber],r.pattern.width,r.pattern.height,c,l,a):s:o.drawPattern(r.pattern.style,r.pattern.width,r.pattern.height,c,l,a)}},{key:"handleGradientFill",value:function(t){var e=t.fillColor,i=t.fillOpacity,a=t.fillConfig,s=t.i,n=this.w.config.fill;a&&(n=r(r({},n),a));var o,l=this.opts,c=new k(this.ctx),h=new v,d=n.gradient.type,u=e,p=void 0===n.gradient.opacityFrom?i:Array.isArray(n.gradient.opacityFrom)?n.gradient.opacityFrom[s]:n.gradient.opacityFrom;u.indexOf("rgba")>-1&&(p=v.getOpacityFromRGBA(u));var f=void 0===n.gradient.opacityTo?i:Array.isArray(n.gradient.opacityTo)?n.gradient.opacityTo[s]:n.gradient.opacityTo;if(void 0===n.gradient.gradientToColors||0===n.gradient.gradientToColors.length)o="dark"===n.gradient.shade?h.shadeColor(-1*parseFloat(n.gradient.shadeIntensity),e.indexOf("rgb")>-1?v.rgb2hex(e):e):h.shadeColor(parseFloat(n.gradient.shadeIntensity),e.indexOf("rgb")>-1?v.rgb2hex(e):e);else if(n.gradient.gradientToColors[l.seriesNumber]){var g=n.gradient.gradientToColors[l.seriesNumber];o=g,g.indexOf("rgba")>-1&&(f=v.getOpacityFromRGBA(g))}else o=e;if(n.gradient.gradientFrom&&(u=n.gradient.gradientFrom),n.gradient.gradientTo&&(o=n.gradient.gradientTo),n.gradient.inverseColors){var x=u;u=o,o=x}return u.indexOf("rgb")>-1&&(u=v.rgb2hex(u)),o.indexOf("rgb")>-1&&(o=v.rgb2hex(o)),c.drawGradient(d,u,o,p,f,l.size,n.gradient.stops,n.gradient.colorStops,s)}}]),t}(),X=function(){function t(e,i){o(this,t),this.ctx=e,this.w=e.w}return c(t,[{key:"setGlobalMarkerSize",value:function(){var t=this.w;if(t.globals.markers.size=Array.isArray(t.config.markers.size)?t.config.markers.size:[t.config.markers.size],t.globals.markers.size.length>0){if(t.globals.markers.size.length<t.globals.series.length+1)for(var e=0;e<=t.globals.series.length;e++)void 0===t.globals.markers.size[e]&&t.globals.markers.size.push(t.globals.markers.size[0])}else t.globals.markers.size=t.config.series.map((function(e){return t.config.markers.size}))}},{key:"plotChartMarkers",value:function(t,e,i,a){var s,r=arguments.length>4&&void 0!==arguments[4]&&arguments[4],n=this.w,o=e,l=t,c=null,h=new k(this.ctx),d=n.config.markers.discrete&&n.config.markers.discrete.length;if((n.globals.markers.size[e]>0||r||d)&&(c=h.group({class:r||d?"":"apexcharts-series-markers"})).attr("clip-path","url(#gridRectMarkerMask".concat(n.globals.cuid,")")),Array.isArray(l.x))for(var u=0;u<l.x.length;u++){var p=i;1===i&&0===u&&(p=0),1===i&&1===u&&(p=1);var f="apexcharts-marker";"line"!==n.config.chart.type&&"area"!==n.config.chart.type||n.globals.comboCharts||n.config.tooltip.intersect||(f+=" no-pointer-events");var g=Array.isArray(n.config.markers.size)?n.globals.markers.size[e]>0:n.config.markers.size>0;if(g||r||d){v.isNumber(l.y[u])?f+=" w".concat(v.randomId()):f="apexcharts-nullpoint";var x=this.getMarkerConfig({cssClass:f,seriesIndex:e,dataPointIndex:p});n.config.series[o].data[p]&&(n.config.series[o].data[p].fillColor&&(x.pointFillColor=n.config.series[o].data[p].fillColor),n.config.series[o].data[p].strokeColor&&(x.pointStrokeColor=n.config.series[o].data[p].strokeColor)),a&&(x.pSize=a),(s=h.drawMarker(l.x[u],l.y[u],x)).attr("rel",p),s.attr("j",p),s.attr("index",e),s.node.setAttribute("default-marker-size",x.pSize);var m=new w(this.ctx);m.setSelectionFilter(s,e,p),this.addEvents(s),c&&c.add(s)}else void 0===n.globals.pointsArray[e]&&(n.globals.pointsArray[e]=[]),n.globals.pointsArray[e].push([l.x[u],l.y[u]])}return c}},{key:"getMarkerConfig",value:function(t){var e=t.cssClass,i=t.seriesIndex,a=t.dataPointIndex,s=void 0===a?null:a,r=t.finishRadius,n=void 0===r?null:r,o=this.w,l=this.getMarkerStyle(i),c=o.globals.markers.size[i],h=o.config.markers;return null!==s&&h.discrete.length&&h.discrete.map((function(t){t.seriesIndex===i&&t.dataPointIndex===s&&(l.pointStrokeColor=t.strokeColor,l.pointFillColor=t.fillColor,c=t.size,l.pointShape=t.shape)})),{pSize:null===n?c:n,pRadius:h.radius,width:Array.isArray(h.width)?h.width[i]:h.width,height:Array.isArray(h.height)?h.height[i]:h.height,pointStrokeWidth:Array.isArray(h.strokeWidth)?h.strokeWidth[i]:h.strokeWidth,pointStrokeColor:l.pointStrokeColor,pointFillColor:l.pointFillColor,shape:l.pointShape||(Array.isArray(h.shape)?h.shape[i]:h.shape),class:e,pointStrokeOpacity:Array.isArray(h.strokeOpacity)?h.strokeOpacity[i]:h.strokeOpacity,pointStrokeDashArray:Array.isArray(h.strokeDashArray)?h.strokeDashArray[i]:h.strokeDashArray,pointFillOpacity:Array.isArray(h.fillOpacity)?h.fillOpacity[i]:h.fillOpacity,seriesIndex:i}}},{key:"addEvents",value:function(t){var e=this.w,i=new k(this.ctx);t.node.addEventListener("mouseenter",i.pathMouseEnter.bind(this.ctx,t)),t.node.addEventListener("mouseleave",i.pathMouseLeave.bind(this.ctx,t)),t.node.addEventListener("mousedown",i.pathMouseDown.bind(this.ctx,t)),t.node.addEventListener("click",e.config.markers.onClick),t.node.addEventListener("dblclick",e.config.markers.onDblClick),t.node.addEventListener("touchstart",i.pathMouseDown.bind(this.ctx,t),{passive:!0})}},{key:"getMarkerStyle",value:function(t){var e=this.w,i=e.globals.markers.colors,a=e.config.markers.strokeColor||e.config.markers.strokeColors;return{pointStrokeColor:Array.isArray(a)?a[t]:a,pointFillColor:Array.isArray(i)?i[t]:i}}}]),t}(),_=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w,this.initialAnim=this.w.config.chart.animations.enabled,this.dynamicAnim=this.initialAnim&&this.w.config.chart.animations.dynamicAnimation.enabled}return c(t,[{key:"draw",value:function(t,e,i){var a=this.w,s=new k(this.ctx),r=i.realIndex,n=i.pointsPos,o=i.zRatio,l=i.elParent,c=s.group({class:"apexcharts-series-markers apexcharts-series-".concat(a.config.chart.type)});if(c.attr("clip-path","url(#gridRectMarkerMask".concat(a.globals.cuid,")")),Array.isArray(n.x))for(var h=0;h<n.x.length;h++){var d=e+1,u=!0;0===e&&0===h&&(d=0),0===e&&1===h&&(d=1);var p=0,f=a.globals.markers.size[r];if(o!==1/0){var g=a.config.plotOptions.bubble;f=a.globals.seriesZ[r][d],g.zScaling&&(f/=o),g.minBubbleRadius&&f<g.minBubbleRadius&&(f=g.minBubbleRadius),g.maxBubbleRadius&&f>g.maxBubbleRadius&&(f=g.maxBubbleRadius)}a.config.chart.animations.enabled||(p=f);var x=n.x[h],m=n.y[h];if(p=p||0,null!==m&&void 0!==a.globals.series[r][d]||(u=!1),u){var b=this.drawPoint(x,m,p,f,r,d,e);c.add(b)}l.add(c)}}},{key:"drawPoint",value:function(t,e,i,a,s,r,n){var o=this.w,l=s,c=new y(this.ctx),h=new w(this.ctx),d=new N(this.ctx),u=new X(this.ctx),p=new k(this.ctx),f=u.getMarkerConfig({cssClass:"apexcharts-marker",seriesIndex:l,dataPointIndex:r,finishRadius:"bubble"===o.config.chart.type||o.globals.comboCharts&&o.config.series[s]&&"bubble"===o.config.series[s].type?a:null});a=f.pSize;var g,x=d.fillPath({seriesNumber:s,dataPointIndex:r,color:f.pointFillColor,patternUnits:"objectBoundingBox",value:o.globals.series[s][n]});if("circle"===f.shape?g=p.drawCircle(i):"square"!==f.shape&&"rect"!==f.shape||(g=p.drawRect(0,0,f.width-f.pointStrokeWidth/2,f.height-f.pointStrokeWidth/2,f.pRadius)),o.config.series[l].data[r]&&o.config.series[l].data[r].fillColor&&(x=o.config.series[l].data[r].fillColor),g.attr({x:t-f.width/2-f.pointStrokeWidth/2,y:e-f.height/2-f.pointStrokeWidth/2,cx:t,cy:e,fill:x,"fill-opacity":f.pointFillOpacity,stroke:f.pointStrokeColor,r:a,"stroke-width":f.pointStrokeWidth,"stroke-dasharray":f.pointStrokeDashArray,"stroke-opacity":f.pointStrokeOpacity}),o.config.chart.dropShadow.enabled){var m=o.config.chart.dropShadow;h.dropShadow(g,m,s)}if(!this.initialAnim||o.globals.dataChanged||o.globals.resized)o.globals.animationEnded=!0;else{var b=o.config.chart.animations.speed;c.animateMarker(g,0,"circle"===f.shape?a:{width:f.width,height:f.height},b,o.globals.easing,(function(){window.setTimeout((function(){c.animationCompleted(g)}),100)}))}if(o.globals.dataChanged&&"circle"===f.shape)if(this.dynamicAnim){var v,A,S,C,P=o.config.chart.animations.dynamicAnimation.speed;null!=(C=o.globals.previousPaths[s]&&o.globals.previousPaths[s][n])&&(v=C.x,A=C.y,S=void 0!==C.r?C.r:a);for(var L=0;L<o.globals.collapsedSeries.length;L++)o.globals.collapsedSeries[L].index===s&&(P=1,a=0);0===t&&0===e&&(a=0),c.animateCircle(g,{cx:v,cy:A,r:S},{cx:t,cy:e,r:a},P,o.globals.easing)}else g.attr({r:a});return g.attr({rel:r,j:r,index:s,"default-marker-size":a}),h.setSelectionFilter(g,s,r),u.addEvents(g),g.node.classList.add("apexcharts-marker"),g}},{key:"centerTextInBubble",value:function(t){var e=this.w;return{y:t+=parseInt(e.config.dataLabels.style.fontSize,10)/4}}}]),t}(),H=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w}return c(t,[{key:"dataLabelsCorrection",value:function(t,e,i,a,s,r,n){var o=this.w,l=!1,c=new k(this.ctx).getTextRects(i,n),h=c.width,d=c.height;e<0&&(e=0),e>o.globals.gridHeight+d&&(e=o.globals.gridHeight+d/2),void 0===o.globals.dataLabelsRects[a]&&(o.globals.dataLabelsRects[a]=[]),o.globals.dataLabelsRects[a].push({x:t,y:e,width:h,height:d});var u=o.globals.dataLabelsRects[a].length-2,p=void 0!==o.globals.lastDrawnDataLabelsIndexes[a]?o.globals.lastDrawnDataLabelsIndexes[a][o.globals.lastDrawnDataLabelsIndexes[a].length-1]:0;if(void 0!==o.globals.dataLabelsRects[a][u]){var f=o.globals.dataLabelsRects[a][p];(t>f.x+f.width+2||e>f.y+f.height+2||t+h<f.x)&&(l=!0)}return(0===s||r)&&(l=!0),{x:t,y:e,textRects:c,drawnextLabel:l}}},{key:"drawDataLabel",value:function(t){var e=this,i=t.type,a=t.pos,s=t.i,r=t.j,n=t.isRangeStart,o=t.strokeWidth,l=void 0===o?2:o,c=this.w,h=new k(this.ctx),d=c.config.dataLabels,u=0,p=0,f=r,g=null;if(!d.enabled||!Array.isArray(a.x))return g;g=h.group({class:"apexcharts-data-labels"});for(var x=0;x<a.x.length;x++)if(u=a.x[x]+d.offsetX,p=a.y[x]+d.offsetY+l,!isNaN(u)){1===r&&0===x&&(f=0),1===r&&1===x&&(f=1);var m=c.globals.series[s][f];"rangeArea"===i&&(m=n?c.globals.seriesRangeStart[s][f]:c.globals.seriesRangeEnd[s][f]);var b="",v=function(t){return c.config.dataLabels.formatter(t,{ctx:e.ctx,seriesIndex:s,dataPointIndex:f,w:c})};"bubble"===c.config.chart.type?(b=v(m=c.globals.seriesZ[s][f]),p=a.y[x],p=new _(this.ctx).centerTextInBubble(p,s,f).y):void 0!==m&&(b=v(m)),this.plotDataLabelsText({x:u,y:p,text:b,i:s,j:f,parent:g,offsetCorrection:!0,dataLabelsConfig:c.config.dataLabels})}return g}},{key:"plotDataLabelsText",value:function(t){var e=this.w,i=new k(this.ctx),a=t.x,s=t.y,r=t.i,n=t.j,o=t.text,l=t.textAnchor,c=t.fontSize,h=t.parent,d=t.dataLabelsConfig,u=t.color,p=t.alwaysDrawDataLabel,f=t.offsetCorrection;if(!(Array.isArray(e.config.dataLabels.enabledOnSeries)&&e.config.dataLabels.enabledOnSeries.indexOf(r)<0)){var g={x:a,y:s,drawnextLabel:!0,textRects:null};f&&(g=this.dataLabelsCorrection(a,s,o,r,n,p,parseInt(d.style.fontSize,10))),e.globals.zoomed||(a=g.x,s=g.y),g.textRects&&(a<-10-g.textRects.width||a>e.globals.gridWidth+g.textRects.width+10)&&(o="");var x=e.globals.dataLabels.style.colors[r];(("bar"===e.config.chart.type||"rangeBar"===e.config.chart.type)&&e.config.plotOptions.bar.distributed||e.config.dataLabels.distributed)&&(x=e.globals.dataLabels.style.colors[n]),"function"==typeof x&&(x=x({series:e.globals.series,seriesIndex:r,dataPointIndex:n,w:e})),u&&(x=u);var m=d.offsetX,b=d.offsetY;if("bar"!==e.config.chart.type&&"rangeBar"!==e.config.chart.type||(m=0,b=0),g.drawnextLabel){var v=i.drawText({width:100,height:parseInt(d.style.fontSize,10),x:a+m,y:s+b,foreColor:x,textAnchor:l||d.textAnchor,text:o,fontSize:c||d.style.fontSize,fontFamily:d.style.fontFamily,fontWeight:d.style.fontWeight||"normal"});if(v.attr({class:"apexcharts-datalabel",cx:a,cy:s}),d.dropShadow.enabled){var y=d.dropShadow;new w(this.ctx).dropShadow(v,y)}h.add(v),void 0===e.globals.lastDrawnDataLabelsIndexes[r]&&(e.globals.lastDrawnDataLabelsIndexes[r]=[]),e.globals.lastDrawnDataLabelsIndexes[r].push(n)}}}},{key:"addBackgroundToDataLabel",value:function(t,e){var i=this.w,a=i.config.dataLabels.background,s=a.padding,r=a.padding/2,n=e.width,o=e.height,l=new k(this.ctx).drawRect(e.x-s,e.y-r/2,n+2*s,o+r,a.borderRadius,"transparent"===i.config.chart.background?"#fff":i.config.chart.background,a.opacity,a.borderWidth,a.borderColor);return a.dropShadow.enabled&&new w(this.ctx).dropShadow(l,a.dropShadow),l}},{key:"dataLabelsBackground",value:function(){var t=this.w;if("bubble"!==t.config.chart.type)for(var e=t.globals.dom.baseEl.querySelectorAll(".apexcharts-datalabels text"),i=0;i<e.length;i++){var a=e[i],s=a.getBBox(),r=null;if(s.width&&s.height&&(r=this.addBackgroundToDataLabel(a,s)),r){a.parentNode.insertBefore(r.node,a);var n=a.getAttribute("fill");!t.config.chart.animations.enabled||t.globals.resized||t.globals.dataChanged?r.attr({fill:n}):r.animate().attr({fill:n}),a.setAttribute("fill",t.config.dataLabels.background.foreColor)}}}},{key:"bringForward",value:function(){for(var t=this.w,e=t.globals.dom.baseEl.querySelectorAll(".apexcharts-datalabels"),i=t.globals.dom.baseEl.querySelector(".apexcharts-plot-series:last-child"),a=0;a<e.length;a++)i&&i.insertBefore(e[a],i.nextSibling)}}]),t}(),B=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w,this.legendInactiveClass="legend-mouseover-inactive"}return c(t,[{key:"getAllSeriesEls",value:function(){return this.w.globals.dom.baseEl.getElementsByClassName("apexcharts-series")}},{key:"getSeriesByName",value:function(t){return this.w.globals.dom.baseEl.querySelector(".apexcharts-inner .apexcharts-series[seriesName='".concat(v.escapeString(t),"']"))}},{key:"isSeriesHidden",value:function(t){var e=this.getSeriesByName(t),i=parseInt(e.getAttribute("data:realIndex"),10);return{isHidden:e.classList.contains("apexcharts-series-collapsed"),realIndex:i}}},{key:"addCollapsedClassToSeries",value:function(t,e){var i=this.w;function a(i){for(var a=0;a<i.length;a++)i[a].index===e&&t.node.classList.add("apexcharts-series-collapsed")}a(i.globals.collapsedSeries),a(i.globals.ancillaryCollapsedSeries)}},{key:"toggleSeries",value:function(t){var e=this.isSeriesHidden(t);return this.ctx.legend.legendHelpers.toggleDataSeries(e.realIndex,e.isHidden),e.isHidden}},{key:"showSeries",value:function(t){var e=this.isSeriesHidden(t);e.isHidden&&this.ctx.legend.legendHelpers.toggleDataSeries(e.realIndex,!0)}},{key:"hideSeries",value:function(t){var e=this.isSeriesHidden(t);e.isHidden||this.ctx.legend.legendHelpers.toggleDataSeries(e.realIndex,!1)}},{key:"resetSeries",value:function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],a=this.w,s=v.clone(a.globals.initialSeries);a.globals.previousPaths=[],i?(a.globals.collapsedSeries=[],a.globals.ancillaryCollapsedSeries=[],a.globals.collapsedSeriesIndices=[],a.globals.ancillaryCollapsedSeriesIndices=[]):s=this.emptyCollapsedSeries(s),a.config.series=s,t&&(e&&(a.globals.zoomed=!1,this.ctx.updateHelpers.revertDefaultAxisMinMax()),this.ctx.updateHelpers._updateSeries(s,a.config.chart.animations.dynamicAnimation.enabled))}},{key:"emptyCollapsedSeries",value:function(t){for(var e=this.w,i=0;i<t.length;i++)e.globals.collapsedSeriesIndices.indexOf(i)>-1&&(t[i].data=[]);return t}},{key:"toggleSeriesOnHover",value:function(t,e){var i=this.w;e||(e=t.target);var a=i.globals.dom.baseEl.querySelectorAll(".apexcharts-series, .apexcharts-datalabels");if("mousemove"===t.type){var s=parseInt(e.getAttribute("rel"),10)-1,r=null,n=null;i.globals.axisCharts||"radialBar"===i.config.chart.type?i.globals.axisCharts?(r=i.globals.dom.baseEl.querySelector(".apexcharts-series[data\\:realIndex='".concat(s,"']")),n=i.globals.dom.baseEl.querySelector(".apexcharts-datalabels[data\\:realIndex='".concat(s,"']"))):r=i.globals.dom.baseEl.querySelector(".apexcharts-series[rel='".concat(s+1,"']")):r=i.globals.dom.baseEl.querySelector(".apexcharts-series[rel='".concat(s+1,"'] path"));for(var o=0;o<a.length;o++)a[o].classList.add(this.legendInactiveClass);null!==r&&(i.globals.axisCharts||r.parentNode.classList.remove(this.legendInactiveClass),r.classList.remove(this.legendInactiveClass),null!==n&&n.classList.remove(this.legendInactiveClass))}else if("mouseout"===t.type)for(var l=0;l<a.length;l++)a[l].classList.remove(this.legendInactiveClass)}},{key:"highlightRangeInSeries",value:function(t,e){var i=this,a=this.w,s=a.globals.dom.baseEl.getElementsByClassName("apexcharts-heatmap-rect"),r=function(t){for(var e=0;e<s.length;e++)s[e].classList[t](i.legendInactiveClass)};if("mousemove"===t.type){var n=parseInt(e.getAttribute("rel"),10)-1;r("add"),function(t){for(var e=0;e<s.length;e++){var a=parseInt(s[e].getAttribute("val"),10);a>=t.from&&a<=t.to&&s[e].classList.remove(i.legendInactiveClass)}}(a.config.plotOptions.heatmap.colorScale.ranges[n])}else"mouseout"===t.type&&r("remove")}},{key:"getActiveConfigSeriesIndex",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"asc",e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],i=this.w,a=0;if(i.config.series.length>1)for(var s=i.config.series.map((function(t,a){return t.data&&t.data.length>0&&-1===i.globals.collapsedSeriesIndices.indexOf(a)&&(!i.globals.comboCharts||0===e.length||e.length&&e.indexOf(i.config.series[a].type)>-1)?a:-1})),r="asc"===t?0:s.length-1;"asc"===t?r<s.length:r>=0;"asc"===t?r++:r--)if(-1!==s[r]){a=s[r];break}return a}},{key:"getBarSeriesIndices",value:function(){return this.w.globals.comboCharts?this.w.config.series.map((function(t,e){return"bar"===t.type||"column"===t.type?e:-1})).filter((function(t){return-1!==t})):this.w.config.series.map((function(t,e){return e}))}},{key:"getPreviousPaths",value:function(){var t=this.w;function e(e,i,a){for(var s=e[i].childNodes,r={type:a,paths:[],realIndex:e[i].getAttribute("data:realIndex")},n=0;n<s.length;n++)if(s[n].hasAttribute("pathTo")){var o=s[n].getAttribute("pathTo");r.paths.push({d:o})}t.globals.previousPaths.push(r)}t.globals.previousPaths=[],["line","area","bar","rangebar","rangeArea","candlestick","radar"].forEach((function(i){for(var a,s=(a=i,t.globals.dom.baseEl.querySelectorAll(".apexcharts-".concat(a,"-series .apexcharts-series"))),r=0;r<s.length;r++)e(s,r,i)})),this.handlePrevBubbleScatterPaths("bubble"),this.handlePrevBubbleScatterPaths("scatter");var i=t.globals.dom.baseEl.querySelectorAll(".apexcharts-".concat(t.config.chart.type," .apexcharts-series"));if(i.length>0)for(var a=function(e){for(var i=t.globals.dom.baseEl.querySelectorAll(".apexcharts-".concat(t.config.chart.type," .apexcharts-series[data\\:realIndex='").concat(e,"'] rect")),a=[],s=function(t){var e=function(e){return i[t].getAttribute(e)},s={x:parseFloat(e("x")),y:parseFloat(e("y")),width:parseFloat(e("width")),height:parseFloat(e("height"))};a.push({rect:s,color:i[t].getAttribute("color")})},r=0;r<i.length;r++)s(r);t.globals.previousPaths.push(a)},s=0;s<i.length;s++)a(s);t.globals.axisCharts||(t.globals.previousPaths=t.globals.series)}},{key:"handlePrevBubbleScatterPaths",value:function(t){var e=this.w,i=e.globals.dom.baseEl.querySelectorAll(".apexcharts-".concat(t,"-series .apexcharts-series"));if(i.length>0)for(var a=0;a<i.length;a++){for(var s=e.globals.dom.baseEl.querySelectorAll(".apexcharts-".concat(t,"-series .apexcharts-series[data\\:realIndex='").concat(a,"'] circle")),r=[],n=0;n<s.length;n++)r.push({x:s[n].getAttribute("cx"),y:s[n].getAttribute("cy"),r:s[n].getAttribute("r")});e.globals.previousPaths.push(r)}}},{key:"clearPreviousPaths",value:function(){var t=this.w;t.globals.previousPaths=[],t.globals.allSeriesCollapsed=!1}},{key:"handleNoData",value:function(){var t=this.w,e=t.config.noData,i=new k(this.ctx),a=t.globals.svgWidth/2,s=t.globals.svgHeight/2,r="middle";if(t.globals.noData=!0,t.globals.animationEnded=!0,"left"===e.align?(a=10,r="start"):"right"===e.align&&(a=t.globals.svgWidth-10,r="end"),"top"===e.verticalAlign?s=50:"bottom"===e.verticalAlign&&(s=t.globals.svgHeight-50),a+=e.offsetX,s=s+parseInt(e.style.fontSize,10)+2+e.offsetY,void 0!==e.text&&""!==e.text){var n=i.drawText({x:a,y:s,text:e.text,textAnchor:r,fontSize:e.style.fontSize,fontFamily:e.style.fontFamily,foreColor:e.style.color,opacity:1,class:"apexcharts-text-nodata"});t.globals.dom.Paper.add(n)}}},{key:"setNullSeriesToZeroValues",value:function(t){for(var e=this.w,i=0;i<t.length;i++)if(0===t[i].length)for(var a=0;a<t[e.globals.maxValsInArrayIndex].length;a++)t[i].push(0);return t}},{key:"hasAllSeriesEqualX",value:function(){for(var t=!0,e=this.w,i=this.filteredSeriesX(),a=0;a<i.length-1;a++)if(i[a][0]!==i[a+1][0]){t=!1;break}return e.globals.allSeriesHasEqualX=t,t}},{key:"filteredSeriesX",value:function(){return this.w.globals.seriesX.map((function(t){return t.length>0?t:[]}))}}]),t}(),W=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w,this.twoDSeries=[],this.threeDSeries=[],this.twoDSeriesX=[],this.seriesGoals=[],this.coreUtils=new A(this.ctx)}return c(t,[{key:"isMultiFormat",value:function(){return this.isFormatXY()||this.isFormat2DArray()}},{key:"isFormatXY",value:function(){var t=this.w.config.series.slice(),e=new B(this.ctx);if(this.activeSeriesIndex=e.getActiveConfigSeriesIndex(),void 0!==t[this.activeSeriesIndex].data&&t[this.activeSeriesIndex].data.length>0&&null!==t[this.activeSeriesIndex].data[0]&&void 0!==t[this.activeSeriesIndex].data[0].x&&null!==t[this.activeSeriesIndex].data[0])return!0}},{key:"isFormat2DArray",value:function(){var t=this.w.config.series.slice(),e=new B(this.ctx);if(this.activeSeriesIndex=e.getActiveConfigSeriesIndex(),void 0!==t[this.activeSeriesIndex].data&&t[this.activeSeriesIndex].data.length>0&&void 0!==t[this.activeSeriesIndex].data[0]&&null!==t[this.activeSeriesIndex].data[0]&&t[this.activeSeriesIndex].data[0].constructor===Array)return!0}},{key:"handleFormat2DArray",value:function(t,e){for(var i=this.w.config,a=this.w.globals,s="boxPlot"===i.chart.type||"boxPlot"===i.series[e].type,r=0;r<t[e].data.length;r++)if(void 0!==t[e].data[r][1]&&(Array.isArray(t[e].data[r][1])&&4===t[e].data[r][1].length&&!s?this.twoDSeries.push(v.parseNumber(t[e].data[r][1][3])):t[e].data[r].length>=5?this.twoDSeries.push(v.parseNumber(t[e].data[r][4])):this.twoDSeries.push(v.parseNumber(t[e].data[r][1])),a.dataFormatXNumeric=!0),"datetime"===i.xaxis.type){var n=new Date(t[e].data[r][0]);n=new Date(n).getTime(),this.twoDSeriesX.push(n)}else this.twoDSeriesX.push(t[e].data[r][0]);for(var o=0;o<t[e].data.length;o++)void 0!==t[e].data[o][2]&&(this.threeDSeries.push(t[e].data[o][2]),a.isDataXYZ=!0)}},{key:"handleFormatXY",value:function(t,e){var i=this.w.config,a=this.w.globals,s=new E(this.ctx),r=e;a.collapsedSeriesIndices.indexOf(e)>-1&&(r=this.activeSeriesIndex);for(var n=0;n<t[e].data.length;n++)void 0!==t[e].data[n].y&&(Array.isArray(t[e].data[n].y)?this.twoDSeries.push(v.parseNumber(t[e].data[n].y[t[e].data[n].y.length-1])):this.twoDSeries.push(v.parseNumber(t[e].data[n].y))),void 0!==t[e].data[n].goals&&Array.isArray(t[e].data[n].goals)?(void 0===this.seriesGoals[e]&&(this.seriesGoals[e]=[]),this.seriesGoals[e].push(t[e].data[n].goals)):(void 0===this.seriesGoals[e]&&(this.seriesGoals[e]=[]),this.seriesGoals[e].push(null));for(var o=0;o<t[r].data.length;o++){var l="string"==typeof t[r].data[o].x,c=Array.isArray(t[r].data[o].x),h=!c&&!!s.isValidDate(t[r].data[o].x.toString());if(l||h)if(l||i.xaxis.convertedCatToNumeric){var d=a.isBarHorizontal&&a.isRangeData;"datetime"!==i.xaxis.type||d?(this.fallbackToCategory=!0,this.twoDSeriesX.push(t[r].data[o].x)):this.twoDSeriesX.push(s.parseDate(t[r].data[o].x))}else"datetime"===i.xaxis.type?this.twoDSeriesX.push(s.parseDate(t[r].data[o].x.toString())):(a.dataFormatXNumeric=!0,a.isXNumeric=!0,this.twoDSeriesX.push(parseFloat(t[r].data[o].x)));else c?(this.fallbackToCategory=!0,this.twoDSeriesX.push(t[r].data[o].x)):(a.isXNumeric=!0,a.dataFormatXNumeric=!0,this.twoDSeriesX.push(t[r].data[o].x))}if(t[e].data[0]&&void 0!==t[e].data[0].z){for(var u=0;u<t[e].data.length;u++)this.threeDSeries.push(t[e].data[u].z);a.isDataXYZ=!0}}},{key:"handleRangeData",value:function(t,e){var i=this.w.globals,a={};return this.isFormat2DArray()?a=this.handleRangeDataFormat("array",t,e):this.isFormatXY()&&(a=this.handleRangeDataFormat("xy",t,e)),i.seriesRangeStart.push(a.start),i.seriesRangeEnd.push(a.end),i.seriesRange.push(a.rangeUniques),i.seriesRange.forEach((function(t,e){t&&t.forEach((function(t,e){t.y.forEach((function(e,i){for(var a=0;a<t.y.length;a++)if(i!==a){var s=e.y1,r=e.y2,n=t.y[a].y1;s<=t.y[a].y2&&n<=r&&(t.overlaps.indexOf(e.rangeName)<0&&t.overlaps.push(e.rangeName),t.overlaps.indexOf(t.y[a].rangeName)<0&&t.overlaps.push(t.y[a].rangeName))}}))}))})),a}},{key:"handleCandleStickBoxData",value:function(t,e){var i=this.w.globals,a={};return this.isFormat2DArray()?a=this.handleCandleStickBoxDataFormat("array",t,e):this.isFormatXY()&&(a=this.handleCandleStickBoxDataFormat("xy",t,e)),i.seriesCandleO[e]=a.o,i.seriesCandleH[e]=a.h,i.seriesCandleM[e]=a.m,i.seriesCandleL[e]=a.l,i.seriesCandleC[e]=a.c,a}},{key:"handleRangeDataFormat",value:function(t,e,i){var a=[],s=[],r=e[i].data.filter((function(t,e,i){return e===i.findIndex((function(e){return e.x===t.x}))})).map((function(t,e){return{x:t.x,overlaps:[],y:[]}}));if("array"===t)for(var n=0;n<e[i].data.length;n++)Array.isArray(e[i].data[n])?(a.push(e[i].data[n][1][0]),s.push(e[i].data[n][1][1])):(a.push(e[i].data[n]),s.push(e[i].data[n]));else if("xy"===t)for(var o=function(t){var n=Array.isArray(e[i].data[t].y),o=v.randomId(),l=e[i].data[t].x,c={y1:n?e[i].data[t].y[0]:e[i].data[t].y,y2:n?e[i].data[t].y[1]:e[i].data[t].y,rangeName:o};e[i].data[t].rangeName=o;var h=r.findIndex((function(t){return t.x===l}));r[h].y.push(c),a.push(c.y1),s.push(c.y2)},l=0;l<e[i].data.length;l++)o(l);return{start:a,end:s,rangeUniques:r}}},{key:"handleCandleStickBoxDataFormat",value:function(t,e,i){var a=this.w,s="boxPlot"===a.config.chart.type||"boxPlot"===a.config.series[i].type,r=[],n=[],o=[],l=[],c=[];if("array"===t)if(s&&6===e[i].data[0].length||!s&&5===e[i].data[0].length)for(var h=0;h<e[i].data.length;h++)r.push(e[i].data[h][1]),n.push(e[i].data[h][2]),s?(o.push(e[i].data[h][3]),l.push(e[i].data[h][4]),c.push(e[i].data[h][5])):(l.push(e[i].data[h][3]),c.push(e[i].data[h][4]));else for(var d=0;d<e[i].data.length;d++)Array.isArray(e[i].data[d][1])&&(r.push(e[i].data[d][1][0]),n.push(e[i].data[d][1][1]),s?(o.push(e[i].data[d][1][2]),l.push(e[i].data[d][1][3]),c.push(e[i].data[d][1][4])):(l.push(e[i].data[d][1][2]),c.push(e[i].data[d][1][3])));else if("xy"===t)for(var u=0;u<e[i].data.length;u++)Array.isArray(e[i].data[u].y)&&(r.push(e[i].data[u].y[0]),n.push(e[i].data[u].y[1]),s?(o.push(e[i].data[u].y[2]),l.push(e[i].data[u].y[3]),c.push(e[i].data[u].y[4])):(l.push(e[i].data[u].y[2]),c.push(e[i].data[u].y[3])));return{o:r,h:n,m:o,l:l,c:c}}},{key:"parseDataAxisCharts",value:function(t){var e=this,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.ctx,a=this.w.config,s=this.w.globals,r=new E(i),n=a.labels.length>0?a.labels.slice():a.xaxis.categories.slice();s.isRangeBar="rangeBar"===a.chart.type&&s.isBarHorizontal,s.hasGroups="category"===a.xaxis.type&&a.xaxis.group.groups.length>0,s.hasGroups&&(s.groups=a.xaxis.group.groups);for(var o=function(){for(var t=0;t<n.length;t++)if("string"==typeof n[t]){if(!r.isValidDate(n[t]))throw new Error("You have provided invalid Date format. Please provide a valid JavaScript Date");e.twoDSeriesX.push(r.parseDate(n[t]))}else e.twoDSeriesX.push(n[t])},l=0;l<t.length;l++){if(this.twoDSeries=[],this.twoDSeriesX=[],this.threeDSeries=[],void 0===t[l].data)return void console.error("It is a possibility that you may have not included 'data' property in series.");if("rangeBar"!==a.chart.type&&"rangeArea"!==a.chart.type&&"rangeBar"!==t[l].type&&"rangeArea"!==t[l].type||(s.isRangeData=!0,s.isComboCharts?"rangeBar"!==t[l].type&&"rangeArea"!==t[l].type||this.handleRangeData(t,l):"rangeBar"!==a.chart.type&&"rangeArea"!==a.chart.type||this.handleRangeData(t,l)),this.isMultiFormat())this.isFormat2DArray()?this.handleFormat2DArray(t,l):this.isFormatXY()&&this.handleFormatXY(t,l),"candlestick"!==a.chart.type&&"candlestick"!==t[l].type&&"boxPlot"!==a.chart.type&&"boxPlot"!==t[l].type||this.handleCandleStickBoxData(t,l),s.series.push(this.twoDSeries),s.labels.push(this.twoDSeriesX),s.seriesX.push(this.twoDSeriesX),s.seriesGoals=this.seriesGoals,l!==this.activeSeriesIndex||this.fallbackToCategory||(s.isXNumeric=!0);else{"datetime"===a.xaxis.type?(s.isXNumeric=!0,o(),s.seriesX.push(this.twoDSeriesX)):"numeric"===a.xaxis.type&&(s.isXNumeric=!0,n.length>0&&(this.twoDSeriesX=n,s.seriesX.push(this.twoDSeriesX))),s.labels.push(this.twoDSeriesX);var c=t[l].data.map((function(t){return v.parseNumber(t)}));s.series.push(c)}s.seriesZ.push(this.threeDSeries),void 0!==t[l].name?s.seriesNames.push(t[l].name):s.seriesNames.push("series-"+parseInt(l+1,10)),void 0!==t[l].color?s.seriesColors.push(t[l].color):s.seriesColors.push(void 0)}return this.w}},{key:"parseDataNonAxisCharts",value:function(t){var e=this.w.globals,i=this.w.config;e.series=t.slice(),e.seriesNames=i.labels.slice();for(var a=0;a<e.series.length;a++)void 0===e.seriesNames[a]&&e.seriesNames.push("series-"+(a+1));return this.w}},{key:"handleExternalLabelsData",value:function(t){var e=this.w.config,i=this.w.globals;e.xaxis.categories.length>0?i.labels=e.xaxis.categories:e.labels.length>0?i.labels=e.labels.slice():this.fallbackToCategory?(i.labels=i.labels[0],i.seriesRange.length&&(i.seriesRange.map((function(t){t.forEach((function(t){i.labels.indexOf(t.x)<0&&t.x&&i.labels.push(t.x)}))})),i.labels=i.labels.filter((function(t,e,i){return i.indexOf(t)===e}))),e.xaxis.convertedCatToNumeric&&(new z(e).convertCatToNumericXaxis(e,this.ctx,i.seriesX[0]),this._generateExternalLabels(t))):this._generateExternalLabels(t)}},{key:"_generateExternalLabels",value:function(t){var e=this.w.globals,i=this.w.config,a=[];if(e.axisCharts){if(e.series.length>0)if(this.isFormatXY())for(var s=i.series.map((function(t,e){return t.data.filter((function(t,e,i){return i.findIndex((function(e){return e.x===t.x}))===e}))})),r=s.reduce((function(t,e,i,a){return a[t].length>e.length?t:i}),0),n=0;n<s[r].length;n++)a.push(n+1);else for(var o=0;o<e.series[e.maxValsInArrayIndex].length;o++)a.push(o+1);e.seriesX=[];for(var l=0;l<t.length;l++)e.seriesX.push(a);e.isXNumeric=!0}if(0===a.length){a=e.axisCharts?[]:e.series.map((function(t,e){return e+1}));for(var c=0;c<t.length;c++)e.seriesX.push(a)}e.labels=a,i.xaxis.convertedCatToNumeric&&(e.categoryLabels=a.map((function(t){return i.xaxis.labels.formatter(t)}))),e.noLabelsProvided=!0}},{key:"parseData",value:function(t){var e=this.w,i=e.config,a=e.globals;if(this.excludeCollapsedSeriesInYAxis(),this.fallbackToCategory=!1,this.ctx.core.resetGlobals(),this.ctx.core.isMultipleY(),a.axisCharts?(this.parseDataAxisCharts(t),this.coreUtils.getLargestSeries()):this.parseDataNonAxisCharts(t),"bar"===i.chart.type&&i.chart.stacked){var s=new B(this.ctx);a.series=s.setNullSeriesToZeroValues(a.series)}this.coreUtils.getSeriesTotals(),a.axisCharts&&(a.stackedSeriesTotals=this.coreUtils.getStackedSeriesTotals()),this.coreUtils.getPercentSeries(),a.dataFormatXNumeric||a.isXNumeric&&("numeric"!==i.xaxis.type||0!==i.labels.length||0!==i.xaxis.categories.length)||this.handleExternalLabelsData(t);for(var r=this.coreUtils.getCategoryLabels(a.labels),n=0;n<r.length;n++)if(Array.isArray(r[n])){a.isMultiLineX=!0;break}}},{key:"excludeCollapsedSeriesInYAxis",value:function(){var t=this,e=this.w;e.globals.ignoreYAxisIndexes=e.globals.collapsedSeries.map((function(i,a){if(t.w.globals.isMultipleYAxis&&!e.config.chart.stacked)return i.index}))}}]),t}(),j=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w,this.tooltipKeyFormat="dd MMM"}return c(t,[{key:"xLabelFormat",value:function(t,e,i,a){var s=this.w;if("datetime"===s.config.xaxis.type&&void 0===s.config.xaxis.labels.formatter&&void 0===s.config.tooltip.x.formatter){var r=new E(this.ctx);return r.formatDate(r.getDate(e),s.config.tooltip.x.format)}return t(e,i,a)}},{key:"defaultGeneralFormatter",value:function(t){return Array.isArray(t)?t.map((function(t){return t})):t}},{key:"defaultYFormatter",value:function(t,e,i){var a=this.w;return v.isNumber(t)&&(t=0!==a.globals.yValueDecimal?t.toFixed(void 0!==e.decimalsInFloat?e.decimalsInFloat:a.globals.yValueDecimal):a.globals.maxYArr[i]-a.globals.minYArr[i]<5?t.toFixed(1):t.toFixed(0)),t}},{key:"setLabelFormatters",value:function(){var t=this,e=this.w;return e.globals.xaxisTooltipFormatter=function(e){return t.defaultGeneralFormatter(e)},e.globals.ttKeyFormatter=function(e){return t.defaultGeneralFormatter(e)},e.globals.ttZFormatter=function(t){return t},e.globals.legendFormatter=function(e){return t.defaultGeneralFormatter(e)},void 0!==e.config.xaxis.labels.formatter?e.globals.xLabelFormatter=e.config.xaxis.labels.formatter:e.globals.xLabelFormatter=function(t){if(v.isNumber(t)){if(!e.config.xaxis.convertedCatToNumeric&&"numeric"===e.config.xaxis.type){if(v.isNumber(e.config.xaxis.decimalsInFloat))return t.toFixed(e.config.xaxis.decimalsInFloat);var i=e.globals.maxX-e.globals.minX;return i>0&&i<100?t.toFixed(1):t.toFixed(0)}return e.globals.isBarHorizontal&&e.globals.maxY-e.globals.minYArr<4?t.toFixed(1):t.toFixed(0)}return t},"function"==typeof e.config.tooltip.x.formatter?e.globals.ttKeyFormatter=e.config.tooltip.x.formatter:e.globals.ttKeyFormatter=e.globals.xLabelFormatter,"function"==typeof e.config.xaxis.tooltip.formatter&&(e.globals.xaxisTooltipFormatter=e.config.xaxis.tooltip.formatter),(Array.isArray(e.config.tooltip.y)||void 0!==e.config.tooltip.y.formatter)&&(e.globals.ttVal=e.config.tooltip.y),void 0!==e.config.tooltip.z.formatter&&(e.globals.ttZFormatter=e.config.tooltip.z.formatter),void 0!==e.config.legend.formatter&&(e.globals.legendFormatter=e.config.legend.formatter),e.config.yaxis.forEach((function(i,a){void 0!==i.labels.formatter?e.globals.yLabelFormatters[a]=i.labels.formatter:e.globals.yLabelFormatters[a]=function(s){return e.globals.xyCharts?Array.isArray(s)?s.map((function(e){return t.defaultYFormatter(e,i,a)})):t.defaultYFormatter(s,i,a):s}})),e.globals}},{key:"heatmapLabelFormatters",value:function(){var t=this.w;if("heatmap"===t.config.chart.type){t.globals.yAxisScale[0].result=t.globals.seriesNames.slice();var e=t.globals.seriesNames.reduce((function(t,e){return t.length>e.length?t:e}),0);t.globals.yAxisScale[0].niceMax=e,t.globals.yAxisScale[0].niceMin=e}}}]),t}(),V=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w}return c(t,[{key:"getLabel",value:function(t,e,i,a){var s=arguments.length>4&&void 0!==arguments[4]?arguments[4]:[],r=arguments.length>5&&void 0!==arguments[5]?arguments[5]:"12px",n=!(arguments.length>6&&void 0!==arguments[6])||arguments[6],o=this.w,l=void 0===t[a]?"":t[a],c=l,h=o.globals.xLabelFormatter,d=o.config.xaxis.labels.formatter,u=!1,p=new j(this.ctx),f=l;n&&(c=p.xLabelFormat(h,l,f,{i:a,dateFormatter:new E(this.ctx).formatDate,w:o}),void 0!==d&&(c=d(l,t[a],{i:a,dateFormatter:new E(this.ctx).formatDate,w:o})));var g=function(t){var i=null;return e.forEach((function(t){"month"===t.unit?i="year":"day"===t.unit?i="month":"hour"===t.unit?i="day":"minute"===t.unit&&(i="hour")})),i===t};e.length>0?(u=g(e[a].unit),i=e[a].position,c=e[a].value):"datetime"===o.config.xaxis.type&&void 0===d&&(c=""),void 0===c&&(c=""),c=Array.isArray(c)?c:c.toString();var x=new k(this.ctx),m={};m=o.globals.rotateXLabels&&n?x.getTextRects(c,parseInt(r,10),null,"rotate(".concat(o.config.xaxis.labels.rotate," 0 0)"),!1):x.getTextRects(c,parseInt(r,10));var b=!o.config.xaxis.labels.showDuplicates&&this.ctx.timeScale;return!Array.isArray(c)&&(0===c.indexOf("NaN")||0===c.toLowerCase().indexOf("invalid")||c.toLowerCase().indexOf("infinity")>=0||s.indexOf(c)>=0&&b)&&(c=""),{x:i,text:c,textRect:m,isBold:u}}},{key:"checkLabelBasedOnTickamount",value:function(t,e,i){var a=this.w,s=a.config.xaxis.tickAmount;return"dataPoints"===s&&(s=Math.round(a.globals.gridWidth/120)),s>i||t%Math.round(i/(s+1))==0||(e.text=""),e}},{key:"checkForOverflowingLabels",value:function(t,e,i,a,s){var r=this.w;if(0===t&&r.globals.skipFirstTimelinelabel&&(e.text=""),t===i-1&&r.globals.skipLastTimelinelabel&&(e.text=""),r.config.xaxis.labels.hideOverlappingLabels&&a.length>0){var n=s[s.length-1];e.x<n.textRect.width/(r.globals.rotateXLabels?Math.abs(r.config.xaxis.labels.rotate)/12:1.01)+n.x&&(e.text="")}return e}},{key:"checkForReversedLabels",value:function(t,e){var i=this.w;return i.config.yaxis[t]&&i.config.yaxis[t].reversed&&e.reverse(),e}},{key:"isYAxisHidden",value:function(t){var e=this.w,i=new A(this.ctx);return!e.config.yaxis[t].show||!e.config.yaxis[t].showForNullSeries&&i.isSeriesNull(t)&&-1===e.globals.collapsedSeriesIndices.indexOf(t)}},{key:"getYAxisForeColor",value:function(t,e){var i=this.w;return Array.isArray(t)&&i.globals.yAxisScale[e]&&this.ctx.theme.pushExtraColors(t,i.globals.yAxisScale[e].result.length,!1),t}},{key:"drawYAxisTicks",value:function(t,e,i,a,s,r,n){var o=this.w,l=new k(this.ctx),c=o.globals.translateY;if(a.show&&e>0){!0===o.config.yaxis[s].opposite&&(t+=a.width);for(var h=e;h>=0;h--){var d=c+e/10+o.config.yaxis[s].labels.offsetY-1;o.globals.isBarHorizontal&&(d=r*h),"heatmap"===o.config.chart.type&&(d+=r/2);var u=l.drawLine(t+i.offsetX-a.width+a.offsetX,d+a.offsetY,t+i.offsetX+a.offsetX,d+a.offsetY,a.color);n.add(u),c+=r}}}}]),t}(),G=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w}return c(t,[{key:"scaleSvgNode",value:function(t,e){var i=parseFloat(t.getAttributeNS(null,"width")),a=parseFloat(t.getAttributeNS(null,"height"));t.setAttributeNS(null,"width",i*e),t.setAttributeNS(null,"height",a*e),t.setAttributeNS(null,"viewBox","0 0 "+i+" "+a)}},{key:"fixSvgStringForIe11",value:function(t){if(!v.isIE11())return t.replace(/&nbsp;/g,"&#160;");var e=0,i=t.replace(/xmlns="http:\/\/www.w3.org\/2000\/svg"/g,(function(t){return 2==++e?'xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svgjs="http://svgjs.dev"':t}));return(i=i.replace(/xmlns:NS\d+=""/g,"")).replace(/NS\d+:(\w+:\w+=")/g,"$1")}},{key:"getSvgString",value:function(t){null==t&&(t=1);var e=this.w.globals.dom.Paper.svg();if(1!==t){var i=this.w.globals.dom.Paper.node.cloneNode(!0);this.scaleSvgNode(i,t),e=(new XMLSerializer).serializeToString(i)}return this.fixSvgStringForIe11(e)}},{key:"cleanup",value:function(){var t=this.w,e=t.globals.dom.baseEl.getElementsByClassName("apexcharts-xcrosshairs"),i=t.globals.dom.baseEl.getElementsByClassName("apexcharts-ycrosshairs"),a=t.globals.dom.baseEl.querySelectorAll(".apexcharts-zoom-rect, .apexcharts-selection-rect");Array.prototype.forEach.call(a,(function(t){t.setAttribute("width",0)})),e&&e[0]&&(e[0].setAttribute("x",-500),e[0].setAttribute("x1",-500),e[0].setAttribute("x2",-500)),i&&i[0]&&(i[0].setAttribute("y",-100),i[0].setAttribute("y1",-100),i[0].setAttribute("y2",-100))}},{key:"svgUrl",value:function(){this.cleanup();var t=this.getSvgString(),e=new Blob([t],{type:"image/svg+xml;charset=utf-8"});return URL.createObjectURL(e)}},{key:"dataURI",value:function(t){var e=this;return new Promise((function(i){var a=e.w,s=t?t.scale||t.width/a.globals.svgWidth:1;e.cleanup();var r=document.createElement("canvas");r.width=a.globals.svgWidth*s,r.height=parseInt(a.globals.dom.elWrap.style.height,10)*s;var n="transparent"===a.config.chart.background?"#fff":a.config.chart.background,o=r.getContext("2d");o.fillStyle=n,o.fillRect(0,0,r.width*s,r.height*s);var l=e.getSvgString(s);if(window.canvg&&v.isIE11()){var c=window.canvg.Canvg.fromString(o,l,{ignoreClear:!0,ignoreDimensions:!0});c.start();var h=r.msToBlob();c.stop(),i({blob:h})}else{var d="data:image/svg+xml,"+encodeURIComponent(l),u=new Image;u.crossOrigin="anonymous",u.onload=function(){if(o.drawImage(u,0,0),r.msToBlob){var t=r.msToBlob();i({blob:t})}else{var e=r.toDataURL("image/png");i({imgURI:e})}},u.src=d}}))}},{key:"exportToSVG",value:function(){this.triggerDownload(this.svgUrl(),this.w.config.chart.toolbar.export.svg.filename,".svg")}},{key:"exportToPng",value:function(){var t=this;this.dataURI().then((function(e){var i=e.imgURI,a=e.blob;a?navigator.msSaveOrOpenBlob(a,t.w.globals.chartID+".png"):t.triggerDownload(i,t.w.config.chart.toolbar.export.png.filename,".png")}))}},{key:"exportToCSV",value:function(t){var e=this,i=t.series,a=t.fileName,s=t.columnDelimiter,r=void 0===s?",":s,n=t.lineDelimiter,o=void 0===n?"\n":n,l=this.w;i||(i=l.config.series);var c=[],h=[],d="",u=l.globals.series.map((function(t,e){return-1===l.globals.collapsedSeriesIndices.indexOf(e)?t:[]})),p=Math.max.apply(Math,x(i.map((function(t){return t.data?t.data.length:0})))),f=new W(this.ctx),g=new V(this.ctx),m=function(t){var i="";if(l.globals.axisCharts){if("category"===l.config.xaxis.type||l.config.xaxis.convertedCatToNumeric)if(l.globals.isBarHorizontal){var a=l.globals.yLabelFormatters[0],s=new B(e.ctx).getActiveConfigSeriesIndex();i=a(l.globals.labels[t],{seriesIndex:s,dataPointIndex:t,w:l})}else i=g.getLabel(l.globals.labels,l.globals.timescaleLabels,0,t).text;"datetime"===l.config.xaxis.type&&(l.config.xaxis.categories.length?i=l.config.xaxis.categories[t]:l.config.labels.length&&(i=l.config.labels[t]))}else i=l.config.labels[t];return Array.isArray(i)&&(i=i.join(" ")),v.isNumber(i)?i:i.split(r).join("")};c.push(l.config.chart.toolbar.export.csv.headerCategory),"boxPlot"===l.config.chart.type?(c.push("minimum"),c.push("q1"),c.push("median"),c.push("q3"),c.push("maximum")):"candlestick"===l.config.chart.type?(c.push("open"),c.push("high"),c.push("low"),c.push("close")):"rangeBar"===l.config.chart.type?(c.push("minimum"),c.push("maximum")):i.map((function(t,e){var i=t.name?t.name:"series-".concat(e);l.globals.axisCharts&&c.push(i.split(r).join("")?i.split(r).join(""):"series-".concat(e))})),l.globals.axisCharts||(c.push(l.config.chart.toolbar.export.csv.headerValue),h.push(c.join(r))),i.map((function(t,e){l.globals.axisCharts?function(t,e){if(c.length&&0===e&&h.push(c.join(r)),t.data){t.data=t.data.length&&t.data||x(Array(p)).map((function(){return""}));for(var a=0;a<t.data.length;a++){c=[];var s=m(a);if(s||(f.isFormatXY()?s=i[e].data[a].x:f.isFormat2DArray()&&(s=i[e].data[a]?i[e].data[a][0]:"")),0===e){c.push((o=s,"datetime"===l.config.xaxis.type&&String(o).length>=10?l.config.chart.toolbar.export.csv.dateFormatter(s):v.isNumber(s)?s:s.split(r).join("")));for(var n=0;n<l.globals.series.length;n++)f.isFormatXY()?c.push(i[n].data[a].y):c.push(u[n][a])}("candlestick"===l.config.chart.type||t.type&&"candlestick"===t.type)&&(c.pop(),c.push(l.globals.seriesCandleO[e][a]),c.push(l.globals.seriesCandleH[e][a]),c.push(l.globals.seriesCandleL[e][a]),c.push(l.globals.seriesCandleC[e][a])),("boxPlot"===l.config.chart.type||t.type&&"boxPlot"===t.type)&&(c.pop(),c.push(l.globals.seriesCandleO[e][a]),c.push(l.globals.seriesCandleH[e][a]),c.push(l.globals.seriesCandleM[e][a]),c.push(l.globals.seriesCandleL[e][a]),c.push(l.globals.seriesCandleC[e][a])),"rangeBar"===l.config.chart.type&&(c.pop(),c.push(l.globals.seriesRangeStart[e][a]),c.push(l.globals.seriesRangeEnd[e][a])),c.length&&h.push(c.join(r))}}var o}(t,e):((c=[]).push(l.globals.labels[e].split(r).join("")),c.push(u[e]),h.push(c.join(r)))})),d+=h.join(o),this.triggerDownload("data:text/csv; charset=utf-8,"+encodeURIComponent("\ufeff"+d),a||l.config.chart.toolbar.export.csv.filename,".csv")}},{key:"triggerDownload",value:function(t,e,i){var a=document.createElement("a");a.href=t,a.download=(e||this.w.globals.chartID)+i,document.body.appendChild(a),a.click(),document.body.removeChild(a)}}]),t}(),U=function(){function t(e,i){o(this,t),this.ctx=e,this.elgrid=i,this.w=e.w;var a=this.w;this.axesUtils=new V(e),this.xaxisLabels=a.globals.labels.slice(),a.globals.timescaleLabels.length>0&&!a.globals.isBarHorizontal&&(this.xaxisLabels=a.globals.timescaleLabels.slice()),a.config.xaxis.overwriteCategories&&(this.xaxisLabels=a.config.xaxis.overwriteCategories),this.drawnLabels=[],this.drawnLabelsRects=[],"top"===a.config.xaxis.position?this.offY=0:this.offY=a.globals.gridHeight+1,this.offY=this.offY+a.config.xaxis.axisBorder.offsetY,this.isCategoryBarHorizontal="bar"===a.config.chart.type&&a.config.plotOptions.bar.horizontal,this.xaxisFontSize=a.config.xaxis.labels.style.fontSize,this.xaxisFontFamily=a.config.xaxis.labels.style.fontFamily,this.xaxisForeColors=a.config.xaxis.labels.style.colors,this.xaxisBorderWidth=a.config.xaxis.axisBorder.width,this.isCategoryBarHorizontal&&(this.xaxisBorderWidth=a.config.yaxis[0].axisBorder.width.toString()),this.xaxisBorderWidth.indexOf("%")>-1?this.xaxisBorderWidth=a.globals.gridWidth*parseInt(this.xaxisBorderWidth,10)/100:this.xaxisBorderWidth=parseInt(this.xaxisBorderWidth,10),this.xaxisBorderHeight=a.config.xaxis.axisBorder.height,this.yaxis=a.config.yaxis[0]}return c(t,[{key:"drawXaxis",value:function(){var t=this.w,e=new k(this.ctx),i=e.group({class:"apexcharts-xaxis",transform:"translate(".concat(t.config.xaxis.offsetX,", ").concat(t.config.xaxis.offsetY,")")}),a=e.group({class:"apexcharts-xaxis-texts-g",transform:"translate(".concat(t.globals.translateXAxisX,", ").concat(t.globals.translateXAxisY,")")});i.add(a);for(var s=[],r=0;r<this.xaxisLabels.length;r++)s.push(this.xaxisLabels[r]);if(this.drawXAxisLabelAndGroup(!0,e,a,s,t.globals.isXNumeric,(function(t,e){return e})),t.globals.hasGroups){var n=t.globals.groups;s=[];for(var o=0;o<n.length;o++)s.push(n[o].title);var l={};t.config.xaxis.group.style&&(l.xaxisFontSize=t.config.xaxis.group.style.fontSize,l.xaxisFontFamily=t.config.xaxis.group.style.fontFamily,l.xaxisForeColors=t.config.xaxis.group.style.colors,l.fontWeight=t.config.xaxis.group.style.fontWeight,l.cssClass=t.config.xaxis.group.style.cssClass),this.drawXAxisLabelAndGroup(!1,e,a,s,!1,(function(t,e){return n[t].cols*e}),l)}if(void 0!==t.config.xaxis.title.text){var c=e.group({class:"apexcharts-xaxis-title"}),h=e.drawText({x:t.globals.gridWidth/2+t.config.xaxis.title.offsetX,y:this.offY+parseFloat(this.xaxisFontSize)+("bottom"===t.config.xaxis.title.position?t.globals.xAxisLabelsHeight:-t.globals.xAxisLabelsHeight-10)+t.config.xaxis.title.offsetY,text:t.config.xaxis.title.text,textAnchor:"middle",fontSize:t.config.xaxis.title.style.fontSize,fontFamily:t.config.xaxis.title.style.fontFamily,fontWeight:t.config.xaxis.title.style.fontWeight,foreColor:t.config.xaxis.title.style.color,cssClass:"apexcharts-xaxis-title-text "+t.config.xaxis.title.style.cssClass});c.add(h),i.add(c)}if(t.config.xaxis.axisBorder.show){var d=t.globals.barPadForNumericAxis,u=e.drawLine(t.globals.padHorizontal+t.config.xaxis.axisBorder.offsetX-d,this.offY,this.xaxisBorderWidth+d,this.offY,t.config.xaxis.axisBorder.color,0,this.xaxisBorderHeight);this.elgrid&&this.elgrid.elGridBorders?this.elgrid.elGridBorders.add(u):i.add(u)}return i}},{key:"drawXAxisLabelAndGroup",value:function(t,e,i,a,s,r){var n,o=this,l=arguments.length>6&&void 0!==arguments[6]?arguments[6]:{},c=[],h=[],d=this.w,u=l.xaxisFontSize||this.xaxisFontSize,p=l.xaxisFontFamily||this.xaxisFontFamily,f=l.xaxisForeColors||this.xaxisForeColors,g=l.fontWeight||d.config.xaxis.labels.style.fontWeight,x=l.cssClass||d.config.xaxis.labels.style.cssClass,m=d.globals.padHorizontal,b=a.length,v="category"===d.config.xaxis.type?d.globals.dataPoints:b;if(0===v&&b>v&&(v=b),s){var y=v>1?v-1:v;n=d.globals.gridWidth/y,m=m+r(0,n)/2+d.config.xaxis.labels.offsetX}else n=d.globals.gridWidth/v,m=m+r(0,n)+d.config.xaxis.labels.offsetX;for(var w=function(s){var l=m-r(s,n)/2+d.config.xaxis.labels.offsetX;0===s&&1===b&&n/2===m&&1===v&&(l=d.globals.gridWidth/2);var y=o.axesUtils.getLabel(a,d.globals.timescaleLabels,l,s,c,u,t),w=28;if(d.globals.rotateXLabels&&t&&(w=22),d.config.xaxis.title.text&&"top"===d.config.xaxis.position&&(w+=parseFloat(d.config.xaxis.title.style.fontSize)+2),t||(w=w+parseFloat(u)+(d.globals.xAxisLabelsHeight-d.globals.xAxisGroupLabelsHeight)+(d.globals.rotateXLabels?10:0)),y=void 0!==d.config.xaxis.tickAmount&&"dataPoints"!==d.config.xaxis.tickAmount&&"datetime"!==d.config.xaxis.type?o.axesUtils.checkLabelBasedOnTickamount(s,y,b):o.axesUtils.checkForOverflowingLabels(s,y,b,c,h),t&&y.text&&d.globals.xaxisLabelsCount++,d.config.xaxis.labels.show){var k=e.drawText({x:y.x,y:o.offY+d.config.xaxis.labels.offsetY+w-("top"===d.config.xaxis.position?d.globals.xAxisHeight+d.config.xaxis.axisTicks.height-2:0),text:y.text,textAnchor:"middle",fontWeight:y.isBold?600:g,fontSize:u,fontFamily:p,foreColor:Array.isArray(f)?t&&d.config.xaxis.convertedCatToNumeric?f[d.globals.minX+s-1]:f[s]:f,isPlainText:!1,cssClass:(t?"apexcharts-xaxis-label ":"apexcharts-xaxis-group-label ")+x});if(i.add(k),k.on("click",(function(t){if("function"==typeof d.config.chart.events.xAxisLabelClick){var e=Object.assign({},d,{labelIndex:s});d.config.chart.events.xAxisLabelClick(t,o.ctx,e)}})),t){var A=document.createElementNS(d.globals.SVGNS,"title");A.textContent=Array.isArray(y.text)?y.text.join(" "):y.text,k.node.appendChild(A),""!==y.text&&(c.push(y.text),h.push(y))}}s<b-1&&(m+=r(s+1,n))},k=0;k<=b-1;k++)w(k)}},{key:"drawXaxisInversed",value:function(t){var e,i,a=this,s=this.w,r=new k(this.ctx),n=s.config.yaxis[0].opposite?s.globals.translateYAxisX[t]:0,o=r.group({class:"apexcharts-yaxis apexcharts-xaxis-inversed",rel:t}),l=r.group({class:"apexcharts-yaxis-texts-g apexcharts-xaxis-inversed-texts-g",transform:"translate("+n+", 0)"});o.add(l);var c=[];if(s.config.yaxis[t].show)for(var h=0;h<this.xaxisLabels.length;h++)c.push(this.xaxisLabels[h]);e=s.globals.gridHeight/c.length,i=-e/2.2;var d=s.globals.yLabelFormatters[0],u=s.config.yaxis[0].labels;if(u.show)for(var p=function(n){var o=void 0===c[n]?"":c[n];o=d(o,{seriesIndex:t,dataPointIndex:n,w:s});var h=a.axesUtils.getYAxisForeColor(u.style.colors,t),p=0;Array.isArray(o)&&(p=o.length/2*parseInt(u.style.fontSize,10));var f=r.drawText({x:u.offsetX-15,y:i+e+u.offsetY-p,text:o,textAnchor:a.yaxis.opposite?"start":"end",foreColor:Array.isArray(h)?h[n]:h,fontSize:u.style.fontSize,fontFamily:u.style.fontFamily,fontWeight:u.style.fontWeight,isPlainText:!1,cssClass:"apexcharts-yaxis-label "+u.style.cssClass,maxWidth:u.maxWidth});l.add(f),f.on("click",(function(t){if("function"==typeof s.config.chart.events.xAxisLabelClick){var e=Object.assign({},s,{labelIndex:n});s.config.chart.events.xAxisLabelClick(t,a.ctx,e)}}));var g=document.createElementNS(s.globals.SVGNS,"title");if(g.textContent=Array.isArray(o)?o.join(" "):o,f.node.appendChild(g),0!==s.config.yaxis[t].labels.rotate){var x=r.rotateAroundCenter(f.node);f.node.setAttribute("transform","rotate(".concat(s.config.yaxis[t].labels.rotate," 0 ").concat(x.y,")"))}i+=e},f=0;f<=c.length-1;f++)p(f);if(void 0!==s.config.yaxis[0].title.text){var g=r.group({class:"apexcharts-yaxis-title apexcharts-xaxis-title-inversed",transform:"translate("+n+", 0)"}),x=r.drawText({x:s.config.yaxis[0].title.offsetX,y:s.globals.gridHeight/2+s.config.yaxis[0].title.offsetY,text:s.config.yaxis[0].title.text,textAnchor:"middle",foreColor:s.config.yaxis[0].title.style.color,fontSize:s.config.yaxis[0].title.style.fontSize,fontWeight:s.config.yaxis[0].title.style.fontWeight,fontFamily:s.config.yaxis[0].title.style.fontFamily,cssClass:"apexcharts-yaxis-title-text "+s.config.yaxis[0].title.style.cssClass});g.add(x),o.add(g)}var m=0;this.isCategoryBarHorizontal&&s.config.yaxis[0].opposite&&(m=s.globals.gridWidth);var b=s.config.xaxis.axisBorder;if(b.show){var v=r.drawLine(s.globals.padHorizontal+b.offsetX+m,1+b.offsetY,s.globals.padHorizontal+b.offsetX+m,s.globals.gridHeight+b.offsetY,b.color,0);this.elgrid&&this.elgrid.elGridBorders?this.elgrid.elGridBorders.add(v):o.add(v)}return s.config.yaxis[0].axisTicks.show&&this.axesUtils.drawYAxisTicks(m,c.length,s.config.yaxis[0].axisBorder,s.config.yaxis[0].axisTicks,0,e,o),o}},{key:"drawXaxisTicks",value:function(t,e,i){var a=this.w,s=t;if(!(t<0||t-2>a.globals.gridWidth)){var r=this.offY+a.config.xaxis.axisTicks.offsetY;if(e=e+r+a.config.xaxis.axisTicks.height,"top"===a.config.xaxis.position&&(e=r-a.config.xaxis.axisTicks.height),a.config.xaxis.axisTicks.show){var n=new k(this.ctx).drawLine(t+a.config.xaxis.axisTicks.offsetX,r+a.config.xaxis.offsetY,s+a.config.xaxis.axisTicks.offsetX,e+a.config.xaxis.offsetY,a.config.xaxis.axisTicks.color);i.add(n),n.node.classList.add("apexcharts-xaxis-tick")}}}},{key:"getXAxisTicksPositions",value:function(){var t=this.w,e=[],i=this.xaxisLabels.length,a=t.globals.padHorizontal;if(t.globals.timescaleLabels.length>0)for(var s=0;s<i;s++)a=this.xaxisLabels[s].position,e.push(a);else for(var r=i,n=0;n<r;n++){var o=r;t.globals.isXNumeric&&"bar"!==t.config.chart.type&&(o-=1),a+=t.globals.gridWidth/o,e.push(a)}return e}},{key:"xAxisLabelCorrections",value:function(){var t=this.w,e=new k(this.ctx),i=t.globals.dom.baseEl.querySelector(".apexcharts-xaxis-texts-g"),a=t.globals.dom.baseEl.querySelectorAll(".apexcharts-xaxis-texts-g text:not(.apexcharts-xaxis-group-label)"),s=t.globals.dom.baseEl.querySelectorAll(".apexcharts-yaxis-inversed text"),r=t.globals.dom.baseEl.querySelectorAll(".apexcharts-xaxis-inversed-texts-g text tspan");if(t.globals.rotateXLabels||t.config.xaxis.labels.rotateAlways)for(var n=0;n<a.length;n++){var o=e.rotateAroundCenter(a[n]);o.y=o.y-1,o.x=o.x+1,a[n].setAttribute("transform","rotate(".concat(t.config.xaxis.labels.rotate," ").concat(o.x," ").concat(o.y,")")),a[n].setAttribute("text-anchor","end"),i.setAttribute("transform","translate(0, ".concat(-10,")"));var l=a[n].childNodes;t.config.xaxis.labels.trim&&Array.prototype.forEach.call(l,(function(i){e.placeTextWithEllipsis(i,i.textContent,t.globals.xAxisLabelsHeight-("bottom"===t.config.legend.position?20:10))}))}else!function(){for(var i=t.globals.gridWidth/(t.globals.labels.length+1),s=0;s<a.length;s++){var r=a[s].childNodes;t.config.xaxis.labels.trim&&"datetime"!==t.config.xaxis.type&&Array.prototype.forEach.call(r,(function(t){e.placeTextWithEllipsis(t,t.textContent,i)}))}}();if(s.length>0){var c=s[s.length-1].getBBox(),h=s[0].getBBox();c.x<-20&&s[s.length-1].parentNode.removeChild(s[s.length-1]),h.x+h.width>t.globals.gridWidth&&!t.globals.isBarHorizontal&&s[0].parentNode.removeChild(s[0]);for(var d=0;d<r.length;d++)e.placeTextWithEllipsis(r[d],r[d].textContent,t.config.yaxis[0].labels.maxWidth-(t.config.yaxis[0].title.text?2*parseFloat(t.config.yaxis[0].title.style.fontSize):0)-15)}}}]),t}(),q=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w;var i=this.w;this.xaxisLabels=i.globals.labels.slice(),this.axesUtils=new V(e),this.isRangeBar=i.globals.seriesRange.length,i.globals.timescaleLabels.length>0&&(this.xaxisLabels=i.globals.timescaleLabels.slice())}return c(t,[{key:"drawGridArea",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,e=this.w,i=new k(this.ctx);null===t&&(t=i.group({class:"apexcharts-grid"}));var a=i.drawLine(e.globals.padHorizontal,1,e.globals.padHorizontal,e.globals.gridHeight,"transparent"),s=i.drawLine(e.globals.padHorizontal,e.globals.gridHeight,e.globals.gridWidth,e.globals.gridHeight,"transparent");return t.add(s),t.add(a),t}},{key:"drawGrid",value:function(){var t=null;return this.w.globals.axisCharts&&(t=this.renderGrid(),this.drawGridArea(t.el)),t}},{key:"createGridMask",value:function(){var t=this.w,e=t.globals,i=new k(this.ctx),a=Array.isArray(t.config.stroke.width)?0:t.config.stroke.width;if(Array.isArray(t.config.stroke.width)){var s=0;t.config.stroke.width.forEach((function(t){s=Math.max(s,t)})),a=s}e.dom.elGridRectMask=document.createElementNS(e.SVGNS,"clipPath"),e.dom.elGridRectMask.setAttribute("id","gridRectMask".concat(e.cuid)),e.dom.elGridRectMarkerMask=document.createElementNS(e.SVGNS,"clipPath"),e.dom.elGridRectMarkerMask.setAttribute("id","gridRectMarkerMask".concat(e.cuid)),e.dom.elForecastMask=document.createElementNS(e.SVGNS,"clipPath"),e.dom.elForecastMask.setAttribute("id","forecastMask".concat(e.cuid)),e.dom.elNonForecastMask=document.createElementNS(e.SVGNS,"clipPath"),e.dom.elNonForecastMask.setAttribute("id","nonForecastMask".concat(e.cuid));var r=t.config.chart.type,n=0,o=0;("bar"===r||"rangeBar"===r||"candlestick"===r||"boxPlot"===r||t.globals.comboBarCount>0)&&t.globals.isXNumeric&&!t.globals.isBarHorizontal&&(n=t.config.grid.padding.left,o=t.config.grid.padding.right,e.barPadForNumericAxis>n&&(n=e.barPadForNumericAxis,o=e.barPadForNumericAxis)),e.dom.elGridRect=i.drawRect(-a/2-n-2,-a/2,e.gridWidth+a+o+n+4,e.gridHeight+a,0,"#fff");var l=t.globals.markers.largestSize+1;e.dom.elGridRectMarker=i.drawRect(2*-l,2*-l,e.gridWidth+4*l,e.gridHeight+4*l,0,"#fff"),e.dom.elGridRectMask.appendChild(e.dom.elGridRect.node),e.dom.elGridRectMarkerMask.appendChild(e.dom.elGridRectMarker.node);var c=e.dom.baseEl.querySelector("defs");c.appendChild(e.dom.elGridRectMask),c.appendChild(e.dom.elForecastMask),c.appendChild(e.dom.elNonForecastMask),c.appendChild(e.dom.elGridRectMarkerMask)}},{key:"_drawGridLines",value:function(t){var e=t.i,i=t.x1,a=t.y1,s=t.x2,r=t.y2,n=t.xCount,o=t.parent,l=this.w;if(!(0===e&&l.globals.skipFirstTimelinelabel||e===n-1&&l.globals.skipLastTimelinelabel&&!l.config.xaxis.labels.formatter||"radar"===l.config.chart.type)){l.config.grid.xaxis.lines.show&&this._drawGridLine({i:e,x1:i,y1:a,x2:s,y2:r,xCount:n,parent:o});var c=0;if(l.globals.hasGroups&&"between"===l.config.xaxis.tickPlacement){var h=l.globals.groups;if(h){for(var d=0,u=0;d<e&&u<h.length;u++)d+=h[u].cols;d===e&&(c=.6*l.globals.xAxisLabelsHeight)}}new U(this.ctx).drawXaxisTicks(i,c,l.globals.dom.elGraphical)}}},{key:"_drawGridLine",value:function(t){var e=t.i,i=t.x1,a=t.y1,s=t.x2,r=t.y2,n=t.xCount,o=t.parent,l=this.w,c=!1,h=o.node.classList.contains("apexcharts-gridlines-horizontal"),d=l.config.grid.strokeDashArray,u=l.globals.barPadForNumericAxis;(0===a&&0===r||0===i&&0===s)&&(c=!0),a===l.globals.gridHeight&&r===l.globals.gridHeight&&(c=!0),!l.globals.isBarHorizontal||0!==e&&e!==n-1||(c=!0);var p=new k(this).drawLine(i-(h?u:0),a,s+(h?u:0),r,l.config.grid.borderColor,d);p.node.classList.add("apexcharts-gridline"),c?this.elGridBorders.add(p):o.add(p)}},{key:"_drawGridBandRect",value:function(t){var e=t.c,i=t.x1,a=t.y1,s=t.x2,r=t.y2,n=t.type,o=this.w,l=new k(this.ctx),c=o.globals.barPadForNumericAxis;if("column"!==n||"datetime"!==o.config.xaxis.type){var h=o.config.grid[n].colors[e],d=l.drawRect(i-("row"===n?c:0),a,s+("row"===n?2*c:0),r,0,h,o.config.grid[n].opacity);this.elg.add(d),d.attr("clip-path","url(#gridRectMask".concat(o.globals.cuid,")")),d.node.classList.add("apexcharts-grid-".concat(n))}}},{key:"_drawXYLines",value:function(t){var e=this,i=t.xCount,a=t.tickAmount,s=this.w;if(s.config.grid.xaxis.lines.show||s.config.xaxis.axisTicks.show){var r,n=s.globals.padHorizontal,o=s.globals.gridHeight;s.globals.timescaleLabels.length?function(t){for(var a=t.xC,s=t.x1,r=t.y1,n=t.x2,o=t.y2,l=0;l<a;l++)s=e.xaxisLabels[l].position,n=e.xaxisLabels[l].position,e._drawGridLines({i:l,x1:s,y1:r,x2:n,y2:o,xCount:i,parent:e.elgridLinesV})}({xC:i,x1:n,y1:0,x2:r,y2:o}):(s.globals.isXNumeric&&(i=s.globals.xAxisScale.result.length),s.config.xaxis.convertedCatToNumeric&&(i=s.globals.xaxisLabelsCount),function(t){var a=t.xC,r=t.x1,n=t.y1,o=t.x2,l=t.y2;if(void 0!==s.config.xaxis.tickAmount&&"dataPoints"!==s.config.xaxis.tickAmount&&"on"===s.config.xaxis.tickPlacement)s.globals.dom.baseEl.querySelectorAll(".apexcharts-text.apexcharts-xaxis-label tspan:not(:empty)").forEach((function(t,a){var s=t.getBBox();e._drawGridLines({i:a,x1:s.x+s.width/2,y1:n,x2:s.x+s.width/2,y2:l,xCount:i,parent:e.elgridLinesV})}));else for(var c=0;c<a+(s.globals.isXNumeric?0:1);c++)0===c&&1===a&&1===s.globals.dataPoints&&(o=r=s.globals.gridWidth/2),e._drawGridLines({i:c,x1:r,y1:n,x2:o,y2:l,xCount:i,parent:e.elgridLinesV}),o=r+=s.globals.gridWidth/(s.globals.isXNumeric?a-1:a)}({xC:i,x1:n,y1:0,x2:r,y2:o}))}if(s.config.grid.yaxis.lines.show){var l=0,c=0,h=s.globals.gridWidth,d=a+1;this.isRangeBar&&(d=s.globals.labels.length);for(var u=0;u<d+(this.isRangeBar?1:0);u++)this._drawGridLine({i:u,xCount:d+(this.isRangeBar?1:0),x1:0,y1:l,x2:h,y2:c,parent:this.elgridLinesH}),c=l+=s.globals.gridHeight/(this.isRangeBar?d:a)}}},{key:"_drawInvertedXYLines",value:function(t){var e=t.xCount,i=this.w;if(i.config.grid.xaxis.lines.show||i.config.xaxis.axisTicks.show)for(var a,s=i.globals.padHorizontal,r=i.globals.gridHeight,n=0;n<e+1;n++)i.config.grid.xaxis.lines.show&&this._drawGridLine({i:n,xCount:e+1,x1:s,y1:0,x2:a,y2:r,parent:this.elgridLinesV}),new U(this.ctx).drawXaxisTicks(s,0,i.globals.dom.elGraphical),a=s=s+i.globals.gridWidth/e+.3;if(i.config.grid.yaxis.lines.show)for(var o=0,l=0,c=i.globals.gridWidth,h=0;h<i.globals.dataPoints+1;h++)this._drawGridLine({i:h,xCount:i.globals.dataPoints+1,x1:0,y1:o,x2:c,y2:l,parent:this.elgridLinesH}),l=o+=i.globals.gridHeight/i.globals.dataPoints}},{key:"renderGrid",value:function(){var t=this.w,e=new k(this.ctx);this.elg=e.group({class:"apexcharts-grid"}),this.elgridLinesH=e.group({class:"apexcharts-gridlines-horizontal"}),this.elgridLinesV=e.group({class:"apexcharts-gridlines-vertical"}),this.elGridBorders=e.group({class:"apexcharts-grid-borders"}),this.elg.add(this.elgridLinesH),this.elg.add(this.elgridLinesV),t.config.grid.show||(this.elgridLinesV.hide(),this.elgridLinesH.hide(),this.elGridBorders.hide());for(var i,a=t.globals.yAxisScale.length?t.globals.yAxisScale[0].result.length-1:5,s=0;s<t.globals.series.length&&(void 0!==t.globals.yAxisScale[s]&&(a=t.globals.yAxisScale[s].result.length-1),!(a>2));s++);return!t.globals.isBarHorizontal||this.isRangeBar?(i=this.xaxisLabels.length,this.isRangeBar&&(a=t.globals.labels.length,t.config.xaxis.tickAmount&&t.config.xaxis.labels.formatter&&(i=t.config.xaxis.tickAmount)),this._drawXYLines({xCount:i,tickAmount:a})):(i=a,a=t.globals.xTickAmount,this._drawInvertedXYLines({xCount:i,tickAmount:a})),this.drawGridBands(i,a),{el:this.elg,elGridBorders:this.elGridBorders,xAxisTickWidth:t.globals.gridWidth/i}}},{key:"drawGridBands",value:function(t,e){var i=this.w;if(void 0!==i.config.grid.row.colors&&i.config.grid.row.colors.length>0)for(var a=0,s=i.globals.gridHeight/e,r=i.globals.gridWidth,n=0,o=0;n<e;n++,o++)o>=i.config.grid.row.colors.length&&(o=0),this._drawGridBandRect({c:o,x1:0,y1:a,x2:r,y2:s,type:"row"}),a+=i.globals.gridHeight/e;if(void 0!==i.config.grid.column.colors&&i.config.grid.column.colors.length>0)for(var l=i.globals.isBarHorizontal||"category"!==i.config.xaxis.type&&!i.config.xaxis.convertedCatToNumeric?t:t-1,c=i.globals.padHorizontal,h=i.globals.padHorizontal+i.globals.gridWidth/l,d=i.globals.gridHeight,u=0,p=0;u<t;u++,p++)p>=i.config.grid.column.colors.length&&(p=0),this._drawGridBandRect({c:p,x1:c,y1:0,x2:h,y2:d,type:"column"}),c+=i.globals.gridWidth/l}}]),t}(),Z=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w}return c(t,[{key:"niceScale",value:function(t,e){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:10,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,s=arguments.length>4?arguments[4]:void 0,r=this.w,n=Math.abs(e-t);if("dataPoints"===(i=this._adjustTicksForSmallRange(i,a,n))&&(i=r.globals.dataPoints-1),t===Number.MIN_VALUE&&0===e||!v.isNumber(t)&&!v.isNumber(e)||t===Number.MIN_VALUE&&e===-Number.MAX_VALUE){t=0,e=i;var o=this.linearScale(t,e,i);return o}t>e?(console.warn("axis.min cannot be greater than axis.max"),e=t+.1):t===e&&(t=0===t?0:t-.5,e=0===e?2:e+.5);var l=[];n<1&&s&&("candlestick"===r.config.chart.type||"candlestick"===r.config.series[a].type||"boxPlot"===r.config.chart.type||"boxPlot"===r.config.series[a].type||r.globals.isRangeData)&&(e*=1.01);var c=i+1;c<2?c=2:c>2&&(c-=2);var h=n/c,d=Math.floor(v.log10(h)),u=Math.pow(10,d),p=Math.round(h/u);p<1&&(p=1);var f=p*u,g=f*Math.floor(t/f),x=f*Math.ceil(e/f),m=g;if(s&&n>2){for(;l.push(m),!((m+=f)>x););return{result:l,niceMin:l[0],niceMax:l[l.length-1]}}var b=t;(l=[]).push(b);for(var y=Math.abs(e-t)/i,w=0;w<=i;w++)b+=y,l.push(b);return l[l.length-2]>=e&&l.pop(),{result:l,niceMin:l[0],niceMax:l[l.length-1]}}},{key:"linearScale",value:function(t,e){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:10,a=arguments.length>3?arguments[3]:void 0,s=Math.abs(e-t);"dataPoints"===(i=this._adjustTicksForSmallRange(i,a,s))&&(i=this.w.globals.dataPoints-1);var r=s/i;i===Number.MAX_VALUE&&(i=10,r=1);for(var n=[],o=t;i>=0;)n.push(o),o+=r,i-=1;return{result:n,niceMin:n[0],niceMax:n[n.length-1]}}},{key:"logarithmicScaleNice",value:function(t,e,i){e<=0&&(e=Math.max(t,i)),t<=0&&(t=Math.min(e,i));for(var a=[],s=Math.ceil(Math.log(e)/Math.log(i)+1),r=Math.floor(Math.log(t)/Math.log(i));r<s;r++)a.push(Math.pow(i,r));return{result:a,niceMin:a[0],niceMax:a[a.length-1]}}},{key:"logarithmicScale",value:function(t,e,i){e<=0&&(e=Math.max(t,i)),t<=0&&(t=Math.min(e,i));for(var a=[],s=Math.log(e)/Math.log(i),r=Math.log(t)/Math.log(i),n=s-r,o=Math.round(n),l=n/o,c=0,h=r;c<o;c++,h+=l)a.push(Math.pow(i,h));return a.push(Math.pow(i,s)),{result:a,niceMin:t,niceMax:e}}},{key:"_adjustTicksForSmallRange",value:function(t,e,i){var a=t;if(void 0!==e&&this.w.config.yaxis[e].labels.formatter&&void 0===this.w.config.yaxis[e].tickAmount){var s=this.w.config.yaxis[e].labels.formatter(1);v.isNumber(Number(s))&&!v.isFloat(s)&&(a=Math.ceil(i))}return a<t?a:t}},{key:"setYScaleForIndex",value:function(t,e,i){var a=this.w.globals,s=this.w.config,r=a.isBarHorizontal?s.xaxis:s.yaxis[t];void 0===a.yAxisScale[t]&&(a.yAxisScale[t]=[]);var n=Math.abs(i-e);if(r.logarithmic&&n<=5&&(a.invalidLogScale=!0),r.logarithmic&&n>5)a.allSeriesCollapsed=!1,a.yAxisScale[t]=this.logarithmicScale(e,i,r.logBase),a.yAxisScale[t]=r.forceNiceScale?this.logarithmicScaleNice(e,i,r.logBase):this.logarithmicScale(e,i,r.logBase);else if(i!==-Number.MAX_VALUE&&v.isNumber(i))if(a.allSeriesCollapsed=!1,void 0===r.min&&void 0===r.max||r.forceNiceScale){var o=void 0===s.yaxis[t].max&&void 0===s.yaxis[t].min||s.yaxis[t].forceNiceScale;a.yAxisScale[t]=this.niceScale(e,i,r.tickAmount?r.tickAmount:n<5&&n>1?n+1:5,t,o)}else a.yAxisScale[t]=this.linearScale(e,i,r.tickAmount,t);else a.yAxisScale[t]=this.linearScale(0,5,5)}},{key:"setXScale",value:function(t,e){var i=this.w,a=i.globals,s=i.config.xaxis,r=Math.abs(e-t);return e!==-Number.MAX_VALUE&&v.isNumber(e)?a.xAxisScale=this.linearScale(t,e,s.tickAmount?s.tickAmount:r<5&&r>1?r+1:5,0):a.xAxisScale=this.linearScale(0,5,5),a.xAxisScale}},{key:"setMultipleYScales",value:function(){var t=this,e=this.w.globals,i=this.w.config,a=e.minYArr.concat([]),s=e.maxYArr.concat([]),r=[];i.yaxis.forEach((function(e,n){var o=n;i.series.forEach((function(t,i){t.name===e.seriesName&&(o=i,n!==i?r.push({index:i,similarIndex:n,alreadyExists:!0}):r.push({index:i}))}));var l=a[o],c=s[o];t.setYScaleForIndex(n,l,c)})),this.sameScaleInMultipleAxes(a,s,r)}},{key:"sameScaleInMultipleAxes",value:function(t,e,i){var a=this,s=this.w.config,r=this.w.globals,n=[];i.forEach((function(t){t.alreadyExists&&(void 0===n[t.index]&&(n[t.index]=[]),n[t.index].push(t.index),n[t.index].push(t.similarIndex))})),r.yAxisSameScaleIndices=n,n.forEach((function(t,e){n.forEach((function(i,a){var s,r;e!==a&&(s=t,r=i,s.filter((function(t){return-1!==r.indexOf(t)}))).length>0&&(n[e]=n[e].concat(n[a]))}))}));var o=n.map((function(t){return t.filter((function(e,i){return t.indexOf(e)===i}))})).map((function(t){return t.sort()}));n=n.filter((function(t){return!!t}));var l=o.slice(),c=l.map((function(t){return JSON.stringify(t)}));l=l.filter((function(t,e){return c.indexOf(JSON.stringify(t))===e}));var h=[],d=[];t.forEach((function(t,i){l.forEach((function(a,s){a.indexOf(i)>-1&&(void 0===h[s]&&(h[s]=[],d[s]=[]),h[s].push({key:i,value:t}),d[s].push({key:i,value:e[i]}))}))}));var u=Array.apply(null,Array(l.length)).map(Number.prototype.valueOf,Number.MIN_VALUE),p=Array.apply(null,Array(l.length)).map(Number.prototype.valueOf,-Number.MAX_VALUE);h.forEach((function(t,e){t.forEach((function(t,i){u[e]=Math.min(t.value,u[e])}))})),d.forEach((function(t,e){t.forEach((function(t,i){p[e]=Math.max(t.value,p[e])}))})),t.forEach((function(t,e){d.forEach((function(t,i){var n=u[i],o=p[i];s.chart.stacked&&(o=0,t.forEach((function(t,e){t.value!==-Number.MAX_VALUE&&(o+=t.value),n!==Number.MIN_VALUE&&(n+=h[i][e].value)}))),t.forEach((function(i,l){t[l].key===e&&(void 0!==s.yaxis[e].min&&(n="function"==typeof s.yaxis[e].min?s.yaxis[e].min(r.minY):s.yaxis[e].min),void 0!==s.yaxis[e].max&&(o="function"==typeof s.yaxis[e].max?s.yaxis[e].max(r.maxY):s.yaxis[e].max),a.setYScaleForIndex(e,n,o))}))}))}))}},{key:"autoScaleY",value:function(t,e,i){t||(t=this);var a=t.w;if(a.globals.isMultipleYAxis||a.globals.collapsedSeries.length)return console.warn("autoScaleYaxis is not supported in a multi-yaxis chart."),e;var s=a.globals.seriesX[0],r=a.config.chart.stacked;return e.forEach((function(t,n){for(var o=0,l=0;l<s.length;l++)if(s[l]>=i.xaxis.min){o=l;break}var c,h,d=a.globals.minYArr[n],u=a.globals.maxYArr[n],p=a.globals.stackedSeriesTotals;a.globals.series.forEach((function(n,l){var f=n[o];r?(f=p[o],c=h=f,p.forEach((function(t,e){s[e]<=i.xaxis.max&&s[e]>=i.xaxis.min&&(t>h&&null!==t&&(h=t),n[e]<c&&null!==n[e]&&(c=n[e]))}))):(c=h=f,n.forEach((function(t,e){if(s[e]<=i.xaxis.max&&s[e]>=i.xaxis.min){var r=t,n=t;a.globals.series.forEach((function(i,a){null!==t&&(r=Math.min(i[e],r),n=Math.max(i[e],n))})),n>h&&null!==n&&(h=n),r<c&&null!==r&&(c=r)}}))),void 0===c&&void 0===h&&(c=d,h=u),h*=h<0?.9:1.1,0==(c*=c<0?1.1:.9)&&0===h&&(c=-1,h=1),h<0&&h<u&&(h=u),c<0&&c>d&&(c=d),e.length>1?(e[l].min=void 0===t.min?c:t.min,e[l].max=void 0===t.max?h:t.max):(e[0].min=void 0===t.min?c:t.min,e[0].max=void 0===t.max?h:t.max)}))})),e}}]),t}(),$=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w,this.scales=new Z(e)}return c(t,[{key:"init",value:function(){this.setYRange(),this.setXRange(),this.setZRange()}},{key:"getMinYMaxY",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Number.MAX_VALUE,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:-Number.MAX_VALUE,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,s=this.w.config,r=this.w.globals,n=-Number.MAX_VALUE,o=Number.MIN_VALUE;null===a&&(a=t+1);var l=r.series,c=l,h=l;"candlestick"===s.chart.type?(c=r.seriesCandleL,h=r.seriesCandleH):"boxPlot"===s.chart.type?(c=r.seriesCandleO,h=r.seriesCandleC):r.isRangeData&&(c=r.seriesRangeStart,h=r.seriesRangeEnd);for(var d=t;d<a;d++){r.dataPoints=Math.max(r.dataPoints,l[d].length),r.categoryLabels.length&&(r.dataPoints=r.categoryLabels.filter((function(t){return void 0!==t})).length);for(var u=0;u<r.series[d].length;u++){var p=l[d][u];null!==p&&v.isNumber(p)?(void 0!==h[d][u]&&(n=Math.max(n,h[d][u]),e=Math.min(e,h[d][u])),void 0!==c[d][u]&&(e=Math.min(e,c[d][u]),i=Math.max(i,c[d][u])),"candlestick"!==this.w.config.chart.type&&"boxPlot"!==this.w.config.chart.type&&"rangeArea"===this.w.config.chart.type&&"rangeBar"===this.w.config.chart.type||("candlestick"!==this.w.config.chart.type&&"boxPlot"!==this.w.config.chart.type||void 0!==r.seriesCandleC[d][u]&&(n=Math.max(n,r.seriesCandleO[d][u]),n=Math.max(n,r.seriesCandleH[d][u]),n=Math.max(n,r.seriesCandleL[d][u]),n=Math.max(n,r.seriesCandleC[d][u]),"boxPlot"===this.w.config.chart.type&&(n=Math.max(n,r.seriesCandleM[d][u]))),!s.series[d].type||"candlestick"===s.series[d].type&&"boxPlot"===s.series[d].type&&"rangeArea"===s.series[d].type&&"rangeBar"===s.series[d].type||(n=Math.max(n,r.series[d][u]),e=Math.min(e,r.series[d][u])),i=n),r.seriesGoals[d]&&r.seriesGoals[d][u]&&Array.isArray(r.seriesGoals[d][u])&&r.seriesGoals[d][u].forEach((function(t){o!==Number.MIN_VALUE&&(o=Math.min(o,t.value),e=o),n=Math.max(n,t.value),i=n})),v.isFloat(p)&&(p=v.noExponents(p),r.yValueDecimal=Math.max(r.yValueDecimal,p.toString().split(".")[1].length)),o>c[d][u]&&c[d][u]<0&&(o=c[d][u])):r.hasNullValues=!0}}return"rangeBar"===s.chart.type&&r.seriesRangeStart.length&&r.isBarHorizontal&&(o=e),"bar"===s.chart.type&&(o<0&&n<0&&(n=0),o===Number.MIN_VALUE&&(o=0)),{minY:o,maxY:n,lowestY:e,highestY:i}}},{key:"setYRange",value:function(){var t=this.w.globals,e=this.w.config;t.maxY=-Number.MAX_VALUE,t.minY=Number.MIN_VALUE;var i=Number.MAX_VALUE;if(t.isMultipleYAxis)for(var a=0;a<t.series.length;a++){var s=this.getMinYMaxY(a,i,null,a+1);t.minYArr.push(s.minY),t.maxYArr.push(s.maxY),i=s.lowestY}var r=this.getMinYMaxY(0,i,null,t.series.length);if(t.minY=r.minY,t.maxY=r.maxY,i=r.lowestY,e.chart.stacked&&this._setStackedMinMax(),("line"===e.chart.type||"area"===e.chart.type||"candlestick"===e.chart.type||"boxPlot"===e.chart.type||"rangeBar"===e.chart.type&&!t.isBarHorizontal)&&t.minY===Number.MIN_VALUE&&i!==-Number.MAX_VALUE&&i!==t.maxY){var n=t.maxY-i;(i>=0&&i<=10||void 0!==e.yaxis[0].min||void 0!==e.yaxis[0].max)&&(n=0),t.minY=i-5*n/100,i>0&&t.minY<0&&(t.minY=0),t.maxY=t.maxY+5*n/100}return e.yaxis.forEach((function(e,i){void 0!==e.max&&("number"==typeof e.max?t.maxYArr[i]=e.max:"function"==typeof e.max&&(t.maxYArr[i]=e.max(t.isMultipleYAxis?t.maxYArr[i]:t.maxY)),t.maxY=t.maxYArr[i]),void 0!==e.min&&("number"==typeof e.min?t.minYArr[i]=e.min:"function"==typeof e.min&&(t.minYArr[i]=e.min(t.isMultipleYAxis?t.minYArr[i]===Number.MIN_VALUE?0:t.minYArr[i]:t.minY)),t.minY=t.minYArr[i])})),t.isBarHorizontal&&["min","max"].forEach((function(i){void 0!==e.xaxis[i]&&"number"==typeof e.xaxis[i]&&("min"===i?t.minY=e.xaxis[i]:t.maxY=e.xaxis[i])})),t.isMultipleYAxis?(this.scales.setMultipleYScales(),t.minY=i,t.yAxisScale.forEach((function(e,i){t.minYArr[i]=e.niceMin,t.maxYArr[i]=e.niceMax}))):(this.scales.setYScaleForIndex(0,t.minY,t.maxY),t.minY=t.yAxisScale[0].niceMin,t.maxY=t.yAxisScale[0].niceMax,t.minYArr[0]=t.yAxisScale[0].niceMin,t.maxYArr[0]=t.yAxisScale[0].niceMax),{minY:t.minY,maxY:t.maxY,minYArr:t.minYArr,maxYArr:t.maxYArr,yAxisScale:t.yAxisScale}}},{key:"setXRange",value:function(){var t=this.w.globals,e=this.w.config,i="numeric"===e.xaxis.type||"datetime"===e.xaxis.type||"category"===e.xaxis.type&&!t.noLabelsProvided||t.noLabelsProvided||t.isXNumeric;if(t.isXNumeric&&function(){for(var e=0;e<t.series.length;e++)if(t.labels[e])for(var i=0;i<t.labels[e].length;i++)null!==t.labels[e][i]&&v.isNumber(t.labels[e][i])&&(t.maxX=Math.max(t.maxX,t.labels[e][i]),t.initialMaxX=Math.max(t.maxX,t.labels[e][i]),t.minX=Math.min(t.minX,t.labels[e][i]),t.initialMinX=Math.min(t.minX,t.labels[e][i]))}(),t.noLabelsProvided&&0===e.xaxis.categories.length&&(t.maxX=t.labels[t.labels.length-1],t.initialMaxX=t.labels[t.labels.length-1],t.minX=1,t.initialMinX=1),t.isXNumeric||t.noLabelsProvided||t.dataFormatXNumeric){var a;if(void 0===e.xaxis.tickAmount?(a=Math.round(t.svgWidth/150),"numeric"===e.xaxis.type&&t.dataPoints<30&&(a=t.dataPoints-1),a>t.dataPoints&&0!==t.dataPoints&&(a=t.dataPoints-1)):"dataPoints"===e.xaxis.tickAmount?(t.series.length>1&&(a=t.series[t.maxValsInArrayIndex].length-1),t.isXNumeric&&(a=t.maxX-t.minX-1)):a=e.xaxis.tickAmount,t.xTickAmount=a,void 0!==e.xaxis.max&&"number"==typeof e.xaxis.max&&(t.maxX=e.xaxis.max),void 0!==e.xaxis.min&&"number"==typeof e.xaxis.min&&(t.minX=e.xaxis.min),void 0!==e.xaxis.range&&(t.minX=t.maxX-e.xaxis.range),t.minX!==Number.MAX_VALUE&&t.maxX!==-Number.MAX_VALUE)if(e.xaxis.convertedCatToNumeric&&!t.dataFormatXNumeric){for(var s=[],r=t.minX-1;r<t.maxX;r++)s.push(r+1);t.xAxisScale={result:s,niceMin:s[0],niceMax:s[s.length-1]}}else t.xAxisScale=this.scales.setXScale(t.minX,t.maxX);else t.xAxisScale=this.scales.linearScale(1,a,a),t.noLabelsProvided&&t.labels.length>0&&(t.xAxisScale=this.scales.linearScale(1,t.labels.length,a-1),t.seriesX=t.labels.slice());i&&(t.labels=t.xAxisScale.result.slice())}return t.isBarHorizontal&&t.labels.length&&(t.xTickAmount=t.labels.length),this._handleSingleDataPoint(),this._getMinXDiff(),{minX:t.minX,maxX:t.maxX}}},{key:"setZRange",value:function(){var t=this.w.globals;if(t.isDataXYZ)for(var e=0;e<t.series.length;e++)if(void 0!==t.seriesZ[e])for(var i=0;i<t.seriesZ[e].length;i++)null!==t.seriesZ[e][i]&&v.isNumber(t.seriesZ[e][i])&&(t.maxZ=Math.max(t.maxZ,t.seriesZ[e][i]),t.minZ=Math.min(t.minZ,t.seriesZ[e][i]))}},{key:"_handleSingleDataPoint",value:function(){var t=this.w.globals,e=this.w.config;if(t.minX===t.maxX){var i=new E(this.ctx);if("datetime"===e.xaxis.type){var a=i.getDate(t.minX);e.xaxis.labels.datetimeUTC?a.setUTCDate(a.getUTCDate()-2):a.setDate(a.getDate()-2),t.minX=new Date(a).getTime();var s=i.getDate(t.maxX);e.xaxis.labels.datetimeUTC?s.setUTCDate(s.getUTCDate()+2):s.setDate(s.getDate()+2),t.maxX=new Date(s).getTime()}else("numeric"===e.xaxis.type||"category"===e.xaxis.type&&!t.noLabelsProvided)&&(t.minX=t.minX-2,t.initialMinX=t.minX,t.maxX=t.maxX+2,t.initialMaxX=t.maxX)}}},{key:"_getMinXDiff",value:function(){var t=this.w.globals;t.isXNumeric&&t.seriesX.forEach((function(e,i){1===e.length&&e.push(t.seriesX[t.maxValsInArrayIndex][t.seriesX[t.maxValsInArrayIndex].length-1]);var a=e.slice();a.sort((function(t,e){return t-e})),a.forEach((function(e,i){if(i>0){var s=e-a[i-1];s>0&&(t.minXDiff=Math.min(s,t.minXDiff))}})),1!==t.dataPoints&&t.minXDiff!==Number.MAX_VALUE||(t.minXDiff=.5)}))}},{key:"_setStackedMinMax",value:function(){var t=this.w.globals,e=[],i=[];if(t.series.length)for(var a=0;a<t.series[t.maxValsInArrayIndex].length;a++)for(var s=0,r=0,n=0;n<t.series.length;n++)null!==t.series[n][a]&&v.isNumber(t.series[n][a])&&(t.series[n][a]>0?s=s+parseFloat(t.series[n][a])+1e-4:r+=parseFloat(t.series[n][a])),n===t.series.length-1&&(e.push(s),i.push(r));for(var o=0;o<e.length;o++)t.maxY=Math.max(t.maxY,e[o]),t.minY=Math.min(t.minY,i[o])}}]),t}(),J=function(){function t(e,i){o(this,t),this.ctx=e,this.elgrid=i,this.w=e.w;var a=this.w;this.xaxisFontSize=a.config.xaxis.labels.style.fontSize,this.axisFontFamily=a.config.xaxis.labels.style.fontFamily,this.xaxisForeColors=a.config.xaxis.labels.style.colors,this.isCategoryBarHorizontal="bar"===a.config.chart.type&&a.config.plotOptions.bar.horizontal,this.xAxisoffX=0,"bottom"===a.config.xaxis.position&&(this.xAxisoffX=a.globals.gridHeight),this.drawnLabels=[],this.axesUtils=new V(e)}return c(t,[{key:"drawYaxis",value:function(t){var e=this,i=this.w,a=new k(this.ctx),s=i.config.yaxis[t].labels.style,r=s.fontSize,n=s.fontFamily,o=s.fontWeight,l=a.group({class:"apexcharts-yaxis",rel:t,transform:"translate("+i.globals.translateYAxisX[t]+", 0)"});if(this.axesUtils.isYAxisHidden(t))return l;var c=a.group({class:"apexcharts-yaxis-texts-g"});l.add(c);var h=i.globals.yAxisScale[t].result.length-1,d=i.globals.gridHeight/h,u=i.globals.translateY,p=i.globals.yLabelFormatters[t],f=i.globals.yAxisScale[t].result.slice();f=this.axesUtils.checkForReversedLabels(t,f);var g="";if(i.config.yaxis[t].labels.show)for(var x=function(l){var x=f[l];x=p(x,l,i);var m=i.config.yaxis[t].labels.padding;i.config.yaxis[t].opposite&&0!==i.config.yaxis.length&&(m*=-1);var b=e.axesUtils.getYAxisForeColor(s.colors,t),v=a.drawText({x:m,y:u+h/10+i.config.yaxis[t].labels.offsetY+1,text:x,textAnchor:i.config.yaxis[t].opposite?"start":"end",fontSize:r,fontFamily:n,fontWeight:o,maxWidth:i.config.yaxis[t].labels.maxWidth,foreColor:Array.isArray(b)?b[l]:b,isPlainText:!1,cssClass:"apexcharts-yaxis-label "+s.cssClass});l===h&&(g=v),c.add(v);var y=document.createElementNS(i.globals.SVGNS,"title");if(y.textContent=Array.isArray(x)?x.join(" "):x,v.node.appendChild(y),0!==i.config.yaxis[t].labels.rotate){var w=a.rotateAroundCenter(g.node),k=a.rotateAroundCenter(v.node);v.node.setAttribute("transform","rotate(".concat(i.config.yaxis[t].labels.rotate," ").concat(w.x," ").concat(k.y,")"))}u+=d},m=h;m>=0;m--)x(m);if(void 0!==i.config.yaxis[t].title.text){var b=a.group({class:"apexcharts-yaxis-title"}),v=0;i.config.yaxis[t].opposite&&(v=i.globals.translateYAxisX[t]);var y=a.drawText({x:v,y:i.globals.gridHeight/2+i.globals.translateY+i.config.yaxis[t].title.offsetY,text:i.config.yaxis[t].title.text,textAnchor:"end",foreColor:i.config.yaxis[t].title.style.color,fontSize:i.config.yaxis[t].title.style.fontSize,fontWeight:i.config.yaxis[t].title.style.fontWeight,fontFamily:i.config.yaxis[t].title.style.fontFamily,cssClass:"apexcharts-yaxis-title-text "+i.config.yaxis[t].title.style.cssClass});b.add(y),l.add(b)}var w=i.config.yaxis[t].axisBorder,A=31+w.offsetX;if(i.config.yaxis[t].opposite&&(A=-31-w.offsetX),w.show){var S=a.drawLine(A,i.globals.translateY+w.offsetY-2,A,i.globals.gridHeight+i.globals.translateY+w.offsetY+2,w.color,0,w.width);l.add(S)}return i.config.yaxis[t].axisTicks.show&&this.axesUtils.drawYAxisTicks(A,h,w,i.config.yaxis[t].axisTicks,t,d,l),l}},{key:"drawYaxisInversed",value:function(t){var e=this.w,i=new k(this.ctx),a=i.group({class:"apexcharts-xaxis apexcharts-yaxis-inversed"}),s=i.group({class:"apexcharts-xaxis-texts-g",transform:"translate(".concat(e.globals.translateXAxisX,", ").concat(e.globals.translateXAxisY,")")});a.add(s);var r=e.globals.yAxisScale[t].result.length-1,n=e.globals.gridWidth/r+.1,o=n+e.config.xaxis.labels.offsetX,l=e.globals.xLabelFormatter,c=e.globals.yAxisScale[t].result.slice(),h=e.globals.timescaleLabels;h.length>0&&(this.xaxisLabels=h.slice(),r=(c=h.slice()).length),c=this.axesUtils.checkForReversedLabels(t,c);var d=h.length;if(e.config.xaxis.labels.show)for(var u=d?0:r;d?u<d:u>=0;d?u++:u--){var p=c[u];p=l(p,u,e);var f=e.globals.gridWidth+e.globals.padHorizontal-(o-n+e.config.xaxis.labels.offsetX);if(h.length){var g=this.axesUtils.getLabel(c,h,f,u,this.drawnLabels,this.xaxisFontSize);f=g.x,p=g.text,this.drawnLabels.push(g.text),0===u&&e.globals.skipFirstTimelinelabel&&(p=""),u===c.length-1&&e.globals.skipLastTimelinelabel&&(p="")}var x=i.drawText({x:f,y:this.xAxisoffX+e.config.xaxis.labels.offsetY+30-("top"===e.config.xaxis.position?e.globals.xAxisHeight+e.config.xaxis.axisTicks.height-2:0),text:p,textAnchor:"middle",foreColor:Array.isArray(this.xaxisForeColors)?this.xaxisForeColors[t]:this.xaxisForeColors,fontSize:this.xaxisFontSize,fontFamily:this.xaxisFontFamily,fontWeight:e.config.xaxis.labels.style.fontWeight,isPlainText:!1,cssClass:"apexcharts-xaxis-label "+e.config.xaxis.labels.style.cssClass});s.add(x),x.tspan(p);var m=document.createElementNS(e.globals.SVGNS,"title");m.textContent=p,x.node.appendChild(m),o+=n}return this.inversedYAxisTitleText(a),this.inversedYAxisBorder(a),a}},{key:"inversedYAxisBorder",value:function(t){var e=this.w,i=new k(this.ctx),a=e.config.xaxis.axisBorder;if(a.show){var s=0;"bar"===e.config.chart.type&&e.globals.isXNumeric&&(s-=15);var r=i.drawLine(e.globals.padHorizontal+s+a.offsetX,this.xAxisoffX,e.globals.gridWidth,this.xAxisoffX,a.color,0,a.height);this.elgrid&&this.elgrid.elGridBorders?this.elgrid.elGridBorders.add(r):t.add(r)}}},{key:"inversedYAxisTitleText",value:function(t){var e=this.w,i=new k(this.ctx);if(void 0!==e.config.xaxis.title.text){var a=i.group({class:"apexcharts-xaxis-title apexcharts-yaxis-title-inversed"}),s=i.drawText({x:e.globals.gridWidth/2+e.config.xaxis.title.offsetX,y:this.xAxisoffX+parseFloat(this.xaxisFontSize)+parseFloat(e.config.xaxis.title.style.fontSize)+e.config.xaxis.title.offsetY+20,text:e.config.xaxis.title.text,textAnchor:"middle",fontSize:e.config.xaxis.title.style.fontSize,fontFamily:e.config.xaxis.title.style.fontFamily,fontWeight:e.config.xaxis.title.style.fontWeight,foreColor:e.config.xaxis.title.style.color,cssClass:"apexcharts-xaxis-title-text "+e.config.xaxis.title.style.cssClass});a.add(s),t.add(a)}}},{key:"yAxisTitleRotate",value:function(t,e){var i=this.w,a=new k(this.ctx),s={width:0,height:0},r={width:0,height:0},n=i.globals.dom.baseEl.querySelector(" .apexcharts-yaxis[rel='".concat(t,"'] .apexcharts-yaxis-texts-g"));null!==n&&(s=n.getBoundingClientRect());var o=i.globals.dom.baseEl.querySelector(".apexcharts-yaxis[rel='".concat(t,"'] .apexcharts-yaxis-title text"));if(null!==o&&(r=o.getBoundingClientRect()),null!==o){var l=this.xPaddingForYAxisTitle(t,s,r,e);o.setAttribute("x",l.xPos-(e?10:0))}if(null!==o){var c=a.rotateAroundCenter(o);o.setAttribute("transform","rotate(".concat(e?-1*i.config.yaxis[t].title.rotate:i.config.yaxis[t].title.rotate," ").concat(c.x," ").concat(c.y,")"))}}},{key:"xPaddingForYAxisTitle",value:function(t,e,i,a){var s=this.w,r=0,n=0,o=10;return void 0===s.config.yaxis[t].title.text||t<0?{xPos:n,padd:0}:(a?(n=e.width+s.config.yaxis[t].title.offsetX+i.width/2+o/2,0===(r+=1)&&(n-=o/2)):(n=-1*e.width+s.config.yaxis[t].title.offsetX+o/2+i.width/2,s.globals.isBarHorizontal&&(o=25,n=-1*e.width-s.config.yaxis[t].title.offsetX-o)),{xPos:n,padd:o})}},{key:"setYAxisXPosition",value:function(t,e){var i=this.w,a=0,s=0,r=18,n=1;i.config.yaxis.length>1&&(this.multipleYs=!0),i.config.yaxis.map((function(o,l){var c=i.globals.ignoreYAxisIndexes.indexOf(l)>-1||!o.show||o.floating||0===t[l].width,h=t[l].width+e[l].width;o.opposite?i.globals.isBarHorizontal?(s=i.globals.gridWidth+i.globals.translateX-1,i.globals.translateYAxisX[l]=s-o.labels.offsetX):(s=i.globals.gridWidth+i.globals.translateX+n,c||(n=n+h+20),i.globals.translateYAxisX[l]=s-o.labels.offsetX+20):(a=i.globals.translateX-r,c||(r=r+h+20),i.globals.translateYAxisX[l]=a+o.labels.offsetX)}))}},{key:"setYAxisTextAlignments",value:function(){var t=this.w,e=t.globals.dom.baseEl.getElementsByClassName("apexcharts-yaxis");(e=v.listToArray(e)).forEach((function(e,i){var a=t.config.yaxis[i];if(a&&void 0!==a.labels.align){var s=t.globals.dom.baseEl.querySelector(".apexcharts-yaxis[rel='".concat(i,"'] .apexcharts-yaxis-texts-g")),r=t.globals.dom.baseEl.querySelectorAll(".apexcharts-yaxis[rel='".concat(i,"'] .apexcharts-yaxis-label"));r=v.listToArray(r);var n=s.getBoundingClientRect();"left"===a.labels.align?(r.forEach((function(t,e){t.setAttribute("text-anchor","start")})),a.opposite||s.setAttribute("transform","translate(-".concat(n.width,", 0)"))):"center"===a.labels.align?(r.forEach((function(t,e){t.setAttribute("text-anchor","middle")})),s.setAttribute("transform","translate(".concat(n.width/2*(a.opposite?1:-1),", 0)"))):"right"===a.labels.align&&(r.forEach((function(t,e){t.setAttribute("text-anchor","end")})),a.opposite&&s.setAttribute("transform","translate(".concat(n.width,", 0)")))}}))}}]),t}(),Q=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w,this.documentEvent=v.bind(this.documentEvent,this)}return c(t,[{key:"addEventListener",value:function(t,e){var i=this.w;i.globals.events.hasOwnProperty(t)?i.globals.events[t].push(e):i.globals.events[t]=[e]}},{key:"removeEventListener",value:function(t,e){var i=this.w;if(i.globals.events.hasOwnProperty(t)){var a=i.globals.events[t].indexOf(e);-1!==a&&i.globals.events[t].splice(a,1)}}},{key:"fireEvent",value:function(t,e){var i=this.w;if(i.globals.events.hasOwnProperty(t)){e&&e.length||(e=[]);for(var a=i.globals.events[t],s=a.length,r=0;r<s;r++)a[r].apply(null,e)}}},{key:"setupEventHandlers",value:function(){var t=this,e=this.w,i=this.ctx,a=e.globals.dom.baseEl.querySelector(e.globals.chartClass);this.ctx.eventList.forEach((function(t){a.addEventListener(t,(function(t){var a=Object.assign({},e,{seriesIndex:e.globals.capturedSeriesIndex,dataPointIndex:e.globals.capturedDataPointIndex});"mousemove"===t.type||"touchmove"===t.type?"function"==typeof e.config.chart.events.mouseMove&&e.config.chart.events.mouseMove(t,i,a):"mouseleave"===t.type||"touchleave"===t.type?"function"==typeof e.config.chart.events.mouseLeave&&e.config.chart.events.mouseLeave(t,i,a):("mouseup"===t.type&&1===t.which||"touchend"===t.type)&&("function"==typeof e.config.chart.events.click&&e.config.chart.events.click(t,i,a),i.ctx.events.fireEvent("click",[t,i,a]))}),{capture:!1,passive:!0})})),this.ctx.eventList.forEach((function(i){e.globals.dom.baseEl.addEventListener(i,t.documentEvent,{passive:!0})})),this.ctx.core.setupBrushHandler()}},{key:"documentEvent",value:function(t){var e=this.w,i=t.target.className;if("click"===t.type){var a=e.globals.dom.baseEl.querySelector(".apexcharts-menu");a&&a.classList.contains("apexcharts-menu-open")&&"apexcharts-menu-icon"!==i&&a.classList.remove("apexcharts-menu-open")}e.globals.clientX="touchmove"===t.type?t.touches[0].clientX:t.clientX,e.globals.clientY="touchmove"===t.type?t.touches[0].clientY:t.clientY}}]),t}(),K=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w}return c(t,[{key:"setCurrentLocaleValues",value:function(t){var e=this.w.config.chart.locales;window.Apex.chart&&window.Apex.chart.locales&&window.Apex.chart.locales.length>0&&(e=this.w.config.chart.locales.concat(window.Apex.chart.locales));var i=e.filter((function(e){return e.name===t}))[0];if(!i)throw new Error("Wrong locale name provided. Please make sure you set the correct locale name in options");var a=v.extend(D,i);this.w.globals.locale=a.options}}]),t}(),tt=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w}return c(t,[{key:"drawAxis",value:function(t,e){var i,a,s=this.w.globals,r=this.w.config,n=new U(this.ctx,e),o=new J(this.ctx,e);s.axisCharts&&"radar"!==t&&(s.isBarHorizontal?(a=o.drawYaxisInversed(0),i=n.drawXaxisInversed(0),s.dom.elGraphical.add(i),s.dom.elGraphical.add(a)):(i=n.drawXaxis(),s.dom.elGraphical.add(i),r.yaxis.map((function(t,e){-1===s.ignoreYAxisIndexes.indexOf(e)&&(a=o.drawYaxis(e),s.dom.Paper.add(a))}))))}}]),t}(),et=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w}return c(t,[{key:"drawXCrosshairs",value:function(){var t=this.w,e=new k(this.ctx),i=new w(this.ctx),a=t.config.xaxis.crosshairs.fill.gradient,s=t.config.xaxis.crosshairs.dropShadow,r=t.config.xaxis.crosshairs.fill.type,n=a.colorFrom,o=a.colorTo,l=a.opacityFrom,c=a.opacityTo,h=a.stops,d=s.enabled,u=s.left,p=s.top,f=s.blur,g=s.color,x=s.opacity,m=t.config.xaxis.crosshairs.fill.color;if(t.config.xaxis.crosshairs.show){"gradient"===r&&(m=e.drawGradient("vertical",n,o,l,c,null,h,null));var b=e.drawRect();1===t.config.xaxis.crosshairs.width&&(b=e.drawLine());var y=t.globals.gridHeight;(!v.isNumber(y)||y<0)&&(y=0);var A=t.config.xaxis.crosshairs.width;(!v.isNumber(A)||A<0)&&(A=0),b.attr({class:"apexcharts-xcrosshairs",x:0,y:0,y2:y,width:A,height:y,fill:m,filter:"none","fill-opacity":t.config.xaxis.crosshairs.opacity,stroke:t.config.xaxis.crosshairs.stroke.color,"stroke-width":t.config.xaxis.crosshairs.stroke.width,"stroke-dasharray":t.config.xaxis.crosshairs.stroke.dashArray}),d&&(b=i.dropShadow(b,{left:u,top:p,blur:f,color:g,opacity:x})),t.globals.dom.elGraphical.add(b)}}},{key:"drawYCrosshairs",value:function(){var t=this.w,e=new k(this.ctx),i=t.config.yaxis[0].crosshairs,a=t.globals.barPadForNumericAxis;if(t.config.yaxis[0].crosshairs.show){var s=e.drawLine(-a,0,t.globals.gridWidth+a,0,i.stroke.color,i.stroke.dashArray,i.stroke.width);s.attr({class:"apexcharts-ycrosshairs"}),t.globals.dom.elGraphical.add(s)}var r=e.drawLine(-a,0,t.globals.gridWidth+a,0,i.stroke.color,0,0);r.attr({class:"apexcharts-ycrosshairs-hidden"}),t.globals.dom.elGraphical.add(r)}}]),t}(),it=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w}return c(t,[{key:"checkResponsiveConfig",value:function(t){var e=this,i=this.w,a=i.config;if(0!==a.responsive.length){var s=a.responsive.slice();s.sort((function(t,e){return t.breakpoint>e.breakpoint?1:e.breakpoint>t.breakpoint?-1:0})).reverse();var r=new R({}),n=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},a=s[0].breakpoint,n=window.innerWidth>0?window.innerWidth:screen.width;if(n>a){var o=A.extendArrayProps(r,i.globals.initialConfig,i);t=v.extend(o,t),t=v.extend(i.config,t),e.overrideResponsiveOptions(t)}else for(var l=0;l<s.length;l++)n<s[l].breakpoint&&(t=A.extendArrayProps(r,s[l].options,i),t=v.extend(i.config,t),e.overrideResponsiveOptions(t))};if(t){var o=A.extendArrayProps(r,t,i);o=v.extend(i.config,o),n(o=v.extend(o,t))}else n({})}}},{key:"overrideResponsiveOptions",value:function(t){var e=new R(t).init({responsiveOverride:!0});this.w.config=e}}]),t}(),at=function(){function t(e){o(this,t),this.ctx=e,this.colors=[],this.w=e.w;var i=this.w;this.isColorFn=!1,this.isHeatmapDistributed="treemap"===i.config.chart.type&&i.config.plotOptions.treemap.distributed||"heatmap"===i.config.chart.type&&i.config.plotOptions.heatmap.distributed,this.isBarDistributed=i.config.plotOptions.bar.distributed&&("bar"===i.config.chart.type||"rangeBar"===i.config.chart.type)}return c(t,[{key:"init",value:function(){this.setDefaultColors()}},{key:"setDefaultColors",value:function(){var t=this,e=this.w,i=new v;if(e.globals.dom.elWrap.classList.add("apexcharts-theme-".concat(e.config.theme.mode)),void 0===e.config.colors?e.globals.colors=this.predefined():(e.globals.colors=e.config.colors,Array.isArray(e.config.colors)&&e.config.colors.length>0&&"function"==typeof e.config.colors[0]&&(e.globals.colors=e.config.series.map((function(i,a){var s=e.config.colors[a];return s||(s=e.config.colors[0]),"function"==typeof s?(t.isColorFn=!0,s({value:e.globals.axisCharts?e.globals.series[a][0]?e.globals.series[a][0]:0:e.globals.series[a],seriesIndex:a,dataPointIndex:a,w:e})):s})))),e.globals.seriesColors.map((function(t,i){t&&(e.globals.colors[i]=t)})),e.config.theme.monochrome.enabled){var a=[],s=e.globals.series.length;(this.isBarDistributed||this.isHeatmapDistributed)&&(s=e.globals.series[0].length*e.globals.series.length);for(var r=e.config.theme.monochrome.color,n=1/(s/e.config.theme.monochrome.shadeIntensity),o=e.config.theme.monochrome.shadeTo,l=0,c=0;c<s;c++){var h=void 0;"dark"===o?(h=i.shadeColor(-1*l,r),l+=n):(h=i.shadeColor(l,r),l+=n),a.push(h)}e.globals.colors=a.slice()}var d=e.globals.colors.slice();this.pushExtraColors(e.globals.colors),["fill","stroke"].forEach((function(i){void 0===e.config[i].colors?e.globals[i].colors=t.isColorFn?e.config.colors:d:e.globals[i].colors=e.config[i].colors.slice(),t.pushExtraColors(e.globals[i].colors)})),void 0===e.config.dataLabels.style.colors?e.globals.dataLabels.style.colors=d:e.globals.dataLabels.style.colors=e.config.dataLabels.style.colors.slice(),this.pushExtraColors(e.globals.dataLabels.style.colors,50),void 0===e.config.plotOptions.radar.polygons.fill.colors?e.globals.radarPolygons.fill.colors=["dark"===e.config.theme.mode?"#424242":"none"]:e.globals.radarPolygons.fill.colors=e.config.plotOptions.radar.polygons.fill.colors.slice(),this.pushExtraColors(e.globals.radarPolygons.fill.colors,20),void 0===e.config.markers.colors?e.globals.markers.colors=d:e.globals.markers.colors=e.config.markers.colors.slice(),this.pushExtraColors(e.globals.markers.colors)}},{key:"pushExtraColors",value:function(t,e){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,a=this.w,s=e||a.globals.series.length;if(null===i&&(i=this.isBarDistributed||this.isHeatmapDistributed||"heatmap"===a.config.chart.type&&a.config.plotOptions.heatmap.colorScale.inverse),i&&a.globals.series.length&&(s=a.globals.series[a.globals.maxValsInArrayIndex].length*a.globals.series.length),t.length<s)for(var r=s-t.length,n=0;n<r;n++)t.push(t[n])}},{key:"updateThemeOptions",value:function(t){t.chart=t.chart||{},t.tooltip=t.tooltip||{};var e=t.theme.mode||"light",i=t.theme.palette?t.theme.palette:"dark"===e?"palette4":"palette1",a=t.chart.foreColor?t.chart.foreColor:"dark"===e?"#f6f7f8":"#373d3f";return t.tooltip.theme=e,t.chart.foreColor=a,t.theme.palette=i,t}},{key:"predefined",value:function(){switch(this.w.config.theme.palette){case"palette1":default:this.colors=["#008FFB","#00E396","#FEB019","#FF4560","#775DD0"];break;case"palette2":this.colors=["#3f51b5","#03a9f4","#4caf50","#f9ce1d","#FF9800"];break;case"palette3":this.colors=["#33b2df","#546E7A","#d4526e","#13d8aa","#A5978B"];break;case"palette4":this.colors=["#4ecdc4","#c7f464","#81D4FA","#fd6a6a","#546E7A"];break;case"palette5":this.colors=["#2b908f","#f9a3a4","#90ee7e","#fa4443","#69d2e7"];break;case"palette6":this.colors=["#449DD1","#F86624","#EA3546","#662E9B","#C5D86D"];break;case"palette7":this.colors=["#D7263D","#1B998B","#2E294E","#F46036","#E2C044"];break;case"palette8":this.colors=["#662E9B","#F86624","#F9C80E","#EA3546","#43BCCD"];break;case"palette9":this.colors=["#5C4742","#A5978B","#8D5B4C","#5A2A27","#C4BBAF"];break;case"palette10":this.colors=["#A300D6","#7D02EB","#5653FE","#2983FF","#00B1F2"]}return this.colors}}]),t}(),st=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w}return c(t,[{key:"draw",value:function(){this.drawTitleSubtitle("title"),this.drawTitleSubtitle("subtitle")}},{key:"drawTitleSubtitle",value:function(t){var e=this.w,i="title"===t?e.config.title:e.config.subtitle,a=e.globals.svgWidth/2,s=i.offsetY,r="middle";if("left"===i.align?(a=10,r="start"):"right"===i.align&&(a=e.globals.svgWidth-10,r="end"),a+=i.offsetX,s=s+parseInt(i.style.fontSize,10)+i.margin/2,void 0!==i.text){var n=new k(this.ctx).drawText({x:a,y:s,text:i.text,textAnchor:r,fontSize:i.style.fontSize,fontFamily:i.style.fontFamily,fontWeight:i.style.fontWeight,foreColor:i.style.color,opacity:1});n.node.setAttribute("class","apexcharts-".concat(t,"-text")),e.globals.dom.Paper.add(n)}}}]),t}(),rt=function(){function t(e){o(this,t),this.w=e.w,this.dCtx=e}return c(t,[{key:"getTitleSubtitleCoords",value:function(t){var e=this.w,i=0,a=0,s="title"===t?e.config.title.floating:e.config.subtitle.floating,r=e.globals.dom.baseEl.querySelector(".apexcharts-".concat(t,"-text"));if(null!==r&&!s){var n=r.getBoundingClientRect();i=n.width,a=e.globals.axisCharts?n.height+5:n.height}return{width:i,height:a}}},{key:"getLegendsRect",value:function(){var t=this.w,e=t.globals.dom.baseEl.querySelector(".apexcharts-legend");t.config.legend.height||"top"!==t.config.legend.position&&"bottom"!==t.config.legend.position||(e.style.maxHeight=t.globals.svgHeight/2+"px");var i=Object.assign({},v.getBoundingClientRect(e));return null!==e&&!t.config.legend.floating&&t.config.legend.show?this.dCtx.lgRect={x:i.x,y:i.y,height:i.height,width:0===i.height?0:i.width}:this.dCtx.lgRect={x:0,y:0,height:0,width:0},"left"!==t.config.legend.position&&"right"!==t.config.legend.position||1.5*this.dCtx.lgRect.width>t.globals.svgWidth&&(this.dCtx.lgRect.width=t.globals.svgWidth/1.5),this.dCtx.lgRect}},{key:"getLargestStringFromMultiArr",value:function(t,e){var i=t;if(this.w.globals.isMultiLineX){var a=e.map((function(t,e){return Array.isArray(t)?t.length:1})),s=Math.max.apply(Math,x(a));i=e[a.indexOf(s)]}return i}}]),t}(),nt=function(){function t(e){o(this,t),this.w=e.w,this.dCtx=e}return c(t,[{key:"getxAxisLabelsCoords",value:function(){var t,e=this.w,i=e.globals.labels.slice();if(e.config.xaxis.convertedCatToNumeric&&0===i.length&&(i=e.globals.categoryLabels),e.globals.timescaleLabels.length>0){var a=this.getxAxisTimeScaleLabelsCoords();t={width:a.width,height:a.height},e.globals.rotateXLabels=!1}else{this.dCtx.lgWidthForSideLegends="left"!==e.config.legend.position&&"right"!==e.config.legend.position||e.config.legend.floating?0:this.dCtx.lgRect.width;var s=e.globals.xLabelFormatter,r=v.getLargestStringFromArr(i),n=this.dCtx.dimHelpers.getLargestStringFromMultiArr(r,i);e.globals.isBarHorizontal&&(n=r=e.globals.yAxisScale[0].result.reduce((function(t,e){return t.length>e.length?t:e}),0));var o=new j(this.dCtx.ctx),l=r;r=o.xLabelFormat(s,r,l,{i:void 0,dateFormatter:new E(this.dCtx.ctx).formatDate,w:e}),n=o.xLabelFormat(s,n,l,{i:void 0,dateFormatter:new E(this.dCtx.ctx).formatDate,w:e}),(e.config.xaxis.convertedCatToNumeric&&void 0===r||""===String(r).trim())&&(n=r="1");var c=new k(this.dCtx.ctx),h=c.getTextRects(r,e.config.xaxis.labels.style.fontSize),d=h;if(r!==n&&(d=c.getTextRects(n,e.config.xaxis.labels.style.fontSize)),(t={width:h.width>=d.width?h.width:d.width,height:h.height>=d.height?h.height:d.height}).width*i.length>e.globals.svgWidth-this.dCtx.lgWidthForSideLegends-this.dCtx.yAxisWidth-this.dCtx.gridPad.left-this.dCtx.gridPad.right&&0!==e.config.xaxis.labels.rotate||e.config.xaxis.labels.rotateAlways){if(!e.globals.isBarHorizontal){e.globals.rotateXLabels=!0;var u=function(t){return c.getTextRects(t,e.config.xaxis.labels.style.fontSize,e.config.xaxis.labels.style.fontFamily,"rotate(".concat(e.config.xaxis.labels.rotate," 0 0)"),!1)};h=u(r),r!==n&&(d=u(n)),t.height=(h.height>d.height?h.height:d.height)/1.5,t.width=h.width>d.width?h.width:d.width}}else e.globals.rotateXLabels=!1}return e.config.xaxis.labels.show||(t={width:0,height:0}),{width:t.width,height:t.height}}},{key:"getxAxisGroupLabelsCoords",value:function(){var t,e=this.w;if(!e.globals.hasGroups)return{width:0,height:0};var i,a=(null===(t=e.config.xaxis.group.style)||void 0===t?void 0:t.fontSize)||e.config.xaxis.labels.style.fontSize,s=e.globals.groups.map((function(t){return t.title})),r=v.getLargestStringFromArr(s),n=this.dCtx.dimHelpers.getLargestStringFromMultiArr(r,s),o=new k(this.dCtx.ctx),l=o.getTextRects(r,a),c=l;return r!==n&&(c=o.getTextRects(n,a)),i={width:l.width>=c.width?l.width:c.width,height:l.height>=c.height?l.height:c.height},e.config.xaxis.labels.show||(i={width:0,height:0}),{width:i.width,height:i.height}}},{key:"getxAxisTitleCoords",value:function(){var t=this.w,e=0,i=0;if(void 0!==t.config.xaxis.title.text){var a=new k(this.dCtx.ctx).getTextRects(t.config.xaxis.title.text,t.config.xaxis.title.style.fontSize);e=a.width,i=a.height}return{width:e,height:i}}},{key:"getxAxisTimeScaleLabelsCoords",value:function(){var t,e=this.w;this.dCtx.timescaleLabels=e.globals.timescaleLabels.slice();var i=this.dCtx.timescaleLabels.map((function(t){return t.value})),a=i.reduce((function(t,e){return void 0===t?(console.error("You have possibly supplied invalid Date format. Please supply a valid JavaScript Date"),0):t.length>e.length?t:e}),0);return 1.05*(t=new k(this.dCtx.ctx).getTextRects(a,e.config.xaxis.labels.style.fontSize)).width*i.length>e.globals.gridWidth&&0!==e.config.xaxis.labels.rotate&&(e.globals.overlappingXLabels=!0),t}},{key:"additionalPaddingXLabels",value:function(t){var e=this,i=this.w,a=i.globals,s=i.config,r=s.xaxis.type,n=t.width;a.skipLastTimelinelabel=!1,a.skipFirstTimelinelabel=!1;var o=i.config.yaxis[0].opposite&&i.globals.isBarHorizontal,l=function(t,o){(function(t){return-1!==a.collapsedSeriesIndices.indexOf(t)})(o)||function(t){if(e.dCtx.timescaleLabels&&e.dCtx.timescaleLabels.length){var o=e.dCtx.timescaleLabels[0],l=e.dCtx.timescaleLabels[e.dCtx.timescaleLabels.length-1].position+n/1.75-e.dCtx.yAxisWidthRight,c=o.position-n/1.75+e.dCtx.yAxisWidthLeft,h="right"===i.config.legend.position&&e.dCtx.lgRect.width>0?e.dCtx.lgRect.width:0;l>a.svgWidth-a.translateX-h&&(a.skipLastTimelinelabel=!0),c<-(t.show&&!t.floating||"bar"!==s.chart.type&&"candlestick"!==s.chart.type&&"rangeBar"!==s.chart.type&&"boxPlot"!==s.chart.type?10:n/1.75)&&(a.skipFirstTimelinelabel=!0)}else"datetime"===r?e.dCtx.gridPad.right<n&&!a.rotateXLabels&&(a.skipLastTimelinelabel=!0):"datetime"!==r&&e.dCtx.gridPad.right<n/2-e.dCtx.yAxisWidthRight&&!a.rotateXLabels&&!i.config.xaxis.labels.trim&&("between"!==i.config.xaxis.tickPlacement||i.globals.isBarHorizontal)&&(e.dCtx.xPadRight=n/2+1)}(t)};s.yaxis.forEach((function(t,i){o?(e.dCtx.gridPad.left<n&&(e.dCtx.xPadLeft=n/2+1),e.dCtx.xPadRight=n/2+1):l(t,i)}))}}]),t}(),ot=function(){function t(e){o(this,t),this.w=e.w,this.dCtx=e}return c(t,[{key:"getyAxisLabelsCoords",value:function(){var t=this,e=this.w,i=[],a=10,s=new V(this.dCtx.ctx);return e.config.yaxis.map((function(r,n){var o=e.globals.yAxisScale[n],l=0;if(!s.isYAxisHidden(n)&&r.labels.show&&void 0!==r.labels.minWidth&&(l=r.labels.minWidth),!s.isYAxisHidden(n)&&r.labels.show&&o.result.length){var c=e.globals.yLabelFormatters[n],h=o.niceMin===Number.MIN_VALUE?0:o.niceMin,d=String(h).length>String(o.niceMax).length?h:o.niceMax,u=c(d,{seriesIndex:n,dataPointIndex:-1,w:e}),p=u;if(void 0!==u&&0!==u.length||(u=d),e.globals.isBarHorizontal){a=0;var f=e.globals.labels.slice();u=c(u=v.getLargestStringFromArr(f),{seriesIndex:n,dataPointIndex:-1,w:e}),p=t.dCtx.dimHelpers.getLargestStringFromMultiArr(u,f)}var g=new k(t.dCtx.ctx),x="rotate(".concat(r.labels.rotate," 0 0)"),m=g.getTextRects(u,r.labels.style.fontSize,r.labels.style.fontFamily,x,!1),b=m;u!==p&&(b=g.getTextRects(p,r.labels.style.fontSize,r.labels.style.fontFamily,x,!1)),i.push({width:(l>b.width||l>m.width?l:b.width>m.width?b.width:m.width)+a,height:b.height>m.height?b.height:m.height})}else i.push({width:0,height:0})})),i}},{key:"getyAxisTitleCoords",value:function(){var t=this,e=this.w,i=[];return e.config.yaxis.map((function(e,a){if(e.show&&void 0!==e.title.text){var s=new k(t.dCtx.ctx),r="rotate(".concat(e.title.rotate," 0 0)"),n=s.getTextRects(e.title.text,e.title.style.fontSize,e.title.style.fontFamily,r,!1);i.push({width:n.width,height:n.height})}else i.push({width:0,height:0})})),i}},{key:"getTotalYAxisWidth",value:function(){var t=this.w,e=0,i=0,a=0,s=t.globals.yAxisScale.length>1?10:0,r=new V(this.dCtx.ctx),n=function(n,o){var l=t.config.yaxis[o].floating,c=0;n.width>0&&!l?(c=n.width+s,function(e){return t.globals.ignoreYAxisIndexes.indexOf(e)>-1}(o)&&(c=c-n.width-s)):c=l||r.isYAxisHidden(o)?0:5,t.config.yaxis[o].opposite?a+=c:i+=c,e+=c};return t.globals.yLabelsCoords.map((function(t,e){n(t,e)})),t.globals.yTitleCoords.map((function(t,e){n(t,e)})),t.globals.isBarHorizontal&&!t.config.yaxis[0].floating&&(e=t.globals.yLabelsCoords[0].width+t.globals.yTitleCoords[0].width+15),this.dCtx.yAxisWidthLeft=i,this.dCtx.yAxisWidthRight=a,e}}]),t}(),lt=function(){function t(e){o(this,t),this.w=e.w,this.dCtx=e}return c(t,[{key:"gridPadForColumnsInNumericAxis",value:function(t){var e=this.w;if(e.globals.noData||e.globals.allSeriesCollapsed)return 0;var i=function(t){return"bar"===t||"rangeBar"===t||"candlestick"===t||"boxPlot"===t},a=e.config.chart.type,s=0,r=i(a)?e.config.series.length:1;if(e.globals.comboBarCount>0&&(r=e.globals.comboBarCount),e.globals.collapsedSeries.forEach((function(t){i(t.type)&&(r-=1)})),e.config.chart.stacked&&(r=1),(i(a)||e.globals.comboBarCount>0)&&e.globals.isXNumeric&&!e.globals.isBarHorizontal&&r>0){var n,o,l=Math.abs(e.globals.initialMaxX-e.globals.initialMinX);l<=3&&(l=e.globals.dataPoints),n=l/t,e.globals.minXDiff&&e.globals.minXDiff/n>0&&(o=e.globals.minXDiff/n),o>t/2&&(o/=2),(s=o/r*parseInt(e.config.plotOptions.bar.columnWidth,10)/100)<1&&(s=1),s=s/(r>1?1:1.5)+5,e.globals.barPadForNumericAxis=s}return s}},{key:"gridPadFortitleSubtitle",value:function(){var t=this,e=this.w,i=e.globals,a=this.dCtx.isSparkline||!e.globals.axisCharts?0:10;["title","subtitle"].forEach((function(i){void 0!==e.config[i].text?a+=e.config[i].margin:a+=t.dCtx.isSparkline||!e.globals.axisCharts?0:5})),!e.config.legend.show||"bottom"!==e.config.legend.position||e.config.legend.floating||e.globals.axisCharts||(a+=10);var s=this.dCtx.dimHelpers.getTitleSubtitleCoords("title"),r=this.dCtx.dimHelpers.getTitleSubtitleCoords("subtitle");i.gridHeight=i.gridHeight-s.height-r.height-a,i.translateY=i.translateY+s.height+r.height+a}},{key:"setGridXPosForDualYAxis",value:function(t,e){var i=this.w,a=new V(this.dCtx.ctx);i.config.yaxis.map((function(s,r){-1!==i.globals.ignoreYAxisIndexes.indexOf(r)||s.floating||a.isYAxisHidden(r)||(s.opposite&&(i.globals.translateX=i.globals.translateX-(e[r].width+t[r].width)-parseInt(i.config.yaxis[r].labels.style.fontSize,10)/1.2-12),i.globals.translateX<2&&(i.globals.translateX=2))}))}}]),t}(),ct=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w,this.lgRect={},this.yAxisWidth=0,this.yAxisWidthLeft=0,this.yAxisWidthRight=0,this.xAxisHeight=0,this.isSparkline=this.w.config.chart.sparkline.enabled,this.dimHelpers=new rt(this),this.dimYAxis=new ot(this),this.dimXAxis=new nt(this),this.dimGrid=new lt(this),this.lgWidthForSideLegends=0,this.gridPad=this.w.config.grid.padding,this.xPadRight=0,this.xPadLeft=0}return c(t,[{key:"plotCoords",value:function(){var t=this,e=this.w,i=e.globals;this.lgRect=this.dimHelpers.getLegendsRect(),this.isSparkline&&(e.config.markers.discrete.length>0||e.config.markers.size>0)&&Object.entries(this.gridPad).forEach((function(e){var i=function(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var i=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=i){var a,s,r=[],n=!0,o=!1;try{for(i=i.call(t);!(n=(a=i.next()).done)&&(r.push(a.value),2!==r.length);n=!0);}catch(t){o=!0,s=t}finally{try{n||null==i.return||i.return()}finally{if(o)throw s}}return r}}(t)||m(t,2)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(e),a=i[0],s=i[1];t.gridPad[a]=Math.max(s,t.w.globals.markers.largestSize/1.5)})),i.axisCharts?this.setDimensionsForAxisCharts():this.setDimensionsForNonAxisCharts(),this.dimGrid.gridPadFortitleSubtitle(),i.gridHeight=i.gridHeight-this.gridPad.top-this.gridPad.bottom,i.gridWidth=i.gridWidth-this.gridPad.left-this.gridPad.right-this.xPadRight-this.xPadLeft;var a=this.dimGrid.gridPadForColumnsInNumericAxis(i.gridWidth);i.gridWidth=i.gridWidth-2*a,i.translateX=i.translateX+this.gridPad.left+this.xPadLeft+(a>0?a+4:0),i.translateY=i.translateY+this.gridPad.top}},{key:"setDimensionsForAxisCharts",value:function(){var t=this,e=this.w,i=e.globals,a=this.dimYAxis.getyAxisLabelsCoords(),s=this.dimYAxis.getyAxisTitleCoords();e.globals.yLabelsCoords=[],e.globals.yTitleCoords=[],e.config.yaxis.map((function(t,i){e.globals.yLabelsCoords.push({width:a[i].width,index:i}),e.globals.yTitleCoords.push({width:s[i].width,index:i})})),this.yAxisWidth=this.dimYAxis.getTotalYAxisWidth();var r=this.dimXAxis.getxAxisLabelsCoords(),n=this.dimXAxis.getxAxisGroupLabelsCoords(),o=this.dimXAxis.getxAxisTitleCoords();this.conditionalChecksForAxisCoords(r,o,n),i.translateXAxisY=e.globals.rotateXLabels?this.xAxisHeight/8:-4,i.translateXAxisX=e.globals.rotateXLabels&&e.globals.isXNumeric&&e.config.xaxis.labels.rotate<=-45?-this.xAxisWidth/4:0,e.globals.isBarHorizontal&&(i.rotateXLabels=!1,i.translateXAxisY=parseInt(e.config.xaxis.labels.style.fontSize,10)/1.5*-1),i.translateXAxisY=i.translateXAxisY+e.config.xaxis.labels.offsetY,i.translateXAxisX=i.translateXAxisX+e.config.xaxis.labels.offsetX;var l=this.yAxisWidth,c=this.xAxisHeight;i.xAxisLabelsHeight=this.xAxisHeight-o.height,i.xAxisGroupLabelsHeight=i.xAxisLabelsHeight-r.height,i.xAxisLabelsWidth=this.xAxisWidth,i.xAxisHeight=this.xAxisHeight;var h=10;("radar"===e.config.chart.type||this.isSparkline)&&(l=0,c=i.goldenPadding),this.isSparkline&&(this.lgRect={height:0,width:0}),(this.isSparkline||"treemap"===e.config.chart.type)&&(l=0,c=0,h=0),this.isSparkline||this.dimXAxis.additionalPaddingXLabels(r);var d=function(){i.translateX=l,i.gridHeight=i.svgHeight-t.lgRect.height-c-(t.isSparkline||"treemap"===e.config.chart.type?0:e.globals.rotateXLabels?10:15),i.gridWidth=i.svgWidth-l};switch("top"===e.config.xaxis.position&&(h=i.xAxisHeight-e.config.xaxis.axisTicks.height-5),e.config.legend.position){case"bottom":i.translateY=h,d();break;case"top":i.translateY=this.lgRect.height+h,d();break;case"left":i.translateY=h,i.translateX=this.lgRect.width+l,i.gridHeight=i.svgHeight-c-12,i.gridWidth=i.svgWidth-this.lgRect.width-l;break;case"right":i.translateY=h,i.translateX=l,i.gridHeight=i.svgHeight-c-12,i.gridWidth=i.svgWidth-this.lgRect.width-l-5;break;default:throw new Error("Legend position not supported")}this.dimGrid.setGridXPosForDualYAxis(s,a),new J(this.ctx).setYAxisXPosition(a,s)}},{key:"setDimensionsForNonAxisCharts",value:function(){var t=this.w,e=t.globals,i=t.config,a=0;t.config.legend.show&&!t.config.legend.floating&&(a=20);var s="pie"===i.chart.type||"polarArea"===i.chart.type||"donut"===i.chart.type?"pie":"radialBar",r=i.plotOptions[s].offsetY,n=i.plotOptions[s].offsetX;if(!i.legend.show||i.legend.floating)return e.gridHeight=e.svgHeight-i.grid.padding.left+i.grid.padding.right,e.gridWidth=e.gridHeight,e.translateY=r,void(e.translateX=n+(e.svgWidth-e.gridWidth)/2);switch(i.legend.position){case"bottom":e.gridHeight=e.svgHeight-this.lgRect.height-e.goldenPadding,e.gridWidth=e.svgWidth,e.translateY=r-10,e.translateX=n+(e.svgWidth-e.gridWidth)/2;break;case"top":e.gridHeight=e.svgHeight-this.lgRect.height-e.goldenPadding,e.gridWidth=e.svgWidth,e.translateY=this.lgRect.height+r+10,e.translateX=n+(e.svgWidth-e.gridWidth)/2;break;case"left":e.gridWidth=e.svgWidth-this.lgRect.width-a,e.gridHeight="auto"!==i.chart.height?e.svgHeight:e.gridWidth,e.translateY=r,e.translateX=n+this.lgRect.width+a;break;case"right":e.gridWidth=e.svgWidth-this.lgRect.width-a-5,e.gridHeight="auto"!==i.chart.height?e.svgHeight:e.gridWidth,e.translateY=r,e.translateX=n+10;break;default:throw new Error("Legend position not supported")}}},{key:"conditionalChecksForAxisCoords",value:function(t,e,i){var a=this.w,s=a.globals.hasGroups?2:1,r=i.height+t.height+e.height,n=a.globals.isMultiLineX?1.2:a.globals.LINE_HEIGHT_RATIO,o=a.globals.rotateXLabels?22:10,l=a.globals.rotateXLabels&&"bottom"===a.config.legend.position?10:0;this.xAxisHeight=r*n+s*o+l,this.xAxisWidth=t.width,this.xAxisHeight-e.height>a.config.xaxis.labels.maxHeight&&(this.xAxisHeight=a.config.xaxis.labels.maxHeight),a.config.xaxis.labels.minHeight&&this.xAxisHeight<a.config.xaxis.labels.minHeight&&(this.xAxisHeight=a.config.xaxis.labels.minHeight),a.config.xaxis.floating&&(this.xAxisHeight=0);var c=0,h=0;a.config.yaxis.forEach((function(t){c+=t.labels.minWidth,h+=t.labels.maxWidth})),this.yAxisWidth<c&&(this.yAxisWidth=c),this.yAxisWidth>h&&(this.yAxisWidth=h)}}]),t}(),ht=function(){function t(e){o(this,t),this.w=e.w,this.lgCtx=e}return c(t,[{key:"getLegendStyles",value:function(){var t=document.createElement("style");t.setAttribute("type","text/css");var e=document.createTextNode("\t\n \t\n .apexcharts-legend {\t\n display: flex;\t\n overflow: auto;\t\n padding: 0 10px;\t\n }\t\n .apexcharts-legend.apx-legend-position-bottom, .apexcharts-legend.apx-legend-position-top {\t\n flex-wrap: wrap\t\n }\t\n .apexcharts-legend.apx-legend-position-right, .apexcharts-legend.apx-legend-position-left {\t\n flex-direction: column;\t\n bottom: 0;\t\n }\t\n .apexcharts-legend.apx-legend-position-bottom.apexcharts-align-left, .apexcharts-legend.apx-legend-position-top.apexcharts-align-left, .apexcharts-legend.apx-legend-position-right, .apexcharts-legend.apx-legend-position-left {\t\n justify-content: flex-start;\t\n }\t\n .apexcharts-legend.apx-legend-position-bottom.apexcharts-align-center, .apexcharts-legend.apx-legend-position-top.apexcharts-align-center {\t\n justify-content: center; \t\n }\t\n .apexcharts-legend.apx-legend-position-bottom.apexcharts-align-right, .apexcharts-legend.apx-legend-position-top.apexcharts-align-right {\t\n justify-content: flex-end;\t\n }\t\n .apexcharts-legend-series {\t\n cursor: pointer;\t\n line-height: normal;\t\n }\t\n .apexcharts-legend.apx-legend-position-bottom .apexcharts-legend-series, .apexcharts-legend.apx-legend-position-top .apexcharts-legend-series{\t\n display: flex;\t\n align-items: center;\t\n }\t\n .apexcharts-legend-text {\t\n position: relative;\t\n font-size: 14px;\t\n }\t\n .apexcharts-legend-text *, .apexcharts-legend-marker * {\t\n pointer-events: none;\t\n }\t\n .apexcharts-legend-marker {\t\n position: relative;\t\n display: inline-block;\t\n cursor: pointer;\t\n margin-right: 3px;\t\n border-style: solid;\n }\t\n \t\n .apexcharts-legend.apexcharts-align-right .apexcharts-legend-series, .apexcharts-legend.apexcharts-align-left .apexcharts-legend-series{\t\n display: inline-block;\t\n }\t\n .apexcharts-legend-series.apexcharts-no-click {\t\n cursor: auto;\t\n }\t\n .apexcharts-legend .apexcharts-hidden-zero-series, .apexcharts-legend .apexcharts-hidden-null-series {\t\n display: none !important;\t\n }\t\n .apexcharts-inactive-legend {\t\n opacity: 0.45;\t\n }");return t.appendChild(e),t}},{key:"getLegendBBox",value:function(){var t=this.w.globals.dom.baseEl.querySelector(".apexcharts-legend").getBoundingClientRect(),e=t.width;return{clwh:t.height,clww:e}}},{key:"appendToForeignObject",value:function(){var t=this.w.globals;t.dom.elLegendForeign=document.createElementNS(t.SVGNS,"foreignObject");var e=t.dom.elLegendForeign;e.setAttribute("x",0),e.setAttribute("y",0),e.setAttribute("width",t.svgWidth),e.setAttribute("height",t.svgHeight),t.dom.elLegendWrap.setAttribute("xmlns","http://www.w3.org/1999/xhtml"),e.appendChild(t.dom.elLegendWrap),e.appendChild(this.getLegendStyles()),t.dom.Paper.node.insertBefore(e,t.dom.elGraphical.node)}},{key:"toggleDataSeries",value:function(t,e){var i=this,a=this.w;if(a.globals.axisCharts||"radialBar"===a.config.chart.type){a.globals.resized=!0;var s=null,r=null;a.globals.risingSeries=[],a.globals.axisCharts?(s=a.globals.dom.baseEl.querySelector(".apexcharts-series[data\\:realIndex='".concat(t,"']")),r=parseInt(s.getAttribute("data:realIndex"),10)):(s=a.globals.dom.baseEl.querySelector(".apexcharts-series[rel='".concat(t+1,"']")),r=parseInt(s.getAttribute("rel"),10)-1),e?[{cs:a.globals.collapsedSeries,csi:a.globals.collapsedSeriesIndices},{cs:a.globals.ancillaryCollapsedSeries,csi:a.globals.ancillaryCollapsedSeriesIndices}].forEach((function(t){i.riseCollapsedSeries(t.cs,t.csi,r)})):this.hideSeries({seriesEl:s,realIndex:r})}else{var n=a.globals.dom.Paper.select(" .apexcharts-series[rel='".concat(t+1,"'] path")),o=a.config.chart.type;if("pie"===o||"polarArea"===o||"donut"===o){var l=a.config.plotOptions.pie.donut.labels;new k(this.lgCtx.ctx).pathMouseDown(n.members[0],null),this.lgCtx.ctx.pie.printDataLabelsInner(n.members[0].node,l)}n.fire("click")}}},{key:"hideSeries",value:function(t){var e=t.seriesEl,i=t.realIndex,a=this.w,s=v.clone(a.config.series);if(a.globals.axisCharts){var r=!1;if(a.config.yaxis[i]&&a.config.yaxis[i].show&&a.config.yaxis[i].showAlways&&(r=!0,a.globals.ancillaryCollapsedSeriesIndices.indexOf(i)<0&&(a.globals.ancillaryCollapsedSeries.push({index:i,data:s[i].data.slice(),type:e.parentNode.className.baseVal.split("-")[1]}),a.globals.ancillaryCollapsedSeriesIndices.push(i))),!r){a.globals.collapsedSeries.push({index:i,data:s[i].data.slice(),type:e.parentNode.className.baseVal.split("-")[1]}),a.globals.collapsedSeriesIndices.push(i);var n=a.globals.risingSeries.indexOf(i);a.globals.risingSeries.splice(n,1)}}else a.globals.collapsedSeries.push({index:i,data:s[i]}),a.globals.collapsedSeriesIndices.push(i);for(var o=e.childNodes,l=0;l<o.length;l++)o[l].classList.contains("apexcharts-series-markers-wrap")&&(o[l].classList.contains("apexcharts-hide")?o[l].classList.remove("apexcharts-hide"):o[l].classList.add("apexcharts-hide"));a.globals.allSeriesCollapsed=a.globals.collapsedSeries.length===a.config.series.length,s=this._getSeriesBasedOnCollapsedState(s),this.lgCtx.ctx.updateHelpers._updateSeries(s,a.config.chart.animations.dynamicAnimation.enabled)}},{key:"riseCollapsedSeries",value:function(t,e,i){var a=this.w,s=v.clone(a.config.series);if(t.length>0){for(var r=0;r<t.length;r++)t[r].index===i&&(a.globals.axisCharts?(s[i].data=t[r].data.slice(),t.splice(r,1),e.splice(r,1),a.globals.risingSeries.push(i)):(s[i]=t[r].data,t.splice(r,1),e.splice(r,1),a.globals.risingSeries.push(i)));s=this._getSeriesBasedOnCollapsedState(s),this.lgCtx.ctx.updateHelpers._updateSeries(s,a.config.chart.animations.dynamicAnimation.enabled)}}},{key:"_getSeriesBasedOnCollapsedState",value:function(t){var e=this.w;return e.globals.axisCharts?t.forEach((function(i,a){e.globals.collapsedSeriesIndices.indexOf(a)>-1&&(t[a].data=[])})):t.forEach((function(i,a){e.globals.collapsedSeriesIndices.indexOf(a)>-1&&(t[a]=0)})),t}}]),t}(),dt=function(){function t(e,i){o(this,t),this.ctx=e,this.w=e.w,this.onLegendClick=this.onLegendClick.bind(this),this.onLegendHovered=this.onLegendHovered.bind(this),this.isBarsDistributed="bar"===this.w.config.chart.type&&this.w.config.plotOptions.bar.distributed&&1===this.w.config.series.length,this.legendHelpers=new ht(this)}return c(t,[{key:"init",value:function(){var t=this.w,e=t.globals,i=t.config;if((i.legend.showForSingleSeries&&1===e.series.length||this.isBarsDistributed||e.series.length>1||!e.axisCharts)&&i.legend.show){for(;e.dom.elLegendWrap.firstChild;)e.dom.elLegendWrap.removeChild(e.dom.elLegendWrap.firstChild);this.drawLegends(),v.isIE11()?document.getElementsByTagName("head")[0].appendChild(this.legendHelpers.getLegendStyles()):this.legendHelpers.appendToForeignObject(),"bottom"===i.legend.position||"top"===i.legend.position?this.legendAlignHorizontal():"right"!==i.legend.position&&"left"!==i.legend.position||this.legendAlignVertical()}}},{key:"drawLegends",value:function(){var t=this,e=this.w,i=e.config.legend.fontFamily,a=e.globals.seriesNames,s=e.globals.colors.slice();if("heatmap"===e.config.chart.type){var r=e.config.plotOptions.heatmap.colorScale.ranges;a=r.map((function(t){return t.name?t.name:t.from+" - "+t.to})),s=r.map((function(t){return t.color}))}else this.isBarsDistributed&&(a=e.globals.labels.slice());e.config.legend.customLegendItems.length&&(a=e.config.legend.customLegendItems);for(var n=e.globals.legendFormatter,o=e.config.legend.inverseOrder,l=o?a.length-1:0;o?l>=0:l<=a.length-1;o?l--:l++){var c=n(a[l],{seriesIndex:l,w:e}),h=!1,d=!1;if(e.globals.collapsedSeries.length>0)for(var u=0;u<e.globals.collapsedSeries.length;u++)e.globals.collapsedSeries[u].index===l&&(h=!0);if(e.globals.ancillaryCollapsedSeriesIndices.length>0)for(var p=0;p<e.globals.ancillaryCollapsedSeriesIndices.length;p++)e.globals.ancillaryCollapsedSeriesIndices[p]===l&&(d=!0);var f=document.createElement("span");f.classList.add("apexcharts-legend-marker");var g=e.config.legend.markers.offsetX,x=e.config.legend.markers.offsetY,m=e.config.legend.markers.height,b=e.config.legend.markers.width,y=e.config.legend.markers.strokeWidth,w=e.config.legend.markers.strokeColor,S=e.config.legend.markers.radius,C=f.style;C.background=s[l],C.color=s[l],C.setProperty("background",s[l],"important"),e.config.legend.markers.fillColors&&e.config.legend.markers.fillColors[l]&&(C.background=e.config.legend.markers.fillColors[l]),void 0!==e.globals.seriesColors[l]&&(C.background=e.globals.seriesColors[l],C.color=e.globals.seriesColors[l]),C.height=Array.isArray(m)?parseFloat(m[l])+"px":parseFloat(m)+"px",C.width=Array.isArray(b)?parseFloat(b[l])+"px":parseFloat(b)+"px",C.left=(Array.isArray(g)?parseFloat(g[l]):parseFloat(g))+"px",C.top=(Array.isArray(x)?parseFloat(x[l]):parseFloat(x))+"px",C.borderWidth=Array.isArray(y)?y[l]:y,C.borderColor=Array.isArray(w)?w[l]:w,C.borderRadius=Array.isArray(S)?parseFloat(S[l])+"px":parseFloat(S)+"px",e.config.legend.markers.customHTML&&(Array.isArray(e.config.legend.markers.customHTML)?e.config.legend.markers.customHTML[l]&&(f.innerHTML=e.config.legend.markers.customHTML[l]()):f.innerHTML=e.config.legend.markers.customHTML()),k.setAttrs(f,{rel:l+1,"data:collapsed":h||d}),(h||d)&&f.classList.add("apexcharts-inactive-legend");var P=document.createElement("div"),L=document.createElement("span");L.classList.add("apexcharts-legend-text"),L.innerHTML=Array.isArray(c)?c.join(" "):c;var D=e.config.legend.labels.useSeriesColors?e.globals.colors[l]:e.config.legend.labels.colors;D||(D=e.config.chart.foreColor),L.style.color=D,L.style.fontSize=parseFloat(e.config.legend.fontSize)+"px",L.style.fontWeight=e.config.legend.fontWeight,L.style.fontFamily=i||e.config.chart.fontFamily,k.setAttrs(L,{rel:l+1,i:l,"data:default-text":encodeURIComponent(c),"data:collapsed":h||d}),P.appendChild(f),P.appendChild(L);var T=new A(this.ctx);e.config.legend.showForZeroSeries||0===T.getSeriesTotalByIndex(l)&&T.seriesHaveSameValues(l)&&!T.isSeriesNull(l)&&-1===e.globals.collapsedSeriesIndices.indexOf(l)&&-1===e.globals.ancillaryCollapsedSeriesIndices.indexOf(l)&&P.classList.add("apexcharts-hidden-zero-series"),e.config.legend.showForNullSeries||T.isSeriesNull(l)&&-1===e.globals.collapsedSeriesIndices.indexOf(l)&&-1===e.globals.ancillaryCollapsedSeriesIndices.indexOf(l)&&P.classList.add("apexcharts-hidden-null-series"),e.globals.dom.elLegendWrap.appendChild(P),e.globals.dom.elLegendWrap.classList.add("apexcharts-align-".concat(e.config.legend.horizontalAlign)),e.globals.dom.elLegendWrap.classList.add("apx-legend-position-"+e.config.legend.position),P.classList.add("apexcharts-legend-series"),P.style.margin="".concat(e.config.legend.itemMargin.vertical,"px ").concat(e.config.legend.itemMargin.horizontal,"px"),e.globals.dom.elLegendWrap.style.width=e.config.legend.width?e.config.legend.width+"px":"",e.globals.dom.elLegendWrap.style.height=e.config.legend.height?e.config.legend.height+"px":"",k.setAttrs(P,{rel:l+1,seriesName:v.escapeString(a[l]),"data:collapsed":h||d}),(h||d)&&P.classList.add("apexcharts-inactive-legend"),e.config.legend.onItemClick.toggleDataSeries||P.classList.add("apexcharts-no-click")}e.globals.dom.elWrap.addEventListener("click",t.onLegendClick,!0),e.config.legend.onItemHover.highlightDataSeries&&0===e.config.legend.customLegendItems.length&&(e.globals.dom.elWrap.addEventListener("mousemove",t.onLegendHovered,!0),e.globals.dom.elWrap.addEventListener("mouseout",t.onLegendHovered,!0))}},{key:"setLegendWrapXY",value:function(t,e){var i=this.w,a=i.globals.dom.baseEl.querySelector(".apexcharts-legend"),s=a.getBoundingClientRect(),r=0,n=0;if("bottom"===i.config.legend.position)n+=i.globals.svgHeight-s.height/2;else if("top"===i.config.legend.position){var o=new ct(this.ctx),l=o.dimHelpers.getTitleSubtitleCoords("title").height,c=o.dimHelpers.getTitleSubtitleCoords("subtitle").height;n=n+(l>0?l-10:0)+(c>0?c-10:0)}a.style.position="absolute",r=r+t+i.config.legend.offsetX,n=n+e+i.config.legend.offsetY,a.style.left=r+"px",a.style.top=n+"px","bottom"===i.config.legend.position?(a.style.top="auto",a.style.bottom=5-i.config.legend.offsetY+"px"):"right"===i.config.legend.position&&(a.style.left="auto",a.style.right=25+i.config.legend.offsetX+"px"),["width","height"].forEach((function(t){a.style[t]&&(a.style[t]=parseInt(i.config.legend[t],10)+"px")}))}},{key:"legendAlignHorizontal",value:function(){var t=this.w;t.globals.dom.baseEl.querySelector(".apexcharts-legend").style.right=0;var e=this.legendHelpers.getLegendBBox(),i=new ct(this.ctx),a=i.dimHelpers.getTitleSubtitleCoords("title"),s=i.dimHelpers.getTitleSubtitleCoords("subtitle"),r=0;"bottom"===t.config.legend.position?r=-e.clwh/1.8:"top"===t.config.legend.position&&(r=a.height+s.height+t.config.title.margin+t.config.subtitle.margin-10),this.setLegendWrapXY(20,r)}},{key:"legendAlignVertical",value:function(){var t=this.w,e=this.legendHelpers.getLegendBBox(),i=0;"left"===t.config.legend.position&&(i=20),"right"===t.config.legend.position&&(i=t.globals.svgWidth-e.clww-10),this.setLegendWrapXY(i,20)}},{key:"onLegendHovered",value:function(t){var e=this.w,i=t.target.classList.contains("apexcharts-legend-text")||t.target.classList.contains("apexcharts-legend-marker");if("heatmap"===e.config.chart.type||this.isBarsDistributed){if(i){var a=parseInt(t.target.getAttribute("rel"),10)-1;this.ctx.events.fireEvent("legendHover",[this.ctx,a,this.w]),new B(this.ctx).highlightRangeInSeries(t,t.target)}}else!t.target.classList.contains("apexcharts-inactive-legend")&&i&&new B(this.ctx).toggleSeriesOnHover(t,t.target)}},{key:"onLegendClick",value:function(t){var e=this.w;if(!e.config.legend.customLegendItems.length&&(t.target.classList.contains("apexcharts-legend-text")||t.target.classList.contains("apexcharts-legend-marker"))){var i=parseInt(t.target.getAttribute("rel"),10)-1,a="true"===t.target.getAttribute("data:collapsed"),s=this.w.config.chart.events.legendClick;"function"==typeof s&&s(this.ctx,i,this.w),this.ctx.events.fireEvent("legendClick",[this.ctx,i,this.w]);var r=this.w.config.legend.markers.onClick;"function"==typeof r&&t.target.classList.contains("apexcharts-legend-marker")&&(r(this.ctx,i,this.w),this.ctx.events.fireEvent("legendMarkerClick",[this.ctx,i,this.w])),"treemap"!==e.config.chart.type&&"heatmap"!==e.config.chart.type&&!this.isBarsDistributed&&e.config.legend.onItemClick.toggleDataSeries&&this.legendHelpers.toggleDataSeries(i,a)}}}]),t}(),ut=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w;var i=this.w;this.ev=this.w.config.chart.events,this.selectedClass="apexcharts-selected",this.localeValues=this.w.globals.locale.toolbar,this.minX=i.globals.minX,this.maxX=i.globals.maxX}return c(t,[{key:"createToolbar",value:function(){var t=this,e=this.w,i=function(){return document.createElement("div")},a=i();if(a.setAttribute("class","apexcharts-toolbar"),a.style.top=e.config.chart.toolbar.offsetY+"px",a.style.right=3-e.config.chart.toolbar.offsetX+"px",e.globals.dom.elWrap.appendChild(a),this.elZoom=i(),this.elZoomIn=i(),this.elZoomOut=i(),this.elPan=i(),this.elSelection=i(),this.elZoomReset=i(),this.elMenuIcon=i(),this.elMenu=i(),this.elCustomIcons=[],this.t=e.config.chart.toolbar.tools,Array.isArray(this.t.customIcons))for(var s=0;s<this.t.customIcons.length;s++)this.elCustomIcons.push(i());var r=[],n=function(i,a,s){var n=i.toLowerCase();t.t[n]&&e.config.chart.zoom.enabled&&r.push({el:a,icon:"string"==typeof t.t[n]?t.t[n]:s,title:t.localeValues[i],class:"apexcharts-".concat(n,"-icon")})};n("zoomIn",this.elZoomIn,'<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">\n <path d="M0 0h24v24H0z" fill="none"/>\n <path d="M13 7h-2v4H7v2h4v4h2v-4h4v-2h-4V7zm-1-5C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"/>\n</svg>\n'),n("zoomOut",this.elZoomOut,'<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">\n <path d="M0 0h24v24H0z" fill="none"/>\n <path d="M7 11v2h10v-2H7zm5-9C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"/>\n</svg>\n');var o=function(i){t.t[i]&&e.config.chart[i].enabled&&r.push({el:"zoom"===i?t.elZoom:t.elSelection,icon:"string"==typeof t.t[i]?t.t[i]:"zoom"===i?'<svg xmlns="http://www.w3.org/2000/svg" fill="#000000" height="24" viewBox="0 0 24 24" width="24">\n <path d="M15.5 14h-.79l-.28-.27C15.41 12.59 16 11.11 16 9.5 16 5.91 13.09 3 9.5 3S3 5.91 3 9.5 5.91 16 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14z"/>\n <path d="M0 0h24v24H0V0z" fill="none"/>\n <path d="M12 10h-2v2H9v-2H7V9h2V7h1v2h2v1z"/>\n</svg>':'<svg fill="#6E8192" height="24" viewBox="0 0 24 24" width="24" xmlns="http://www.w3.org/2000/svg">\n <path d="M0 0h24v24H0z" fill="none"/>\n <path d="M3 5h2V3c-1.1 0-2 .9-2 2zm0 8h2v-2H3v2zm4 8h2v-2H7v2zM3 9h2V7H3v2zm10-6h-2v2h2V3zm6 0v2h2c0-1.1-.9-2-2-2zM5 21v-2H3c0 1.1.9 2 2 2zm-2-4h2v-2H3v2zM9 3H7v2h2V3zm2 18h2v-2h-2v2zm8-8h2v-2h-2v2zm0 8c1.1 0 2-.9 2-2h-2v2zm0-12h2V7h-2v2zm0 8h2v-2h-2v2zm-4 4h2v-2h-2v2zm0-16h2V3h-2v2z"/>\n</svg>',title:t.localeValues["zoom"===i?"selectionZoom":"selection"],class:e.globals.isTouchDevice?"apexcharts-element-hidden":"apexcharts-".concat(i,"-icon")})};o("zoom"),o("selection"),this.t.pan&&e.config.chart.zoom.enabled&&r.push({el:this.elPan,icon:"string"==typeof this.t.pan?this.t.pan:'<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" fill="#000000" height="24" viewBox="0 0 24 24" width="24">\n <defs>\n <path d="M0 0h24v24H0z" id="a"/>\n </defs>\n <clipPath id="b">\n <use overflow="visible" xlink:href="#a"/>\n </clipPath>\n <path clip-path="url(#b)" d="M23 5.5V20c0 2.2-1.8 4-4 4h-7.3c-1.08 0-2.1-.43-2.85-1.19L1 14.83s1.26-1.23 1.3-1.25c.22-.19.49-.29.79-.29.22 0 .42.06.6.16.04.01 4.31 2.46 4.31 2.46V4c0-.83.67-1.5 1.5-1.5S11 3.17 11 4v7h1V1.5c0-.83.67-1.5 1.5-1.5S15 .67 15 1.5V11h1V2.5c0-.83.67-1.5 1.5-1.5s1.5.67 1.5 1.5V11h1V5.5c0-.83.67-1.5 1.5-1.5s1.5.67 1.5 1.5z"/>\n</svg>',title:this.localeValues.pan,class:e.globals.isTouchDevice?"apexcharts-element-hidden":"apexcharts-pan-icon"}),n("reset",this.elZoomReset,'<svg fill="#000000" height="24" viewBox="0 0 24 24" width="24" xmlns="http://www.w3.org/2000/svg">\n <path d="M10 20v-6h4v6h5v-8h3L12 3 2 12h3v8z"/>\n <path d="M0 0h24v24H0z" fill="none"/>\n</svg>'),this.t.download&&r.push({el:this.elMenuIcon,icon:"string"==typeof this.t.download?this.t.download:'<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><path fill="none" d="M0 0h24v24H0V0z"/><path d="M3 18h18v-2H3v2zm0-5h18v-2H3v2zm0-7v2h18V6H3z"/></svg>',title:this.localeValues.menu,class:"apexcharts-menu-icon"});for(var l=0;l<this.elCustomIcons.length;l++)r.push({el:this.elCustomIcons[l],icon:this.t.customIcons[l].icon,title:this.t.customIcons[l].title,index:this.t.customIcons[l].index,class:"apexcharts-toolbar-custom-icon "+this.t.customIcons[l].class});r.forEach((function(t,e){t.index&&v.moveIndexInArray(r,e,t.index)}));for(var c=0;c<r.length;c++)k.setAttrs(r[c].el,{class:r[c].class,title:r[c].title}),r[c].el.innerHTML=r[c].icon,a.appendChild(r[c].el);this._createHamburgerMenu(a),e.globals.zoomEnabled?this.elZoom.classList.add(this.selectedClass):e.globals.panEnabled?this.elPan.classList.add(this.selectedClass):e.globals.selectionEnabled&&this.elSelection.classList.add(this.selectedClass),this.addToolbarEventListeners()}},{key:"_createHamburgerMenu",value:function(t){this.elMenuItems=[],t.appendChild(this.elMenu),k.setAttrs(this.elMenu,{class:"apexcharts-menu"});var e=[{name:"exportSVG",title:this.localeValues.exportToSVG},{name:"exportPNG",title:this.localeValues.exportToPNG},{name:"exportCSV",title:this.localeValues.exportToCSV}];this.w.globals.allSeriesHasEqualX||e.splice(2,1);for(var i=0;i<e.length;i++)this.elMenuItems.push(document.createElement("div")),this.elMenuItems[i].innerHTML=e[i].title,k.setAttrs(this.elMenuItems[i],{class:"apexcharts-menu-item ".concat(e[i].name),title:e[i].title}),this.elMenu.appendChild(this.elMenuItems[i])}},{key:"addToolbarEventListeners",value:function(){var t=this;this.elZoomReset.addEventListener("click",this.handleZoomReset.bind(this)),this.elSelection.addEventListener("click",this.toggleZoomSelection.bind(this,"selection")),this.elZoom.addEventListener("click",this.toggleZoomSelection.bind(this,"zoom")),this.elZoomIn.addEventListener("click",this.handleZoomIn.bind(this)),this.elZoomOut.addEventListener("click",this.handleZoomOut.bind(this)),this.elPan.addEventListener("click",this.togglePanning.bind(this)),this.elMenuIcon.addEventListener("click",this.toggleMenu.bind(this)),this.elMenuItems.forEach((function(e){e.classList.contains("exportSVG")?e.addEventListener("click",t.handleDownload.bind(t,"svg")):e.classList.contains("exportPNG")?e.addEventListener("click",t.handleDownload.bind(t,"png")):e.classList.contains("exportCSV")&&e.addEventListener("click",t.handleDownload.bind(t,"csv"))}));for(var e=0;e<this.t.customIcons.length;e++)this.elCustomIcons[e].addEventListener("click",this.t.customIcons[e].click.bind(this,this.ctx,this.ctx.w))}},{key:"toggleZoomSelection",value:function(t){this.ctx.getSyncedCharts().forEach((function(e){e.ctx.toolbar.toggleOtherControls();var i="selection"===t?e.ctx.toolbar.elSelection:e.ctx.toolbar.elZoom,a="selection"===t?"selectionEnabled":"zoomEnabled";e.w.globals[a]=!e.w.globals[a],i.classList.contains(e.ctx.toolbar.selectedClass)?i.classList.remove(e.ctx.toolbar.selectedClass):i.classList.add(e.ctx.toolbar.selectedClass)}))}},{key:"getToolbarIconsReference",value:function(){var t=this.w;this.elZoom||(this.elZoom=t.globals.dom.baseEl.querySelector(".apexcharts-zoom-icon")),this.elPan||(this.elPan=t.globals.dom.baseEl.querySelector(".apexcharts-pan-icon")),this.elSelection||(this.elSelection=t.globals.dom.baseEl.querySelector(".apexcharts-selection-icon"))}},{key:"enableZoomPanFromToolbar",value:function(t){this.toggleOtherControls(),"pan"===t?this.w.globals.panEnabled=!0:this.w.globals.zoomEnabled=!0;var e="pan"===t?this.elPan:this.elZoom,i="pan"===t?this.elZoom:this.elPan;e&&e.classList.add(this.selectedClass),i&&i.classList.remove(this.selectedClass)}},{key:"togglePanning",value:function(){this.ctx.getSyncedCharts().forEach((function(t){t.ctx.toolbar.toggleOtherControls(),t.w.globals.panEnabled=!t.w.globals.panEnabled,t.ctx.toolbar.elPan.classList.contains(t.ctx.toolbar.selectedClass)?t.ctx.toolbar.elPan.classList.remove(t.ctx.toolbar.selectedClass):t.ctx.toolbar.elPan.classList.add(t.ctx.toolbar.selectedClass)}))}},{key:"toggleOtherControls",value:function(){var t=this,e=this.w;e.globals.panEnabled=!1,e.globals.zoomEnabled=!1,e.globals.selectionEnabled=!1,this.getToolbarIconsReference(),[this.elPan,this.elSelection,this.elZoom].forEach((function(e){e&&e.classList.remove(t.selectedClass)}))}},{key:"handleZoomIn",value:function(){var t=this.w;t.globals.isRangeBar&&(this.minX=t.globals.minY,this.maxX=t.globals.maxY);var e=(this.minX+this.maxX)/2,i=(this.minX+e)/2,a=(this.maxX+e)/2,s=this._getNewMinXMaxX(i,a);t.globals.disableZoomIn||this.zoomUpdateOptions(s.minX,s.maxX)}},{key:"handleZoomOut",value:function(){var t=this.w;if(t.globals.isRangeBar&&(this.minX=t.globals.minY,this.maxX=t.globals.maxY),!("datetime"===t.config.xaxis.type&&new Date(this.minX).getUTCFullYear()<1e3)){var e=(this.minX+this.maxX)/2,i=this.minX-(e-this.minX),a=this.maxX-(e-this.maxX),s=this._getNewMinXMaxX(i,a);t.globals.disableZoomOut||this.zoomUpdateOptions(s.minX,s.maxX)}}},{key:"_getNewMinXMaxX",value:function(t,e){var i=this.w.config.xaxis.convertedCatToNumeric;return{minX:i?Math.floor(t):t,maxX:i?Math.floor(e):e}}},{key:"zoomUpdateOptions",value:function(t,e){var i=this.w;if(void 0!==t||void 0!==e){if(!(i.config.xaxis.convertedCatToNumeric&&(t<1&&(t=1,e=i.globals.dataPoints),e-t<2))){var a={min:t,max:e},s=this.getBeforeZoomRange(a);s&&(a=s.xaxis);var r={xaxis:a},n=v.clone(i.globals.initialConfig.yaxis);i.config.chart.zoom.autoScaleYaxis&&(n=new Z(this.ctx).autoScaleY(this.ctx,n,{xaxis:a})),i.config.chart.group||(r.yaxis=n),this.w.globals.zoomed=!0,this.ctx.updateHelpers._updateOptions(r,!1,this.w.config.chart.animations.dynamicAnimation.enabled),this.zoomCallback(a,n)}}else this.handleZoomReset()}},{key:"zoomCallback",value:function(t,e){"function"==typeof this.ev.zoomed&&this.ev.zoomed(this.ctx,{xaxis:t,yaxis:e})}},{key:"getBeforeZoomRange",value:function(t,e){var i=null;return"function"==typeof this.ev.beforeZoom&&(i=this.ev.beforeZoom(this,{xaxis:t,yaxis:e})),i}},{key:"toggleMenu",value:function(){var t=this;window.setTimeout((function(){t.elMenu.classList.contains("apexcharts-menu-open")?t.elMenu.classList.remove("apexcharts-menu-open"):t.elMenu.classList.add("apexcharts-menu-open")}),0)}},{key:"handleDownload",value:function(t){var e=this.w,i=new G(this.ctx);switch(t){case"svg":i.exportToSVG(this.ctx);break;case"png":i.exportToPng(this.ctx);break;case"csv":i.exportToCSV({series:e.config.series,columnDelimiter:e.config.chart.toolbar.export.csv.columnDelimiter})}}},{key:"handleZoomReset",value:function(t){this.ctx.getSyncedCharts().forEach((function(t){var e=t.w;if(e.globals.lastXAxis.min=void 0,e.globals.lastXAxis.max=void 0,t.updateHelpers.revertDefaultAxisMinMax(),"function"==typeof e.config.chart.events.beforeResetZoom){var i=e.config.chart.events.beforeResetZoom(t,e);i&&t.updateHelpers.revertDefaultAxisMinMax(i)}"function"==typeof e.config.chart.events.zoomed&&t.ctx.toolbar.zoomCallback({min:e.config.xaxis.min,max:e.config.xaxis.max}),e.globals.zoomed=!1;var a=t.ctx.series.emptyCollapsedSeries(v.clone(e.globals.initialSeries));t.updateHelpers._updateSeries(a,e.config.chart.animations.dynamicAnimation.enabled)}))}},{key:"destroy",value:function(){this.elZoom=null,this.elZoomIn=null,this.elZoomOut=null,this.elPan=null,this.elSelection=null,this.elZoomReset=null,this.elMenuIcon=null}}]),t}(),pt=function(t){d(i,ut);var e=g(i);function i(t){var a;return o(this,i),(a=e.call(this,t)).ctx=t,a.w=t.w,a.dragged=!1,a.graphics=new k(a.ctx),a.eventList=["mousedown","mouseleave","mousemove","touchstart","touchmove","mouseup","touchend"],a.clientX=0,a.clientY=0,a.startX=0,a.endX=0,a.dragX=0,a.startY=0,a.endY=0,a.dragY=0,a.moveDirection="none",a}return c(i,[{key:"init",value:function(t){var e=this,i=t.xyRatios,a=this.w,s=this;this.xyRatios=i,this.zoomRect=this.graphics.drawRect(0,0,0,0),this.selectionRect=this.graphics.drawRect(0,0,0,0),this.gridRect=a.globals.dom.baseEl.querySelector(".apexcharts-grid"),this.zoomRect.node.classList.add("apexcharts-zoom-rect"),this.selectionRect.node.classList.add("apexcharts-selection-rect"),a.globals.dom.elGraphical.add(this.zoomRect),a.globals.dom.elGraphical.add(this.selectionRect),"x"===a.config.chart.selection.type?this.slDraggableRect=this.selectionRect.draggable({minX:0,minY:0,maxX:a.globals.gridWidth,maxY:a.globals.gridHeight}).on("dragmove",this.selectionDragging.bind(this,"dragging")):"y"===a.config.chart.selection.type?this.slDraggableRect=this.selectionRect.draggable({minX:0,maxX:a.globals.gridWidth}).on("dragmove",this.selectionDragging.bind(this,"dragging")):this.slDraggableRect=this.selectionRect.draggable().on("dragmove",this.selectionDragging.bind(this,"dragging")),this.preselectedSelection(),this.hoverArea=a.globals.dom.baseEl.querySelector("".concat(a.globals.chartClass," .apexcharts-svg")),this.hoverArea.classList.add("apexcharts-zoomable"),this.eventList.forEach((function(t){e.hoverArea.addEventListener(t,s.svgMouseEvents.bind(s,i),{capture:!1,passive:!0})}))}},{key:"destroy",value:function(){this.slDraggableRect&&(this.slDraggableRect.draggable(!1),this.slDraggableRect.off(),this.selectionRect.off()),this.selectionRect=null,this.zoomRect=null,this.gridRect=null}},{key:"svgMouseEvents",value:function(t,e){var i=this.w,a=this,s=this.ctx.toolbar,r=i.globals.zoomEnabled?i.config.chart.zoom.type:i.config.chart.selection.type,n=i.config.chart.toolbar.autoSelected;if(e.shiftKey?(this.shiftWasPressed=!0,s.enableZoomPanFromToolbar("pan"===n?"zoom":"pan")):this.shiftWasPressed&&(s.enableZoomPanFromToolbar(n),this.shiftWasPressed=!1),e.target){var o,l=e.target.classList;if(e.target.parentNode&&null!==e.target.parentNode&&(o=e.target.parentNode.classList),!(l.contains("apexcharts-selection-rect")||l.contains("apexcharts-legend-marker")||l.contains("apexcharts-legend-text")||o&&o.contains("apexcharts-toolbar"))){if(a.clientX="touchmove"===e.type||"touchstart"===e.type?e.touches[0].clientX:"touchend"===e.type?e.changedTouches[0].clientX:e.clientX,a.clientY="touchmove"===e.type||"touchstart"===e.type?e.touches[0].clientY:"touchend"===e.type?e.changedTouches[0].clientY:e.clientY,"mousedown"===e.type&&1===e.which){var c=a.gridRect.getBoundingClientRect();a.startX=a.clientX-c.left,a.startY=a.clientY-c.top,a.dragged=!1,a.w.globals.mousedown=!0}if(("mousemove"===e.type&&1===e.which||"touchmove"===e.type)&&(a.dragged=!0,i.globals.panEnabled?(i.globals.selection=null,a.w.globals.mousedown&&a.panDragging({context:a,zoomtype:r,xyRatios:t})):(a.w.globals.mousedown&&i.globals.zoomEnabled||a.w.globals.mousedown&&i.globals.selectionEnabled)&&(a.selection=a.selectionDrawing({context:a,zoomtype:r}))),"mouseup"===e.type||"touchend"===e.type||"mouseleave"===e.type){var h=a.gridRect.getBoundingClientRect();a.w.globals.mousedown&&(a.endX=a.clientX-h.left,a.endY=a.clientY-h.top,a.dragX=Math.abs(a.endX-a.startX),a.dragY=Math.abs(a.endY-a.startY),(i.globals.zoomEnabled||i.globals.selectionEnabled)&&a.selectionDrawn({context:a,zoomtype:r}),i.globals.panEnabled&&i.config.xaxis.convertedCatToNumeric&&a.delayedPanScrolled()),i.globals.zoomEnabled&&a.hideSelectionRect(this.selectionRect),a.dragged=!1,a.w.globals.mousedown=!1}this.makeSelectionRectDraggable()}}}},{key:"makeSelectionRectDraggable",value:function(){var t=this.w;if(this.selectionRect){var e=this.selectionRect.node.getBoundingClientRect();e.width>0&&e.height>0&&this.slDraggableRect.selectize({points:"l, r",pointSize:8,pointType:"rect"}).resize({constraint:{minX:0,minY:0,maxX:t.globals.gridWidth,maxY:t.globals.gridHeight}}).on("resizing",this.selectionDragging.bind(this,"resizing"))}}},{key:"preselectedSelection",value:function(){var t=this.w,e=this.xyRatios;if(!t.globals.zoomEnabled)if(void 0!==t.globals.selection&&null!==t.globals.selection)this.drawSelectionRect(t.globals.selection);else if(void 0!==t.config.chart.selection.xaxis.min&&void 0!==t.config.chart.selection.xaxis.max){var i=(t.config.chart.selection.xaxis.min-t.globals.minX)/e.xRatio,a={x:i,y:0,width:t.globals.gridWidth-(t.globals.maxX-t.config.chart.selection.xaxis.max)/e.xRatio-i,height:t.globals.gridHeight,translateX:0,translateY:0,selectionEnabled:!0};this.drawSelectionRect(a),this.makeSelectionRectDraggable(),"function"==typeof t.config.chart.events.selection&&t.config.chart.events.selection(this.ctx,{xaxis:{min:t.config.chart.selection.xaxis.min,max:t.config.chart.selection.xaxis.max},yaxis:{}})}}},{key:"drawSelectionRect",value:function(t){var e=t.x,i=t.y,a=t.width,s=t.height,r=t.translateX,n=void 0===r?0:r,o=t.translateY,l=void 0===o?0:o,c=this.w,h=this.zoomRect,d=this.selectionRect;if(this.dragged||null!==c.globals.selection){var u={transform:"translate("+n+", "+l+")"};c.globals.zoomEnabled&&this.dragged&&(a<0&&(a=1),h.attr({x:e,y:i,width:a,height:s,fill:c.config.chart.zoom.zoomedArea.fill.color,"fill-opacity":c.config.chart.zoom.zoomedArea.fill.opacity,stroke:c.config.chart.zoom.zoomedArea.stroke.color,"stroke-width":c.config.chart.zoom.zoomedArea.stroke.width,"stroke-opacity":c.config.chart.zoom.zoomedArea.stroke.opacity}),k.setAttrs(h.node,u)),c.globals.selectionEnabled&&(d.attr({x:e,y:i,width:a>0?a:0,height:s>0?s:0,fill:c.config.chart.selection.fill.color,"fill-opacity":c.config.chart.selection.fill.opacity,stroke:c.config.chart.selection.stroke.color,"stroke-width":c.config.chart.selection.stroke.width,"stroke-dasharray":c.config.chart.selection.stroke.dashArray,"stroke-opacity":c.config.chart.selection.stroke.opacity}),k.setAttrs(d.node,u))}}},{key:"hideSelectionRect",value:function(t){t&&t.attr({x:0,y:0,width:0,height:0})}},{key:"selectionDrawing",value:function(t){var e,i=t.context,a=t.zoomtype,s=this.w,r=i,n=this.gridRect.getBoundingClientRect(),o=r.startX-1,l=r.startY,c=!1,h=!1,d=r.clientX-n.left-o,u=r.clientY-n.top-l;return Math.abs(d+o)>s.globals.gridWidth?d=s.globals.gridWidth-o:r.clientX-n.left<0&&(d=o),o>r.clientX-n.left&&(c=!0,d=Math.abs(d)),l>r.clientY-n.top&&(h=!0,u=Math.abs(u)),e="x"===a?{x:c?o-d:o,y:0,width:d,height:s.globals.gridHeight}:"y"===a?{x:0,y:h?l-u:l,width:s.globals.gridWidth,height:u}:{x:c?o-d:o,y:h?l-u:l,width:d,height:u},r.drawSelectionRect(e),r.selectionDragging("resizing"),e}},{key:"selectionDragging",value:function(t,e){var i=this,a=this.w,s=this.xyRatios,r=this.selectionRect,n=0;"resizing"===t&&(n=30);var o=function(t){return parseFloat(r.node.getAttribute(t))},l={x:o("x"),y:o("y"),width:o("width"),height:o("height")};a.globals.selection=l,"function"==typeof a.config.chart.events.selection&&a.globals.selectionEnabled&&(clearTimeout(this.w.globals.selectionResizeTimer),this.w.globals.selectionResizeTimer=window.setTimeout((function(){var t=i.gridRect.getBoundingClientRect(),e=r.node.getBoundingClientRect(),n={xaxis:{min:a.globals.xAxisScale.niceMin+(e.left-t.left)*s.xRatio,max:a.globals.xAxisScale.niceMin+(e.right-t.left)*s.xRatio},yaxis:{min:a.globals.yAxisScale[0].niceMin+(t.bottom-e.bottom)*s.yRatio[0],max:a.globals.yAxisScale[0].niceMax-(e.top-t.top)*s.yRatio[0]}};a.config.chart.events.selection(i.ctx,n),a.config.chart.brush.enabled&&void 0!==a.config.chart.events.brushScrolled&&a.config.chart.events.brushScrolled(i.ctx,n)}),n))}},{key:"selectionDrawn",value:function(t){var e=t.context,i=t.zoomtype,a=this.w,s=e,r=this.xyRatios,n=this.ctx.toolbar;if(s.startX>s.endX){var o=s.startX;s.startX=s.endX,s.endX=o}if(s.startY>s.endY){var l=s.startY;s.startY=s.endY,s.endY=l}var c=void 0,h=void 0;a.globals.isRangeBar?(c=a.globals.yAxisScale[0].niceMin+s.startX*r.invertedYRatio,h=a.globals.yAxisScale[0].niceMin+s.endX*r.invertedYRatio):(c=a.globals.xAxisScale.niceMin+s.startX*r.xRatio,h=a.globals.xAxisScale.niceMin+s.endX*r.xRatio);var d=[],u=[];if(a.config.yaxis.forEach((function(t,e){d.push(a.globals.yAxisScale[e].niceMax-r.yRatio[e]*s.startY),u.push(a.globals.yAxisScale[e].niceMax-r.yRatio[e]*s.endY)})),s.dragged&&(s.dragX>10||s.dragY>10)&&c!==h)if(a.globals.zoomEnabled){var p=v.clone(a.globals.initialConfig.yaxis),f=v.clone(a.globals.initialConfig.xaxis);if(a.globals.zoomed=!0,a.config.xaxis.convertedCatToNumeric&&(c=Math.floor(c),h=Math.floor(h),c<1&&(c=1,h=a.globals.dataPoints),h-c<2&&(h=c+1)),"xy"!==i&&"x"!==i||(f={min:c,max:h}),"xy"!==i&&"y"!==i||p.forEach((function(t,e){p[e].min=u[e],p[e].max=d[e]})),a.config.chart.zoom.autoScaleYaxis){var g=new Z(s.ctx);p=g.autoScaleY(s.ctx,p,{xaxis:f})}if(n){var x=n.getBeforeZoomRange(f,p);x&&(f=x.xaxis?x.xaxis:f,p=x.yaxis?x.yaxis:p)}var m={xaxis:f};a.config.chart.group||(m.yaxis=p),s.ctx.updateHelpers._updateOptions(m,!1,s.w.config.chart.animations.dynamicAnimation.enabled),"function"==typeof a.config.chart.events.zoomed&&n.zoomCallback(f,p)}else if(a.globals.selectionEnabled){var b,y=null;b={min:c,max:h},"xy"!==i&&"y"!==i||(y=v.clone(a.config.yaxis)).forEach((function(t,e){y[e].min=u[e],y[e].max=d[e]})),a.globals.selection=s.selection,"function"==typeof a.config.chart.events.selection&&a.config.chart.events.selection(s.ctx,{xaxis:b,yaxis:y})}}},{key:"panDragging",value:function(t){var e=t.context,i=this.w,a=e;if(void 0!==i.globals.lastClientPosition.x){var s=i.globals.lastClientPosition.x-a.clientX,r=i.globals.lastClientPosition.y-a.clientY;Math.abs(s)>Math.abs(r)&&s>0?this.moveDirection="left":Math.abs(s)>Math.abs(r)&&s<0?this.moveDirection="right":Math.abs(r)>Math.abs(s)&&r>0?this.moveDirection="up":Math.abs(r)>Math.abs(s)&&r<0&&(this.moveDirection="down")}i.globals.lastClientPosition={x:a.clientX,y:a.clientY};var n=i.globals.isRangeBar?i.globals.minY:i.globals.minX,o=i.globals.isRangeBar?i.globals.maxY:i.globals.maxX;i.config.xaxis.convertedCatToNumeric||a.panScrolled(n,o)}},{key:"delayedPanScrolled",value:function(){var t=this.w,e=t.globals.minX,i=t.globals.maxX,a=(t.globals.maxX-t.globals.minX)/2;"left"===this.moveDirection?(e=t.globals.minX+a,i=t.globals.maxX+a):"right"===this.moveDirection&&(e=t.globals.minX-a,i=t.globals.maxX-a),e=Math.floor(e),i=Math.floor(i),this.updateScrolledChart({xaxis:{min:e,max:i}},e,i)}},{key:"panScrolled",value:function(t,e){var i=this.w,a=this.xyRatios,s=v.clone(i.globals.initialConfig.yaxis),r=a.xRatio,n=i.globals.minX,o=i.globals.maxX;i.globals.isRangeBar&&(r=a.invertedYRatio,n=i.globals.minY,o=i.globals.maxY),"left"===this.moveDirection?(t=n+i.globals.gridWidth/15*r,e=o+i.globals.gridWidth/15*r):"right"===this.moveDirection&&(t=n-i.globals.gridWidth/15*r,e=o-i.globals.gridWidth/15*r),i.globals.isRangeBar||(t<i.globals.initialMinX||e>i.globals.initialMaxX)&&(t=n,e=o);var l={min:t,max:e};i.config.chart.zoom.autoScaleYaxis&&(s=new Z(this.ctx).autoScaleY(this.ctx,s,{xaxis:l}));var c={xaxis:{min:t,max:e}};i.config.chart.group||(c.yaxis=s),this.updateScrolledChart(c,t,e)}},{key:"updateScrolledChart",value:function(t,e,i){var a=this.w;this.ctx.updateHelpers._updateOptions(t,!1,!1),"function"==typeof a.config.chart.events.scrolled&&a.config.chart.events.scrolled(this.ctx,{xaxis:{min:e,max:i}})}}]),i}(),ft=function(){function t(e){o(this,t),this.w=e.w,this.ttCtx=e,this.ctx=e.ctx}return c(t,[{key:"getNearestValues",value:function(t){var e=t.hoverArea,i=t.elGrid,a=t.clientX,s=t.clientY,r=this.w,n=i.getBoundingClientRect(),o=n.width,l=n.height,c=o/(r.globals.dataPoints-1),h=l/r.globals.dataPoints,d=this.hasBars();!r.globals.comboCharts&&!d||r.config.xaxis.convertedCatToNumeric||(c=o/r.globals.dataPoints);var u=a-n.left-r.globals.barPadForNumericAxis,p=s-n.top;u<0||p<0||u>o||p>l?(e.classList.remove("hovering-zoom"),e.classList.remove("hovering-pan")):r.globals.zoomEnabled?(e.classList.remove("hovering-pan"),e.classList.add("hovering-zoom")):r.globals.panEnabled&&(e.classList.remove("hovering-zoom"),e.classList.add("hovering-pan"));var f=Math.round(u/c),g=Math.floor(p/h);d&&!r.config.xaxis.convertedCatToNumeric&&(f=Math.ceil(u/c),f-=1);var x=null,m=null,b=[],y=[];if(r.globals.seriesXvalues.forEach((function(t){b.push([t[0]+1e-6].concat(t))})),r.globals.seriesYvalues.forEach((function(t){y.push([t[0]+1e-6].concat(t))})),b=b.map((function(t){return t.filter((function(t){return v.isNumber(t)}))})),y=y.map((function(t){return t.filter((function(t){return v.isNumber(t)}))})),r.globals.isXNumeric){var w=this.ttCtx.getElGrid().getBoundingClientRect(),k=u*(w.width/o),A=p*(w.height/l);x=(m=this.closestInMultiArray(k,A,b,y)).index,f=m.j,null!==x&&(b=r.globals.seriesXvalues[x],f=(m=this.closestInArray(k,b)).index)}return r.globals.capturedSeriesIndex=null===x?-1:x,(!f||f<1)&&(f=0),r.globals.isBarHorizontal?r.globals.capturedDataPointIndex=g:r.globals.capturedDataPointIndex=f,{capturedSeries:x,j:r.globals.isBarHorizontal?g:f,hoverX:u,hoverY:p}}},{key:"closestInMultiArray",value:function(t,e,i,a){var s=this.w,r=0,n=null,o=-1;s.globals.series.length>1?r=this.getFirstActiveXArray(i):n=0;var l=i[r][0],c=Math.abs(t-l);if(i.forEach((function(e){e.forEach((function(e,i){var a=Math.abs(t-e);a<c&&(c=a,o=i)}))})),-1!==o){var h=a[r][o],d=Math.abs(e-h);n=r,a.forEach((function(t,i){var a=Math.abs(e-t[o]);a<d&&(d=a,n=i)}))}return{index:n,j:o}}},{key:"getFirstActiveXArray",value:function(t){for(var e=this.w,i=0,a=t.map((function(t,e){return t.length>0?e:-1})),s=0;s<a.length;s++)if(-1!==a[s]&&-1===e.globals.collapsedSeriesIndices.indexOf(s)&&-1===e.globals.ancillaryCollapsedSeriesIndices.indexOf(s)){i=a[s];break}return i}},{key:"closestInArray",value:function(t,e){for(var i=e[0],a=null,s=Math.abs(t-i),r=0;r<e.length;r++){var n=Math.abs(t-e[r]);n<s&&(s=n,a=r)}return{index:a}}},{key:"isXoverlap",value:function(t){var e=[],i=this.w.globals.seriesX.filter((function(t){return void 0!==t[0]}));if(i.length>0)for(var a=0;a<i.length-1;a++)void 0!==i[a][t]&&void 0!==i[a+1][t]&&i[a][t]!==i[a+1][t]&&e.push("unEqual");return 0===e.length}},{key:"isInitialSeriesSameLen",value:function(){for(var t=!0,e=this.w.globals.initialSeries,i=0;i<e.length-1;i++)if(e[i].data.length!==e[i+1].data.length){t=!1;break}return t}},{key:"getBarsHeight",value:function(t){return x(t).reduce((function(t,e){return t+e.getBBox().height}),0)}},{key:"getElMarkers",value:function(){return this.w.globals.dom.baseEl.querySelectorAll(" .apexcharts-series-markers")}},{key:"getAllMarkers",value:function(){var t=this.w.globals.dom.baseEl.querySelectorAll(".apexcharts-series-markers-wrap");(t=x(t)).sort((function(t,e){var i=Number(t.getAttribute("data:realIndex")),a=Number(e.getAttribute("data:realIndex"));return a<i?1:a>i?-1:0}));var e=[];return t.forEach((function(t){e.push(t.querySelector(".apexcharts-marker"))})),e}},{key:"hasMarkers",value:function(){return this.getElMarkers().length>0}},{key:"getElBars",value:function(){return this.w.globals.dom.baseEl.querySelectorAll(".apexcharts-bar-series, .apexcharts-candlestick-series, .apexcharts-boxPlot-series, .apexcharts-rangebar-series")}},{key:"hasBars",value:function(){return this.getElBars().length>0}},{key:"getHoverMarkerSize",value:function(t){var e=this.w,i=e.config.markers.hover.size;return void 0===i&&(i=e.globals.markers.size[t]+e.config.markers.hover.sizeOffset),i}},{key:"toggleAllTooltipSeriesGroups",value:function(t){var e=this.w,i=this.ttCtx;0===i.allTooltipSeriesGroups.length&&(i.allTooltipSeriesGroups=e.globals.dom.baseEl.querySelectorAll(".apexcharts-tooltip-series-group"));for(var a=i.allTooltipSeriesGroups,s=0;s<a.length;s++)"enable"===t?(a[s].classList.add("apexcharts-active"),a[s].style.display=e.config.tooltip.items.display):(a[s].classList.remove("apexcharts-active"),a[s].style.display="none")}}]),t}(),gt=function(){function t(e){o(this,t),this.w=e.w,this.ctx=e.ctx,this.ttCtx=e,this.tooltipUtil=new ft(e)}return c(t,[{key:"drawSeriesTexts",value:function(t){var e=t.shared,i=void 0===e||e,a=t.ttItems,s=t.i,r=void 0===s?0:s,n=t.j,o=void 0===n?null:n,l=t.y1,c=t.y2,h=t.e,d=this.w;void 0!==d.config.tooltip.custom?this.handleCustomTooltip({i:r,j:o,y1:l,y2:c,w:d}):this.toggleActiveInactiveSeries(i);var u=this.getValuesToPrint({i:r,j:o});this.printLabels({i:r,j:o,values:u,ttItems:a,shared:i,e:h});var p=this.ttCtx.getElTooltip();this.ttCtx.tooltipRect.ttWidth=p.getBoundingClientRect().width,this.ttCtx.tooltipRect.ttHeight=p.getBoundingClientRect().height}},{key:"printLabels",value:function(t){var e,i=this,a=t.i,s=t.j,n=t.values,o=t.ttItems,l=t.shared,c=t.e,h=this.w,d=[],u=function(t){return h.globals.seriesGoals[t]&&h.globals.seriesGoals[t][s]&&Array.isArray(h.globals.seriesGoals[t][s])},p=n.xVal,f=n.zVal,g=n.xAxisTTVal,x="",m=h.globals.colors[a];null!==s&&h.config.plotOptions.bar.distributed&&(m=h.globals.colors[s]);for(var b=function(t,n){var b=i.getFormatters(a);x=i.getSeriesName({fn:b.yLbTitleFormatter,index:a,seriesIndex:a,j:s}),"treemap"===h.config.chart.type&&(x=b.yLbTitleFormatter(String(h.config.series[a].data[s].x),{series:h.globals.series,seriesIndex:a,dataPointIndex:s,w:h}));var v=h.config.tooltip.inverseOrder?n:t;if(h.globals.axisCharts){var y=function(t){return b.yLbFormatter(h.globals.series[t][s],{series:h.globals.series,seriesIndex:t,dataPointIndex:s,w:h})};if(l)b=i.getFormatters(v),x=i.getSeriesName({fn:b.yLbTitleFormatter,index:v,seriesIndex:a,j:s}),m=h.globals.colors[v],e=y(v),u(v)&&(d=h.globals.seriesGoals[v][s].map((function(t){return{attrs:t,val:b.yLbFormatter(t.value,{seriesIndex:v,dataPointIndex:s,w:h})}})));else{var w,k=null==c||null===(w=c.target)||void 0===w?void 0:w.getAttribute("fill");k&&(m=-1!==k.indexOf("url")?document.querySelector(k.substr(4).slice(0,-1)).childNodes[0].getAttribute("stroke"):k),e=y(a),u(a)&&Array.isArray(h.globals.seriesGoals[a][s])&&(d=h.globals.seriesGoals[a][s].map((function(t){return{attrs:t,val:b.yLbFormatter(t.value,{seriesIndex:a,dataPointIndex:s,w:h})}})))}}null===s&&(e=b.yLbFormatter(h.globals.series[a],r(r({},h),{},{seriesIndex:a,dataPointIndex:a}))),i.DOMHandling({i:a,t:v,j:s,ttItems:o,values:{val:e,goalVals:d,xVal:p,xAxisTTVal:g,zVal:f},seriesName:x,shared:l,pColor:m})},v=0,y=h.globals.series.length-1;v<h.globals.series.length;v++,y--)b(v,y)}},{key:"getFormatters",value:function(t){var e,i=this.w,a=i.globals.yLabelFormatters[t];return void 0!==i.globals.ttVal?Array.isArray(i.globals.ttVal)?(a=i.globals.ttVal[t]&&i.globals.ttVal[t].formatter,e=i.globals.ttVal[t]&&i.globals.ttVal[t].title&&i.globals.ttVal[t].title.formatter):(a=i.globals.ttVal.formatter,"function"==typeof i.globals.ttVal.title.formatter&&(e=i.globals.ttVal.title.formatter)):e=i.config.tooltip.y.title.formatter,"function"!=typeof a&&(a=i.globals.yLabelFormatters[0]?i.globals.yLabelFormatters[0]:function(t){return t}),"function"!=typeof e&&(e=function(t){return t}),{yLbFormatter:a,yLbTitleFormatter:e}}},{key:"getSeriesName",value:function(t){var e=t.fn,i=t.index,a=t.seriesIndex,s=t.j,r=this.w;return e(String(r.globals.seriesNames[i]),{series:r.globals.series,seriesIndex:a,dataPointIndex:s,w:r})}},{key:"DOMHandling",value:function(t){t.i;var e=t.t,i=t.j,a=t.ttItems,s=t.values,r=t.seriesName,n=t.shared,o=t.pColor,l=this.w,c=this.ttCtx,h=s.val,d=s.goalVals,u=s.xVal,p=s.xAxisTTVal,f=s.zVal,g=null;g=a[e].children,l.config.tooltip.fillSeriesColor&&(a[e].style.backgroundColor=o,g[0].style.display="none"),c.showTooltipTitle&&(null===c.tooltipTitle&&(c.tooltipTitle=l.globals.dom.baseEl.querySelector(".apexcharts-tooltip-title")),c.tooltipTitle.innerHTML=u),c.isXAxisTooltipEnabled&&(c.xaxisTooltipText.innerHTML=""!==p?p:u);var x=a[e].querySelector(".apexcharts-tooltip-text-y-label");x&&(x.innerHTML=r||"");var m=a[e].querySelector(".apexcharts-tooltip-text-y-value");m&&(m.innerHTML=void 0!==h?h:""),g[0]&&g[0].classList.contains("apexcharts-tooltip-marker")&&(l.config.tooltip.marker.fillColors&&Array.isArray(l.config.tooltip.marker.fillColors)&&(o=l.config.tooltip.marker.fillColors[e]),g[0].style.backgroundColor=o),l.config.tooltip.marker.show||(g[0].style.display="none");var b=a[e].querySelector(".apexcharts-tooltip-text-goals-label"),v=a[e].querySelector(".apexcharts-tooltip-text-goals-value");if(d.length&&l.globals.seriesGoals[e]){var y=function(){var t="<div >",e="<div>";d.forEach((function(i,a){t+=' <div style="display: flex"><span class="apexcharts-tooltip-marker" style="background-color: '.concat(i.attrs.strokeColor,'; height: 3px; border-radius: 0; top: 5px;"></span> ').concat(i.attrs.name,"</div>"),e+="<div>".concat(i.val,"</div>")})),b.innerHTML=t+"</div>",v.innerHTML=e+"</div>"};n?l.globals.seriesGoals[e][i]&&Array.isArray(l.globals.seriesGoals[e][i])?y():(b.innerHTML="",v.innerHTML=""):y()}else b.innerHTML="",v.innerHTML="";null!==f&&(a[e].querySelector(".apexcharts-tooltip-text-z-label").innerHTML=l.config.tooltip.z.title,a[e].querySelector(".apexcharts-tooltip-text-z-value").innerHTML=void 0!==f?f:""),n&&g[0]&&(null==h||l.globals.ancillaryCollapsedSeriesIndices.indexOf(e)>-1||l.globals.collapsedSeriesIndices.indexOf(e)>-1?g[0].parentNode.style.display="none":g[0].parentNode.style.display=l.config.tooltip.items.display)}},{key:"toggleActiveInactiveSeries",value:function(t){var e=this.w;if(t)this.tooltipUtil.toggleAllTooltipSeriesGroups("enable");else{this.tooltipUtil.toggleAllTooltipSeriesGroups("disable");var i=e.globals.dom.baseEl.querySelector(".apexcharts-tooltip-series-group");i&&(i.classList.add("apexcharts-active"),i.style.display=e.config.tooltip.items.display)}}},{key:"getValuesToPrint",value:function(t){var e=t.i,i=t.j,a=this.w,s=this.ctx.series.filteredSeriesX(),r="",n="",o=null,l=null,c={series:a.globals.series,seriesIndex:e,dataPointIndex:i,w:a},h=a.globals.ttZFormatter;null===i?l=a.globals.series[e]:a.globals.isXNumeric&&"treemap"!==a.config.chart.type?(r=s[e][i],0===s[e].length&&(r=s[this.tooltipUtil.getFirstActiveXArray(s)][i])):r=void 0!==a.globals.labels[i]?a.globals.labels[i]:"";var d=r;return r=a.globals.isXNumeric&&"datetime"===a.config.xaxis.type?new j(this.ctx).xLabelFormat(a.globals.ttKeyFormatter,d,d,{i:void 0,dateFormatter:new E(this.ctx).formatDate,w:this.w}):a.globals.isBarHorizontal?a.globals.yLabelFormatters[0](d,c):a.globals.xLabelFormatter(d,c),void 0!==a.config.tooltip.x.formatter&&(r=a.globals.ttKeyFormatter(d,c)),a.globals.seriesZ.length>0&&a.globals.seriesZ[e].length>0&&(o=h(a.globals.seriesZ[e][i],a)),n="function"==typeof a.config.xaxis.tooltip.formatter?a.globals.xaxisTooltipFormatter(d,c):r,{val:Array.isArray(l)?l.join(" "):l,xVal:Array.isArray(r)?r.join(" "):r,xAxisTTVal:Array.isArray(n)?n.join(" "):n,zVal:o}}},{key:"handleCustomTooltip",value:function(t){var e=t.i,i=t.j,a=t.y1,s=t.y2,r=t.w,n=this.ttCtx.getElTooltip(),o=r.config.tooltip.custom;Array.isArray(o)&&o[e]&&(o=o[e]),n.innerHTML=o({ctx:this.ctx,series:r.globals.series,seriesIndex:e,dataPointIndex:i,y1:a,y2:s,w:r})}}]),t}(),xt=function(){function t(e){o(this,t),this.ttCtx=e,this.ctx=e.ctx,this.w=e.w}return c(t,[{key:"moveXCrosshairs",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,i=this.ttCtx,a=this.w,s=i.getElXCrosshairs(),r=t-i.xcrosshairsWidth/2,n=a.globals.labels.slice().length;if(null!==e&&(r=a.globals.gridWidth/n*e),null===s||a.globals.isBarHorizontal||(s.setAttribute("x",r),s.setAttribute("x1",r),s.setAttribute("x2",r),s.setAttribute("y2",a.globals.gridHeight),s.classList.add("apexcharts-active")),r<0&&(r=0),r>a.globals.gridWidth&&(r=a.globals.gridWidth),i.isXAxisTooltipEnabled){var o=r;"tickWidth"!==a.config.xaxis.crosshairs.width&&"barWidth"!==a.config.xaxis.crosshairs.width||(o=r+i.xcrosshairsWidth/2),this.moveXAxisTooltip(o)}}},{key:"moveYCrosshairs",value:function(t){var e=this.ttCtx;null!==e.ycrosshairs&&k.setAttrs(e.ycrosshairs,{y1:t,y2:t}),null!==e.ycrosshairsHidden&&k.setAttrs(e.ycrosshairsHidden,{y1:t,y2:t})}},{key:"moveXAxisTooltip",value:function(t){var e=this.w,i=this.ttCtx;if(null!==i.xaxisTooltip&&0!==i.xcrosshairsWidth){i.xaxisTooltip.classList.add("apexcharts-active");var a,s=i.xaxisOffY+e.config.xaxis.tooltip.offsetY+e.globals.translateY+1+e.config.xaxis.offsetY;t-=i.xaxisTooltip.getBoundingClientRect().width/2,isNaN(t)||(t+=e.globals.translateX,a=new k(this.ctx).getTextRects(i.xaxisTooltipText.innerHTML),i.xaxisTooltipText.style.minWidth=a.width+"px",i.xaxisTooltip.style.left=t+"px",i.xaxisTooltip.style.top=s+"px")}}},{key:"moveYAxisTooltip",value:function(t){var e=this.w,i=this.ttCtx;null===i.yaxisTTEls&&(i.yaxisTTEls=e.globals.dom.baseEl.querySelectorAll(".apexcharts-yaxistooltip"));var a=parseInt(i.ycrosshairsHidden.getAttribute("y1"),10),s=e.globals.translateY+a,r=i.yaxisTTEls[t].getBoundingClientRect().height,n=e.globals.translateYAxisX[t]-2;e.config.yaxis[t].opposite&&(n-=26),s-=r/2,-1===e.globals.ignoreYAxisIndexes.indexOf(t)?(i.yaxisTTEls[t].classList.add("apexcharts-active"),i.yaxisTTEls[t].style.top=s+"px",i.yaxisTTEls[t].style.left=n+e.config.yaxis[t].tooltip.offsetX+"px"):i.yaxisTTEls[t].classList.remove("apexcharts-active")}},{key:"moveTooltip",value:function(t,e){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,a=this.w,s=this.ttCtx,r=s.getElTooltip(),n=s.tooltipRect,o=null!==i?parseFloat(i):1,l=parseFloat(t)+o+5,c=parseFloat(e)+o/2;if(l>a.globals.gridWidth/2&&(l=l-n.ttWidth-o-10),l>a.globals.gridWidth-n.ttWidth-10&&(l=a.globals.gridWidth-n.ttWidth),l<-20&&(l=-20),a.config.tooltip.followCursor){var h=s.getElGrid(),d=h.getBoundingClientRect();c=s.e.clientY+a.globals.translateY-d.top-n.ttHeight/2}else a.globals.isBarHorizontal||(n.ttHeight/2+c>a.globals.gridHeight&&(c=a.globals.gridHeight-n.ttHeight+a.globals.translateY),c<0&&(c=0));isNaN(l)||(l+=a.globals.translateX,r.style.left=l+"px",r.style.top=c+"px")}},{key:"moveMarkers",value:function(t,e){var i=this.w,a=this.ttCtx;if(i.globals.markers.size[t]>0)for(var s=i.globals.dom.baseEl.querySelectorAll(" .apexcharts-series[data\\:realIndex='".concat(t,"'] .apexcharts-marker")),r=0;r<s.length;r++)parseInt(s[r].getAttribute("rel"),10)===e&&(a.marker.resetPointsSize(),a.marker.enlargeCurrentPoint(e,s[r]));else a.marker.resetPointsSize(),this.moveDynamicPointOnHover(e,t)}},{key:"moveDynamicPointOnHover",value:function(t,e){var i,a,s=this.w,r=this.ttCtx,n=s.globals.pointsArray,o=r.tooltipUtil.getHoverMarkerSize(e),l=s.config.series[e].type;if(!l||"column"!==l&&"candlestick"!==l&&"boxPlot"!==l){i=n[e][t][0],a=n[e][t][1]?n[e][t][1]:0;var c=s.globals.dom.baseEl.querySelector(".apexcharts-series[data\\:realIndex='".concat(e,"'] .apexcharts-series-markers circle"));c&&a<s.globals.gridHeight&&a>0&&(c.setAttribute("r",o),c.setAttribute("cx",i),c.setAttribute("cy",a)),this.moveXCrosshairs(i),r.fixedTooltip||this.moveTooltip(i,a,o)}}},{key:"moveDynamicPointsOnHover",value:function(t){var e,i=this.ttCtx,a=i.w,s=0,r=0,n=a.globals.pointsArray;e=new B(this.ctx).getActiveConfigSeriesIndex("asc",["line","area","scatter","bubble"]);var o=i.tooltipUtil.getHoverMarkerSize(e);n[e]&&(s=n[e][t][0],r=n[e][t][1]);var l=i.tooltipUtil.getAllMarkers();if(null!==l)for(var c=0;c<a.globals.series.length;c++){var h=n[c];if(a.globals.comboCharts&&void 0===h&&l.splice(c,0,null),h&&h.length){var d=n[c][t][1],u=void 0;if(l[c].setAttribute("cx",s),"rangeArea"===a.config.chart.type&&!a.globals.comboCharts){var p=t+a.globals.series[c].length;u=n[c][p][1],d-=Math.abs(d-u)/2}null!==d&&!isNaN(d)&&d<a.globals.gridHeight+o&&d+o>0?(l[c]&&l[c].setAttribute("r",o),l[c]&&l[c].setAttribute("cy",d)):l[c]&&l[c].setAttribute("r",0)}}if(this.moveXCrosshairs(s),!i.fixedTooltip){var f=r||a.globals.gridHeight;this.moveTooltip(s,f,o)}}},{key:"moveStickyTooltipOverBars",value:function(t){var e=this.w,i=this.ttCtx,a=e.globals.columnSeries?e.globals.columnSeries.length:e.globals.series.length,s=a>=2&&a%2==0?Math.floor(a/2):Math.floor(a/2)+1;e.globals.isBarHorizontal&&(s=new B(this.ctx).getActiveConfigSeriesIndex("desc")+1);var r=e.globals.dom.baseEl.querySelector(".apexcharts-bar-series .apexcharts-series[rel='".concat(s,"'] path[j='").concat(t,"'], .apexcharts-candlestick-series .apexcharts-series[rel='").concat(s,"'] path[j='").concat(t,"'], .apexcharts-boxPlot-series .apexcharts-series[rel='").concat(s,"'] path[j='").concat(t,"'], .apexcharts-rangebar-series .apexcharts-series[rel='").concat(s,"'] path[j='").concat(t,"']")),n=r?parseFloat(r.getAttribute("cx")):0,o=r?parseFloat(r.getAttribute("cy")):0,l=r?parseFloat(r.getAttribute("barWidth")):0,c=r?parseFloat(r.getAttribute("barHeight")):0,h=i.getElGrid().getBoundingClientRect(),d=r.classList.contains("apexcharts-candlestick-area")||r.classList.contains("apexcharts-boxPlot-area");if(e.globals.isXNumeric?(r&&!d&&(n-=a%2!=0?l/2:0),r&&d&&e.globals.comboCharts&&(n-=l/2)):e.globals.isBarHorizontal||(n=i.xAxisTicksPositions[t-1]+i.dataPointsDividedWidth/2,isNaN(n)&&(n=i.xAxisTicksPositions[t]-i.dataPointsDividedWidth/2)),e.globals.isBarHorizontal?(o>e.globals.gridHeight/2&&(o-=i.tooltipRect.ttHeight),(o=o+e.config.grid.padding.top+c/3)+c>e.globals.gridHeight&&(o=e.globals.gridHeight-c)):e.config.tooltip.followCursor?o=i.e.clientY-h.top-i.tooltipRect.ttHeight/2:o+i.tooltipRect.ttHeight+15>e.globals.gridHeight&&(o=e.globals.gridHeight),o<-10&&(o=-10),e.globals.isBarHorizontal||this.moveXCrosshairs(n),!i.fixedTooltip){var u=o||e.globals.gridHeight;this.moveTooltip(n,u)}}}]),t}(),mt=function(){function t(e){o(this,t),this.w=e.w,this.ttCtx=e,this.ctx=e.ctx,this.tooltipPosition=new xt(e)}return c(t,[{key:"drawDynamicPoints",value:function(){var t=this.w,e=new k(this.ctx),i=new X(this.ctx),a=t.globals.dom.baseEl.querySelectorAll(".apexcharts-series");a=x(a),t.config.chart.stacked&&a.sort((function(t,e){return parseFloat(t.getAttribute("data:realIndex"))-parseFloat(e.getAttribute("data:realIndex"))}));for(var s=0;s<a.length;s++){var r=a[s].querySelector(".apexcharts-series-markers-wrap");if(null!==r){var n=void 0,o="apexcharts-marker w".concat((Math.random()+1).toString(36).substring(4));"line"!==t.config.chart.type&&"area"!==t.config.chart.type||t.globals.comboCharts||t.config.tooltip.intersect||(o+=" no-pointer-events");var l=i.getMarkerConfig({cssClass:o,seriesIndex:Number(r.getAttribute("data:realIndex"))});(n=e.drawMarker(0,0,l)).node.setAttribute("default-marker-size",0);var c=document.createElementNS(t.globals.SVGNS,"g");c.classList.add("apexcharts-series-markers"),c.appendChild(n.node),r.appendChild(c)}}}},{key:"enlargeCurrentPoint",value:function(t,e){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,s=this.w;"bubble"!==s.config.chart.type&&this.newPointSize(t,e);var r=e.getAttribute("cx"),n=e.getAttribute("cy");if(null!==i&&null!==a&&(r=i,n=a),this.tooltipPosition.moveXCrosshairs(r),!this.fixedTooltip){if("radar"===s.config.chart.type){var o=this.ttCtx.getElGrid(),l=o.getBoundingClientRect();r=this.ttCtx.e.clientX-l.left}this.tooltipPosition.moveTooltip(r,n,s.config.markers.hover.size)}}},{key:"enlargePoints",value:function(t){for(var e=this.w,i=this,a=this.ttCtx,s=t,r=e.globals.dom.baseEl.querySelectorAll(".apexcharts-series:not(.apexcharts-series-collapsed) .apexcharts-marker"),n=e.config.markers.hover.size,o=0;o<r.length;o++){var l=r[o].getAttribute("rel"),c=r[o].getAttribute("index");if(void 0===n&&(n=e.globals.markers.size[c]+e.config.markers.hover.sizeOffset),s===parseInt(l,10)){i.newPointSize(s,r[o]);var h=r[o].getAttribute("cx"),d=r[o].getAttribute("cy");i.tooltipPosition.moveXCrosshairs(h),a.fixedTooltip||i.tooltipPosition.moveTooltip(h,d,n)}else i.oldPointSize(r[o])}}},{key:"newPointSize",value:function(t,e){var i=this.w,a=i.config.markers.hover.size,s=0===t?e.parentNode.firstChild:e.parentNode.lastChild;if("0"!==s.getAttribute("default-marker-size")){var r=parseInt(s.getAttribute("index"),10);void 0===a&&(a=i.globals.markers.size[r]+i.config.markers.hover.sizeOffset),a<0&&(a=0),s.setAttribute("r",a)}}},{key:"oldPointSize",value:function(t){var e=parseFloat(t.getAttribute("default-marker-size"));t.setAttribute("r",e)}},{key:"resetPointsSize",value:function(){for(var t=this.w.globals.dom.baseEl.querySelectorAll(".apexcharts-series:not(.apexcharts-series-collapsed) .apexcharts-marker"),e=0;e<t.length;e++){var i=parseFloat(t[e].getAttribute("default-marker-size"));v.isNumber(i)&&i>=0?t[e].setAttribute("r",i):t[e].setAttribute("r",0)}}}]),t}(),bt=function(){function t(e){o(this,t),this.w=e.w,this.ttCtx=e}return c(t,[{key:"getAttr",value:function(t,e){return parseFloat(t.target.getAttribute(e))}},{key:"handleHeatTreeTooltip",value:function(t){var e=t.e,i=t.opt,a=t.x,s=t.y,r=t.type,n=this.ttCtx,o=this.w;if(e.target.classList.contains("apexcharts-".concat(r,"-rect"))){var l=this.getAttr(e,"i"),c=this.getAttr(e,"j"),h=this.getAttr(e,"cx"),d=this.getAttr(e,"cy"),u=this.getAttr(e,"width"),p=this.getAttr(e,"height");if(n.tooltipLabels.drawSeriesTexts({ttItems:i.ttItems,i:l,j:c,shared:!1,e:e}),o.globals.capturedSeriesIndex=l,o.globals.capturedDataPointIndex=c,a=h+n.tooltipRect.ttWidth/2+u,s=d+n.tooltipRect.ttHeight/2-p/2,n.tooltipPosition.moveXCrosshairs(h+u/2),a>o.globals.gridWidth/2&&(a=h-n.tooltipRect.ttWidth/2+u),n.w.config.tooltip.followCursor){var f=o.globals.dom.elWrap.getBoundingClientRect();a=o.globals.clientX-f.left-(a>o.globals.gridWidth/2?n.tooltipRect.ttWidth:0),s=o.globals.clientY-f.top-(s>o.globals.gridHeight/2?n.tooltipRect.ttHeight:0)}}return{x:a,y:s}}},{key:"handleMarkerTooltip",value:function(t){var e,i,a=t.e,s=t.opt,r=t.x,n=t.y,o=this.w,l=this.ttCtx;if(a.target.classList.contains("apexcharts-marker")){var c=parseInt(s.paths.getAttribute("cx"),10),h=parseInt(s.paths.getAttribute("cy"),10),d=parseFloat(s.paths.getAttribute("val"));if(i=parseInt(s.paths.getAttribute("rel"),10),e=parseInt(s.paths.parentNode.parentNode.parentNode.getAttribute("rel"),10)-1,l.intersect){var u=v.findAncestor(s.paths,"apexcharts-series");u&&(e=parseInt(u.getAttribute("data:realIndex"),10))}if(l.tooltipLabels.drawSeriesTexts({ttItems:s.ttItems,i:e,j:i,shared:!l.showOnIntersect&&o.config.tooltip.shared,e:a}),"mouseup"===a.type&&l.markerClick(a,e,i),o.globals.capturedSeriesIndex=e,o.globals.capturedDataPointIndex=i,r=c,n=h+o.globals.translateY-1.4*l.tooltipRect.ttHeight,l.w.config.tooltip.followCursor){var p=l.getElGrid().getBoundingClientRect();n=l.e.clientY+o.globals.translateY-p.top}d<0&&(n=h),l.marker.enlargeCurrentPoint(i,s.paths,r,n)}return{x:r,y:n}}},{key:"handleBarTooltip",value:function(t){var e,i,a=t.e,s=t.opt,r=this.w,n=this.ttCtx,o=n.getElTooltip(),l=0,c=0,h=0,d=this.getBarTooltipXY({e:a,opt:s});e=d.i;var u=d.barHeight,p=d.j;r.globals.capturedSeriesIndex=e,r.globals.capturedDataPointIndex=p,r.globals.isBarHorizontal&&n.tooltipUtil.hasBars()||!r.config.tooltip.shared?(c=d.x,h=d.y,i=Array.isArray(r.config.stroke.width)?r.config.stroke.width[e]:r.config.stroke.width,l=c):r.globals.comboCharts||r.config.tooltip.shared||(l/=2),isNaN(h)?h=r.globals.svgHeight-n.tooltipRect.ttHeight:h<0&&(h=0);var f=parseInt(s.paths.parentNode.getAttribute("data:realIndex"),10),g=r.globals.isMultipleYAxis?r.config.yaxis[f]&&r.config.yaxis[f].reversed:r.config.yaxis[0].reversed;if(c+n.tooltipRect.ttWidth>r.globals.gridWidth&&!g?c-=n.tooltipRect.ttWidth:c<0&&(c=0),n.w.config.tooltip.followCursor){var x=n.getElGrid().getBoundingClientRect();h=n.e.clientY-x.top}null===n.tooltip&&(n.tooltip=r.globals.dom.baseEl.querySelector(".apexcharts-tooltip")),r.config.tooltip.shared||(r.globals.comboBarCount>0?n.tooltipPosition.moveXCrosshairs(l+i/2):n.tooltipPosition.moveXCrosshairs(l)),!n.fixedTooltip&&(!r.config.tooltip.shared||r.globals.isBarHorizontal&&n.tooltipUtil.hasBars())&&(g&&(c-=n.tooltipRect.ttWidth)<0&&(c=0),!g||r.globals.isBarHorizontal&&n.tooltipUtil.hasBars()||(h=h+u-2*(r.globals.series[e][p]<0?u:0)),n.tooltipRect.ttHeight+h>r.globals.gridHeight?h=r.globals.gridHeight-n.tooltipRect.ttHeight+r.globals.translateY:(h=h+r.globals.translateY-n.tooltipRect.ttHeight/2)<0&&(h=0),o.style.left=c+r.globals.translateX+"px",o.style.top=h+"px")}},{key:"getBarTooltipXY",value:function(t){var e=t.e,i=t.opt,a=this.w,s=null,r=this.ttCtx,n=0,o=0,l=0,c=0,h=0,d=e.target.classList;if(d.contains("apexcharts-bar-area")||d.contains("apexcharts-candlestick-area")||d.contains("apexcharts-boxPlot-area")||d.contains("apexcharts-rangebar-area")){var u=e.target,p=u.getBoundingClientRect(),f=i.elGrid.getBoundingClientRect(),g=p.height;h=p.height;var x=p.width,m=parseInt(u.getAttribute("cx"),10),b=parseInt(u.getAttribute("cy"),10);c=parseFloat(u.getAttribute("barWidth"));var v="touchmove"===e.type?e.touches[0].clientX:e.clientX;s=parseInt(u.getAttribute("j"),10),n=parseInt(u.parentNode.getAttribute("rel"),10)-1;var y=u.getAttribute("data-range-y1"),w=u.getAttribute("data-range-y2");a.globals.comboCharts&&(n=parseInt(u.parentNode.getAttribute("data:realIndex"),10)),r.tooltipLabels.drawSeriesTexts({ttItems:i.ttItems,i:n,j:s,y1:y?parseInt(y,10):null,y2:w?parseInt(w,10):null,shared:!r.showOnIntersect&&a.config.tooltip.shared,e:e}),a.config.tooltip.followCursor?a.globals.isBarHorizontal?(o=v-f.left+15,l=b-r.dataPointsDividedHeight+g/2-r.tooltipRect.ttHeight/2):(o=a.globals.isXNumeric?m-x/2:m-r.dataPointsDividedWidth+x/2,l=e.clientY-f.top-r.tooltipRect.ttHeight/2-15):a.globals.isBarHorizontal?((o=m)<r.xyRatios.baseLineInvertedY&&(o=m-r.tooltipRect.ttWidth),l=b-r.dataPointsDividedHeight+g/2-r.tooltipRect.ttHeight/2):(o=a.globals.isXNumeric?m-x/2:m-r.dataPointsDividedWidth+x/2,l=b)}return{x:o,y:l,barHeight:h,barWidth:c,i:n,j:s}}}]),t}(),vt=function(){function t(e){o(this,t),this.w=e.w,this.ttCtx=e}return c(t,[{key:"drawXaxisTooltip",value:function(){var t=this.w,e=this.ttCtx,i="bottom"===t.config.xaxis.position;e.xaxisOffY=i?t.globals.gridHeight+1:-t.globals.xAxisHeight-t.config.xaxis.axisTicks.height+3;var a=i?"apexcharts-xaxistooltip apexcharts-xaxistooltip-bottom":"apexcharts-xaxistooltip apexcharts-xaxistooltip-top",s=t.globals.dom.elWrap;e.isXAxisTooltipEnabled&&null===t.globals.dom.baseEl.querySelector(".apexcharts-xaxistooltip")&&(e.xaxisTooltip=document.createElement("div"),e.xaxisTooltip.setAttribute("class",a+" apexcharts-theme-"+t.config.tooltip.theme),s.appendChild(e.xaxisTooltip),e.xaxisTooltipText=document.createElement("div"),e.xaxisTooltipText.classList.add("apexcharts-xaxistooltip-text"),e.xaxisTooltipText.style.fontFamily=t.config.xaxis.tooltip.style.fontFamily||t.config.chart.fontFamily,e.xaxisTooltipText.style.fontSize=t.config.xaxis.tooltip.style.fontSize,e.xaxisTooltip.appendChild(e.xaxisTooltipText))}},{key:"drawYaxisTooltip",value:function(){for(var t=this.w,e=this.ttCtx,i=function(i){var a=t.config.yaxis[i].opposite||t.config.yaxis[i].crosshairs.opposite;e.yaxisOffX=a?t.globals.gridWidth+1:1;var s="apexcharts-yaxistooltip apexcharts-yaxistooltip-".concat(i,a?" apexcharts-yaxistooltip-right":" apexcharts-yaxistooltip-left");t.globals.yAxisSameScaleIndices.map((function(e,a){e.map((function(e,a){a===i&&(s+=t.config.yaxis[a].show?" ":" apexcharts-yaxistooltip-hidden")}))}));var r=t.globals.dom.elWrap;null===t.globals.dom.baseEl.querySelector(".apexcharts-yaxistooltip apexcharts-yaxistooltip-".concat(i))&&(e.yaxisTooltip=document.createElement("div"),e.yaxisTooltip.setAttribute("class",s+" apexcharts-theme-"+t.config.tooltip.theme),r.appendChild(e.yaxisTooltip),0===i&&(e.yaxisTooltipText=[]),e.yaxisTooltipText[i]=document.createElement("div"),e.yaxisTooltipText[i].classList.add("apexcharts-yaxistooltip-text"),e.yaxisTooltip.appendChild(e.yaxisTooltipText[i]))},a=0;a<t.config.yaxis.length;a++)i(a)}},{key:"setXCrosshairWidth",value:function(){var t=this.w,e=this.ttCtx,i=e.getElXCrosshairs();if(e.xcrosshairsWidth=parseInt(t.config.xaxis.crosshairs.width,10),t.globals.comboCharts){var a=t.globals.dom.baseEl.querySelector(".apexcharts-bar-area");if(null!==a&&"barWidth"===t.config.xaxis.crosshairs.width){var s=parseFloat(a.getAttribute("barWidth"));e.xcrosshairsWidth=s}else if("tickWidth"===t.config.xaxis.crosshairs.width){var r=t.globals.labels.length;e.xcrosshairsWidth=t.globals.gridWidth/r}}else if("tickWidth"===t.config.xaxis.crosshairs.width){var n=t.globals.labels.length;e.xcrosshairsWidth=t.globals.gridWidth/n}else if("barWidth"===t.config.xaxis.crosshairs.width){var o=t.globals.dom.baseEl.querySelector(".apexcharts-bar-area");if(null!==o){var l=parseFloat(o.getAttribute("barWidth"));e.xcrosshairsWidth=l}else e.xcrosshairsWidth=1}t.globals.isBarHorizontal&&(e.xcrosshairsWidth=0),null!==i&&e.xcrosshairsWidth>0&&i.setAttribute("width",e.xcrosshairsWidth)}},{key:"handleYCrosshair",value:function(){var t=this.w,e=this.ttCtx;e.ycrosshairs=t.globals.dom.baseEl.querySelector(".apexcharts-ycrosshairs"),e.ycrosshairsHidden=t.globals.dom.baseEl.querySelector(".apexcharts-ycrosshairs-hidden")}},{key:"drawYaxisTooltipText",value:function(t,e,i){var a=this.ttCtx,s=this.w,r=s.globals.yLabelFormatters[t];if(a.yaxisTooltips[t]){var n=a.getElGrid().getBoundingClientRect(),o=(e-n.top)*i.yRatio[t],l=s.globals.maxYArr[t]-s.globals.minYArr[t],c=s.globals.minYArr[t]+(l-o);a.tooltipPosition.moveYCrosshairs(e-n.top),a.yaxisTooltipText[t].innerHTML=r(c),a.tooltipPosition.moveYAxisTooltip(t)}}}]),t}(),yt=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w;var i=this.w;this.tConfig=i.config.tooltip,this.tooltipUtil=new ft(this),this.tooltipLabels=new gt(this),this.tooltipPosition=new xt(this),this.marker=new mt(this),this.intersect=new bt(this),this.axesTooltip=new vt(this),this.showOnIntersect=this.tConfig.intersect,this.showTooltipTitle=this.tConfig.x.show,this.fixedTooltip=this.tConfig.fixed.enabled,this.xaxisTooltip=null,this.yaxisTTEls=null,this.isBarShared=!i.globals.isBarHorizontal&&this.tConfig.shared,this.lastHoverTime=Date.now()}return c(t,[{key:"getElTooltip",value:function(t){return t||(t=this),t.w.globals.dom.baseEl?t.w.globals.dom.baseEl.querySelector(".apexcharts-tooltip"):null}},{key:"getElXCrosshairs",value:function(){return this.w.globals.dom.baseEl.querySelector(".apexcharts-xcrosshairs")}},{key:"getElGrid",value:function(){return this.w.globals.dom.baseEl.querySelector(".apexcharts-grid")}},{key:"drawTooltip",value:function(t){var e=this.w;this.xyRatios=t,this.isXAxisTooltipEnabled=e.config.xaxis.tooltip.enabled&&e.globals.axisCharts,this.yaxisTooltips=e.config.yaxis.map((function(t,i){return!!(t.show&&t.tooltip.enabled&&e.globals.axisCharts)})),this.allTooltipSeriesGroups=[],e.globals.axisCharts||(this.showTooltipTitle=!1);var i=document.createElement("div");if(i.classList.add("apexcharts-tooltip"),e.config.tooltip.cssClass&&i.classList.add(e.config.tooltip.cssClass),i.classList.add("apexcharts-theme-".concat(this.tConfig.theme)),e.globals.dom.elWrap.appendChild(i),e.globals.axisCharts){this.axesTooltip.drawXaxisTooltip(),this.axesTooltip.drawYaxisTooltip(),this.axesTooltip.setXCrosshairWidth(),this.axesTooltip.handleYCrosshair();var a=new U(this.ctx);this.xAxisTicksPositions=a.getXAxisTicksPositions()}if(!e.globals.comboCharts&&!this.tConfig.intersect&&"rangeBar"!==e.config.chart.type||this.tConfig.shared||(this.showOnIntersect=!0),0!==e.config.markers.size&&0!==e.globals.markers.largestSize||this.marker.drawDynamicPoints(this),e.globals.collapsedSeries.length!==e.globals.series.length){this.dataPointsDividedHeight=e.globals.gridHeight/e.globals.dataPoints,this.dataPointsDividedWidth=e.globals.gridWidth/e.globals.dataPoints,this.showTooltipTitle&&(this.tooltipTitle=document.createElement("div"),this.tooltipTitle.classList.add("apexcharts-tooltip-title"),this.tooltipTitle.style.fontFamily=this.tConfig.style.fontFamily||e.config.chart.fontFamily,this.tooltipTitle.style.fontSize=this.tConfig.style.fontSize,i.appendChild(this.tooltipTitle));var s=e.globals.series.length;(e.globals.xyCharts||e.globals.comboCharts)&&this.tConfig.shared&&(s=this.showOnIntersect?1:e.globals.series.length),this.legendLabels=e.globals.dom.baseEl.querySelectorAll(".apexcharts-legend-text"),this.ttItems=this.createTTElements(s),this.addSVGEvents()}}},{key:"createTTElements",value:function(t){for(var e=this,i=this.w,a=[],s=this.getElTooltip(),r=function(r){var n=document.createElement("div");n.classList.add("apexcharts-tooltip-series-group"),n.style.order=i.config.tooltip.inverseOrder?t-r:r+1,e.tConfig.shared&&e.tConfig.enabledOnSeries&&Array.isArray(e.tConfig.enabledOnSeries)&&e.tConfig.enabledOnSeries.indexOf(r)<0&&n.classList.add("apexcharts-tooltip-series-group-hidden");var o=document.createElement("span");o.classList.add("apexcharts-tooltip-marker"),o.style.backgroundColor=i.globals.colors[r],n.appendChild(o);var l=document.createElement("div");l.classList.add("apexcharts-tooltip-text"),l.style.fontFamily=e.tConfig.style.fontFamily||i.config.chart.fontFamily,l.style.fontSize=e.tConfig.style.fontSize,["y","goals","z"].forEach((function(t){var e=document.createElement("div");e.classList.add("apexcharts-tooltip-".concat(t,"-group"));var i=document.createElement("span");i.classList.add("apexcharts-tooltip-text-".concat(t,"-label")),e.appendChild(i);var a=document.createElement("span");a.classList.add("apexcharts-tooltip-text-".concat(t,"-value")),e.appendChild(a),l.appendChild(e)})),n.appendChild(l),s.appendChild(n),a.push(n)},n=0;n<t;n++)r(n);return a}},{key:"addSVGEvents",value:function(){var t=this.w,e=t.config.chart.type,i=this.getElTooltip(),a=!("bar"!==e&&"candlestick"!==e&&"boxPlot"!==e&&"rangeBar"!==e),s="area"===e||"line"===e||"scatter"===e||"bubble"===e||"radar"===e,r=t.globals.dom.Paper.node,n=this.getElGrid();n&&(this.seriesBound=n.getBoundingClientRect());var o,l=[],c=[],h={hoverArea:r,elGrid:n,tooltipEl:i,tooltipY:l,tooltipX:c,ttItems:this.ttItems};if(t.globals.axisCharts&&(s?o=t.globals.dom.baseEl.querySelectorAll(".apexcharts-series[data\\:longestSeries='true'] .apexcharts-marker"):a?o=t.globals.dom.baseEl.querySelectorAll(".apexcharts-series .apexcharts-bar-area, .apexcharts-series .apexcharts-candlestick-area, .apexcharts-series .apexcharts-boxPlot-area, .apexcharts-series .apexcharts-rangebar-area"):"heatmap"!==e&&"treemap"!==e||(o=t.globals.dom.baseEl.querySelectorAll(".apexcharts-series .apexcharts-heatmap, .apexcharts-series .apexcharts-treemap")),o&&o.length))for(var d=0;d<o.length;d++)l.push(o[d].getAttribute("cy")),c.push(o[d].getAttribute("cx"));if(t.globals.xyCharts&&!this.showOnIntersect||t.globals.comboCharts&&!this.showOnIntersect||a&&this.tooltipUtil.hasBars()&&this.tConfig.shared)this.addPathsEventListeners([r],h);else if(a&&!t.globals.comboCharts||s&&this.showOnIntersect)this.addDatapointEventsListeners(h);else if(!t.globals.axisCharts||"heatmap"===e||"treemap"===e){var u=t.globals.dom.baseEl.querySelectorAll(".apexcharts-series");this.addPathsEventListeners(u,h)}if(this.showOnIntersect){var p=t.globals.dom.baseEl.querySelectorAll(".apexcharts-line-series .apexcharts-marker, .apexcharts-area-series .apexcharts-marker");p.length>0&&this.addPathsEventListeners(p,h),this.tooltipUtil.hasBars()&&!this.tConfig.shared&&this.addDatapointEventsListeners(h)}}},{key:"drawFixedTooltipRect",value:function(){var t=this.w,e=this.getElTooltip(),i=e.getBoundingClientRect(),a=i.width+10,s=i.height+10,r=this.tConfig.fixed.offsetX,n=this.tConfig.fixed.offsetY,o=this.tConfig.fixed.position.toLowerCase();return o.indexOf("right")>-1&&(r=r+t.globals.svgWidth-a+10),o.indexOf("bottom")>-1&&(n=n+t.globals.svgHeight-s-10),e.style.left=r+"px",e.style.top=n+"px",{x:r,y:n,ttWidth:a,ttHeight:s}}},{key:"addDatapointEventsListeners",value:function(t){var e=this.w.globals.dom.baseEl.querySelectorAll(".apexcharts-series-markers .apexcharts-marker, .apexcharts-bar-area, .apexcharts-candlestick-area, .apexcharts-boxPlot-area, .apexcharts-rangebar-area");this.addPathsEventListeners(e,t)}},{key:"addPathsEventListeners",value:function(t,e){for(var i=this,a=function(a){var s={paths:t[a],tooltipEl:e.tooltipEl,tooltipY:e.tooltipY,tooltipX:e.tooltipX,elGrid:e.elGrid,hoverArea:e.hoverArea,ttItems:e.ttItems};["mousemove","mouseup","touchmove","mouseout","touchend"].map((function(e){return t[a].addEventListener(e,i.onSeriesHover.bind(i,s),{capture:!1,passive:!0})}))},s=0;s<t.length;s++)a(s)}},{key:"onSeriesHover",value:function(t,e){var i=this,a=Date.now()-this.lastHoverTime;a>=100?this.seriesHover(t,e):(clearTimeout(this.seriesHoverTimeout),this.seriesHoverTimeout=setTimeout((function(){i.seriesHover(t,e)}),100-a))}},{key:"seriesHover",value:function(t,e){var i=this;this.lastHoverTime=Date.now();var a=[],s=this.w;s.config.chart.group&&(a=this.ctx.getGroupedCharts()),s.globals.axisCharts&&(s.globals.minX===-1/0&&s.globals.maxX===1/0||0===s.globals.dataPoints)||(a.length?a.forEach((function(a){var s=i.getElTooltip(a),r={paths:t.paths,tooltipEl:s,tooltipY:t.tooltipY,tooltipX:t.tooltipX,elGrid:t.elGrid,hoverArea:t.hoverArea,ttItems:a.w.globals.tooltip.ttItems};a.w.globals.minX===i.w.globals.minX&&a.w.globals.maxX===i.w.globals.maxX&&a.w.globals.tooltip.seriesHoverByContext({chartCtx:a,ttCtx:a.w.globals.tooltip,opt:r,e:e})})):this.seriesHoverByContext({chartCtx:this.ctx,ttCtx:this.w.globals.tooltip,opt:t,e:e}))}},{key:"seriesHoverByContext",value:function(t){var e=t.chartCtx,i=t.ttCtx,a=t.opt,s=t.e,r=e.w,n=this.getElTooltip();n&&(i.tooltipRect={x:0,y:0,ttWidth:n.getBoundingClientRect().width,ttHeight:n.getBoundingClientRect().height},i.e=s,!i.tooltipUtil.hasBars()||r.globals.comboCharts||i.isBarShared||this.tConfig.onDatasetHover.highlightDataSeries&&new B(e).toggleSeriesOnHover(s,s.target.parentNode),i.fixedTooltip&&i.drawFixedTooltipRect(),r.globals.axisCharts?i.axisChartsTooltips({e:s,opt:a,tooltipRect:i.tooltipRect}):i.nonAxisChartsTooltips({e:s,opt:a,tooltipRect:i.tooltipRect}))}},{key:"axisChartsTooltips",value:function(t){var e,i,a=t.e,s=t.opt,r=this.w,n=s.elGrid.getBoundingClientRect(),o="touchmove"===a.type?a.touches[0].clientX:a.clientX,l="touchmove"===a.type?a.touches[0].clientY:a.clientY;if(this.clientY=l,this.clientX=o,r.globals.capturedSeriesIndex=-1,r.globals.capturedDataPointIndex=-1,l<n.top||l>n.top+n.height)this.handleMouseOut(s);else{if(Array.isArray(this.tConfig.enabledOnSeries)&&!r.config.tooltip.shared){var c=parseInt(s.paths.getAttribute("index"),10);if(this.tConfig.enabledOnSeries.indexOf(c)<0)return void this.handleMouseOut(s)}var h=this.getElTooltip(),d=this.getElXCrosshairs(),u=r.globals.xyCharts||"bar"===r.config.chart.type&&!r.globals.isBarHorizontal&&this.tooltipUtil.hasBars()&&this.tConfig.shared||r.globals.comboCharts&&this.tooltipUtil.hasBars();if("mousemove"===a.type||"touchmove"===a.type||"mouseup"===a.type){if(r.globals.collapsedSeries.length+r.globals.ancillaryCollapsedSeries.length===r.globals.series.length)return;null!==d&&d.classList.add("apexcharts-active");var p=this.yaxisTooltips.filter((function(t){return!0===t}));if(null!==this.ycrosshairs&&p.length&&this.ycrosshairs.classList.add("apexcharts-active"),u&&!this.showOnIntersect)this.handleStickyTooltip(a,o,l,s);else if("heatmap"===r.config.chart.type||"treemap"===r.config.chart.type){var f=this.intersect.handleHeatTreeTooltip({e:a,opt:s,x:e,y:i,type:r.config.chart.type});e=f.x,i=f.y,h.style.left=e+"px",h.style.top=i+"px"}else this.tooltipUtil.hasBars()&&this.intersect.handleBarTooltip({e:a,opt:s}),this.tooltipUtil.hasMarkers()&&this.intersect.handleMarkerTooltip({e:a,opt:s,x:e,y:i});if(this.yaxisTooltips.length)for(var g=0;g<r.config.yaxis.length;g++)this.axesTooltip.drawYaxisTooltipText(g,l,this.xyRatios);s.tooltipEl.classList.add("apexcharts-active")}else"mouseout"!==a.type&&"touchend"!==a.type||this.handleMouseOut(s)}}},{key:"nonAxisChartsTooltips",value:function(t){var e=t.e,i=t.opt,a=t.tooltipRect,s=this.w,r=i.paths.getAttribute("rel"),n=this.getElTooltip(),o=s.globals.dom.elWrap.getBoundingClientRect();if("mousemove"===e.type||"touchmove"===e.type){n.classList.add("apexcharts-active"),this.tooltipLabels.drawSeriesTexts({ttItems:i.ttItems,i:parseInt(r,10)-1,shared:!1});var l=s.globals.clientX-o.left-a.ttWidth/2,c=s.globals.clientY-o.top-a.ttHeight-10;if(n.style.left=l+"px",n.style.top=c+"px",s.config.legend.tooltipHoverFormatter){var h=r-1,d=(0,s.config.legend.tooltipHoverFormatter)(this.legendLabels[h].getAttribute("data:default-text"),{seriesIndex:h,dataPointIndex:h,w:s});this.legendLabels[h].innerHTML=d}}else"mouseout"!==e.type&&"touchend"!==e.type||(n.classList.remove("apexcharts-active"),s.config.legend.tooltipHoverFormatter&&this.legendLabels.forEach((function(t){var e=t.getAttribute("data:default-text");t.innerHTML=decodeURIComponent(e)})))}},{key:"handleStickyTooltip",value:function(t,e,i,a){var s=this.w,r=this.tooltipUtil.getNearestValues({context:this,hoverArea:a.hoverArea,elGrid:a.elGrid,clientX:e,clientY:i}),n=r.j,o=r.capturedSeries,l=a.elGrid.getBoundingClientRect();r.hoverX<0||r.hoverX>l.width?this.handleMouseOut(a):null!==o?this.handleStickyCapturedSeries(t,o,a,n):(this.tooltipUtil.isXoverlap(n)||s.globals.isBarHorizontal)&&this.create(t,this,0,n,a.ttItems)}},{key:"handleStickyCapturedSeries",value:function(t,e,i,a){var s=this.w;this.tConfig.shared||null!==s.globals.series[e][a]?void 0!==s.globals.series[e][a]?this.tConfig.shared&&this.tooltipUtil.isXoverlap(a)&&this.tooltipUtil.isInitialSeriesSameLen()?this.create(t,this,e,a,i.ttItems):this.create(t,this,e,a,i.ttItems,!1):this.tooltipUtil.isXoverlap(a)&&this.create(t,this,0,a,i.ttItems):this.handleMouseOut(i)}},{key:"deactivateHoverFilter",value:function(){for(var t=this.w,e=new k(this.ctx),i=t.globals.dom.Paper.select(".apexcharts-bar-area"),a=0;a<i.length;a++)e.pathMouseLeave(i[a])}},{key:"handleMouseOut",value:function(t){var e=this.w,i=this.getElXCrosshairs();if(t.tooltipEl.classList.remove("apexcharts-active"),this.deactivateHoverFilter(),"bubble"!==e.config.chart.type&&this.marker.resetPointsSize(),null!==i&&i.classList.remove("apexcharts-active"),null!==this.ycrosshairs&&this.ycrosshairs.classList.remove("apexcharts-active"),this.isXAxisTooltipEnabled&&this.xaxisTooltip.classList.remove("apexcharts-active"),this.yaxisTooltips.length){null===this.yaxisTTEls&&(this.yaxisTTEls=e.globals.dom.baseEl.querySelectorAll(".apexcharts-yaxistooltip"));for(var a=0;a<this.yaxisTTEls.length;a++)this.yaxisTTEls[a].classList.remove("apexcharts-active")}e.config.legend.tooltipHoverFormatter&&this.legendLabels.forEach((function(t){var e=t.getAttribute("data:default-text");t.innerHTML=decodeURIComponent(e)}))}},{key:"markerClick",value:function(t,e,i){var a=this.w;"function"==typeof a.config.chart.events.markerClick&&a.config.chart.events.markerClick(t,this.ctx,{seriesIndex:e,dataPointIndex:i,w:a}),this.ctx.events.fireEvent("markerClick",[t,this.ctx,{seriesIndex:e,dataPointIndex:i,w:a}])}},{key:"create",value:function(t,e,i,a,s){var r=arguments.length>5&&void 0!==arguments[5]?arguments[5]:null,n=this.w,o=e;"mouseup"===t.type&&this.markerClick(t,i,a),null===r&&(r=this.tConfig.shared);var l=this.tooltipUtil.hasMarkers(),c=this.tooltipUtil.getElBars();if(n.config.legend.tooltipHoverFormatter){var h=n.config.legend.tooltipHoverFormatter,d=Array.from(this.legendLabels);d.forEach((function(t){var e=t.getAttribute("data:default-text");t.innerHTML=decodeURIComponent(e)}));for(var u=0;u<d.length;u++){var p=d[u],f=parseInt(p.getAttribute("i"),10),g=decodeURIComponent(p.getAttribute("data:default-text")),x=h(g,{seriesIndex:r?f:i,dataPointIndex:a,w:n});if(r)p.innerHTML=n.globals.collapsedSeriesIndices.indexOf(f)<0?x:g;else if(p.innerHTML=f===i?x:g,i===f)break}}if(r){if(o.tooltipLabels.drawSeriesTexts({ttItems:s,i:i,j:a,shared:!this.showOnIntersect&&this.tConfig.shared}),l&&(n.globals.markers.largestSize>0?o.marker.enlargePoints(a):o.tooltipPosition.moveDynamicPointsOnHover(a)),this.tooltipUtil.hasBars()&&(this.barSeriesHeight=this.tooltipUtil.getBarsHeight(c),this.barSeriesHeight>0)){var m=new k(this.ctx),b=n.globals.dom.Paper.select(".apexcharts-bar-area[j='".concat(a,"']"));this.deactivateHoverFilter(),this.tooltipPosition.moveStickyTooltipOverBars(a);for(var v=0;v<b.length;v++)m.pathMouseEnter(b[v])}}else o.tooltipLabels.drawSeriesTexts({shared:!1,ttItems:s,i:i,j:a}),this.tooltipUtil.hasBars()&&o.tooltipPosition.moveStickyTooltipOverBars(a),l&&o.tooltipPosition.moveMarkers(i,a)}}]),t}(),wt=function(){function t(e){o(this,t),this.w=e.w,this.barCtx=e,this.totalFormatter=this.w.config.plotOptions.bar.dataLabels.total.formatter,this.totalFormatter||(this.totalFormatter=this.w.config.dataLabels.formatter)}return c(t,[{key:"handleBarDataLabels",value:function(t){var e=t.x,i=t.y,a=t.y1,s=t.y2,r=t.i,n=t.j,o=t.realIndex,l=t.series,c=t.barHeight,h=t.barWidth,d=t.barYPosition,u=t.visibleSeries,p=t.renderedPath,f=this.w,g=new k(this.barCtx.ctx),x=Array.isArray(this.barCtx.strokeWidth)?this.barCtx.strokeWidth[o]:this.barCtx.strokeWidth,m=e+parseFloat(h*u),b=i+parseFloat(c*u);f.globals.isXNumeric&&!f.globals.isBarHorizontal&&(m=e+parseFloat(h*(u+1)),b=i+parseFloat(c*(u+1))-x);var v,y,w=null,A=e,S=i,C=f.config.dataLabels,P=this.barCtx.barOptions.dataLabels,L=this.barCtx.barOptions.dataLabels.total;void 0!==d&&this.barCtx.isRangeBar&&(b=d,S=d);var D=C.offsetX,T=C.offsetY,M={width:0,height:0};if(f.config.dataLabels.enabled){var E=this.barCtx.series[r][n];M=g.getTextRects(f.globals.yLabelFormatters[0](E),parseFloat(C.style.fontSize))}var I={x:e,y:i,i:r,j:n,realIndex:o,renderedPath:p,bcx:m,bcy:b,barHeight:c,barWidth:h,textRects:M,strokeWidth:x,dataLabelsX:A,dataLabelsY:S,dataLabelsConfig:C,barDataLabelsConfig:P,barTotalDataLabelsConfig:L,offX:D,offY:T};return y=this.barCtx.isHorizontal?this.calculateBarsDataLabelsPosition(I):this.calculateColumnsDataLabelsPosition(I),p.attr({cy:y.bcy,cx:y.bcx,j:n,val:l[r][n],barHeight:c,barWidth:h}),v=this.drawCalculatedDataLabels({x:y.dataLabelsX,y:y.dataLabelsY,val:this.barCtx.isRangeBar?[a,s]:l[r][n],i:o,j:n,barWidth:h,barHeight:c,textRects:M,dataLabelsConfig:C}),f.config.chart.stacked&&L.enabled&&(w=this.drawTotalDataLabels({x:y.totalDataLabelsX,y:y.totalDataLabelsY,realIndex:o,textAnchor:y.totalDataLabelsAnchor,val:this.getStackedTotalDataLabel({realIndex:o,j:n}),dataLabelsConfig:C,barTotalDataLabelsConfig:L})),{dataLabels:v,totalDataLabels:w}}},{key:"getStackedTotalDataLabel",value:function(t){var e=t.realIndex,i=t.j,a=this.w,s=this.barCtx.stackedSeriesTotals[i];return this.totalFormatter&&(s=this.totalFormatter(s,r(r({},a),{},{seriesIndex:e,dataPointIndex:i,w:a}))),s}},{key:"calculateColumnsDataLabelsPosition",value:function(t){var e,i,a,s=this.w,r=t.i,n=t.j,o=t.realIndex,l=t.y,c=t.bcx,h=t.barWidth,d=t.barHeight,u=t.textRects,p=t.dataLabelsY,f=t.dataLabelsConfig,g=t.barDataLabelsConfig,x=t.barTotalDataLabelsConfig,m=t.strokeWidth,b=t.offX,v=t.offY;d=Math.abs(d);var y="vertical"===s.config.plotOptions.bar.dataLabels.orientation;c-=m/2;var w=s.globals.gridWidth/s.globals.dataPoints;e=s.globals.isXNumeric?c-h/2+b:c-w+h/2+b,y&&(e=e+u.height/2-m/2-2);var A=this.barCtx.series[r][n]<0,S=l;switch(this.barCtx.isReversed&&(S=l-d+(A?2*d:0),l-=d),g.position){case"center":p=y?A?S+d/2+v:S+d/2-v:A?S-d/2+u.height/2+v:S+d/2+u.height/2-v;break;case"bottom":p=y?A?S+d+v:S+d-v:A?S-d+u.height+m+v:S+d-u.height/2+m-v;break;case"top":p=y?A?S+v:S-v:A?S-u.height/2-v:S+u.height+v}if(this.barCtx.lastActiveBarSerieIndex===o&&x.enabled){var C=new k(this.barCtx.ctx).getTextRects(this.getStackedTotalDataLabel({realIndex:o,j:n}),f.fontSize);i=A?S-C.height/2-v-x.offsetY+18:S+C.height+v+x.offsetY-18,a=e+x.offsetX}return s.config.chart.stacked||(p<0?p=0+m:p+u.height/3>s.globals.gridHeight&&(p=s.globals.gridHeight-m)),{bcx:c,bcy:l,dataLabelsX:e,dataLabelsY:p,totalDataLabelsX:a,totalDataLabelsY:i,totalDataLabelsAnchor:"middle"}}},{key:"calculateBarsDataLabelsPosition",value:function(t){var e=this.w,i=t.x,a=t.i,s=t.j,r=t.realIndex,n=t.bcy,o=t.barHeight,l=t.barWidth,c=t.textRects,h=t.dataLabelsX,d=t.strokeWidth,u=t.dataLabelsConfig,p=t.barDataLabelsConfig,f=t.barTotalDataLabelsConfig,g=t.offX,x=t.offY,m=e.globals.gridHeight/e.globals.dataPoints;l=Math.abs(l);var b,v,y=n-(this.barCtx.isRangeBar?0:m)+o/2+c.height/2+x-3,w="start",A=this.barCtx.series[a][s]<0,S=i;switch(this.barCtx.isReversed&&(S=i+l-(A?2*l:0),i=e.globals.gridWidth-l),p.position){case"center":h=A?S+l/2-g:Math.max(c.width/2,S-l/2)+g;break;case"bottom":h=A?S+l-d-Math.round(c.width/2)-g:S-l+d+Math.round(c.width/2)+g;break;case"top":h=A?S-d+Math.round(c.width/2)-g:S-d-Math.round(c.width/2)+g}if(this.barCtx.lastActiveBarSerieIndex===r&&f.enabled){var C=new k(this.barCtx.ctx).getTextRects(this.getStackedTotalDataLabel({realIndex:r,j:s}),u.fontSize);A?(b=S-d+Math.round(C.width/2)-g-f.offsetX-15,w="end"):b=S-d-Math.round(C.width/2)+g+f.offsetX+15,v=y+f.offsetY}return e.config.chart.stacked||(h<0?h=h+c.width+d:h+c.width/2>e.globals.gridWidth&&(h=e.globals.gridWidth-c.width-d)),{bcx:i,bcy:n,dataLabelsX:h,dataLabelsY:y,totalDataLabelsX:b,totalDataLabelsY:v,totalDataLabelsAnchor:w}}},{key:"drawCalculatedDataLabels",value:function(t){var e=t.x,i=t.y,a=t.val,s=t.i,n=t.j,o=t.textRects,l=t.barHeight,c=t.barWidth,h=t.dataLabelsConfig,d=this.w,u="rotate(0)";"vertical"===d.config.plotOptions.bar.dataLabels.orientation&&(u="rotate(-90, ".concat(e,", ").concat(i,")"));var p=new H(this.barCtx.ctx),f=new k(this.barCtx.ctx),g=h.formatter,x=null,m=d.globals.collapsedSeriesIndices.indexOf(s)>-1;if(h.enabled&&!m){x=f.group({class:"apexcharts-data-labels",transform:u});var b="";void 0!==a&&(b=g(a,r(r({},d),{},{seriesIndex:s,dataPointIndex:n,w:d})));var v=d.globals.series[s][n]<0,y=d.config.plotOptions.bar.dataLabels.position;"vertical"===d.config.plotOptions.bar.dataLabels.orientation&&("top"===y&&(h.textAnchor=v?"end":"start"),"center"===y&&(h.textAnchor="middle"),"bottom"===y&&(h.textAnchor=v?"end":"start")),this.barCtx.isRangeBar&&this.barCtx.barOptions.dataLabels.hideOverflowingLabels&&c<f.getTextRects(b,parseFloat(h.style.fontSize)).width&&(b=""),d.config.chart.stacked&&this.barCtx.barOptions.dataLabels.hideOverflowingLabels&&(this.barCtx.isHorizontal?o.width/1.6>Math.abs(c)&&(b=""):o.height/1.6>Math.abs(l)&&(b=""));var w=r({},h);this.barCtx.isHorizontal&&a<0&&("start"===h.textAnchor?w.textAnchor="end":"end"===h.textAnchor&&(w.textAnchor="start")),p.plotDataLabelsText({x:e,y:i,text:b,i:s,j:n,parent:x,dataLabelsConfig:w,alwaysDrawDataLabel:!0,offsetCorrection:!0})}return x}},{key:"drawTotalDataLabels",value:function(t){var e,i=t.x,a=t.y,s=t.val,r=t.realIndex,n=t.textAnchor,o=t.barTotalDataLabelsConfig,l=new k(this.barCtx.ctx);return o.enabled&&void 0!==i&&void 0!==a&&this.barCtx.lastActiveBarSerieIndex===r&&(e=l.drawText({x:i,y:a,foreColor:o.style.color,text:s,textAnchor:n,fontFamily:o.style.fontFamily,fontSize:o.style.fontSize,fontWeight:o.style.fontWeight})),e}}]),t}(),kt=function(){function t(e){o(this,t),this.w=e.w,this.barCtx=e}return c(t,[{key:"initVariables",value:function(t){var e=this.w;this.barCtx.series=t,this.barCtx.totalItems=0,this.barCtx.seriesLen=0,this.barCtx.visibleI=-1,this.barCtx.visibleItems=1;for(var i=0;i<t.length;i++)if(t[i].length>0&&(this.barCtx.seriesLen=this.barCtx.seriesLen+1,this.barCtx.totalItems+=t[i].length),e.globals.isXNumeric)for(var a=0;a<t[i].length;a++)e.globals.seriesX[i][a]>e.globals.minX&&e.globals.seriesX[i][a]<e.globals.maxX&&this.barCtx.visibleItems++;else this.barCtx.visibleItems=e.globals.dataPoints;0===this.barCtx.seriesLen&&(this.barCtx.seriesLen=1),this.barCtx.zeroSerieses=[],this.barCtx.radiusOnSeriesNumber=t.length-1,e.globals.comboCharts||this.checkZeroSeries({series:t})}},{key:"initialPositions",value:function(){var t,e,i,a,s,r,n,o,l=this.w,c=l.globals.dataPoints;this.barCtx.isRangeBar&&(c=l.globals.labels.length);var h=this.barCtx.seriesLen;if(l.config.plotOptions.bar.rangeBarGroupRows&&(h=1),this.barCtx.isHorizontal)s=(i=l.globals.gridHeight/c)/h,l.globals.isXNumeric&&(s=(i=l.globals.gridHeight/this.barCtx.totalItems)/this.barCtx.seriesLen),s=s*parseInt(this.barCtx.barOptions.barHeight,10)/100,o=this.barCtx.baseLineInvertedY+l.globals.padHorizontal+(this.barCtx.isReversed?l.globals.gridWidth:0)-(this.barCtx.isReversed?2*this.barCtx.baseLineInvertedY:0),e=(i-s*this.barCtx.seriesLen)/2;else{if(a=l.globals.gridWidth/this.barCtx.visibleItems,l.config.xaxis.convertedCatToNumeric&&(a=l.globals.gridWidth/l.globals.dataPoints),r=a/this.barCtx.seriesLen*parseInt(this.barCtx.barOptions.columnWidth,10)/100,l.globals.isXNumeric){var d=this.barCtx.xRatio;l.config.xaxis.convertedCatToNumeric&&(d=this.barCtx.initialXRatio),l.globals.minXDiff&&.5!==l.globals.minXDiff&&l.globals.minXDiff/d>0&&(a=l.globals.minXDiff/d),(r=a/this.barCtx.seriesLen*parseInt(this.barCtx.barOptions.columnWidth,10)/100)<1&&(r=1)}n=l.globals.gridHeight-this.barCtx.baseLineY[this.barCtx.yaxisIndex]-(this.barCtx.isReversed?l.globals.gridHeight:0)+(this.barCtx.isReversed?2*this.barCtx.baseLineY[this.barCtx.yaxisIndex]:0),t=l.globals.padHorizontal+(a-r*this.barCtx.seriesLen)/2}return{x:t,y:e,yDivision:i,xDivision:a,barHeight:s,barWidth:r,zeroH:n,zeroW:o}}},{key:"getPathFillColor",value:function(t,e,i,a){var s,r,n,o,l=this.w,c=new N(this.barCtx.ctx),h=null,d=this.barCtx.barOptions.distributed?i:e;return this.barCtx.barOptions.colors.ranges.length>0&&this.barCtx.barOptions.colors.ranges.map((function(a){t[e][i]>=a.from&&t[e][i]<=a.to&&(h=a.color)})),l.config.series[e].data[i]&&l.config.series[e].data[i].fillColor&&(h=l.config.series[e].data[i].fillColor),c.fillPath({seriesNumber:this.barCtx.barOptions.distributed?d:a,dataPointIndex:i,color:h,value:t[e][i],fillConfig:null===(s=l.config.series[e].data[i])||void 0===s?void 0:s.fill,fillType:null!==(r=l.config.series[e].data[i])&&void 0!==r&&null!==(n=r.fill)&&void 0!==n&&n.type?null===(o=l.config.series[e].data[i])||void 0===o?void 0:o.fill.type:l.config.fill.type})}},{key:"getStrokeWidth",value:function(t,e,i){var a=0,s=this.w;return void 0===this.barCtx.series[t][e]||null===this.barCtx.series[t][e]?this.barCtx.isNullValue=!0:this.barCtx.isNullValue=!1,s.config.stroke.show&&(this.barCtx.isNullValue||(a=Array.isArray(this.barCtx.strokeWidth)?this.barCtx.strokeWidth[i]:this.barCtx.strokeWidth)),a}},{key:"shouldApplyRadius",value:function(t){var e=this.w,i=!1;return e.config.plotOptions.bar.borderRadius>0&&(e.config.chart.stacked&&"last"===e.config.plotOptions.bar.borderRadiusWhenStacked?this.barCtx.lastActiveBarSerieIndex===t&&(i=!0):i=!0),i}},{key:"barBackground",value:function(t){var e=t.j,i=t.i,a=t.x1,s=t.x2,r=t.y1,n=t.y2,o=t.elSeries,l=this.w,c=new k(this.barCtx.ctx),h=new B(this.barCtx.ctx).getActiveConfigSeriesIndex();if(this.barCtx.barOptions.colors.backgroundBarColors.length>0&&h===i){e>=this.barCtx.barOptions.colors.backgroundBarColors.length&&(e%=this.barCtx.barOptions.colors.backgroundBarColors.length);var d=this.barCtx.barOptions.colors.backgroundBarColors[e],u=c.drawRect(void 0!==a?a:0,void 0!==r?r:0,void 0!==s?s:l.globals.gridWidth,void 0!==n?n:l.globals.gridHeight,this.barCtx.barOptions.colors.backgroundBarRadius,d,this.barCtx.barOptions.colors.backgroundBarOpacity);o.add(u),u.node.classList.add("apexcharts-backgroundBar")}}},{key:"getColumnPaths",value:function(t){var e,i=t.barWidth,a=t.barXPosition,s=t.y1,r=t.y2,n=t.strokeWidth,o=t.realIndex,l=t.i,c=t.j,h=t.w,d=new k(this.barCtx.ctx);(n=Array.isArray(n)?n[o]:n)||(n=0);var u=i,p=a;null!==(e=h.config.series[o].data[c])&&void 0!==e&&e.columnWidthOffset&&(p=a-h.config.series[o].data[c].columnWidthOffset/2,u=i+h.config.series[o].data[c].columnWidthOffset);var f=p,g=p+u;s+=.001,r+=.001;var x=d.move(f,s),m=d.move(f,s),b=d.line(g-n,s);return h.globals.previousPaths.length>0&&(m=this.barCtx.getPreviousPath(o,c,!1)),x=x+d.line(f,r)+d.line(g-n,r)+d.line(g-n,s)+("around"===h.config.plotOptions.bar.borderRadiusApplication?" Z":" z"),m=m+d.line(f,s)+b+b+b+b+b+d.line(f,s)+("around"===h.config.plotOptions.bar.borderRadiusApplication?" Z":" z"),this.shouldApplyRadius(o)&&(x=d.roundPathCorners(x,h.config.plotOptions.bar.borderRadius)),h.config.chart.stacked&&(this.barCtx.yArrj.push(r),this.barCtx.yArrjF.push(Math.abs(s-r)),this.barCtx.yArrjVal.push(this.barCtx.series[l][c])),{pathTo:x,pathFrom:m}}},{key:"getBarpaths",value:function(t){var e,i=t.barYPosition,a=t.barHeight,s=t.x1,r=t.x2,n=t.strokeWidth,o=t.realIndex,l=t.i,c=t.j,h=t.w,d=new k(this.barCtx.ctx);(n=Array.isArray(n)?n[o]:n)||(n=0);var u=i,p=a;null!==(e=h.config.series[o].data[c])&&void 0!==e&&e.barHeightOffset&&(u=i-h.config.series[o].data[c].barHeightOffset/2,p=a+h.config.series[o].data[c].barHeightOffset);var f=u,g=u+p;s+=.001,r+=.001;var x=d.move(s,f),m=d.move(s,f);h.globals.previousPaths.length>0&&(m=this.barCtx.getPreviousPath(o,c,!1));var b=d.line(s,g-n);return x=x+d.line(r,f)+d.line(r,g-n)+b+("around"===h.config.plotOptions.bar.borderRadiusApplication?" Z":" z"),m=m+d.line(s,f)+b+b+b+b+b+d.line(s,f)+("around"===h.config.plotOptions.bar.borderRadiusApplication?" Z":" z"),this.shouldApplyRadius(o)&&(x=d.roundPathCorners(x,h.config.plotOptions.bar.borderRadius)),h.config.chart.stacked&&(this.barCtx.xArrj.push(r),this.barCtx.xArrjF.push(Math.abs(s-r)),this.barCtx.xArrjVal.push(this.barCtx.series[l][c])),{pathTo:x,pathFrom:m}}},{key:"checkZeroSeries",value:function(t){for(var e=t.series,i=this.w,a=0;a<e.length;a++){for(var s=0,r=0;r<e[i.globals.maxValsInArrayIndex].length;r++)s+=e[a][r];0===s&&this.barCtx.zeroSerieses.push(a)}for(var n=e.length-1;n>=0;n--)this.barCtx.zeroSerieses.indexOf(n)>-1&&n===this.radiusOnSeriesNumber&&(this.barCtx.radiusOnSeriesNumber-=1);for(var o=e.length-1;o>=0;o--)i.globals.collapsedSeriesIndices.indexOf(this.barCtx.radiusOnSeriesNumber)>-1&&(this.barCtx.radiusOnSeriesNumber-=1)}},{key:"getXForValue",value:function(t,e){var i=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],a=i?e:null;return null!=t&&(a=e+t/this.barCtx.invertedYRatio-2*(this.barCtx.isReversed?t/this.barCtx.invertedYRatio:0)),a}},{key:"getYForValue",value:function(t,e){var i=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],a=i?e:null;return null!=t&&(a=e-t/this.barCtx.yRatio[this.barCtx.yaxisIndex]+2*(this.barCtx.isReversed?t/this.barCtx.yRatio[this.barCtx.yaxisIndex]:0)),a}},{key:"getGoalValues",value:function(t,e,i,a,s){var r=this,n=this.w,o=[];return n.globals.seriesGoals[a]&&n.globals.seriesGoals[a][s]&&Array.isArray(n.globals.seriesGoals[a][s])&&n.globals.seriesGoals[a][s].forEach((function(a){var s;o.push((h(s={},t,"x"===t?r.getXForValue(a.value,e,!1):r.getYForValue(a.value,i,!1)),h(s,"attrs",a),s))})),o}},{key:"drawGoalLine",value:function(t){var e=t.barXPosition,i=t.barYPosition,a=t.goalX,s=t.goalY,r=t.barWidth,n=t.barHeight,o=new k(this.barCtx.ctx),l=o.group({className:"apexcharts-bar-goals-groups"}),c=null;return this.barCtx.isHorizontal?Array.isArray(a)&&a.forEach((function(t){var e=void 0!==t.attrs.strokeHeight?t.attrs.strokeHeight:n/2,a=i+e+n/2;c=o.drawLine(t.x,a-2*e,t.x,a,t.attrs.strokeColor?t.attrs.strokeColor:void 0,t.attrs.strokeDashArray,t.attrs.strokeWidth?t.attrs.strokeWidth:2,t.attrs.strokeLineCap),l.add(c)})):Array.isArray(s)&&s.forEach((function(t){var i=void 0!==t.attrs.strokeWidth?t.attrs.strokeWidth:r/2,a=e+i+r/2;c=o.drawLine(a-2*i,t.y,a,t.y,t.attrs.strokeColor?t.attrs.strokeColor:void 0,t.attrs.strokeDashArray,t.attrs.strokeHeight?t.attrs.strokeHeight:2,t.attrs.strokeLineCap),l.add(c)})),l}}]),t}(),At=function(){function t(e,i){o(this,t),this.ctx=e,this.w=e.w;var a=this.w;this.barOptions=a.config.plotOptions.bar,this.isHorizontal=this.barOptions.horizontal,this.strokeWidth=a.config.stroke.width,this.isNullValue=!1,this.isRangeBar=a.globals.seriesRange.length&&this.isHorizontal,this.xyRatios=i,null!==this.xyRatios&&(this.xRatio=i.xRatio,this.initialXRatio=i.initialXRatio,this.yRatio=i.yRatio,this.invertedXRatio=i.invertedXRatio,this.invertedYRatio=i.invertedYRatio,this.baseLineY=i.baseLineY,this.baseLineInvertedY=i.baseLineInvertedY),this.yaxisIndex=0,this.seriesLen=0;var s=new B(this.ctx);this.lastActiveBarSerieIndex=s.getActiveConfigSeriesIndex("desc",["bar","column"]);var r=s.getBarSeriesIndices(),n=new A(this.ctx);this.stackedSeriesTotals=n.getStackedSeriesTotals(this.w.config.series.map((function(t,e){return-1===r.indexOf(e)?e:-1})).filter((function(t){return-1!==t}))),this.barHelpers=new kt(this)}return c(t,[{key:"draw",value:function(t,e){var i=this.w,a=new k(this.ctx),s=new A(this.ctx,i);t=s.getLogSeries(t),this.series=t,this.yRatio=s.getLogYRatios(this.yRatio),this.barHelpers.initVariables(t);var n=a.group({class:"apexcharts-bar-series apexcharts-plot-series"});i.config.dataLabels.enabled&&this.totalItems>this.barOptions.dataLabels.maxItems&&console.warn("WARNING: DataLabels are enabled but there are too many to display. This may cause performance issue when rendering.");for(var o=0,l=0;o<t.length;o++,l++){var c,h,d,u,p=void 0,f=void 0,g=[],x=[],m=i.globals.comboCharts?e[o]:o,b=a.group({class:"apexcharts-series",rel:o+1,seriesName:v.escapeString(i.globals.seriesNames[m]),"data:realIndex":m});this.ctx.series.addCollapsedClassToSeries(b,m),t[o].length>0&&(this.visibleI=this.visibleI+1);var y=0,w=0;this.yRatio.length>1&&(this.yaxisIndex=m),this.isReversed=i.config.yaxis[this.yaxisIndex]&&i.config.yaxis[this.yaxisIndex].reversed;var S=this.barHelpers.initialPositions();f=S.y,y=S.barHeight,h=S.yDivision,u=S.zeroW,p=S.x,w=S.barWidth,c=S.xDivision,d=S.zeroH,this.horizontal||x.push(p+w/2);for(var C=a.group({class:"apexcharts-datalabels","data:realIndex":m}),P=a.group({class:"apexcharts-bar-goals-markers",style:"pointer-events: none"}),L=0;L<i.globals.dataPoints;L++){var D=this.barHelpers.getStrokeWidth(o,L,m),T=null,M={indexes:{i:o,j:L,realIndex:m,bc:l},x:p,y:f,strokeWidth:D,elSeries:b};this.isHorizontal?(T=this.drawBarPaths(r(r({},M),{},{barHeight:y,zeroW:u,yDivision:h})),w=this.series[o][L]/this.invertedYRatio):(T=this.drawColumnPaths(r(r({},M),{},{xDivision:c,barWidth:w,zeroH:d})),y=this.series[o][L]/this.yRatio[this.yaxisIndex]);var E=this.barHelpers.drawGoalLine({barXPosition:T.barXPosition,barYPosition:T.barYPosition,goalX:T.goalX,goalY:T.goalY,barHeight:y,barWidth:w});E&&P.add(E),f=T.y,p=T.x,L>0&&x.push(p+w/2),g.push(f);var I=this.barHelpers.getPathFillColor(t,o,L,m);this.renderSeries({realIndex:m,pathFill:I,j:L,i:o,pathFrom:T.pathFrom,pathTo:T.pathTo,strokeWidth:D,elSeries:b,x:p,y:f,series:t,barHeight:y,barWidth:w,elDataLabelsWrap:C,elGoalsMarkers:P,visibleSeries:this.visibleI,type:"bar"})}i.globals.seriesXvalues[m]=x,i.globals.seriesYvalues[m]=g,n.add(b)}return n}},{key:"renderSeries",value:function(t){var e=t.realIndex,i=t.pathFill,a=t.lineFill,s=t.j,r=t.i,n=t.pathFrom,o=t.pathTo,l=t.strokeWidth,c=t.elSeries,h=t.x,d=t.y,u=t.y1,p=t.y2,f=t.series,g=t.barHeight,x=t.barWidth,m=t.barYPosition,b=t.elDataLabelsWrap,v=t.elGoalsMarkers,y=t.visibleSeries,A=t.type,S=this.w,C=new k(this.ctx);a||(a=this.barOptions.distributed?S.globals.stroke.colors[s]:S.globals.stroke.colors[e]),S.config.series[r].data[s]&&S.config.series[r].data[s].strokeColor&&(a=S.config.series[r].data[s].strokeColor),this.isNullValue&&(i="none");var P=s/S.config.chart.animations.animateGradually.delay*(S.config.chart.animations.speed/S.globals.dataPoints)/2.4,L=C.renderPaths({i:r,j:s,realIndex:e,pathFrom:n,pathTo:o,stroke:a,strokeWidth:l,strokeLineCap:S.config.stroke.lineCap,fill:i,animationDelay:P,initialSpeed:S.config.chart.animations.speed,dataChangeSpeed:S.config.chart.animations.dynamicAnimation.speed,className:"apexcharts-".concat(A,"-area")});L.attr("clip-path","url(#gridRectMask".concat(S.globals.cuid,")"));var D=S.config.forecastDataPoints;D.count>0&&s>=S.globals.dataPoints-D.count&&(L.node.setAttribute("stroke-dasharray",D.dashArray),L.node.setAttribute("stroke-width",D.strokeWidth),L.node.setAttribute("fill-opacity",D.fillOpacity)),void 0!==u&&void 0!==p&&(L.attr("data-range-y1",u),L.attr("data-range-y2",p)),new w(this.ctx).setSelectionFilter(L,e,s),c.add(L);var T=new wt(this).handleBarDataLabels({x:h,y:d,y1:u,y2:p,i:r,j:s,series:f,realIndex:e,barHeight:g,barWidth:x,barYPosition:m,renderedPath:L,visibleSeries:y});return null!==T.dataLabels&&b.add(T.dataLabels),T.totalDataLabels&&b.add(T.totalDataLabels),c.add(b),v&&c.add(v),c}},{key:"drawBarPaths",value:function(t){var e=t.indexes,i=t.barHeight,a=t.strokeWidth,s=t.zeroW,r=t.x,n=t.y,o=t.yDivision,l=t.elSeries,c=this.w,h=e.i,d=e.j;c.globals.isXNumeric&&(n=(c.globals.seriesX[h][d]-c.globals.minX)/this.invertedXRatio-i);var u=n+i*this.visibleI;r=this.barHelpers.getXForValue(this.series[h][d],s);var p=this.barHelpers.getBarpaths({barYPosition:u,barHeight:i,x1:s,x2:r,strokeWidth:a,series:this.series,realIndex:e.realIndex,i:h,j:d,w:c});return c.globals.isXNumeric||(n+=o),this.barHelpers.barBackground({j:d,i:h,y1:u-i*this.visibleI,y2:i*this.seriesLen,elSeries:l}),{pathTo:p.pathTo,pathFrom:p.pathFrom,x:r,y:n,goalX:this.barHelpers.getGoalValues("x",s,null,h,d),barYPosition:u}}},{key:"drawColumnPaths",value:function(t){var e=t.indexes,i=t.x,a=t.y,s=t.xDivision,r=t.barWidth,n=t.zeroH,o=t.strokeWidth,l=t.elSeries,c=this.w,h=e.realIndex,d=e.i,u=e.j,p=e.bc;if(c.globals.isXNumeric){var f=h;c.globals.seriesX[h].length||(f=c.globals.maxValsInArrayIndex),i=(c.globals.seriesX[f][u]-c.globals.minX)/this.xRatio-r*this.seriesLen/2}var g=i+r*this.visibleI;a=this.barHelpers.getYForValue(this.series[d][u],n);var x=this.barHelpers.getColumnPaths({barXPosition:g,barWidth:r,y1:n,y2:a,strokeWidth:o,series:this.series,realIndex:e.realIndex,i:d,j:u,w:c});return c.globals.isXNumeric||(i+=s),this.barHelpers.barBackground({bc:p,j:u,i:d,x1:g-o/2-r*this.visibleI,x2:r*this.seriesLen+o/2,elSeries:l}),{pathTo:x.pathTo,pathFrom:x.pathFrom,x:i,y:a,goalY:this.barHelpers.getGoalValues("y",null,n,d,u),barXPosition:g}}},{key:"getPreviousPath",value:function(t,e){for(var i,a=this.w,s=0;s<a.globals.previousPaths.length;s++){var r=a.globals.previousPaths[s];r.paths&&r.paths.length>0&&parseInt(r.realIndex,10)===parseInt(t,10)&&void 0!==a.globals.previousPaths[s].paths[e]&&(i=a.globals.previousPaths[s].paths[e].d)}return i}}]),t}(),St=function(t){d(i,At);var e=g(i);function i(){return o(this,i),e.apply(this,arguments)}return c(i,[{key:"draw",value:function(t,e){var i=this,a=this.w;this.graphics=new k(this.ctx),this.bar=new At(this.ctx,this.xyRatios);var s=new A(this.ctx,a);t=s.getLogSeries(t),this.yRatio=s.getLogYRatios(this.yRatio),this.barHelpers.initVariables(t),"100%"===a.config.chart.stackType&&(t=a.globals.seriesPercent.slice()),this.series=t,this.totalItems=0,this.prevY=[],this.prevX=[],this.prevYF=[],this.prevXF=[],this.prevYVal=[],this.prevXVal=[],this.xArrj=[],this.xArrjF=[],this.xArrjVal=[],this.yArrj=[],this.yArrjF=[],this.yArrjVal=[];for(var n=0;n<t.length;n++)t[n].length>0&&(this.totalItems+=t[n].length);for(var o=this.graphics.group({class:"apexcharts-bar-series apexcharts-plot-series"}),l=0,c=0,h=function(s,n){var h=void 0,d=void 0,u=void 0,p=void 0,f=[],g=[],x=a.globals.comboCharts?e[s]:s;i.yRatio.length>1&&(i.yaxisIndex=x),i.isReversed=a.config.yaxis[i.yaxisIndex]&&a.config.yaxis[i.yaxisIndex].reversed;var m=i.graphics.group({class:"apexcharts-series",seriesName:v.escapeString(a.globals.seriesNames[x]),rel:s+1,"data:realIndex":x});i.ctx.series.addCollapsedClassToSeries(m,x);var b=i.graphics.group({class:"apexcharts-datalabels","data:realIndex":x}),y=i.graphics.group({class:"apexcharts-bar-goals-markers",style:"pointer-events: none"}),w=0,k=0,A=i.initialPositions(l,c,h,d,u,p);c=A.y,w=A.barHeight,d=A.yDivision,p=A.zeroW,l=A.x,k=A.barWidth,h=A.xDivision,u=A.zeroH,i.yArrj=[],i.yArrjF=[],i.yArrjVal=[],i.xArrj=[],i.xArrjF=[],i.xArrjVal=[],1===i.prevY.length&&i.prevY[0].every((function(t){return isNaN(t)}))&&(i.prevY[0]=i.prevY[0].map((function(t){return u})),i.prevYF[0]=i.prevYF[0].map((function(t){return 0})));for(var S=0;S<a.globals.dataPoints;S++){var C=i.barHelpers.getStrokeWidth(s,S,x),P={indexes:{i:s,j:S,realIndex:x,bc:n},strokeWidth:C,x:l,y:c,elSeries:m},L=null;i.isHorizontal?(L=i.drawStackedBarPaths(r(r({},P),{},{zeroW:p,barHeight:w,yDivision:d})),k=i.series[s][S]/i.invertedYRatio):(L=i.drawStackedColumnPaths(r(r({},P),{},{xDivision:h,barWidth:k,zeroH:u})),w=i.series[s][S]/i.yRatio[i.yaxisIndex]);var D=i.barHelpers.drawGoalLine({barXPosition:L.barXPosition,barYPosition:L.barYPosition,goalX:L.goalX,goalY:L.goalY,barHeight:w,barWidth:k});D&&y.add(D),c=L.y,l=L.x,f.push(l),g.push(c);var T=i.barHelpers.getPathFillColor(t,s,S,x);m=i.renderSeries({realIndex:x,pathFill:T,j:S,i:s,pathFrom:L.pathFrom,pathTo:L.pathTo,strokeWidth:C,elSeries:m,x:l,y:c,series:t,barHeight:w,barWidth:k,elDataLabelsWrap:b,elGoalsMarkers:y,type:"bar",visibleSeries:0})}a.globals.seriesXvalues[x]=f,a.globals.seriesYvalues[x]=g,i.prevY.push(i.yArrj),i.prevYF.push(i.yArrjF),i.prevYVal.push(i.yArrjVal),i.prevX.push(i.xArrj),i.prevXF.push(i.xArrjF),i.prevXVal.push(i.xArrjVal),o.add(m)},d=0,u=0;d<t.length;d++,u++)h(d,u);return o}},{key:"initialPositions",value:function(t,e,i,a,s,r){var n,o,l=this.w;return this.isHorizontal?(n=(n=a=l.globals.gridHeight/l.globals.dataPoints)*parseInt(l.config.plotOptions.bar.barHeight,10)/100,r=this.baseLineInvertedY+l.globals.padHorizontal+(this.isReversed?l.globals.gridWidth:0)-(this.isReversed?2*this.baseLineInvertedY:0),e=(a-n)/2):(o=i=l.globals.gridWidth/l.globals.dataPoints,o=l.globals.isXNumeric&&l.globals.dataPoints>1?(i=l.globals.minXDiff/this.xRatio)*parseInt(this.barOptions.columnWidth,10)/100:o*parseInt(l.config.plotOptions.bar.columnWidth,10)/100,s=l.globals.gridHeight-this.baseLineY[this.yaxisIndex]-(this.isReversed?l.globals.gridHeight:0)+(this.isReversed?2*this.baseLineY[this.yaxisIndex]:0),t=l.globals.padHorizontal+(i-o)/2),{x:t,y:e,yDivision:a,xDivision:i,barHeight:n,barWidth:o,zeroH:s,zeroW:r}}},{key:"drawStackedBarPaths",value:function(t){for(var e,i=t.indexes,a=t.barHeight,s=t.strokeWidth,r=t.zeroW,n=t.x,o=t.y,l=t.yDivision,c=t.elSeries,h=this.w,d=o,u=i.i,p=i.j,f=0,g=0;g<this.prevXF.length;g++)f+=this.prevXF[g][p];if(u>0){var x=r;this.prevXVal[u-1][p]<0?x=this.series[u][p]>=0?this.prevX[u-1][p]+f-2*(this.isReversed?f:0):this.prevX[u-1][p]:this.prevXVal[u-1][p]>=0&&(x=this.series[u][p]>=0?this.prevX[u-1][p]:this.prevX[u-1][p]-f+2*(this.isReversed?f:0)),e=x}else e=r;n=null===this.series[u][p]?e:e+this.series[u][p]/this.invertedYRatio-2*(this.isReversed?this.series[u][p]/this.invertedYRatio:0);var m=this.barHelpers.getBarpaths({barYPosition:d,barHeight:a,x1:e,x2:n,strokeWidth:s,series:this.series,realIndex:i.realIndex,i:u,j:p,w:h});return this.barHelpers.barBackground({j:p,i:u,y1:d,y2:a,elSeries:c}),o+=l,{pathTo:m.pathTo,pathFrom:m.pathFrom,goalX:this.barHelpers.getGoalValues("x",r,null,u,p),barYPosition:d,x:n,y:o}}},{key:"drawStackedColumnPaths",value:function(t){var e=t.indexes,i=t.x,a=t.y,s=t.xDivision,r=t.barWidth,n=t.zeroH;t.strokeWidth;var o=t.elSeries,l=this.w,c=e.i,h=e.j,d=e.bc;if(l.globals.isXNumeric){var u=l.globals.seriesX[c][h];u||(u=0),i=(u-l.globals.minX)/this.xRatio-r/2}for(var p,f=i,g=0,x=0;x<this.prevYF.length;x++)g+=isNaN(this.prevYF[x][h])?0:this.prevYF[x][h];if(c>0&&!l.globals.isXNumeric||c>0&&l.globals.isXNumeric&&l.globals.seriesX[c-1][h]===l.globals.seriesX[c][h]){var m,b,v=Math.min(this.yRatio.length+1,c+1);if(void 0!==this.prevY[c-1])for(var y=1;y<v;y++)if(!isNaN(this.prevY[c-y][h])){b=this.prevY[c-y][h];break}for(var w=1;w<v;w++){if(this.prevYVal[c-w][h]<0){m=this.series[c][h]>=0?b-g+2*(this.isReversed?g:0):b;break}if(this.prevYVal[c-w][h]>=0){m=this.series[c][h]>=0?b:b+g-2*(this.isReversed?g:0);break}}void 0===m&&(m=l.globals.gridHeight),p=this.prevYF[0].every((function(t){return 0===t}))&&this.prevYF.slice(1,c).every((function(t){return t.every((function(t){return isNaN(t)}))}))?n:m}else p=n;a=p-this.series[c][h]/this.yRatio[this.yaxisIndex]+2*(this.isReversed?this.series[c][h]/this.yRatio[this.yaxisIndex]:0);var k=this.barHelpers.getColumnPaths({barXPosition:f,barWidth:r,y1:p,y2:a,yRatio:this.yRatio[this.yaxisIndex],strokeWidth:this.strokeWidth,series:this.series,realIndex:e.realIndex,i:c,j:h,w:l});return this.barHelpers.barBackground({bc:d,j:h,i:c,x1:f,x2:r,elSeries:o}),i+=s,{pathTo:k.pathTo,pathFrom:k.pathFrom,goalY:this.barHelpers.getGoalValues("y",null,n,c,h),barXPosition:f,x:l.globals.isXNumeric?i-s:i,y:a}}}]),i}(),Ct=function(t){d(i,At);var e=g(i);function i(){return o(this,i),e.apply(this,arguments)}return c(i,[{key:"draw",value:function(t,e){var i=this,a=this.w,s=new k(this.ctx),n=new N(this.ctx);this.candlestickOptions=this.w.config.plotOptions.candlestick,this.boxOptions=this.w.config.plotOptions.boxPlot,this.isHorizontal=a.config.plotOptions.bar.horizontal;var o=new A(this.ctx,a);t=o.getLogSeries(t),this.series=t,this.yRatio=o.getLogYRatios(this.yRatio),this.barHelpers.initVariables(t);for(var l=s.group({class:"apexcharts-".concat(a.config.chart.type,"-series apexcharts-plot-series")}),c=function(o){i.isBoxPlot="boxPlot"===a.config.chart.type||"boxPlot"===a.config.series[o].type;var c,h,d,u,p,f,g=void 0,x=void 0,m=[],b=[],y=a.globals.comboCharts?e[o]:o,w=s.group({class:"apexcharts-series",seriesName:v.escapeString(a.globals.seriesNames[y]),rel:o+1,"data:realIndex":y});i.ctx.series.addCollapsedClassToSeries(w,y),t[o].length>0&&(i.visibleI=i.visibleI+1),i.yRatio.length>1&&(i.yaxisIndex=y);var k=i.barHelpers.initialPositions();x=k.y,p=k.barHeight,h=k.yDivision,u=k.zeroW,g=k.x,f=k.barWidth,c=k.xDivision,d=k.zeroH,b.push(g+f/2);for(var A=s.group({class:"apexcharts-datalabels","data:realIndex":y}),S=function(e){var s=i.barHelpers.getStrokeWidth(o,e,y),l=null,v={indexes:{i:o,j:e,realIndex:y},x:g,y:x,strokeWidth:s,elSeries:w};l=i.isHorizontal?i.drawHorizontalBoxPaths(r(r({},v),{},{yDivision:h,barHeight:p,zeroW:u})):i.drawVerticalBoxPaths(r(r({},v),{},{xDivision:c,barWidth:f,zeroH:d})),x=l.y,g=l.x,e>0&&b.push(g+f/2),m.push(x),l.pathTo.forEach((function(r,c){var h=!i.isBoxPlot&&i.candlestickOptions.wick.useFillColor?l.color[c]:a.globals.stroke.colors[o],d=n.fillPath({seriesNumber:y,dataPointIndex:e,color:l.color[c],value:t[o][e]});i.renderSeries({realIndex:y,pathFill:d,lineFill:h,j:e,i:o,pathFrom:l.pathFrom,pathTo:r,strokeWidth:s,elSeries:w,x:g,y:x,series:t,barHeight:p,barWidth:f,elDataLabelsWrap:A,visibleSeries:i.visibleI,type:a.config.chart.type})}))},C=0;C<a.globals.dataPoints;C++)S(C);a.globals.seriesXvalues[y]=b,a.globals.seriesYvalues[y]=m,l.add(w)},h=0;h<t.length;h++)c(h);return l}},{key:"drawVerticalBoxPaths",value:function(t){var e=t.indexes,i=t.x;t.y;var a=t.xDivision,s=t.barWidth,r=t.zeroH,n=t.strokeWidth,o=this.w,l=new k(this.ctx),c=e.i,h=e.j,d=!0,u=o.config.plotOptions.candlestick.colors.upward,p=o.config.plotOptions.candlestick.colors.downward,f="";this.isBoxPlot&&(f=[this.boxOptions.colors.lower,this.boxOptions.colors.upper]);var g=this.yRatio[this.yaxisIndex],x=e.realIndex,m=this.getOHLCValue(x,h),b=r,v=r;m.o>m.c&&(d=!1);var y=Math.min(m.o,m.c),w=Math.max(m.o,m.c),A=m.m;o.globals.isXNumeric&&(i=(o.globals.seriesX[x][h]-o.globals.minX)/this.xRatio-s/2);var S=i+s*this.visibleI;void 0===this.series[c][h]||null===this.series[c][h]?(y=r,w=r):(y=r-y/g,w=r-w/g,b=r-m.h/g,v=r-m.l/g,A=r-m.m/g);var C=l.move(S,r),P=l.move(S+s/2,y);return o.globals.previousPaths.length>0&&(P=this.getPreviousPath(x,h,!0)),C=this.isBoxPlot?[l.move(S,y)+l.line(S+s/2,y)+l.line(S+s/2,b)+l.line(S+s/4,b)+l.line(S+s-s/4,b)+l.line(S+s/2,b)+l.line(S+s/2,y)+l.line(S+s,y)+l.line(S+s,A)+l.line(S,A)+l.line(S,y+n/2),l.move(S,A)+l.line(S+s,A)+l.line(S+s,w)+l.line(S+s/2,w)+l.line(S+s/2,v)+l.line(S+s-s/4,v)+l.line(S+s/4,v)+l.line(S+s/2,v)+l.line(S+s/2,w)+l.line(S,w)+l.line(S,A)+"z"]:[l.move(S,w)+l.line(S+s/2,w)+l.line(S+s/2,b)+l.line(S+s/2,w)+l.line(S+s,w)+l.line(S+s,y)+l.line(S+s/2,y)+l.line(S+s/2,v)+l.line(S+s/2,y)+l.line(S,y)+l.line(S,w-n/2)],P+=l.move(S,y),o.globals.isXNumeric||(i+=a),{pathTo:C,pathFrom:P,x:i,y:w,barXPosition:S,color:this.isBoxPlot?f:d?[u]:[p]}}},{key:"drawHorizontalBoxPaths",value:function(t){var e=t.indexes;t.x;var i=t.y,a=t.yDivision,s=t.barHeight,r=t.zeroW,n=t.strokeWidth,o=this.w,l=new k(this.ctx),c=e.i,h=e.j,d=this.boxOptions.colors.lower;this.isBoxPlot&&(d=[this.boxOptions.colors.lower,this.boxOptions.colors.upper]);var u=this.invertedYRatio,p=e.realIndex,f=this.getOHLCValue(p,h),g=r,x=r,m=Math.min(f.o,f.c),b=Math.max(f.o,f.c),v=f.m;o.globals.isXNumeric&&(i=(o.globals.seriesX[p][h]-o.globals.minX)/this.invertedXRatio-s/2);var y=i+s*this.visibleI;void 0===this.series[c][h]||null===this.series[c][h]?(m=r,b=r):(m=r+m/u,b=r+b/u,g=r+f.h/u,x=r+f.l/u,v=r+f.m/u);var w=l.move(r,y),A=l.move(m,y+s/2);return o.globals.previousPaths.length>0&&(A=this.getPreviousPath(p,h,!0)),w=[l.move(m,y)+l.line(m,y+s/2)+l.line(g,y+s/2)+l.line(g,y+s/2-s/4)+l.line(g,y+s/2+s/4)+l.line(g,y+s/2)+l.line(m,y+s/2)+l.line(m,y+s)+l.line(v,y+s)+l.line(v,y)+l.line(m+n/2,y),l.move(v,y)+l.line(v,y+s)+l.line(b,y+s)+l.line(b,y+s/2)+l.line(x,y+s/2)+l.line(x,y+s-s/4)+l.line(x,y+s/4)+l.line(x,y+s/2)+l.line(b,y+s/2)+l.line(b,y)+l.line(v,y)+"z"],A+=l.move(m,y),o.globals.isXNumeric||(i+=a),{pathTo:w,pathFrom:A,x:b,y:i,barYPosition:y,color:d}}},{key:"getOHLCValue",value:function(t,e){var i=this.w;return{o:this.isBoxPlot?i.globals.seriesCandleH[t][e]:i.globals.seriesCandleO[t][e],h:this.isBoxPlot?i.globals.seriesCandleO[t][e]:i.globals.seriesCandleH[t][e],m:i.globals.seriesCandleM[t][e],l:this.isBoxPlot?i.globals.seriesCandleC[t][e]:i.globals.seriesCandleL[t][e],c:this.isBoxPlot?i.globals.seriesCandleL[t][e]:i.globals.seriesCandleC[t][e]}}}]),i}(),Pt=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w}return c(t,[{key:"checkColorRange",value:function(){var t=this.w,e=!1,i=t.config.plotOptions[t.config.chart.type];return i.colorScale.ranges.length>0&&i.colorScale.ranges.map((function(t,i){t.from<=0&&(e=!0)})),e}},{key:"getShadeColor",value:function(t,e,i,a){var s=this.w,r=1,n=s.config.plotOptions[t].shadeIntensity,o=this.determineColor(t,e,i);s.globals.hasNegs||a?r=s.config.plotOptions[t].reverseNegativeShade?o.percent<0?o.percent/100*(1.25*n):(1-o.percent/100)*(1.25*n):o.percent<=0?1-(1+o.percent/100)*n:(1-o.percent/100)*n:(r=1-o.percent/100,"treemap"===t&&(r=(1-o.percent/100)*(1.25*n)));var l=o.color,c=new v;return s.config.plotOptions[t].enableShades&&(l="dark"===this.w.config.theme.mode?v.hexToRgba(c.shadeColor(-1*r,o.color),s.config.fill.opacity):v.hexToRgba(c.shadeColor(r,o.color),s.config.fill.opacity)),{color:l,colorProps:o}}},{key:"determineColor",value:function(t,e,i){var a=this.w,s=a.globals.series[e][i],r=a.config.plotOptions[t],n=r.colorScale.inverse?i:e;r.distributed&&"treemap"===a.config.chart.type&&(n=i);var o=a.globals.colors[n],l=null,c=Math.min.apply(Math,x(a.globals.series[e])),h=Math.max.apply(Math,x(a.globals.series[e]));r.distributed||"heatmap"!==t||(c=a.globals.minY,h=a.globals.maxY),void 0!==r.colorScale.min&&(c=r.colorScale.min<a.globals.minY?r.colorScale.min:a.globals.minY,h=r.colorScale.max>a.globals.maxY?r.colorScale.max:a.globals.maxY);var d=Math.abs(h)+Math.abs(c),u=100*s/(0===d?d-1e-6:d);return r.colorScale.ranges.length>0&&r.colorScale.ranges.map((function(t,e){if(s>=t.from&&s<=t.to){o=t.color,l=t.foreColor?t.foreColor:null,c=t.from,h=t.to;var i=Math.abs(h)+Math.abs(c);u=100*s/(0===i?i-1e-6:i)}})),{color:o,foreColor:l,percent:u}}},{key:"calculateDataLabels",value:function(t){var e=t.text,i=t.x,a=t.y,s=t.i,r=t.j,n=t.colorProps,o=t.fontSize,l=this.w.config.dataLabels,c=new k(this.ctx),h=new H(this.ctx),d=null;if(l.enabled){d=c.group({class:"apexcharts-data-labels"});var u=l.offsetX,p=l.offsetY,f=i+u,g=a+parseFloat(l.style.fontSize)/3+p;h.plotDataLabelsText({x:f,y:g,text:e,i:s,j:r,color:n.foreColor,parent:d,fontSize:o,dataLabelsConfig:l})}return d}},{key:"addListeners",value:function(t){var e=new k(this.ctx);t.node.addEventListener("mouseenter",e.pathMouseEnter.bind(this,t)),t.node.addEventListener("mouseleave",e.pathMouseLeave.bind(this,t)),t.node.addEventListener("mousedown",e.pathMouseDown.bind(this,t))}}]),t}(),Lt=function(){function t(e,i){o(this,t),this.ctx=e,this.w=e.w,this.xRatio=i.xRatio,this.yRatio=i.yRatio,this.dynamicAnim=this.w.config.chart.animations.dynamicAnimation,this.helpers=new Pt(e),this.rectRadius=this.w.config.plotOptions.heatmap.radius,this.strokeWidth=this.w.config.stroke.show?this.w.config.stroke.width:0}return c(t,[{key:"draw",value:function(t){var e=this.w,i=new k(this.ctx),a=i.group({class:"apexcharts-heatmap"});a.attr("clip-path","url(#gridRectMask".concat(e.globals.cuid,")"));var s=e.globals.gridWidth/e.globals.dataPoints,r=e.globals.gridHeight/e.globals.series.length,n=0,o=!1;this.negRange=this.helpers.checkColorRange();var l=t.slice();e.config.yaxis[0].reversed&&(o=!0,l.reverse());for(var c=o?0:l.length-1;o?c<l.length:c>=0;o?c++:c--){var h=i.group({class:"apexcharts-series apexcharts-heatmap-series",seriesName:v.escapeString(e.globals.seriesNames[c]),rel:c+1,"data:realIndex":c});if(this.ctx.series.addCollapsedClassToSeries(h,c),e.config.chart.dropShadow.enabled){var d=e.config.chart.dropShadow;new w(this.ctx).dropShadow(h,d,c)}for(var u=0,p=e.config.plotOptions.heatmap.shadeIntensity,f=0;f<l[c].length;f++){var g=this.helpers.getShadeColor(e.config.chart.type,c,f,this.negRange),x=g.color,m=g.colorProps;"image"===e.config.fill.type&&(x=new N(this.ctx).fillPath({seriesNumber:c,dataPointIndex:f,opacity:e.globals.hasNegs?m.percent<0?1-(1+m.percent/100):p+m.percent/100:m.percent/100,patternID:v.randomId(),width:e.config.fill.image.width?e.config.fill.image.width:s,height:e.config.fill.image.height?e.config.fill.image.height:r}));var b=this.rectRadius,y=i.drawRect(u,n,s,r,b);if(y.attr({cx:u,cy:n}),y.node.classList.add("apexcharts-heatmap-rect"),h.add(y),y.attr({fill:x,i:c,index:c,j:f,val:l[c][f],"stroke-width":this.strokeWidth,stroke:e.config.plotOptions.heatmap.useFillColorAsStroke?x:e.globals.stroke.colors[0],color:x}),this.helpers.addListeners(y),e.config.chart.animations.enabled&&!e.globals.dataChanged){var A=1;e.globals.resized||(A=e.config.chart.animations.speed),this.animateHeatMap(y,u,n,s,r,A)}if(e.globals.dataChanged){var S=1;if(this.dynamicAnim.enabled&&e.globals.shouldAnimate){S=this.dynamicAnim.speed;var C=e.globals.previousPaths[c]&&e.globals.previousPaths[c][f]&&e.globals.previousPaths[c][f].color;C||(C="rgba(255, 255, 255, 0)"),this.animateHeatColor(y,v.isColorHex(C)?C:v.rgb2hex(C),v.isColorHex(x)?x:v.rgb2hex(x),S)}}var P=(0,e.config.dataLabels.formatter)(e.globals.series[c][f],{value:e.globals.series[c][f],seriesIndex:c,dataPointIndex:f,w:e}),L=this.helpers.calculateDataLabels({text:P,x:u+s/2,y:n+r/2,i:c,j:f,colorProps:m,series:l});null!==L&&h.add(L),u+=s}n+=r,a.add(h)}var D=e.globals.yAxisScale[0].result.slice();e.config.yaxis[0].reversed?D.unshift(""):D.push(""),e.globals.yAxisScale[0].result=D;var T=e.globals.gridHeight/e.globals.series.length;return e.config.yaxis[0].labels.offsetY=-T/2,a}},{key:"animateHeatMap",value:function(t,e,i,a,s,r){var n=new y(this.ctx);n.animateRect(t,{x:e+a/2,y:i+s/2,width:0,height:0},{x:e,y:i,width:a,height:s},r,(function(){n.animationCompleted(t)}))}},{key:"animateHeatColor",value:function(t,e,i,a){t.attr({fill:e}).animate(a).attr({fill:i})}}]),t}(),Dt=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w}return c(t,[{key:"drawYAxisTexts",value:function(t,e,i,a){var s=this.w,r=s.config.yaxis[0],n=s.globals.yLabelFormatters[0];return new k(this.ctx).drawText({x:t+r.labels.offsetX,y:e+r.labels.offsetY,text:n(a,i),textAnchor:"middle",fontSize:r.labels.style.fontSize,fontFamily:r.labels.style.fontFamily,foreColor:Array.isArray(r.labels.style.colors)?r.labels.style.colors[i]:r.labels.style.colors})}}]),t}(),Tt=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w;var i=this.w;this.chartType=this.w.config.chart.type,this.initialAnim=this.w.config.chart.animations.enabled,this.dynamicAnim=this.initialAnim&&this.w.config.chart.animations.dynamicAnimation.enabled,this.animBeginArr=[0],this.animDur=0,this.donutDataLabels=this.w.config.plotOptions.pie.donut.labels,this.lineColorArr=void 0!==i.globals.stroke.colors?i.globals.stroke.colors:i.globals.colors,this.defaultSize=Math.min(i.globals.gridWidth,i.globals.gridHeight),this.centerY=this.defaultSize/2,this.centerX=i.globals.gridWidth/2,"radialBar"===i.config.chart.type?this.fullAngle=360:this.fullAngle=Math.abs(i.config.plotOptions.pie.endAngle-i.config.plotOptions.pie.startAngle),this.initialAngle=i.config.plotOptions.pie.startAngle%this.fullAngle,i.globals.radialSize=this.defaultSize/2.05-i.config.stroke.width-(i.config.chart.sparkline.enabled?0:i.config.chart.dropShadow.blur),this.donutSize=i.globals.radialSize*parseInt(i.config.plotOptions.pie.donut.size,10)/100,this.maxY=0,this.sliceLabels=[],this.sliceSizes=[],this.prevSectorAngleArr=[]}return c(t,[{key:"draw",value:function(t){var e=this,i=this.w,a=new k(this.ctx);if(this.ret=a.group({class:"apexcharts-pie"}),i.globals.noData)return this.ret;for(var s=0,r=0;r<t.length;r++)s+=v.negToZero(t[r]);var n=[],o=a.group();0===s&&(s=1e-5),t.forEach((function(t){e.maxY=Math.max(e.maxY,t)})),i.config.yaxis[0].max&&(this.maxY=i.config.yaxis[0].max),"back"===i.config.grid.position&&"polarArea"===this.chartType&&this.drawPolarElements(this.ret);for(var l=0;l<t.length;l++){var c=this.fullAngle*v.negToZero(t[l])/s;n.push(c),"polarArea"===this.chartType?(n[l]=this.fullAngle/t.length,this.sliceSizes.push(i.globals.radialSize*t[l]/this.maxY)):this.sliceSizes.push(i.globals.radialSize)}if(i.globals.dataChanged){for(var h,d=0,u=0;u<i.globals.previousPaths.length;u++)d+=v.negToZero(i.globals.previousPaths[u]);for(var p=0;p<i.globals.previousPaths.length;p++)h=this.fullAngle*v.negToZero(i.globals.previousPaths[p])/d,this.prevSectorAngleArr.push(h)}this.donutSize<0&&(this.donutSize=0);var f=i.config.plotOptions.pie.customScale,g=i.globals.gridWidth/2,x=i.globals.gridHeight/2,m=g-i.globals.gridWidth/2*f,b=x-i.globals.gridHeight/2*f;if("donut"===this.chartType){var y=a.drawCircle(this.donutSize);y.attr({cx:this.centerX,cy:this.centerY,fill:i.config.plotOptions.pie.donut.background?i.config.plotOptions.pie.donut.background:"transparent"}),o.add(y)}var w=this.drawArcs(n,t);if(this.sliceLabels.forEach((function(t){w.add(t)})),o.attr({transform:"translate(".concat(m,", ").concat(b,") scale(").concat(f,")")}),o.add(w),this.ret.add(o),this.donutDataLabels.show){var A=this.renderInnerDataLabels(this.donutDataLabels,{hollowSize:this.donutSize,centerX:this.centerX,centerY:this.centerY,opacity:this.donutDataLabels.show,translateX:m,translateY:b});this.ret.add(A)}return"front"===i.config.grid.position&&"polarArea"===this.chartType&&this.drawPolarElements(this.ret),this.ret}},{key:"drawArcs",value:function(t,e){var i=this.w,a=new w(this.ctx),s=new k(this.ctx),r=new N(this.ctx),n=s.group({class:"apexcharts-slices"}),o=this.initialAngle,l=this.initialAngle,c=this.initialAngle,h=this.initialAngle;this.strokeWidth=i.config.stroke.show?i.config.stroke.width:0;for(var d=0;d<t.length;d++){var u=s.group({class:"apexcharts-series apexcharts-pie-series",seriesName:v.escapeString(i.globals.seriesNames[d]),rel:d+1,"data:realIndex":d});n.add(u),l=h,c=(o=c)+t[d],h=l+this.prevSectorAngleArr[d];var p=c<o?this.fullAngle+c-o:c-o,f=r.fillPath({seriesNumber:d,size:this.sliceSizes[d],value:e[d]}),g=this.getChangedPath(l,h),x=s.drawPath({d:g,stroke:Array.isArray(this.lineColorArr)?this.lineColorArr[d]:this.lineColorArr,strokeWidth:0,fill:f,fillOpacity:i.config.fill.opacity,classes:"apexcharts-pie-area apexcharts-".concat(this.chartType.toLowerCase(),"-slice-").concat(d)});if(x.attr({index:0,j:d}),a.setSelectionFilter(x,0,d),i.config.chart.dropShadow.enabled){var m=i.config.chart.dropShadow;a.dropShadow(x,m,d)}this.addListeners(x,this.donutDataLabels),k.setAttrs(x.node,{"data:angle":p,"data:startAngle":o,"data:strokeWidth":this.strokeWidth,"data:value":e[d]});var b={x:0,y:0};"pie"===this.chartType||"polarArea"===this.chartType?b=v.polarToCartesian(this.centerX,this.centerY,i.globals.radialSize/1.25+i.config.plotOptions.pie.dataLabels.offset,(o+p/2)%this.fullAngle):"donut"===this.chartType&&(b=v.polarToCartesian(this.centerX,this.centerY,(i.globals.radialSize+this.donutSize)/2+i.config.plotOptions.pie.dataLabels.offset,(o+p/2)%this.fullAngle)),u.add(x);var y=0;if(!this.initialAnim||i.globals.resized||i.globals.dataChanged?this.animBeginArr.push(0):(0==(y=p/this.fullAngle*i.config.chart.animations.speed)&&(y=1),this.animDur=y+this.animDur,this.animBeginArr.push(this.animDur)),this.dynamicAnim&&i.globals.dataChanged?this.animatePaths(x,{size:this.sliceSizes[d],endAngle:c,startAngle:o,prevStartAngle:l,prevEndAngle:h,animateStartingPos:!0,i:d,animBeginArr:this.animBeginArr,shouldSetPrevPaths:!0,dur:i.config.chart.animations.dynamicAnimation.speed}):this.animatePaths(x,{size:this.sliceSizes[d],endAngle:c,startAngle:o,i:d,totalItems:t.length-1,animBeginArr:this.animBeginArr,dur:y}),i.config.plotOptions.pie.expandOnClick&&"polarArea"!==this.chartType&&x.click(this.pieClicked.bind(this,d)),void 0!==i.globals.selectedDataPoints[0]&&i.globals.selectedDataPoints[0].indexOf(d)>-1&&this.pieClicked(d),i.config.dataLabels.enabled){var A=b.x,S=b.y,C=100*p/this.fullAngle+"%";if(0!==p&&i.config.plotOptions.pie.dataLabels.minAngleToShowLabel<t[d]){var P=i.config.dataLabels.formatter;void 0!==P&&(C=P(i.globals.seriesPercent[d][0],{seriesIndex:d,w:i}));var L=i.globals.dataLabels.style.colors[d],D=s.group({class:"apexcharts-datalabels"}),T=s.drawText({x:A,y:S,text:C,textAnchor:"middle",fontSize:i.config.dataLabels.style.fontSize,fontFamily:i.config.dataLabels.style.fontFamily,fontWeight:i.config.dataLabels.style.fontWeight,foreColor:L});if(D.add(T),i.config.dataLabels.dropShadow.enabled){var M=i.config.dataLabels.dropShadow;a.dropShadow(T,M)}T.node.classList.add("apexcharts-pie-label"),i.config.chart.animations.animate&&!1===i.globals.resized&&(T.node.classList.add("apexcharts-pie-label-delay"),T.node.style.animationDelay=i.config.chart.animations.speed/940+"s"),this.sliceLabels.push(D)}}}return n}},{key:"addListeners",value:function(t,e){var i=new k(this.ctx);t.node.addEventListener("mouseenter",i.pathMouseEnter.bind(this,t)),t.node.addEventListener("mouseleave",i.pathMouseLeave.bind(this,t)),t.node.addEventListener("mouseleave",this.revertDataLabelsInner.bind(this,t.node,e)),t.node.addEventListener("mousedown",i.pathMouseDown.bind(this,t)),this.donutDataLabels.total.showAlways||(t.node.addEventListener("mouseenter",this.printDataLabelsInner.bind(this,t.node,e)),t.node.addEventListener("mousedown",this.printDataLabelsInner.bind(this,t.node,e)))}},{key:"animatePaths",value:function(t,e){var i=this.w,a=e.endAngle<e.startAngle?this.fullAngle+e.endAngle-e.startAngle:e.endAngle-e.startAngle,s=a,r=e.startAngle,n=e.startAngle;void 0!==e.prevStartAngle&&void 0!==e.prevEndAngle&&(r=e.prevEndAngle,s=e.prevEndAngle<e.prevStartAngle?this.fullAngle+e.prevEndAngle-e.prevStartAngle:e.prevEndAngle-e.prevStartAngle),e.i===i.config.series.length-1&&(a+n>this.fullAngle?e.endAngle=e.endAngle-(a+n):a+n<this.fullAngle&&(e.endAngle=e.endAngle+(this.fullAngle-(a+n)))),a===this.fullAngle&&(a=this.fullAngle-.01),this.animateArc(t,r,n,a,s,e)}},{key:"animateArc",value:function(t,e,i,a,s,r){var n,o=this,l=this.w,c=new y(this.ctx),h=r.size;(isNaN(e)||isNaN(s))&&(e=i,s=a,r.dur=0);var d=a,u=i,p=e<i?this.fullAngle+e-i:e-i;l.globals.dataChanged&&r.shouldSetPrevPaths&&r.prevEndAngle&&(n=o.getPiePath({me:o,startAngle:r.prevStartAngle,angle:r.prevEndAngle<r.prevStartAngle?this.fullAngle+r.prevEndAngle-r.prevStartAngle:r.prevEndAngle-r.prevStartAngle,size:h}),t.attr({d:n})),0!==r.dur?t.animate(r.dur,l.globals.easing,r.animBeginArr[r.i]).afterAll((function(){"pie"!==o.chartType&&"donut"!==o.chartType&&"polarArea"!==o.chartType||this.animate(l.config.chart.animations.dynamicAnimation.speed).attr({"stroke-width":o.strokeWidth}),r.i===l.config.series.length-1&&c.animationCompleted(t)})).during((function(l){d=p+(a-p)*l,r.animateStartingPos&&(d=s+(a-s)*l,u=e-s+(i-(e-s))*l),n=o.getPiePath({me:o,startAngle:u,angle:d,size:h}),t.node.setAttribute("data:pathOrig",n),t.attr({d:n})})):(n=o.getPiePath({me:o,startAngle:u,angle:a,size:h}),r.isTrack||(l.globals.animationEnded=!0),t.node.setAttribute("data:pathOrig",n),t.attr({d:n,"stroke-width":o.strokeWidth}))}},{key:"pieClicked",value:function(t){var e,i=this.w,a=this,s=a.sliceSizes[t]+(i.config.plotOptions.pie.expandOnClick?4:0),r=i.globals.dom.Paper.select(".apexcharts-".concat(a.chartType.toLowerCase(),"-slice-").concat(t)).members[0];if("true"!==r.attr("data:pieClicked")){var n=i.globals.dom.baseEl.getElementsByClassName("apexcharts-pie-area");Array.prototype.forEach.call(n,(function(t){t.setAttribute("data:pieClicked","false");var e=t.getAttribute("data:pathOrig");t.setAttribute("d",e)})),r.attr("data:pieClicked","true");var o=parseInt(r.attr("data:startAngle"),10),l=parseInt(r.attr("data:angle"),10);e=a.getPiePath({me:a,startAngle:o,angle:l,size:s}),360!==l&&r.plot(e)}else{r.attr({"data:pieClicked":"false"}),this.revertDataLabelsInner(r.node,this.donutDataLabels);var c=r.attr("data:pathOrig");r.attr({d:c})}}},{key:"getChangedPath",value:function(t,e){var i="";return this.dynamicAnim&&this.w.globals.dataChanged&&(i=this.getPiePath({me:this,startAngle:t,angle:e-t,size:this.size})),i}},{key:"getPiePath",value:function(t){var e=t.me,i=t.startAngle,a=t.angle,s=t.size,r=i,n=Math.PI*(r-90)/180,o=a+i;Math.ceil(o)>=this.fullAngle+this.w.config.plotOptions.pie.startAngle%this.fullAngle&&(o=this.fullAngle+this.w.config.plotOptions.pie.startAngle%this.fullAngle-.01),Math.ceil(o)>this.fullAngle&&(o-=this.fullAngle);var l=Math.PI*(o-90)/180,c=e.centerX+s*Math.cos(n),h=e.centerY+s*Math.sin(n),d=e.centerX+s*Math.cos(l),u=e.centerY+s*Math.sin(l),p=v.polarToCartesian(e.centerX,e.centerY,e.donutSize,o),f=v.polarToCartesian(e.centerX,e.centerY,e.donutSize,r),g=a>180?1:0,x=["M",c,h,"A",s,s,0,g,1,d,u];return"donut"===e.chartType?[].concat(x,["L",p.x,p.y,"A",e.donutSize,e.donutSize,0,g,0,f.x,f.y,"L",c,h,"z"]).join(" "):"pie"===e.chartType||"polarArea"===e.chartType?[].concat(x,["L",e.centerX,e.centerY,"L",c,h]).join(" "):[].concat(x).join(" ")}},{key:"drawPolarElements",value:function(t){var e=this.w,i=new Z(this.ctx),a=new k(this.ctx),s=new Dt(this.ctx),r=a.group(),n=a.group(),o=i.niceScale(0,Math.ceil(this.maxY),e.config.yaxis[0].tickAmount,0,!0),l=o.result.reverse(),c=o.result.length;this.maxY=o.niceMax;for(var h=e.globals.radialSize,d=h/(c-1),u=0;u<c-1;u++){var p=a.drawCircle(h);if(p.attr({cx:this.centerX,cy:this.centerY,fill:"none","stroke-width":e.config.plotOptions.polarArea.rings.strokeWidth,stroke:e.config.plotOptions.polarArea.rings.strokeColor}),e.config.yaxis[0].show){var f=s.drawYAxisTexts(this.centerX,this.centerY-h+parseInt(e.config.yaxis[0].labels.style.fontSize,10)/2,u,l[u]);n.add(f)}r.add(p),h-=d}this.drawSpokes(t),t.add(r),t.add(n)}},{key:"renderInnerDataLabels",value:function(t,e){var i=this.w,a=new k(this.ctx),s=a.group({class:"apexcharts-datalabels-group",transform:"translate(".concat(e.translateX?e.translateX:0,", ").concat(e.translateY?e.translateY:0,") scale(").concat(i.config.plotOptions.pie.customScale,")")}),r=t.total.show;s.node.style.opacity=e.opacity;var n,o,l=e.centerX,c=e.centerY;n=void 0===t.name.color?i.globals.colors[0]:t.name.color;var h=t.name.fontSize,d=t.name.fontFamily,u=t.name.fontWeight;o=void 0===t.value.color?i.config.chart.foreColor:t.value.color;var p=t.value.formatter,f="",g="";if(r?(n=t.total.color,h=t.total.fontSize,d=t.total.fontFamily,u=t.total.fontWeight,g=t.total.label,f=t.total.formatter(i)):1===i.globals.series.length&&(f=p(i.globals.series[0],i),g=i.globals.seriesNames[0]),g&&(g=t.name.formatter(g,t.total.show,i)),t.name.show){var x=a.drawText({x:l,y:c+parseFloat(t.name.offsetY),text:g,textAnchor:"middle",foreColor:n,fontSize:h,fontWeight:u,fontFamily:d});x.node.classList.add("apexcharts-datalabel-label"),s.add(x)}if(t.value.show){var m=t.name.show?parseFloat(t.value.offsetY)+16:t.value.offsetY,b=a.drawText({x:l,y:c+m,text:f,textAnchor:"middle",foreColor:o,fontWeight:t.value.fontWeight,fontSize:t.value.fontSize,fontFamily:t.value.fontFamily});b.node.classList.add("apexcharts-datalabel-value"),s.add(b)}return s}},{key:"printInnerLabels",value:function(t,e,i,a){var s,r=this.w;a?s=void 0===t.name.color?r.globals.colors[parseInt(a.parentNode.getAttribute("rel"),10)-1]:t.name.color:r.globals.series.length>1&&t.total.show&&(s=t.total.color);var n=r.globals.dom.baseEl.querySelector(".apexcharts-datalabel-label"),o=r.globals.dom.baseEl.querySelector(".apexcharts-datalabel-value");i=(0,t.value.formatter)(i,r),a||"function"!=typeof t.total.formatter||(i=t.total.formatter(r));var l=e===t.total.label;e=t.name.formatter(e,l,r),null!==n&&(n.textContent=e),null!==o&&(o.textContent=i),null!==n&&(n.style.fill=s)}},{key:"printDataLabelsInner",value:function(t,e){var i=this.w,a=t.getAttribute("data:value"),s=i.globals.seriesNames[parseInt(t.parentNode.getAttribute("rel"),10)-1];i.globals.series.length>1&&this.printInnerLabels(e,s,a,t);var r=i.globals.dom.baseEl.querySelector(".apexcharts-datalabels-group");null!==r&&(r.style.opacity=1)}},{key:"drawSpokes",value:function(t){var e=this,i=this.w,a=new k(this.ctx),s=i.config.plotOptions.polarArea.spokes;if(0!==s.strokeWidth){for(var r=[],n=360/i.globals.series.length,o=0;o<i.globals.series.length;o++)r.push(v.polarToCartesian(this.centerX,this.centerY,i.globals.radialSize,i.config.plotOptions.pie.startAngle+n*o));r.forEach((function(i,r){var n=a.drawLine(i.x,i.y,e.centerX,e.centerY,Array.isArray(s.connectorColors)?s.connectorColors[r]:s.connectorColors);t.add(n)}))}}},{key:"revertDataLabelsInner",value:function(t,e,i){var a=this,s=this.w,r=s.globals.dom.baseEl.querySelector(".apexcharts-datalabels-group"),n=!1,o=s.globals.dom.baseEl.getElementsByClassName("apexcharts-pie-area"),l=function(t){var i=t.makeSliceOut,s=t.printLabel;Array.prototype.forEach.call(o,(function(t){"true"===t.getAttribute("data:pieClicked")&&(i&&(n=!0),s&&a.printDataLabelsInner(t,e))}))};if(l({makeSliceOut:!0,printLabel:!1}),e.total.show&&s.globals.series.length>1)n&&!e.total.showAlways?l({makeSliceOut:!1,printLabel:!0}):this.printInnerLabels(e,e.total.label,e.total.formatter(s));else if(l({makeSliceOut:!1,printLabel:!0}),!n)if(s.globals.selectedDataPoints.length&&s.globals.series.length>1)if(s.globals.selectedDataPoints[0].length>0){var c=s.globals.selectedDataPoints[0],h=s.globals.dom.baseEl.querySelector(".apexcharts-".concat(this.chartType.toLowerCase(),"-slice-").concat(c));this.printDataLabelsInner(h,e)}else r&&s.globals.selectedDataPoints.length&&0===s.globals.selectedDataPoints[0].length&&(r.style.opacity=0);else r&&s.globals.series.length>1&&(r.style.opacity=0)}}]),t}(),Mt=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w,this.chartType=this.w.config.chart.type,this.initialAnim=this.w.config.chart.animations.enabled,this.dynamicAnim=this.initialAnim&&this.w.config.chart.animations.dynamicAnimation.enabled,this.animDur=0;var i=this.w;this.graphics=new k(this.ctx),this.lineColorArr=void 0!==i.globals.stroke.colors?i.globals.stroke.colors:i.globals.colors,this.defaultSize=i.globals.svgHeight<i.globals.svgWidth?i.globals.gridHeight+1.5*i.globals.goldenPadding:i.globals.gridWidth,this.isLog=i.config.yaxis[0].logarithmic,this.coreUtils=new A(this.ctx),this.maxValue=this.isLog?this.coreUtils.getLogVal(i.globals.maxY,0):i.globals.maxY,this.minValue=this.isLog?this.coreUtils.getLogVal(this.w.globals.minY,0):i.globals.minY,this.polygons=i.config.plotOptions.radar.polygons,this.strokeWidth=i.config.stroke.show?i.config.stroke.width:0,this.size=this.defaultSize/2.1-this.strokeWidth-i.config.chart.dropShadow.blur,i.config.xaxis.labels.show&&(this.size=this.size-i.globals.xAxisLabelsWidth/1.75),void 0!==i.config.plotOptions.radar.size&&(this.size=i.config.plotOptions.radar.size),this.dataRadiusOfPercent=[],this.dataRadius=[],this.angleArr=[],this.yaxisLabelsTextsPos=[]}return c(t,[{key:"draw",value:function(t){var e=this,i=this.w,a=new N(this.ctx),s=[],n=new H(this.ctx);t.length&&(this.dataPointsLen=t[i.globals.maxValsInArrayIndex].length),this.disAngle=2*Math.PI/this.dataPointsLen;var o=i.globals.gridWidth/2,l=i.globals.gridHeight/2,c=o+i.config.plotOptions.radar.offsetX,h=l+i.config.plotOptions.radar.offsetY,d=this.graphics.group({class:"apexcharts-radar-series apexcharts-plot-series",transform:"translate(".concat(c||0,", ").concat(h||0,")")}),u=[],p=null,f=null;if(this.yaxisLabels=this.graphics.group({class:"apexcharts-yaxis"}),t.forEach((function(t,o){var l=t.length===i.globals.dataPoints,c=e.graphics.group().attr({class:"apexcharts-series","data:longestSeries":l,seriesName:v.escapeString(i.globals.seriesNames[o]),rel:o+1,"data:realIndex":o});e.dataRadiusOfPercent[o]=[],e.dataRadius[o]=[],e.angleArr[o]=[],t.forEach((function(t,i){var a=Math.abs(e.maxValue-e.minValue);t+=Math.abs(e.minValue),e.isLog&&(t=e.coreUtils.getLogVal(t,0)),e.dataRadiusOfPercent[o][i]=t/a,e.dataRadius[o][i]=e.dataRadiusOfPercent[o][i]*e.size,e.angleArr[o][i]=i*e.disAngle})),u=e.getDataPointsPos(e.dataRadius[o],e.angleArr[o]);var h=e.createPaths(u,{x:0,y:0});p=e.graphics.group({class:"apexcharts-series-markers-wrap apexcharts-element-hidden"}),f=e.graphics.group({class:"apexcharts-datalabels","data:realIndex":o}),i.globals.delayedElements.push({el:p.node,index:o});var d={i:o,realIndex:o,animationDelay:o,initialSpeed:i.config.chart.animations.speed,dataChangeSpeed:i.config.chart.animations.dynamicAnimation.speed,className:"apexcharts-radar",shouldClipToGrid:!1,bindEventsOnPaths:!1,stroke:i.globals.stroke.colors[o],strokeLineCap:i.config.stroke.lineCap},g=null;i.globals.previousPaths.length>0&&(g=e.getPreviousPath(o));for(var x=0;x<h.linePathsTo.length;x++){var m=e.graphics.renderPaths(r(r({},d),{},{pathFrom:null===g?h.linePathsFrom[x]:g,pathTo:h.linePathsTo[x],strokeWidth:Array.isArray(e.strokeWidth)?e.strokeWidth[o]:e.strokeWidth,fill:"none",drawShadow:!1}));c.add(m);var b=a.fillPath({seriesNumber:o}),y=e.graphics.renderPaths(r(r({},d),{},{pathFrom:null===g?h.areaPathsFrom[x]:g,pathTo:h.areaPathsTo[x],strokeWidth:0,fill:b,drawShadow:!1}));if(i.config.chart.dropShadow.enabled){var k=new w(e.ctx),A=i.config.chart.dropShadow;k.dropShadow(y,Object.assign({},A,{noUserSpaceOnUse:!0}),o)}c.add(y)}t.forEach((function(t,a){var s=new X(e.ctx).getMarkerConfig({cssClass:"apexcharts-marker",seriesIndex:o,dataPointIndex:a}),l=e.graphics.drawMarker(u[a].x,u[a].y,s);l.attr("rel",a),l.attr("j",a),l.attr("index",o),l.node.setAttribute("default-marker-size",s.pSize);var h=e.graphics.group({class:"apexcharts-series-markers"});h&&h.add(l),p.add(h),c.add(p);var d=i.config.dataLabels;if(d.enabled){var g=d.formatter(i.globals.series[o][a],{seriesIndex:o,dataPointIndex:a,w:i});n.plotDataLabelsText({x:u[a].x,y:u[a].y,text:g,textAnchor:"middle",i:o,j:o,parent:f,offsetCorrection:!1,dataLabelsConfig:r({},d)})}c.add(f)})),s.push(c)})),this.drawPolygons({parent:d}),i.config.xaxis.labels.show){var g=this.drawXAxisTexts();d.add(g)}return s.forEach((function(t){d.add(t)})),d.add(this.yaxisLabels),d}},{key:"drawPolygons",value:function(t){for(var e=this,i=this.w,a=t.parent,s=new Dt(this.ctx),r=i.globals.yAxisScale[0].result.reverse(),n=r.length,o=[],l=this.size/(n-1),c=0;c<n;c++)o[c]=l*c;o.reverse();var h=[],d=[];o.forEach((function(t,i){var a=v.getPolygonPos(t,e.dataPointsLen),s="";a.forEach((function(t,a){if(0===i){var r=e.graphics.drawLine(t.x,t.y,0,0,Array.isArray(e.polygons.connectorColors)?e.polygons.connectorColors[a]:e.polygons.connectorColors);d.push(r)}0===a&&e.yaxisLabelsTextsPos.push({x:t.x,y:t.y}),s+=t.x+","+t.y+" "})),h.push(s)})),h.forEach((function(t,s){var r=e.polygons.strokeColors,n=e.polygons.strokeWidth,o=e.graphics.drawPolygon(t,Array.isArray(r)?r[s]:r,Array.isArray(n)?n[s]:n,i.globals.radarPolygons.fill.colors[s]);a.add(o)})),d.forEach((function(t){a.add(t)})),i.config.yaxis[0].show&&this.yaxisLabelsTextsPos.forEach((function(t,i){var a=s.drawYAxisTexts(t.x,t.y,i,r[i]);e.yaxisLabels.add(a)}))}},{key:"drawXAxisTexts",value:function(){var t=this,e=this.w,i=e.config.xaxis.labels,a=this.graphics.group({class:"apexcharts-xaxis"}),s=v.getPolygonPos(this.size,this.dataPointsLen);return e.globals.labels.forEach((function(n,o){var l=e.config.xaxis.labels.formatter,c=new H(t.ctx);if(s[o]){var h=t.getTextPos(s[o],t.size),d=l(n,{seriesIndex:-1,dataPointIndex:o,w:e});c.plotDataLabelsText({x:h.newX,y:h.newY,text:d,textAnchor:h.textAnchor,i:o,j:o,parent:a,color:Array.isArray(i.style.colors)&&i.style.colors[o]?i.style.colors[o]:"#a8a8a8",dataLabelsConfig:r({textAnchor:h.textAnchor,dropShadow:{enabled:!1}},i),offsetCorrection:!1})}})),a}},{key:"createPaths",value:function(t,e){var i=this,a=[],s=[],r=[],n=[];if(t.length){s=[this.graphics.move(e.x,e.y)],n=[this.graphics.move(e.x,e.y)];var o=this.graphics.move(t[0].x,t[0].y),l=this.graphics.move(t[0].x,t[0].y);t.forEach((function(e,a){o+=i.graphics.line(e.x,e.y),l+=i.graphics.line(e.x,e.y),a===t.length-1&&(o+="Z",l+="Z")})),a.push(o),r.push(l)}return{linePathsFrom:s,linePathsTo:a,areaPathsFrom:n,areaPathsTo:r}}},{key:"getTextPos",value:function(t,e){var i="middle",a=t.x,s=t.y;return Math.abs(t.x)>=10?t.x>0?(i="start",a+=10):t.x<0&&(i="end",a-=10):i="middle",Math.abs(t.y)>=e-10&&(t.y<0?s-=10:t.y>0&&(s+=10)),{textAnchor:i,newX:a,newY:s}}},{key:"getPreviousPath",value:function(t){for(var e=this.w,i=null,a=0;a<e.globals.previousPaths.length;a++){var s=e.globals.previousPaths[a];s.paths.length>0&&parseInt(s.realIndex,10)===parseInt(t,10)&&void 0!==e.globals.previousPaths[a].paths[0]&&(i=e.globals.previousPaths[a].paths[0].d)}return i}},{key:"getDataPointsPos",value:function(t,e){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:this.dataPointsLen;t=t||[],e=e||[];for(var a=[],s=0;s<i;s++){var r={};r.x=t[s]*Math.sin(e[s]),r.y=-t[s]*Math.cos(e[s]),a.push(r)}return a}}]),t}(),Et=function(t){d(i,Tt);var e=g(i);function i(t){var a;o(this,i),(a=e.call(this,t)).ctx=t,a.w=t.w,a.animBeginArr=[0],a.animDur=0;var s=a.w;return a.startAngle=s.config.plotOptions.radialBar.startAngle,a.endAngle=s.config.plotOptions.radialBar.endAngle,a.totalAngle=Math.abs(s.config.plotOptions.radialBar.endAngle-s.config.plotOptions.radialBar.startAngle),a.trackStartAngle=s.config.plotOptions.radialBar.track.startAngle,a.trackEndAngle=s.config.plotOptions.radialBar.track.endAngle,a.donutDataLabels=a.w.config.plotOptions.radialBar.dataLabels,a.radialDataLabels=a.donutDataLabels,a.trackStartAngle||(a.trackStartAngle=a.startAngle),a.trackEndAngle||(a.trackEndAngle=a.endAngle),360===a.endAngle&&(a.endAngle=359.99),a.margin=parseInt(s.config.plotOptions.radialBar.track.margin,10),a}return c(i,[{key:"draw",value:function(t){var e=this.w,i=new k(this.ctx),a=i.group({class:"apexcharts-radialbar"});if(e.globals.noData)return a;var s=i.group(),r=this.defaultSize/2,n=e.globals.gridWidth/2,o=this.defaultSize/2.05;e.config.chart.sparkline.enabled||(o=o-e.config.stroke.width-e.config.chart.dropShadow.blur);var l=e.globals.fill.colors;if(e.config.plotOptions.radialBar.track.show){var c=this.drawTracks({size:o,centerX:n,centerY:r,colorArr:l,series:t});s.add(c)}var h=this.drawArcs({size:o,centerX:n,centerY:r,colorArr:l,series:t}),d=360;e.config.plotOptions.radialBar.startAngle<0&&(d=this.totalAngle);var u=(360-d)/360;if(e.globals.radialSize=o-o*u,this.radialDataLabels.value.show){var p=Math.max(this.radialDataLabels.value.offsetY,this.radialDataLabels.name.offsetY);e.globals.radialSize+=p*u}return s.add(h.g),"front"===e.config.plotOptions.radialBar.hollow.position&&(h.g.add(h.elHollow),h.dataLabels&&h.g.add(h.dataLabels)),a.add(s),a}},{key:"drawTracks",value:function(t){var e=this.w,i=new k(this.ctx),a=i.group({class:"apexcharts-tracks"}),s=new w(this.ctx),r=new N(this.ctx),n=this.getStrokeWidth(t);t.size=t.size-n/2;for(var o=0;o<t.series.length;o++){var l=i.group({class:"apexcharts-radialbar-track apexcharts-track"});a.add(l),l.attr({rel:o+1}),t.size=t.size-n-this.margin;var c=e.config.plotOptions.radialBar.track,h=r.fillPath({seriesNumber:0,size:t.size,fillColors:Array.isArray(c.background)?c.background[o]:c.background,solid:!0}),d=this.trackStartAngle,u=this.trackEndAngle;Math.abs(u)+Math.abs(d)>=360&&(u=360-Math.abs(this.startAngle)-.1);var p=i.drawPath({d:"",stroke:h,strokeWidth:n*parseInt(c.strokeWidth,10)/100,fill:"none",strokeOpacity:c.opacity,classes:"apexcharts-radialbar-area"});if(c.dropShadow.enabled){var f=c.dropShadow;s.dropShadow(p,f)}l.add(p),p.attr("id","apexcharts-radialbarTrack-"+o),this.animatePaths(p,{centerX:t.centerX,centerY:t.centerY,endAngle:u,startAngle:d,size:t.size,i:o,totalItems:2,animBeginArr:0,dur:0,isTrack:!0,easing:e.globals.easing})}return a}},{key:"drawArcs",value:function(t){var e=this.w,i=new k(this.ctx),a=new N(this.ctx),s=new w(this.ctx),r=i.group(),n=this.getStrokeWidth(t);t.size=t.size-n/2;var o=e.config.plotOptions.radialBar.hollow.background,l=t.size-n*t.series.length-this.margin*t.series.length-n*parseInt(e.config.plotOptions.radialBar.track.strokeWidth,10)/100/2,c=l-e.config.plotOptions.radialBar.hollow.margin;void 0!==e.config.plotOptions.radialBar.hollow.image&&(o=this.drawHollowImage(t,r,l,o));var h=this.drawHollow({size:c,centerX:t.centerX,centerY:t.centerY,fill:o||"transparent"});if(e.config.plotOptions.radialBar.hollow.dropShadow.enabled){var d=e.config.plotOptions.radialBar.hollow.dropShadow;s.dropShadow(h,d)}var u=1;!this.radialDataLabels.total.show&&e.globals.series.length>1&&(u=0);var p=null;this.radialDataLabels.show&&(p=this.renderInnerDataLabels(this.radialDataLabels,{hollowSize:l,centerX:t.centerX,centerY:t.centerY,opacity:u})),"back"===e.config.plotOptions.radialBar.hollow.position&&(r.add(h),p&&r.add(p));var f=!1;e.config.plotOptions.radialBar.inverseOrder&&(f=!0);for(var g=f?t.series.length-1:0;f?g>=0:g<t.series.length;f?g--:g++){var x=i.group({class:"apexcharts-series apexcharts-radial-series",seriesName:v.escapeString(e.globals.seriesNames[g])});r.add(x),x.attr({rel:g+1,"data:realIndex":g}),this.ctx.series.addCollapsedClassToSeries(x,g),t.size=t.size-n-this.margin;var m=a.fillPath({seriesNumber:g,size:t.size,value:t.series[g]}),b=this.startAngle,y=void 0,A=v.negToZero(t.series[g]>100?100:t.series[g])/100,S=Math.round(this.totalAngle*A)+this.startAngle,C=void 0;e.globals.dataChanged&&(y=this.startAngle,C=Math.round(this.totalAngle*v.negToZero(e.globals.previousPaths[g])/100)+y),Math.abs(S)+Math.abs(b)>=360&&(S-=.01),Math.abs(C)+Math.abs(y)>=360&&(C-=.01);var P=S-b,L=Array.isArray(e.config.stroke.dashArray)?e.config.stroke.dashArray[g]:e.config.stroke.dashArray,D=i.drawPath({d:"",stroke:m,strokeWidth:n,fill:"none",fillOpacity:e.config.fill.opacity,classes:"apexcharts-radialbar-area apexcharts-radialbar-slice-"+g,strokeDashArray:L});if(k.setAttrs(D.node,{"data:angle":P,"data:value":t.series[g]}),e.config.chart.dropShadow.enabled){var T=e.config.chart.dropShadow;s.dropShadow(D,T,g)}s.setSelectionFilter(D,0,g),this.addListeners(D,this.radialDataLabels),x.add(D),D.attr({index:0,j:g});var M=0;!this.initialAnim||e.globals.resized||e.globals.dataChanged||(M=e.config.chart.animations.speed),e.globals.dataChanged&&(M=e.config.chart.animations.dynamicAnimation.speed),this.animDur=M/(1.2*t.series.length)+this.animDur,this.animBeginArr.push(this.animDur),this.animatePaths(D,{centerX:t.centerX,centerY:t.centerY,endAngle:S,startAngle:b,prevEndAngle:C,prevStartAngle:y,size:t.size,i:g,totalItems:2,animBeginArr:this.animBeginArr,dur:M,shouldSetPrevPaths:!0,easing:e.globals.easing})}return{g:r,elHollow:h,dataLabels:p}}},{key:"drawHollow",value:function(t){var e=new k(this.ctx).drawCircle(2*t.size);return e.attr({class:"apexcharts-radialbar-hollow",cx:t.centerX,cy:t.centerY,r:t.size,fill:t.fill}),e}},{key:"drawHollowImage",value:function(t,e,i,a){var s=this.w,r=new N(this.ctx),n=v.randomId(),o=s.config.plotOptions.radialBar.hollow.image;if(s.config.plotOptions.radialBar.hollow.imageClipped)r.clippedImgArea({width:i,height:i,image:o,patternID:"pattern".concat(s.globals.cuid).concat(n)}),a="url(#pattern".concat(s.globals.cuid).concat(n,")");else{var l=s.config.plotOptions.radialBar.hollow.imageWidth,c=s.config.plotOptions.radialBar.hollow.imageHeight;if(void 0===l&&void 0===c){var h=s.globals.dom.Paper.image(o).loaded((function(e){this.move(t.centerX-e.width/2+s.config.plotOptions.radialBar.hollow.imageOffsetX,t.centerY-e.height/2+s.config.plotOptions.radialBar.hollow.imageOffsetY)}));e.add(h)}else{var d=s.globals.dom.Paper.image(o).loaded((function(e){this.move(t.centerX-l/2+s.config.plotOptions.radialBar.hollow.imageOffsetX,t.centerY-c/2+s.config.plotOptions.radialBar.hollow.imageOffsetY),this.size(l,c)}));e.add(d)}}return a}},{key:"getStrokeWidth",value:function(t){var e=this.w;return t.size*(100-parseInt(e.config.plotOptions.radialBar.hollow.size,10))/100/(t.series.length+1)-this.margin}}]),i}(),It=function(t){d(i,At);var e=g(i);function i(){return o(this,i),e.apply(this,arguments)}return c(i,[{key:"draw",value:function(t,e){var i=this.w,a=new k(this.ctx);this.rangeBarOptions=this.w.config.plotOptions.rangeBar,this.series=t,this.seriesRangeStart=i.globals.seriesRangeStart,this.seriesRangeEnd=i.globals.seriesRangeEnd,this.barHelpers.initVariables(t);for(var s=a.group({class:"apexcharts-rangebar-series apexcharts-plot-series"}),n=0;n<t.length;n++){var o,l,c,h=void 0,d=void 0,u=void 0,p=i.globals.comboCharts?e[n]:n,f=a.group({class:"apexcharts-series",seriesName:v.escapeString(i.globals.seriesNames[p]),rel:n+1,"data:realIndex":p});this.ctx.series.addCollapsedClassToSeries(f,p),t[n].length>0&&(this.visibleI=this.visibleI+1);var g=0,x=0;this.yRatio.length>1&&(this.yaxisIndex=p);var m=this.barHelpers.initialPositions();d=m.y,c=m.zeroW,h=m.x,x=m.barWidth,o=m.xDivision,l=m.zeroH;for(var b=a.group({class:"apexcharts-datalabels","data:realIndex":p}),y=a.group({class:"apexcharts-rangebar-goals-markers",style:"pointer-events: none"}),w=0;w<i.globals.dataPoints;w++){var A=this.barHelpers.getStrokeWidth(n,w,p),S=this.seriesRangeStart[n][w],C=this.seriesRangeEnd[n][w],P=null,L=null,D={x:h,y:d,strokeWidth:A,elSeries:f};if(u=m.yDivision,g=m.barHeight,this.isHorizontal){L=d+g*this.visibleI;var T=this.seriesLen;i.config.plotOptions.bar.rangeBarGroupRows&&(T=1);var M=(u-g*T)/2;if(void 0===i.config.series[n].data[w])break;if(i.config.series[n].data[w].x){var E=this.detectOverlappingBars({i:n,j:w,barYPosition:L,srty:M,barHeight:g,yDivision:u,initPositions:m});g=E.barHeight,L=E.barYPosition}x=(P=this.drawRangeBarPaths(r({indexes:{i:n,j:w,realIndex:p},barHeight:g,barYPosition:L,zeroW:c,yDivision:u,y1:S,y2:C},D))).barWidth}else g=(P=this.drawRangeColumnPaths(r({indexes:{i:n,j:w,realIndex:p},zeroH:l,barWidth:x,xDivision:o},D))).barHeight;var I=this.barHelpers.drawGoalLine({barXPosition:P.barXPosition,barYPosition:L,goalX:P.goalX,goalY:P.goalY,barHeight:g,barWidth:x});I&&y.add(I),d=P.y,h=P.x;var O=this.barHelpers.getPathFillColor(t,n,w,p),z=i.globals.stroke.colors[p];this.renderSeries({realIndex:p,pathFill:O,lineFill:z,j:w,i:n,x:h,y:d,y1:S,y2:C,pathFrom:P.pathFrom,pathTo:P.pathTo,strokeWidth:A,elSeries:f,series:t,barHeight:g,barYPosition:L,barWidth:x,elDataLabelsWrap:b,elGoalsMarkers:y,visibleSeries:this.visibleI,type:"rangebar"})}s.add(f)}return s}},{key:"detectOverlappingBars",value:function(t){var e=t.i,i=t.j,a=t.barYPosition,s=t.srty,r=t.barHeight,n=t.yDivision,o=t.initPositions,l=this.w,c=[],h=l.config.series[e].data[i].rangeName,d=l.config.series[e].data[i].x,u=l.globals.labels.indexOf(d),p=l.globals.seriesRange[e].findIndex((function(t){return t.x===d&&t.overlaps.length>0}));return a=l.config.plotOptions.bar.rangeBarGroupRows?s+n*u:s+r*this.visibleI+n*u,p>-1&&!l.config.plotOptions.bar.rangeBarOverlap&&(c=l.globals.seriesRange[e][p].overlaps).indexOf(h)>-1&&(a=(r=o.barHeight/c.length)*this.visibleI+n*(100-parseInt(this.barOptions.barHeight,10))/100/2+r*(this.visibleI+c.indexOf(h))+n*u),{barYPosition:a,barHeight:r}}},{key:"drawRangeColumnPaths",value:function(t){var e=t.indexes,i=t.x;t.strokeWidth;var a=t.xDivision,s=t.barWidth,r=t.zeroH,n=this.w,o=e.i,l=e.j,c=this.yRatio[this.yaxisIndex],h=e.realIndex,d=this.getRangeValue(h,l),u=Math.min(d.start,d.end),p=Math.max(d.start,d.end);n.globals.isXNumeric&&(i=(n.globals.seriesX[o][l]-n.globals.minX)/this.xRatio-s/2);var f=i+s*this.visibleI;void 0===this.series[o][l]||null===this.series[o][l]?u=r:(u=r-u/c,p=r-p/c);var g=Math.abs(p-u),x=this.barHelpers.getColumnPaths({barXPosition:f,barWidth:s,y1:u,y2:p,strokeWidth:this.strokeWidth,series:this.seriesRangeEnd,realIndex:e.realIndex,i:h,j:l,w:n});return n.globals.isXNumeric||(i+=a),{pathTo:x.pathTo,pathFrom:x.pathFrom,barHeight:g,x:i,y:p,goalY:this.barHelpers.getGoalValues("y",null,r,o,l),barXPosition:f}}},{key:"drawRangeBarPaths",value:function(t){var e=t.indexes,i=t.y,a=t.y1,s=t.y2,r=t.yDivision,n=t.barHeight,o=t.barYPosition,l=t.zeroW,c=this.w,h=l+a/this.invertedYRatio,d=l+s/this.invertedYRatio,u=Math.abs(d-h),p=this.barHelpers.getBarpaths({barYPosition:o,barHeight:n,x1:h,x2:d,strokeWidth:this.strokeWidth,series:this.seriesRangeEnd,i:e.realIndex,realIndex:e.realIndex,j:e.j,w:c});return c.globals.isXNumeric||(i+=r),{pathTo:p.pathTo,pathFrom:p.pathFrom,barWidth:u,x:d,goalX:this.barHelpers.getGoalValues("x",l,null,e.realIndex,e.j),y:i}}},{key:"getRangeValue",value:function(t,e){var i=this.w;return{start:i.globals.seriesRangeStart[t][e],end:i.globals.seriesRangeEnd[t][e]}}}]),i}(),Ot=function(){function t(e){o(this,t),this.w=e.w,this.lineCtx=e}return c(t,[{key:"sameValueSeriesFix",value:function(t,e){var i=this.w;if(("gradient"===i.config.fill.type||"gradient"===i.config.fill.type[t])&&new A(this.lineCtx.ctx,i).seriesHaveSameValues(t)){var a=e[t].slice();a[a.length-1]=a[a.length-1]+1e-6,e[t]=a}return e}},{key:"calculatePoints",value:function(t){var e=t.series,i=t.realIndex,a=t.x,s=t.y,r=t.i,n=t.j,o=t.prevY,l=this.w,c=[],h=[];if(0===n){var d=this.lineCtx.categoryAxisCorrection+l.config.markers.offsetX;l.globals.isXNumeric&&(d=(l.globals.seriesX[i][0]-l.globals.minX)/this.lineCtx.xRatio+l.config.markers.offsetX),c.push(d),h.push(v.isNumber(e[r][0])?o+l.config.markers.offsetY:null),c.push(a+l.config.markers.offsetX),h.push(v.isNumber(e[r][n+1])?s+l.config.markers.offsetY:null)}else c.push(a+l.config.markers.offsetX),h.push(v.isNumber(e[r][n+1])?s+l.config.markers.offsetY:null);return{x:c,y:h}}},{key:"checkPreviousPaths",value:function(t){for(var e=t.pathFromLine,i=t.pathFromArea,a=t.realIndex,s=this.w,r=0;r<s.globals.previousPaths.length;r++){var n=s.globals.previousPaths[r];("line"===n.type||"area"===n.type)&&n.paths.length>0&&parseInt(n.realIndex,10)===parseInt(a,10)&&("line"===n.type?(this.lineCtx.appendPathFrom=!1,e=s.globals.previousPaths[r].paths[0].d):"area"===n.type&&(this.lineCtx.appendPathFrom=!1,i=s.globals.previousPaths[r].paths[0].d,s.config.stroke.show&&s.globals.previousPaths[r].paths[1]&&(e=s.globals.previousPaths[r].paths[1].d)))}return{pathFromLine:e,pathFromArea:i}}},{key:"determineFirstPrevY",value:function(t){var e,i=t.i,a=t.series,s=t.prevY,r=t.lineYPosition,n=this.w;if(void 0!==(null===(e=a[i])||void 0===e?void 0:e[0]))s=(r=n.config.chart.stacked&&i>0?this.lineCtx.prevSeriesY[i-1][0]:this.lineCtx.zeroY)-a[i][0]/this.lineCtx.yRatio[this.lineCtx.yaxisIndex]+2*(this.lineCtx.isReversed?a[i][0]/this.lineCtx.yRatio[this.lineCtx.yaxisIndex]:0);else if(n.config.chart.stacked&&i>0&&void 0===a[i][0])for(var o=i-1;o>=0;o--)if(null!==a[o][0]&&void 0!==a[o][0]){s=r=this.lineCtx.prevSeriesY[o][0];break}return{prevY:s,lineYPosition:r}}}]),t}(),zt=function(){function t(e,i,a){o(this,t),this.ctx=e,this.w=e.w,this.xyRatios=i,this.pointsChart=!("bubble"!==this.w.config.chart.type&&"scatter"!==this.w.config.chart.type)||a,this.scatter=new _(this.ctx),this.noNegatives=this.w.globals.minX===Number.MAX_VALUE,this.lineHelpers=new Ot(this),this.markers=new X(this.ctx),this.prevSeriesY=[],this.categoryAxisCorrection=0,this.yaxisIndex=0}return c(t,[{key:"draw",value:function(t,e,i,a){var s=this.w,n=new k(this.ctx),o=s.globals.comboCharts?e:s.config.chart.type,l=n.group({class:"apexcharts-".concat(o,"-series apexcharts-plot-series")}),c=new A(this.ctx,s);this.yRatio=this.xyRatios.yRatio,this.zRatio=this.xyRatios.zRatio,this.xRatio=this.xyRatios.xRatio,this.baseLineY=this.xyRatios.baseLineY,t=c.getLogSeries(t),this.yRatio=c.getLogYRatios(this.yRatio);for(var h=[],d=0;d<t.length;d++){t=this.lineHelpers.sameValueSeriesFix(d,t);var u=s.globals.comboCharts?i[d]:d;this._initSerieVariables(t,d,u);var p=[],f=[],g=s.globals.padHorizontal+this.categoryAxisCorrection;this.ctx.series.addCollapsedClassToSeries(this.elSeries,u),s.globals.isXNumeric&&s.globals.seriesX.length>0&&(g=(s.globals.seriesX[u][0]-s.globals.minX)/this.xRatio),f.push(g);var x,m=g,b=void 0,v=m,y=this.zeroY,w=this.zeroY;y=this.lineHelpers.determineFirstPrevY({i:d,series:t,prevY:y,lineYPosition:0}).prevY,p.push(y),x=y,"rangeArea"===o&&(b=w=this.lineHelpers.determineFirstPrevY({i:d,series:a,prevY:w,lineYPosition:0}).prevY);var S={type:o,series:t,realIndex:u,i:d,x:g,y:1,pX:m,pY:x,pathsFrom:this._calculatePathsFrom({type:o,series:t,i:d,realIndex:u,prevX:v,prevY:y,prevY2:w}),linePaths:[],areaPaths:[],seriesIndex:i,lineYPosition:0,xArrj:f,yArrj:p,seriesRangeEnd:a},C=this._iterateOverDataPoints(r(r({},S),{},{iterations:"rangeArea"===o?t[d].length-1:void 0,isRangeStart:!0}));if("rangeArea"===o){var P=this._calculatePathsFrom({series:a,i:d,realIndex:u,prevX:v,prevY:w}),L=this._iterateOverDataPoints(r(r({},S),{},{series:a,pY:b,pathsFrom:P,iterations:a[d].length-1,isRangeStart:!1}));C.linePaths[0]=L.linePath+C.linePath,C.pathFromLine=L.pathFromLine+C.pathFromLine}this._handlePaths({type:o,realIndex:u,i:d,paths:C}),this.elSeries.add(this.elPointsMain),this.elSeries.add(this.elDataLabelsWrap),h.push(this.elSeries)}if(s.config.chart.stacked)for(var D=h.length;D>0;D--)l.add(h[D-1]);else for(var T=0;T<h.length;T++)l.add(h[T]);return l}},{key:"_initSerieVariables",value:function(t,e,i){var a=this.w,s=new k(this.ctx);this.xDivision=a.globals.gridWidth/(a.globals.dataPoints-("on"===a.config.xaxis.tickPlacement?1:0)),this.strokeWidth=Array.isArray(a.config.stroke.width)?a.config.stroke.width[i]:a.config.stroke.width,this.yRatio.length>1&&(this.yaxisIndex=i),this.isReversed=a.config.yaxis[this.yaxisIndex]&&a.config.yaxis[this.yaxisIndex].reversed,this.zeroY=a.globals.gridHeight-this.baseLineY[this.yaxisIndex]-(this.isReversed?a.globals.gridHeight:0)+(this.isReversed?2*this.baseLineY[this.yaxisIndex]:0),this.areaBottomY=this.zeroY,(this.zeroY>a.globals.gridHeight||"end"===a.config.plotOptions.area.fillTo)&&(this.areaBottomY=a.globals.gridHeight),this.categoryAxisCorrection=this.xDivision/2,this.elSeries=s.group({class:"apexcharts-series",seriesName:v.escapeString(a.globals.seriesNames[i])}),this.elPointsMain=s.group({class:"apexcharts-series-markers-wrap","data:realIndex":i}),this.elDataLabelsWrap=s.group({class:"apexcharts-datalabels","data:realIndex":i});var r=t[e].length===a.globals.dataPoints;this.elSeries.attr({"data:longestSeries":r,rel:e+1,"data:realIndex":i}),this.appendPathFrom=!0}},{key:"_calculatePathsFrom",value:function(t){var e,i,a,s,r=t.type,n=t.series,o=t.i,l=t.realIndex,c=t.prevX,h=t.prevY,d=t.prevY2,u=this.w,p=new k(this.ctx);if(null===n[o][0]){for(var f=0;f<n[o].length;f++)if(null!==n[o][f]){c=this.xDivision*f,h=this.zeroY-n[o][f]/this.yRatio[this.yaxisIndex],e=p.move(c,h),i=p.move(c,this.areaBottomY);break}}else e=p.move(c,h),"rangeArea"===r&&(e=p.move(c,d)+p.line(c,h)),i=p.move(c,this.areaBottomY)+p.line(c,h);if(a=p.move(-1,this.zeroY)+p.line(-1,this.zeroY),s=p.move(-1,this.zeroY)+p.line(-1,this.zeroY),u.globals.previousPaths.length>0){var g=this.lineHelpers.checkPreviousPaths({pathFromLine:a,pathFromArea:s,realIndex:l});a=g.pathFromLine,s=g.pathFromArea}return{prevX:c,prevY:h,linePath:e,areaPath:i,pathFromLine:a,pathFromArea:s}}},{key:"_handlePaths",value:function(t){var e=t.type,i=t.realIndex,a=t.i,s=t.paths,n=this.w,o=new k(this.ctx),l=new N(this.ctx);this.prevSeriesY.push(s.yArrj),n.globals.seriesXvalues[i]=s.xArrj,n.globals.seriesYvalues[i]=s.yArrj;var c=n.config.forecastDataPoints;if(c.count>0&&"rangeArea"!==e){var h=n.globals.seriesXvalues[i][n.globals.seriesXvalues[i].length-c.count-1],d=o.drawRect(h,0,n.globals.gridWidth,n.globals.gridHeight,0);n.globals.dom.elForecastMask.appendChild(d.node);var u=o.drawRect(0,0,h,n.globals.gridHeight,0);n.globals.dom.elNonForecastMask.appendChild(u.node)}this.pointsChart||n.globals.delayedElements.push({el:this.elPointsMain.node,index:i});var p={i:a,realIndex:i,animationDelay:a,initialSpeed:n.config.chart.animations.speed,dataChangeSpeed:n.config.chart.animations.dynamicAnimation.speed,className:"apexcharts-".concat(e)};if("area"===e)for(var f=l.fillPath({seriesNumber:i}),g=0;g<s.areaPaths.length;g++){var x=o.renderPaths(r(r({},p),{},{pathFrom:s.pathFromArea,pathTo:s.areaPaths[g],stroke:"none",strokeWidth:0,strokeLineCap:null,fill:f}));this.elSeries.add(x)}if(n.config.stroke.show&&!this.pointsChart){var m=null;if("line"===e)m=l.fillPath({seriesNumber:i,i:a});else if("solid"===n.config.stroke.fill.type)m=n.globals.stroke.colors[i];else{var b=n.config.fill;n.config.fill=n.config.stroke.fill,m=l.fillPath({seriesNumber:i,i:a}),n.config.fill=b}for(var v=0;v<s.linePaths.length;v++){var y=m;"rangeArea"===e&&(y=l.fillPath({seriesNumber:i}));var w=r(r({},p),{},{pathFrom:s.pathFromLine,pathTo:s.linePaths[v],stroke:m,strokeWidth:this.strokeWidth,strokeLineCap:n.config.stroke.lineCap,fill:"rangeArea"===e?y:"none"}),A=o.renderPaths(w);if(this.elSeries.add(A),A.attr("fill-rule","evenodd"),c.count>0&&"rangeArea"!==e){var S=o.renderPaths(w);S.node.setAttribute("stroke-dasharray",c.dashArray),c.strokeWidth&&S.node.setAttribute("stroke-width",c.strokeWidth),this.elSeries.add(S),S.attr("clip-path","url(#forecastMask".concat(n.globals.cuid,")")),A.attr("clip-path","url(#nonForecastMask".concat(n.globals.cuid,")"))}}}}},{key:"_iterateOverDataPoints",value:function(t){var e=t.type,i=t.series,a=t.iterations,s=t.realIndex,r=t.i,n=t.x,o=t.y,l=t.pX,c=t.pY,h=t.pathsFrom,d=t.linePaths,u=t.areaPaths,p=t.seriesIndex,f=t.lineYPosition,g=t.xArrj,x=t.yArrj,m=t.isRangeStart,b=t.seriesRangeEnd,y=this.w,w=new k(this.ctx),A=this.yRatio,S=h.prevY,C=h.linePath,P=h.areaPath,L=h.pathFromLine,D=h.pathFromArea,T=v.isNumber(y.globals.minYArr[s])?y.globals.minYArr[s]:y.globals.minY;a||(a=y.globals.dataPoints>1?y.globals.dataPoints-1:y.globals.dataPoints);for(var M=o,E=0;E<a;E++){var I=void 0===i[r][E+1]||null===i[r][E+1];if(y.globals.isXNumeric){var O=y.globals.seriesX[s][E+1];void 0===y.globals.seriesX[s][E+1]&&(O=y.globals.seriesX[s][a-1]),n=(O-y.globals.minX)/this.xRatio}else n+=this.xDivision;f=y.config.chart.stacked&&r>0&&y.globals.collapsedSeries.length<y.config.series.length-1?this.prevSeriesY[function(t){for(var e=t,i=0;i<y.globals.series.length;i++)if(y.globals.collapsedSeriesIndices.indexOf(t)>-1){e--;break}return e>=0?e:0}(r-1)][E+1]:this.zeroY,I?o=f-T/A[this.yaxisIndex]+2*(this.isReversed?T/A[this.yaxisIndex]:0):(o=f-i[r][E+1]/A[this.yaxisIndex]+2*(this.isReversed?i[r][E+1]/A[this.yaxisIndex]:0),"rangeArea"===e&&(M=f-b[r][E+1]/A[this.yaxisIndex]+2*(this.isReversed?b[r][E+1]/A[this.yaxisIndex]:0))),g.push(n),x.push(o);var z=this.lineHelpers.calculatePoints({series:i,x:n,y:o,realIndex:s,i:r,j:E,prevY:S}),R=this._createPaths({type:e,series:i,i:r,realIndex:s,j:E,x:n,y:o,y2:M,pX:l,pY:c,linePath:C,areaPath:P,linePaths:d,areaPaths:u,seriesIndex:p,isRangeStart:m});u=R.areaPaths,d=R.linePaths,l=R.pX,c=R.pY,P=R.areaPath,C=R.linePath,this.appendPathFrom&&(L+=w.line(n,this.zeroY),D+=w.line(n,this.zeroY)),this.handleNullDataPoints(i,z,r,E,s),this._handleMarkersAndLabels({type:e,pointsPos:z,i:r,j:E,realIndex:s,isRangeStart:m})}return{yArrj:x,xArrj:g,pathFromArea:D,areaPaths:u,pathFromLine:L,linePaths:d,linePath:C,areaPath:P}}},{key:"_handleMarkersAndLabels",value:function(t){var e=t.type,i=t.pointsPos,a=t.isRangeStart,s=t.i,r=t.j,n=t.realIndex,o=this.w,l=new H(this.ctx);if(this.pointsChart)this.scatter.draw(this.elSeries,r,{realIndex:n,pointsPos:i,zRatio:this.zRatio,elParent:this.elPointsMain});else{o.globals.series[s].length>1&&this.elPointsMain.node.classList.add("apexcharts-element-hidden");var c=this.markers.plotChartMarkers(i,n,r+1);null!==c&&this.elPointsMain.add(c)}var h=l.drawDataLabel({type:e,isRangeStart:a,pos:i,i:n,j:r+1});null!==h&&this.elDataLabelsWrap.add(h)}},{key:"_createPaths",value:function(t){var e=t.type,i=t.series,a=t.i,s=t.realIndex,r=t.j,n=t.x,o=t.y,l=t.y2,c=t.pX,h=t.pY,d=t.linePath,u=t.areaPath,p=t.linePaths,f=t.areaPaths,g=t.seriesIndex,x=t.isRangeStart,m=this.w,b=new k(this.ctx),v=m.config.stroke.curve,y=this.areaBottomY;if(Array.isArray(m.config.stroke.curve)&&(v=Array.isArray(g)?m.config.stroke.curve[g[a]]:m.config.stroke.curve[a]),"smooth"===v){var w=.35*(n-c);m.globals.hasNullValues?(null!==i[a][r]&&(null!==i[a][r+1]?(d=b.move(c,h)+b.curve(c+w,h,n-w,o,n+1,o),u=b.move(c+1,h)+b.curve(c+w,h,n-w,o,n+1,o)+b.line(n,y)+b.line(c,y)+"z"):(d=b.move(c,h),u=b.move(c,h)+"z")),p.push(d),f.push(u)):(d+=b.curve(c+w,h,n-w,o,n,o),u+=b.curve(c+w,h,n-w,o,n,o)),c=n,h=o,r===i[a].length-2&&(u=u+b.curve(c,h,n,o,n,y)+b.move(n,o)+"z","rangeArea"===e&&x?d=d+b.curve(c,h,n,o,n,l)+b.move(n,l)+"z":m.globals.hasNullValues||(p.push(d),f.push(u)))}else{if(null===i[a][r+1]){d+=b.move(n,o);var A=m.globals.isXNumeric?(m.globals.seriesX[s][r]-m.globals.minX)/this.xRatio:n-this.xDivision;u=u+b.line(A,y)+b.move(n,o)+"z"}null===i[a][r]&&(d+=b.move(n,o),u+=b.move(n,y)),"stepline"===v?(d=d+b.line(n,null,"H")+b.line(null,o,"V"),u=u+b.line(n,null,"H")+b.line(null,o,"V")):"straight"===v&&(d+=b.line(n,o),u+=b.line(n,o)),r===i[a].length-2&&(u=u+b.line(n,y)+b.move(n,o)+"z","rangeArea"===e&&x?d=d+b.line(n,l)+b.move(n,l)+"z":(p.push(d),f.push(u)))}return{linePaths:p,areaPaths:f,pX:c,pY:h,linePath:d,areaPath:u}}},{key:"handleNullDataPoints",value:function(t,e,i,a,s){var r=this.w;if(null===t[i][a]&&r.config.markers.showNullDataPoints||1===t[i].length){var n=this.markers.plotChartMarkers(e,s,a+1,this.strokeWidth-r.config.markers.strokeWidth/2,!0);null!==n&&this.elPointsMain.add(n)}}}]),t}();window.TreemapSquared={},window.TreemapSquared.generate=function(){function t(e,i,a,s){this.xoffset=e,this.yoffset=i,this.height=s,this.width=a,this.shortestEdge=function(){return Math.min(this.height,this.width)},this.getCoordinates=function(t){var e,i=[],a=this.xoffset,s=this.yoffset,n=r(t)/this.height,o=r(t)/this.width;if(this.width>=this.height)for(e=0;e<t.length;e++)i.push([a,s,a+n,s+t[e]/n]),s+=t[e]/n;else for(e=0;e<t.length;e++)i.push([a,s,a+t[e]/o,s+o]),a+=t[e]/o;return i},this.cutArea=function(e){var i;if(this.width>=this.height){var a=e/this.height,s=this.width-a;i=new t(this.xoffset+a,this.yoffset,s,this.height)}else{var r=e/this.width,n=this.height-r;i=new t(this.xoffset,this.yoffset+r,this.width,n)}return i}}function e(e,a,s,n,o){n=void 0===n?0:n,o=void 0===o?0:o;var l=i(function(t,e){var i,a=[],s=e/r(t);for(i=0;i<t.length;i++)a[i]=t[i]*s;return a}(e,a*s),[],new t(n,o,a,s),[]);return function(t){var e,i,a=[];for(e=0;e<t.length;e++)for(i=0;i<t[e].length;i++)a.push(t[e][i]);return a}(l)}function i(t,e,s,n){var o,l,c;if(0!==t.length)return o=s.shortestEdge(),function(t,e,i){var s;return 0===t.length||((s=t.slice()).push(e),a(t,i)>=a(s,i))}(e,l=t[0],o)?(e.push(l),i(t.slice(1),e,s,n)):(c=s.cutArea(r(e),n),n.push(s.getCoordinates(e)),i(t,[],c,n)),n;n.push(s.getCoordinates(e))}function a(t,e){var i=Math.min.apply(Math,t),a=Math.max.apply(Math,t),s=r(t);return Math.max(Math.pow(e,2)*a/Math.pow(s,2),Math.pow(s,2)/(Math.pow(e,2)*i))}function s(t){return t&&t.constructor===Array}function r(t){var e,i=0;for(e=0;e<t.length;e++)i+=t[e];return i}function n(t){var e,i=0;if(s(t[0]))for(e=0;e<t.length;e++)i+=n(t[e]);else i=r(t);return i}return function t(i,a,r,o,l){o=void 0===o?0:o,l=void 0===l?0:l;var c,h,d=[],u=[];if(s(i[0])){for(h=0;h<i.length;h++)d[h]=n(i[h]);for(c=e(d,a,r,o,l),h=0;h<i.length;h++)u.push(t(i[h],c[h][2]-c[h][0],c[h][3]-c[h][1],c[h][0],c[h][1]))}else u=e(i,a,r,o,l);return u}}();var Rt,Yt,Ft=function(){function t(e,i){o(this,t),this.ctx=e,this.w=e.w,this.strokeWidth=this.w.config.stroke.width,this.helpers=new Pt(e),this.dynamicAnim=this.w.config.chart.animations.dynamicAnimation,this.labels=[]}return c(t,[{key:"draw",value:function(t){var e=this,i=this.w,a=new k(this.ctx),s=new N(this.ctx),r=a.group({class:"apexcharts-treemap"});if(i.globals.noData)return r;var n=[];return t.forEach((function(t){var e=t.map((function(t){return Math.abs(t)}));n.push(e)})),this.negRange=this.helpers.checkColorRange(),i.config.series.forEach((function(t,i){t.data.forEach((function(t){Array.isArray(e.labels[i])||(e.labels[i]=[]),e.labels[i].push(t.x)}))})),window.TreemapSquared.generate(n,i.globals.gridWidth,i.globals.gridHeight).forEach((function(n,o){var l=a.group({class:"apexcharts-series apexcharts-treemap-series",seriesName:v.escapeString(i.globals.seriesNames[o]),rel:o+1,"data:realIndex":o});if(i.config.chart.dropShadow.enabled){var c=i.config.chart.dropShadow;new w(e.ctx).dropShadow(r,c,o)}var h=a.group({class:"apexcharts-data-labels"});n.forEach((function(r,n){var c=r[0],h=r[1],d=r[2],u=r[3],p=a.drawRect(c,h,d-c,u-h,0,"#fff",1,e.strokeWidth,i.config.plotOptions.treemap.useFillColorAsStroke?g:i.globals.stroke.colors[o]);p.attr({cx:c,cy:h,index:o,i:o,j:n,width:d-c,height:u-h});var f=e.helpers.getShadeColor(i.config.chart.type,o,n,e.negRange),g=f.color;void 0!==i.config.series[o].data[n]&&i.config.series[o].data[n].fillColor&&(g=i.config.series[o].data[n].fillColor);var x=s.fillPath({color:g,seriesNumber:o,dataPointIndex:n});p.node.classList.add("apexcharts-treemap-rect"),p.attr({fill:x}),e.helpers.addListeners(p);var m={x:c+(d-c)/2,y:h+(u-h)/2,width:0,height:0},b={x:c,y:h,width:d-c,height:u-h};if(i.config.chart.animations.enabled&&!i.globals.dataChanged){var v=1;i.globals.resized||(v=i.config.chart.animations.speed),e.animateTreemap(p,m,b,v)}if(i.globals.dataChanged){var y=1;e.dynamicAnim.enabled&&i.globals.shouldAnimate&&(y=e.dynamicAnim.speed,i.globals.previousPaths[o]&&i.globals.previousPaths[o][n]&&i.globals.previousPaths[o][n].rect&&(m=i.globals.previousPaths[o][n].rect),e.animateTreemap(p,m,b,y))}var w=e.getFontSize(r),k=i.config.dataLabels.formatter(e.labels[o][n],{value:i.globals.series[o][n],seriesIndex:o,dataPointIndex:n,w:i}),A=e.helpers.calculateDataLabels({text:k,x:(c+d)/2,y:(h+u)/2+e.strokeWidth/2+w/3,i:o,j:n,colorProps:f,fontSize:w,series:t});i.config.dataLabels.enabled&&A&&e.rotateToFitLabel(A,w,k,c,h,d,u),l.add(p),null!==A&&l.add(A)})),l.add(h),r.add(l)})),r}},{key:"getFontSize",value:function(t){var e,i,a=this.w,s=function t(e){var i,a=0;if(Array.isArray(e[0]))for(i=0;i<e.length;i++)a+=t(e[i]);else for(i=0;i<e.length;i++)a+=e[i].length;return a}(this.labels)/function t(e){var i,a=0;if(Array.isArray(e[0]))for(i=0;i<e.length;i++)a+=t(e[i]);else for(i=0;i<e.length;i++)a+=1;return a}(this.labels);return e=(t[2]-t[0])*(t[3]-t[1]),i=Math.pow(e,.5),Math.min(i/s,parseInt(a.config.dataLabels.style.fontSize,10))}},{key:"rotateToFitLabel",value:function(t,e,i,a,s,r,n){var o=new k(this.ctx),l=o.getTextRects(i,e);if(l.width+this.w.config.stroke.width+5>r-a&&l.width<=n-s){var c=o.rotateAroundCenter(t.node);t.node.setAttribute("transform","rotate(-90 ".concat(c.x," ").concat(c.y,")"))}}},{key:"animateTreemap",value:function(t,e,i,a){var s=new y(this.ctx);s.animateRect(t,{x:e.x,y:e.y,width:e.width,height:e.height},{x:i.x,y:i.y,width:i.width,height:i.height},a,(function(){s.animationCompleted(t)}))}}]),t}(),Nt=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w,this.timeScaleArray=[],this.utc=this.w.config.xaxis.labels.datetimeUTC}return c(t,[{key:"calculateTimeScaleTicks",value:function(t,e){var i=this,a=this.w;if(a.globals.allSeriesCollapsed)return a.globals.labels=[],a.globals.timescaleLabels=[],[];var s=new E(this.ctx),n=(e-t)/864e5;this.determineInterval(n),a.globals.disableZoomIn=!1,a.globals.disableZoomOut=!1,n<.00011574074074074075?a.globals.disableZoomIn=!0:n>5e4&&(a.globals.disableZoomOut=!0);var o=s.getTimeUnitsfromTimestamp(t,e,this.utc),l=a.globals.gridWidth/n,c=l/24,h=c/60,d=h/60,u=Math.floor(24*n),p=Math.floor(1440*n),f=Math.floor(86400*n),g=Math.floor(n),x=Math.floor(n/30),m=Math.floor(n/365),b={minMillisecond:o.minMillisecond,minSecond:o.minSecond,minMinute:o.minMinute,minHour:o.minHour,minDate:o.minDate,minMonth:o.minMonth,minYear:o.minYear},v={firstVal:b,currentMillisecond:b.minMillisecond,currentSecond:b.minSecond,currentMinute:b.minMinute,currentHour:b.minHour,currentMonthDate:b.minDate,currentDate:b.minDate,currentMonth:b.minMonth,currentYear:b.minYear,daysWidthOnXAxis:l,hoursWidthOnXAxis:c,minutesWidthOnXAxis:h,secondsWidthOnXAxis:d,numberOfSeconds:f,numberOfMinutes:p,numberOfHours:u,numberOfDays:g,numberOfMonths:x,numberOfYears:m};switch(this.tickInterval){case"years":this.generateYearScale(v);break;case"months":case"half_year":this.generateMonthScale(v);break;case"months_days":case"months_fortnight":case"days":case"week_days":this.generateDayScale(v);break;case"hours":this.generateHourScale(v);break;case"minutes_fives":case"minutes":this.generateMinuteScale(v);break;case"seconds_tens":case"seconds_fives":case"seconds":this.generateSecondScale(v)}var y=this.timeScaleArray.map((function(t){var e={position:t.position,unit:t.unit,year:t.year,day:t.day?t.day:1,hour:t.hour?t.hour:0,month:t.month+1};return"month"===t.unit?r(r({},e),{},{day:1,value:t.value+1}):"day"===t.unit||"hour"===t.unit?r(r({},e),{},{value:t.value}):"minute"===t.unit?r(r({},e),{},{value:t.value,minute:t.value}):"second"===t.unit?r(r({},e),{},{value:t.value,minute:t.minute,second:t.second}):t}));return y.filter((function(t){var e=1,s=Math.ceil(a.globals.gridWidth/120),r=t.value;void 0!==a.config.xaxis.tickAmount&&(s=a.config.xaxis.tickAmount),y.length>s&&(e=Math.floor(y.length/s));var n=!1,o=!1;switch(i.tickInterval){case"years":"year"===t.unit&&(n=!0);break;case"half_year":e=7,"year"===t.unit&&(n=!0);break;case"months":e=1,"year"===t.unit&&(n=!0);break;case"months_fortnight":e=15,"year"!==t.unit&&"month"!==t.unit||(n=!0),30===r&&(o=!0);break;case"months_days":e=10,"month"===t.unit&&(n=!0),30===r&&(o=!0);break;case"week_days":e=8,"month"===t.unit&&(n=!0);break;case"days":e=1,"month"===t.unit&&(n=!0);break;case"hours":"day"===t.unit&&(n=!0);break;case"minutes_fives":case"seconds_fives":r%5!=0&&(o=!0);break;case"seconds_tens":r%10!=0&&(o=!0)}if("hours"===i.tickInterval||"minutes_fives"===i.tickInterval||"seconds_tens"===i.tickInterval||"seconds_fives"===i.tickInterval){if(!o)return!0}else if((r%e==0||n)&&!o)return!0}))}},{key:"recalcDimensionsBasedOnFormat",value:function(t,e){var i=this.w,a=this.formatDates(t),s=this.removeOverlappingTS(a);i.globals.timescaleLabels=s.slice(),new ct(this.ctx).plotCoords()}},{key:"determineInterval",value:function(t){var e=24*t,i=60*e;switch(!0){case t/365>5:this.tickInterval="years";break;case t>800:this.tickInterval="half_year";break;case t>180:this.tickInterval="months";break;case t>90:this.tickInterval="months_fortnight";break;case t>60:this.tickInterval="months_days";break;case t>30:this.tickInterval="week_days";break;case t>2:this.tickInterval="days";break;case e>2.4:this.tickInterval="hours";break;case i>15:this.tickInterval="minutes_fives";break;case i>5:this.tickInterval="minutes";break;case i>1:this.tickInterval="seconds_tens";break;case 60*i>20:this.tickInterval="seconds_fives";break;default:this.tickInterval="seconds"}}},{key:"generateYearScale",value:function(t){var e=t.firstVal,i=t.currentMonth,a=t.currentYear,s=t.daysWidthOnXAxis,r=t.numberOfYears,n=e.minYear,o=0,l=new E(this.ctx),c="year";if(e.minDate>1||e.minMonth>0){var h=l.determineRemainingDaysOfYear(e.minYear,e.minMonth,e.minDate);o=(l.determineDaysOfYear(e.minYear)-h+1)*s,n=e.minYear+1,this.timeScaleArray.push({position:o,value:n,unit:c,year:n,month:v.monthMod(i+1)})}else 1===e.minDate&&0===e.minMonth&&this.timeScaleArray.push({position:o,value:n,unit:c,year:a,month:v.monthMod(i+1)});for(var d=n,u=o,p=0;p<r;p++)d++,u=l.determineDaysOfYear(d-1)*s+u,this.timeScaleArray.push({position:u,value:d,unit:c,year:d,month:1})}},{key:"generateMonthScale",value:function(t){var e=t.firstVal,i=t.currentMonthDate,a=t.currentMonth,s=t.currentYear,r=t.daysWidthOnXAxis,n=t.numberOfMonths,o=a,l=0,c=new E(this.ctx),h="month",d=0;if(e.minDate>1){l=(c.determineDaysOfMonths(a+1,e.minYear)-i+1)*r,o=v.monthMod(a+1);var u=s+d,p=v.monthMod(o),f=o;0===o&&(h="year",f=u,p=1,u+=d+=1),this.timeScaleArray.push({position:l,value:f,unit:h,year:u,month:p})}else this.timeScaleArray.push({position:l,value:o,unit:h,year:s,month:v.monthMod(a)});for(var g=o+1,x=l,m=0,b=1;m<n;m++,b++){0===(g=v.monthMod(g))?(h="year",d+=1):h="month";var y=this._getYear(s,g,d);x=c.determineDaysOfMonths(g,y)*r+x;var w=0===g?y:g;this.timeScaleArray.push({position:x,value:w,unit:h,year:y,month:0===g?1:g}),g++}}},{key:"generateDayScale",value:function(t){var e=t.firstVal,i=t.currentMonth,a=t.currentYear,s=t.hoursWidthOnXAxis,r=t.numberOfDays,n=new E(this.ctx),o="day",l=e.minDate+1,c=l,h=function(t,e,i){return t>n.determineDaysOfMonths(e+1,i)?(c=1,o="month",u=e+=1,e):e},d=(24-e.minHour)*s,u=l,p=h(c,i,a);0===e.minHour&&1===e.minDate?(d=0,u=v.monthMod(e.minMonth),o="month",c=e.minDate,r++):1!==e.minDate&&0===e.minHour&&0===e.minMinute&&(d=0,l=e.minDate,u=l,p=h(c=l,i,a)),this.timeScaleArray.push({position:d,value:u,unit:o,year:this._getYear(a,p,0),month:v.monthMod(p),day:c});for(var f=d,g=0;g<r;g++){o="day",p=h(c+=1,p,this._getYear(a,p,0));var x=this._getYear(a,p,0);f=24*s+f;var m=1===c?v.monthMod(p):c;this.timeScaleArray.push({position:f,value:m,unit:o,year:x,month:v.monthMod(p),day:m})}}},{key:"generateHourScale",value:function(t){var e=t.firstVal,i=t.currentDate,a=t.currentMonth,s=t.currentYear,r=t.minutesWidthOnXAxis,n=t.numberOfHours,o=new E(this.ctx),l="hour",c=function(t,e){return t>o.determineDaysOfMonths(e+1,s)&&(g=1,e+=1),{month:e,date:g}},h=function(t,e){return t>o.determineDaysOfMonths(e+1,s)?e+=1:e},d=60-(e.minMinute+e.minSecond/60),u=d*r,p=e.minHour+1,f=p+1;60===d&&(u=0,f=(p=e.minHour)+1);var g=i,x=h(g,a);this.timeScaleArray.push({position:u,value:p,unit:l,day:g,hour:f,year:s,month:v.monthMod(x)});for(var m=u,b=0;b<n;b++){l="hour",f>=24&&(f=0,l="day",x=c(g+=1,x).month,x=h(g,x));var y=this._getYear(s,x,0);m=0===f&&0===b?d*r:60*r+m;var w=0===f?g:f;this.timeScaleArray.push({position:m,value:w,unit:l,hour:f,day:g,year:y,month:v.monthMod(x)}),f++}}},{key:"generateMinuteScale",value:function(t){for(var e=t.currentMillisecond,i=t.currentSecond,a=t.currentMinute,s=t.currentHour,r=t.currentDate,n=t.currentMonth,o=t.currentYear,l=t.minutesWidthOnXAxis,c=t.secondsWidthOnXAxis,h=t.numberOfMinutes,d=a+1,u=r,p=n,f=o,g=s,x=(60-i-e/1e3)*c,m=0;m<h;m++)d>=60&&(d=0,24===(g+=1)&&(g=0)),this.timeScaleArray.push({position:x,value:d,unit:"minute",hour:g,minute:d,day:u,year:this._getYear(f,p,0),month:v.monthMod(p)}),x+=l,d++}},{key:"generateSecondScale",value:function(t){for(var e=t.currentMillisecond,i=t.currentSecond,a=t.currentMinute,s=t.currentHour,r=t.currentDate,n=t.currentMonth,o=t.currentYear,l=t.secondsWidthOnXAxis,c=t.numberOfSeconds,h=i+1,d=a,u=r,p=n,f=o,g=s,x=(1e3-e)/1e3*l,m=0;m<c;m++)h>=60&&(h=0,++d>=60&&(d=0,24==++g&&(g=0))),this.timeScaleArray.push({position:x,value:h,unit:"second",hour:g,minute:d,second:h,day:u,year:this._getYear(f,p,0),month:v.monthMod(p)}),x+=l,h++}},{key:"createRawDateString",value:function(t,e){var i=t.year;return 0===t.month&&(t.month=1),i+="-"+("0"+t.month.toString()).slice(-2),"day"===t.unit?i+="day"===t.unit?"-"+("0"+e).slice(-2):"-01":i+="-"+("0"+(t.day?t.day:"1")).slice(-2),"hour"===t.unit?i+="hour"===t.unit?"T"+("0"+e).slice(-2):"T00":i+="T"+("0"+(t.hour?t.hour:"0")).slice(-2),"minute"===t.unit?i+=":"+("0"+e).slice(-2):i+=":"+(t.minute?("0"+t.minute).slice(-2):"00"),"second"===t.unit?i+=":"+("0"+e).slice(-2):i+=":00",this.utc&&(i+=".000Z"),i}},{key:"formatDates",value:function(t){var e=this,i=this.w;return t.map((function(t){var a=t.value.toString(),s=new E(e.ctx),r=e.createRawDateString(t,a),n=s.getDate(s.parseDate(r));if(e.utc||(n=s.getDate(s.parseDateWithTimezone(r))),void 0===i.config.xaxis.labels.format){var o="dd MMM",l=i.config.xaxis.labels.datetimeFormatter;"year"===t.unit&&(o=l.year),"month"===t.unit&&(o=l.month),"day"===t.unit&&(o=l.day),"hour"===t.unit&&(o=l.hour),"minute"===t.unit&&(o=l.minute),"second"===t.unit&&(o=l.second),a=s.formatDate(n,o)}else a=s.formatDate(n,i.config.xaxis.labels.format);return{dateString:r,position:t.position,value:a,unit:t.unit,year:t.year,month:t.month}}))}},{key:"removeOverlappingTS",value:function(t){var e,i=this,a=new k(this.ctx),s=!1;t.length>0&&t[0].value&&t.every((function(e){return e.value.length===t[0].value.length}))&&(s=!0,e=a.getTextRects(t[0].value).width);var r=0,n=t.map((function(n,o){if(o>0&&i.w.config.xaxis.labels.hideOverlappingLabels){var l=s?e:a.getTextRects(t[r].value).width,c=t[r].position;return n.position>c+l+10?(r=o,n):null}return n}));return n.filter((function(t){return null!==t}))}},{key:"_getYear",value:function(t,e,i){return t+Math.floor(e/12)+i}}]),t}(),Xt=function(){function t(e,i){o(this,t),this.ctx=i,this.w=i.w,this.el=e}return c(t,[{key:"setupElements",value:function(){var t=this.w.globals,e=this.w.config,i=e.chart.type;t.axisCharts=["line","area","bar","rangeBar","rangeArea","candlestick","boxPlot","scatter","bubble","radar","heatmap","treemap"].indexOf(i)>-1,t.xyCharts=["line","area","bar","rangeBar","rangeArea","candlestick","boxPlot","scatter","bubble"].indexOf(i)>-1,t.isBarHorizontal=("bar"===e.chart.type||"rangeBar"===e.chart.type||"boxPlot"===e.chart.type)&&e.plotOptions.bar.horizontal,t.chartClass=".apexcharts"+t.chartID,t.dom.baseEl=this.el,t.dom.elWrap=document.createElement("div"),k.setAttrs(t.dom.elWrap,{id:t.chartClass.substring(1),class:"apexcharts-canvas "+t.chartClass.substring(1)}),this.el.appendChild(t.dom.elWrap),t.dom.Paper=new window.SVG.Doc(t.dom.elWrap),t.dom.Paper.attr({class:"apexcharts-svg","xmlns:data":"ApexChartsNS",transform:"translate(".concat(e.chart.offsetX,", ").concat(e.chart.offsetY,")")}),t.dom.Paper.node.style.background=e.chart.background,this.setSVGDimensions(),t.dom.elGraphical=t.dom.Paper.group().attr({class:"apexcharts-inner apexcharts-graphical"}),t.dom.elAnnotations=t.dom.Paper.group().attr({class:"apexcharts-annotations"}),t.dom.elDefs=t.dom.Paper.defs(),t.dom.elLegendWrap=document.createElement("div"),t.dom.elLegendWrap.classList.add("apexcharts-legend"),t.dom.elWrap.appendChild(t.dom.elLegendWrap),t.dom.Paper.add(t.dom.elGraphical),t.dom.elGraphical.add(t.dom.elDefs)}},{key:"plotChartType",value:function(t,e){var i=this.w,a=i.config,s=i.globals,r={series:[],i:[]},n={series:[],i:[]},o={series:[],i:[]},l={series:[],i:[]},c={series:[],i:[]},h={series:[],i:[]},d={series:[],i:[]},u={series:[],i:[]},p={series:[],seriesRangeEnd:[],i:[]};s.series.map((function(e,f){var g=0;void 0!==t[f].type?("column"===t[f].type||"bar"===t[f].type?(s.series.length>1&&a.plotOptions.bar.horizontal&&console.warn("Horizontal bars are not supported in a mixed/combo chart. Please turn off `plotOptions.bar.horizontal`"),c.series.push(e),c.i.push(f),g++,i.globals.columnSeries=c.series):"area"===t[f].type?(n.series.push(e),n.i.push(f),g++):"line"===t[f].type?(r.series.push(e),r.i.push(f),g++):"scatter"===t[f].type?(o.series.push(e),o.i.push(f)):"bubble"===t[f].type?(l.series.push(e),l.i.push(f),g++):"candlestick"===t[f].type?(h.series.push(e),h.i.push(f),g++):"boxPlot"===t[f].type?(d.series.push(e),d.i.push(f),g++):"rangeBar"===t[f].type?(u.series.push(e),u.i.push(f),g++):"rangeArea"===t[f].type?(p.series.push(s.seriesRangeStart[f]),p.seriesRangeEnd.push(s.seriesRangeEnd[f]),p.i.push(f),g++):console.warn("You have specified an unrecognized chart type. Available types for this property are line/area/column/bar/scatter/bubble"),g>1&&(s.comboCharts=!0)):(r.series.push(e),r.i.push(f))}));var f=new zt(this.ctx,e),g=new Ct(this.ctx,e);this.ctx.pie=new Tt(this.ctx);var x=new Et(this.ctx);this.ctx.rangeBar=new It(this.ctx,e);var m=new Mt(this.ctx),b=[];if(s.comboCharts){if(n.series.length>0&&b.push(f.draw(n.series,"area",n.i)),c.series.length>0)if(i.config.chart.stacked){var v=new St(this.ctx,e);b.push(v.draw(c.series,c.i))}else this.ctx.bar=new At(this.ctx,e),b.push(this.ctx.bar.draw(c.series,c.i));if(p.series.length>0&&b.push(f.draw(p.series,"rangeArea",p.i,p.seriesRangeEnd)),r.series.length>0&&b.push(f.draw(r.series,"line",r.i)),h.series.length>0&&b.push(g.draw(h.series,h.i)),d.series.length>0&&b.push(g.draw(d.series,d.i)),u.series.length>0&&b.push(this.ctx.rangeBar.draw(u.series,u.i)),o.series.length>0){var y=new zt(this.ctx,e,!0);b.push(y.draw(o.series,"scatter",o.i))}if(l.series.length>0){var w=new zt(this.ctx,e,!0);b.push(w.draw(l.series,"bubble",l.i))}}else switch(a.chart.type){case"line":b=f.draw(s.series,"line");break;case"area":b=f.draw(s.series,"area");break;case"bar":a.chart.stacked?b=new St(this.ctx,e).draw(s.series):(this.ctx.bar=new At(this.ctx,e),b=this.ctx.bar.draw(s.series));break;case"candlestick":case"boxPlot":b=new Ct(this.ctx,e).draw(s.series);break;case"rangeBar":b=this.ctx.rangeBar.draw(s.series);break;case"rangeArea":b=f.draw(s.seriesRangeStart,"rangeArea",void 0,s.seriesRangeEnd);break;case"heatmap":b=new Lt(this.ctx,e).draw(s.series);break;case"treemap":b=new Ft(this.ctx,e).draw(s.series);break;case"pie":case"donut":case"polarArea":b=this.ctx.pie.draw(s.series);break;case"radialBar":b=x.draw(s.series);break;case"radar":b=m.draw(s.series);break;default:b=f.draw(s.series)}return b}},{key:"setSVGDimensions",value:function(){var t=this.w.globals,e=this.w.config;t.svgWidth=e.chart.width,t.svgHeight=e.chart.height;var i=v.getDimensions(this.el),a=e.chart.width.toString().split(/[0-9]+/g).pop();"%"===a?v.isNumber(i[0])&&(0===i[0].width&&(i=v.getDimensions(this.el.parentNode)),t.svgWidth=i[0]*parseInt(e.chart.width,10)/100):"px"!==a&&""!==a||(t.svgWidth=parseInt(e.chart.width,10));var s=e.chart.height.toString().split(/[0-9]+/g).pop();if("auto"!==t.svgHeight&&""!==t.svgHeight)if("%"===s){var r=v.getDimensions(this.el.parentNode);t.svgHeight=r[1]*parseInt(e.chart.height,10)/100}else t.svgHeight=parseInt(e.chart.height,10);else t.axisCharts?t.svgHeight=t.svgWidth/1.61:t.svgHeight=t.svgWidth/1.2;if(t.svgWidth<0&&(t.svgWidth=0),t.svgHeight<0&&(t.svgHeight=0),k.setAttrs(t.dom.Paper.node,{width:t.svgWidth,height:t.svgHeight}),"%"!==s){var n=e.chart.sparkline.enabled?0:t.axisCharts?e.chart.parentHeightOffset:0;t.dom.Paper.node.parentNode.parentNode.style.minHeight=t.svgHeight+n+"px"}t.dom.elWrap.style.width=t.svgWidth+"px",t.dom.elWrap.style.height=t.svgHeight+"px"}},{key:"shiftGraphPosition",value:function(){var t=this.w.globals,e=t.translateY,i={transform:"translate("+t.translateX+", "+e+")"};k.setAttrs(t.dom.elGraphical.node,i)}},{key:"resizeNonAxisCharts",value:function(){var t=this.w,e=t.globals,i=0,a=t.config.chart.sparkline.enabled?1:15;a+=t.config.grid.padding.bottom,"top"!==t.config.legend.position&&"bottom"!==t.config.legend.position||!t.config.legend.show||t.config.legend.floating||(i=new dt(this.ctx).legendHelpers.getLegendBBox().clwh+10);var s=t.globals.dom.baseEl.querySelector(".apexcharts-radialbar, .apexcharts-pie"),r=2.05*t.globals.radialSize;if(s&&!t.config.chart.sparkline.enabled&&0!==t.config.plotOptions.radialBar.startAngle){var n=v.getBoundingClientRect(s);r=n.bottom;var o=n.bottom-n.top;r=Math.max(2.05*t.globals.radialSize,o)}var l=r+e.translateY+i+a;e.dom.elLegendForeign&&e.dom.elLegendForeign.setAttribute("height",l),t.config.chart.height&&String(t.config.chart.height).indexOf("%")>0||(e.dom.elWrap.style.height=l+"px",k.setAttrs(e.dom.Paper.node,{height:l}),e.dom.Paper.node.parentNode.parentNode.style.minHeight=l+"px")}},{key:"coreCalculations",value:function(){new $(this.ctx).init()}},{key:"resetGlobals",value:function(){var t=this,e=function(){return t.w.config.series.map((function(t){return[]}))},i=new Y,a=this.w.globals;i.initGlobalVars(a),a.seriesXvalues=e(),a.seriesYvalues=e()}},{key:"isMultipleY",value:function(){if(this.w.config.yaxis.constructor===Array&&this.w.config.yaxis.length>1)return this.w.globals.isMultipleYAxis=!0,!0}},{key:"xySettings",value:function(){var t=null,e=this.w;if(e.globals.axisCharts){if("back"===e.config.xaxis.crosshairs.position&&new et(this.ctx).drawXCrosshairs(),"back"===e.config.yaxis[0].crosshairs.position&&new et(this.ctx).drawYCrosshairs(),"datetime"===e.config.xaxis.type&&void 0===e.config.xaxis.labels.formatter){this.ctx.timeScale=new Nt(this.ctx);var i=[];isFinite(e.globals.minX)&&isFinite(e.globals.maxX)&&!e.globals.isBarHorizontal?i=this.ctx.timeScale.calculateTimeScaleTicks(e.globals.minX,e.globals.maxX):e.globals.isBarHorizontal&&(i=this.ctx.timeScale.calculateTimeScaleTicks(e.globals.minY,e.globals.maxY)),this.ctx.timeScale.recalcDimensionsBasedOnFormat(i)}t=new A(this.ctx).getCalculatedRatios()}return t}},{key:"updateSourceChart",value:function(t){this.ctx.w.globals.selection=void 0,this.ctx.updateHelpers._updateOptions({chart:{selection:{xaxis:{min:t.w.globals.minX,max:t.w.globals.maxX}}}},!1,!1)}},{key:"setupBrushHandler",value:function(){var t=this,e=this.w;if(e.config.chart.brush.enabled&&"function"!=typeof e.config.chart.events.selection){var i=e.config.chart.brush.targets||[e.config.chart.brush.target];i.forEach((function(e){var i=ApexCharts.getChartByID(e);i.w.globals.brushSource=t.ctx,"function"!=typeof i.w.config.chart.events.zoomed&&(i.w.config.chart.events.zoomed=function(){t.updateSourceChart(i)}),"function"!=typeof i.w.config.chart.events.scrolled&&(i.w.config.chart.events.scrolled=function(){t.updateSourceChart(i)})})),e.config.chart.events.selection=function(t,a){i.forEach((function(t){var i=ApexCharts.getChartByID(t),s=v.clone(e.config.yaxis);if(e.config.chart.brush.autoScaleYaxis&&1===i.w.globals.series.length){var n=new Z(i);s=n.autoScaleY(i,s,a)}var o=i.w.config.yaxis.reduce((function(t,e,a){return[].concat(x(t),[r(r({},i.w.config.yaxis[a]),{},{min:s[0].min,max:s[0].max})])}),[]);i.ctx.updateHelpers._updateOptions({xaxis:{min:a.xaxis.min,max:a.xaxis.max},yaxis:o},!1,!1,!1,!1)}))}}}}]),t}(),_t=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w}return c(t,[{key:"_updateOptions",value:function(t){var e=this,i=arguments.length>1&&void 0!==arguments[1]&&arguments[1],a=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],s=!(arguments.length>3&&void 0!==arguments[3])||arguments[3],r=arguments.length>4&&void 0!==arguments[4]&&arguments[4];return new Promise((function(o){var l=[e.ctx];s&&(l=e.ctx.getSyncedCharts()),e.ctx.w.globals.isExecCalled&&(l=[e.ctx],e.ctx.w.globals.isExecCalled=!1),l.forEach((function(s,c){var h=s.w;if(h.globals.shouldAnimate=a,i||(h.globals.resized=!0,h.globals.dataChanged=!0,a&&s.series.getPreviousPaths()),t&&"object"===n(t)&&(s.config=new R(t),t=A.extendArrayProps(s.config,t,h),s.w.globals.chartID!==e.ctx.w.globals.chartID&&delete t.series,h.config=v.extend(h.config,t),r&&(h.globals.lastXAxis=t.xaxis?v.clone(t.xaxis):[],h.globals.lastYAxis=t.yaxis?v.clone(t.yaxis):[],h.globals.initialConfig=v.extend({},h.config),h.globals.initialSeries=v.clone(h.config.series),t.series))){for(var d=0;d<h.globals.collapsedSeriesIndices.length;d++){var u=h.config.series[h.globals.collapsedSeriesIndices[d]];h.globals.collapsedSeries[d].data=h.globals.axisCharts?u.data.slice():u}for(var p=0;p<h.globals.ancillaryCollapsedSeriesIndices.length;p++){var f=h.config.series[h.globals.ancillaryCollapsedSeriesIndices[p]];h.globals.ancillaryCollapsedSeries[p].data=h.globals.axisCharts?f.data.slice():f}s.series.emptyCollapsedSeries(h.config.series)}return s.update(t).then((function(){c===l.length-1&&o(s)}))}))}))}},{key:"_updateSeries",value:function(t,e){var i=this,a=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return new Promise((function(s){var r,n=i.w;return n.globals.shouldAnimate=e,n.globals.dataChanged=!0,e&&i.ctx.series.getPreviousPaths(),n.globals.axisCharts?(0===(r=t.map((function(t,e){return i._extendSeries(t,e)}))).length&&(r=[{data:[]}]),n.config.series=r):n.config.series=t.slice(),a&&(n.globals.initialConfig.series=v.clone(n.config.series),n.globals.initialSeries=v.clone(n.config.series)),i.ctx.update().then((function(){s(i.ctx)}))}))}},{key:"_extendSeries",value:function(t,e){var i=this.w,a=i.config.series[e];return r(r({},i.config.series[e]),{},{name:t.name?t.name:a&&a.name,color:t.color?t.color:a&&a.color,type:t.type?t.type:a&&a.type,data:t.data?t.data:a&&a.data})}},{key:"toggleDataPointSelection",value:function(t,e){var i=this.w,a=null,s=".apexcharts-series[data\\:realIndex='".concat(t,"']");return i.globals.axisCharts?a=i.globals.dom.Paper.select("".concat(s," path[j='").concat(e,"'], ").concat(s," circle[j='").concat(e,"'], ").concat(s," rect[j='").concat(e,"']")).members[0]:void 0===e&&(a=i.globals.dom.Paper.select("".concat(s," path[j='").concat(t,"']")).members[0],"pie"!==i.config.chart.type&&"polarArea"!==i.config.chart.type&&"donut"!==i.config.chart.type||this.ctx.pie.pieClicked(t)),a?(new k(this.ctx).pathMouseDown(a,null),a.node?a.node:null):(console.warn("toggleDataPointSelection: Element not found"),null)}},{key:"forceXAxisUpdate",value:function(t){var e=this.w;if(["min","max"].forEach((function(i){void 0!==t.xaxis[i]&&(e.config.xaxis[i]=t.xaxis[i],e.globals.lastXAxis[i]=t.xaxis[i])})),t.xaxis.categories&&t.xaxis.categories.length&&(e.config.xaxis.categories=t.xaxis.categories),e.config.xaxis.convertedCatToNumeric){var i=new z(t);t=i.convertCatToNumericXaxis(t,this.ctx)}return t}},{key:"forceYAxisUpdate",value:function(t){return t.chart&&t.chart.stacked&&"100%"===t.chart.stackType&&(Array.isArray(t.yaxis)?t.yaxis.forEach((function(e,i){t.yaxis[i].min=0,t.yaxis[i].max=100})):(t.yaxis.min=0,t.yaxis.max=100)),t}},{key:"revertDefaultAxisMinMax",value:function(t){var e=this,i=this.w,a=i.globals.lastXAxis,s=i.globals.lastYAxis;t&&t.xaxis&&(a=t.xaxis),t&&t.yaxis&&(s=t.yaxis),i.config.xaxis.min=a.min,i.config.xaxis.max=a.max,i.config.yaxis.map((function(t,a){i.globals.zoomed||void 0!==s[a]?function(t){void 0!==s[t]&&(i.config.yaxis[t].min=s[t].min,i.config.yaxis[t].max=s[t].max)}(a):void 0!==e.ctx.opts.yaxis[a]&&(t.min=e.ctx.opts.yaxis[a].min,t.max=e.ctx.opts.yaxis[a].max)}))}}]),t}();Rt="undefined"!=typeof window?window:void 0,Yt=function(t,e){var i=(void 0!==this?this:t).SVG=function(t){if(i.supported)return t=new i.Doc(t),i.parser.draw||i.prepare(),t};if(i.ns="http://www.w3.org/2000/svg",i.xmlns="http://www.w3.org/2000/xmlns/",i.xlink="http://www.w3.org/1999/xlink",i.svgjs="http://svgjs.dev",i.supported=!0,!i.supported)return!1;i.did=1e3,i.eid=function(t){return"Svgjs"+d(t)+i.did++},i.create=function(t){var i=e.createElementNS(this.ns,t);return i.setAttribute("id",this.eid(t)),i},i.extend=function(){var t,e;e=(t=[].slice.call(arguments)).pop();for(var a=t.length-1;a>=0;a--)if(t[a])for(var s in e)t[a].prototype[s]=e[s];i.Set&&i.Set.inherit&&i.Set.inherit()},i.invent=function(t){var e="function"==typeof t.create?t.create:function(){this.constructor.call(this,i.create(t.create))};return t.inherit&&(e.prototype=new t.inherit),t.extend&&i.extend(e,t.extend),t.construct&&i.extend(t.parent||i.Container,t.construct),e},i.adopt=function(e){return e?e.instance?e.instance:((a="svg"==e.nodeName?e.parentNode instanceof t.SVGElement?new i.Nested:new i.Doc:"linearGradient"==e.nodeName?new i.Gradient("linear"):"radialGradient"==e.nodeName?new i.Gradient("radial"):i[d(e.nodeName)]?new(i[d(e.nodeName)]):new i.Element(e)).type=e.nodeName,a.node=e,e.instance=a,a instanceof i.Doc&&a.namespace().defs(),a.setData(JSON.parse(e.getAttribute("svgjs:data"))||{}),a):null;var a},i.prepare=function(){var t=e.getElementsByTagName("body")[0],a=(t?new i.Doc(t):i.adopt(e.documentElement).nested()).size(2,0);i.parser={body:t||e.documentElement,draw:a.style("opacity:0;position:absolute;left:-100%;top:-100%;overflow:hidden").node,poly:a.polyline().node,path:a.path().node,native:i.create("svg")}},i.parser={native:i.create("svg")},e.addEventListener("DOMContentLoaded",(function(){i.parser.draw||i.prepare()}),!1),i.regex={numberAndUnit:/^([+-]?(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?)([a-z%]*)$/i,hex:/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i,rgb:/rgb\((\d+),(\d+),(\d+)\)/,reference:/#([a-z0-9\-_]+)/i,transforms:/\)\s*,?\s*/,whitespace:/\s/g,isHex:/^#[a-f0-9]{3,6}$/i,isRgb:/^rgb\(/,isCss:/[^:]+:[^;]+;?/,isBlank:/^(\s+)?$/,isNumber:/^[+-]?(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,isPercent:/^-?[\d\.]+%$/,isImage:/\.(jpg|jpeg|png|gif|svg)(\?[^=]+.*)?/i,delimiter:/[\s,]+/,hyphen:/([^e])\-/gi,pathLetters:/[MLHVCSQTAZ]/gi,isPathLetter:/[MLHVCSQTAZ]/i,numbersWithDots:/((\d?\.\d+(?:e[+-]?\d+)?)((?:\.\d+(?:e[+-]?\d+)?)+))+/gi,dots:/\./g},i.utils={map:function(t,e){for(var i=t.length,a=[],s=0;s<i;s++)a.push(e(t[s]));return a},filter:function(t,e){for(var i=t.length,a=[],s=0;s<i;s++)e(t[s])&&a.push(t[s]);return a},filterSVGElements:function(e){return this.filter(e,(function(e){return e instanceof t.SVGElement}))}},i.defaults={attrs:{"fill-opacity":1,"stroke-opacity":1,"stroke-width":0,"stroke-linejoin":"miter","stroke-linecap":"butt",fill:"#000000",stroke:"#000000",opacity:1,x:0,y:0,cx:0,cy:0,width:0,height:0,r:0,rx:0,ry:0,offset:0,"stop-opacity":1,"stop-color":"#000000","font-size":16,"font-family":"Helvetica, Arial, sans-serif","text-anchor":"start"}},i.Color=function(t){var e,a;this.r=0,this.g=0,this.b=0,t&&("string"==typeof t?i.regex.isRgb.test(t)?(e=i.regex.rgb.exec(t.replace(i.regex.whitespace,"")),this.r=parseInt(e[1]),this.g=parseInt(e[2]),this.b=parseInt(e[3])):i.regex.isHex.test(t)&&(e=i.regex.hex.exec(4==(a=t).length?["#",a.substring(1,2),a.substring(1,2),a.substring(2,3),a.substring(2,3),a.substring(3,4),a.substring(3,4)].join(""):a),this.r=parseInt(e[1],16),this.g=parseInt(e[2],16),this.b=parseInt(e[3],16)):"object"===n(t)&&(this.r=t.r,this.g=t.g,this.b=t.b))},i.extend(i.Color,{toString:function(){return this.toHex()},toHex:function(){return"#"+u(this.r)+u(this.g)+u(this.b)},toRgb:function(){return"rgb("+[this.r,this.g,this.b].join()+")"},brightness:function(){return this.r/255*.3+this.g/255*.59+this.b/255*.11},morph:function(t){return this.destination=new i.Color(t),this},at:function(t){return this.destination?(t=t<0?0:t>1?1:t,new i.Color({r:~~(this.r+(this.destination.r-this.r)*t),g:~~(this.g+(this.destination.g-this.g)*t),b:~~(this.b+(this.destination.b-this.b)*t)})):this}}),i.Color.test=function(t){return t+="",i.regex.isHex.test(t)||i.regex.isRgb.test(t)},i.Color.isRgb=function(t){return t&&"number"==typeof t.r&&"number"==typeof t.g&&"number"==typeof t.b},i.Color.isColor=function(t){return i.Color.isRgb(t)||i.Color.test(t)},i.Array=function(t,e){0==(t=(t||[]).valueOf()).length&&e&&(t=e.valueOf()),this.value=this.parse(t)},i.extend(i.Array,{toString:function(){return this.value.join(" ")},valueOf:function(){return this.value},parse:function(t){return t=t.valueOf(),Array.isArray(t)?t:this.split(t)}}),i.PointArray=function(t,e){i.Array.call(this,t,e||[[0,0]])},i.PointArray.prototype=new i.Array,i.PointArray.prototype.constructor=i.PointArray;for(var a={M:function(t,e,i){return e.x=i.x=t[0],e.y=i.y=t[1],["M",e.x,e.y]},L:function(t,e){return e.x=t[0],e.y=t[1],["L",t[0],t[1]]},H:function(t,e){return e.x=t[0],["H",t[0]]},V:function(t,e){return e.y=t[0],["V",t[0]]},C:function(t,e){return e.x=t[4],e.y=t[5],["C",t[0],t[1],t[2],t[3],t[4],t[5]]},Q:function(t,e){return e.x=t[2],e.y=t[3],["Q",t[0],t[1],t[2],t[3]]},Z:function(t,e,i){return e.x=i.x,e.y=i.y,["Z"]}},s="mlhvqtcsaz".split(""),r=0,o=s.length;r<o;++r)a[s[r]]=function(t){return function(e,i,s){if("H"==t)e[0]=e[0]+i.x;else if("V"==t)e[0]=e[0]+i.y;else if("A"==t)e[5]=e[5]+i.x,e[6]=e[6]+i.y;else for(var r=0,n=e.length;r<n;++r)e[r]=e[r]+(r%2?i.y:i.x);if(a&&"function"==typeof a[t])return a[t](e,i,s)}}(s[r].toUpperCase());i.PathArray=function(t,e){i.Array.call(this,t,e||[["M",0,0]])},i.PathArray.prototype=new i.Array,i.PathArray.prototype.constructor=i.PathArray,i.extend(i.PathArray,{toString:function(){return function(t){for(var e=0,i=t.length,a="";e<i;e++)a+=t[e][0],null!=t[e][1]&&(a+=t[e][1],null!=t[e][2]&&(a+=" ",a+=t[e][2],null!=t[e][3]&&(a+=" ",a+=t[e][3],a+=" ",a+=t[e][4],null!=t[e][5]&&(a+=" ",a+=t[e][5],a+=" ",a+=t[e][6],null!=t[e][7]&&(a+=" ",a+=t[e][7])))));return a+" "}(this.value)},move:function(t,e){var i=this.bbox();return i.x,i.y,this},at:function(t){if(!this.destination)return this;for(var e=this.value,a=this.destination.value,s=[],r=new i.PathArray,n=0,o=e.length;n<o;n++){s[n]=[e[n][0]];for(var l=1,c=e[n].length;l<c;l++)s[n][l]=e[n][l]+(a[n][l]-e[n][l])*t;"A"===s[n][0]&&(s[n][4]=+(0!=s[n][4]),s[n][5]=+(0!=s[n][5]))}return r.value=s,r},parse:function(t){if(t instanceof i.PathArray)return t.valueOf();var e,s={M:2,L:2,H:1,V:1,C:6,S:4,Q:4,T:2,A:7,Z:0};t="string"==typeof t?t.replace(i.regex.numbersWithDots,c).replace(i.regex.pathLetters," $& ").replace(i.regex.hyphen,"$1 -").trim().split(i.regex.delimiter):t.reduce((function(t,e){return[].concat.call(t,e)}),[]);var r=[],n=new i.Point,o=new i.Point,l=0,h=t.length;do{i.regex.isPathLetter.test(t[l])?(e=t[l],++l):"M"==e?e="L":"m"==e&&(e="l"),r.push(a[e].call(null,t.slice(l,l+=s[e.toUpperCase()]).map(parseFloat),n,o))}while(h>l);return r},bbox:function(){return i.parser.draw||i.prepare(),i.parser.path.setAttribute("d",this.toString()),i.parser.path.getBBox()}}),i.Number=i.invent({create:function(t,e){this.value=0,this.unit=e||"","number"==typeof t?this.value=isNaN(t)?0:isFinite(t)?t:t<0?-34e37:34e37:"string"==typeof t?(e=t.match(i.regex.numberAndUnit))&&(this.value=parseFloat(e[1]),"%"==e[5]?this.value/=100:"s"==e[5]&&(this.value*=1e3),this.unit=e[5]):t instanceof i.Number&&(this.value=t.valueOf(),this.unit=t.unit)},extend:{toString:function(){return("%"==this.unit?~~(1e8*this.value)/1e6:"s"==this.unit?this.value/1e3:this.value)+this.unit},toJSON:function(){return this.toString()},valueOf:function(){return this.value},plus:function(t){return t=new i.Number(t),new i.Number(this+t,this.unit||t.unit)},minus:function(t){return t=new i.Number(t),new i.Number(this-t,this.unit||t.unit)},times:function(t){return t=new i.Number(t),new i.Number(this*t,this.unit||t.unit)},divide:function(t){return t=new i.Number(t),new i.Number(this/t,this.unit||t.unit)},to:function(t){var e=new i.Number(this);return"string"==typeof t&&(e.unit=t),e},morph:function(t){return this.destination=new i.Number(t),t.relative&&(this.destination.value+=this.value),this},at:function(t){return this.destination?new i.Number(this.destination).minus(this).times(t).plus(this):this}}}),i.Element=i.invent({create:function(t){this._stroke=i.defaults.attrs.stroke,this._event=null,this.dom={},(this.node=t)&&(this.type=t.nodeName,this.node.instance=this,this._stroke=t.getAttribute("stroke")||this._stroke)},extend:{x:function(t){return this.attr("x",t)},y:function(t){return this.attr("y",t)},cx:function(t){return null==t?this.x()+this.width()/2:this.x(t-this.width()/2)},cy:function(t){return null==t?this.y()+this.height()/2:this.y(t-this.height()/2)},move:function(t,e){return this.x(t).y(e)},center:function(t,e){return this.cx(t).cy(e)},width:function(t){return this.attr("width",t)},height:function(t){return this.attr("height",t)},size:function(t,e){var a=p(this,t,e);return this.width(new i.Number(a.width)).height(new i.Number(a.height))},clone:function(t){this.writeDataToDom();var e=x(this.node.cloneNode(!0));return t?t.add(e):this.after(e),e},remove:function(){return this.parent()&&this.parent().removeElement(this),this},replace:function(t){return this.after(t).remove(),t},addTo:function(t){return t.put(this)},putIn:function(t){return t.add(this)},id:function(t){return this.attr("id",t)},show:function(){return this.style("display","")},hide:function(){return this.style("display","none")},visible:function(){return"none"!=this.style("display")},toString:function(){return this.attr("id")},classes:function(){var t=this.attr("class");return null==t?[]:t.trim().split(i.regex.delimiter)},hasClass:function(t){return-1!=this.classes().indexOf(t)},addClass:function(t){if(!this.hasClass(t)){var e=this.classes();e.push(t),this.attr("class",e.join(" "))}return this},removeClass:function(t){return this.hasClass(t)&&this.attr("class",this.classes().filter((function(e){return e!=t})).join(" ")),this},toggleClass:function(t){return this.hasClass(t)?this.removeClass(t):this.addClass(t)},reference:function(t){return i.get(this.attr(t))},parent:function(e){var a=this;if(!a.node.parentNode)return null;if(a=i.adopt(a.node.parentNode),!e)return a;for(;a&&a.node instanceof t.SVGElement;){if("string"==typeof e?a.matches(e):a instanceof e)return a;if(!a.node.parentNode||"#document"==a.node.parentNode.nodeName)return null;a=i.adopt(a.node.parentNode)}},doc:function(){return this instanceof i.Doc?this:this.parent(i.Doc)},parents:function(t){var e=[],i=this;do{if(!(i=i.parent(t))||!i.node)break;e.push(i)}while(i.parent);return e},matches:function(t){return function(t,e){return(t.matches||t.matchesSelector||t.msMatchesSelector||t.mozMatchesSelector||t.webkitMatchesSelector||t.oMatchesSelector).call(t,e)}(this.node,t)},native:function(){return this.node},svg:function(t){var a=e.createElement("svg");if(!(t&&this instanceof i.Parent))return a.appendChild(t=e.createElement("svg")),this.writeDataToDom(),t.appendChild(this.node.cloneNode(!0)),a.innerHTML.replace(/^<svg>/,"").replace(/<\/svg>$/,"");a.innerHTML="<svg>"+t.replace(/\n/,"").replace(/<([\w:-]+)([^<]+?)\/>/g,"<$1$2></$1>")+"</svg>";for(var s=0,r=a.firstChild.childNodes.length;s<r;s++)this.node.appendChild(a.firstChild.firstChild);return this},writeDataToDom:function(){return(this.each||this.lines)&&(this.each?this:this.lines()).each((function(){this.writeDataToDom()})),this.node.removeAttribute("svgjs:data"),Object.keys(this.dom).length&&this.node.setAttribute("svgjs:data",JSON.stringify(this.dom)),this},setData:function(t){return this.dom=t,this},is:function(t){return function(t,e){return t instanceof e}(this,t)}}}),i.easing={"-":function(t){return t},"<>":function(t){return-Math.cos(t*Math.PI)/2+.5},">":function(t){return Math.sin(t*Math.PI/2)},"<":function(t){return 1-Math.cos(t*Math.PI/2)}},i.morph=function(t){return function(e,a){return new i.MorphObj(e,a).at(t)}},i.Situation=i.invent({create:function(t){this.init=!1,this.reversed=!1,this.reversing=!1,this.duration=new i.Number(t.duration).valueOf(),this.delay=new i.Number(t.delay).valueOf(),this.start=+new Date+this.delay,this.finish=this.start+this.duration,this.ease=t.ease,this.loop=0,this.loops=!1,this.animations={},this.attrs={},this.styles={},this.transforms=[],this.once={}}}),i.FX=i.invent({create:function(t){this._target=t,this.situations=[],this.active=!1,this.situation=null,this.paused=!1,this.lastPos=0,this.pos=0,this.absPos=0,this._speed=1},extend:{animate:function(t,e,a){"object"===n(t)&&(e=t.ease,a=t.delay,t=t.duration);var s=new i.Situation({duration:t||1e3,delay:a||0,ease:i.easing[e||"-"]||e});return this.queue(s),this},target:function(t){return t&&t instanceof i.Element?(this._target=t,this):this._target},timeToAbsPos:function(t){return(t-this.situation.start)/(this.situation.duration/this._speed)},absPosToTime:function(t){return this.situation.duration/this._speed*t+this.situation.start},startAnimFrame:function(){this.stopAnimFrame(),this.animationFrame=t.requestAnimationFrame(function(){this.step()}.bind(this))},stopAnimFrame:function(){t.cancelAnimationFrame(this.animationFrame)},start:function(){return!this.active&&this.situation&&(this.active=!0,this.startCurrent()),this},startCurrent:function(){return this.situation.start=+new Date+this.situation.delay/this._speed,this.situation.finish=this.situation.start+this.situation.duration/this._speed,this.initAnimations().step()},queue:function(t){return("function"==typeof t||t instanceof i.Situation)&&this.situations.push(t),this.situation||(this.situation=this.situations.shift()),this},dequeue:function(){return this.stop(),this.situation=this.situations.shift(),this.situation&&(this.situation instanceof i.Situation?this.start():this.situation.call(this)),this},initAnimations:function(){var t,e=this.situation;if(e.init)return this;for(var a in e.animations){t=this.target()[a](),Array.isArray(t)||(t=[t]),Array.isArray(e.animations[a])||(e.animations[a]=[e.animations[a]]);for(var s=t.length;s--;)e.animations[a][s]instanceof i.Number&&(t[s]=new i.Number(t[s])),e.animations[a][s]=t[s].morph(e.animations[a][s])}for(var a in e.attrs)e.attrs[a]=new i.MorphObj(this.target().attr(a),e.attrs[a]);for(var a in e.styles)e.styles[a]=new i.MorphObj(this.target().style(a),e.styles[a]);return e.initialTransformation=this.target().matrixify(),e.init=!0,this},clearQueue:function(){return this.situations=[],this},clearCurrent:function(){return this.situation=null,this},stop:function(t,e){var i=this.active;return this.active=!1,e&&this.clearQueue(),t&&this.situation&&(!i&&this.startCurrent(),this.atEnd()),this.stopAnimFrame(),this.clearCurrent()},after:function(t){var e=this.last();return this.target().on("finished.fx",(function i(a){a.detail.situation==e&&(t.call(this,e),this.off("finished.fx",i))})),this._callStart()},during:function(t){var e=this.last(),a=function(a){a.detail.situation==e&&t.call(this,a.detail.pos,i.morph(a.detail.pos),a.detail.eased,e)};return this.target().off("during.fx",a).on("during.fx",a),this.after((function(){this.off("during.fx",a)})),this._callStart()},afterAll:function(t){var e=function e(i){t.call(this),this.off("allfinished.fx",e)};return this.target().off("allfinished.fx",e).on("allfinished.fx",e),this._callStart()},last:function(){return this.situations.length?this.situations[this.situations.length-1]:this.situation},add:function(t,e,i){return this.last()[i||"animations"][t]=e,this._callStart()},step:function(t){var e,i,a;t||(this.absPos=this.timeToAbsPos(+new Date)),!1!==this.situation.loops?(e=Math.max(this.absPos,0),i=Math.floor(e),!0===this.situation.loops||i<this.situation.loops?(this.pos=e-i,a=this.situation.loop,this.situation.loop=i):(this.absPos=this.situation.loops,this.pos=1,a=this.situation.loop-1,this.situation.loop=this.situation.loops),this.situation.reversing&&(this.situation.reversed=this.situation.reversed!=Boolean((this.situation.loop-a)%2))):(this.absPos=Math.min(this.absPos,1),this.pos=this.absPos),this.pos<0&&(this.pos=0),this.situation.reversed&&(this.pos=1-this.pos);var s=this.situation.ease(this.pos);for(var r in this.situation.once)r>this.lastPos&&r<=s&&(this.situation.once[r].call(this.target(),this.pos,s),delete this.situation.once[r]);return this.active&&this.target().fire("during",{pos:this.pos,eased:s,fx:this,situation:this.situation}),this.situation?(this.eachAt(),1==this.pos&&!this.situation.reversed||this.situation.reversed&&0==this.pos?(this.stopAnimFrame(),this.target().fire("finished",{fx:this,situation:this.situation}),this.situations.length||(this.target().fire("allfinished"),this.situations.length||(this.target().off(".fx"),this.active=!1)),this.active?this.dequeue():this.clearCurrent()):!this.paused&&this.active&&this.startAnimFrame(),this.lastPos=s,this):this},eachAt:function(){var t,e=this,a=this.target(),s=this.situation;for(var r in s.animations)t=[].concat(s.animations[r]).map((function(t){return"string"!=typeof t&&t.at?t.at(s.ease(e.pos),e.pos):t})),a[r].apply(a,t);for(var r in s.attrs)t=[r].concat(s.attrs[r]).map((function(t){return"string"!=typeof t&&t.at?t.at(s.ease(e.pos),e.pos):t})),a.attr.apply(a,t);for(var r in s.styles)t=[r].concat(s.styles[r]).map((function(t){return"string"!=typeof t&&t.at?t.at(s.ease(e.pos),e.pos):t})),a.style.apply(a,t);if(s.transforms.length){t=s.initialTransformation,r=0;for(var n=s.transforms.length;r<n;r++){var o=s.transforms[r];o instanceof i.Matrix?t=o.relative?t.multiply((new i.Matrix).morph(o).at(s.ease(this.pos))):t.morph(o).at(s.ease(this.pos)):(o.relative||o.undo(t.extract()),t=t.multiply(o.at(s.ease(this.pos))))}a.matrix(t)}return this},once:function(t,e,i){var a=this.last();return i||(t=a.ease(t)),a.once[t]=e,this},_callStart:function(){return setTimeout(function(){this.start()}.bind(this),0),this}},parent:i.Element,construct:{animate:function(t,e,a){return(this.fx||(this.fx=new i.FX(this))).animate(t,e,a)},delay:function(t){return(this.fx||(this.fx=new i.FX(this))).delay(t)},stop:function(t,e){return this.fx&&this.fx.stop(t,e),this},finish:function(){return this.fx&&this.fx.finish(),this}}}),i.MorphObj=i.invent({create:function(t,e){return i.Color.isColor(e)?new i.Color(t).morph(e):i.regex.delimiter.test(t)?i.regex.pathLetters.test(t)?new i.PathArray(t).morph(e):new i.Array(t).morph(e):i.regex.numberAndUnit.test(e)?new i.Number(t).morph(e):(this.value=t,void(this.destination=e))},extend:{at:function(t,e){return e<1?this.value:this.destination},valueOf:function(){return this.value}}}),i.extend(i.FX,{attr:function(t,e,i){if("object"===n(t))for(var a in t)this.attr(a,t[a]);else this.add(t,e,"attrs");return this},plot:function(t,e,i,a){return 4==arguments.length?this.plot([t,e,i,a]):this.add("plot",new(this.target().morphArray)(t))}}),i.Box=i.invent({create:function(t,e,a,s){if(!("object"!==n(t)||t instanceof i.Element))return i.Box.call(this,null!=t.left?t.left:t.x,null!=t.top?t.top:t.y,t.width,t.height);4==arguments.length&&(this.x=t,this.y=e,this.width=a,this.height=s),m(this)}}),i.BBox=i.invent({create:function(t){if(i.Box.apply(this,[].slice.call(arguments)),t instanceof i.Element){var a;try{if(!e.documentElement.contains){for(var s=t.node;s.parentNode;)s=s.parentNode;if(s!=e)throw new Error("Element not in the dom")}a=t.node.getBBox()}catch(e){if(t instanceof i.Shape){i.parser.draw||i.prepare();var r=t.clone(i.parser.draw.instance).show();r&&r.node&&"function"==typeof r.node.getBBox&&(a=r.node.getBBox()),r&&"function"==typeof r.remove&&r.remove()}else a={x:t.node.clientLeft,y:t.node.clientTop,width:t.node.clientWidth,height:t.node.clientHeight}}i.Box.call(this,a)}},inherit:i.Box,parent:i.Element,construct:{bbox:function(){return new i.BBox(this)}}}),i.BBox.prototype.constructor=i.BBox,i.Matrix=i.invent({create:function(t){var e=g([1,0,0,1,0,0]);t=null===t?e:t instanceof i.Element?t.matrixify():"string"==typeof t?g(t.split(i.regex.delimiter).map(parseFloat)):6==arguments.length?g([].slice.call(arguments)):Array.isArray(t)?g(t):t&&"object"===n(t)?t:e;for(var a=v.length-1;a>=0;--a)this[v[a]]=null!=t[v[a]]?t[v[a]]:e[v[a]]},extend:{extract:function(){var t=f(this,0,1);f(this,1,0);var e=180/Math.PI*Math.atan2(t.y,t.x)-90;return{x:this.e,y:this.f,transformedX:(this.e*Math.cos(e*Math.PI/180)+this.f*Math.sin(e*Math.PI/180))/Math.sqrt(this.a*this.a+this.b*this.b),transformedY:(this.f*Math.cos(e*Math.PI/180)+this.e*Math.sin(-e*Math.PI/180))/Math.sqrt(this.c*this.c+this.d*this.d),rotation:e,a:this.a,b:this.b,c:this.c,d:this.d,e:this.e,f:this.f,matrix:new i.Matrix(this)}},clone:function(){return new i.Matrix(this)},morph:function(t){return this.destination=new i.Matrix(t),this},multiply:function(t){return new i.Matrix(this.native().multiply(function(t){return t instanceof i.Matrix||(t=new i.Matrix(t)),t}(t).native()))},inverse:function(){return new i.Matrix(this.native().inverse())},translate:function(t,e){return new i.Matrix(this.native().translate(t||0,e||0))},native:function(){for(var t=i.parser.native.createSVGMatrix(),e=v.length-1;e>=0;e--)t[v[e]]=this[v[e]];return t},toString:function(){return"matrix("+b(this.a)+","+b(this.b)+","+b(this.c)+","+b(this.d)+","+b(this.e)+","+b(this.f)+")"}},parent:i.Element,construct:{ctm:function(){return new i.Matrix(this.node.getCTM())},screenCTM:function(){if(this instanceof i.Nested){var t=this.rect(1,1),e=t.node.getScreenCTM();return t.remove(),new i.Matrix(e)}return new i.Matrix(this.node.getScreenCTM())}}}),i.Point=i.invent({create:function(t,e){var i;i=Array.isArray(t)?{x:t[0],y:t[1]}:"object"===n(t)?{x:t.x,y:t.y}:null!=t?{x:t,y:null!=e?e:t}:{x:0,y:0},this.x=i.x,this.y=i.y},extend:{clone:function(){return new i.Point(this)},morph:function(t,e){return this.destination=new i.Point(t,e),this}}}),i.extend(i.Element,{point:function(t,e){return new i.Point(t,e).transform(this.screenCTM().inverse())}}),i.extend(i.Element,{attr:function(t,e,a){if(null==t){for(t={},a=(e=this.node.attributes).length-1;a>=0;a--)t[e[a].nodeName]=i.regex.isNumber.test(e[a].nodeValue)?parseFloat(e[a].nodeValue):e[a].nodeValue;return t}if("object"===n(t))for(var s in t)this.attr(s,t[s]);else if(null===e)this.node.removeAttribute(t);else{if(null==e)return null==(e=this.node.getAttribute(t))?i.defaults.attrs[t]:i.regex.isNumber.test(e)?parseFloat(e):e;"stroke-width"==t?this.attr("stroke",parseFloat(e)>0?this._stroke:null):"stroke"==t&&(this._stroke=e),"fill"!=t&&"stroke"!=t||(i.regex.isImage.test(e)&&(e=this.doc().defs().image(e,0,0)),e instanceof i.Image&&(e=this.doc().defs().pattern(0,0,(function(){this.add(e)})))),"number"==typeof e?e=new i.Number(e):i.Color.isColor(e)?e=new i.Color(e):Array.isArray(e)&&(e=new i.Array(e)),"leading"==t?this.leading&&this.leading(e):"string"==typeof a?this.node.setAttributeNS(a,t,e.toString()):this.node.setAttribute(t,e.toString()),!this.rebuild||"font-size"!=t&&"x"!=t||this.rebuild(t,e)}return this}}),i.extend(i.Element,{transform:function(t,e){var a;return"object"!==n(t)?(a=new i.Matrix(this).extract(),"string"==typeof t?a[t]:a):(a=new i.Matrix(this),e=!!e||!!t.relative,null!=t.a&&(a=e?a.multiply(new i.Matrix(t)):new i.Matrix(t)),this.attr("transform",a))}}),i.extend(i.Element,{untransform:function(){return this.attr("transform",null)},matrixify:function(){return(this.attr("transform")||"").split(i.regex.transforms).slice(0,-1).map((function(t){var e=t.trim().split("(");return[e[0],e[1].split(i.regex.delimiter).map((function(t){return parseFloat(t)}))]})).reduce((function(t,e){return"matrix"==e[0]?t.multiply(g(e[1])):t[e[0]].apply(t,e[1])}),new i.Matrix)},toParent:function(t){if(this==t)return this;var e=this.screenCTM(),i=t.screenCTM().inverse();return this.addTo(t).untransform().transform(i.multiply(e)),this},toDoc:function(){return this.toParent(this.doc())}}),i.Transformation=i.invent({create:function(t,e){if(arguments.length>1&&"boolean"!=typeof e)return this.constructor.call(this,[].slice.call(arguments));if(Array.isArray(t))for(var i=0,a=this.arguments.length;i<a;++i)this[this.arguments[i]]=t[i];else if(t&&"object"===n(t))for(i=0,a=this.arguments.length;i<a;++i)this[this.arguments[i]]=t[this.arguments[i]];this.inversed=!1,!0===e&&(this.inversed=!0)}}),i.Translate=i.invent({parent:i.Matrix,inherit:i.Transformation,create:function(t,e){this.constructor.apply(this,[].slice.call(arguments))},extend:{arguments:["transformedX","transformedY"],method:"translate"}}),i.extend(i.Element,{style:function(t,e){if(0==arguments.length)return this.node.style.cssText||"";if(arguments.length<2)if("object"===n(t))for(var a in t)this.style(a,t[a]);else{if(!i.regex.isCss.test(t))return this.node.style[h(t)];for(t=t.split(/\s*;\s*/).filter((function(t){return!!t})).map((function(t){return t.split(/\s*:\s*/)}));e=t.pop();)this.style(e[0],e[1])}else this.node.style[h(t)]=null===e||i.regex.isBlank.test(e)?"":e;return this}}),i.Parent=i.invent({create:function(t){this.constructor.call(this,t)},inherit:i.Element,extend:{children:function(){return i.utils.map(i.utils.filterSVGElements(this.node.childNodes),(function(t){return i.adopt(t)}))},add:function(t,e){return null==e?this.node.appendChild(t.node):t.node!=this.node.childNodes[e]&&this.node.insertBefore(t.node,this.node.childNodes[e]),this},put:function(t,e){return this.add(t,e),t},has:function(t){return this.index(t)>=0},index:function(t){return[].slice.call(this.node.childNodes).indexOf(t.node)},get:function(t){return i.adopt(this.node.childNodes[t])},first:function(){return this.get(0)},last:function(){return this.get(this.node.childNodes.length-1)},each:function(t,e){for(var a=this.children(),s=0,r=a.length;s<r;s++)a[s]instanceof i.Element&&t.apply(a[s],[s,a]),e&&a[s]instanceof i.Container&&a[s].each(t,e);return this},removeElement:function(t){return this.node.removeChild(t.node),this},clear:function(){for(;this.node.hasChildNodes();)this.node.removeChild(this.node.lastChild);return delete this._defs,this},defs:function(){return this.doc().defs()}}}),i.extend(i.Parent,{ungroup:function(t,e){return 0===e||this instanceof i.Defs||this.node==i.parser.draw||(t=t||(this instanceof i.Doc?this:this.parent(i.Parent)),e=e||1/0,this.each((function(){return this instanceof i.Defs?this:this instanceof i.Parent?this.ungroup(t,e-1):this.toParent(t)})),this.node.firstChild||this.remove()),this},flatten:function(t,e){return this.ungroup(t,e)}}),i.Container=i.invent({create:function(t){this.constructor.call(this,t)},inherit:i.Parent}),i.ViewBox=i.invent({parent:i.Container,construct:{}}),["click","dblclick","mousedown","mouseup","mouseover","mouseout","mousemove","touchstart","touchmove","touchleave","touchend","touchcancel"].forEach((function(t){i.Element.prototype[t]=function(e){return i.on(this.node,t,e),this}})),i.listeners=[],i.handlerMap=[],i.listenerId=0,i.on=function(t,e,a,s,r){var n=a.bind(s||t.instance||t),o=(i.handlerMap.indexOf(t)+1||i.handlerMap.push(t))-1,l=e.split(".")[0],c=e.split(".")[1]||"*";i.listeners[o]=i.listeners[o]||{},i.listeners[o][l]=i.listeners[o][l]||{},i.listeners[o][l][c]=i.listeners[o][l][c]||{},a._svgjsListenerId||(a._svgjsListenerId=++i.listenerId),i.listeners[o][l][c][a._svgjsListenerId]=n,t.addEventListener(l,n,r||{passive:!0})},i.off=function(t,e,a){var s=i.handlerMap.indexOf(t),r=e&&e.split(".")[0],n=e&&e.split(".")[1],o="";if(-1!=s)if(a){if("function"==typeof a&&(a=a._svgjsListenerId),!a)return;i.listeners[s][r]&&i.listeners[s][r][n||"*"]&&(t.removeEventListener(r,i.listeners[s][r][n||"*"][a],!1),delete i.listeners[s][r][n||"*"][a])}else if(n&&r){if(i.listeners[s][r]&&i.listeners[s][r][n]){for(var l in i.listeners[s][r][n])i.off(t,[r,n].join("."),l);delete i.listeners[s][r][n]}}else if(n)for(var c in i.listeners[s])for(var o in i.listeners[s][c])n===o&&i.off(t,[c,n].join("."));else if(r){if(i.listeners[s][r]){for(var o in i.listeners[s][r])i.off(t,[r,o].join("."));delete i.listeners[s][r]}}else{for(var c in i.listeners[s])i.off(t,c);delete i.listeners[s],delete i.handlerMap[s]}},i.extend(i.Element,{on:function(t,e,a,s){return i.on(this.node,t,e,a,s),this},off:function(t,e){return i.off(this.node,t,e),this},fire:function(e,a){return e instanceof t.Event?this.node.dispatchEvent(e):this.node.dispatchEvent(e=new i.CustomEvent(e,{detail:a,cancelable:!0})),this._event=e,this},event:function(){return this._event}}),i.Defs=i.invent({create:"defs",inherit:i.Container}),i.G=i.invent({create:"g",inherit:i.Container,extend:{x:function(t){return null==t?this.transform("x"):this.transform({x:t-this.x()},!0)}},construct:{group:function(){return this.put(new i.G)}}}),i.Doc=i.invent({create:function(t){t&&("svg"==(t="string"==typeof t?e.getElementById(t):t).nodeName?this.constructor.call(this,t):(this.constructor.call(this,i.create("svg")),t.appendChild(this.node),this.size("100%","100%")),this.namespace().defs())},inherit:i.Container,extend:{namespace:function(){return this.attr({xmlns:i.ns,version:"1.1"}).attr("xmlns:xlink",i.xlink,i.xmlns).attr("xmlns:svgjs",i.svgjs,i.xmlns)},defs:function(){var t;return this._defs||((t=this.node.getElementsByTagName("defs")[0])?this._defs=i.adopt(t):this._defs=new i.Defs,this.node.appendChild(this._defs.node)),this._defs},parent:function(){return this.node.parentNode&&"#document"!=this.node.parentNode.nodeName?this.node.parentNode:null},remove:function(){return this.parent()&&this.parent().removeChild(this.node),this},clear:function(){for(;this.node.hasChildNodes();)this.node.removeChild(this.node.lastChild);return delete this._defs,i.parser.draw&&!i.parser.draw.parentNode&&this.node.appendChild(i.parser.draw),this},clone:function(t){this.writeDataToDom();var e=this.node,i=x(e.cloneNode(!0));return t?(t.node||t).appendChild(i.node):e.parentNode.insertBefore(i.node,e.nextSibling),i}}}),i.extend(i.Element,{}),i.Gradient=i.invent({create:function(t){this.constructor.call(this,i.create(t+"Gradient")),this.type=t},inherit:i.Container,extend:{at:function(t,e,a){return this.put(new i.Stop).update(t,e,a)},update:function(t){return this.clear(),"function"==typeof t&&t.call(this,this),this},fill:function(){return"url(#"+this.id()+")"},toString:function(){return this.fill()},attr:function(t,e,a){return"transform"==t&&(t="gradientTransform"),i.Container.prototype.attr.call(this,t,e,a)}},construct:{gradient:function(t,e){return this.defs().gradient(t,e)}}}),i.extend(i.Gradient,i.FX,{from:function(t,e){return"radial"==(this._target||this).type?this.attr({fx:new i.Number(t),fy:new i.Number(e)}):this.attr({x1:new i.Number(t),y1:new i.Number(e)})},to:function(t,e){return"radial"==(this._target||this).type?this.attr({cx:new i.Number(t),cy:new i.Number(e)}):this.attr({x2:new i.Number(t),y2:new i.Number(e)})}}),i.extend(i.Defs,{gradient:function(t,e){return this.put(new i.Gradient(t)).update(e)}}),i.Stop=i.invent({create:"stop",inherit:i.Element,extend:{update:function(t){return("number"==typeof t||t instanceof i.Number)&&(t={offset:arguments[0],color:arguments[1],opacity:arguments[2]}),null!=t.opacity&&this.attr("stop-opacity",t.opacity),null!=t.color&&this.attr("stop-color",t.color),null!=t.offset&&this.attr("offset",new i.Number(t.offset)),this}}}),i.Pattern=i.invent({create:"pattern",inherit:i.Container,extend:{fill:function(){return"url(#"+this.id()+")"},update:function(t){return this.clear(),"function"==typeof t&&t.call(this,this),this},toString:function(){return this.fill()},attr:function(t,e,a){return"transform"==t&&(t="patternTransform"),i.Container.prototype.attr.call(this,t,e,a)}},construct:{pattern:function(t,e,i){return this.defs().pattern(t,e,i)}}}),i.extend(i.Defs,{pattern:function(t,e,a){return this.put(new i.Pattern).update(a).attr({x:0,y:0,width:t,height:e,patternUnits:"userSpaceOnUse"})}}),i.Shape=i.invent({create:function(t){this.constructor.call(this,t)},inherit:i.Element}),i.Symbol=i.invent({create:"symbol",inherit:i.Container,construct:{symbol:function(){return this.put(new i.Symbol)}}}),i.Use=i.invent({create:"use",inherit:i.Shape,extend:{element:function(t,e){return this.attr("href",(e||"")+"#"+t,i.xlink)}},construct:{use:function(t,e){return this.put(new i.Use).element(t,e)}}}),i.Rect=i.invent({create:"rect",inherit:i.Shape,construct:{rect:function(t,e){return this.put(new i.Rect).size(t,e)}}}),i.Circle=i.invent({create:"circle",inherit:i.Shape,construct:{circle:function(t){return this.put(new i.Circle).rx(new i.Number(t).divide(2)).move(0,0)}}}),i.extend(i.Circle,i.FX,{rx:function(t){return this.attr("r",t)},ry:function(t){return this.rx(t)}}),i.Ellipse=i.invent({create:"ellipse",inherit:i.Shape,construct:{ellipse:function(t,e){return this.put(new i.Ellipse).size(t,e).move(0,0)}}}),i.extend(i.Ellipse,i.Rect,i.FX,{rx:function(t){return this.attr("rx",t)},ry:function(t){return this.attr("ry",t)}}),i.extend(i.Circle,i.Ellipse,{x:function(t){return null==t?this.cx()-this.rx():this.cx(t+this.rx())},y:function(t){return null==t?this.cy()-this.ry():this.cy(t+this.ry())},cx:function(t){return null==t?this.attr("cx"):this.attr("cx",t)},cy:function(t){return null==t?this.attr("cy"):this.attr("cy",t)},width:function(t){return null==t?2*this.rx():this.rx(new i.Number(t).divide(2))},height:function(t){return null==t?2*this.ry():this.ry(new i.Number(t).divide(2))},size:function(t,e){var a=p(this,t,e);return this.rx(new i.Number(a.width).divide(2)).ry(new i.Number(a.height).divide(2))}}),i.Line=i.invent({create:"line",inherit:i.Shape,extend:{array:function(){return new i.PointArray([[this.attr("x1"),this.attr("y1")],[this.attr("x2"),this.attr("y2")]])},plot:function(t,e,a,s){return null==t?this.array():(t=void 0!==e?{x1:t,y1:e,x2:a,y2:s}:new i.PointArray(t).toLine(),this.attr(t))},move:function(t,e){return this.attr(this.array().move(t,e).toLine())},size:function(t,e){var i=p(this,t,e);return this.attr(this.array().size(i.width,i.height).toLine())}},construct:{line:function(t,e,a,s){return i.Line.prototype.plot.apply(this.put(new i.Line),null!=t?[t,e,a,s]:[0,0,0,0])}}}),i.Polyline=i.invent({create:"polyline",inherit:i.Shape,construct:{polyline:function(t){return this.put(new i.Polyline).plot(t||new i.PointArray)}}}),i.Polygon=i.invent({create:"polygon",inherit:i.Shape,construct:{polygon:function(t){return this.put(new i.Polygon).plot(t||new i.PointArray)}}}),i.extend(i.Polyline,i.Polygon,{array:function(){return this._array||(this._array=new i.PointArray(this.attr("points")))},plot:function(t){return null==t?this.array():this.clear().attr("points","string"==typeof t?t:this._array=new i.PointArray(t))},clear:function(){return delete this._array,this},move:function(t,e){return this.attr("points",this.array().move(t,e))},size:function(t,e){var i=p(this,t,e);return this.attr("points",this.array().size(i.width,i.height))}}),i.extend(i.Line,i.Polyline,i.Polygon,{morphArray:i.PointArray,x:function(t){return null==t?this.bbox().x:this.move(t,this.bbox().y)},y:function(t){return null==t?this.bbox().y:this.move(this.bbox().x,t)},width:function(t){var e=this.bbox();return null==t?e.width:this.size(t,e.height)},height:function(t){var e=this.bbox();return null==t?e.height:this.size(e.width,t)}}),i.Path=i.invent({create:"path",inherit:i.Shape,extend:{morphArray:i.PathArray,array:function(){return this._array||(this._array=new i.PathArray(this.attr("d")))},plot:function(t){return null==t?this.array():this.clear().attr("d","string"==typeof t?t:this._array=new i.PathArray(t))},clear:function(){return delete this._array,this}},construct:{path:function(t){return this.put(new i.Path).plot(t||new i.PathArray)}}}),i.Image=i.invent({create:"image",inherit:i.Shape,extend:{load:function(e){if(!e)return this;var a=this,s=new t.Image;return i.on(s,"load",(function(){i.off(s);var t=a.parent(i.Pattern);null!==t&&(0==a.width()&&0==a.height()&&a.size(s.width,s.height),t&&0==t.width()&&0==t.height()&&t.size(a.width(),a.height()),"function"==typeof a._loaded&&a._loaded.call(a,{width:s.width,height:s.height,ratio:s.width/s.height,url:e}))})),i.on(s,"error",(function(t){i.off(s),"function"==typeof a._error&&a._error.call(a,t)})),this.attr("href",s.src=this.src=e,i.xlink)},loaded:function(t){return this._loaded=t,this},error:function(t){return this._error=t,this}},construct:{image:function(t,e,a){return this.put(new i.Image).load(t).size(e||0,a||e||0)}}}),i.Text=i.invent({create:function(){this.constructor.call(this,i.create("text")),this.dom.leading=new i.Number(1.3),this._rebuild=!0,this._build=!1,this.attr("font-family",i.defaults.attrs["font-family"])},inherit:i.Shape,extend:{x:function(t){return null==t?this.attr("x"):this.attr("x",t)},text:function(t){if(void 0===t){t="";for(var e=this.node.childNodes,a=0,s=e.length;a<s;++a)0!=a&&3!=e[a].nodeType&&1==i.adopt(e[a]).dom.newLined&&(t+="\n"),t+=e[a].textContent;return t}if(this.clear().build(!0),"function"==typeof t)t.call(this,this);else{a=0;for(var r=(t=t.split("\n")).length;a<r;a++)this.tspan(t[a]).newLine()}return this.build(!1).rebuild()},size:function(t){return this.attr("font-size",t).rebuild()},leading:function(t){return null==t?this.dom.leading:(this.dom.leading=new i.Number(t),this.rebuild())},lines:function(){var t=(this.textPath&&this.textPath()||this).node,e=i.utils.map(i.utils.filterSVGElements(t.childNodes),(function(t){return i.adopt(t)}));return new i.Set(e)},rebuild:function(t){if("boolean"==typeof t&&(this._rebuild=t),this._rebuild){var e=this,a=0,s=this.dom.leading*new i.Number(this.attr("font-size"));this.lines().each((function(){this.dom.newLined&&(e.textPath()||this.attr("x",e.attr("x")),"\n"==this.text()?a+=s:(this.attr("dy",s+a),a=0))})),this.fire("rebuild")}return this},build:function(t){return this._build=!!t,this},setData:function(t){return this.dom=t,this.dom.leading=new i.Number(t.leading||1.3),this}},construct:{text:function(t){return this.put(new i.Text).text(t)},plain:function(t){return this.put(new i.Text).plain(t)}}}),i.Tspan=i.invent({create:"tspan",inherit:i.Shape,extend:{text:function(t){return null==t?this.node.textContent+(this.dom.newLined?"\n":""):("function"==typeof t?t.call(this,this):this.plain(t),this)},dx:function(t){return this.attr("dx",t)},dy:function(t){return this.attr("dy",t)},newLine:function(){var t=this.parent(i.Text);return this.dom.newLined=!0,this.dy(t.dom.leading*t.attr("font-size")).attr("x",t.x())}}}),i.extend(i.Text,i.Tspan,{plain:function(t){return!1===this._build&&this.clear(),this.node.appendChild(e.createTextNode(t)),this},tspan:function(t){var e=(this.textPath&&this.textPath()||this).node,a=new i.Tspan;return!1===this._build&&this.clear(),e.appendChild(a.node),a.text(t)},clear:function(){for(var t=(this.textPath&&this.textPath()||this).node;t.hasChildNodes();)t.removeChild(t.lastChild);return this},length:function(){return this.node.getComputedTextLength()}}),i.TextPath=i.invent({create:"textPath",inherit:i.Parent,parent:i.Text,construct:{morphArray:i.PathArray,array:function(){var t=this.track();return t?t.array():null},plot:function(t){var e=this.track(),i=null;return e&&(i=e.plot(t)),null==t?i:this},track:function(){var t=this.textPath();if(t)return t.reference("href")},textPath:function(){if(this.node.firstChild&&"textPath"==this.node.firstChild.nodeName)return i.adopt(this.node.firstChild)}}}),i.Nested=i.invent({create:function(){this.constructor.call(this,i.create("svg")),this.style("overflow","visible")},inherit:i.Container,construct:{nested:function(){return this.put(new i.Nested)}}});var l={stroke:["color","width","opacity","linecap","linejoin","miterlimit","dasharray","dashoffset"],fill:["color","opacity","rule"],prefix:function(t,e){return"color"==e?t:t+"-"+e}};function c(t,e,a,s){return a+s.replace(i.regex.dots," .")}function h(t){return t.toLowerCase().replace(/-(.)/g,(function(t,e){return e.toUpperCase()}))}function d(t){return t.charAt(0).toUpperCase()+t.slice(1)}function u(t){var e=t.toString(16);return 1==e.length?"0"+e:e}function p(t,e,i){if(null==e||null==i){var a=t.bbox();null==e?e=a.width/a.height*i:null==i&&(i=a.height/a.width*e)}return{width:e,height:i}}function f(t,e,i){return{x:e*t.a+i*t.c+0,y:e*t.b+i*t.d+0}}function g(t){return{a:t[0],b:t[1],c:t[2],d:t[3],e:t[4],f:t[5]}}function x(e){for(var a=e.childNodes.length-1;a>=0;a--)e.childNodes[a]instanceof t.SVGElement&&x(e.childNodes[a]);return i.adopt(e).id(i.eid(e.nodeName))}function m(t){return null==t.x&&(t.x=0,t.y=0,t.width=0,t.height=0),t.w=t.width,t.h=t.height,t.x2=t.x+t.width,t.y2=t.y+t.height,t.cx=t.x+t.width/2,t.cy=t.y+t.height/2,t}function b(t){return Math.abs(t)>1e-37?t:0}["fill","stroke"].forEach((function(t){var e={};e[t]=function(e){if(void 0===e)return this;if("string"==typeof e||i.Color.isRgb(e)||e&&"function"==typeof e.fill)this.attr(t,e);else for(var a=l[t].length-1;a>=0;a--)null!=e[l[t][a]]&&this.attr(l.prefix(t,l[t][a]),e[l[t][a]]);return this},i.extend(i.Element,i.FX,e)})),i.extend(i.Element,i.FX,{translate:function(t,e){return this.transform({x:t,y:e})},matrix:function(t){return this.attr("transform",new i.Matrix(6==arguments.length?[].slice.call(arguments):t))},opacity:function(t){return this.attr("opacity",t)},dx:function(t){return this.x(new i.Number(t).plus(this instanceof i.FX?0:this.x()),!0)},dy:function(t){return this.y(new i.Number(t).plus(this instanceof i.FX?0:this.y()),!0)}}),i.extend(i.Path,{length:function(){return this.node.getTotalLength()},pointAt:function(t){return this.node.getPointAtLength(t)}}),i.Set=i.invent({create:function(t){Array.isArray(t)?this.members=t:this.clear()},extend:{add:function(){for(var t=[].slice.call(arguments),e=0,i=t.length;e<i;e++)this.members.push(t[e]);return this},remove:function(t){var e=this.index(t);return e>-1&&this.members.splice(e,1),this},each:function(t){for(var e=0,i=this.members.length;e<i;e++)t.apply(this.members[e],[e,this.members]);return this},clear:function(){return this.members=[],this},length:function(){return this.members.length},has:function(t){return this.index(t)>=0},index:function(t){return this.members.indexOf(t)},get:function(t){return this.members[t]},first:function(){return this.get(0)},last:function(){return this.get(this.members.length-1)},valueOf:function(){return this.members}},construct:{set:function(t){return new i.Set(t)}}}),i.FX.Set=i.invent({create:function(t){this.set=t}}),i.Set.inherit=function(){var t=[];for(var e in i.Shape.prototype)"function"==typeof i.Shape.prototype[e]&&"function"!=typeof i.Set.prototype[e]&&t.push(e);for(var e in t.forEach((function(t){i.Set.prototype[t]=function(){for(var e=0,a=this.members.length;e<a;e++)this.members[e]&&"function"==typeof this.members[e][t]&&this.members[e][t].apply(this.members[e],arguments);return"animate"==t?this.fx||(this.fx=new i.FX.Set(this)):this}})),t=[],i.FX.prototype)"function"==typeof i.FX.prototype[e]&&"function"!=typeof i.FX.Set.prototype[e]&&t.push(e);t.forEach((function(t){i.FX.Set.prototype[t]=function(){for(var e=0,i=this.set.members.length;e<i;e++)this.set.members[e].fx[t].apply(this.set.members[e].fx,arguments);return this}}))},i.extend(i.Element,{}),i.extend(i.Element,{remember:function(t,e){if("object"===n(arguments[0]))for(var i in t)this.remember(i,t[i]);else{if(1==arguments.length)return this.memory()[t];this.memory()[t]=e}return this},forget:function(){if(0==arguments.length)this._memory={};else for(var t=arguments.length-1;t>=0;t--)delete this.memory()[arguments[t]];return this},memory:function(){return this._memory||(this._memory={})}}),i.get=function(t){var a=e.getElementById(function(t){var e=(t||"").toString().match(i.regex.reference);if(e)return e[1]}(t)||t);return i.adopt(a)},i.select=function(t,a){return new i.Set(i.utils.map((a||e).querySelectorAll(t),(function(t){return i.adopt(t)})))},i.extend(i.Parent,{select:function(t){return i.select(t,this.node)}});var v="abcdef".split("");if("function"!=typeof t.CustomEvent){var y=function(t,i){i=i||{bubbles:!1,cancelable:!1,detail:void 0};var a=e.createEvent("CustomEvent");return a.initCustomEvent(t,i.bubbles,i.cancelable,i.detail),a};y.prototype=t.Event.prototype,i.CustomEvent=y}else i.CustomEvent=t.CustomEvent;return i},void 0!==(a=function(){return Yt(Rt,Rt.document)}.call(e,i,e,t))&&(t.exports=a),function(){SVG.Filter=SVG.invent({create:"filter",inherit:SVG.Parent,extend:{source:"SourceGraphic",sourceAlpha:"SourceAlpha",background:"BackgroundImage",backgroundAlpha:"BackgroundAlpha",fill:"FillPaint",stroke:"StrokePaint",autoSetIn:!0,put:function(t,e){return this.add(t,e),!t.attr("in")&&this.autoSetIn&&t.attr("in",this.source),t.attr("result")||t.attr("result",t),t},blend:function(t,e,i){return this.put(new SVG.BlendEffect(t,e,i))},colorMatrix:function(t,e){return this.put(new SVG.ColorMatrixEffect(t,e))},convolveMatrix:function(t){return this.put(new SVG.ConvolveMatrixEffect(t))},componentTransfer:function(t){return this.put(new SVG.ComponentTransferEffect(t))},composite:function(t,e,i){return this.put(new SVG.CompositeEffect(t,e,i))},flood:function(t,e){return this.put(new SVG.FloodEffect(t,e))},offset:function(t,e){return this.put(new SVG.OffsetEffect(t,e))},image:function(t){return this.put(new SVG.ImageEffect(t))},merge:function(){var t=[void 0];for(var e in arguments)t.push(arguments[e]);return this.put(new(SVG.MergeEffect.bind.apply(SVG.MergeEffect,t)))},gaussianBlur:function(t,e){return this.put(new SVG.GaussianBlurEffect(t,e))},morphology:function(t,e){return this.put(new SVG.MorphologyEffect(t,e))},diffuseLighting:function(t,e,i){return this.put(new SVG.DiffuseLightingEffect(t,e,i))},displacementMap:function(t,e,i,a,s){return this.put(new SVG.DisplacementMapEffect(t,e,i,a,s))},specularLighting:function(t,e,i,a){return this.put(new SVG.SpecularLightingEffect(t,e,i,a))},tile:function(){return this.put(new SVG.TileEffect)},turbulence:function(t,e,i,a,s){return this.put(new SVG.TurbulenceEffect(t,e,i,a,s))},toString:function(){return"url(#"+this.attr("id")+")"}}}),SVG.extend(SVG.Defs,{filter:function(t){var e=this.put(new SVG.Filter);return"function"==typeof t&&t.call(e,e),e}}),SVG.extend(SVG.Container,{filter:function(t){return this.defs().filter(t)}}),SVG.extend(SVG.Element,SVG.G,SVG.Nested,{filter:function(t){return this.filterer=t instanceof SVG.Element?t:this.doc().filter(t),this.doc()&&this.filterer.doc()!==this.doc()&&this.doc().defs().add(this.filterer),this.attr("filter",this.filterer),this.filterer},unfilter:function(t){return this.filterer&&!0===t&&this.filterer.remove(),delete this.filterer,this.attr("filter",null)}}),SVG.Effect=SVG.invent({create:function(){this.constructor.call(this)},inherit:SVG.Element,extend:{in:function(t){return null==t?this.parent()&&this.parent().select('[result="'+this.attr("in")+'"]').get(0)||this.attr("in"):this.attr("in",t)},result:function(t){return null==t?this.attr("result"):this.attr("result",t)},toString:function(){return this.result()}}}),SVG.ParentEffect=SVG.invent({create:function(){this.constructor.call(this)},inherit:SVG.Parent,extend:{in:function(t){return null==t?this.parent()&&this.parent().select('[result="'+this.attr("in")+'"]').get(0)||this.attr("in"):this.attr("in",t)},result:function(t){return null==t?this.attr("result"):this.attr("result",t)},toString:function(){return this.result()}}});var t={blend:function(t,e){return this.parent()&&this.parent().blend(this,t,e)},colorMatrix:function(t,e){return this.parent()&&this.parent().colorMatrix(t,e).in(this)},convolveMatrix:function(t){return this.parent()&&this.parent().convolveMatrix(t).in(this)},componentTransfer:function(t){return this.parent()&&this.parent().componentTransfer(t).in(this)},composite:function(t,e){return this.parent()&&this.parent().composite(this,t,e)},flood:function(t,e){return this.parent()&&this.parent().flood(t,e)},offset:function(t,e){return this.parent()&&this.parent().offset(t,e).in(this)},image:function(t){return this.parent()&&this.parent().image(t)},merge:function(){return this.parent()&&this.parent().merge.apply(this.parent(),[this].concat(arguments))},gaussianBlur:function(t,e){return this.parent()&&this.parent().gaussianBlur(t,e).in(this)},morphology:function(t,e){return this.parent()&&this.parent().morphology(t,e).in(this)},diffuseLighting:function(t,e,i){return this.parent()&&this.parent().diffuseLighting(t,e,i).in(this)},displacementMap:function(t,e,i,a){return this.parent()&&this.parent().displacementMap(this,t,e,i,a)},specularLighting:function(t,e,i,a){return this.parent()&&this.parent().specularLighting(t,e,i,a).in(this)},tile:function(){return this.parent()&&this.parent().tile().in(this)},turbulence:function(t,e,i,a,s){return this.parent()&&this.parent().turbulence(t,e,i,a,s).in(this)}};SVG.extend(SVG.Effect,t),SVG.extend(SVG.ParentEffect,t),SVG.ChildEffect=SVG.invent({create:function(){this.constructor.call(this)},inherit:SVG.Element,extend:{in:function(t){this.attr("in",t)}}});var e={blend:function(t,e,i){this.attr({in:t,in2:e,mode:i||"normal"})},colorMatrix:function(t,e){"matrix"==t&&(e=s(e)),this.attr({type:t,values:void 0===e?null:e})},convolveMatrix:function(t){t=s(t),this.attr({order:Math.sqrt(t.split(" ").length),kernelMatrix:t})},composite:function(t,e,i){this.attr({in:t,in2:e,operator:i})},flood:function(t,e){this.attr("flood-color",t),null!=e&&this.attr("flood-opacity",e)},offset:function(t,e){this.attr({dx:t,dy:e})},image:function(t){this.attr("href",t,SVG.xlink)},displacementMap:function(t,e,i,a,s){this.attr({in:t,in2:e,scale:i,xChannelSelector:a,yChannelSelector:s})},gaussianBlur:function(t,e){null!=t||null!=e?this.attr("stdDeviation",r(Array.prototype.slice.call(arguments))):this.attr("stdDeviation","0 0")},morphology:function(t,e){this.attr({operator:t,radius:e})},tile:function(){},turbulence:function(t,e,i,a,s){this.attr({numOctaves:e,seed:i,stitchTiles:a,baseFrequency:t,type:s})}},i={merge:function(){var t;if(arguments[0]instanceof SVG.Set){var e=this;arguments[0].each((function(t){this instanceof SVG.MergeNode?e.put(this):(this instanceof SVG.Effect||this instanceof SVG.ParentEffect)&&e.put(new SVG.MergeNode(this))}))}else{t=Array.isArray(arguments[0])?arguments[0]:arguments;for(var i=0;i<t.length;i++)t[i]instanceof SVG.MergeNode?this.put(t[i]):this.put(new SVG.MergeNode(t[i]))}},componentTransfer:function(t){if(this.rgb=new SVG.Set,["r","g","b","a"].forEach(function(t){this[t]=new(SVG["Func"+t.toUpperCase()])("identity"),this.rgb.add(this[t]),this.node.appendChild(this[t].node)}.bind(this)),t)for(var e in t.rgb&&(["r","g","b"].forEach(function(e){this[e].attr(t.rgb)}.bind(this)),delete t.rgb),t)this[e].attr(t[e])},diffuseLighting:function(t,e,i){this.attr({surfaceScale:t,diffuseConstant:e,kernelUnitLength:i})},specularLighting:function(t,e,i,a){this.attr({surfaceScale:t,diffuseConstant:e,specularExponent:i,kernelUnitLength:a})}},a={distantLight:function(t,e){this.attr({azimuth:t,elevation:e})},pointLight:function(t,e,i){this.attr({x:t,y:e,z:i})},spotLight:function(t,e,i,a,s,r){this.attr({x:t,y:e,z:i,pointsAtX:a,pointsAtY:s,pointsAtZ:r})},mergeNode:function(t){this.attr("in",t)}};function s(t){return Array.isArray(t)&&(t=new SVG.Array(t)),t.toString().replace(/^\s+/,"").replace(/\s+$/,"").replace(/\s+/g," ")}function r(t){if(!Array.isArray(t))return t;for(var e=0,i=t.length,a=[];e<i;e++)a.push(t[e]);return a.join(" ")}function n(){var t=function(){};for(var e in"function"==typeof arguments[arguments.length-1]&&(t=arguments[arguments.length-1],Array.prototype.splice.call(arguments,arguments.length-1,1)),arguments)for(var i in arguments[e])t(arguments[e][i],i,arguments[e])}["r","g","b","a"].forEach((function(t){a["Func"+t.toUpperCase()]=function(t){switch(this.attr("type",t),t){case"table":this.attr("tableValues",arguments[1]);break;case"linear":this.attr("slope",arguments[1]),this.attr("intercept",arguments[2]);break;case"gamma":this.attr("amplitude",arguments[1]),this.attr("exponent",arguments[2]),this.attr("offset",arguments[2])}}})),n(e,(function(t,e){var i=e.charAt(0).toUpperCase()+e.slice(1);SVG[i+"Effect"]=SVG.invent({create:function(){this.constructor.call(this,SVG.create("fe"+i)),t.apply(this,arguments),this.result(this.attr("id")+"Out")},inherit:SVG.Effect,extend:{}})})),n(i,(function(t,e){var i=e.charAt(0).toUpperCase()+e.slice(1);SVG[i+"Effect"]=SVG.invent({create:function(){this.constructor.call(this,SVG.create("fe"+i)),t.apply(this,arguments),this.result(this.attr("id")+"Out")},inherit:SVG.ParentEffect,extend:{}})})),n(a,(function(t,e){var i=e.charAt(0).toUpperCase()+e.slice(1);SVG[i]=SVG.invent({create:function(){this.constructor.call(this,SVG.create("fe"+i)),t.apply(this,arguments)},inherit:SVG.ChildEffect,extend:{}})})),SVG.extend(SVG.MergeEffect,{in:function(t){return t instanceof SVG.MergeNode?this.add(t,0):this.add(new SVG.MergeNode(t),0),this}}),SVG.extend(SVG.CompositeEffect,SVG.BlendEffect,SVG.DisplacementMapEffect,{in2:function(t){return null==t?this.parent()&&this.parent().select('[result="'+this.attr("in2")+'"]').get(0)||this.attr("in2"):this.attr("in2",t)}}),SVG.filter={sepiatone:[.343,.669,.119,0,0,.249,.626,.13,0,0,.172,.334,.111,0,0,0,0,0,1,0]}}.call(void 0),function(){function t(t,s,r,n,o,l,c){for(var h=t.slice(s,r||c),d=n.slice(o,l||c),u=0,p={pos:[0,0],start:[0,0]},f={pos:[0,0],start:[0,0]};h[u]=e.call(p,h[u]),d[u]=e.call(f,d[u]),h[u][0]!=d[u][0]||"M"==h[u][0]||"A"==h[u][0]&&(h[u][4]!=d[u][4]||h[u][5]!=d[u][5])?(Array.prototype.splice.apply(h,[u,1].concat(a.call(p,h[u]))),Array.prototype.splice.apply(d,[u,1].concat(a.call(f,d[u])))):(h[u]=i.call(p,h[u]),d[u]=i.call(f,d[u])),++u!=h.length||u!=d.length;)u==h.length&&h.push(["C",p.pos[0],p.pos[1],p.pos[0],p.pos[1],p.pos[0],p.pos[1]]),u==d.length&&d.push(["C",f.pos[0],f.pos[1],f.pos[0],f.pos[1],f.pos[0],f.pos[1]]);return{start:h,dest:d}}function e(t){switch(t[0]){case"z":case"Z":t[0]="L",t[1]=this.start[0],t[2]=this.start[1];break;case"H":t[0]="L",t[2]=this.pos[1];break;case"V":t[0]="L",t[2]=t[1],t[1]=this.pos[0];break;case"T":t[0]="Q",t[3]=t[1],t[4]=t[2],t[1]=this.reflection[1],t[2]=this.reflection[0];break;case"S":t[0]="C",t[6]=t[4],t[5]=t[3],t[4]=t[2],t[3]=t[1],t[2]=this.reflection[1],t[1]=this.reflection[0]}return t}function i(t){var e=t.length;return this.pos=[t[e-2],t[e-1]],-1!="SCQT".indexOf(t[0])&&(this.reflection=[2*this.pos[0]-t[e-4],2*this.pos[1]-t[e-3]]),t}function a(t){var e=[t];switch(t[0]){case"M":return this.pos=this.start=[t[1],t[2]],e;case"L":t[5]=t[3]=t[1],t[6]=t[4]=t[2],t[1]=this.pos[0],t[2]=this.pos[1];break;case"Q":t[6]=t[4],t[5]=t[3],t[4]=1*t[4]/3+2*t[2]/3,t[3]=1*t[3]/3+2*t[1]/3,t[2]=1*this.pos[1]/3+2*t[2]/3,t[1]=1*this.pos[0]/3+2*t[1]/3;break;case"A":e=function(t,e){var i,a,s,r,n,o,l,c,h,d,u,p,f,g,x,m,b,v,y,w,k,A,S,C,P,L,D=Math.abs(e[1]),T=Math.abs(e[2]),M=e[3]%360,E=e[4],I=e[5],O=e[6],z=e[7],R=new SVG.Point(t),Y=new SVG.Point(O,z),F=[];if(0===D||0===T||R.x===Y.x&&R.y===Y.y)return[["C",R.x,R.y,Y.x,Y.y,Y.x,Y.y]];for((a=(i=new SVG.Point((R.x-Y.x)/2,(R.y-Y.y)/2).transform((new SVG.Matrix).rotate(M))).x*i.x/(D*D)+i.y*i.y/(T*T))>1&&(D*=a=Math.sqrt(a),T*=a),s=(new SVG.Matrix).rotate(M).scale(1/D,1/T).rotate(-M),R=R.transform(s),o=(r=[(Y=Y.transform(s)).x-R.x,Y.y-R.y])[0]*r[0]+r[1]*r[1],n=Math.sqrt(o),r[0]/=n,r[1]/=n,l=o<4?Math.sqrt(1-o/4):0,E===I&&(l*=-1),c=new SVG.Point((Y.x+R.x)/2+l*-r[1],(Y.y+R.y)/2+l*r[0]),h=new SVG.Point(R.x-c.x,R.y-c.y),d=new SVG.Point(Y.x-c.x,Y.y-c.y),u=Math.acos(h.x/Math.sqrt(h.x*h.x+h.y*h.y)),h.y<0&&(u*=-1),p=Math.acos(d.x/Math.sqrt(d.x*d.x+d.y*d.y)),d.y<0&&(p*=-1),I&&u>p&&(p+=2*Math.PI),!I&&u<p&&(p-=2*Math.PI),m=[],b=u,f=(p-u)/(g=Math.ceil(2*Math.abs(u-p)/Math.PI)),x=4*Math.tan(f/4)/3,k=0;k<=g;k++)y=Math.cos(b),v=Math.sin(b),w=new SVG.Point(c.x+y,c.y+v),m[k]=[new SVG.Point(w.x+x*v,w.y-x*y),w,new SVG.Point(w.x-x*v,w.y+x*y)],b+=f;for(m[0][0]=m[0][1].clone(),m[m.length-1][2]=m[m.length-1][1].clone(),s=(new SVG.Matrix).rotate(M).scale(D,T).rotate(-M),k=0,A=m.length;k<A;k++)m[k][0]=m[k][0].transform(s),m[k][1]=m[k][1].transform(s),m[k][2]=m[k][2].transform(s);for(k=1,A=m.length;k<A;k++)S=(w=m[k-1][2]).x,C=w.y,P=(w=m[k][0]).x,L=w.y,O=(w=m[k][1]).x,z=w.y,F.push(["C",S,C,P,L,O,z]);return F}(this.pos,t),t=e[0]}return t[0]="C",this.pos=[t[5],t[6]],this.reflection=[2*t[5]-t[3],2*t[6]-t[4]],e}function s(t,e){if(!1===e)return!1;for(var i=e,a=t.length;i<a;++i)if("M"==t[i][0])return i;return!1}SVG.extend(SVG.PathArray,{morph:function(e){for(var i=this.value,a=this.parse(e),r=0,n=0,o=!1,l=!1;!1!==r||!1!==n;){var c;o=s(i,!1!==r&&r+1),l=s(a,!1!==n&&n+1),!1===r&&(r=0==(c=new SVG.PathArray(h.start).bbox()).height||0==c.width?i.push(i[0])-1:i.push(["M",c.x+c.width/2,c.y+c.height/2])-1),!1===n&&(n=0==(c=new SVG.PathArray(h.dest).bbox()).height||0==c.width?a.push(a[0])-1:a.push(["M",c.x+c.width/2,c.y+c.height/2])-1);var h=t(i,r,o,a,n,l);i=i.slice(0,r).concat(h.start,!1===o?[]:i.slice(o)),a=a.slice(0,n).concat(h.dest,!1===l?[]:a.slice(l)),r=!1!==o&&r+h.start.length,n=!1!==l&&n+h.dest.length}return this.value=i,this.destination=new SVG.PathArray,this.destination.value=a,this}})}(),function(){function t(t){t.remember("_draggable",this),this.el=t}t.prototype.init=function(t,e){var i=this;this.constraint=t,this.value=e,this.el.on("mousedown.drag",(function(t){i.start(t)})),this.el.on("touchstart.drag",(function(t){i.start(t)}))},t.prototype.transformPoint=function(t,e){var i=(t=t||window.event).changedTouches&&t.changedTouches[0]||t;return this.p.x=i.clientX-(e||0),this.p.y=i.clientY,this.p.matrixTransform(this.m)},t.prototype.getBBox=function(){var t=this.el.bbox();return this.el instanceof SVG.Nested&&(t=this.el.rbox()),(this.el instanceof SVG.G||this.el instanceof SVG.Use||this.el instanceof SVG.Nested)&&(t.x=this.el.x(),t.y=this.el.y()),t},t.prototype.start=function(t){if("click"!=t.type&&"mousedown"!=t.type&&"mousemove"!=t.type||1==(t.which||t.buttons)){var e=this;if(this.el.fire("beforedrag",{event:t,handler:this}),!this.el.event().defaultPrevented){t.preventDefault(),t.stopPropagation(),this.parent=this.parent||this.el.parent(SVG.Nested)||this.el.parent(SVG.Doc),this.p=this.parent.node.createSVGPoint(),this.m=this.el.node.getScreenCTM().inverse();var i,a=this.getBBox();if(this.el instanceof SVG.Text)switch(i=this.el.node.getComputedTextLength(),this.el.attr("text-anchor")){case"middle":i/=2;break;case"start":i=0}this.startPoints={point:this.transformPoint(t,i),box:a,transform:this.el.transform()},SVG.on(window,"mousemove.drag",(function(t){e.drag(t)})),SVG.on(window,"touchmove.drag",(function(t){e.drag(t)})),SVG.on(window,"mouseup.drag",(function(t){e.end(t)})),SVG.on(window,"touchend.drag",(function(t){e.end(t)})),this.el.fire("dragstart",{event:t,p:this.startPoints.point,m:this.m,handler:this})}}},t.prototype.drag=function(t){var e=this.getBBox(),i=this.transformPoint(t),a=this.startPoints.box.x+i.x-this.startPoints.point.x,s=this.startPoints.box.y+i.y-this.startPoints.point.y,r=this.constraint,n=i.x-this.startPoints.point.x,o=i.y-this.startPoints.point.y;if(this.el.fire("dragmove",{event:t,p:i,m:this.m,handler:this}),this.el.event().defaultPrevented)return i;if("function"==typeof r){var l=r.call(this.el,a,s,this.m);"boolean"==typeof l&&(l={x:l,y:l}),!0===l.x?this.el.x(a):!1!==l.x&&this.el.x(l.x),!0===l.y?this.el.y(s):!1!==l.y&&this.el.y(l.y)}else"object"==typeof r&&(null!=r.minX&&a<r.minX?n=(a=r.minX)-this.startPoints.box.x:null!=r.maxX&&a>r.maxX-e.width&&(n=(a=r.maxX-e.width)-this.startPoints.box.x),null!=r.minY&&s<r.minY?o=(s=r.minY)-this.startPoints.box.y:null!=r.maxY&&s>r.maxY-e.height&&(o=(s=r.maxY-e.height)-this.startPoints.box.y),null!=r.snapToGrid&&(a-=a%r.snapToGrid,s-=s%r.snapToGrid,n-=n%r.snapToGrid,o-=o%r.snapToGrid),this.el instanceof SVG.G?this.el.matrix(this.startPoints.transform).transform({x:n,y:o},!0):this.el.move(a,s));return i},t.prototype.end=function(t){var e=this.drag(t);this.el.fire("dragend",{event:t,p:e,m:this.m,handler:this}),SVG.off(window,"mousemove.drag"),SVG.off(window,"touchmove.drag"),SVG.off(window,"mouseup.drag"),SVG.off(window,"touchend.drag")},SVG.extend(SVG.Element,{draggable:function(e,i){"function"!=typeof e&&"object"!=typeof e||(i=e,e=!0);var a=this.remember("_draggable")||new t(this);return(e=void 0===e||e)?a.init(i||{},e):(this.off("mousedown.drag"),this.off("touchstart.drag")),this}})}.call(void 0),function(){function t(t){this.el=t,t.remember("_selectHandler",this),this.pointSelection={isSelected:!1},this.rectSelection={isSelected:!1},this.pointsList={lt:[0,0],rt:["width",0],rb:["width","height"],lb:[0,"height"],t:["width",0],r:["width","height"],b:["width","height"],l:[0,"height"]},this.pointCoord=function(t,e,i){var a="string"!=typeof t?t:e[t];return i?a/2:a},this.pointCoords=function(t,e){var i=this.pointsList[t];return{x:this.pointCoord(i[0],e,"t"===t||"b"===t),y:this.pointCoord(i[1],e,"r"===t||"l"===t)}}}t.prototype.init=function(t,e){var i=this.el.bbox();this.options={};var a=this.el.selectize.defaults.points;for(var s in this.el.selectize.defaults)this.options[s]=this.el.selectize.defaults[s],void 0!==e[s]&&(this.options[s]=e[s]);var r=["points","pointsExclude"];for(var s in r){var n=this.options[r[s]];"string"==typeof n?n=n.length>0?n.split(/\s*,\s*/i):[]:"boolean"==typeof n&&"points"===r[s]&&(n=n?a:[]),this.options[r[s]]=n}this.options.points=[a,this.options.points].reduce((function(t,e){return t.filter((function(t){return e.indexOf(t)>-1}))})),this.options.points=[this.options.points,this.options.pointsExclude].reduce((function(t,e){return t.filter((function(t){return e.indexOf(t)<0}))})),this.parent=this.el.parent(),this.nested=this.nested||this.parent.group(),this.nested.matrix(new SVG.Matrix(this.el).translate(i.x,i.y)),this.options.deepSelect&&-1!==["line","polyline","polygon"].indexOf(this.el.type)?this.selectPoints(t):this.selectRect(t),this.observe(),this.cleanup()},t.prototype.selectPoints=function(t){return this.pointSelection.isSelected=t,this.pointSelection.set||(this.pointSelection.set=this.parent.set(),this.drawPoints()),this},t.prototype.getPointArray=function(){var t=this.el.bbox();return this.el.array().valueOf().map((function(e){return[e[0]-t.x,e[1]-t.y]}))},t.prototype.drawPoints=function(){for(var t=this,e=this.getPointArray(),i=0,a=e.length;i<a;++i){var s=function(e){return function(i){(i=i||window.event).preventDefault?i.preventDefault():i.returnValue=!1,i.stopPropagation();var a=i.pageX||i.touches[0].pageX,s=i.pageY||i.touches[0].pageY;t.el.fire("point",{x:a,y:s,i:e,event:i})}}(i),r=this.drawPoint(e[i][0],e[i][1]).addClass(this.options.classPoints).addClass(this.options.classPoints+"_point").on("touchstart",s).on("mousedown",s);this.pointSelection.set.add(r)}},t.prototype.drawPoint=function(t,e){var i=this.options.pointType;switch(i){case"circle":return this.drawCircle(t,e);case"rect":return this.drawRect(t,e);default:if("function"==typeof i)return i.call(this,t,e);throw new Error("Unknown "+i+" point type!")}},t.prototype.drawCircle=function(t,e){return this.nested.circle(this.options.pointSize).center(t,e)},t.prototype.drawRect=function(t,e){return this.nested.rect(this.options.pointSize,this.options.pointSize).center(t,e)},t.prototype.updatePointSelection=function(){var t=this.getPointArray();this.pointSelection.set.each((function(e){this.cx()===t[e][0]&&this.cy()===t[e][1]||this.center(t[e][0],t[e][1])}))},t.prototype.updateRectSelection=function(){var t=this,e=this.el.bbox();if(this.rectSelection.set.get(0).attr({width:e.width,height:e.height}),this.options.points.length&&this.options.points.map((function(i,a){var s=t.pointCoords(i,e);t.rectSelection.set.get(a+1).center(s.x,s.y)})),this.options.rotationPoint){var i=this.rectSelection.set.length();this.rectSelection.set.get(i-1).center(e.width/2,20)}},t.prototype.selectRect=function(t){var e=this,i=this.el.bbox();function a(t){return function(i){(i=i||window.event).preventDefault?i.preventDefault():i.returnValue=!1,i.stopPropagation();var a=i.pageX||i.touches[0].pageX,s=i.pageY||i.touches[0].pageY;e.el.fire(t,{x:a,y:s,event:i})}}if(this.rectSelection.isSelected=t,this.rectSelection.set=this.rectSelection.set||this.parent.set(),this.rectSelection.set.get(0)||this.rectSelection.set.add(this.nested.rect(i.width,i.height).addClass(this.options.classRect)),this.options.points.length&&this.rectSelection.set.length()<2&&(this.options.points.map((function(t,s){var r=e.pointCoords(t,i),n=e.drawPoint(r.x,r.y).attr("class",e.options.classPoints+"_"+t).on("mousedown",a(t)).on("touchstart",a(t));e.rectSelection.set.add(n)})),this.rectSelection.set.each((function(){this.addClass(e.options.classPoints)}))),this.options.rotationPoint&&(this.options.points&&!this.rectSelection.set.get(9)||!this.options.points&&!this.rectSelection.set.get(1))){var s=function(t){(t=t||window.event).preventDefault?t.preventDefault():t.returnValue=!1,t.stopPropagation();var i=t.pageX||t.touches[0].pageX,a=t.pageY||t.touches[0].pageY;e.el.fire("rot",{x:i,y:a,event:t})},r=this.drawPoint(i.width/2,20).attr("class",this.options.classPoints+"_rot").on("touchstart",s).on("mousedown",s);this.rectSelection.set.add(r)}},t.prototype.handler=function(){var t=this.el.bbox();this.nested.matrix(new SVG.Matrix(this.el).translate(t.x,t.y)),this.rectSelection.isSelected&&this.updateRectSelection(),this.pointSelection.isSelected&&this.updatePointSelection()},t.prototype.observe=function(){var t=this;if(MutationObserver)if(this.rectSelection.isSelected||this.pointSelection.isSelected)this.observerInst=this.observerInst||new MutationObserver((function(){t.handler()})),this.observerInst.observe(this.el.node,{attributes:!0});else try{this.observerInst.disconnect(),delete this.observerInst}catch(t){}else this.el.off("DOMAttrModified.select"),(this.rectSelection.isSelected||this.pointSelection.isSelected)&&this.el.on("DOMAttrModified.select",(function(){t.handler()}))},t.prototype.cleanup=function(){!this.rectSelection.isSelected&&this.rectSelection.set&&(this.rectSelection.set.each((function(){this.remove()})),this.rectSelection.set.clear(),delete this.rectSelection.set),!this.pointSelection.isSelected&&this.pointSelection.set&&(this.pointSelection.set.each((function(){this.remove()})),this.pointSelection.set.clear(),delete this.pointSelection.set),this.pointSelection.isSelected||this.rectSelection.isSelected||(this.nested.remove(),delete this.nested)},SVG.extend(SVG.Element,{selectize:function(e,i){return"object"==typeof e&&(i=e,e=!0),(this.remember("_selectHandler")||new t(this)).init(void 0===e||e,i||{}),this}}),SVG.Element.prototype.selectize.defaults={points:["lt","rt","rb","lb","t","r","b","l"],pointsExclude:[],classRect:"svg_select_boundingRect",classPoints:"svg_select_points",pointSize:7,rotationPoint:!0,deepSelect:!1,pointType:"circle"}}(),function(){(function(){function t(t){t.remember("_resizeHandler",this),this.el=t,this.parameters={},this.lastUpdateCall=null,this.p=t.doc().node.createSVGPoint()}t.prototype.transformPoint=function(t,e,i){return this.p.x=t-(this.offset.x-window.pageXOffset),this.p.y=e-(this.offset.y-window.pageYOffset),this.p.matrixTransform(i||this.m)},t.prototype._extractPosition=function(t){return{x:null!=t.clientX?t.clientX:t.touches[0].clientX,y:null!=t.clientY?t.clientY:t.touches[0].clientY}},t.prototype.init=function(t){var e=this;if(this.stop(),"stop"!==t){for(var i in this.options={},this.el.resize.defaults)this.options[i]=this.el.resize.defaults[i],void 0!==t[i]&&(this.options[i]=t[i]);this.el.on("lt.resize",(function(t){e.resize(t||window.event)})),this.el.on("rt.resize",(function(t){e.resize(t||window.event)})),this.el.on("rb.resize",(function(t){e.resize(t||window.event)})),this.el.on("lb.resize",(function(t){e.resize(t||window.event)})),this.el.on("t.resize",(function(t){e.resize(t||window.event)})),this.el.on("r.resize",(function(t){e.resize(t||window.event)})),this.el.on("b.resize",(function(t){e.resize(t||window.event)})),this.el.on("l.resize",(function(t){e.resize(t||window.event)})),this.el.on("rot.resize",(function(t){e.resize(t||window.event)})),this.el.on("point.resize",(function(t){e.resize(t||window.event)})),this.update()}},t.prototype.stop=function(){return this.el.off("lt.resize"),this.el.off("rt.resize"),this.el.off("rb.resize"),this.el.off("lb.resize"),this.el.off("t.resize"),this.el.off("r.resize"),this.el.off("b.resize"),this.el.off("l.resize"),this.el.off("rot.resize"),this.el.off("point.resize"),this},t.prototype.resize=function(t){var e=this;this.m=this.el.node.getScreenCTM().inverse(),this.offset={x:window.pageXOffset,y:window.pageYOffset};var i=this._extractPosition(t.detail.event);if(this.parameters={type:this.el.type,p:this.transformPoint(i.x,i.y),x:t.detail.x,y:t.detail.y,box:this.el.bbox(),rotation:this.el.transform().rotation},"text"===this.el.type&&(this.parameters.fontSize=this.el.attr()["font-size"]),void 0!==t.detail.i){var a=this.el.array().valueOf();this.parameters.i=t.detail.i,this.parameters.pointCoords=[a[t.detail.i][0],a[t.detail.i][1]]}switch(t.type){case"lt":this.calc=function(t,e){var i=this.snapToGrid(t,e);if(this.parameters.box.width-i[0]>0&&this.parameters.box.height-i[1]>0){if("text"===this.parameters.type)return this.el.move(this.parameters.box.x+i[0],this.parameters.box.y),void this.el.attr("font-size",this.parameters.fontSize-i[0]);i=this.checkAspectRatio(i),this.el.move(this.parameters.box.x+i[0],this.parameters.box.y+i[1]).size(this.parameters.box.width-i[0],this.parameters.box.height-i[1])}};break;case"rt":this.calc=function(t,e){var i=this.snapToGrid(t,e,2);if(this.parameters.box.width+i[0]>0&&this.parameters.box.height-i[1]>0){if("text"===this.parameters.type)return this.el.move(this.parameters.box.x-i[0],this.parameters.box.y),void this.el.attr("font-size",this.parameters.fontSize+i[0]);i=this.checkAspectRatio(i,!0),this.el.move(this.parameters.box.x,this.parameters.box.y+i[1]).size(this.parameters.box.width+i[0],this.parameters.box.height-i[1])}};break;case"rb":this.calc=function(t,e){var i=this.snapToGrid(t,e,0);if(this.parameters.box.width+i[0]>0&&this.parameters.box.height+i[1]>0){if("text"===this.parameters.type)return this.el.move(this.parameters.box.x-i[0],this.parameters.box.y),void this.el.attr("font-size",this.parameters.fontSize+i[0]);i=this.checkAspectRatio(i),this.el.move(this.parameters.box.x,this.parameters.box.y).size(this.parameters.box.width+i[0],this.parameters.box.height+i[1])}};break;case"lb":this.calc=function(t,e){var i=this.snapToGrid(t,e,1);if(this.parameters.box.width-i[0]>0&&this.parameters.box.height+i[1]>0){if("text"===this.parameters.type)return this.el.move(this.parameters.box.x+i[0],this.parameters.box.y),void this.el.attr("font-size",this.parameters.fontSize-i[0]);i=this.checkAspectRatio(i,!0),this.el.move(this.parameters.box.x+i[0],this.parameters.box.y).size(this.parameters.box.width-i[0],this.parameters.box.height+i[1])}};break;case"t":this.calc=function(t,e){var i=this.snapToGrid(t,e,2);if(this.parameters.box.height-i[1]>0){if("text"===this.parameters.type)return;this.el.move(this.parameters.box.x,this.parameters.box.y+i[1]).height(this.parameters.box.height-i[1])}};break;case"r":this.calc=function(t,e){var i=this.snapToGrid(t,e,0);if(this.parameters.box.width+i[0]>0){if("text"===this.parameters.type)return;this.el.move(this.parameters.box.x,this.parameters.box.y).width(this.parameters.box.width+i[0])}};break;case"b":this.calc=function(t,e){var i=this.snapToGrid(t,e,0);if(this.parameters.box.height+i[1]>0){if("text"===this.parameters.type)return;this.el.move(this.parameters.box.x,this.parameters.box.y).height(this.parameters.box.height+i[1])}};break;case"l":this.calc=function(t,e){var i=this.snapToGrid(t,e,1);if(this.parameters.box.width-i[0]>0){if("text"===this.parameters.type)return;this.el.move(this.parameters.box.x+i[0],this.parameters.box.y).width(this.parameters.box.width-i[0])}};break;case"rot":this.calc=function(t,e){var i=t+this.parameters.p.x,a=e+this.parameters.p.y,s=Math.atan2(this.parameters.p.y-this.parameters.box.y-this.parameters.box.height/2,this.parameters.p.x-this.parameters.box.x-this.parameters.box.width/2),r=Math.atan2(a-this.parameters.box.y-this.parameters.box.height/2,i-this.parameters.box.x-this.parameters.box.width/2),n=this.parameters.rotation+180*(r-s)/Math.PI+this.options.snapToAngle/2;this.el.center(this.parameters.box.cx,this.parameters.box.cy).rotate(n-n%this.options.snapToAngle,this.parameters.box.cx,this.parameters.box.cy)};break;case"point":this.calc=function(t,e){var i=this.snapToGrid(t,e,this.parameters.pointCoords[0],this.parameters.pointCoords[1]),a=this.el.array().valueOf();a[this.parameters.i][0]=this.parameters.pointCoords[0]+i[0],a[this.parameters.i][1]=this.parameters.pointCoords[1]+i[1],this.el.plot(a)}}this.el.fire("resizestart",{dx:this.parameters.x,dy:this.parameters.y,event:t}),SVG.on(window,"touchmove.resize",(function(t){e.update(t||window.event)})),SVG.on(window,"touchend.resize",(function(){e.done()})),SVG.on(window,"mousemove.resize",(function(t){e.update(t||window.event)})),SVG.on(window,"mouseup.resize",(function(){e.done()}))},t.prototype.update=function(t){if(t){var e=this._extractPosition(t),i=this.transformPoint(e.x,e.y),a=i.x-this.parameters.p.x,s=i.y-this.parameters.p.y;this.lastUpdateCall=[a,s],this.calc(a,s),this.el.fire("resizing",{dx:a,dy:s,event:t})}else this.lastUpdateCall&&this.calc(this.lastUpdateCall[0],this.lastUpdateCall[1])},t.prototype.done=function(){this.lastUpdateCall=null,SVG.off(window,"mousemove.resize"),SVG.off(window,"mouseup.resize"),SVG.off(window,"touchmove.resize"),SVG.off(window,"touchend.resize"),this.el.fire("resizedone")},t.prototype.snapToGrid=function(t,e,i,a){var s;return void 0!==a?s=[(i+t)%this.options.snapToGrid,(a+e)%this.options.snapToGrid]:(i=null==i?3:i,s=[(this.parameters.box.x+t+(1&i?0:this.parameters.box.width))%this.options.snapToGrid,(this.parameters.box.y+e+(2&i?0:this.parameters.box.height))%this.options.snapToGrid]),t<0&&(s[0]-=this.options.snapToGrid),e<0&&(s[1]-=this.options.snapToGrid),t-=Math.abs(s[0])<this.options.snapToGrid/2?s[0]:s[0]-(t<0?-this.options.snapToGrid:this.options.snapToGrid),e-=Math.abs(s[1])<this.options.snapToGrid/2?s[1]:s[1]-(e<0?-this.options.snapToGrid:this.options.snapToGrid),this.constraintToBox(t,e,i,a)},t.prototype.constraintToBox=function(t,e,i,a){var s,r,n=this.options.constraint||{};return void 0!==a?(s=i,r=a):(s=this.parameters.box.x+(1&i?0:this.parameters.box.width),r=this.parameters.box.y+(2&i?0:this.parameters.box.height)),void 0!==n.minX&&s+t<n.minX&&(t=n.minX-s),void 0!==n.maxX&&s+t>n.maxX&&(t=n.maxX-s),void 0!==n.minY&&r+e<n.minY&&(e=n.minY-r),void 0!==n.maxY&&r+e>n.maxY&&(e=n.maxY-r),[t,e]},t.prototype.checkAspectRatio=function(t,e){if(!this.options.saveAspectRatio)return t;var i=t.slice(),a=this.parameters.box.width/this.parameters.box.height,s=this.parameters.box.width+t[0],r=this.parameters.box.height-t[1],n=s/r;return n<a?(i[1]=s/a-this.parameters.box.height,e&&(i[1]=-i[1])):n>a&&(i[0]=this.parameters.box.width-r*a,e&&(i[0]=-i[0])),i},SVG.extend(SVG.Element,{resize:function(e){return(this.remember("_resizeHandler")||new t(this)).init(e||{}),this}}),SVG.Element.prototype.resize.defaults={snapToAngle:.1,snapToGrid:1,constraint:{},saveAspectRatio:!1}}).call(this)}(),void 0===window.Apex&&(window.Apex={});var Ht=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w}return c(t,[{key:"initModules",value:function(){this.ctx.publicMethods=["updateOptions","updateSeries","appendData","appendSeries","toggleSeries","showSeries","hideSeries","setLocale","resetSeries","zoomX","toggleDataPointSelection","dataURI","exportToCSV","addXaxisAnnotation","addYaxisAnnotation","addPointAnnotation","clearAnnotations","removeAnnotation","paper","destroy"],this.ctx.eventList=["click","mousedown","mousemove","mouseleave","touchstart","touchmove","touchleave","mouseup","touchend"],this.ctx.animations=new y(this.ctx),this.ctx.axes=new tt(this.ctx),this.ctx.core=new Xt(this.ctx.el,this.ctx),this.ctx.config=new R({}),this.ctx.data=new W(this.ctx),this.ctx.grid=new q(this.ctx),this.ctx.graphics=new k(this.ctx),this.ctx.coreUtils=new A(this.ctx),this.ctx.crosshairs=new et(this.ctx),this.ctx.events=new Q(this.ctx),this.ctx.exports=new G(this.ctx),this.ctx.localization=new K(this.ctx),this.ctx.options=new T,this.ctx.responsive=new it(this.ctx),this.ctx.series=new B(this.ctx),this.ctx.theme=new at(this.ctx),this.ctx.formatters=new j(this.ctx),this.ctx.titleSubtitle=new st(this.ctx),this.ctx.legend=new dt(this.ctx),this.ctx.toolbar=new ut(this.ctx),this.ctx.tooltip=new yt(this.ctx),this.ctx.dimensions=new ct(this.ctx),this.ctx.updateHelpers=new _t(this.ctx),this.ctx.zoomPanSelection=new pt(this.ctx),this.ctx.w.globals.tooltip=new yt(this.ctx)}}]),t}(),Bt=function(){function t(e){o(this,t),this.ctx=e,this.w=e.w}return c(t,[{key:"clear",value:function(t){var e=t.isUpdating;this.ctx.zoomPanSelection&&this.ctx.zoomPanSelection.destroy(),this.ctx.toolbar&&this.ctx.toolbar.destroy(),this.ctx.animations=null,this.ctx.axes=null,this.ctx.annotations=null,this.ctx.core=null,this.ctx.data=null,this.ctx.grid=null,this.ctx.series=null,this.ctx.responsive=null,this.ctx.theme=null,this.ctx.formatters=null,this.ctx.titleSubtitle=null,this.ctx.legend=null,this.ctx.dimensions=null,this.ctx.options=null,this.ctx.crosshairs=null,this.ctx.zoomPanSelection=null,this.ctx.updateHelpers=null,this.ctx.toolbar=null,this.ctx.localization=null,this.ctx.w.globals.tooltip=null,this.clearDomElements({isUpdating:e})}},{key:"killSVG",value:function(t){t.each((function(t,e){this.removeClass("*"),this.off(),this.stop()}),!0),t.ungroup(),t.clear()}},{key:"clearDomElements",value:function(t){var e=this,i=t.isUpdating,a=this.w.globals.dom.Paper.node;a.parentNode&&a.parentNode.parentNode&&!i&&(a.parentNode.parentNode.style.minHeight="unset");var s=this.w.globals.dom.baseEl;s&&this.ctx.eventList.forEach((function(t){s.removeEventListener(t,e.ctx.events.documentEvent)}));var r=this.w.globals.dom;if(null!==this.ctx.el)for(;this.ctx.el.firstChild;)this.ctx.el.removeChild(this.ctx.el.firstChild);this.killSVG(r.Paper),r.Paper.remove(),r.elWrap=null,r.elGraphical=null,r.elAnnotations=null,r.elLegendWrap=null,r.baseEl=null,r.elGridRect=null,r.elGridRectMask=null,r.elGridRectMarkerMask=null,r.elForecastMask=null,r.elNonForecastMask=null,r.elDefs=null}}]),t}(),Wt=new WeakMap,jt=function(){function t(e,i){o(this,t),this.opts=i,this.ctx=this,this.w=new F(i).init(),this.el=e,this.w.globals.cuid=v.randomId(),this.w.globals.chartID=this.w.config.chart.id?v.escapeString(this.w.config.chart.id):this.w.globals.cuid,new Ht(this).initModules(),this.create=v.bind(this.create,this),this.windowResizeHandler=this._windowResizeHandler.bind(this),this.parentResizeHandler=this._parentResizeCallback.bind(this)}return c(t,[{key:"render",value:function(){var t=this;return new Promise((function(e,i){if(null!==t.el){void 0===Apex._chartInstances&&(Apex._chartInstances=[]),t.w.config.chart.id&&Apex._chartInstances.push({id:t.w.globals.chartID,group:t.w.config.chart.group,chart:t}),t.setLocale(t.w.config.chart.defaultLocale);var a=t.w.config.chart.events.beforeMount;if("function"==typeof a&&a(t,t.w),t.events.fireEvent("beforeMount",[t,t.w]),window.addEventListener("resize",t.windowResizeHandler),function(t,e){var i=!1;if(t.nodeType!==Node.DOCUMENT_FRAGMENT_NODE){var a=t.getBoundingClientRect();"none"!==t.style.display&&0!==a.width||(i=!0)}var s=new ResizeObserver((function(a){i&&e.call(t,a),i=!0}));t.nodeType===Node.DOCUMENT_FRAGMENT_NODE?Array.from(t.children).forEach((function(t){return s.observe(t)})):s.observe(t),Wt.set(e,s)}(t.el.parentNode,t.parentResizeHandler),!t.css){var s=t.el.getRootNode&&t.el.getRootNode(),r=v.is("ShadowRoot",s),n=t.el.ownerDocument,o=n.getElementById("apexcharts-css");!r&&o||(t.css=document.createElement("style"),t.css.id="apexcharts-css",t.css.textContent='@keyframes opaque {\n 0% {\n opacity: 0\n }\n\n to {\n opacity: 1\n }\n}\n\n@keyframes resizeanim {\n 0%,to {\n opacity: 0\n }\n}\n\n.apexcharts-canvas {\n position: relative;\n user-select: none\n}\n\n.apexcharts-canvas ::-webkit-scrollbar {\n -webkit-appearance: none;\n width: 6px\n}\n\n.apexcharts-canvas ::-webkit-scrollbar-thumb {\n border-radius: 4px;\n background-color: rgba(0,0,0,.5);\n box-shadow: 0 0 1px rgba(255,255,255,.5);\n -webkit-box-shadow: 0 0 1px rgba(255,255,255,.5)\n}\n\n.apexcharts-inner {\n position: relative\n}\n\n.apexcharts-text tspan {\n font-family: inherit\n}\n\n.legend-mouseover-inactive {\n transition: .15s ease all;\n opacity: .2\n}\n\n.apexcharts-legend-text {\n padding-left: 15px;\n margin-left: -15px;\n}\n\n.apexcharts-series-collapsed {\n opacity: 0\n}\n\n.apexcharts-tooltip {\n border-radius: 5px;\n box-shadow: 2px 2px 6px -4px #999;\n cursor: default;\n font-size: 14px;\n left: 62px;\n opacity: 0;\n pointer-events: none;\n position: absolute;\n top: 20px;\n display: flex;\n flex-direction: column;\n overflow: hidden;\n white-space: nowrap;\n z-index: 12;\n transition: .15s ease all\n}\n\n.apexcharts-tooltip.apexcharts-active {\n opacity: 1;\n transition: .15s ease all\n}\n\n.apexcharts-tooltip.apexcharts-theme-light {\n border: 1px solid #e3e3e3;\n background: rgba(255,255,255,.96)\n}\n\n.apexcharts-tooltip.apexcharts-theme-dark {\n color: #fff;\n background: rgba(30,30,30,.8)\n}\n\n.apexcharts-tooltip * {\n font-family: inherit\n}\n\n.apexcharts-tooltip-title {\n padding: 6px;\n font-size: 15px;\n margin-bottom: 4px\n}\n\n.apexcharts-tooltip.apexcharts-theme-light .apexcharts-tooltip-title {\n background: #eceff1;\n border-bottom: 1px solid #ddd\n}\n\n.apexcharts-tooltip.apexcharts-theme-dark .apexcharts-tooltip-title {\n background: rgba(0,0,0,.7);\n border-bottom: 1px solid #333\n}\n\n.apexcharts-tooltip-text-goals-value,.apexcharts-tooltip-text-y-value,.apexcharts-tooltip-text-z-value {\n display: inline-block;\n margin-left: 5px;\n font-weight: 600\n}\n\n.apexcharts-tooltip-text-goals-label:empty,.apexcharts-tooltip-text-goals-value:empty,.apexcharts-tooltip-text-y-label:empty,.apexcharts-tooltip-text-y-value:empty,.apexcharts-tooltip-text-z-value:empty,.apexcharts-tooltip-title:empty {\n display: none\n}\n\n.apexcharts-tooltip-text-goals-label,.apexcharts-tooltip-text-goals-value {\n padding: 6px 0 5px\n}\n\n.apexcharts-tooltip-goals-group,.apexcharts-tooltip-text-goals-label,.apexcharts-tooltip-text-goals-value {\n display: flex\n}\n\n.apexcharts-tooltip-text-goals-label:not(:empty),.apexcharts-tooltip-text-goals-value:not(:empty) {\n margin-top: -6px\n}\n\n.apexcharts-tooltip-marker {\n width: 12px;\n height: 12px;\n position: relative;\n top: 0;\n margin-right: 10px;\n border-radius: 50%\n}\n\n.apexcharts-tooltip-series-group {\n padding: 0 10px;\n display: none;\n text-align: left;\n justify-content: left;\n align-items: center\n}\n\n.apexcharts-tooltip-series-group.apexcharts-active .apexcharts-tooltip-marker {\n opacity: 1\n}\n\n.apexcharts-tooltip-series-group.apexcharts-active,.apexcharts-tooltip-series-group:last-child {\n padding-bottom: 4px\n}\n\n.apexcharts-tooltip-series-group-hidden {\n opacity: 0;\n height: 0;\n line-height: 0;\n padding: 0!important\n}\n\n.apexcharts-tooltip-y-group {\n padding: 6px 0 5px\n}\n\n.apexcharts-custom-tooltip,.apexcharts-tooltip-box {\n padding: 4px 8px\n}\n\n.apexcharts-tooltip-boxPlot {\n display: flex;\n flex-direction: column-reverse\n}\n\n.apexcharts-tooltip-box>div {\n margin: 4px 0\n}\n\n.apexcharts-tooltip-box span.value {\n font-weight: 700\n}\n\n.apexcharts-tooltip-rangebar {\n padding: 5px 8px\n}\n\n.apexcharts-tooltip-rangebar .category {\n font-weight: 600;\n color: #777\n}\n\n.apexcharts-tooltip-rangebar .series-name {\n font-weight: 700;\n display: block;\n margin-bottom: 5px\n}\n\n.apexcharts-xaxistooltip,.apexcharts-yaxistooltip {\n opacity: 0;\n pointer-events: none;\n color: #373d3f;\n font-size: 13px;\n text-align: center;\n border-radius: 2px;\n position: absolute;\n z-index: 10;\n background: #eceff1;\n border: 1px solid #90a4ae\n}\n\n.apexcharts-xaxistooltip {\n padding: 9px 10px;\n transition: .15s ease all\n}\n\n.apexcharts-xaxistooltip.apexcharts-theme-dark {\n background: rgba(0,0,0,.7);\n border: 1px solid rgba(0,0,0,.5);\n color: #fff\n}\n\n.apexcharts-xaxistooltip:after,.apexcharts-xaxistooltip:before {\n left: 50%;\n border: solid transparent;\n content: " ";\n height: 0;\n width: 0;\n position: absolute;\n pointer-events: none\n}\n\n.apexcharts-xaxistooltip:after {\n border-color: transparent;\n border-width: 6px;\n margin-left: -6px\n}\n\n.apexcharts-xaxistooltip:before {\n border-color: transparent;\n border-width: 7px;\n margin-left: -7px\n}\n\n.apexcharts-xaxistooltip-bottom:after,.apexcharts-xaxistooltip-bottom:before {\n bottom: 100%\n}\n\n.apexcharts-xaxistooltip-top:after,.apexcharts-xaxistooltip-top:before {\n top: 100%\n}\n\n.apexcharts-xaxistooltip-bottom:after {\n border-bottom-color: #eceff1\n}\n\n.apexcharts-xaxistooltip-bottom:before {\n border-bottom-color: #90a4ae\n}\n\n.apexcharts-xaxistooltip-bottom.apexcharts-theme-dark:after,.apexcharts-xaxistooltip-bottom.apexcharts-theme-dark:before {\n border-bottom-color: rgba(0,0,0,.5)\n}\n\n.apexcharts-xaxistooltip-top:after {\n border-top-color: #eceff1\n}\n\n.apexcharts-xaxistooltip-top:before {\n border-top-color: #90a4ae\n}\n\n.apexcharts-xaxistooltip-top.apexcharts-theme-dark:after,.apexcharts-xaxistooltip-top.apexcharts-theme-dark:before {\n border-top-color: rgba(0,0,0,.5)\n}\n\n.apexcharts-xaxistooltip.apexcharts-active {\n opacity: 1;\n transition: .15s ease all\n}\n\n.apexcharts-yaxistooltip {\n padding: 4px 10px\n}\n\n.apexcharts-yaxistooltip.apexcharts-theme-dark {\n background: rgba(0,0,0,.7);\n border: 1px solid rgba(0,0,0,.5);\n color: #fff\n}\n\n.apexcharts-yaxistooltip:after,.apexcharts-yaxistooltip:before {\n top: 50%;\n border: solid transparent;\n content: " ";\n height: 0;\n width: 0;\n position: absolute;\n pointer-events: none\n}\n\n.apexcharts-yaxistooltip:after {\n border-color: transparent;\n border-width: 6px;\n margin-top: -6px\n}\n\n.apexcharts-yaxistooltip:before {\n border-color: transparent;\n border-width: 7px;\n margin-top: -7px\n}\n\n.apexcharts-yaxistooltip-left:after,.apexcharts-yaxistooltip-left:before {\n left: 100%\n}\n\n.apexcharts-yaxistooltip-right:after,.apexcharts-yaxistooltip-right:before {\n right: 100%\n}\n\n.apexcharts-yaxistooltip-left:after {\n border-left-color: #eceff1\n}\n\n.apexcharts-yaxistooltip-left:before {\n border-left-color: #90a4ae\n}\n\n.apexcharts-yaxistooltip-left.apexcharts-theme-dark:after,.apexcharts-yaxistooltip-left.apexcharts-theme-dark:before {\n border-left-color: rgba(0,0,0,.5)\n}\n\n.apexcharts-yaxistooltip-right:after {\n border-right-color: #eceff1\n}\n\n.apexcharts-yaxistooltip-right:before {\n border-right-color: #90a4ae\n}\n\n.apexcharts-yaxistooltip-right.apexcharts-theme-dark:after,.apexcharts-yaxistooltip-right.apexcharts-theme-dark:before {\n border-right-color: rgba(0,0,0,.5)\n}\n\n.apexcharts-yaxistooltip.apexcharts-active {\n opacity: 1\n}\n\n.apexcharts-yaxistooltip-hidden {\n display: none\n}\n\n.apexcharts-xcrosshairs,.apexcharts-ycrosshairs {\n pointer-events: none;\n opacity: 0;\n transition: .15s ease all\n}\n\n.apexcharts-xcrosshairs.apexcharts-active,.apexcharts-ycrosshairs.apexcharts-active {\n opacity: 1;\n transition: .15s ease all\n}\n\n.apexcharts-ycrosshairs-hidden {\n opacity: 0\n}\n\n.apexcharts-selection-rect {\n cursor: move\n}\n\n.svg_select_boundingRect,.svg_select_points_rot {\n pointer-events: none;\n opacity: 0;\n visibility: hidden\n}\n\n.apexcharts-selection-rect+g .svg_select_boundingRect,.apexcharts-selection-rect+g .svg_select_points_rot {\n opacity: 0;\n visibility: hidden\n}\n\n.apexcharts-selection-rect+g .svg_select_points_l,.apexcharts-selection-rect+g .svg_select_points_r {\n cursor: ew-resize;\n opacity: 1;\n visibility: visible\n}\n\n.svg_select_points {\n fill: #efefef;\n stroke: #333;\n rx: 2\n}\n\n.apexcharts-svg.apexcharts-zoomable.hovering-zoom {\n cursor: crosshair\n}\n\n.apexcharts-svg.apexcharts-zoomable.hovering-pan {\n cursor: move\n}\n\n.apexcharts-menu-icon,.apexcharts-pan-icon,.apexcharts-reset-icon,.apexcharts-selection-icon,.apexcharts-toolbar-custom-icon,.apexcharts-zoom-icon,.apexcharts-zoomin-icon,.apexcharts-zoomout-icon {\n cursor: pointer;\n width: 20px;\n height: 20px;\n line-height: 24px;\n color: #6e8192;\n text-align: center\n}\n\n.apexcharts-menu-icon svg,.apexcharts-reset-icon svg,.apexcharts-zoom-icon svg,.apexcharts-zoomin-icon svg,.apexcharts-zoomout-icon svg {\n fill: #6e8192\n}\n\n.apexcharts-selection-icon svg {\n fill: #444;\n transform: scale(.76)\n}\n\n.apexcharts-theme-dark .apexcharts-menu-icon svg,.apexcharts-theme-dark .apexcharts-pan-icon svg,.apexcharts-theme-dark .apexcharts-reset-icon svg,.apexcharts-theme-dark .apexcharts-selection-icon svg,.apexcharts-theme-dark .apexcharts-toolbar-custom-icon svg,.apexcharts-theme-dark .apexcharts-zoom-icon svg,.apexcharts-theme-dark .apexcharts-zoomin-icon svg,.apexcharts-theme-dark .apexcharts-zoomout-icon svg {\n fill: #f3f4f5\n}\n\n.apexcharts-canvas .apexcharts-reset-zoom-icon.apexcharts-selected svg,.apexcharts-canvas .apexcharts-selection-icon.apexcharts-selected svg,.apexcharts-canvas .apexcharts-zoom-icon.apexcharts-selected svg {\n fill: #008ffb\n}\n\n.apexcharts-theme-light .apexcharts-menu-icon:hover svg,.apexcharts-theme-light .apexcharts-reset-icon:hover svg,.apexcharts-theme-light .apexcharts-selection-icon:not(.apexcharts-selected):hover svg,.apexcharts-theme-light .apexcharts-zoom-icon:not(.apexcharts-selected):hover svg,.apexcharts-theme-light .apexcharts-zoomin-icon:hover svg,.apexcharts-theme-light .apexcharts-zoomout-icon:hover svg {\n fill: #333\n}\n\n.apexcharts-menu-icon,.apexcharts-selection-icon {\n position: relative\n}\n\n.apexcharts-reset-icon {\n margin-left: 5px\n}\n\n.apexcharts-menu-icon,.apexcharts-reset-icon,.apexcharts-zoom-icon {\n transform: scale(.85)\n}\n\n.apexcharts-zoomin-icon,.apexcharts-zoomout-icon {\n transform: scale(.7)\n}\n\n.apexcharts-zoomout-icon {\n margin-right: 3px\n}\n\n.apexcharts-pan-icon {\n transform: scale(.62);\n position: relative;\n left: 1px;\n top: 0\n}\n\n.apexcharts-pan-icon svg {\n fill: #fff;\n stroke: #6e8192;\n stroke-width: 2\n}\n\n.apexcharts-pan-icon.apexcharts-selected svg {\n stroke: #008ffb\n}\n\n.apexcharts-pan-icon:not(.apexcharts-selected):hover svg {\n stroke: #333\n}\n\n.apexcharts-toolbar {\n position: absolute;\n z-index: 11;\n max-width: 176px;\n text-align: right;\n border-radius: 3px;\n padding: 0 6px 2px;\n display: flex;\n justify-content: space-between;\n align-items: center\n}\n\n.apexcharts-menu {\n background: #fff;\n position: absolute;\n top: 100%;\n border: 1px solid #ddd;\n border-radius: 3px;\n padding: 3px;\n right: 10px;\n opacity: 0;\n min-width: 110px;\n transition: .15s ease all;\n pointer-events: none\n}\n\n.apexcharts-menu.apexcharts-menu-open {\n opacity: 1;\n pointer-events: all;\n transition: .15s ease all\n}\n\n.apexcharts-menu-item {\n padding: 6px 7px;\n font-size: 12px;\n cursor: pointer\n}\n\n.apexcharts-theme-light .apexcharts-menu-item:hover {\n background: #eee\n}\n\n.apexcharts-theme-dark .apexcharts-menu {\n background: rgba(0,0,0,.7);\n color: #fff\n}\n\n@media screen and (min-width:768px) {\n .apexcharts-canvas:hover .apexcharts-toolbar {\n opacity: 1\n }\n}\n\n.apexcharts-canvas .apexcharts-element-hidden,.apexcharts-datalabel.apexcharts-element-hidden,.apexcharts-hide .apexcharts-series-points {\n opacity: 0\n}\n\n.apexcharts-datalabel,.apexcharts-datalabel-label,.apexcharts-datalabel-value,.apexcharts-datalabels,.apexcharts-pie-label {\n cursor: default;\n pointer-events: none\n}\n\n.apexcharts-pie-label-delay {\n opacity: 0;\n animation-name: opaque;\n animation-duration: .3s;\n animation-fill-mode: forwards;\n animation-timing-function: ease\n}\n\n.apexcharts-annotation-rect,.apexcharts-area-series .apexcharts-area,.apexcharts-area-series .apexcharts-series-markers .apexcharts-marker.no-pointer-events,.apexcharts-gridline,.apexcharts-line,.apexcharts-line-series .apexcharts-series-markers .apexcharts-marker.no-pointer-events,.apexcharts-point-annotation-label,.apexcharts-radar-series path,.apexcharts-radar-series polygon,.apexcharts-toolbar svg,.apexcharts-tooltip .apexcharts-marker,.apexcharts-xaxis-annotation-label,.apexcharts-yaxis-annotation-label,.apexcharts-zoom-rect {\n pointer-events: none\n}\n\n.apexcharts-marker {\n transition: .15s ease all\n}\n\n.resize-triggers {\n animation: 1ms resizeanim;\n visibility: hidden;\n opacity: 0;\n height: 100%;\n width: 100%;\n overflow: hidden\n}\n\n.contract-trigger:before,.resize-triggers,.resize-triggers>div {\n content: " ";\n display: block;\n position: absolute;\n top: 0;\n left: 0\n}\n\n.resize-triggers>div {\n height: 100%;\n width: 100%;\n background: #eee;\n overflow: auto\n}\n\n.contract-trigger:before {\n overflow: hidden;\n width: 200%;\n height: 200%\n}\n',r?s.prepend(t.css):n.head.appendChild(t.css))}var l=t.create(t.w.config.series,{});if(!l)return e(t);t.mount(l).then((function(){"function"==typeof t.w.config.chart.events.mounted&&t.w.config.chart.events.mounted(t,t.w),t.events.fireEvent("mounted",[t,t.w]),e(l)})).catch((function(t){i(t)}))}else i(new Error("Element not found"))}))}},{key:"create",value:function(t,e){var i=this.w;new Ht(this).initModules();var a=this.w.globals;if(a.noData=!1,a.animationEnded=!1,this.responsive.checkResponsiveConfig(e),i.config.xaxis.convertedCatToNumeric&&new z(i.config).convertCatToNumericXaxis(i.config,this.ctx),null===this.el)return a.animationEnded=!0,null;if(this.core.setupElements(),"treemap"===i.config.chart.type&&(i.config.grid.show=!1,i.config.yaxis[0].show=!1),0===a.svgWidth)return a.animationEnded=!0,null;var s=A.checkComboSeries(t);a.comboCharts=s.comboCharts,a.comboBarCount=s.comboBarCount;var r=t.every((function(t){return t.data&&0===t.data.length}));(0===t.length||r)&&this.series.handleNoData(),this.events.setupEventHandlers(),this.data.parseData(t),this.theme.init(),new X(this).setGlobalMarkerSize(),this.formatters.setLabelFormatters(),this.titleSubtitle.draw(),a.noData&&a.collapsedSeries.length!==a.series.length&&!i.config.legend.showForSingleSeries||this.legend.init(),this.series.hasAllSeriesEqualX(),a.axisCharts&&(this.core.coreCalculations(),"category"!==i.config.xaxis.type&&this.formatters.setLabelFormatters(),this.ctx.toolbar.minX=i.globals.minX,this.ctx.toolbar.maxX=i.globals.maxX),this.formatters.heatmapLabelFormatters(),new A(this).getLargestMarkerSize(),this.dimensions.plotCoords();var n=this.core.xySettings();this.grid.createGridMask();var o=this.core.plotChartType(t,n),l=new H(this);l.bringForward(),i.config.dataLabels.background.enabled&&l.dataLabelsBackground(),this.core.shiftGraphPosition();var c={plot:{left:i.globals.translateX,top:i.globals.translateY,width:i.globals.gridWidth,height:i.globals.gridHeight}};return{elGraph:o,xyRatios:n,elInner:i.globals.dom.elGraphical,dimensions:c}}},{key:"mount",value:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,i=this,a=i.w;return new Promise((function(s,r){if(null===i.el)return r(new Error("Not enough data to display or target element not found"));(null===e||a.globals.allSeriesCollapsed)&&i.series.handleNoData(),i.grid=new q(i);var n=i.grid.drawGrid();"treemap"!==a.config.chart.type&&i.axes.drawAxis(a.config.chart.type,n),i.annotations=new M(i),i.annotations.drawImageAnnos(),i.annotations.drawTextAnnos(),"back"===a.config.grid.position&&n&&a.globals.dom.elGraphical.add(n.el);var o=new U(t.ctx,n),l=new J(t.ctx,n);if(null!==n&&(o.xAxisLabelCorrections(n.xAxisTickWidth),l.setYAxisTextAlignments(),a.config.yaxis.map((function(t,e){-1===a.globals.ignoreYAxisIndexes.indexOf(e)&&l.yAxisTitleRotate(e,t.opposite)}))),"back"===a.config.annotations.position&&(a.globals.dom.Paper.add(a.globals.dom.elAnnotations),i.annotations.drawAxesAnnotations()),Array.isArray(e.elGraph))for(var c=0;c<e.elGraph.length;c++)a.globals.dom.elGraphical.add(e.elGraph[c]);else a.globals.dom.elGraphical.add(e.elGraph);if("front"===a.config.grid.position&&n&&a.globals.dom.elGraphical.add(n.el),n&&n.elGridBorders&&n.elGridBorders.node&&a.globals.dom.elGraphical.add(n.elGridBorders),"front"===a.config.xaxis.crosshairs.position&&i.crosshairs.drawXCrosshairs(),"front"===a.config.yaxis[0].crosshairs.position&&i.crosshairs.drawYCrosshairs(),"front"===a.config.annotations.position&&(a.globals.dom.Paper.add(a.globals.dom.elAnnotations),i.annotations.drawAxesAnnotations()),!a.globals.noData){if(a.config.tooltip.enabled&&!a.globals.noData&&i.w.globals.tooltip.drawTooltip(e.xyRatios),a.globals.axisCharts&&(a.globals.isXNumeric||a.config.xaxis.convertedCatToNumeric||a.globals.isRangeBar))(a.config.chart.zoom.enabled||a.config.chart.selection&&a.config.chart.selection.enabled||a.config.chart.pan&&a.config.chart.pan.enabled)&&i.zoomPanSelection.init({xyRatios:e.xyRatios});else{var h=a.config.chart.toolbar.tools;["zoom","zoomin","zoomout","selection","pan","reset"].forEach((function(t){h[t]=!1}))}a.config.chart.toolbar.show&&!a.globals.allSeriesCollapsed&&i.toolbar.createToolbar()}a.globals.memory.methodsToExec.length>0&&a.globals.memory.methodsToExec.forEach((function(t){t.method(t.params,!1,t.context)})),a.globals.axisCharts||a.globals.noData||i.core.resizeNonAxisCharts(),s(i)}))}},{key:"destroy",value:function(){var t,e;window.removeEventListener("resize",this.windowResizeHandler),this.el.parentNode,t=this.parentResizeHandler,(e=Wt.get(t))&&(e.disconnect(),Wt.delete(t));var i=this.w.config.chart.id;i&&Apex._chartInstances.forEach((function(t,e){t.id===v.escapeString(i)&&Apex._chartInstances.splice(e,1)})),new Bt(this.ctx).clear({isUpdating:!1})}},{key:"updateOptions",value:function(t){var e=this,i=arguments.length>1&&void 0!==arguments[1]&&arguments[1],a=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],s=!(arguments.length>3&&void 0!==arguments[3])||arguments[3],r=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],n=this.w;return n.globals.selection=void 0,t.series&&(this.series.resetSeries(!1,!0,!1),t.series.length&&t.series[0].data&&(t.series=t.series.map((function(t,i){return e.updateHelpers._extendSeries(t,i)}))),this.updateHelpers.revertDefaultAxisMinMax()),t.xaxis&&(t=this.updateHelpers.forceXAxisUpdate(t)),t.yaxis&&(t=this.updateHelpers.forceYAxisUpdate(t)),n.globals.collapsedSeriesIndices.length>0&&this.series.clearPreviousPaths(),t.theme&&(t=this.theme.updateThemeOptions(t)),this.updateHelpers._updateOptions(t,i,a,s,r)}},{key:"updateSeries",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];return this.series.resetSeries(!1),this.updateHelpers.revertDefaultAxisMinMax(),this.updateHelpers._updateSeries(t,e,i)}},{key:"appendSeries",value:function(t){var e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],a=this.w.config.series.slice();return a.push(t),this.series.resetSeries(!1),this.updateHelpers.revertDefaultAxisMinMax(),this.updateHelpers._updateSeries(a,e,i)}},{key:"appendData",value:function(t){var e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=this;i.w.globals.dataChanged=!0,i.series.getPreviousPaths();for(var a=i.w.config.series.slice(),s=0;s<a.length;s++)if(null!==t[s]&&void 0!==t[s])for(var r=0;r<t[s].data.length;r++)a[s].data.push(t[s].data[r]);return i.w.config.series=a,e&&(i.w.globals.initialSeries=v.clone(i.w.config.series)),this.update()}},{key:"update",value:function(t){var e=this;return new Promise((function(i,a){new Bt(e.ctx).clear({isUpdating:!0});var s=e.create(e.w.config.series,t);if(!s)return i(e);e.mount(s).then((function(){"function"==typeof e.w.config.chart.events.updated&&e.w.config.chart.events.updated(e,e.w),e.events.fireEvent("updated",[e,e.w]),e.w.globals.isDirty=!0,i(e)})).catch((function(t){a(t)}))}))}},{key:"getSyncedCharts",value:function(){var t=this.getGroupedCharts(),e=[this];return t.length&&(e=[],t.forEach((function(t){e.push(t)}))),e}},{key:"getGroupedCharts",value:function(){var t=this;return Apex._chartInstances.filter((function(t){if(t.group)return!0})).map((function(e){return t.w.config.chart.group===e.group?e.chart:t}))}},{key:"toggleSeries",value:function(t){return this.series.toggleSeries(t)}},{key:"highlightSeriesOnLegendHover",value:function(t,e){return this.series.toggleSeriesOnHover(t,e)}},{key:"showSeries",value:function(t){this.series.showSeries(t)}},{key:"hideSeries",value:function(t){this.series.hideSeries(t)}},{key:"resetSeries",value:function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];this.series.resetSeries(t,e)}},{key:"addEventListener",value:function(t,e){this.events.addEventListener(t,e)}},{key:"removeEventListener",value:function(t,e){this.events.removeEventListener(t,e)}},{key:"addXaxisAnnotation",value:function(t){var e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:void 0,a=this;i&&(a=i),a.annotations.addXaxisAnnotationExternal(t,e,a)}},{key:"addYaxisAnnotation",value:function(t){var e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:void 0,a=this;i&&(a=i),a.annotations.addYaxisAnnotationExternal(t,e,a)}},{key:"addPointAnnotation",value:function(t){var e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:void 0,a=this;i&&(a=i),a.annotations.addPointAnnotationExternal(t,e,a)}},{key:"clearAnnotations",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:void 0,e=this;t&&(e=t),e.annotations.clearAnnotations(e)}},{key:"removeAnnotation",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:void 0,i=this;e&&(i=e),i.annotations.removeAnnotation(i,t)}},{key:"getChartArea",value:function(){return this.w.globals.dom.baseEl.querySelector(".apexcharts-inner")}},{key:"getSeriesTotalXRange",value:function(t,e){return this.coreUtils.getSeriesTotalsXRange(t,e)}},{key:"getHighestValueInSeries",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,e=new $(this.ctx);return e.getMinYMaxY(t).highestY}},{key:"getLowestValueInSeries",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,e=new $(this.ctx);return e.getMinYMaxY(t).lowestY}},{key:"getSeriesTotal",value:function(){return this.w.globals.seriesTotals}},{key:"toggleDataPointSelection",value:function(t,e){return this.updateHelpers.toggleDataPointSelection(t,e)}},{key:"zoomX",value:function(t,e){this.ctx.toolbar.zoomUpdateOptions(t,e)}},{key:"setLocale",value:function(t){this.localization.setCurrentLocaleValues(t)}},{key:"dataURI",value:function(t){return new G(this.ctx).dataURI(t)}},{key:"exportToCSV",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=new G(this.ctx);return e.exportToCSV(t)}},{key:"paper",value:function(){return this.w.globals.dom.Paper}},{key:"_parentResizeCallback",value:function(){this.w.globals.animationEnded&&this.w.config.chart.redrawOnParentResize&&this._windowResize()}},{key:"_windowResize",value:function(){var t=this;clearTimeout(this.w.globals.resizeTimer),this.w.globals.resizeTimer=window.setTimeout((function(){t.w.globals.resized=!0,t.w.globals.dataChanged=!1,t.ctx.update()}),150)}},{key:"_windowResizeHandler",value:function(){var t=this.w.config.chart.redrawOnWindowResize;"function"==typeof t&&(t=t()),t&&this._windowResize()}}],[{key:"getChartByID",value:function(t){var e=v.escapeString(t),i=Apex._chartInstances.filter((function(t){return t.id===e}))[0];return i&&i.chart}},{key:"initOnLoad",value:function(){for(var e=document.querySelectorAll("[data-apexcharts]"),i=0;i<e.length;i++)new t(e[i],JSON.parse(e[i].getAttribute("data-options"))).render()}},{key:"exec",value:function(t,e){var i=this.getChartByID(t);if(i){i.w.globals.isExecCalled=!0;var a=null;if(-1!==i.publicMethods.indexOf(e)){for(var s=arguments.length,r=new Array(s>2?s-2:0),n=2;n<s;n++)r[n-2]=arguments[n];a=i[e].apply(i,r)}return a}}},{key:"merge",value:function(t,e){return v.extend(t,e)}}]),t}();t.exports=jt},4184:function(t,e){var i;!function(){"use strict";var a={}.hasOwnProperty;function s(){for(var t=[],e=0;e<arguments.length;e++){var i=arguments[e];if(i){var r=typeof i;if("string"===r||"number"===r)t.push(i);else if(Array.isArray(i)){if(i.length){var n=s.apply(null,i);n&&t.push(n)}}else if("object"===r){if(i.toString!==Object.prototype.toString&&!i.toString.toString().includes("[native code]")){t.push(i.toString());continue}for(var o in i)a.call(i,o)&&i[o]&&t.push(o)}}}return t.join(" ")}t.exports?(s.default=s,t.exports=s):void 0===(i=function(){return s}.apply(e,[]))||(t.exports=i)}()},8679:function(t,e,i){"use strict";var a=i(9864),s={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},r={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},n={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},o={};function l(t){return a.isMemo(t)?n:o[t.$$typeof]||s}o[a.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},o[a.Memo]=n;var c=Object.defineProperty,h=Object.getOwnPropertyNames,d=Object.getOwnPropertySymbols,u=Object.getOwnPropertyDescriptor,p=Object.getPrototypeOf,f=Object.prototype;t.exports=function t(e,i,a){if("string"!=typeof i){if(f){var s=p(i);s&&s!==f&&t(e,s,a)}var n=h(i);d&&(n=n.concat(d(i)));for(var o=l(e),g=l(i),x=0;x<n.length;++x){var m=n[x];if(!(r[m]||a&&a[m]||g&&g[m]||o&&o[m])){var b=u(i,m);try{c(e,m,b)}catch(t){}}}}return e}},7466:function(t){window,t.exports=function(t){var e={};function i(a){if(e[a])return e[a].exports;var s=e[a]={i:a,l:!1,exports:{}};return t[a].call(s.exports,s,s.exports,i),s.l=!0,s.exports}return i.m=t,i.c=e,i.d=function(t,e,a){i.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:a})},i.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},i.t=function(t,e){if(1&e&&(t=i(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var a=Object.create(null);if(i.r(a),Object.defineProperty(a,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var s in t)i.d(a,s,function(e){return t[e]}.bind(null,s));return a},i.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return i.d(e,"a",e),e},i.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},i.p="",i(i.s=4)}([function(t,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var a=function(){function t(e,i,a){void 0===e&&(e=null),void 0===i&&(i=null),void 0===a&&(a="en-US"),this.dateInstance="object"==typeof i&&null!==i?i.parse(e instanceof t?e.clone().toJSDate():e):"string"==typeof i?t.parseDateTime(e,i,a):e?t.parseDateTime(e):t.parseDateTime(new Date),this.lang=a}return t.parseDateTime=function(e,i,a){if(void 0===i&&(i="YYYY-MM-DD"),void 0===a&&(a="en-US"),!e)return new Date(NaN);if(e instanceof Date)return new Date(e);if(e instanceof t)return e.clone().toJSDate();if(/^-?\d{10,}$/.test(e))return t.getDateZeroTime(new Date(Number(e)));if("string"==typeof e){for(var s=[],r=null;null!=(r=t.regex.exec(i));)"\\"!==r[1]&&s.push(r);if(s.length){var n={year:null,month:null,shortMonth:null,longMonth:null,day:null,value:""};s[0].index>0&&(n.value+=".*?");for(var o=0,l=Object.entries(s);o<l.length;o++){var c=l[o],h=c[0],d=c[1],u=Number(h),p=t.formatPatterns(d[0],a),f=p.group,g=p.pattern;n[f]=u+1,n.value+=g,n.value+=".*?"}var x=new RegExp("^"+n.value+"$");if(x.test(e)){var m=x.exec(e),b=Number(m[n.year]),v=null;n.month?v=Number(m[n.month])-1:n.shortMonth?v=t.shortMonths(a).indexOf(m[n.shortMonth]):n.longMonth&&(v=t.longMonths(a).indexOf(m[n.longMonth]));var y=Number(m[n.day])||1;return new Date(b,v,y,0,0,0,0)}}}return t.getDateZeroTime(new Date(e))},t.convertArray=function(e,i){return e.map((function(e){return e instanceof Array?e.map((function(e){return new t(e,i)})):new t(e,i)}))},t.getDateZeroTime=function(t){return new Date(t.getFullYear(),t.getMonth(),t.getDate(),0,0,0,0)},t.shortMonths=function(e){return t.MONTH_JS.map((function(t){return new Date(2019,t).toLocaleString(e,{month:"short"})}))},t.longMonths=function(e){return t.MONTH_JS.map((function(t){return new Date(2019,t).toLocaleString(e,{month:"long"})}))},t.formatPatterns=function(e,i){switch(e){case"YY":case"YYYY":return{group:"year",pattern:"(\\d{"+e.length+"})"};case"M":return{group:"month",pattern:"(\\d{1,2})"};case"MM":return{group:"month",pattern:"(\\d{2})"};case"MMM":return{group:"shortMonth",pattern:"("+t.shortMonths(i).join("|")+")"};case"MMMM":return{group:"longMonth",pattern:"("+t.longMonths(i).join("|")+")"};case"D":return{group:"day",pattern:"(\\d{1,2})"};case"DD":return{group:"day",pattern:"(\\d{2})"}}},t.prototype.toJSDate=function(){return this.dateInstance},t.prototype.toLocaleString=function(t,e){return this.dateInstance.toLocaleString(t,e)},t.prototype.toDateString=function(){return this.dateInstance.toDateString()},t.prototype.getSeconds=function(){return this.dateInstance.getSeconds()},t.prototype.getDay=function(){return this.dateInstance.getDay()},t.prototype.getTime=function(){return this.dateInstance.getTime()},t.prototype.getDate=function(){return this.dateInstance.getDate()},t.prototype.getMonth=function(){return this.dateInstance.getMonth()},t.prototype.getFullYear=function(){return this.dateInstance.getFullYear()},t.prototype.setMonth=function(t){return this.dateInstance.setMonth(t)},t.prototype.setHours=function(t,e,i,a){void 0===t&&(t=0),void 0===e&&(e=0),void 0===i&&(i=0),void 0===a&&(a=0),this.dateInstance.setHours(t,e,i,a)},t.prototype.setSeconds=function(t){return this.dateInstance.setSeconds(t)},t.prototype.setDate=function(t){return this.dateInstance.setDate(t)},t.prototype.setFullYear=function(t){return this.dateInstance.setFullYear(t)},t.prototype.getWeek=function(t){var e=new Date(this.timestamp()),i=(this.getDay()+(7-t))%7;e.setDate(e.getDate()-i);var a=e.getTime();return e.setMonth(0,1),e.getDay()!==t&&e.setMonth(0,1+(4-e.getDay()+7)%7),1+Math.ceil((a-e.getTime())/6048e5)},t.prototype.clone=function(){return new t(this.toJSDate())},t.prototype.isBetween=function(t,e,i){switch(void 0===i&&(i="()"),i){default:case"()":return this.timestamp()>t.getTime()&&this.timestamp()<e.getTime();case"[)":return this.timestamp()>=t.getTime()&&this.timestamp()<e.getTime();case"(]":return this.timestamp()>t.getTime()&&this.timestamp()<=e.getTime();case"[]":return this.timestamp()>=t.getTime()&&this.timestamp()<=e.getTime()}},t.prototype.isBefore=function(t,e){switch(void 0===e&&(e="seconds"),e){case"second":case"seconds":return t.getTime()>this.getTime();case"day":case"days":return new Date(t.getFullYear(),t.getMonth(),t.getDate()).getTime()>new Date(this.getFullYear(),this.getMonth(),this.getDate()).getTime();case"month":case"months":return new Date(t.getFullYear(),t.getMonth(),1).getTime()>new Date(this.getFullYear(),this.getMonth(),1).getTime();case"year":case"years":return t.getFullYear()>this.getFullYear()}throw new Error("isBefore: Invalid unit!")},t.prototype.isSameOrBefore=function(t,e){switch(void 0===e&&(e="seconds"),e){case"second":case"seconds":return t.getTime()>=this.getTime();case"day":case"days":return new Date(t.getFullYear(),t.getMonth(),t.getDate()).getTime()>=new Date(this.getFullYear(),this.getMonth(),this.getDate()).getTime();case"month":case"months":return new Date(t.getFullYear(),t.getMonth(),1).getTime()>=new Date(this.getFullYear(),this.getMonth(),1).getTime()}throw new Error("isSameOrBefore: Invalid unit!")},t.prototype.isAfter=function(t,e){switch(void 0===e&&(e="seconds"),e){case"second":case"seconds":return this.getTime()>t.getTime();case"day":case"days":return new Date(this.getFullYear(),this.getMonth(),this.getDate()).getTime()>new Date(t.getFullYear(),t.getMonth(),t.getDate()).getTime();case"month":case"months":return new Date(this.getFullYear(),this.getMonth(),1).getTime()>new Date(t.getFullYear(),t.getMonth(),1).getTime();case"year":case"years":return this.getFullYear()>t.getFullYear()}throw new Error("isAfter: Invalid unit!")},t.prototype.isSameOrAfter=function(t,e){switch(void 0===e&&(e="seconds"),e){case"second":case"seconds":return this.getTime()>=t.getTime();case"day":case"days":return new Date(this.getFullYear(),this.getMonth(),this.getDate()).getTime()>=new Date(t.getFullYear(),t.getMonth(),t.getDate()).getTime();case"month":case"months":return new Date(this.getFullYear(),this.getMonth(),1).getTime()>=new Date(t.getFullYear(),t.getMonth(),1).getTime()}throw new Error("isSameOrAfter: Invalid unit!")},t.prototype.isSame=function(t,e){switch(void 0===e&&(e="seconds"),e){case"second":case"seconds":return this.getTime()===t.getTime();case"day":case"days":return new Date(this.getFullYear(),this.getMonth(),this.getDate()).getTime()===new Date(t.getFullYear(),t.getMonth(),t.getDate()).getTime();case"month":case"months":return new Date(this.getFullYear(),this.getMonth(),1).getTime()===new Date(t.getFullYear(),t.getMonth(),1).getTime()}throw new Error("isSame: Invalid unit!")},t.prototype.add=function(t,e){switch(void 0===e&&(e="seconds"),e){case"second":case"seconds":this.setSeconds(this.getSeconds()+t);break;case"day":case"days":this.setDate(this.getDate()+t);break;case"month":case"months":this.setMonth(this.getMonth()+t)}return this},t.prototype.subtract=function(t,e){switch(void 0===e&&(e="seconds"),e){case"second":case"seconds":this.setSeconds(this.getSeconds()-t);break;case"day":case"days":this.setDate(this.getDate()-t);break;case"month":case"months":this.setMonth(this.getMonth()-t)}return this},t.prototype.diff=function(t,e){switch(void 0===e&&(e="seconds"),e){default:case"second":case"seconds":return this.getTime()-t.getTime();case"day":case"days":return Math.round((this.timestamp()-t.getTime())/864e5);case"month":case"months":}},t.prototype.format=function(e,i){if(void 0===i&&(i="en-US"),"object"==typeof e)return e.output(this.clone().toJSDate());for(var a="",s=[],r=null;null!=(r=t.regex.exec(e));)"\\"!==r[1]&&s.push(r);if(s.length){s[0].index>0&&(a+=e.substring(0,s[0].index));for(var n=0,o=Object.entries(s);n<o.length;n++){var l=o[n],c=l[0],h=l[1],d=Number(c);a+=this.formatTokens(h[0],i),s[d+1]&&(a+=e.substring(h.index+h[0].length,s[d+1].index)),d===s.length-1&&(a+=e.substring(h.index+h[0].length))}}return a.replace(/\\/g,"")},t.prototype.timestamp=function(){return new Date(this.getFullYear(),this.getMonth(),this.getDate(),0,0,0,0).getTime()},t.prototype.formatTokens=function(e,i){switch(e){case"YY":return String(this.getFullYear()).slice(-2);case"YYYY":return String(this.getFullYear());case"M":return String(this.getMonth()+1);case"MM":return("0"+(this.getMonth()+1)).slice(-2);case"MMM":return t.shortMonths(i)[this.getMonth()];case"MMMM":return t.longMonths(i)[this.getMonth()];case"D":return String(this.getDate());case"DD":return("0"+this.getDate()).slice(-2);default:return""}},t.regex=/(\\)?(Y{2,4}|M{1,4}|D{1,2}|d{1,4})/g,t.MONTH_JS=[0,1,2,3,4,5,6,7,8,9,10,11],t}();e.DateTime=a},function(t,e,i){"use strict";var a,s=this&&this.__extends||(a=function(t,e){return(a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var i in e)e.hasOwnProperty(i)&&(t[i]=e[i])})(t,e)},function(t,e){function i(){this.constructor=t}a(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}),r=this&&this.__spreadArrays||function(){for(var t=0,e=0,i=arguments.length;e<i;e++)t+=arguments[e].length;var a=Array(t),s=0;for(e=0;e<i;e++)for(var r=arguments[e],n=0,o=r.length;n<o;n++,s++)a[s]=r[n];return a};Object.defineProperty(e,"__esModule",{value:!0});var n=i(5),o=i(0),l=i(3),c=i(2),h=function(t){function e(e){var i=t.call(this,e)||this;return i.preventClick=!1,i.bindEvents(),i}return s(e,t),e.prototype.scrollToDate=function(t){if(this.options.scrollToDate){var e=this.options.startDate instanceof o.DateTime?this.options.startDate.clone():null,i=this.options.endDate instanceof o.DateTime?this.options.endDate.clone():null;!this.options.startDate||t&&t!==this.options.element?t&&this.options.endDate&&t===this.options.elementEnd&&(i.setDate(1),this.options.numberOfMonths>1&&i.isAfter(e)&&i.setMonth(i.getMonth()-(this.options.numberOfMonths-1)),this.calendars[0]=i.clone()):(e.setDate(1),this.calendars[0]=e.clone())}},e.prototype.bindEvents=function(){document.addEventListener("click",this.onClick.bind(this),!0),this.ui=document.createElement("div"),this.ui.className=l.litepicker,this.ui.style.display="none",this.ui.addEventListener("mouseenter",this.onMouseEnter.bind(this),!0),this.ui.addEventListener("mouseleave",this.onMouseLeave.bind(this),!1),this.options.autoRefresh?(this.options.element instanceof HTMLElement&&this.options.element.addEventListener("keyup",this.onInput.bind(this),!0),this.options.elementEnd instanceof HTMLElement&&this.options.elementEnd.addEventListener("keyup",this.onInput.bind(this),!0)):(this.options.element instanceof HTMLElement&&this.options.element.addEventListener("change",this.onInput.bind(this),!0),this.options.elementEnd instanceof HTMLElement&&this.options.elementEnd.addEventListener("change",this.onInput.bind(this),!0)),this.options.parentEl?this.options.parentEl instanceof HTMLElement?this.options.parentEl.appendChild(this.ui):document.querySelector(this.options.parentEl).appendChild(this.ui):this.options.inlineMode?this.options.element instanceof HTMLInputElement?this.options.element.parentNode.appendChild(this.ui):this.options.element.appendChild(this.ui):document.body.appendChild(this.ui),this.updateInput(),this.init(),"function"==typeof this.options.setup&&this.options.setup.call(this,this),this.render(),this.options.inlineMode&&this.show()},e.prototype.updateInput=function(){if(this.options.element instanceof HTMLInputElement){var t=this.options.startDate,e=this.options.endDate;if(this.options.singleMode&&t)this.options.element.value=t.format(this.options.format,this.options.lang);else if(!this.options.singleMode&&t&&e){var i=t.format(this.options.format,this.options.lang),a=e.format(this.options.format,this.options.lang);this.options.elementEnd instanceof HTMLInputElement?(this.options.element.value=i,this.options.elementEnd.value=a):this.options.element.value=""+i+this.options.delimiter+a}t||e||(this.options.element.value="",this.options.elementEnd instanceof HTMLInputElement&&(this.options.elementEnd.value=""))}},e.prototype.isSamePicker=function(t){return t.closest("."+l.litepicker)===this.ui},e.prototype.shouldShown=function(t){return!t.disabled&&(t===this.options.element||this.options.elementEnd&&t===this.options.elementEnd)},e.prototype.shouldResetDatePicked=function(){return this.options.singleMode||2===this.datePicked.length},e.prototype.shouldSwapDatePicked=function(){return 2===this.datePicked.length&&this.datePicked[0].getTime()>this.datePicked[1].getTime()},e.prototype.shouldCheckLockDays=function(){return this.options.disallowLockDaysInRange&&2===this.datePicked.length},e.prototype.onClick=function(t){var e=t.target;if(t.target.shadowRoot&&(e=t.composedPath()[0]),e&&this.ui)if(this.shouldShown(e))this.show(e);else if(e.closest("."+l.litepicker)||!this.isShowning()){if(this.isSamePicker(e))if(this.emit("before:click",e),this.preventClick)this.preventClick=!1;else{if(e.classList.contains(l.dayItem)){if(t.preventDefault(),e.classList.contains(l.isLocked))return;if(this.shouldResetDatePicked()&&(this.datePicked.length=0),this.datePicked[this.datePicked.length]=new o.DateTime(e.dataset.time),this.shouldSwapDatePicked()){var i=this.datePicked[1].clone();this.datePicked[1]=this.datePicked[0].clone(),this.datePicked[0]=i.clone()}return this.shouldCheckLockDays()&&c.rangeIsLocked(this.datePicked,this.options)&&(this.emit("error:range",this.datePicked),this.datePicked.length=0),this.render(),this.emit.apply(this,r(["preselect"],r(this.datePicked).map((function(t){return t.clone()})))),void(this.options.autoApply&&(this.options.singleMode&&this.datePicked.length?(this.setDate(this.datePicked[0]),this.hide()):this.options.singleMode||2!==this.datePicked.length||(this.setDateRange(this.datePicked[0],this.datePicked[1]),this.hide())))}if(e.classList.contains(l.buttonPreviousMonth)){t.preventDefault();var a=0,s=this.options.switchingMonths||this.options.numberOfMonths;if(this.options.splitView){var n=e.closest("."+l.monthItem);a=c.findNestedMonthItem(n),s=1}return this.calendars[a].setMonth(this.calendars[a].getMonth()-s),this.gotoDate(this.calendars[a],a),void this.emit("change:month",this.calendars[a],a)}if(e.classList.contains(l.buttonNextMonth))return t.preventDefault(),a=0,s=this.options.switchingMonths||this.options.numberOfMonths,this.options.splitView&&(n=e.closest("."+l.monthItem),a=c.findNestedMonthItem(n),s=1),this.calendars[a].setMonth(this.calendars[a].getMonth()+s),this.gotoDate(this.calendars[a],a),void this.emit("change:month",this.calendars[a],a);e.classList.contains(l.buttonCancel)&&(t.preventDefault(),this.hide(),this.emit("button:cancel")),e.classList.contains(l.buttonApply)&&(t.preventDefault(),this.options.singleMode&&this.datePicked.length?this.setDate(this.datePicked[0]):this.options.singleMode||2!==this.datePicked.length||this.setDateRange(this.datePicked[0],this.datePicked[1]),this.hide(),this.emit("button:apply",this.options.startDate,this.options.endDate))}}else this.hide()},e.prototype.showTooltip=function(t,e){var i=this.ui.querySelector("."+l.containerTooltip);i.style.visibility="visible",i.innerHTML=e;var a=this.ui.getBoundingClientRect(),s=i.getBoundingClientRect(),r=t.getBoundingClientRect(),n=r.top,o=r.left;if(this.options.inlineMode&&this.options.parentEl){var c=this.ui.parentNode.getBoundingClientRect();n-=c.top,o-=c.left}else n-=a.top,o-=a.left;n-=s.height,o-=s.width/2,o+=r.width/2,i.style.top=n+"px",i.style.left=o+"px",this.emit("tooltip",i,t)},e.prototype.hideTooltip=function(){this.ui.querySelector("."+l.containerTooltip).style.visibility="hidden"},e.prototype.shouldAllowMouseEnter=function(t){return!this.options.singleMode&&!t.classList.contains(l.isLocked)},e.prototype.shouldAllowRepick=function(){return this.options.elementEnd&&this.options.allowRepick&&this.options.startDate&&this.options.endDate},e.prototype.isDayItem=function(t){return t.classList.contains(l.dayItem)},e.prototype.onMouseEnter=function(t){var e=this,i=t.target;if(this.isDayItem(i)&&this.shouldAllowMouseEnter(i)){if(this.shouldAllowRepick()&&(this.triggerElement===this.options.element?this.datePicked[0]=this.options.endDate.clone():this.triggerElement===this.options.elementEnd&&(this.datePicked[0]=this.options.startDate.clone())),1!==this.datePicked.length)return;var a=this.ui.querySelector("."+l.dayItem+'[data-time="'+this.datePicked[0].getTime()+'"]'),s=this.datePicked[0].clone(),r=new o.DateTime(i.dataset.time),n=!1;if(s.getTime()>r.getTime()){var c=s.clone();s=r.clone(),r=c.clone(),n=!0}if(Array.prototype.slice.call(this.ui.querySelectorAll("."+l.dayItem)).forEach((function(t){var i=new o.DateTime(t.dataset.time),a=e.renderDay(i);i.isBetween(s,r)&&a.classList.add(l.isInRange),t.className=a.className})),i.classList.add(l.isEndDate),n?(a&&a.classList.add(l.isFlipped),i.classList.add(l.isFlipped)):(a&&a.classList.remove(l.isFlipped),i.classList.remove(l.isFlipped)),this.options.showTooltip){var h=r.diff(s,"day")+1;if("function"==typeof this.options.tooltipNumber&&(h=this.options.tooltipNumber.call(this,h)),h>0){var d=this.pluralSelector(h),u=h+" "+(this.options.tooltipText[d]?this.options.tooltipText[d]:"["+d+"]");this.showTooltip(i,u);var p=window.navigator.userAgent,f=/(iphone|ipad)/i.test(p),g=/OS 1([0-2])/i.test(p);f&&g&&i.dispatchEvent(new Event("click"))}else this.hideTooltip()}}},e.prototype.onMouseLeave=function(t){t.target,this.options.allowRepick&&(!this.options.allowRepick||this.options.startDate||this.options.endDate)&&(this.datePicked.length=0,this.render())},e.prototype.onInput=function(t){var e=this.parseInput(),i=e[0],a=e[1],s=this.options.format;if(this.options.elementEnd?i instanceof o.DateTime&&a instanceof o.DateTime&&i.format(s)===this.options.element.value&&a.format(s)===this.options.elementEnd.value:this.options.singleMode?i instanceof o.DateTime&&i.format(s)===this.options.element.value:i instanceof o.DateTime&&a instanceof o.DateTime&&""+i.format(s)+this.options.delimiter+a.format(s)===this.options.element.value){if(a&&i.getTime()>a.getTime()){var r=i.clone();i=a.clone(),a=r.clone()}this.options.startDate=new o.DateTime(i,this.options.format,this.options.lang),a&&(this.options.endDate=new o.DateTime(a,this.options.format,this.options.lang)),this.updateInput(),this.render();var n=i.clone(),l=0;(this.options.elementEnd?i.format(s)===t.target.value:t.target.value.startsWith(i.format(s)))||(n=a.clone(),l=this.options.numberOfMonths-1),this.emit("selected",this.getStartDate(),this.getEndDate()),this.gotoDate(n,l)}},e}(n.Calendar);e.Litepicker=h},function(t,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.findNestedMonthItem=function(t){for(var e=t.parentNode.childNodes,i=0;i<e.length;i+=1)if(e.item(i)===t)return i;return 0},e.dateIsLocked=function(t,e,i){var a=!1;return e.lockDays.length&&(a=e.lockDays.filter((function(i){return i instanceof Array?t.isBetween(i[0],i[1],e.lockDaysInclusivity):i.isSame(t,"day")})).length),a||"function"!=typeof e.lockDaysFilter||(a=e.lockDaysFilter.call(this,t.clone(),null,i)),a},e.rangeIsLocked=function(t,e){var i=!1;return e.lockDays.length&&(i=e.lockDays.filter((function(i){if(i instanceof Array){var a=t[0].toDateString()===i[0].toDateString()&&t[1].toDateString()===i[1].toDateString();return i[0].isBetween(t[0],t[1],e.lockDaysInclusivity)||i[1].isBetween(t[0],t[1],e.lockDaysInclusivity)||a}return i.isBetween(t[0],t[1],e.lockDaysInclusivity)})).length),i||"function"!=typeof e.lockDaysFilter||(i=e.lockDaysFilter.call(this,t[0].clone(),t[1].clone(),t)),i}},function(t,e,i){var a=i(8);"string"==typeof a&&(a=[[t.i,a,""]]);var s={insert:function(t){var e=document.querySelector("head"),i=window._lastElementInsertedByStyleLoader;window.disableLitepickerStyles||(i?i.nextSibling?e.insertBefore(t,i.nextSibling):e.appendChild(t):e.insertBefore(t,e.firstChild),window._lastElementInsertedByStyleLoader=t)},singleton:!1};i(10)(a,s),a.locals&&(t.exports=a.locals)},function(t,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var a=i(1);e.Litepicker=a.Litepicker,i(11),window.Litepicker=a.Litepicker,e.default=a.Litepicker},function(t,e,i){"use strict";var a,s=this&&this.__extends||(a=function(t,e){return(a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var i in e)e.hasOwnProperty(i)&&(t[i]=e[i])})(t,e)},function(t,e){function i(){this.constructor=t}a(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)});Object.defineProperty(e,"__esModule",{value:!0});var r=i(6),n=i(0),o=i(3),l=i(2),c=function(t){function e(e){return t.call(this,e)||this}return s(e,t),e.prototype.render=function(){var t=this;this.emit("before:render",this.ui);var e=document.createElement("div");e.className=o.containerMain;var i=document.createElement("div");i.className=o.containerMonths,o["columns"+this.options.numberOfColumns]&&(i.classList.remove(o.columns2,o.columns3,o.columns4),i.classList.add(o["columns"+this.options.numberOfColumns])),this.options.splitView&&i.classList.add(o.splitView),this.options.showWeekNumbers&&i.classList.add(o.showWeekNumbers);for(var a=this.calendars[0].clone(),s=a.getMonth(),r=a.getMonth()+this.options.numberOfMonths,n=0,l=s;l<r;l+=1){var c=a.clone();c.setDate(1),c.setHours(0,0,0,0),this.options.splitView?c=this.calendars[n].clone():c.setMonth(l),i.appendChild(this.renderMonth(c,n)),n+=1}if(this.ui.innerHTML="",e.appendChild(i),this.options.resetButton){var h=void 0;"function"==typeof this.options.resetButton?h=this.options.resetButton.call(this):((h=document.createElement("button")).type="button",h.className=o.resetButton,h.innerHTML=this.options.buttonText.reset),h.addEventListener("click",(function(e){e.preventDefault(),t.clearSelection()})),e.querySelector("."+o.monthItem+":last-child").querySelector("."+o.monthItemHeader).appendChild(h)}this.ui.appendChild(e),this.options.autoApply&&!this.options.footerHTML||this.ui.appendChild(this.renderFooter()),this.options.showTooltip&&this.ui.appendChild(this.renderTooltip()),this.ui.dataset.plugins=(this.options.plugins||[]).join("|"),this.emit("render",this.ui)},e.prototype.renderMonth=function(t,e){var i=this,a=t.clone(),s=32-new Date(a.getFullYear(),a.getMonth(),32).getDate(),r=document.createElement("div");r.className=o.monthItem;var c=document.createElement("div");c.className=o.monthItemHeader;var h=document.createElement("div");if(this.options.dropdowns.months){var d=document.createElement("select");d.className=o.monthItemName;for(var u=0;u<12;u+=1){var p=document.createElement("option"),f=new n.DateTime(new Date(t.getFullYear(),u,2,0,0,0)),g=new n.DateTime(new Date(t.getFullYear(),u,1,0,0,0));p.value=String(u),p.text=f.toLocaleString(this.options.lang,{month:"long"}),p.disabled=this.options.minDate&&g.isBefore(new n.DateTime(this.options.minDate),"month")||this.options.maxDate&&g.isAfter(new n.DateTime(this.options.maxDate),"month"),p.selected=g.getMonth()===t.getMonth(),d.appendChild(p)}d.addEventListener("change",(function(t){var e=t.target,a=0;if(i.options.splitView){var s=e.closest("."+o.monthItem);a=l.findNestedMonthItem(s)}i.calendars[a].setMonth(Number(e.value)),i.render(),i.emit("change:month",i.calendars[a],a,t)})),h.appendChild(d)}else(f=document.createElement("strong")).className=o.monthItemName,f.innerHTML=t.toLocaleString(this.options.lang,{month:"long"}),h.appendChild(f);if(this.options.dropdowns.years){var x=document.createElement("select");x.className=o.monthItemYear;var m=this.options.dropdowns.minYear,b=this.options.dropdowns.maxYear?this.options.dropdowns.maxYear:(new Date).getFullYear();for(t.getFullYear()>b&&((p=document.createElement("option")).value=String(t.getFullYear()),p.text=String(t.getFullYear()),p.selected=!0,p.disabled=!0,x.appendChild(p)),u=b;u>=m;u-=1){p=document.createElement("option");var v=new n.DateTime(new Date(u,0,1,0,0,0));p.value=String(u),p.text=String(u),p.disabled=this.options.minDate&&v.isBefore(new n.DateTime(this.options.minDate),"year")||this.options.maxDate&&v.isAfter(new n.DateTime(this.options.maxDate),"year"),p.selected=t.getFullYear()===u,x.appendChild(p)}if(t.getFullYear()<m&&((p=document.createElement("option")).value=String(t.getFullYear()),p.text=String(t.getFullYear()),p.selected=!0,p.disabled=!0,x.appendChild(p)),"asc"===this.options.dropdowns.years){var y=Array.prototype.slice.call(x.childNodes).reverse();x.innerHTML="",y.forEach((function(t){t.innerHTML=t.value,x.appendChild(t)}))}x.addEventListener("change",(function(t){var e=t.target,a=0;if(i.options.splitView){var s=e.closest("."+o.monthItem);a=l.findNestedMonthItem(s)}i.calendars[a].setFullYear(Number(e.value)),i.render(),i.emit("change:year",i.calendars[a],a,t)})),h.appendChild(x)}else{var w=document.createElement("span");w.className=o.monthItemYear,w.innerHTML=String(t.getFullYear()),h.appendChild(w)}var k=document.createElement("button");k.type="button",k.className=o.buttonPreviousMonth,k.innerHTML=this.options.buttonText.previousMonth;var A=document.createElement("button");A.type="button",A.className=o.buttonNextMonth,A.innerHTML=this.options.buttonText.nextMonth,c.appendChild(k),c.appendChild(h),c.appendChild(A),this.options.minDate&&a.isSameOrBefore(new n.DateTime(this.options.minDate),"month")&&r.classList.add(o.noPreviousMonth),this.options.maxDate&&a.isSameOrAfter(new n.DateTime(this.options.maxDate),"month")&&r.classList.add(o.noNextMonth);var S=document.createElement("div");S.className=o.monthItemWeekdaysRow,this.options.showWeekNumbers&&(S.innerHTML="<div>W</div>");for(var C=1;C<=7;C+=1){var P=3+this.options.firstDay+C,L=document.createElement("div");L.innerHTML=this.weekdayName(P),L.title=this.weekdayName(P,"long"),S.appendChild(L)}var D=document.createElement("div");D.className=o.containerDays;var T=this.calcSkipDays(a);this.options.showWeekNumbers&&T&&D.appendChild(this.renderWeekNumber(a));for(var M=0;M<T;M+=1){var E=document.createElement("div");D.appendChild(E)}for(M=1;M<=s;M+=1)a.setDate(M),this.options.showWeekNumbers&&a.getDay()===this.options.firstDay&&D.appendChild(this.renderWeekNumber(a)),D.appendChild(this.renderDay(a));return r.appendChild(c),r.appendChild(S),r.appendChild(D),this.emit("render:month",r,t),r},e.prototype.renderDay=function(t){t.setHours();var e=document.createElement("div");if(e.className=o.dayItem,e.innerHTML=String(t.getDate()),e.dataset.time=String(t.getTime()),t.toDateString()===(new Date).toDateString()&&e.classList.add(o.isToday),this.datePicked.length)this.datePicked[0].toDateString()===t.toDateString()&&(e.classList.add(o.isStartDate),this.options.singleMode&&e.classList.add(o.isEndDate)),2===this.datePicked.length&&this.datePicked[1].toDateString()===t.toDateString()&&e.classList.add(o.isEndDate),2===this.datePicked.length&&t.isBetween(this.datePicked[0],this.datePicked[1])&&e.classList.add(o.isInRange);else if(this.options.startDate){var i=this.options.startDate,a=this.options.endDate;i.toDateString()===t.toDateString()&&(e.classList.add(o.isStartDate),this.options.singleMode&&e.classList.add(o.isEndDate)),a&&a.toDateString()===t.toDateString()&&e.classList.add(o.isEndDate),i&&a&&t.isBetween(i,a)&&e.classList.add(o.isInRange)}if(this.options.minDate&&t.isBefore(new n.DateTime(this.options.minDate))&&e.classList.add(o.isLocked),this.options.maxDate&&t.isAfter(new n.DateTime(this.options.maxDate))&&e.classList.add(o.isLocked),this.options.minDays>1&&1===this.datePicked.length){var s=this.options.minDays-1,r=this.datePicked[0].clone().subtract(s,"day"),c=this.datePicked[0].clone().add(s,"day");t.isBetween(r,this.datePicked[0],"(]")&&e.classList.add(o.isLocked),t.isBetween(this.datePicked[0],c,"[)")&&e.classList.add(o.isLocked)}if(this.options.maxDays&&1===this.datePicked.length){var h=this.options.maxDays;r=this.datePicked[0].clone().subtract(h,"day"),c=this.datePicked[0].clone().add(h,"day"),t.isSameOrBefore(r)&&e.classList.add(o.isLocked),t.isSameOrAfter(c)&&e.classList.add(o.isLocked)}return this.options.selectForward&&1===this.datePicked.length&&t.isBefore(this.datePicked[0])&&e.classList.add(o.isLocked),this.options.selectBackward&&1===this.datePicked.length&&t.isAfter(this.datePicked[0])&&e.classList.add(o.isLocked),l.dateIsLocked(t,this.options,this.datePicked)&&e.classList.add(o.isLocked),this.options.highlightedDays.length&&this.options.highlightedDays.filter((function(e){return e instanceof Array?t.isBetween(e[0],e[1],"[]"):e.isSame(t,"day")})).length&&e.classList.add(o.isHighlighted),e.tabIndex=e.classList.contains("is-locked")?-1:0,this.emit("render:day",e,t),e},e.prototype.renderFooter=function(){var t=document.createElement("div");if(t.className=o.containerFooter,this.options.footerHTML?t.innerHTML=this.options.footerHTML:t.innerHTML='\n <span class="'+o.previewDateRange+'"></span>\n <button type="button" class="'+o.buttonCancel+'">'+this.options.buttonText.cancel+'</button>\n <button type="button" class="'+o.buttonApply+'">'+this.options.buttonText.apply+"</button>\n ",this.options.singleMode){if(1===this.datePicked.length){var e=this.datePicked[0].format(this.options.format,this.options.lang);t.querySelector("."+o.previewDateRange).innerHTML=e}}else if(1===this.datePicked.length&&t.querySelector("."+o.buttonApply).setAttribute("disabled",""),2===this.datePicked.length){e=this.datePicked[0].format(this.options.format,this.options.lang);var i=this.datePicked[1].format(this.options.format,this.options.lang);t.querySelector("."+o.previewDateRange).innerHTML=""+e+this.options.delimiter+i}return this.emit("render:footer",t),t},e.prototype.renderWeekNumber=function(t){var e=document.createElement("div"),i=t.getWeek(this.options.firstDay);return e.className=o.weekNumber,e.innerHTML=53===i&&0===t.getMonth()?"53 / 1":i,e},e.prototype.renderTooltip=function(){var t=document.createElement("div");return t.className=o.containerTooltip,t},e.prototype.weekdayName=function(t,e){return void 0===e&&(e="short"),new Date(1970,0,t,12,0,0,0).toLocaleString(this.options.lang,{weekday:e})},e.prototype.calcSkipDays=function(t){var e=t.getDay()-this.options.firstDay;return e<0&&(e+=7),e},e}(r.LPCore);e.Calendar=c},function(t,e,i){"use strict";var a,s=this&&this.__extends||(a=function(t,e){return(a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var i in e)e.hasOwnProperty(i)&&(t[i]=e[i])})(t,e)},function(t,e){function i(){this.constructor=t}a(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}),r=this&&this.__assign||function(){return(r=Object.assign||function(t){for(var e,i=1,a=arguments.length;i<a;i++)for(var s in e=arguments[i])Object.prototype.hasOwnProperty.call(e,s)&&(t[s]=e[s]);return t}).apply(this,arguments)};Object.defineProperty(e,"__esModule",{value:!0});var n=i(7),o=i(0),l=i(1),c=function(t){function e(e){var i=t.call(this)||this;i.datePicked=[],i.calendars=[],i.options={element:null,elementEnd:null,parentEl:null,firstDay:1,format:"YYYY-MM-DD",lang:"en-US",delimiter:" - ",numberOfMonths:1,numberOfColumns:1,startDate:null,endDate:null,zIndex:9999,position:"auto",selectForward:!1,selectBackward:!1,splitView:!1,inlineMode:!1,singleMode:!0,autoApply:!0,allowRepick:!1,showWeekNumbers:!1,showTooltip:!0,scrollToDate:!0,mobileFriendly:!0,resetButton:!1,autoRefresh:!1,lockDaysFormat:"YYYY-MM-DD",lockDays:[],disallowLockDaysInRange:!1,lockDaysInclusivity:"[]",highlightedDaysFormat:"YYYY-MM-DD",highlightedDays:[],dropdowns:{minYear:1990,maxYear:null,months:!1,years:!1},buttonText:{apply:"Apply",cancel:"Cancel",previousMonth:'<svg width="11" height="16" xmlns="http://www.w3.org/2000/svg"><path d="M7.919 0l2.748 2.667L5.333 8l5.334 5.333L7.919 16 0 8z" fill-rule="nonzero"/></svg>',nextMonth:'<svg width="11" height="16" xmlns="http://www.w3.org/2000/svg"><path d="M2.748 16L0 13.333 5.333 8 0 2.667 2.748 0l7.919 8z" fill-rule="nonzero"/></svg>',reset:'<svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" width="24">\n <path d="M0 0h24v24H0z" fill="none"/>\n <path d="M13 3c-4.97 0-9 4.03-9 9H1l3.89 3.89.07.14L9 12H6c0-3.87 3.13-7 7-7s7 3.13 7 7-3.13 7-7 7c-1.93 0-3.68-.79-4.94-2.06l-1.42 1.42C8.27 19.99 10.51 21 13 21c4.97 0 9-4.03 9-9s-4.03-9-9-9zm-1 5v5l4.28 2.54.72-1.21-3.5-2.08V8H12z"/>\n </svg>'},tooltipText:{one:"day",other:"days"}},i.options=r(r({},i.options),e.element.dataset),Object.keys(i.options).forEach((function(t){"true"!==i.options[t]&&"false"!==i.options[t]||(i.options[t]="true"===i.options[t])}));var a=r(r({},i.options.dropdowns),e.dropdowns),s=r(r({},i.options.buttonText),e.buttonText),n=r(r({},i.options.tooltipText),e.tooltipText);i.options=r(r({},i.options),e),i.options.dropdowns=r({},a),i.options.buttonText=r({},s),i.options.tooltipText=r({},n),i.options.elementEnd||(i.options.allowRepick=!1),i.options.lockDays.length&&(i.options.lockDays=o.DateTime.convertArray(i.options.lockDays,i.options.lockDaysFormat)),i.options.highlightedDays.length&&(i.options.highlightedDays=o.DateTime.convertArray(i.options.highlightedDays,i.options.highlightedDaysFormat));var l=i.parseInput(),c=l[0],h=l[1];i.options.startDate&&(i.options.singleMode||i.options.endDate)&&(c=new o.DateTime(i.options.startDate,i.options.format,i.options.lang)),c&&i.options.endDate&&(h=new o.DateTime(i.options.endDate,i.options.format,i.options.lang)),c instanceof o.DateTime&&!isNaN(c.getTime())&&(i.options.startDate=c),i.options.startDate&&h instanceof o.DateTime&&!isNaN(h.getTime())&&(i.options.endDate=h),!i.options.singleMode||i.options.startDate instanceof o.DateTime||(i.options.startDate=null),i.options.singleMode||i.options.startDate instanceof o.DateTime&&i.options.endDate instanceof o.DateTime||(i.options.startDate=null,i.options.endDate=null);for(var d=0;d<i.options.numberOfMonths;d+=1){var u=i.options.startDate instanceof o.DateTime?i.options.startDate.clone():new o.DateTime;if(!i.options.startDate&&(0===d||i.options.splitView)){var p=i.options.maxDate?new o.DateTime(i.options.maxDate):null,f=i.options.minDate?new o.DateTime(i.options.minDate):null,g=i.options.numberOfMonths-1;f&&p&&u.isAfter(p)?(u=f.clone()).setDate(1):!f&&p&&u.isAfter(p)&&((u=p.clone()).setDate(1),u.setMonth(u.getMonth()-g))}u.setDate(1),u.setMonth(u.getMonth()+d),i.calendars[d]=u}if(i.options.showTooltip)if(i.options.tooltipPluralSelector)i.pluralSelector=i.options.tooltipPluralSelector;else try{var x=new Intl.PluralRules(i.options.lang);i.pluralSelector=x.select.bind(x)}catch(t){i.pluralSelector=function(t){return 0===Math.abs(t)?"one":"other"}}return i}return s(e,t),e.add=function(t,e){l.Litepicker.prototype[t]=e},e.prototype.DateTime=function(t,e){return t?new o.DateTime(t,e):new o.DateTime},e.prototype.init=function(){var t=this;this.options.plugins&&this.options.plugins.length&&this.options.plugins.forEach((function(e){l.Litepicker.prototype.hasOwnProperty(e)?l.Litepicker.prototype[e].init.call(t,t):console.warn("Litepicker: plugin «"+e+"» not found.")}))},e.prototype.parseInput=function(){var t=this.options.delimiter,e=new RegExp(""+t),i=this.options.element instanceof HTMLInputElement?this.options.element.value.split(t):[];if(this.options.elementEnd){if(this.options.element instanceof HTMLInputElement&&this.options.element.value.length&&this.options.elementEnd instanceof HTMLInputElement&&this.options.elementEnd.value.length)return[new o.DateTime(this.options.element.value,this.options.format),new o.DateTime(this.options.elementEnd.value,this.options.format)]}else if(this.options.singleMode){if(this.options.element instanceof HTMLInputElement&&this.options.element.value.length)return[new o.DateTime(this.options.element.value,this.options.format)]}else if(this.options.element instanceof HTMLInputElement&&e.test(this.options.element.value)&&i.length&&i.length%2==0){var a=i.slice(0,i.length/2).join(t),s=i.slice(i.length/2).join(t);return[new o.DateTime(a,this.options.format),new o.DateTime(s,this.options.format)]}return[]},e.prototype.isShowning=function(){return this.ui&&"none"!==this.ui.style.display},e.prototype.findPosition=function(t){var e=t.getBoundingClientRect(),i=this.ui.getBoundingClientRect(),a=this.options.position.split(" "),s=window.scrollX||window.pageXOffset,r=window.scrollY||window.pageYOffset,n=0,o=0;if("auto"!==a[0]&&/top|bottom/.test(a[0]))n=e[a[0]]+r,"top"===a[0]&&(n-=i.height);else{n=e.bottom+r;var l=e.bottom+i.height>window.innerHeight,c=e.top+r-i.height>=i.height;l&&c&&(n=e.top+r-i.height)}if(/left|right/.test(a[0])||a[1]&&"auto"!==a[1]&&/left|right/.test(a[1]))o=/left|right/.test(a[0])?e[a[0]]+s:e[a[1]]+s,"right"!==a[0]&&"right"!==a[1]||(o-=i.width);else{o=e.left+s,l=e.left+i.width>window.innerWidth;var h=e.right+s-i.width>=0;l&&h&&(o=e.right+s-i.width)}return{left:o,top:n}},e}(n.EventEmitter);e.LPCore=c},function(t,e,i){"use strict";var a,s="object"==typeof Reflect?Reflect:null,r=s&&"function"==typeof s.apply?s.apply:function(t,e,i){return Function.prototype.apply.call(t,e,i)};a=s&&"function"==typeof s.ownKeys?s.ownKeys:Object.getOwnPropertySymbols?function(t){return Object.getOwnPropertyNames(t).concat(Object.getOwnPropertySymbols(t))}:function(t){return Object.getOwnPropertyNames(t)};var n=Number.isNaN||function(t){return t!=t};function o(){o.init.call(this)}t.exports=o,o.EventEmitter=o,o.prototype._events=void 0,o.prototype._eventsCount=0,o.prototype._maxListeners=void 0;var l=10;function c(t){return void 0===t._maxListeners?o.defaultMaxListeners:t._maxListeners}function h(t,e,i,a){var s,r,n,o;if("function"!=typeof i)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof i);if(void 0===(r=t._events)?(r=t._events=Object.create(null),t._eventsCount=0):(void 0!==r.newListener&&(t.emit("newListener",e,i.listener?i.listener:i),r=t._events),n=r[e]),void 0===n)n=r[e]=i,++t._eventsCount;else if("function"==typeof n?n=r[e]=a?[i,n]:[n,i]:a?n.unshift(i):n.push(i),(s=c(t))>0&&n.length>s&&!n.warned){n.warned=!0;var l=new Error("Possible EventEmitter memory leak detected. "+n.length+" "+String(e)+" listeners added. Use emitter.setMaxListeners() to increase limit");l.name="MaxListenersExceededWarning",l.emitter=t,l.type=e,l.count=n.length,o=l,console&&console.warn&&console.warn(o)}return t}function d(){for(var t=[],e=0;e<arguments.length;e++)t.push(arguments[e]);this.fired||(this.target.removeListener(this.type,this.wrapFn),this.fired=!0,r(this.listener,this.target,t))}function u(t,e,i){var a={fired:!1,wrapFn:void 0,target:t,type:e,listener:i},s=d.bind(a);return s.listener=i,a.wrapFn=s,s}function p(t,e,i){var a=t._events;if(void 0===a)return[];var s=a[e];return void 0===s?[]:"function"==typeof s?i?[s.listener||s]:[s]:i?function(t){for(var e=new Array(t.length),i=0;i<e.length;++i)e[i]=t[i].listener||t[i];return e}(s):g(s,s.length)}function f(t){var e=this._events;if(void 0!==e){var i=e[t];if("function"==typeof i)return 1;if(void 0!==i)return i.length}return 0}function g(t,e){for(var i=new Array(e),a=0;a<e;++a)i[a]=t[a];return i}Object.defineProperty(o,"defaultMaxListeners",{enumerable:!0,get:function(){return l},set:function(t){if("number"!=typeof t||t<0||n(t))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+t+".");l=t}}),o.init=function(){void 0!==this._events&&this._events!==Object.getPrototypeOf(this)._events||(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},o.prototype.setMaxListeners=function(t){if("number"!=typeof t||t<0||n(t))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+t+".");return this._maxListeners=t,this},o.prototype.getMaxListeners=function(){return c(this)},o.prototype.emit=function(t){for(var e=[],i=1;i<arguments.length;i++)e.push(arguments[i]);var a="error"===t,s=this._events;if(void 0!==s)a=a&&void 0===s.error;else if(!a)return!1;if(a){var n;if(e.length>0&&(n=e[0]),n instanceof Error)throw n;var o=new Error("Unhandled error."+(n?" ("+n.message+")":""));throw o.context=n,o}var l=s[t];if(void 0===l)return!1;if("function"==typeof l)r(l,this,e);else{var c=l.length,h=g(l,c);for(i=0;i<c;++i)r(h[i],this,e)}return!0},o.prototype.addListener=function(t,e){return h(this,t,e,!1)},o.prototype.on=o.prototype.addListener,o.prototype.prependListener=function(t,e){return h(this,t,e,!0)},o.prototype.once=function(t,e){if("function"!=typeof e)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof e);return this.on(t,u(this,t,e)),this},o.prototype.prependOnceListener=function(t,e){if("function"!=typeof e)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof e);return this.prependListener(t,u(this,t,e)),this},o.prototype.removeListener=function(t,e){var i,a,s,r,n;if("function"!=typeof e)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof e);if(void 0===(a=this._events))return this;if(void 0===(i=a[t]))return this;if(i===e||i.listener===e)0==--this._eventsCount?this._events=Object.create(null):(delete a[t],a.removeListener&&this.emit("removeListener",t,i.listener||e));else if("function"!=typeof i){for(s=-1,r=i.length-1;r>=0;r--)if(i[r]===e||i[r].listener===e){n=i[r].listener,s=r;break}if(s<0)return this;0===s?i.shift():function(t,e){for(;e+1<t.length;e++)t[e]=t[e+1];t.pop()}(i,s),1===i.length&&(a[t]=i[0]),void 0!==a.removeListener&&this.emit("removeListener",t,n||e)}return this},o.prototype.off=o.prototype.removeListener,o.prototype.removeAllListeners=function(t){var e,i,a;if(void 0===(i=this._events))return this;if(void 0===i.removeListener)return 0===arguments.length?(this._events=Object.create(null),this._eventsCount=0):void 0!==i[t]&&(0==--this._eventsCount?this._events=Object.create(null):delete i[t]),this;if(0===arguments.length){var s,r=Object.keys(i);for(a=0;a<r.length;++a)"removeListener"!==(s=r[a])&&this.removeAllListeners(s);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if("function"==typeof(e=i[t]))this.removeListener(t,e);else if(void 0!==e)for(a=e.length-1;a>=0;a--)this.removeListener(t,e[a]);return this},o.prototype.listeners=function(t){return p(this,t,!0)},o.prototype.rawListeners=function(t){return p(this,t,!1)},o.listenerCount=function(t,e){return"function"==typeof t.listenerCount?t.listenerCount(e):f.call(t,e)},o.prototype.listenerCount=f,o.prototype.eventNames=function(){return this._eventsCount>0?a(this._events):[]}},function(t,e,i){(e=i(9)(!1)).push([t.i,':root{--litepicker-container-months-color-bg: #fff;--litepicker-container-months-box-shadow-color: #ddd;--litepicker-footer-color-bg: #fafafa;--litepicker-footer-box-shadow-color: #ddd;--litepicker-tooltip-color-bg: #fff;--litepicker-month-header-color: #333;--litepicker-button-prev-month-color: #9e9e9e;--litepicker-button-next-month-color: #9e9e9e;--litepicker-button-prev-month-color-hover: #2196f3;--litepicker-button-next-month-color-hover: #2196f3;--litepicker-month-width: calc(var(--litepicker-day-width) * 7);--litepicker-month-weekday-color: #9e9e9e;--litepicker-month-week-number-color: #9e9e9e;--litepicker-day-width: 38px;--litepicker-day-color: #333;--litepicker-day-color-hover: #2196f3;--litepicker-is-today-color: #f44336;--litepicker-is-in-range-color: #bbdefb;--litepicker-is-locked-color: #9e9e9e;--litepicker-is-start-color: #fff;--litepicker-is-start-color-bg: #2196f3;--litepicker-is-end-color: #fff;--litepicker-is-end-color-bg: #2196f3;--litepicker-button-cancel-color: #fff;--litepicker-button-cancel-color-bg: #9e9e9e;--litepicker-button-apply-color: #fff;--litepicker-button-apply-color-bg: #2196f3;--litepicker-button-reset-color: #909090;--litepicker-button-reset-color-hover: #2196f3;--litepicker-highlighted-day-color: #333;--litepicker-highlighted-day-color-bg: #ffeb3b}.show-week-numbers{--litepicker-month-width: calc(var(--litepicker-day-width) * 8)}.litepicker{font-family:-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;font-size:0.8em;display:none}.litepicker button{border:none;background:none}.litepicker .container__main{display:-webkit-box;display:-ms-flexbox;display:flex}.litepicker .container__months{display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;background-color:var(--litepicker-container-months-color-bg);border-radius:5px;-webkit-box-shadow:0 0 5px var(--litepicker-container-months-box-shadow-color);box-shadow:0 0 5px var(--litepicker-container-months-box-shadow-color);width:calc(var(--litepicker-month-width) + 10px);-webkit-box-sizing:content-box;box-sizing:content-box}.litepicker .container__months.columns-2{width:calc((var(--litepicker-month-width) * 2) + 20px)}.litepicker .container__months.columns-3{width:calc((var(--litepicker-month-width) * 3) + 30px)}.litepicker .container__months.columns-4{width:calc((var(--litepicker-month-width) * 4) + 40px)}.litepicker .container__months.split-view .month-item-header .button-previous-month,.litepicker .container__months.split-view .month-item-header .button-next-month{visibility:visible}.litepicker .container__months .month-item{padding:5px;width:var(--litepicker-month-width);-webkit-box-sizing:content-box;box-sizing:content-box}.litepicker .container__months .month-item-header{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;font-weight:500;padding:10px 5px;text-align:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;color:var(--litepicker-month-header-color)}.litepicker .container__months .month-item-header div{-webkit-box-flex:1;-ms-flex:1;flex:1}.litepicker .container__months .month-item-header div>.month-item-name{margin-right:5px}.litepicker .container__months .month-item-header div>.month-item-year{padding:0}.litepicker .container__months .month-item-header .reset-button{color:var(--litepicker-button-reset-color)}.litepicker .container__months .month-item-header .reset-button>svg{fill:var(--litepicker-button-reset-color)}.litepicker .container__months .month-item-header .reset-button *{pointer-events:none}.litepicker .container__months .month-item-header .reset-button:hover{color:var(--litepicker-button-reset-color-hover)}.litepicker .container__months .month-item-header .reset-button:hover>svg{fill:var(--litepicker-button-reset-color-hover)}.litepicker .container__months .month-item-header .button-previous-month,.litepicker .container__months .month-item-header .button-next-month{visibility:hidden;text-decoration:none;padding:3px 5px;border-radius:3px;-webkit-transition:color 0.3s, border 0.3s;transition:color 0.3s, border 0.3s;cursor:default}.litepicker .container__months .month-item-header .button-previous-month *,.litepicker .container__months .month-item-header .button-next-month *{pointer-events:none}.litepicker .container__months .month-item-header .button-previous-month{color:var(--litepicker-button-prev-month-color)}.litepicker .container__months .month-item-header .button-previous-month>svg,.litepicker .container__months .month-item-header .button-previous-month>img{fill:var(--litepicker-button-prev-month-color)}.litepicker .container__months .month-item-header .button-previous-month:hover{color:var(--litepicker-button-prev-month-color-hover)}.litepicker .container__months .month-item-header .button-previous-month:hover>svg{fill:var(--litepicker-button-prev-month-color-hover)}.litepicker .container__months .month-item-header .button-next-month{color:var(--litepicker-button-next-month-color)}.litepicker .container__months .month-item-header .button-next-month>svg,.litepicker .container__months .month-item-header .button-next-month>img{fill:var(--litepicker-button-next-month-color)}.litepicker .container__months .month-item-header .button-next-month:hover{color:var(--litepicker-button-next-month-color-hover)}.litepicker .container__months .month-item-header .button-next-month:hover>svg{fill:var(--litepicker-button-next-month-color-hover)}.litepicker .container__months .month-item-weekdays-row{display:-webkit-box;display:-ms-flexbox;display:flex;justify-self:center;-webkit-box-pack:start;-ms-flex-pack:start;justify-content:flex-start;color:var(--litepicker-month-weekday-color)}.litepicker .container__months .month-item-weekdays-row>div{padding:5px 0;font-size:85%;-webkit-box-flex:1;-ms-flex:1;flex:1;width:var(--litepicker-day-width);text-align:center}.litepicker .container__months .month-item:first-child .button-previous-month{visibility:visible}.litepicker .container__months .month-item:last-child .button-next-month{visibility:visible}.litepicker .container__months .month-item.no-previous-month .button-previous-month{visibility:hidden}.litepicker .container__months .month-item.no-next-month .button-next-month{visibility:hidden}.litepicker .container__days{display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;justify-self:center;-webkit-box-pack:start;-ms-flex-pack:start;justify-content:flex-start;text-align:center;-webkit-box-sizing:content-box;box-sizing:content-box}.litepicker .container__days>div,.litepicker .container__days>a{padding:5px 0;width:var(--litepicker-day-width)}.litepicker .container__days .day-item{color:var(--litepicker-day-color);text-align:center;text-decoration:none;border-radius:3px;-webkit-transition:color 0.3s, border 0.3s;transition:color 0.3s, border 0.3s;cursor:default}.litepicker .container__days .day-item:hover{color:var(--litepicker-day-color-hover);-webkit-box-shadow:inset 0 0 0 1px var(--litepicker-day-color-hover);box-shadow:inset 0 0 0 1px var(--litepicker-day-color-hover)}.litepicker .container__days .day-item.is-today{color:var(--litepicker-is-today-color)}.litepicker .container__days .day-item.is-locked{color:var(--litepicker-is-locked-color)}.litepicker .container__days .day-item.is-locked:hover{color:var(--litepicker-is-locked-color);-webkit-box-shadow:none;box-shadow:none;cursor:default}.litepicker .container__days .day-item.is-in-range{background-color:var(--litepicker-is-in-range-color);border-radius:0}.litepicker .container__days .day-item.is-start-date{color:var(--litepicker-is-start-color);background-color:var(--litepicker-is-start-color-bg);border-top-left-radius:5px;border-bottom-left-radius:5px;border-top-right-radius:0;border-bottom-right-radius:0}.litepicker .container__days .day-item.is-start-date.is-flipped{border-top-left-radius:0;border-bottom-left-radius:0;border-top-right-radius:5px;border-bottom-right-radius:5px}.litepicker .container__days .day-item.is-end-date{color:var(--litepicker-is-end-color);background-color:var(--litepicker-is-end-color-bg);border-top-left-radius:0;border-bottom-left-radius:0;border-top-right-radius:5px;border-bottom-right-radius:5px}.litepicker .container__days .day-item.is-end-date.is-flipped{border-top-left-radius:5px;border-bottom-left-radius:5px;border-top-right-radius:0;border-bottom-right-radius:0}.litepicker .container__days .day-item.is-start-date.is-end-date{border-top-left-radius:5px;border-bottom-left-radius:5px;border-top-right-radius:5px;border-bottom-right-radius:5px}.litepicker .container__days .day-item.is-highlighted{color:var(--litepicker-highlighted-day-color);background-color:var(--litepicker-highlighted-day-color-bg)}.litepicker .container__days .week-number{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;color:var(--litepicker-month-week-number-color);font-size:85%}.litepicker .container__footer{text-align:right;padding:10px 5px;margin:0 5px;background-color:var(--litepicker-footer-color-bg);-webkit-box-shadow:inset 0px 3px 3px 0px var(--litepicker-footer-box-shadow-color);box-shadow:inset 0px 3px 3px 0px var(--litepicker-footer-box-shadow-color);border-bottom-left-radius:5px;border-bottom-right-radius:5px}.litepicker .container__footer .preview-date-range{margin-right:10px;font-size:90%}.litepicker .container__footer .button-cancel{background-color:var(--litepicker-button-cancel-color-bg);color:var(--litepicker-button-cancel-color);border:0;padding:3px 7px 4px;border-radius:3px}.litepicker .container__footer .button-cancel *{pointer-events:none}.litepicker .container__footer .button-apply{background-color:var(--litepicker-button-apply-color-bg);color:var(--litepicker-button-apply-color);border:0;padding:3px 7px 4px;border-radius:3px;margin-left:10px;margin-right:10px}.litepicker .container__footer .button-apply:disabled{opacity:0.7}.litepicker .container__footer .button-apply *{pointer-events:none}.litepicker .container__tooltip{position:absolute;margin-top:-4px;padding:4px 8px;border-radius:4px;background-color:var(--litepicker-tooltip-color-bg);-webkit-box-shadow:0 1px 3px rgba(0,0,0,0.25);box-shadow:0 1px 3px rgba(0,0,0,0.25);white-space:nowrap;font-size:11px;pointer-events:none;visibility:hidden}.litepicker .container__tooltip:before{position:absolute;bottom:-5px;left:calc(50% - 5px);border-top:5px solid rgba(0,0,0,0.12);border-right:5px solid transparent;border-left:5px solid transparent;content:""}.litepicker .container__tooltip:after{position:absolute;bottom:-4px;left:calc(50% - 4px);border-top:4px solid var(--litepicker-tooltip-color-bg);border-right:4px solid transparent;border-left:4px solid transparent;content:""}\n',""]),e.locals={showWeekNumbers:"show-week-numbers",litepicker:"litepicker",containerMain:"container__main",containerMonths:"container__months",columns2:"columns-2",columns3:"columns-3",columns4:"columns-4",splitView:"split-view",monthItemHeader:"month-item-header",buttonPreviousMonth:"button-previous-month",buttonNextMonth:"button-next-month",monthItem:"month-item",monthItemName:"month-item-name",monthItemYear:"month-item-year",resetButton:"reset-button",monthItemWeekdaysRow:"month-item-weekdays-row",noPreviousMonth:"no-previous-month",noNextMonth:"no-next-month",containerDays:"container__days",dayItem:"day-item",isToday:"is-today",isLocked:"is-locked",isInRange:"is-in-range",isStartDate:"is-start-date",isFlipped:"is-flipped",isEndDate:"is-end-date",isHighlighted:"is-highlighted",weekNumber:"week-number",containerFooter:"container__footer",previewDateRange:"preview-date-range",buttonCancel:"button-cancel",buttonApply:"button-apply",containerTooltip:"container__tooltip"},t.exports=e},function(t,e,i){"use strict";t.exports=function(t){var e=[];return e.toString=function(){return this.map((function(e){var i=function(t,e){var i,a,s,r=t[1]||"",n=t[3];if(!n)return r;if(e&&"function"==typeof btoa){var o=(i=n,a=btoa(unescape(encodeURIComponent(JSON.stringify(i)))),s="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(a),"/*# ".concat(s," */")),l=n.sources.map((function(t){return"/*# sourceURL=".concat(n.sourceRoot||"").concat(t," */")}));return[r].concat(l).concat([o]).join("\n")}return[r].join("\n")}(e,t);return e[2]?"@media ".concat(e[2]," {").concat(i,"}"):i})).join("")},e.i=function(t,i,a){"string"==typeof t&&(t=[[null,t,""]]);var s={};if(a)for(var r=0;r<this.length;r++){var n=this[r][0];null!=n&&(s[n]=!0)}for(var o=0;o<t.length;o++){var l=[].concat(t[o]);a&&s[l[0]]||(i&&(l[2]?l[2]="".concat(i," and ").concat(l[2]):l[2]=i),e.push(l))}},e}},function(t,e,i){"use strict";var a,s={},r=function(){var t={};return function(e){if(void 0===t[e]){var i=document.querySelector(e);if(window.HTMLIFrameElement&&i instanceof window.HTMLIFrameElement)try{i=i.contentDocument.head}catch(t){i=null}t[e]=i}return t[e]}}();function n(t,e){for(var i=[],a={},s=0;s<t.length;s++){var r=t[s],n=e.base?r[0]+e.base:r[0],o={css:r[1],media:r[2],sourceMap:r[3]};a[n]?a[n].parts.push(o):i.push(a[n]={id:n,parts:[o]})}return i}function o(t,e){for(var i=0;i<t.length;i++){var a=t[i],r=s[a.id],n=0;if(r){for(r.refs++;n<r.parts.length;n++)r.parts[n](a.parts[n]);for(;n<a.parts.length;n++)r.parts.push(g(a.parts[n],e))}else{for(var o=[];n<a.parts.length;n++)o.push(g(a.parts[n],e));s[a.id]={id:a.id,refs:1,parts:o}}}}function l(t){var e=document.createElement("style");if(void 0===t.attributes.nonce){var a=i.nc;a&&(t.attributes.nonce=a)}if(Object.keys(t.attributes).forEach((function(i){e.setAttribute(i,t.attributes[i])})),"function"==typeof t.insert)t.insert(e);else{var s=r(t.insert||"head");if(!s)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");s.appendChild(e)}return e}var c,h=(c=[],function(t,e){return c[t]=e,c.filter(Boolean).join("\n")});function d(t,e,i,a){var s=i?"":a.css;if(t.styleSheet)t.styleSheet.cssText=h(e,s);else{var r=document.createTextNode(s),n=t.childNodes;n[e]&&t.removeChild(n[e]),n.length?t.insertBefore(r,n[e]):t.appendChild(r)}}function u(t,e,i){var a=i.css,s=i.media,r=i.sourceMap;if(s&&t.setAttribute("media",s),r&&btoa&&(a+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(r))))," */")),t.styleSheet)t.styleSheet.cssText=a;else{for(;t.firstChild;)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(a))}}var p=null,f=0;function g(t,e){var i,a,s;if(e.singleton){var r=f++;i=p||(p=l(e)),a=d.bind(null,i,r,!1),s=d.bind(null,i,r,!0)}else i=l(e),a=u.bind(null,i,e),s=function(){!function(t){if(null===t.parentNode)return!1;t.parentNode.removeChild(t)}(i)};return a(t),function(e){if(e){if(e.css===t.css&&e.media===t.media&&e.sourceMap===t.sourceMap)return;a(t=e)}else s()}}t.exports=function(t,e){(e=e||{}).attributes="object"==typeof e.attributes?e.attributes:{},e.singleton||"boolean"==typeof e.singleton||(e.singleton=(void 0===a&&(a=Boolean(window&&document&&document.all&&!window.atob)),a));var i=n(t,e);return o(i,e),function(t){for(var a=[],r=0;r<i.length;r++){var l=i[r],c=s[l.id];c&&(c.refs--,a.push(c))}t&&o(n(t,e),e);for(var h=0;h<a.length;h++){var d=a[h];if(0===d.refs){for(var u=0;u<d.parts.length;u++)d.parts[u]();delete s[d.id]}}}}},function(t,e,i){"use strict";var a=this&&this.__assign||function(){return(a=Object.assign||function(t){for(var e,i=1,a=arguments.length;i<a;i++)for(var s in e=arguments[i])Object.prototype.hasOwnProperty.call(e,s)&&(t[s]=e[s]);return t}).apply(this,arguments)};Object.defineProperty(e,"__esModule",{value:!0});var s=i(0),r=i(1),n=i(2);r.Litepicker.prototype.show=function(t){void 0===t&&(t=null),this.emit("before:show",t);var e=t||this.options.element;if(this.triggerElement=e,!this.isShowning()){if(this.options.inlineMode)return this.ui.style.position="relative",this.ui.style.display="inline-block",this.ui.style.top=null,this.ui.style.left=null,this.ui.style.bottom=null,void(this.ui.style.right=null);this.scrollToDate(t),this.render(),this.ui.style.position="absolute",this.ui.style.display="block",this.ui.style.zIndex=this.options.zIndex;var i=this.findPosition(e);this.ui.style.top=i.top+"px",this.ui.style.left=i.left+"px",this.ui.style.right=null,this.ui.style.bottom=null,this.emit("show",t)}},r.Litepicker.prototype.hide=function(){this.isShowning()&&(this.datePicked.length=0,this.updateInput(),this.options.inlineMode?this.render():(this.ui.style.display="none",this.emit("hide")))},r.Litepicker.prototype.getDate=function(){return this.getStartDate()},r.Litepicker.prototype.getStartDate=function(){return this.options.startDate?this.options.startDate.clone():null},r.Litepicker.prototype.getEndDate=function(){return this.options.endDate?this.options.endDate.clone():null},r.Litepicker.prototype.setDate=function(t,e){void 0===e&&(e=!1);var i=new s.DateTime(t,this.options.format,this.options.lang);n.dateIsLocked(i,this.options,[i])&&!e?this.emit("error:date",i):(this.setStartDate(t),this.options.inlineMode&&this.render(),this.emit("selected",this.getDate()))},r.Litepicker.prototype.setStartDate=function(t){t&&(this.options.startDate=new s.DateTime(t,this.options.format,this.options.lang),this.updateInput())},r.Litepicker.prototype.setEndDate=function(t){t&&(this.options.endDate=new s.DateTime(t,this.options.format,this.options.lang),this.options.startDate.getTime()>this.options.endDate.getTime()&&(this.options.endDate=this.options.startDate.clone(),this.options.startDate=new s.DateTime(t,this.options.format,this.options.lang)),this.updateInput())},r.Litepicker.prototype.setDateRange=function(t,e,i){void 0===i&&(i=!1),this.triggerElement=void 0;var a=new s.DateTime(t,this.options.format,this.options.lang),r=new s.DateTime(e,this.options.format,this.options.lang);(this.options.disallowLockDaysInRange?n.rangeIsLocked([a,r],this.options):n.dateIsLocked(a,this.options,[a,r])||n.dateIsLocked(r,this.options,[a,r]))&&!i?this.emit("error:range",[a,r]):(this.setStartDate(a),this.setEndDate(r),this.options.inlineMode&&this.render(),this.updateInput(),this.emit("selected",this.getStartDate(),this.getEndDate()))},r.Litepicker.prototype.gotoDate=function(t,e){void 0===e&&(e=0);var i=new s.DateTime(t);i.setDate(1),this.calendars[e]=i.clone(),this.render()},r.Litepicker.prototype.setLockDays=function(t){this.options.lockDays=s.DateTime.convertArray(t,this.options.lockDaysFormat),this.render()},r.Litepicker.prototype.setHighlightedDays=function(t){this.options.highlightedDays=s.DateTime.convertArray(t,this.options.highlightedDaysFormat),this.render()},r.Litepicker.prototype.setOptions=function(t){delete t.element,delete t.elementEnd,delete t.parentEl,t.startDate&&(t.startDate=new s.DateTime(t.startDate,this.options.format,this.options.lang)),t.endDate&&(t.endDate=new s.DateTime(t.endDate,this.options.format,this.options.lang));var e=a(a({},this.options.dropdowns),t.dropdowns),i=a(a({},this.options.buttonText),t.buttonText),r=a(a({},this.options.tooltipText),t.tooltipText);this.options=a(a({},this.options),t),this.options.dropdowns=a({},e),this.options.buttonText=a({},i),this.options.tooltipText=a({},r),!this.options.singleMode||this.options.startDate instanceof s.DateTime||(this.options.startDate=null,this.options.endDate=null),this.options.singleMode||this.options.startDate instanceof s.DateTime&&this.options.endDate instanceof s.DateTime||(this.options.startDate=null,this.options.endDate=null);for(var n=0;n<this.options.numberOfMonths;n+=1){var o=this.options.startDate?this.options.startDate.clone():new s.DateTime;o.setDate(1),o.setMonth(o.getMonth()+n),this.calendars[n]=o}this.options.lockDays.length&&(this.options.lockDays=s.DateTime.convertArray(this.options.lockDays,this.options.lockDaysFormat)),this.options.highlightedDays.length&&(this.options.highlightedDays=s.DateTime.convertArray(this.options.highlightedDays,this.options.highlightedDaysFormat)),this.render(),this.options.inlineMode&&this.show(),this.updateInput()},r.Litepicker.prototype.clearSelection=function(){this.options.startDate=null,this.options.endDate=null,this.datePicked.length=0,this.updateInput(),this.isShowning()&&this.render(),this.emit("clear:selection")},r.Litepicker.prototype.destroy=function(){this.ui&&this.ui.parentNode&&(this.ui.parentNode.removeChild(this.ui),this.ui=null),this.emit("destroy")}}])},6710:function(){!function(t){var e={};function i(a){if(e[a])return e[a].exports;var s=e[a]={i:a,l:!1,exports:{}};return t[a].call(s.exports,s,s.exports,i),s.l=!0,s.exports}i.m=t,i.c=e,i.d=function(t,e,a){i.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:a})},i.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},i.t=function(t,e){if(1&e&&(t=i(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var a=Object.create(null);if(i.r(a),Object.defineProperty(a,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var s in t)i.d(a,s,function(e){return t[e]}.bind(null,s));return a},i.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return i.d(e,"a",e),e},i.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},i.p="",i(i.s=8)}([function(t,e,i){"use strict";t.exports=function(t){var e=[];return e.toString=function(){return this.map((function(e){var i=function(t,e){var i,a,s,r=t[1]||"",n=t[3];if(!n)return r;if(e&&"function"==typeof btoa){var o=(i=n,a=btoa(unescape(encodeURIComponent(JSON.stringify(i)))),s="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(a),"/*# ".concat(s," */")),l=n.sources.map((function(t){return"/*# sourceURL=".concat(n.sourceRoot||"").concat(t," */")}));return[r].concat(l).concat([o]).join("\n")}return[r].join("\n")}(e,t);return e[2]?"@media ".concat(e[2]," {").concat(i,"}"):i})).join("")},e.i=function(t,i,a){"string"==typeof t&&(t=[[null,t,""]]);var s={};if(a)for(var r=0;r<this.length;r++){var n=this[r][0];null!=n&&(s[n]=!0)}for(var o=0;o<t.length;o++){var l=[].concat(t[o]);a&&s[l[0]]||(i&&(l[2]?l[2]="".concat(i," and ").concat(l[2]):l[2]=i),e.push(l))}},e}},function(t,e,i){"use strict";var a,s={},r=function(){var t={};return function(e){if(void 0===t[e]){var i=document.querySelector(e);if(window.HTMLIFrameElement&&i instanceof window.HTMLIFrameElement)try{i=i.contentDocument.head}catch(t){i=null}t[e]=i}return t[e]}}();function n(t,e){for(var i=[],a={},s=0;s<t.length;s++){var r=t[s],n=e.base?r[0]+e.base:r[0],o={css:r[1],media:r[2],sourceMap:r[3]};a[n]?a[n].parts.push(o):i.push(a[n]={id:n,parts:[o]})}return i}function o(t,e){for(var i=0;i<t.length;i++){var a=t[i],r=s[a.id],n=0;if(r){for(r.refs++;n<r.parts.length;n++)r.parts[n](a.parts[n]);for(;n<a.parts.length;n++)r.parts.push(g(a.parts[n],e))}else{for(var o=[];n<a.parts.length;n++)o.push(g(a.parts[n],e));s[a.id]={id:a.id,refs:1,parts:o}}}}function l(t){var e=document.createElement("style");if(void 0===t.attributes.nonce){var a=i.nc;a&&(t.attributes.nonce=a)}if(Object.keys(t.attributes).forEach((function(i){e.setAttribute(i,t.attributes[i])})),"function"==typeof t.insert)t.insert(e);else{var s=r(t.insert||"head");if(!s)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");s.appendChild(e)}return e}var c,h=(c=[],function(t,e){return c[t]=e,c.filter(Boolean).join("\n")});function d(t,e,i,a){var s=i?"":a.css;if(t.styleSheet)t.styleSheet.cssText=h(e,s);else{var r=document.createTextNode(s),n=t.childNodes;n[e]&&t.removeChild(n[e]),n.length?t.insertBefore(r,n[e]):t.appendChild(r)}}function u(t,e,i){var a=i.css,s=i.media,r=i.sourceMap;if(s&&t.setAttribute("media",s),r&&btoa&&(a+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(r))))," */")),t.styleSheet)t.styleSheet.cssText=a;else{for(;t.firstChild;)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(a))}}var p=null,f=0;function g(t,e){var i,a,s;if(e.singleton){var r=f++;i=p||(p=l(e)),a=d.bind(null,i,r,!1),s=d.bind(null,i,r,!0)}else i=l(e),a=u.bind(null,i,e),s=function(){!function(t){if(null===t.parentNode)return!1;t.parentNode.removeChild(t)}(i)};return a(t),function(e){if(e){if(e.css===t.css&&e.media===t.media&&e.sourceMap===t.sourceMap)return;a(t=e)}else s()}}t.exports=function(t,e){(e=e||{}).attributes="object"==typeof e.attributes?e.attributes:{},e.singleton||"boolean"==typeof e.singleton||(e.singleton=(void 0===a&&(a=Boolean(window&&document&&document.all&&!window.atob)),a));var i=n(t,e);return o(i,e),function(t){for(var a=[],r=0;r<i.length;r++){var l=i[r],c=s[l.id];c&&(c.refs--,a.push(c))}t&&o(n(t,e),e);for(var h=0;h<a.length;h++){var d=a[h];if(0===d.refs){for(var u=0;u<d.parts.length;u++)d.parts[u]();delete s[d.id]}}}}},,,,,,,function(t,e,i){"use strict";function a(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),i.push.apply(i,a)}return i}function s(t){for(var e=1;e<arguments.length;e++){var i=null!=arguments[e]?arguments[e]:{};e%2?a(Object(i),!0).forEach((function(e){r(t,e,i[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):a(Object(i)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(i,e))}))}return t}function r(t,e,i){return e in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}i.r(e),i(9),Litepicker.add("ranges",{init:function(t){var e={position:"left",customRanges:{},customRangesLabels:["Today","Yesterday","Last 7 Days","Last 30 Days","This Month","Last Month"],force:!1,autoApply:t.options.autoApply};t.options.ranges=s(s({},e),t.options.ranges),t.options.singleMode=!1;var i=t.options.ranges;if(!Object.keys(i.customRanges).length){var a,n=t.DateTime();i.customRanges=(r(a={},i.customRangesLabels[0],[n.clone(),n.clone()]),r(a,i.customRangesLabels[1],[n.clone().subtract(1,"day"),n.clone().subtract(1,"day")]),r(a,i.customRangesLabels[2],[n.clone().subtract(6,"day"),n]),r(a,i.customRangesLabels[3],[n.clone().subtract(29,"day"),n]),r(a,i.customRangesLabels[4],function(t){var e=t.clone();return e.setDate(1),[e,new Date(t.getFullYear(),t.getMonth()+1,0)]}(n)),r(a,i.customRangesLabels[5],function(t){var e=t.clone();return e.setDate(1),e.setMonth(t.getMonth()-1),[e,new Date(t.getFullYear(),t.getMonth(),0)]}(n)),a)}t.on("render",(function(e){var a=document.createElement("div");a.className="container__predefined-ranges",t.ui.dataset.rangesPosition=i.position,Object.keys(i.customRanges).forEach((function(s){var r=i.customRanges[s],n=document.createElement("button");n.innerText=s,n.tabIndex=e.dataset.plugins.indexOf("keyboardnav")>=0?1:-1,n.dataset.start=r[0].getTime(),n.dataset.end=r[1].getTime(),n.addEventListener("click",(function(e){var a=e.target;if(a){var s=t.DateTime(Number(a.dataset.start)),r=t.DateTime(Number(a.dataset.end));i.autoApply?(t.setDateRange(s,r,i.force),t.emit("ranges.selected",s,r),t.hide()):(t.datePicked=[s,r],t.emit("ranges.preselect",s,r)),!t.options.inlineMode&&i.autoApply||t.gotoDate(s)}})),a.appendChild(n)})),e.querySelector(".container__main").prepend(a)}))}})},function(t,e,i){var a=i(10);"string"==typeof a&&(a=[[t.i,a,""]]);var s={insert:function(t){var e=document.querySelector("head"),i=window._lastElementInsertedByStyleLoader;window.disableLitepickerStyles||(i?i.nextSibling?e.insertBefore(t,i.nextSibling):e.appendChild(t):e.insertBefore(t,e.firstChild),window._lastElementInsertedByStyleLoader=t)},singleton:!1};i(1)(a,s),a.locals&&(t.exports=a.locals)},function(t,e,i){(e=i(0)(!1)).push([t.i,'.litepicker[data-plugins*="ranges"] > .container__main > .container__predefined-ranges {\n display: flex;\n flex-direction: column;\n align-items: flex-start;\n background: var(--litepicker-container-months-color-bg);\n box-shadow: -2px 0px 5px var(--litepicker-footer-box-shadow-color);\n border-radius: 3px;\n}\n.litepicker[data-plugins*="ranges"][data-ranges-position="left"] > .container__main {\n /* */\n}\n.litepicker[data-plugins*="ranges"][data-ranges-position="right"] > .container__main{\n flex-direction: row-reverse;\n}\n.litepicker[data-plugins*="ranges"][data-ranges-position="right"] > .container__main > .container__predefined-ranges {\n box-shadow: 2px 0px 2px var(--litepicker-footer-box-shadow-color);\n}\n.litepicker[data-plugins*="ranges"][data-ranges-position="top"] > .container__main {\n flex-direction: column;\n}\n.litepicker[data-plugins*="ranges"][data-ranges-position="top"] > .container__main > .container__predefined-ranges {\n flex-direction: row;\n box-shadow: 2px 0px 2px var(--litepicker-footer-box-shadow-color);\n}\n.litepicker[data-plugins*="ranges"][data-ranges-position="bottom"] > .container__main {\n flex-direction: column-reverse;\n}\n.litepicker[data-plugins*="ranges"][data-ranges-position="bottom"] > .container__main > .container__predefined-ranges {\n flex-direction: row;\n box-shadow: 2px 0px 2px var(--litepicker-footer-box-shadow-color);\n}\n.litepicker[data-plugins*="ranges"] > .container__main > .container__predefined-ranges button {\n padding: 5px;\n margin: 2px 0;\n}\n.litepicker[data-plugins*="ranges"][data-ranges-position="left"] > .container__main > .container__predefined-ranges button,\n.litepicker[data-plugins*="ranges"][data-ranges-position="right"] > .container__main > .container__predefined-ranges button{\n width: 100%;\n text-align: left;\n}\n.litepicker[data-plugins*="ranges"] > .container__main > .container__predefined-ranges button:hover {\n cursor: default;\n opacity: .6;\n}',""]),t.exports=e}])},2703:function(t,e,i){"use strict";var a=i(414);function s(){}function r(){}r.resetWarningCache=s,t.exports=function(){function t(t,e,i,s,r,n){if(n!==a){var o=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 o.name="Invariant Violation",o}}function e(){return t}t.isRequired=t;var i={array:t,bigint:t,bool:t,func:t,number:t,object:t,string:t,symbol:t,any:t,arrayOf:e,element:t,elementType:t,instanceOf:e,node:t,objectOf:e,oneOf:e,oneOfType:e,shape:e,exact:e,checkPropTypes:r,resetWarningCache:s};return i.PropTypes=i,i}},5697:function(t,e,i){t.exports=i(2703)()},414:function(t){"use strict";t.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},7129:function(t,e){"use strict";var i=Object.prototype.hasOwnProperty;function a(t){try{return decodeURIComponent(t.replace(/\+/g," "))}catch(t){return null}}function s(t){try{return encodeURIComponent(t)}catch(t){return null}}e.stringify=function(t,e){e=e||"";var a,r,n=[];for(r in"string"!=typeof e&&(e="?"),t)if(i.call(t,r)){if((a=t[r])||null!=a&&!isNaN(a)||(a=""),r=s(r),a=s(a),null===r||null===a)continue;n.push(r+"="+a)}return n.length?e+n.join("&"):""},e.parse=function(t){for(var e,i=/([^=?#&]+)=?([^&]*)/g,s={};e=i.exec(t);){var r=a(e[1]),n=a(e[2]);null===r||null===n||r in s||(s[r]=n)}return s}},7229:function(t,e,i){"use strict";var a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},s=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var i=arguments[e];for(var a in i)Object.prototype.hasOwnProperty.call(i,a)&&(t[a]=i[a])}return t},r=function(){function t(t,e){for(var i=0;i<e.length;i++){var a=e[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(t,a.key,a)}}return function(e,i,a){return i&&t(e.prototype,i),a&&t(e,a),e}}(),n=h(i(5927)),o=i(9196),l=h(o),c=h(i(5697));function h(t){return t&&t.__esModule?t:{default:t}}window.ApexCharts=n.default;var d=function(){function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t);var i=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return l.default.createRef?i.chartRef=l.default.createRef():i.setRef=function(t){return i.chartRef=t},i.chart=null,i}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(t,o.Component),r(t,[{key:"render",value:function(){var t=this.props,e=(t.type,t.height,t.width,t.series,t.options,function(t,e){var i={};for(var a in t)0<=e.indexOf(a)||Object.prototype.hasOwnProperty.call(t,a)&&(i[a]=t[a]);return i}(t,["type","height","width","series","options"]));return l.default.createElement("div",s({ref:l.default.createRef?this.chartRef:this.setRef},e))}},{key:"componentDidMount",value:function(){var t=l.default.createRef?this.chartRef.current:this.chartRef;this.chart=new n.default(t,this.getConfig()),this.chart.render()}},{key:"getConfig",value:function(){var t=this.props,e=t.type,i=t.height,a=t.width,s=t.series,r=t.options,n={chart:{type:e,height:i,width:a},series:s};return this.extend(r,n)}},{key:"isObject",value:function(t){return t&&"object"===(void 0===t?"undefined":a(t))&&!Array.isArray(t)&&null!=t}},{key:"extend",value:function(t,e){var i=this;"function"!=typeof Object.assign&&(Object.assign=function(t){if(null==t)throw new TypeError("Cannot convert undefined or null to object");for(var e=Object(t),i=1;i<arguments.length;i++){var a=arguments[i];if(null!=a)for(var s in a)a.hasOwnProperty(s)&&(e[s]=a[s])}return e});var a=Object.assign({},t);return this.isObject(t)&&this.isObject(e)&&Object.keys(e).forEach((function(s){i.isObject(e[s])&&s in t?a[s]=i.extend(t[s],e[s]):Object.assign(a,function(t,e,i){return e in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}({},s,e[s]))})),a}},{key:"componentDidUpdate",value:function(t){if(!this.chart)return null;var e=this.props,i=e.options,a=e.series,s=e.height,r=e.width,n=JSON.stringify(t.options),o=JSON.stringify(t.series),l=JSON.stringify(i),c=JSON.stringify(a);n===l&&o===c&&s===t.height&&r===t.width||(o===c?this.chart.updateOptions(this.getConfig()):n===l&&s===t.height&&r===t.width?this.chart.updateSeries(a):this.chart.updateOptions(this.getConfig()))}},{key:"componentWillUnmount",value:function(){this.chart&&"function"==typeof this.chart.destroy&&this.chart.destroy()}}]),t}();(e.Z=d).propTypes={type:c.default.string.isRequired,width:c.default.any,height:c.default.any,series:c.default.array.isRequired,options:c.default.object.isRequired},d.defaultProps={type:"line",width:"100%",height:"auto"}},9921:function(t,e){"use strict";var i="function"==typeof Symbol&&Symbol.for,a=i?Symbol.for("react.element"):60103,s=i?Symbol.for("react.portal"):60106,r=i?Symbol.for("react.fragment"):60107,n=i?Symbol.for("react.strict_mode"):60108,o=i?Symbol.for("react.profiler"):60114,l=i?Symbol.for("react.provider"):60109,c=i?Symbol.for("react.context"):60110,h=i?Symbol.for("react.async_mode"):60111,d=i?Symbol.for("react.concurrent_mode"):60111,u=i?Symbol.for("react.forward_ref"):60112,p=i?Symbol.for("react.suspense"):60113,f=i?Symbol.for("react.suspense_list"):60120,g=i?Symbol.for("react.memo"):60115,x=i?Symbol.for("react.lazy"):60116,m=i?Symbol.for("react.block"):60121,b=i?Symbol.for("react.fundamental"):60117,v=i?Symbol.for("react.responder"):60118,y=i?Symbol.for("react.scope"):60119;function w(t){if("object"==typeof t&&null!==t){var e=t.$$typeof;switch(e){case a:switch(t=t.type){case h:case d:case r:case o:case n:case p:return t;default:switch(t=t&&t.$$typeof){case c:case u:case x:case g:case l:return t;default:return e}}case s:return e}}}function k(t){return w(t)===d}e.AsyncMode=h,e.ConcurrentMode=d,e.ContextConsumer=c,e.ContextProvider=l,e.Element=a,e.ForwardRef=u,e.Fragment=r,e.Lazy=x,e.Memo=g,e.Portal=s,e.Profiler=o,e.StrictMode=n,e.Suspense=p,e.isAsyncMode=function(t){return k(t)||w(t)===h},e.isConcurrentMode=k,e.isContextConsumer=function(t){return w(t)===c},e.isContextProvider=function(t){return w(t)===l},e.isElement=function(t){return"object"==typeof t&&null!==t&&t.$$typeof===a},e.isForwardRef=function(t){return w(t)===u},e.isFragment=function(t){return w(t)===r},e.isLazy=function(t){return w(t)===x},e.isMemo=function(t){return w(t)===g},e.isPortal=function(t){return w(t)===s},e.isProfiler=function(t){return w(t)===o},e.isStrictMode=function(t){return w(t)===n},e.isSuspense=function(t){return w(t)===p},e.isValidElementType=function(t){return"string"==typeof t||"function"==typeof t||t===r||t===d||t===o||t===n||t===p||t===f||"object"==typeof t&&null!==t&&(t.$$typeof===x||t.$$typeof===g||t.$$typeof===l||t.$$typeof===c||t.$$typeof===u||t.$$typeof===b||t.$$typeof===v||t.$$typeof===y||t.$$typeof===m)},e.typeOf=w},9864:function(t,e,i){"use strict";t.exports=i(9921)},9196:function(t){"use strict";t.exports=window.React}},e={};function i(a){var s=e[a];if(void 0!==s)return s.exports;var r=e[a]={exports:{}};return t[a](r,r.exports,i),r.exports}i.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return i.d(e,{a:e}),e},i.d=function(t,e){for(var a in e)i.o(e,a)&&!i.o(t,a)&&Object.defineProperty(t,a,{enumerable:!0,get:e[a]})},i.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},function(){"use strict";var t=window.wp.element;function e(t,e){(null==e||e>t.length)&&(e=t.length);for(var i=0,a=new Array(e);i<e;i++)a[i]=t[i];return a}function a(t,i){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var i=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=i){var a,s,_x,r,n=[],_n=!0,o=!1;try{if(_x=(i=i.call(t)).next,0===e){if(Object(i)!==i)return;_n=!1}else for(;!(_n=(a=_x.call(i)).done)&&(n.push(a.value),n.length!==e);_n=!0);}catch(t){o=!0,s=t}finally{try{if(!_n&&null!=i.return&&(r=i.return(),Object(r)!==r))return}finally{if(o)throw s}}return n}}(t,i)||function(t,i){if(t){if("string"==typeof t)return e(t,i);var a=Object.prototype.toString.call(t).slice(8,-1);return"Object"===a&&t.constructor&&(a=t.constructor.name),"Map"===a||"Set"===a?Array.from(t):"Arguments"===a||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(a)?e(t,i):void 0}}(t,i)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function s(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function r(t){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},r(t)}function n(t){var e=function(t,e){if("object"!==r(t)||null===t)return t;var i=t[Symbol.toPrimitive];if(void 0!==i){var a=i.call(t,e);if("object"!==r(a))return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t,"string");return"symbol"===r(e)?e:String(e)}function o(t,e){for(var i=0;i<e.length;i++){var a=e[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(t,n(a.key),a)}}function l(t,e,i){return e&&o(t.prototype,e),i&&o(t,i),Object.defineProperty(t,"prototype",{writable:!1}),t}function c(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function h(t,e){return h=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},h(t,e)}function d(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&h(t,e)}function u(t,e){if(e&&("object"===r(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return c(t)}function p(t){return p=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},p(t)}function f(t,e,i){return(e=n(e))in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}var g,x=i(7129);function m(t){return{path:t.pathname,hash:t.hash,query:x.parse(t.search)}}function b(){return b=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var i=arguments[e];for(var a in i)Object.prototype.hasOwnProperty.call(i,a)&&(t[a]=i[a])}return t},b.apply(this,arguments)}!function(t){t.Pop="POP",t.Push="PUSH",t.Replace="REPLACE"}(g||(g={}));var v="beforeunload";function y(t){t.preventDefault(),t.returnValue=""}function w(){var t=[];return{get length(){return t.length},push:function(e){return t.push(e),function(){t=t.filter((function(t){return t!==e}))}},call:function(e){t.forEach((function(t){return t&&t(e)}))}}}var k=function(t){void 0===t&&(t={});var e=t.window,i=void 0===e?document.defaultView:e,a=i.history;function s(){var t=i.location,e=t.pathname,s=t.search,r=t.hash,n=a.state||{};return[n.idx,{pathname:e,search:s,hash:r,state:n.usr||null,key:n.key||"default"}]}var r=null;i.addEventListener("popstate",(function(){if(r)d.call(r),r=null;else{var t=g.Pop,e=s(),i=e[0],a=e[1];if(d.length){if(null!=i){var n=l-i;n&&(r={action:t,location:a,retry:function(){k(-1*n)}},k(n))}}else m(t)}}));var n=g.Pop,o=s(),l=o[0],c=o[1],h=w(),d=w();function u(t){return"string"==typeof t?t:(i=(e=t).pathname,a=void 0===i?"/":i,s=e.search,r=void 0===s?"":s,n=e.hash,o=void 0===n?"":n,r&&"?"!==r&&(a+="?"===r.charAt(0)?r:"?"+r),o&&"#"!==o&&(a+="#"===o.charAt(0)?o:"#"+o),a);var e,i,a,s,r,n,o}function p(t,e){return void 0===e&&(e=null),b({pathname:c.pathname,hash:"",search:""},"string"==typeof t?function(t){var e={};if(t){var i=t.indexOf("#");i>=0&&(e.hash=t.substr(i),t=t.substr(0,i));var a=t.indexOf("?");a>=0&&(e.search=t.substr(a),t=t.substr(0,a)),t&&(e.pathname=t)}return e}(t):t,{state:e,key:Math.random().toString(36).substr(2,8)})}function f(t,e){return[{usr:t.state,key:t.key,idx:e},u(t)]}function x(t,e,i){return!d.length||(d.call({action:t,location:e,retry:i}),!1)}function m(t){n=t;var e=s();l=e[0],c=e[1],h.call({action:n,location:c})}function k(t){a.go(t)}return null==l&&(l=0,a.replaceState(b({},a.state,{idx:l}),"")),{get action(){return n},get location(){return c},createHref:u,push:function t(e,s){var r=g.Push,n=p(e,s);if(x(r,n,(function(){t(e,s)}))){var o=f(n,l+1),c=o[0],h=o[1];try{a.pushState(c,"",h)}catch(t){i.location.assign(h)}m(r)}},replace:function t(e,i){var s=g.Replace,r=p(e,i);if(x(s,r,(function(){t(e,i)}))){var n=f(r,l),o=n[0],c=n[1];a.replaceState(o,"",c),m(s)}},go:k,back:function(){k(-1)},forward:function(){k(1)},listen:function(t){return h.push(t)},block:function(t){var e=d.push(t);return 1===d.length&&i.addEventListener(v,y),function(){e(),d.length||i.removeEventListener(v,y)}}}}(),A=wp.element.createContext({route:m(k.location)});function S(t,e){var i=[];return function(t,e,i){void 0===i&&(i={});var a=i.decode,s=void 0===a?function(t){return t}:a;return function(i){var a=t.exec(i);if(!a)return!1;for(var r=a[0],n=a.index,o=Object.create(null),l=function(t){if(void 0===a[t])return"continue";var i=e[t-1];"*"===i.modifier||"+"===i.modifier?o[i.name]=a[t].split(i.prefix+i.suffix).map((function(t){return s(t,i)})):o[i.name]=s(a[t],i)},c=1;c<a.length;c++)l(c);return{path:r,index:n,params:o}}}(D(t,i,e),i,e)}function C(t){return t.replace(/([.+*?=^!:${}()[\]|/\\])/g,"\\$1")}function P(t){return t&&t.sensitive?"":"i"}function L(t,e,i){return function(t,e,i){void 0===i&&(i={});for(var a=i.strict,s=void 0!==a&&a,r=i.start,n=void 0===r||r,o=i.end,l=void 0===o||o,c=i.encode,h=void 0===c?function(t){return t}:c,d=i.delimiter,u=void 0===d?"/#?":d,p=i.endsWith,f="[".concat(C(void 0===p?"":p),"]|$"),g="[".concat(C(u),"]"),x=n?"^":"",m=0,b=t;m<b.length;m++){var v=b[m];if("string"==typeof v)x+=C(h(v));else{var y=C(h(v.prefix)),w=C(h(v.suffix));if(v.pattern)if(e&&e.push(v),y||w)if("+"===v.modifier||"*"===v.modifier){var k="*"===v.modifier?"?":"";x+="(?:".concat(y,"((?:").concat(v.pattern,")(?:").concat(w).concat(y,"(?:").concat(v.pattern,"))*)").concat(w,")").concat(k)}else x+="(?:".concat(y,"(").concat(v.pattern,")").concat(w,")").concat(v.modifier);else"+"===v.modifier||"*"===v.modifier?x+="((?:".concat(v.pattern,")").concat(v.modifier,")"):x+="(".concat(v.pattern,")").concat(v.modifier);else x+="(?:".concat(y).concat(w,")").concat(v.modifier)}}if(l)s||(x+="".concat(g,"?")),x+=i.endsWith?"(?=".concat(f,")"):"$";else{var A=t[t.length-1],S="string"==typeof A?g.indexOf(A[A.length-1])>-1:void 0===A;s||(x+="(?:".concat(g,"(?=").concat(f,"))?")),S||(x+="(?=".concat(g,"|").concat(f,")"))}return new RegExp(x,P(i))}(function(t,e){void 0===e&&(e={});for(var i=function(t){for(var e=[],i=0;i<t.length;){var a=t[i];if("*"!==a&&"+"!==a&&"?"!==a)if("\\"!==a)if("{"!==a)if("}"!==a)if(":"!==a)if("("!==a)e.push({type:"CHAR",index:i,value:t[i++]});else{var s=1,r="";if("?"===t[o=i+1])throw new TypeError('Pattern cannot start with "?" at '.concat(o));for(;o<t.length;)if("\\"!==t[o]){if(")"===t[o]){if(0==--s){o++;break}}else if("("===t[o]&&(s++,"?"!==t[o+1]))throw new TypeError("Capturing groups are not allowed at ".concat(o));r+=t[o++]}else r+=t[o++]+t[o++];if(s)throw new TypeError("Unbalanced pattern at ".concat(i));if(!r)throw new TypeError("Missing pattern at ".concat(i));e.push({type:"PATTERN",index:i,value:r}),i=o}else{for(var n="",o=i+1;o<t.length;){var l=t.charCodeAt(o);if(!(l>=48&&l<=57||l>=65&&l<=90||l>=97&&l<=122||95===l))break;n+=t[o++]}if(!n)throw new TypeError("Missing parameter name at ".concat(i));e.push({type:"NAME",index:i,value:n}),i=o}else e.push({type:"CLOSE",index:i,value:t[i++]});else e.push({type:"OPEN",index:i,value:t[i++]});else e.push({type:"ESCAPED_CHAR",index:i++,value:t[i++]});else e.push({type:"MODIFIER",index:i,value:t[i++]})}return e.push({type:"END",index:i,value:""}),e}(t),a=e.prefixes,s=void 0===a?"./":a,r="[^".concat(C(e.delimiter||"/#?"),"]+?"),n=[],o=0,l=0,c="",h=function(t){if(l<i.length&&i[l].type===t)return i[l++].value},d=function(t){var e=h(t);if(void 0!==e)return e;var a=i[l],s=a.type,r=a.index;throw new TypeError("Unexpected ".concat(s," at ").concat(r,", expected ").concat(t))},u=function(){for(var t,e="";t=h("CHAR")||h("ESCAPED_CHAR");)e+=t;return e};l<i.length;){var p=h("CHAR"),f=h("NAME"),g=h("PATTERN");if(f||g){var x=p||"";-1===s.indexOf(x)&&(c+=x,x=""),c&&(n.push(c),c=""),n.push({name:f||o++,prefix:x,suffix:"",pattern:g||r,modifier:h("MODIFIER")||""})}else{var m=p||h("ESCAPED_CHAR");if(m)c+=m;else if(c&&(n.push(c),c=""),h("OPEN")){x=u();var b=h("NAME")||"",v=h("PATTERN")||"",y=u();d("CLOSE"),n.push({name:b||(v?o++:""),pattern:b&&!v?r:v,prefix:x,suffix:y,modifier:h("MODIFIER")||""})}else d("END")}}return n}(t,i),e,i)}function D(t,e,i){return t instanceof RegExp?function(t,e){if(!e)return t;for(var i=/\((?:\?<(.*?)>)?(?!\?)/g,a=0,s=i.exec(t.source);s;)e.push({name:s[1]||a++,prefix:"",suffix:"",modifier:"",pattern:""}),s=i.exec(t.source);return t}(t,e):Array.isArray(t)?function(t,e,i){var a=t.map((function(t){return D(t,e,i).source}));return new RegExp("(?:".concat(a.join("|"),")"),P(i))}(t,e,i):L(t,e,i)}var T=i(9196),M=i.n(T),E=function(){function t(t){var e=this;this._insertTag=function(t){var i;i=0===e.tags.length?e.insertionPoint?e.insertionPoint.nextSibling:e.prepend?e.container.firstChild:e.before:e.tags[e.tags.length-1].nextSibling,e.container.insertBefore(t,i),e.tags.push(t)},this.isSpeedy=void 0===t.speedy||t.speedy,this.tags=[],this.ctr=0,this.nonce=t.nonce,this.key=t.key,this.container=t.container,this.prepend=t.prepend,this.insertionPoint=t.insertionPoint,this.before=null}var e=t.prototype;return e.hydrate=function(t){t.forEach(this._insertTag)},e.insert=function(t){this.ctr%(this.isSpeedy?65e3:1)==0&&this._insertTag(function(t){var e=document.createElement("style");return e.setAttribute("data-emotion",t.key),void 0!==t.nonce&&e.setAttribute("nonce",t.nonce),e.appendChild(document.createTextNode("")),e.setAttribute("data-s",""),e}(this));var e=this.tags[this.tags.length-1];if(this.isSpeedy){var i=function(t){if(t.sheet)return t.sheet;for(var e=0;e<document.styleSheets.length;e++)if(document.styleSheets[e].ownerNode===t)return document.styleSheets[e]}(e);try{i.insertRule(t,i.cssRules.length)}catch(t){}}else e.appendChild(document.createTextNode(t));this.ctr++},e.flush=function(){this.tags.forEach((function(t){return t.parentNode&&t.parentNode.removeChild(t)})),this.tags=[],this.ctr=0},t}(),I=Math.abs,O=String.fromCharCode,z=Object.assign;function R(t){return t.trim()}function Y(t,e,i){return t.replace(e,i)}function F(t,e){return t.indexOf(e)}function N(t,e){return 0|t.charCodeAt(e)}function X(t,e,i){return t.slice(e,i)}function _(t){return t.length}function H(t){return t.length}function B(t,e){return e.push(t),t}var W=1,j=1,V=0,G=0,U=0,q="";function Z(t,e,i,a,s,r,n){return{value:t,root:e,parent:i,type:a,props:s,children:r,line:W,column:j,length:n,return:""}}function $(t,e){return z(Z("",null,null,"",null,null,0),t,{length:-t.length},e)}function J(){return U=G>0?N(q,--G):0,j--,10===U&&(j=1,W--),U}function Q(){return U=G<V?N(q,G++):0,j++,10===U&&(j=1,W++),U}function K(){return N(q,G)}function tt(){return G}function et(t,e){return X(q,t,e)}function it(t){switch(t){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function at(t){return W=j=1,V=_(q=t),G=0,[]}function st(t){return q="",t}function rt(t){return R(et(G-1,lt(91===t?t+2:40===t?t+1:t)))}function nt(t){for(;(U=K())&&U<33;)Q();return it(t)>2||it(U)>3?"":" "}function ot(t,e){for(;--e&&Q()&&!(U<48||U>102||U>57&&U<65||U>70&&U<97););return et(t,tt()+(e<6&&32==K()&&32==Q()))}function lt(t){for(;Q();)switch(U){case t:return G;case 34:case 39:34!==t&&39!==t&&lt(U);break;case 40:41===t&&lt(t);break;case 92:Q()}return G}function ct(t,e){for(;Q()&&t+U!==57&&(t+U!==84||47!==K()););return"/*"+et(e,G-1)+"*"+O(47===t?t:Q())}function ht(t){for(;!it(K());)Q();return et(t,G)}var dt="-ms-",ut="-webkit-",pt="comm",ft="rule",gt="decl",xt="@keyframes";function mt(t,e){for(var i="",a=H(t),s=0;s<a;s++)i+=e(t[s],s,t,e)||"";return i}function bt(t,e,i,a){switch(t.type){case"@import":case gt:return t.return=t.return||t.value;case pt:return"";case xt:return t.return=t.value+"{"+mt(t.children,a)+"}";case ft:t.value=t.props.join(",")}return _(i=mt(t.children,a))?t.return=t.value+"{"+i+"}":""}function vt(t){return st(yt("",null,null,null,[""],t=at(t),0,[0],t))}function yt(t,e,i,a,s,r,n,o,l){for(var c=0,h=0,d=n,u=0,p=0,f=0,g=1,x=1,m=1,b=0,v="",y=s,w=r,k=a,A=v;x;)switch(f=b,b=Q()){case 40:if(108!=f&&58==N(A,d-1)){-1!=F(A+=Y(rt(b),"&","&\f"),"&\f")&&(m=-1);break}case 34:case 39:case 91:A+=rt(b);break;case 9:case 10:case 13:case 32:A+=nt(f);break;case 92:A+=ot(tt()-1,7);continue;case 47:switch(K()){case 42:case 47:B(kt(ct(Q(),tt()),e,i),l);break;default:A+="/"}break;case 123*g:o[c++]=_(A)*m;case 125*g:case 59:case 0:switch(b){case 0:case 125:x=0;case 59+h:p>0&&_(A)-d&&B(p>32?At(A+";",a,i,d-1):At(Y(A," ","")+";",a,i,d-2),l);break;case 59:A+=";";default:if(B(k=wt(A,e,i,c,h,s,o,v,y=[],w=[],d),r),123===b)if(0===h)yt(A,e,k,k,y,r,d,o,w);else switch(99===u&&110===N(A,3)?100:u){case 100:case 109:case 115:yt(t,k,k,a&&B(wt(t,k,k,0,0,s,o,v,s,y=[],d),w),s,w,d,o,a?y:w);break;default:yt(A,k,k,k,[""],w,0,o,w)}}c=h=p=0,g=m=1,v=A="",d=n;break;case 58:d=1+_(A),p=f;default:if(g<1)if(123==b)--g;else if(125==b&&0==g++&&125==J())continue;switch(A+=O(b),b*g){case 38:m=h>0?1:(A+="\f",-1);break;case 44:o[c++]=(_(A)-1)*m,m=1;break;case 64:45===K()&&(A+=rt(Q())),u=K(),h=d=_(v=A+=ht(tt())),b++;break;case 45:45===f&&2==_(A)&&(g=0)}}return r}function wt(t,e,i,a,s,r,n,o,l,c,h){for(var d=s-1,u=0===s?r:[""],p=H(u),f=0,g=0,x=0;f<a;++f)for(var m=0,b=X(t,d+1,d=I(g=n[f])),v=t;m<p;++m)(v=R(g>0?u[m]+" "+b:Y(b,/&\f/g,u[m])))&&(l[x++]=v);return Z(t,e,i,0===s?ft:o,l,c,h)}function kt(t,e,i){return Z(t,e,i,pt,O(U),X(t,2,-2),0)}function At(t,e,i,a){return Z(t,e,i,gt,X(t,0,a),X(t,a+1,-1),a)}var St=function(t,e,i){for(var a=0,s=0;a=s,s=K(),38===a&&12===s&&(e[i]=1),!it(s);)Q();return et(t,G)},Ct=new WeakMap,Pt=function(t){if("rule"===t.type&&t.parent&&!(t.length<1)){for(var e=t.value,i=t.parent,a=t.column===i.column&&t.line===i.line;"rule"!==i.type;)if(!(i=i.parent))return;if((1!==t.props.length||58===e.charCodeAt(0)||Ct.get(i))&&!a){Ct.set(t,!0);for(var s=[],r=function(t,e){return st(function(t,e){var i=-1,a=44;do{switch(it(a)){case 0:38===a&&12===K()&&(e[i]=1),t[i]+=St(G-1,e,i);break;case 2:t[i]+=rt(a);break;case 4:if(44===a){t[++i]=58===K()?"&\f":"",e[i]=t[i].length;break}default:t[i]+=O(a)}}while(a=Q());return t}(at(t),e))}(e,s),n=i.props,o=0,l=0;o<r.length;o++)for(var c=0;c<n.length;c++,l++)t.props[l]=s[o]?r[o].replace(/&\f/g,n[c]):n[c]+" "+r[o]}}},Lt=function(t){if("decl"===t.type){var e=t.value;108===e.charCodeAt(0)&&98===e.charCodeAt(2)&&(t.return="",t.value="")}};function Dt(t,e){switch(function(t,e){return 45^N(t,0)?(((e<<2^N(t,0))<<2^N(t,1))<<2^N(t,2))<<2^N(t,3):0}(t,e)){case 5103:return"-webkit-print-"+t+t;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return ut+t+t;case 5349:case 4246:case 4810:case 6968:case 2756:return ut+t+"-moz-"+t+dt+t+t;case 6828:case 4268:return ut+t+dt+t+t;case 6165:return ut+t+dt+"flex-"+t+t;case 5187:return ut+t+Y(t,/(\w+).+(:[^]+)/,"-webkit-box-$1$2-ms-flex-$1$2")+t;case 5443:return ut+t+dt+"flex-item-"+Y(t,/flex-|-self/,"")+t;case 4675:return ut+t+dt+"flex-line-pack"+Y(t,/align-content|flex-|-self/,"")+t;case 5548:return ut+t+dt+Y(t,"shrink","negative")+t;case 5292:return ut+t+dt+Y(t,"basis","preferred-size")+t;case 6060:return"-webkit-box-"+Y(t,"-grow","")+ut+t+dt+Y(t,"grow","positive")+t;case 4554:return ut+Y(t,/([^-])(transform)/g,"$1-webkit-$2")+t;case 6187:return Y(Y(Y(t,/(zoom-|grab)/,"-webkit-$1"),/(image-set)/,"-webkit-$1"),t,"")+t;case 5495:case 3959:return Y(t,/(image-set\([^]*)/,"-webkit-$1$`$1");case 4968:return Y(Y(t,/(.+:)(flex-)?(.*)/,"-webkit-box-pack:$3-ms-flex-pack:$3"),/s.+-b[^;]+/,"justify")+ut+t+t;case 4095:case 3583:case 4068:case 2532:return Y(t,/(.+)-inline(.+)/,"-webkit-$1$2")+t;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(_(t)-1-e>6)switch(N(t,e+1)){case 109:if(45!==N(t,e+4))break;case 102:return Y(t,/(.+:)(.+)-([^]+)/,"$1-webkit-$2-$3$1-moz-"+(108==N(t,e+3)?"$3":"$2-$3"))+t;case 115:return~F(t,"stretch")?Dt(Y(t,"stretch","fill-available"),e)+t:t}break;case 4949:if(115!==N(t,e+1))break;case 6444:switch(N(t,_(t)-3-(~F(t,"!important")&&10))){case 107:return Y(t,":",":-webkit-")+t;case 101:return Y(t,/(.+:)([^;!]+)(;|!.+)?/,"$1-webkit-"+(45===N(t,14)?"inline-":"")+"box$3$1-webkit-$2$3$1-ms-$2box$3")+t}break;case 5936:switch(N(t,e+11)){case 114:return ut+t+dt+Y(t,/[svh]\w+-[tblr]{2}/,"tb")+t;case 108:return ut+t+dt+Y(t,/[svh]\w+-[tblr]{2}/,"tb-rl")+t;case 45:return ut+t+dt+Y(t,/[svh]\w+-[tblr]{2}/,"lr")+t}return ut+t+dt+t+t}return t}var Tt=[function(t,e,i,a){if(t.length>-1&&!t.return)switch(t.type){case gt:t.return=Dt(t.value,t.length);break;case xt:return mt([$(t,{value:Y(t.value,"@","@-webkit-")})],a);case ft:if(t.length)return function(t,e){return t.map(e).join("")}(t.props,(function(e){switch(function(t,e){return(t=/(::plac\w+|:read-\w+)/.exec(t))?t[0]:t}(e)){case":read-only":case":read-write":return mt([$(t,{props:[Y(e,/:(read-\w+)/,":-moz-$1")]})],a);case"::placeholder":return mt([$(t,{props:[Y(e,/:(plac\w+)/,":-webkit-input-$1")]}),$(t,{props:[Y(e,/:(plac\w+)/,":-moz-$1")]}),$(t,{props:[Y(e,/:(plac\w+)/,"-ms-input-$1")]})],a)}return""}))}}],Mt=function(t){var e=t.key;if("css"===e){var i=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(i,(function(t){-1!==t.getAttribute("data-emotion").indexOf(" ")&&(document.head.appendChild(t),t.setAttribute("data-s",""))}))}var a,s,r=t.stylisPlugins||Tt,n={},o=[];a=t.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+e+' "]'),(function(t){for(var e=t.getAttribute("data-emotion").split(" "),i=1;i<e.length;i++)n[e[i]]=!0;o.push(t)}));var l,c,h,d,u=[bt,(d=function(t){l.insert(t)},function(t){t.root||(t=t.return)&&d(t)})],p=(c=[Pt,Lt].concat(r,u),h=H(c),function(t,e,i,a){for(var s="",r=0;r<h;r++)s+=c[r](t,e,i,a)||"";return s});s=function(t,e,i,a){l=i,mt(vt(t?t+"{"+e.styles+"}":e.styles),p),a&&(f.inserted[e.name]=!0)};var f={key:e,sheet:new E({key:e,container:a,nonce:t.nonce,speedy:t.speedy,prepend:t.prepend,insertionPoint:t.insertionPoint}),nonce:t.nonce,inserted:n,registered:{},insert:s};return f.sheet.hydrate(o),f},Et=function(t,e,i){var a=t.key+"-"+e.name;!1===i&&void 0===t.registered[a]&&(t.registered[a]=e.styles)},It=function(t){for(var e,i=0,a=0,s=t.length;s>=4;++a,s-=4)e=1540483477*(65535&(e=255&t.charCodeAt(a)|(255&t.charCodeAt(++a))<<8|(255&t.charCodeAt(++a))<<16|(255&t.charCodeAt(++a))<<24))+(59797*(e>>>16)<<16),i=1540483477*(65535&(e^=e>>>24))+(59797*(e>>>16)<<16)^1540483477*(65535&i)+(59797*(i>>>16)<<16);switch(s){case 3:i^=(255&t.charCodeAt(a+2))<<16;case 2:i^=(255&t.charCodeAt(a+1))<<8;case 1:i=1540483477*(65535&(i^=255&t.charCodeAt(a)))+(59797*(i>>>16)<<16)}return(((i=1540483477*(65535&(i^=i>>>13))+(59797*(i>>>16)<<16))^i>>>15)>>>0).toString(36)},Ot={animationIterationCount:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},zt=/[A-Z]|^ms/g,Rt=/_EMO_([^_]+?)_([^]*?)_EMO_/g,Yt=function(t){return 45===t.charCodeAt(1)},Ft=function(t){return null!=t&&"boolean"!=typeof t},Nt=function(t){var e=Object.create(null);return function(t){return void 0===e[t]&&(e[t]=Yt(i=t)?i:i.replace(zt,"-$&").toLowerCase()),e[t];var i}}(),Xt=function(t,e){switch(t){case"animation":case"animationName":if("string"==typeof e)return e.replace(Rt,(function(t,e,i){return Ht={name:e,styles:i,next:Ht},e}))}return 1===Ot[t]||Yt(t)||"number"!=typeof e||0===e?e:e+"px"};function _t(t,e,i){if(null==i)return"";if(void 0!==i.__emotion_styles)return i;switch(typeof i){case"boolean":return"";case"object":if(1===i.anim)return Ht={name:i.name,styles:i.styles,next:Ht},i.name;if(void 0!==i.styles){var a=i.next;if(void 0!==a)for(;void 0!==a;)Ht={name:a.name,styles:a.styles,next:Ht},a=a.next;return i.styles+";"}return function(t,e,i){var a="";if(Array.isArray(i))for(var s=0;s<i.length;s++)a+=_t(t,e,i[s])+";";else for(var r in i){var n=i[r];if("object"!=typeof n)null!=e&&void 0!==e[n]?a+=r+"{"+e[n]+"}":Ft(n)&&(a+=Nt(r)+":"+Xt(r,n)+";");else if(!Array.isArray(n)||"string"!=typeof n[0]||null!=e&&void 0!==e[n[0]]){var o=_t(t,e,n);switch(r){case"animation":case"animationName":a+=Nt(r)+":"+o+";";break;default:a+=r+"{"+o+"}"}}else for(var l=0;l<n.length;l++)Ft(n[l])&&(a+=Nt(r)+":"+Xt(r,n[l])+";")}return a}(t,e,i);case"function":if(void 0!==t){var s=Ht,r=i(t);return Ht=s,_t(t,e,r)}}if(null==e)return i;var n=e[i];return void 0!==n?n:i}var Ht,Bt=/label:\s*([^\s;\n{]+)\s*(;|$)/g,Wt=!!T.useInsertionEffect&&T.useInsertionEffect,jt=Wt||function(t){return t()},Vt=(Wt||T.useLayoutEffect,{}.hasOwnProperty),Gt=(0,T.createContext)("undefined"!=typeof HTMLElement?Mt({key:"css"}):null);Gt.Provider;var Ut=function(t){return(0,T.forwardRef)((function(e,i){var a=(0,T.useContext)(Gt);return t(e,a,i)}))},qt=(0,T.createContext)({}),Zt="__EMOTION_TYPE_PLEASE_DO_NOT_USE__",$t=function(t,e){var i={};for(var a in e)Vt.call(e,a)&&(i[a]=e[a]);return i[Zt]=t,i},Jt=function(t){var e=t.cache,i=t.serialized,a=t.isStringTag;return Et(e,i,a),jt((function(){return function(t,e,i){Et(t,e,i);var a=t.key+"-"+e.name;if(void 0===t.inserted[e.name]){var s=e;do{t.insert(e===s?"."+a:"",s,t.sheet,!0),s=s.next}while(void 0!==s)}}(e,i,a)})),null},Qt=Ut((function(t,e,i){var a=t.css;"string"==typeof a&&void 0!==e.registered[a]&&(a=e.registered[a]);var s=t[Zt],r=[a],n="";"string"==typeof t.className?n=function(t,e,i){var a="";return i.split(" ").forEach((function(i){void 0!==t[i]?e.push(t[i]+";"):a+=i+" "})),a}(e.registered,r,t.className):null!=t.className&&(n=t.className+" ");var o=function(t,e,i){if(1===t.length&&"object"==typeof t[0]&&null!==t[0]&&void 0!==t[0].styles)return t[0];var a=!0,s="";Ht=void 0;var r=t[0];null==r||void 0===r.raw?(a=!1,s+=_t(i,e,r)):s+=r[0];for(var n=1;n<t.length;n++)s+=_t(i,e,t[n]),a&&(s+=r[n]);Bt.lastIndex=0;for(var o,l="";null!==(o=Bt.exec(s));)l+="-"+o[1];return{name:It(s)+l,styles:s,next:Ht}}(r,void 0,(0,T.useContext)(qt));n+=e.key+"-"+o.name;var l={};for(var c in t)Vt.call(t,c)&&"css"!==c&&c!==Zt&&(l[c]=t[c]);return l.ref=i,l.className=n,(0,T.createElement)(T.Fragment,null,(0,T.createElement)(Jt,{cache:e,serialized:o,isStringTag:"string"==typeof s}),(0,T.createElement)(s,l))}));i(8679);var Kt=function(t,e){var i=arguments;if(null==e||!Vt.call(e,"css"))return T.createElement.apply(void 0,i);var a=i.length,s=new Array(a);s[0]=Qt,s[1]=$t(t,e);for(var r=2;r<a;r++)s[r]=i[r];return T.createElement.apply(null,s)},te=wp.element.useContext,ee="";function ie(t){var e=t.path,i=t.onRoute,a=t.children,s=te(A).route,r=S("".concat(e))("".concat(s.hash.substr(1)));return r?(i&&(ee!==r.path&&i(),ee=r.path),Kt("div",null,wp.element.cloneElement(a,{route:r}))):null}var ae=i(4184),se=i.n(ae);wp.element.useContext;var re=function(t){d(r,t);var e,i,a=(e=r,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}(),function(){var t,a=p(e);if(i){var s=p(this).constructor;t=Reflect.construct(a,arguments,s)}else t=a.apply(this,arguments);return u(this,t)});function r(t){var e;s(this,r),f(c(e=a.call(this,t)),"handleRouteChange",(function(t){var i=m(null==t?void 0:t.location);e.setState({route:i})})),e.routes=Object.keys(t.routes).map((function(e){return t.routes[e].path})),e.unlisten=k.listen(e.handleRouteChange);var i=m(k.location),n=k.location.search;return e.state={route:i,defaultRoute:null!=t&&t.defaultRoute?"".concat(n,"#").concat(null==t?void 0:t.defaultRoute):"".concat(n,"#/")},e}return l(r,[{key:"componentWillUnmount",value:function(){this.unlisten()}},{key:"render",value:function(){var t=this.props,e=t.children,i=(t.NotFound,this.state),a=i.route,s=i.defaultRoute;if(!a.hash)return k.push(s),Kt("div",null);var r=!1;(this.routes||[]).forEach((function(t){var e=S(a.hash.substr(1))("".concat(a.hash.substr(1)));e&&(r={name:t,data:e})}));var n={route:a,matched:r},o=!r;return Kt(A.Provider,{value:n},o?Kt("div",null,"Not found"):e)}}]),r}(t.Component),ne=function(t){var e=t.width,i=t.height;return Kt("svg",{id:"e8f68bdd-4984-4f2e-95b7-7fc8ec281257","data-name":"Layer 1",width:e,height:i,xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink",viewBox:"0 0 918.14 765.54"},Kt("defs",null,Kt("linearGradient",{id:"27aa7b70-b106-4a00-be67-693c8380e41d",x1:"397.74",y1:"717.25",x2:"397.74",y2:"86.11",gradientUnits:"userSpaceOnUse"},Kt("stop",{offset:"0","stop-color":"gray","stop-opacity":"0.25"}),Kt("stop",{offset:"0.54","stop-color":"gray","stop-opacity":"0.12"}),Kt("stop",{offset:"1","stop-color":"gray","stop-opacity":"0.1"})),Kt("linearGradient",{id:"46a816da-c484-41ec-8a6f-fbf14454d910",x1:"288.88",y1:"378.44",x2:"288.88",y2:"209.65",xlinkHref:"#27aa7b70-b106-4a00-be67-693c8380e41d"}),Kt("linearGradient",{id:"32b634d8-28f1-48d9-a868-f602a2cad942",x1:"288.88",y1:"328.29",x2:"288.88",y2:"223.1",xlinkHref:"#27aa7b70-b106-4a00-be67-693c8380e41d"}),Kt("clipPath",{id:"7a4c6aff-0be0-461b-a111-b3ae1b8fbf73",transform:"translate(-140.93 -67.23)"},Kt("rect",{id:"8cc91f6d-19b0-43cc-9c18-2faa83ac34ba","data-name":"<Rectangle>",x:"354.51",y:"291.55",width:"150.6",height:"101.52",fill:"#fff"})),Kt("linearGradient",{id:"38f1cb81-8fac-4205-a0ff-a33ac00d354c",x1:"288.88",y1:"594.94",x2:"288.88",y2:"426.14",xlinkHref:"#27aa7b70-b106-4a00-be67-693c8380e41d"}),Kt("linearGradient",{id:"6fc01aaf-135e-403e-a209-43b2a4fe59f1",x1:"288.88",y1:"544.79",x2:"288.88",y2:"439.6",xlinkHref:"#27aa7b70-b106-4a00-be67-693c8380e41d"}),Kt("clipPath",{id:"79ce363a-d134-40e4-9f82-b96d04a36978",transform:"translate(-140.93 -67.23)"},Kt("rect",{id:"5b44e697-61fe-43bd-9a58-5f3e41301748","data-name":"<Rectangle>",x:"354.51",y:"508.05",width:"150.6",height:"101.52",fill:"#fff"})),Kt("linearGradient",{id:"54803c44-522d-4b9e-9a34-f1f7b43e8483",x1:"671.57",y1:"760.34",x2:"671.57",y2:"129.2",gradientTransform:"translate(1109.43 -194.1) rotate(90)",xlinkHref:"#27aa7b70-b106-4a00-be67-693c8380e41d"}),Kt("linearGradient",{id:"089a6a47-adaa-499b-aefb-cd6464b62fb8",x1:"670.96",y1:"553.63",x2:"670.96",y2:"387.28",gradientTransform:"translate(1129.51 -168.41) rotate(90)",xlinkHref:"#27aa7b70-b106-4a00-be67-693c8380e41d"}),Kt("linearGradient",{id:"fd8d88e0-7826-450d-9e0b-001d1be709c2",x1:"637.66",y1:"754.12",x2:"637.66",y2:"601.05",xlinkHref:"#27aa7b70-b106-4a00-be67-693c8380e41d"}),Kt("linearGradient",{id:"8d1793c5-b76e-44e2-a52e-569460402331",x1:"778.37",y1:"673.86",x2:"778.37",y2:"569.13",xlinkHref:"#27aa7b70-b106-4a00-be67-693c8380e41d"}),Kt("linearGradient",{id:"4745700d-8097-45ff-9f71-625443fc4ad8",x1:"778.37",y1:"774.41",x2:"778.37",y2:"713.66",xlinkHref:"#27aa7b70-b106-4a00-be67-693c8380e41d"})),Kt("title",null,"secure data"),Kt("g",{opacity:"0.5"},Kt("rect",{x:"162.9",y:"86.11",width:"469.69",height:"631.14",fill:"url(#27aa7b70-b106-4a00-be67-693c8380e41d)"})),Kt("rect",{x:"169.02",y:"94.67",width:"455.01",height:"609.12",fill:"#f2f2f2"}),Kt("rect",{x:"204.49",y:"120.36",width:"156.56",height:"4.89",fill:"#e0e0e0"}),Kt("rect",{x:"204.49",y:"142.37",width:"156.56",height:"4.89",fill:"#6c63ff",opacity:"0.7"}),Kt("rect",{x:"384.29",y:"120.36",width:"156.56",height:"4.89",fill:"#e0e0e0"}),Kt("rect",{x:"408.75",y:"259.8",width:"156.56",height:"4.89",fill:"#e0e0e0"}),Kt("rect",{x:"412.42",y:"273.25",width:"156.56",height:"4.89",fill:"#e0e0e0"}),Kt("rect",{x:"419.76",y:"286.7",width:"156.56",height:"4.89",fill:"#e0e0e0"}),Kt("rect",{x:"408.75",y:"476.29",width:"156.56",height:"4.89",fill:"#e0e0e0"}),Kt("rect",{x:"412.42",y:"489.75",width:"156.56",height:"4.89",fill:"#e0e0e0"}),Kt("rect",{x:"419.76",y:"503.2",width:"156.56",height:"4.89",fill:"#e0e0e0"}),Kt("g",{opacity:"0.5"},Kt("rect",{x:"205.71",y:"209.65",width:"166.35",height:"168.79",fill:"url(#46a816da-c484-41ec-8a6f-fbf14454d910)"})),Kt("rect",{x:"206.76",y:"213.32",width:"163.72",height:"161.45",fill:"#f5f5f5"}),Kt("g",{opacity:"0.5"},Kt("rect",{x:"212.53",y:"223.1",width:"152.7",height:"105.19",fill:"url(#32b634d8-28f1-48d9-a868-f602a2cad942)"})),Kt("rect",{id:"689f37f3-cc41-448d-b172-63ec123bc985","data-name":"<Rectangle>",x:"213.58",y:"224.32",width:"150.6",height:"101.52",fill:"#fff"}),Kt("g",{"clip-path":"url(#7a4c6aff-0be0-461b-a111-b3ae1b8fbf73)"},Kt("polygon",{points:"200.82 322.18 238.74 263.46 254.64 289.15 288.88 253.68 318.24 289.15 343.93 236.56 409.98 341.75 195.93 334.41 200.82 322.18",fill:"#6c63ff",opacity:"0.4"}),Kt("circle",{cx:"230.17",cy:"239",r:"11.01",fill:"#6c63ff",opacity:"0.4"})),Kt("g",{opacity:"0.5"},Kt("rect",{x:"205.71",y:"426.14",width:"166.35",height:"168.79",fill:"url(#38f1cb81-8fac-4205-a0ff-a33ac00d354c)"})),Kt("rect",{x:"206.76",y:"429.81",width:"163.72",height:"161.45",fill:"#f5f5f5"}),Kt("g",{opacity:"0.5"},Kt("rect",{x:"212.53",y:"439.6",width:"152.7",height:"105.19",fill:"url(#6fc01aaf-135e-403e-a209-43b2a4fe59f1)"})),Kt("rect",{id:"b429ac3a-f8a8-4171-bcce-5b6c002c0714","data-name":"<Rectangle>",x:"213.58",y:"440.82",width:"150.6",height:"101.52",fill:"#fff"}),Kt("g",{"clip-path":"url(#79ce363a-d134-40e4-9f82-b96d04a36978)"},Kt("polygon",{points:"200.82 538.67 238.74 479.96 254.64 505.65 288.88 470.18 318.24 505.65 343.93 453.05 409.98 558.24 195.93 550.9 200.82 538.67",fill:"#bdbdbd",opacity:"0.4"}),Kt("circle",{cx:"230.17",cy:"455.5",r:"11.01",fill:"#bdbdbd",opacity:"0.4"})),Kt("g",{opacity:"0.5"},Kt("rect",{x:"349.09",y:"242.63",width:"631.14",height:"469.69",transform:"translate(-74.16 969.06) rotate(-78.76)",fill:"url(#54803c44-522d-4b9e-9a34-f1f7b43e8483)"})),Kt("rect",{x:"359.37",y:"247.33",width:"609.12",height:"455.01",transform:"translate(-72.16 966.22) rotate(-78.76)",fill:"#fff"}),Kt("rect",{x:"523.5",y:"197.22",width:"322.91",height:"4.89",transform:"translate(-88.86 -196.94) rotate(11.24)",fill:"#e0e0e0"}),Kt("rect",{x:"433.36",y:"650.7",width:"322.91",height:"4.89",transform:"translate(-2.18 -170.66) rotate(11.24)",fill:"#e0e0e0"}),Kt("rect",{x:"428.58",y:"671.14",width:"249.52",height:"4.89",transform:"translate(1.01 -162.18) rotate(11.24)",fill:"#e0e0e0"}),Kt("rect",{x:"424.6",y:"683.47",width:"92.96",height:"4.89",transform:"translate(1.84 -145.91) rotate(11.24)",fill:"#6c63ff",opacity:"0.7"}),Kt("rect",{x:"519.57",y:"209.08",width:"161.45",height:"4.89",transform:"translate(-88.17 -180.2) rotate(11.24)",fill:"#6c63ff",opacity:"0.7"}),Kt("rect",{x:"512.84",y:"249.31",width:"291.11",height:"4.89",transform:"translate(-79.21 -190.76) rotate(11.24)",fill:"#e0e0e0"}),Kt("rect",{x:"509.47",y:"255.44",width:"70.94",height:"4.89",transform:"translate(-80.19 -168.52) rotate(11.24)",fill:"#3ad29f",opacity:"0.7"}),Kt("rect",{x:"501.56",y:"307.59",width:"322.91",height:"4.89",transform:"translate(-67.76 -190.54) rotate(11.24)",fill:"#e0e0e0"}),Kt("g",{opacity:"0.5"},Kt("rect",{x:"575.87",y:"357.6",width:"166.35",height:"289.88",transform:"translate(-103.27 983.74) rotate(-78.76)",fill:"url(#089a6a47-adaa-499b-aefb-cd6464b62fb8)"})),Kt("rect",{x:"516.06",y:"420.61",width:"286.22",height:"162.68",transform:"translate(-30.42 -186.11) rotate(11.24)",fill:"#fff"}),Kt("rect",{x:"496.08",y:"335.18",width:"322.91",height:"4.89",transform:"translate(-62.49 -188.94) rotate(11.24)",fill:"#e0e0e0"}),Kt("rect",{x:"547.86",y:"424.02",width:"35.47",height:"118.64",transform:"translate(-35.84 -168.22) rotate(11.24)",fill:"#6c63ff"}),Kt("rect",{x:"606.43",y:"475.19",width:"35.47",height:"79.5",transform:"translate(-28.56 -179.03) rotate(11.24)",fill:"#3ad29f"}),Kt("rect",{x:"665.23",y:"523.93",width:"35.47",height:"42.81",transform:"translate(-21.5 -189.92) rotate(11.24)",fill:"#f55f44"}),Kt("rect",{x:"731.91",y:"492.72",width:"35.47",height:"86.84",transform:"translate(-22.02 -203.09) rotate(11.24)",fill:"#fdd835"}),Kt("g",{opacity:"0.5"},Kt("rect",{x:"128.65",y:"645.09",width:"3.67",height:"20.79",fill:"#47e6b1"}),Kt("rect",{x:"269.58",y:"712.31",width:"3.67",height:"20.79",transform:"translate(853.2 384.07) rotate(90)",fill:"#47e6b1"})),Kt("path",{d:"M699.44,75.56a4.49,4.49,0,0,1-2.5-5.43,2.16,2.16,0,0,0,.1-.5h0a2.25,2.25,0,0,0-4-1.49h0a2.16,2.16,0,0,0-.25.44,4.49,4.49,0,0,1-5.43,2.5,2.16,2.16,0,0,0-.5-.1h0a2.25,2.25,0,0,0-1.49,4h0a2.16,2.16,0,0,0,.44.25,4.49,4.49,0,0,1,2.5,5.43,2.16,2.16,0,0,0-.1.5h0a2.25,2.25,0,0,0,4,1.49h0a2.16,2.16,0,0,0,.25-.44,4.49,4.49,0,0,1,5.43-2.5,2.16,2.16,0,0,0,.5.1h0a2.25,2.25,0,0,0,1.49-4h0A2.16,2.16,0,0,0,699.44,75.56Z",transform:"translate(-140.93 -67.23)",fill:"#4d8af0",opacity:"0.5"}),Kt("path",{d:"M286.33,179.4a4.49,4.49,0,0,1-2.5-5.43,2.16,2.16,0,0,0,.1-.5h0a2.25,2.25,0,0,0-4-1.49h0a2.16,2.16,0,0,0-.25.44,4.49,4.49,0,0,1-5.43,2.5,2.16,2.16,0,0,0-.5-.1h0a2.25,2.25,0,0,0-1.49,4h0a2.16,2.16,0,0,0,.44.25,4.49,4.49,0,0,1,2.5,5.43,2.16,2.16,0,0,0-.1.5h0a2.25,2.25,0,0,0,4,1.49h0a2.16,2.16,0,0,0,.25-.44,4.49,4.49,0,0,1,5.43-2.5,2.16,2.16,0,0,0,.5.1h0a2.25,2.25,0,0,0,1.49-4h0A2.16,2.16,0,0,0,286.33,179.4Z",transform:"translate(-140.93 -67.23)",fill:"#fdd835",opacity:"0.5"}),Kt("path",{d:"M253.63,484.46a4.49,4.49,0,0,1-2.5-5.43,2.16,2.16,0,0,0,.1-.5h0a2.25,2.25,0,0,0-4-1.49h0a2.16,2.16,0,0,0-.25.44,4.49,4.49,0,0,1-5.43,2.5,2.16,2.16,0,0,0-.5-.1h0a2.25,2.25,0,0,0-1.49,4h0a2.16,2.16,0,0,0,.44.25,4.49,4.49,0,0,1,2.5,5.43,2.16,2.16,0,0,0-.1.5h0a2.25,2.25,0,0,0,4,1.49h0a2.16,2.16,0,0,0,.25-.44,4.49,4.49,0,0,1,5.43-2.5,2.16,2.16,0,0,0,.5.1h0a2.25,2.25,0,0,0,1.49-4h0A2.16,2.16,0,0,0,253.63,484.46Z",transform:"translate(-140.93 -67.23)",fill:"#fdd835",opacity:"0.5"}),Kt("circle",{cx:"337.81",cy:"28.62",r:"7.34",fill:"#f55f44",opacity:"0.5"}),Kt("circle",{cx:"7.34",cy:"317.46",r:"7.34",fill:"#f55f44",opacity:"0.5"}),Kt("circle",{cx:"863.76",cy:"120.36",r:"7.34",fill:"#f55f44",opacity:"0.5"}),Kt("circle",{cx:"822.17",cy:"339.3",r:"7.34",fill:"#4d8af0",opacity:"0.5"}),Kt("circle",{cx:"37.68",cy:"145.22",r:"7.34",fill:"#47e6b1",opacity:"0.5"}),Kt("circle",{cx:"853.29",cy:"647.34",r:"7.34",fill:"#47e6b1",opacity:"0.5"}),Kt("circle",{cx:"910.8",cy:"430.97",r:"7.34",fill:"#47e6b1",opacity:"0.5"}),Kt("rect",{x:"544.42",y:"601.05",width:"186.48",height:"153.07",fill:"url(#fd8d88e0-7826-450d-9e0b-001d1be709c2)"}),Kt("path",{d:"M723.82,639a54.55,54.55,0,0,1,109.1,0v34.91h15.27V639a69.82,69.82,0,0,0-139.65,0v34.91h15.27Z",transform:"translate(-140.93 -67.23)",fill:"url(#8d1793c5-b76e-44e2-a52e-569460402331)"}),Kt("path",{d:"M726,638.25a52.37,52.37,0,1,1,104.74,0v33.52H845.4V638.25a67,67,0,0,0-134.06,0v33.52H726Z",transform:"translate(-140.93 -67.23)",fill:"#f5f5f5"}),Kt("rect",{x:"546.32",y:"602.45",width:"182.24",height:"148.73",fill:"#6c63ff"}),Kt("rect",{x:"546.32",y:"602.45",width:"182.24",height:"148.73",fill:"#f5f5f5"}),Kt("rect",{x:"546.32",y:"631.77",width:"182.24",height:"90.07",fill:"#6c63ff"}),Kt("path",{d:"M791.73,727a13.36,13.36,0,1,0-23.08,9.15v28.51a9.72,9.72,0,0,0,19.44,0V736.18A13.3,13.3,0,0,0,791.73,727Z",transform:"translate(-140.93 -67.23)",fill:"url(#4745700d-8097-45ff-9f71-625443fc4ad8)"}),Kt("path",{d:"M789.89,729.38a11.52,11.52,0,1,0-19.9,7.89v24.58a8.38,8.38,0,1,0,16.76,0V737.27A11.47,11.47,0,0,0,789.89,729.38Z",transform:"translate(-140.93 -67.23)",opacity:"0.2"}))},__=wp.i18n.__,oe=wp.components,le=oe.Flex,ce=oe.FlexItem,he=oe.FlexBlock,de=function(){return Kt(le,{style:{padding:"30px",background:"#fff"}},Kt(ce,null,Kt(ne,{width:"250px"})),Kt(he,{style:{marginLeft:"20px"}},Kt("h1",null,__("Get detailed video insights.","presto-player")),Kt("p",null,__("Upgrade to Pro and get video insights like plays, watch-time, and drop off numbers.","presto-player")),Kt("a",{href:"https://prestoplayer.com",target:"_blank",className:"button button-primary"},__("Learn More","presto-player"))))};function ue(t,e){return e||(e=t.slice(0)),Object.freeze(Object.defineProperties(t,{raw:{value:Object.freeze(e)}}))}function pe(t,e,i,a,s,r,n){try{var o=t[r](n),l=o.value}catch(t){return void i(t)}o.done?e(l):Promise.resolve(l).then(a,s)}function fe(t){return function(){var e=this,i=arguments;return new Promise((function(a,s){var r=t.apply(e,i);function n(t){pe(r,a,s,n,o,"next",t)}function o(t){pe(r,a,s,n,o,"throw",t)}n(void 0)}))}}var ge=window.regeneratorRuntime,xe=i.n(ge);function me(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),i.push.apply(i,a)}return i}function be(t){for(var e=1;e<arguments.length;e++){var i=null!=arguments[e]?arguments[e]:{};e%2?me(Object(i),!0).forEach((function(e){f(t,e,i[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):me(Object(i)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(i,e))}))}return t}wp.i18n.__;var ve=wp.apiFetch,ye=wp.element.useState,we=wp.compose.createHigherOrderComponent,ke=function(){return we((function(t){return function(e){var i=a(ye(!1),2),s=i[0],r=i[1],n=a(ye(1),2),o=n[0],l=n[1],c=a(ye(0),2),h=c[0],d=c[1],u=a(ye(0),2),p=u[0],f=u[1],g=a(ye([]),2),x=g[0],m=g[1],v=a(ye(""),2),y=v[0],w=v[1],k=function(){var t=fe(xe().mark((function t(e){var i,a,s,n;return xe().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return i=e.endpoint,a=e.params,s=void 0===a?{}:a,r(!0),t.prev=2,t.next=5,ve({path:wp.url.addQueryArgs(i,be({page:o,per_page:5},s)),parse:!1}).then((function(t){var e=t.headers?parseInt(t.headers.get("X-WP-Total")):0,i=t.headers?parseInt(t.headers.get("X-WP-TotalPages")):0;return d(e),f(i),t.json()}));case 5:n=t.sent,m(n),t.next=13;break;case 9:t.prev=9,t.t0=t.catch(2),console.error(t.t0),null!==t.t0&&void 0!==t.t0&&t.t0.message&&w(t.t0.message);case 13:return t.prev=13,r(!1),t.finish(13);case 16:case"end":return t.stop()}}),t,null,[[2,9,13,16]])})));return function(_x){return t.apply(this,arguments)}}();return Kt(t,b({loading:s,setLoading:r,fetchData:k,page:o,setPage:l,total:h,setTotal:d,totalPages:p,setTotalPages:f,data:x,setData:m,error:y,setError:w},e))}}),"withDataList")},Ae=wp.i18n,Se=Ae.__,Ce=Ae.sprintf,Pe=function(t){var e=(new Date).getTimezoneOffset();return new Date(t.getTime()-60*e*1e3).toISOString().split("T")[0]+"T00:00:00.000Z"},Le=wp.components,De=Le.Spinner,Te=Le.Flex,Me=Le.FlexItem,Ee=function(t){var e=t.height;return Kt(Te,{style:{height:"".concat(void 0===e?100:e,"px")},align:"center",justify:"center"},Kt(Me,null,Kt(De,null)))},Ie=wp.i18n.__,Oe=wp.components,ze=Oe.Card,Re=Oe.CardBody,Ye=Oe.Flex,Fe=Oe.FlexBlock,Ne=Oe.Button,Xe=Oe.ButtonGroup,_e=wp.element,He=_e.useState,Be=_e.useEffect,We=function(t){var e=t.page,i=t.setPage,s=t.perPage,r=t.total,n=t.totalPages,o=a(He(!1),2),l=o[0],c=o[1],h=a(He(!1),2),d=h[0],u=h[1],p=a(He(0),2),f=p[0],g=p[1],x=a(He(0),2),m=x[0],b=x[1];return Be((function(){g(Math.min(s*e,r)),b(s*(e-1)+1)}),[s,e,r]),Be((function(){c(e-1>0),u(n>=e+1)}),[e,n]),Kt(ze,{size:"large",className:"presto-card pagination"},Kt(Re,{className:"presto-flow"},Kt(Ye,null,Kt(Fe,null,sprintf(Ie("Showing %1s to %2s of %3s","presto-player"),m,f,r)),Kt(Fe,null,Kt(Ye,{justify:"flex-end"},Kt(Xe,null,Kt(Ne,{isSecondary:!0,disabled:!l,onClick:function(){i(Math.max(e-1,0))}},Ie("Previous","presto-player")),Kt(Ne,{isSecondary:!0,disabled:!d,onClick:function(){i(Math.min(n,e+1))}},Ie("Next","presto-player"))))))))},je=wp.i18n.__,Ve=wp.element,Ge=(Ve.useRef,Ve.useEffect,Ve.useState,wp.components),Ue=Ge.Card,qe=Ge.CardBody,Ze=(Ge.Flex,Ge.FlexBlock,Ge.Button,Ge.ButtonGroup,function(t){var e=t.columns,i=t.data,a=t.onRowClick,s=t.title;return i.length?Kt(Ue,{size:"large",className:"presto-card table-card"},Kt(qe,{className:"presto-flow"},Kt("div",{className:"presto-card__title"},s),Kt("table",{role:"table",className:se()("presto-table",{"is-clickable":a})},Kt("thead",{role:"rowgroup"},Kt("tr",{role:"row"},e&&e.map((function(t){return Kt("th",{key:t.key,role:"columnheader"},t.label)})))),Kt("tbody",{role:"rowgroup"},i.map((function(t,i){return Kt("tr",{role:"row",key:"row-".concat(i),onClick:function(){return a&&a(t)}},e.map((function(e,a){return Kt("td",{role:"cell","data-title":e.label,key:"row-".concat(i,"-").concat(a),"aria-label":e.label},e.render?e.render(t):Kt("div",null,e.value(t)))})))})))))):Kt(Ue,{size:"large",className:"presto-card table-card"},Kt(qe,{className:"presto-flow"},Kt("div",{className:"presto-card__title"},s),Kt("div",{style:{opacity:.65}},je("No data available.","presto-player"))))}),$e=wp.i18n.__,Je=wp.element,Qe=(Je.useEffect,Je.useState,wp.components),Ke=Qe.Card,ti=Qe.CardBody,ei=function(t){var e=t.perPage,i=void 0===e?10:e,a=t.title,s=t.page,r=t.setPage,n=t.loading,o=t.total,l=t.totalPages,c=t.columns,h=t.data,d=t.onSelect;return n?Kt(Ke,null,Kt(Ee,null)):null!=h&&h.length?Kt("div",{className:"datatable"},Kt(Ze,{data:h,columns:c,perPage:i,onRowClick:d,title:a}),!!o&&Kt(We,{page:s,setPage:r,perPage:i,total:o,totalPages:l})):Kt(Ke,{size:"large",className:"presto-card"},Kt(ti,{className:"presto-flow"},Kt("div",{className:"presto-card__title"},a),Kt("div",{style:{opacity:.65}},$e("No data available.","presto-player"))))};function ii(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),i.push.apply(i,a)}return i}function ai(t){for(var e=1;e<arguments.length;e++){var i=null!=arguments[e]?arguments[e]:{};e%2?ii(Object(i),!0).forEach((function(e){f(t,e,i[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):ii(Object(i)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(i,e))}))}return t}var si=wp.i18n.__,ri=wp.element.useEffect,ni=(0,wp.compose.compose)([ke()])((function(t){var e=t.loading,i=t.page,a=t.setPage,s=t.total,r=t.totalPages,n=t.data,o=t.error,l=t.fetchData,c=t.startDate,h=t.endDate;ri((function(){l({endpoint:"/presto-player/v1/analytics/top-users",params:ai(ai({per_page:5},c?{start:Pe(c)}:{}),h?{end:Pe(h)}:{})})}),[i,c,h]);var d=[{key:"name",label:si("Name","presto-player"),value:function(t){var e;return null==t||null===(e=t.user)||void 0===e?void 0:e.name}},{key:"total_view",label:si("Total View","presto-player"),value:function(t){var e,i;return null==t||null===(e=t.stats)||void 0===e||null===(i=e[0])||void 0===i?void 0:i.data}},{key:"avg_view_time",label:si("Avg View Time","presto-player"),render:function(t){var e,i;return Kt("div",{className:"presto-badge"},null==t||null===(e=t.stats)||void 0===e||null===(i=e[1])||void 0===i?void 0:i.data)}}];return o?{error:o}:Kt(ei,{title:si("Top Users","presto-player"),page:i,perPage:5,setPage:a,loading:e,total:s,totalPages:r,columns:d,data:n,onSelect:function(t){var e,i;return i=null==t||null===(e=t.user)||void 0===e?void 0:e.id,void k.push("#/user/".concat(i))}})}));function oi(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),i.push.apply(i,a)}return i}function li(t){for(var e=1;e<arguments.length;e++){var i=null!=arguments[e]?arguments[e]:{};e%2?oi(Object(i),!0).forEach((function(e){f(t,e,i[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):oi(Object(i)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(i,e))}))}return t}var ci=wp.i18n.__,hi=wp.element.useEffect,di=(0,wp.compose.compose)([ke()])((function(t){var e=t.loading,i=t.page,a=t.setPage,s=t.total,r=t.totalPages,n=t.data,o=t.error,l=t.fetchData,c=t.startDate,h=t.endDate,d=t.userId;hi((function(){l({endpoint:"/presto-player/v1/analytics/top-videos",params:li(li(li({per_page:10},c?{start:Pe(c)}:{}),h?{end:Pe(h)}:{}),d?{user_id:d}:{})})}),[i,c,h]);var u=[{key:"name",label:ci("Name","presto-player"),render:function(t){return Kt("h3",{style:{marginBottom:0,wordBreak:"break-all"}},t.video.title?t.video.title:ci("Untitled","presto-player"))}},{key:"total_view",label:ci("Total View","presto-player"),value:function(t){return t.stats[0].data}},{key:"avg_view_time",label:ci("Avg View Time","presto-player"),render:function(t){return Kt("div",{className:"presto-badge"},t.stats[1].data)}},{key:"view_more",label:"",render:function(t){return Kt("span",{style:{color:"var(--wp-admin-theme-color, #007cba)"}},ci("View Details","presto-player")," →")}}];return o?{error:o}:Kt(ei,{title:ci("Top Media","presto-player"),perPage:10,page:i,setPage:a,loading:e,total:s,totalPages:r,columns:u,data:n,onSelect:function(t){var e,i;i=null==t||null===(e=t.video)||void 0===e?void 0:e.id,k.push("#/video/".concat(i))}})})),ui=wp.apiFetch;ui.use(ui.createNonceMiddleware(prestoPlayer.nonce)),ui.use(ui.createRootURLMiddleware(prestoPlayer.root+prestoPlayer.prestoVersionString));var pi=ui,fi=i(7229);function gi(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),i.push.apply(i,a)}return i}function xi(t){for(var e=1;e<arguments.length;e++){var i=null!=arguments[e]?arguments[e]:{};e%2?gi(Object(i),!0).forEach((function(e){f(t,e,i[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):gi(Object(i)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(i,e))}))}return t}var mi=wp.i18n,bi=mi.__,vi=mi.sprintf,yi=wp.components,wi=(yi.Card,yi.CardBody),ki=wp.element,Ai=ki.useState,Si=ki.useEffect,Ci=(ki.useRef,function(t){var e=a(Ai(!0),2),i=e[0],s=e[1],r=a(Ai(0),2),n=r[0],o=r[1],l=t.startDate,c=t.endDate,h=a(Ai([{name:"Views",data:[]}]),2),d=h[0],u=h[1],p={options:{chart:{toolbar:{show:!1}},yaxis:{min:0,labels:{formatter:function(t){return t<1?0:Math.abs(t)>999?Math.sign(t)*(Math.abs(t)/1e3).toFixed(1)+"k":Math.sign(t)*Math.abs(t).toFixed(0)}}},colors:["#7c3aed"],xaxis:{type:"datetime",min:new Date(l).setHours(0,0,0,0),max:new Date(c).setHours(23,59,59,999)},dataLabels:{enabled:!1},stroke:{curve:"smooth"},fill:{type:"gradient",gradient:{shadeIntensity:1,opacityFrom:.7,opacityTo:.9,stops:[0,90,100]}}}};Si((function(){f()}),[t]);var f=function(){s(!0),pi({path:"/presto-player/v1/analytics/views?"+jQuery.param(xi(xi({},l?{start:Pe(l)}:{}),c?{end:Pe(c)}:{})),parse:!1}).then(function(){var t=fe(xe().mark((function t(e){var i,a;return xe().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return o(e.headers&&e.headers.get("X-WP-Total")),t.next=3,e.json();case 3:i=t.sent,a=[],i.length&&i.forEach((function(t){a.push({x:t.date_time,y:t.total})})),u([{name:"Views",data:a}]);case 7:case"end":return t.stop()}}),t)})));return function(_x){return t.apply(this,arguments)}}()).catch((function(t){console.error(t)})).finally((function(){s(!1)}))};return i?Kt(wi,null,Kt(Ee,null)):Kt(wi,{className:"presto-flow"},Kt("div",{className:"presto-card__title"},vi(bi("%d Unique Views","presto-player"),n)),Kt(fi.Z,{options:p.options,series:d,type:"area",height:280}))}),Pi=wp.i18n,Li=Pi.__,Di=Pi.sprintf,Ti=wp.components,Mi=(Ti.Card,Ti.CardBody),Ei=wp.element,Ii=Ei.useState,Oi=Ei.useEffect,zi=(Ei.useRef,function(t){var e=a(Ii(!0),2),i=e[0],s=e[1],r=a(Ii(0),2),n=r[0],o=r[1],l=t.startDate,c=t.endDate,h=a(Ii([{name:"Views",data:[]}]),2),d=h[0],u=h[1],p={options:{chart:{toolbar:{show:!1}},yaxis:{labels:{formatter:function(t){return Math.abs(t)>999?Math.sign(t)*(Math.abs(t)/1e3).toFixed(1)+"k min":(Math.sign(t)*Math.abs(t)).toFixed(1)+"min"}}},colors:["#7c3aed"],xaxis:{type:"datetime",min:new Date(l).setHours(0,0,0,0),max:new Date(c).setHours(23,59,59,999)},dataLabels:{enabled:!1},stroke:{curve:"smooth"},fill:{type:"gradient",gradient:{shadeIntensity:1,opacityFrom:.7,opacityTo:.9,stops:[0,90,100]}}}};Oi((function(){v()}),[t]);var f,g,x,m,b,v=function(){s(!0),pi({path:"/presto-player/v1/analytics/watch-time?"+jQuery.param({start:Pe(l),end:Pe(c)}),parse:!1}).then(function(){var t=fe(xe().mark((function t(e){var i,a,s,r;return xe().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,e.json();case 2:i=t.sent,a=i.data,s=i.average,o(parseFloat(s)),r=[],a.length&&a.forEach((function(t){r.push({x:t.date_time,y:(t.total/60).toFixed(2)})})),u([{name:"Watch Time",data:r}]);case 9:case"end":return t.stop()}}),t)})));return function(_x){return t.apply(this,arguments)}}()).catch((function(t){console.error(t)})).finally((function(){s(!1)}))};return i?Kt(Mi,null,Kt(Ee,null)):Kt(Mi,{className:"presto-flow"},Kt("div",{className:"presto-card__title"},Di(Li("%s average watch time","presto-player"),(f=n,g=Math.floor(f/60/60),x=Math.floor(f/60)-60*g,m=f%60,b="",g&&(b+=Ce(Se("%d hours","presto-player"),g)+", "),x&&(b+=Ce(Se("%d minutes","presto-player"),x)+" "),(g||x)&&m&&(b+=Se("and","presto-player")+" "),b+Ce(Se("%d seconds","presto-player"),m)))),Kt(fi.Z,{options:p.options,series:d,type:"area",height:280}))}),Ri=wp.i18n.__,Yi=wp.components,Fi=Yi.Panel,Ni=Yi.TabPanel,Xi=function(t){var e=t.startDate,i=t.endDate;return Kt(Fi,null,Kt(Ni,{className:"presto-module-tabs",onSelect:function(){},tabs:[{name:"views",title:Ri("Views","presto-player")},{name:"watch",title:Ri("Watch Time","presto-player")}]},(function(t){switch(t.name){case"views":return Kt(Ci,{startDate:e,endDate:i});case"watch":return Kt(zi,{startDate:e,endDate:i});default:return Kt(React.Fragment,null,"Not Found")}})))},_i=i(7466),Hi=i.n(_i),Bi=(i(6710),wp.i18n.__),Wi=wp.element,ji=Wi.useRef,Vi=Wi.useEffect,Gi=Wi.useState,Ui=function(t){var e=t.startDate,i=t.setStartDate,s=t.endDate,r=t.setEndDate,n=ji(),o=a(Gi(25),2),l=o[0],c=o[1];return Vi((function(){new(Hi())({element:null==n?void 0:n.current,singleMode:!1,format:"MMMM D YYYY",autoApply:!1,plugins:["ranges"],maxDate:new Date,numberOfMonths:2,buttonText:{apply:Bi("Apply","presto-player"),cancel:Bi("Cancel","presto-player")},dropdowns:{minYear:1990,maxYear:null,months:!0,years:!0},setup:function(t){t.setDateRange(e,s),t.on("button:apply",(function(t,e){i(t.dateInstance),r(e.dateInstance),c(n.current.value.length)}))}})}),[n]),Kt("div",{className:"component-base-control"},Kt("div",{className:"components-base-control__field"},Kt("input",{className:"components-text-control__input presto-settings__date-select",ref:n,size:l})))},qi=window.wp.apiFetch,Zi=i.n(qi),$i=window.wp.components,Ji=function(){function t(t){this.isSpeedy=void 0===t.speedy||t.speedy,this.tags=[],this.ctr=0,this.nonce=t.nonce,this.key=t.key,this.container=t.container,this.before=null}var e=t.prototype;return e.insert=function(t){if(this.ctr%(this.isSpeedy?65e3:1)==0){var e,i=function(t){var e=document.createElement("style");return e.setAttribute("data-emotion",t.key),void 0!==t.nonce&&e.setAttribute("nonce",t.nonce),e.appendChild(document.createTextNode("")),e}(this);e=0===this.tags.length?this.before:this.tags[this.tags.length-1].nextSibling,this.container.insertBefore(i,e),this.tags.push(i)}var a=this.tags[this.tags.length-1];if(this.isSpeedy){var s=function(t){if(t.sheet)return t.sheet;for(var e=0;e<document.styleSheets.length;e++)if(document.styleSheets[e].ownerNode===t)return document.styleSheets[e]}(a);try{var r=105===t.charCodeAt(1)&&64===t.charCodeAt(0);s.insertRule(t,r?0:s.cssRules.length)}catch(t){}}else a.appendChild(document.createTextNode(t));this.ctr++},e.flush=function(){this.tags.forEach((function(t){return t.parentNode.removeChild(t)})),this.tags=[],this.ctr=0},t}(),Qi=function(t){function e(t,a,l,c,u){for(var p,f,g,x,y,k=0,A=0,S=0,C=0,P=0,I=0,z=g=p=0,Y=0,F=0,N=0,X=0,_=l.length,H=_-1,B="",W="",j="",V="";Y<_;){if(f=l.charCodeAt(Y),Y===H&&0!==A+C+S+k&&(0!==A&&(f=47===A?10:47),C=S=k=0,_++,H++),0===A+C+S+k){if(Y===H&&(0<F&&(B=B.replace(d,"")),0<B.trim().length)){switch(f){case 32:case 9:case 59:case 13:case 10:break;default:B+=l.charAt(Y)}f=59}switch(f){case 123:for(p=(B=B.trim()).charCodeAt(0),g=1,X=++Y;Y<_;){switch(f=l.charCodeAt(Y)){case 123:g++;break;case 125:g--;break;case 47:switch(f=l.charCodeAt(Y+1)){case 42:case 47:t:{for(z=Y+1;z<H;++z)switch(l.charCodeAt(z)){case 47:if(42===f&&42===l.charCodeAt(z-1)&&Y+2!==z){Y=z+1;break t}break;case 10:if(47===f){Y=z+1;break t}}Y=z}}break;case 91:f++;case 40:f++;case 34:case 39:for(;Y++<H&&l.charCodeAt(Y)!==f;);}if(0===g)break;Y++}if(g=l.substring(X,Y),0===p&&(p=(B=B.replace(h,"").trim()).charCodeAt(0)),64===p){switch(0<F&&(B=B.replace(d,"")),f=B.charCodeAt(1)){case 100:case 109:case 115:case 45:F=a;break;default:F=E}if(X=(g=e(a,F,g,f,u+1)).length,0<O&&(y=o(3,g,F=i(E,B,N),a,D,L,X,f,u,c),B=F.join(""),void 0!==y&&0===(X=(g=y.trim()).length)&&(f=0,g="")),0<X)switch(f){case 115:B=B.replace(w,n);case 100:case 109:case 45:g=B+"{"+g+"}";break;case 107:g=(B=B.replace(m,"$1 $2"))+"{"+g+"}",g=1===M||2===M&&r("@"+g,3)?"@-webkit-"+g+"@"+g:"@"+g;break;default:g=B+g,112===c&&(W+=g,g="")}else g=""}else g=e(a,i(a,B,N),g,c,u+1);j+=g,g=N=F=z=p=0,B="",f=l.charCodeAt(++Y);break;case 125:case 59:if(1<(X=(B=(0<F?B.replace(d,""):B).trim()).length))switch(0===z&&(p=B.charCodeAt(0),45===p||96<p&&123>p)&&(X=(B=B.replace(" ",":")).length),0<O&&void 0!==(y=o(1,B,a,t,D,L,W.length,c,u,c))&&0===(X=(B=y.trim()).length)&&(B="\0\0"),p=B.charCodeAt(0),f=B.charCodeAt(1),p){case 0:break;case 64:if(105===f||99===f){V+=B+l.charAt(Y);break}default:58!==B.charCodeAt(X-1)&&(W+=s(B,p,f,B.charCodeAt(2)))}N=F=z=p=0,B="",f=l.charCodeAt(++Y)}}switch(f){case 13:case 10:47===A?A=0:0===1+p&&107!==c&&0<B.length&&(F=1,B+="\0"),0<O*R&&o(0,B,a,t,D,L,W.length,c,u,c),L=1,D++;break;case 59:case 125:if(0===A+C+S+k){L++;break}default:switch(L++,x=l.charAt(Y),f){case 9:case 32:if(0===C+k+A)switch(P){case 44:case 58:case 9:case 32:x="";break;default:32!==f&&(x=" ")}break;case 0:x="\\0";break;case 12:x="\\f";break;case 11:x="\\v";break;case 38:0===C+A+k&&(F=N=1,x="\f"+x);break;case 108:if(0===C+A+k+T&&0<z)switch(Y-z){case 2:112===P&&58===l.charCodeAt(Y-3)&&(T=P);case 8:111===I&&(T=I)}break;case 58:0===C+A+k&&(z=Y);break;case 44:0===A+S+C+k&&(F=1,x+="\r");break;case 34:case 39:0===A&&(C=C===f?0:0===C?f:C);break;case 91:0===C+A+S&&k++;break;case 93:0===C+A+S&&k--;break;case 41:0===C+A+k&&S--;break;case 40:0===C+A+k&&(0===p&&(2*P+3*I==533||(p=1)),S++);break;case 64:0===A+S+C+k+z+g&&(g=1);break;case 42:case 47:if(!(0<C+k+S))switch(A){case 0:switch(2*f+3*l.charCodeAt(Y+1)){case 235:A=47;break;case 220:X=Y,A=42}break;case 42:47===f&&42===P&&X+2!==Y&&(33===l.charCodeAt(X+2)&&(W+=l.substring(X,Y+1)),x="",A=0)}}0===A&&(B+=x)}I=P,P=f,Y++}if(0<(X=W.length)){if(F=a,0<O&&void 0!==(y=o(2,W,F,t,D,L,X,c,u,c))&&0===(W=y).length)return V+W+j;if(W=F.join(",")+"{"+W+"}",0!=M*T){switch(2!==M||r(W,2)||(T=0),T){case 111:W=W.replace(v,":-moz-$1")+W;break;case 112:W=W.replace(b,"::-webkit-input-$1")+W.replace(b,"::-moz-$1")+W.replace(b,":-ms-input-$1")+W}T=0}}return V+W+j}function i(t,e,i){var s=e.trim().split(g);e=s;var r=s.length,n=t.length;switch(n){case 0:case 1:var o=0;for(t=0===n?"":t[0]+" ";o<r;++o)e[o]=a(t,e[o],i).trim();break;default:var l=o=0;for(e=[];o<r;++o)for(var c=0;c<n;++c)e[l++]=a(t[c]+" ",s[o],i).trim()}return e}function a(t,e,i){var a=e.charCodeAt(0);switch(33>a&&(a=(e=e.trim()).charCodeAt(0)),a){case 38:return e.replace(x,"$1"+t.trim());case 58:return t.trim()+e.replace(x,"$1"+t.trim());default:if(0<1*i&&0<e.indexOf("\f"))return e.replace(x,(58===t.charCodeAt(0)?"":"$1")+t.trim())}return t+e}function s(t,e,i,a){var n=t+";",o=2*e+3*i+4*a;if(944===o){t=n.indexOf(":",9)+1;var l=n.substring(t,n.length-1).trim();return l=n.substring(0,t).trim()+l+";",1===M||2===M&&r(l,1)?"-webkit-"+l+l:l}if(0===M||2===M&&!r(n,1))return n;switch(o){case 1015:return 97===n.charCodeAt(10)?"-webkit-"+n+n:n;case 951:return 116===n.charCodeAt(3)?"-webkit-"+n+n:n;case 963:return 110===n.charCodeAt(5)?"-webkit-"+n+n:n;case 1009:if(100!==n.charCodeAt(4))break;case 969:case 942:return"-webkit-"+n+n;case 978:return"-webkit-"+n+"-moz-"+n+n;case 1019:case 983:return"-webkit-"+n+"-moz-"+n+"-ms-"+n+n;case 883:if(45===n.charCodeAt(8))return"-webkit-"+n+n;if(0<n.indexOf("image-set(",11))return n.replace(P,"$1-webkit-$2")+n;break;case 932:if(45===n.charCodeAt(4))switch(n.charCodeAt(5)){case 103:return"-webkit-box-"+n.replace("-grow","")+"-webkit-"+n+"-ms-"+n.replace("grow","positive")+n;case 115:return"-webkit-"+n+"-ms-"+n.replace("shrink","negative")+n;case 98:return"-webkit-"+n+"-ms-"+n.replace("basis","preferred-size")+n}return"-webkit-"+n+"-ms-"+n+n;case 964:return"-webkit-"+n+"-ms-flex-"+n+n;case 1023:if(99!==n.charCodeAt(8))break;return"-webkit-box-pack"+(l=n.substring(n.indexOf(":",15)).replace("flex-","").replace("space-between","justify"))+"-webkit-"+n+"-ms-flex-pack"+l+n;case 1005:return p.test(n)?n.replace(u,":-webkit-")+n.replace(u,":-moz-")+n:n;case 1e3:switch(e=(l=n.substring(13).trim()).indexOf("-")+1,l.charCodeAt(0)+l.charCodeAt(e)){case 226:l=n.replace(y,"tb");break;case 232:l=n.replace(y,"tb-rl");break;case 220:l=n.replace(y,"lr");break;default:return n}return"-webkit-"+n+"-ms-"+l+n;case 1017:if(-1===n.indexOf("sticky",9))break;case 975:switch(e=(n=t).length-10,o=(l=(33===n.charCodeAt(e)?n.substring(0,e):n).substring(t.indexOf(":",7)+1).trim()).charCodeAt(0)+(0|l.charCodeAt(7))){case 203:if(111>l.charCodeAt(8))break;case 115:n=n.replace(l,"-webkit-"+l)+";"+n;break;case 207:case 102:n=n.replace(l,"-webkit-"+(102<o?"inline-":"")+"box")+";"+n.replace(l,"-webkit-"+l)+";"+n.replace(l,"-ms-"+l+"box")+";"+n}return n+";";case 938:if(45===n.charCodeAt(5))switch(n.charCodeAt(6)){case 105:return l=n.replace("-items",""),"-webkit-"+n+"-webkit-box-"+l+"-ms-flex-"+l+n;case 115:return"-webkit-"+n+"-ms-flex-item-"+n.replace(A,"")+n;default:return"-webkit-"+n+"-ms-flex-line-pack"+n.replace("align-content","").replace(A,"")+n}break;case 973:case 989:if(45!==n.charCodeAt(3)||122===n.charCodeAt(4))break;case 931:case 953:if(!0===C.test(t))return 115===(l=t.substring(t.indexOf(":")+1)).charCodeAt(0)?s(t.replace("stretch","fill-available"),e,i,a).replace(":fill-available",":stretch"):n.replace(l,"-webkit-"+l)+n.replace(l,"-moz-"+l.replace("fill-",""))+n;break;case 962:if(n="-webkit-"+n+(102===n.charCodeAt(5)?"-ms-"+n:"")+n,211===i+a&&105===n.charCodeAt(13)&&0<n.indexOf("transform",10))return n.substring(0,n.indexOf(";",27)+1).replace(f,"$1-webkit-$2")+n}return n}function r(t,e){var i=t.indexOf(1===e?":":"{"),a=t.substring(0,3!==e?i:10);return i=t.substring(i+1,t.length-1),z(2!==e?a:a.replace(S,"$1"),i,e)}function n(t,e){var i=s(e,e.charCodeAt(0),e.charCodeAt(1),e.charCodeAt(2));return i!==e+";"?i.replace(k," or ($1)").substring(4):"("+e+")"}function o(t,e,i,a,s,r,n,o,l,h){for(var d,u=0,p=e;u<O;++u)switch(d=I[u].call(c,t,p,i,a,s,r,n,o,l,h)){case void 0:case!1:case!0:case null:break;default:p=d}if(p!==e)return p}function l(t){return void 0!==(t=t.prefix)&&(z=null,t?"function"!=typeof t?M=1:(M=2,z=t):M=0),l}function c(t,i){var a=t;if(33>a.charCodeAt(0)&&(a=a.trim()),a=[a],0<O){var s=o(-1,i,a,a,D,L,0,0,0,0);void 0!==s&&"string"==typeof s&&(i=s)}var r=e(E,a,i,0,0);return 0<O&&void 0!==(s=o(-2,r,a,a,D,L,r.length,0,0,0))&&(r=s),T=0,L=D=1,r}var h=/^\0+/g,d=/[\0\r\f]/g,u=/: */g,p=/zoo|gra/,f=/([,: ])(transform)/g,g=/,\r+?/g,x=/([\t\r\n ])*\f?&/g,m=/@(k\w+)\s*(\S*)\s*/,b=/::(place)/g,v=/:(read-only)/g,y=/[svh]\w+-[tblr]{2}/,w=/\(\s*(.*)\s*\)/g,k=/([\s\S]*?);/g,A=/-self|flex-/g,S=/[^]*?(:[rp][el]a[\w-]+)[^]*/,C=/stretch|:\s*\w+\-(?:conte|avail)/,P=/([^-])(image-set\()/,L=1,D=1,T=0,M=1,E=[],I=[],O=0,z=null,R=0;return c.use=function t(e){switch(e){case void 0:case null:O=I.length=0;break;default:if("function"==typeof e)I[O++]=e;else if("object"==typeof e)for(var i=0,a=e.length;i<a;++i)t(e[i]);else R=0|!!e}return t},c.set=l,void 0!==t&&l(t),c},Ki="/*|*/";function ta(t){t&&ea.current.insert(t+"}")}var ea={current:null},ia=function(t,e,i,a,s,r,n,o,l,c){switch(t){case 1:switch(e.charCodeAt(0)){case 64:return ea.current.insert(e+";"),"";case 108:if(98===e.charCodeAt(2))return""}break;case 2:if(0===o)return e+Ki;break;case 3:switch(o){case 102:case 112:return ea.current.insert(i[0]+e),"";default:return e+(0===c?Ki:"")}case-2:e.split("/*|*/}").forEach(ta)}};function aa(t,e,i){var a="";return i.split(" ").forEach((function(i){void 0!==t[i]?e.push(t[i]):a+=i+" "})),a}var sa,ra=function(t,e,i){var a=t.key+"-"+e.name;if(!1===i&&void 0===t.registered[a]&&(t.registered[a]=e.styles),void 0===t.inserted[e.name]){var s=e;do{t.insert("."+a,s,t.sheet,!0),s=s.next}while(void 0!==s)}},na=function(t){for(var e,i=0,a=0,s=t.length;s>=4;++a,s-=4)e=1540483477*(65535&(e=255&t.charCodeAt(a)|(255&t.charCodeAt(++a))<<8|(255&t.charCodeAt(++a))<<16|(255&t.charCodeAt(++a))<<24))+(59797*(e>>>16)<<16),i=1540483477*(65535&(e^=e>>>24))+(59797*(e>>>16)<<16)^1540483477*(65535&i)+(59797*(i>>>16)<<16);switch(s){case 3:i^=(255&t.charCodeAt(a+2))<<16;case 2:i^=(255&t.charCodeAt(a+1))<<8;case 1:i=1540483477*(65535&(i^=255&t.charCodeAt(a)))+(59797*(i>>>16)<<16)}return(((i=1540483477*(65535&(i^=i>>>13))+(59797*(i>>>16)<<16))^i>>>15)>>>0).toString(36)},oa={animationIterationCount:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},la=/[A-Z]|^ms/g,ca=/_EMO_([^_]+?)_([^]*?)_EMO_/g,ha=function(t){return 45===t.charCodeAt(1)},da=function(t){return null!=t&&"boolean"!=typeof t},ua=(sa={},function(t){return void 0===sa[t]&&(sa[t]=ha(e=t)?e:e.replace(la,"-$&").toLowerCase()),sa[t];var e}),pa=function(t,e){switch(t){case"animation":case"animationName":if("string"==typeof e)return e.replace(ca,(function(t,e,i){return ga={name:e,styles:i,next:ga},e}))}return 1===oa[t]||ha(t)||"number"!=typeof e||0===e?e:e+"px"};function fa(t,e,i,a){if(null==i)return"";if(void 0!==i.__emotion_styles)return i;switch(typeof i){case"boolean":return"";case"object":if(1===i.anim)return ga={name:i.name,styles:i.styles,next:ga},i.name;if(void 0!==i.styles){var s=i.next;if(void 0!==s)for(;void 0!==s;)ga={name:s.name,styles:s.styles,next:ga},s=s.next;return i.styles+";"}return function(t,e,i){var a="";if(Array.isArray(i))for(var s=0;s<i.length;s++)a+=fa(t,e,i[s],!1);else for(var r in i){var n=i[r];if("object"!=typeof n)null!=e&&void 0!==e[n]?a+=r+"{"+e[n]+"}":da(n)&&(a+=ua(r)+":"+pa(r,n)+";");else if(!Array.isArray(n)||"string"!=typeof n[0]||null!=e&&void 0!==e[n[0]]){var o=fa(t,e,n,!1);switch(r){case"animation":case"animationName":a+=ua(r)+":"+o+";";break;default:a+=r+"{"+o+"}"}}else for(var l=0;l<n.length;l++)da(n[l])&&(a+=ua(r)+":"+pa(r,n[l])+";")}return a}(t,e,i);case"function":if(void 0!==t){var r=ga,n=i(t);return ga=r,fa(t,e,n,a)}}if(null==e)return i;var o=e[i];return void 0===o||a?i:o}var ga,xa=/label:\s*([^\s;\n{]+)\s*;/g,ma=function(t,e,i){if(1===t.length&&"object"==typeof t[0]&&null!==t[0]&&void 0!==t[0].styles)return t[0];var a=!0,s="";ga=void 0;var r=t[0];null==r||void 0===r.raw?(a=!1,s+=fa(i,e,r,!1)):s+=r[0];for(var n=1;n<t.length;n++)s+=fa(i,e,t[n],46===s.charCodeAt(s.length-1)),a&&(s+=r[n]);xa.lastIndex=0;for(var o,l="";null!==(o=xa.exec(s));)l+="-"+o[1];return{name:na(s)+l,styles:s,next:ga}},ba=Object.prototype.hasOwnProperty,va=(0,T.createContext)("undefined"!=typeof HTMLElement?function(t){void 0===t&&(t={});var e,i=t.key||"css";void 0!==t.prefix&&(e={prefix:t.prefix});var a,s=new Qi(e),r={};a=t.container||document.head;var n,o=document.querySelectorAll("style[data-emotion-"+i+"]");Array.prototype.forEach.call(o,(function(t){t.getAttribute("data-emotion-"+i).split(" ").forEach((function(t){r[t]=!0})),t.parentNode!==a&&a.appendChild(t)})),s.use(t.stylisPlugins)(ia),n=function(t,e,i,a){var r=e.name;ea.current=i,s(t,e.styles),a&&(l.inserted[r]=!0)};var l={key:i,sheet:new Ji({key:i,container:a,nonce:t.nonce,speedy:t.speedy}),nonce:t.nonce,inserted:r,registered:{},insert:n};return l}():null),ya=(0,T.createContext)({}),wa=(va.Provider,function(t){var e=function(e,i){return(0,T.createElement)(va.Consumer,null,(function(a){return t(e,a,i)}))};return(0,T.forwardRef)(e)}),ka=function(t,e){var i={};for(var a in e)ba.call(e,a)&&(i[a]=e[a]);return i.__EMOTION_TYPE_PLEASE_DO_NOT_USE__=t,i},Aa=function(){return null},Sa=function(t,e,i,a){var s=null===i?e.css:e.css(i);"string"==typeof s&&void 0!==t.registered[s]&&(s=t.registered[s]);var r=e.__EMOTION_TYPE_PLEASE_DO_NOT_USE__,n=[s],o="";"string"==typeof e.className?o=aa(t.registered,n,e.className):null!=e.className&&(o=e.className+" ");var l=ma(n);ra(t,l,"string"==typeof r),o+=t.key+"-"+l.name;var c={};for(var h in e)ba.call(e,h)&&"css"!==h&&"__EMOTION_TYPE_PLEASE_DO_NOT_USE__"!==h&&(c[h]=e[h]);c.ref=a,c.className=o;var d=(0,T.createElement)(r,c),u=(0,T.createElement)(Aa,null);return(0,T.createElement)(T.Fragment,null,u,d)},Ca=wa((function(t,e,i){return"function"==typeof t.css?(0,T.createElement)(ya.Consumer,null,(function(a){return Sa(e,t,a,i)})):Sa(e,t,null,i)})),Pa=function(){for(var t=arguments.length,e=new Array(t),i=0;i<t;i++)e[i]=arguments[i];return ma(e)},La=function(t,e){var i=arguments;if(null==e||!ba.call(e,"css"))return T.createElement.apply(void 0,i);var a=i.length,s=new Array(a);s[0]=Ca,s[1]=ka(t,e);for(var r=2;r<a;r++)s[r]=i[r];return T.createElement.apply(null,s)},Da=(T.Component,function t(e){for(var i=e.length,a=0,s="";a<i;a++){var r=e[a];if(null!=r){var n=void 0;switch(typeof r){case"boolean":break;case"object":if(Array.isArray(r))n=t(r);else for(var o in n="",r)r[o]&&o&&(n&&(n+=" "),n+=o);break;default:n=r}n&&(s&&(s+=" "),s+=n)}}return s});function Ta(t,e,i){var a=[],s=aa(t,a,i);return a.length<2?i:s+e(a)}var Ma,Ea=function(){return null},Ia=(wa((function(t,e){return(0,T.createElement)(ya.Consumer,null,(function(i){var a=function(){for(var t=arguments.length,i=new Array(t),a=0;a<t;a++)i[a]=arguments[a];var s=ma(i,e.registered);return ra(e,s,!1),e.key+"-"+s.name},s={css:a,cx:function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];return Ta(e.registered,a,Da(i))},theme:i},r=t.children(s),n=(0,T.createElement)(Ea,null);return(0,T.createElement)(T.Fragment,null,n,r)}))})),wp.i18n.__),Oa=wp.components,za=Oa.Flex,Ra=Oa.FlexBlock,Ya=Oa.FlexItem,Fa=wp.element,Na=Fa.useState,Xa=Fa.useEffect;function _a(t){var e=t.startDate,i=t.endDate,s=t.setStartDate,r=t.setEndDate,n=a(Na(!1),2),o=n[0],l=n[1];return Xa((function(){Zi()({path:"/wp/v2/settings"}).then((function(t){var e;!1===(null==t||null===(e=t.presto_player_analytics)||void 0===e?void 0:e.enable)&&l(!0)}))}),[]),La(React.Fragment,null,o?La(Ha,null):"",La(za,null,La(Ra,null,La("h1",null,Ia("Analytics","presto-player"))),La(Ya,null,La(Ui,{startDate:e,setStartDate:s,endDate:i,setEndDate:r}))),La("div",{className:"presto-flow"},La("div",{className:"presto-dashboard"},La("div",{className:"presto-dashboard__row"},La("div",{className:"presto-dashboard__item is-large"},La(Xi,{startDate:e,endDate:i})),La("div",{className:"presto-dashboard__item"},La(ni,{startDate:e,endDate:i}))),La("div",{className:"presto-dashboard__row"},La("div",{className:"presto-dashboard__item is-large"},La(di,{startDate:e,endDate:i}))))))}var Ha=function(){return La($i.Notice,{css:Pa(Ma||(Ma=ue(["\n margin: 0 0 1em 0 !important;\n "]))),status:"warning",isDismissible:!1},La("p",null,Ia("Analytics are currently disabled. To collect analytics, turn them on in your settings page.","presto-player")))},Ba=wp.components,Wa=Ba.Card,ja=Ba.CardBody,Va=function(t){var e=t.loading,i=t.title,a=t.value,s=t.label;return e?Kt(Wa,null,Kt(ja,null,Kt(Ee,null))):Kt(Wa,{className:"presto-player__stat-card"},Kt(ja,null,Kt("div",{className:"presto-subtitle"},i),Kt("h1",null,a),Kt("div",null,s)))};function Ga(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),i.push.apply(i,a)}return i}function Ua(t){for(var e=1;e<arguments.length;e++){var i=null!=arguments[e]?arguments[e]:{};e%2?Ga(Object(i),!0).forEach((function(e){f(t,e,i[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):Ga(Object(i)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(i,e))}))}return t}var qa,Za,$a,Ja=wp.apiFetch,Qa=wp.element.useState,Ka=wp.compose.createHigherOrderComponent,ts=function(){return Ka((function(t){return function(e){var i=a(Qa(!1),2),s=i[0],r=i[1],n=a(Qa([]),2),o=n[0],l=n[1],c=a(Qa(""),2),h=c[0],d=c[1],u=function(){var t=fe(xe().mark((function t(e){var i,a,s,n;return xe().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return i=e.endpoint,a=e.params,s=void 0===a?{}:a,r(!0),t.prev=2,t.next=5,Ja({path:wp.url.addQueryArgs(i,Ua({},s))});case 5:n=t.sent,l(n),t.next=13;break;case 9:t.prev=9,t.t0=t.catch(2),console.error(t.t0),null!==t.t0&&void 0!==t.t0&&t.t0.message&&d(t.t0.message);case 13:return t.prev=13,r(!1),t.finish(13);case 16:case"end":return t.stop()}}),t,null,[[2,9,13,16]])})));return function(_x){return t.apply(this,arguments)}}();return Kt(t,b({loading:s,setLoading:r,fetchData:u,stat:o,setStat:l,error:h,setError:d},e))}}),"withStat")},es=wp.i18n.__,is=wp.compose.compose,as=wp.element.useEffect,ss=is([ts()])((function(t){var e=t.userId,i=t.startDate,a=t.endDate,s=t.stat,r=t.fetchData,n=t.loading;return as((function(){r({endpoint:"/presto-player/v1/analytics/user/".concat(e,"/total-views"),params:{start:Pe(i),end:Pe(a)}})}),[i,a]),Kt(Va,{loading:n,value:parseInt(null==s?void 0:s.view),title:es("Total Views","presto-player")})})),rs=wp.i18n.__,ns=wp.compose.compose,os=wp.element.useEffect,ls=ns([ts()])((function(t){var e=t.userId,i=t.startDate,a=t.endDate,s=t.stat,r=t.fetchData,n=t.loading;return os((function(){r({endpoint:"/presto-player/v1/analytics/user/".concat(e,"/average-watchtime"),params:{start:Pe(i),end:Pe(a)}})}),[i,a]),Kt(Va,{loading:n,value:parseFloat(null==s?void 0:s.view).toFixed(2),title:rs("Average Watch Time","presto-player"),label:rs("seconds","presto-player")})})),cs=wp.i18n.__,hs=wp.compose.compose,ds=wp.element.useEffect,us=hs([ts()])((function(t){var e=t.userId,i=t.startDate,a=t.endDate,s=t.stat,r=t.fetchData,n=t.loading;return ds((function(){r({endpoint:"/presto-player/v1/analytics/user/".concat(e,"/total-watchtime"),params:{start:Pe(i),end:Pe(a)}})}),[i,a]),Kt(Va,{loading:n,value:parseFloat(null==s?void 0:s.view).toFixed(2),title:cs("Total Watch Time","presto-player"),label:cs("seconds","presto-player")})})),ps=wp.i18n.__,fs=wp.components,gs=fs.Flex,xs=fs.FlexBlock,ms=fs.FlexItem,bs=fs.Spinner,vs=fs.Button,ys=wp.element,ws=ys.useEffect,ks=ys.useState,As=wp.apiFetch,Ss=function(t){var e,i,s,r,n=t.route,o=t.startDate,l=t.endDate,c=t.setStartDate,h=t.setEndDate,d=a(ks(!0),2),u=d[0],p=d[1],f=a(ks({}),2),g=f[0],x=f[1],m=a(ks(""),2),b=m[0],v=m[1],y=function(){var t=fe(xe().mark((function t(){var e,i;return xe().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return p(!0),t.prev=1,t.next=4,As({url:"/wp-json/wp/v2/users/".concat(null==n||null===(e=n.params)||void 0===e?void 0:e.id,"?context=edit")});case 4:i=t.sent,x(i),t.next=11;break;case 8:t.prev=8,t.t0=t.catch(1),"rest_no_route"===t.t0.code&&v("User Not Found");case 11:return t.prev=11,p(!1),t.finish(11);case 14:case"end":return t.stop()}}),t,null,[[1,8,11,14]])})));return function(){return t.apply(this,arguments)}}();return ws((function(){y()}),[]),b?La("div",{className:"presto-flow"},La(gs,null,La(xs,null,La("h2",null,b)))):La("div",{className:"presto-flow"},La(gs,null,La(xs,null,La(vs,{isSecondary:!0,onClick:function(){k.push("#/")}},"← ",ps("Back to Dashboard","presto-player")))),La(gs,{wrap:!0},La(xs,null,u?La(bs,null):La("div",{css:Pa(qa||(qa=ue(["\n display: flex;\n align-items: center;\n\n .presto__edit-user-button {\n opacity: 0;\n visibility: hidden;\n transition: opacity 0.3s ease;\n }\n\n &:hover {\n .presto__edit-user-button {\n opacity: 1;\n visibility: visible;\n }\n }\n "])))},La("div",null,La("h1",{className:"presto-dashboard__title"},null==g?void 0:g.name),La("p",{css:Pa(Za||(Za=ue(["\n margin-top: -10px;\n opacity: 0.65;\n "])))},null==g?void 0:g.email)),!!g.id&&La("div",{className:"presto__edit-user-button",css:Pa($a||($a=ue(["\n margin: 0 20px;\n "])))},La(vs,{href:"/wp-admin/user-edit.php?user_id=".concat(null==g?void 0:g.id),isSecondary:!0,isSmall:!0},ps("View Profile","presto-player")," →")))),La(ms,null,La(Ui,{startDate:o,setStartDate:c,endDate:l,setEndDate:h}))),La("div",{className:"presto-dashboard presto-flow"},La("div",{className:"presto-dashboard__row"},La("div",{className:"presto-dashboard__item"},La(ss,{userId:null==n||null===(e=n.params)||void 0===e?void 0:e.id,startDate:o,endDate:l})),La("div",{className:"presto-dashboard__item"},La(ls,{userId:null==n||null===(i=n.params)||void 0===i?void 0:i.id,startDate:o,endDate:l})),La("div",{className:"presto-dashboard__item"},La(us,{userId:null==n||null===(s=n.params)||void 0===s?void 0:s.id,startDate:o,endDate:l}))),La("div",{className:"presto-dashboard__row"},La("div",{className:"presto-dashboard__item is-large"},La(di,{startDate:o,endDate:l,userId:null==n||null===(r=n.params)||void 0===r?void 0:r.id})))))},Cs=wp.i18n.__,Ps=wp.compose.compose,Ls=wp.element.useEffect,Ds=Ps([ts()])((function(t){var e=t.video_id,i=t.startDate,a=t.endDate,s=t.stat,r=t.fetchData,n=t.loading;return Ls((function(){r({endpoint:"/presto-player/v1/analytics/video/".concat(e,"/average-watchtime"),params:{start:Pe(i),end:Pe(a)}})}),[i,a]),Kt(Va,{loading:n,value:parseInt(s),title:Cs("Average Watch Time","presto-player"),label:Cs("seconds","presto-player")})})),Ts=wp.i18n,Ms=Ts.__,Es=(Ts.sprintf,wp.components),Is=Es.Card,Os=Es.CardBody,zs=wp.element,Rs=zs.useState,Ys=zs.useEffect,Fs=(zs.useRef,function(t){var e=t.video_id,i=t.startDate,s=t.endDate,r=a(Rs(!0),2),n=r[0],o=r[1],l=a(Rs([{name:"Views",data:[]}]),2),c=l[0],h=l[1];Ys((function(){o(!0),pi({path:wp.url.addQueryArgs("/presto-player/v1/analytics/video/".concat(e,"/timeline"),{start:Pe(i),end:Pe(s)})}).then((function(t){var e=[];t.length&&t.forEach((function(t){e.push({x:t.watch_time,y:t.total})})),h([{name:"Viewers",data:e}])})).catch((function(t){console.error(t)})).finally((function(){o(!1)}))}),[i,s]);var d={options:{chart:{toolbar:{show:!1}},tickAmount:1,yaxis:{labels:{formatter:function(t){return parseInt(t)}}},xaxis:{labels:{formatter:function(t){return e=t,e=1e3*parseInt(e||0),new Date(e).toISOString().substr(11,8);var e}}},colors:["#7c3aed"],dataLabels:{enabled:!1},stroke:{curve:"smooth"},fill:{type:"gradient",gradient:{shadeIntensity:1,opacityFrom:.7,opacityTo:.9,stops:[0,90,100]}}}};return Kt(Is,null,n?Kt(Os,null,Kt(Ee,null)):Kt(Os,null,Kt("div",{className:"presto-card__title"},Ms("Audience Retention","presto-player")),Kt(fi.Z,{options:d.options,series:c,type:"area",height:280})))}),Ns=wp.i18n.__,Xs=wp.compose.compose,_s=wp.element.useEffect,Hs=Xs([ts()])((function(t){var e=t.video_id,i=t.startDate,a=t.endDate,s=t.stat,r=t.fetchData,n=t.loading;return _s((function(){r({endpoint:"/presto-player/v1/analytics/video/".concat(e,"/views"),params:{start:Pe(i),end:Pe(a)}})}),[i,a]),Kt(Va,{loading:n,value:parseInt(s),title:Ns("Unique Views","presto-player")})})),Bs=function(t){return t.replace(/([A-Z])/g,(function(t){return"-".concat(t[0].toLowerCase())}))},Ws=function(t,e,i){var a=e.className||e.class,s=i.className||i.class,r=Gs(t),n=Gs(a?a.split(" "):[]),o=Gs(s?s.split(" "):[]),l=[];return r.forEach((function(t){n.has(t)?(l.push(t),n.delete(t)):o.has(t)||l.push(t)})),n.forEach((function(t){return l.push(t)})),l.join(" ")},js=function(t){if("undefined"==typeof document)return!0;var e="on"+t,i=e in document;if(!i){var a=document.createElement("div");a.setAttribute(e,"return;"),i="function"==typeof a[e]}return i},Vs=function(t,e,i){var a=t.__events||(t.__events={}),s=a[e];s&&t.removeEventListener(e,s),t.addEventListener(e,a[e]=function(t){i&&i.call(this,t)})},Gs=function(t){var e=new Map;return t.forEach((function(t){return e.set(t,t)})),e},Us=function(t,e){"function"==typeof t?t(e):null!=t&&(t.current=e)},qs=function(){for(var t=arguments.length,e=new Array(t),i=0;i<t;i++)e[i]=arguments[i];return function(t){e.forEach((function(e){Us(e,t)}))}};var Zs,$s=function(t,e,i,a){void 0!==a&&a();var n=t.toLowerCase().split("-").map((function(t){return t.charAt(0).toUpperCase()+t.slice(1)})).join(""),o=function(e){d(h,e);var a,o,c=(a=h,o=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}(),function(){var t,e=p(a);if(o){var i=p(this).constructor;t=Reflect.construct(e,arguments,i)}else t=e.apply(this,arguments);return u(this,t)});function h(t){var e;return s(this,h),(e=c.call(this,t)).setComponentElRef=function(t){e.componentEl=t},e}return l(h,[{key:"componentDidMount",value:function(){this.componentDidUpdate(this.props)}},{key:"componentDidUpdate",value:function(t){!function(t,e){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};if(t instanceof Element){var a=Ws(t.classList,e,i);""!==a&&(t.className=a),Object.keys(e).forEach((function(i){if("children"!==i&&"style"!==i&&"ref"!==i&&"class"!==i&&"className"!==i&&"forwardedRef"!==i)if(0===i.indexOf("on")&&i[2]===i[2].toUpperCase()){var a=i.substring(2),s=a[0].toLowerCase()+a.substring(1);js(s)||Vs(t,s,e[i])}else t[i]=e[i],"string"===r(e[i])&&t.setAttribute(Bs(i),e[i])}))}}(this.componentEl,this.props,t)}},{key:"render",value:function(){var e=this.props,a=e.children,s=e.forwardedRef,r=e.style,n=(e.className,e.ref,function(t,e){var i={};for(var a in t)Object.prototype.hasOwnProperty.call(t,a)&&e.indexOf(a)<0&&(i[a]=t[a]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols){var s=0;for(a=Object.getOwnPropertySymbols(t);s<a.length;s++)e.indexOf(a[s])<0&&Object.prototype.propertyIsEnumerable.call(t,a[s])&&(i[a[s]]=t[a[s]])}return i}(e,["children","forwardedRef","style","className","ref"])),o=Object.keys(n).reduce((function(t,e){if(0===e.indexOf("on")&&e[2]===e[2].toUpperCase()){var i=e.substring(2).toLowerCase();"undefined"!=typeof document&&js(i)&&(t[e]=n[e])}else t[e]=n[e];return t}),{});i&&(o=i(this.props,o));var l=Object.assign(Object.assign({},o),{ref:qs(s,this.setComponentElRef),style:r});return(0,T.createElement)(t,l,a)}}],[{key:"displayName",get:function(){return n}}]),h}(M().Component);return e&&(o.contextType=e),function(t,e){var i=function(e,i){return M().createElement(t,Object.assign({},e,{forwardedRef:i}))};return i.displayName=e,M().forwardRef(i)}(o,n)},Js=$s("presto-player"),Qs=$s("presto-search-bar-ui"),Ks=wp.element;function tr(t){if(t){if(t.match(/^(?:https?:\/\/)?(?:www\.)?(?:youtu\.be\/|youtube\.com\/(?:embed\/|v\/|watch\?v=|watch\?.+&v=))((\w|-){11})(?:\S+)?$/))return"youtube";if(t.match(/(https?:\/\/)?(www\.)?(player\.)?vimeo\.com\/([a-z]*\/)*([‌​0-9]{6,11})[?]?.*/))return"vimeo";if(t.indexOf("https://vz-")>-1&&t.indexOf("b-cdn.net")>-1)return"bunny";if(t.indexOf(".mp3")>-1)return"audio"}return"self-hosted"}function er(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),i.push.apply(i,a)}return i}function ir(t){for(var e=1;e<arguments.length;e++){var i=null!=arguments[e]?arguments[e]:{};e%2?er(Object(i),!0).forEach((function(e){f(t,e,i[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):er(Object(i)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(i,e))}))}return t}Ks.useRef,Ks.useEffect;var ar=wp.data.useSelect,sr=function(t){var e,i,a,s,r,n=t.src,o=t.classes,l=t.preset,c=t.branding,h=t.attributes,d=t.adminPreview,u=t.currentTime,p=t.preload,f=void 0===p?"metadata":p,g=t.overlays,x=t.type,m=h.chapters,b=h.mutedOverlay,v=h.mutedPreview,y=ar((function(t){var e;return null===(e=t("presto-player/player"))||void 0===e?void 0:e.youtube()})),w=ar((function(t){var e;return null===(e=t("presto-player/player"))||void 0===e?void 0:e.playerCSS()}));return Kt("div",{className:"wp-block-video presto-block-video",style:"audio"===x?ir(ir(ir({"--presto-player-border-radius":"".concat(null==l?void 0:l.border_radius,"px")},null!=l&&l.background_color?{"--plyr-audio-controls-background":l.background_color}:{"--plyr-audio-controls-background":null==c?void 0:c.color}),null!=l&&l.control_color?{"--plyr-audio-control-color":l.control_color,"--plyr-range-thumb-background":l.control_color,"--plyr-range-fill-background":l.control_color,"--plyr-audio-progress-buffered-background":function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,i=t.replace("#","");3===i.length&&(i=i[0]+i[0]+i[1]+i[1]+i[2]+i[2]);var a=parseInt(i.substring(0,2),16),s=parseInt(i.substring(2,4),16),r=parseInt(i.substring(4,6),16);return e>1&&e<=100&&(e/=100),"rgba("+a+","+s+","+r+","+e+")"}(l.control_color||(null==c?void 0:c.color)||"#00b3ff",.5)}:{"--plyr-audio-control-color":"#ffffff","--plyr-range-thumb-background":"#ffffff","--plyr-range-fill-background":"#ffffff"}),{},{"--plyr-range-thumb-shadow":"0px"}):ir(ir(ir({"--presto-player-border-radius":"".concat(null==l?void 0:l.border_radius,"px")},null!=l&&l.caption_background?{"--plyr-captions-background":l.caption_background}:{}),null!=c&&c.color?{"--plyr-color-main":c.color}:{}),{},{"--presto-player-email-border-radius":"".concat((null==l||null===(e=l.email_collection)||void 0===e?void 0:e.border_radius)||0,"px"),"--presto-player-logo-width":"".concat((null==c?void 0:c.logo_width)||75,"px")})},Kt(Js,{src:n,"data-css":w,classes:o,currentTime:u,overlays:g,isAdmin:!0,preload:f,preset:l,bunny:{thumbnail:null==h?void 0:h.previewThumbnail,preview:null==h?void 0:h.preview},youtube:{channelId:null==y?void 0:y.channel_id},tracks:!(null==l||!l.captions)&&[{kind:"captions",label:"English",srclang:"en",src:"/path/to/captions.en.vtt",default:!0}],branding:c,chapters:m,blockAttributes:h,poster:h.poster,provider:"audio"===x?"audio":tr(n),mediaTitle:h.title},Kt("div",{slot:"player-end"},!(null===(i=l.search)||void 0===i||!i.enabled)&&Kt(Qs,{css:Pa(Zs||(Zs=ue(["\n position: absolute;\n top: 15px;\n right: 23px;\n z-index: 1;\n "]))),placeholder:null===(a=l.search)||void 0===a?void 0:a.placeholder}),(null==v?void 0:v.enabled)&&(null==b?void 0:b.enabled)&&Kt("div",{className:"presto-player__overlay is-image",style:{position:"absolute",width:"".concat((null==b?void 0:b.width)||100,"%"),left:"".concat(100*((null==b||null===(s=b.focalPoint)||void 0===s?void 0:s.x)||.5),"%"),top:"".concat(100*((null==b||null===(r=b.focalPoint)||void 0===r?void 0:r.y)||.5),"%")}},Kt("img",{src:null==b?void 0:b.src,style:{transform:"translateX(-50%) translateY(-50%)"}})),d)))};function rr(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),i.push.apply(i,a)}return i}function nr(t){for(var e=1;e<arguments.length;e++){var i=null!=arguments[e]?arguments[e]:{};e%2?rr(Object(i),!0).forEach((function(e){f(t,e,i[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):rr(Object(i)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(i,e))}))}return t}var or=wp.i18n.__,lr=wp.components,cr=lr.Flex,hr=lr.FlexBlock,dr=lr.FlexItem,ur=lr.Spinner,pr=lr.Button,fr=lr.TextControl,gr=wp.element,xr=gr.useEffect,mr=gr.useState,br=wp.apiFetch,vr=function(t){var e,i,s,r=t.route,n=t.startDate,o=t.endDate,l=t.setStartDate,c=t.setEndDate,h=a(mr(!0),2),d=h[0],u=h[1],p=a(mr({}),2),f=p[0],g=p[1],x=a(mr(""),2),m=x[0],b=x[1],v=a(mr(null),2),y=v[0],w=v[1],A=a(mr(!1),2),S=A[0],C=A[1],P=function(){var t=fe(xe().mark((function t(){var e,i,a,s;return xe().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return u(!0),t.prev=1,t.next=4,br({url:"".concat(null===(e=prestoPlayer)||void 0===e?void 0:e.root).concat(null===(i=prestoPlayer)||void 0===i?void 0:i.prestoVersionString,"videos/").concat(null==r||null===(a=r.params)||void 0===a?void 0:a.id)});case 4:s=t.sent,g(s),w(null==s?void 0:s.title),t.next=12;break;case 9:t.prev=9,t.t0=t.catch(1),"rest_no_route"===t.t0.code&&b("Video Not Found");case 12:return t.prev=12,u(!1),t.finish(12);case 15:case"end":return t.stop()}}),t,null,[[1,9,12,15]])})));return function(){return t.apply(this,arguments)}}(),L=function(){var t=fe(xe().mark((function t(){var e,i;return xe().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return console.log("New Video title ".concat(y)),u(!0),t.prev=2,e=nr(nr({},f),{title:y}),t.next=6,wp.apiFetch({method:"POST",url:wp.url.addQueryArgs("".concat(prestoPlayer.root).concat(prestoPlayer.prestoVersionString,"videos/").concat(f.id),{_method:"PUT"}),data:e});case 6:if(i=t.sent){t.next=9;break}throw genericError;case 9:C(!1),g(i),t.next=16;break;case 13:t.prev=13,t.t0=t.catch(2),b(null!==t.t0&&void 0!==t.t0&&t.t0.message?t.t0.message:genericError);case 16:return t.prev=16,u(!1),t.finish(16);case 19:case"end":return t.stop()}}),t,null,[[2,13,16,19]])})));return function(){return t.apply(this,arguments)}}();return xr((function(){P()}),[]),m?Kt("div",{className:"presto-flow"},Kt(cr,null,Kt(hr,null,Kt("h2",null,m)))):Kt("div",{className:"presto-flow"},Kt(cr,null,Kt(hr,null,Kt(pr,{isSecondary:!0,onClick:function(){k.push("#/")}},"← ",or("Back to Dashboard","presto-player")))),Kt(cr,{wrap:!0},Kt(hr,null,d?Kt(ur,null):S?Kt("div",{className:"presto-inline-edit presto-inline-edit--editing"},Kt(fr,{className:"presto-inline-edit__input",type:"text",value:y,onChange:function(t){return w(t)}}),Kt(pr,{className:"presto-inline-edit__button",isPrimary:!0,onClick:L}," ","Save"," "),Kt(pr,{className:"presto-inline-edit__button",isSecondary:!0,onClick:function(){w(null==f?void 0:f.title),C(!1)}}," ","Cancel"," ")):Kt("div",{className:"presto-inline-edit"},Kt("h1",{className:"presto-dashboard__title presto-inline-edit__text"},null==f?void 0:f.title),Kt("button",{className:"presto-inline-edit__edit",onClick:function(){return C(!0)}},Kt("span",{className:"dashicon dashicons dashicons-edit"})))),Kt(dr,null,Kt(Ui,{startDate:n,setStartDate:l,endDate:o,setEndDate:c}))),Kt("div",{className:"presto-dashboard presto-flow"},Kt("div",{className:"presto-dashboard__row"},Kt("div",{className:"presto-dashboard__item is-large"},Kt(Hs,{video_id:null==r||null===(e=r.params)||void 0===e?void 0:e.id,startDate:n,endDate:o})),Kt("div",{className:"presto-dashboard__item"},!!Object.keys(f||{}).length&&Kt(sr,{src:null==f?void 0:f.src,attributes:{title:f.title},type:tr(f.src),preset:{"play-large":!0,play:!0,progress:!0,rewind:!0,"fast-forward":!0,"current-time":!0,background_color:"#8421cb",volume:!0,mute:!0,i18n:window.prestoPlayer.i18n}})),Kt("div",{className:"presto-dashboard__item"},Kt(Ds,{video_id:null==r||null===(i=r.params)||void 0===i?void 0:i.id,startDate:n,endDate:o}))),Kt("div",{className:"presto-dashboard__row"},Kt("div",{className:"presto-dashboard__item is-large"},Kt(Fs,{video_id:null==r||null===(s=r.params)||void 0===s?void 0:s.id,startDate:n,endDate:o})))))},yr={dashboard:{path:"/"},video:{path:"/video/:id"},user:{path:"/user/:id"}},wr=wp.element.useState;(0,wp.element.render)(Kt((function(){var t,e=function(){window.scrollTo(0,0)},i=a(wr(new Date(Date.now()-6048e5)),2),s=i[0],r=i[1],n=a(wr(new Date),2),o=n[0],l=n[1];return null!==(t=prestoPlayer)&&void 0!==t&&t.isPremium?Kt("div",{className:"presto-dashboard__content"},Kt(re,{routes:yr},Kt(ie,{path:yr.dashboard.path,onRoute:e},Kt(_a,{startDate:s,endDate:o,setStartDate:r,setEndDate:l})),Kt(ie,{path:yr.video.path,onRoute:e},Kt(vr,{startDate:s,endDate:o,setStartDate:r,setEndDate:l})),Kt(ie,{path:yr.user.path,onRoute:e},Kt(Ss,{startDate:s,endDate:o,setStartDate:r,setEndDate:l})))):Kt("div",{className:"presto-dashboard__content"},Kt(de,null))}),null),document.getElementById("presto-analytics-page"))}()}();
dist/analytics/admin-7f8d2917.css.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"sources":["webpack:///./src/admin/analytics/analytics.scss","webpack:///./src/admin/scss/admin.scss","webpack:///./src/admin/scss/datatable.scss","webpack:///./src/admin/analytics/scss/utility.scss","webpack:///./src/admin/analytics/scss/layout.scss","webpack:///./src/admin/analytics/scss/typography.scss","webpack:///./src/admin/analytics/scss/notices.scss","webpack:///./src/admin/analytics/scss/components.scss"],"names":[],"mappings":";;;;;;;;;;;;;;;;;AAAA,EACE,6CCCE,eAEA,iBAEF,2BACE,YACA,gBACA,iCACE,YAGJ,gDACE,iBAEF,0BACE,eACA,oBACA,uBACA,mBAEA,WACA,YACA,kBACA,YACA,WACA,WACA,6CAEA,gCACE,UACA,uDAGJ,6BACE,oBCpCJ,WACE,aACA,sBACA,gBACA,yBACA,uBACE,4BACA,6BAEA,YAEF,uBACE,yBACA,0BAEA,gBACA,YChBJ,iBACE,wCAEF,gBACE,aACA,mBACA,uBACA,iBAGF,mBACE,WACA,yBAGE,kDAEE,eAKF,mCACE,eACA,sCAGF,4CACE,yBAIJ,4CAEE,gBACA,eACA,6BAGF,qCACE,gBAGF,sBACE,cACA,yBACA,YACA,eACA,gBACA,yBACA,mBAOJ,+FAMI,uIAKE,cAIF,4BACE,kBACA,YACA,aAGF,sBACE,gBAGF,qCACE,mBAGF,sBAGE,yCACA,kBAEA,2BAGF,6BAEE,kBAEA,SACA,UACA,UACA,mBACA,mBAIA,yBACA,eALA,CAKA,CC3GJ,uBACE,eACA,iBAEA,aACA,eACA,mCACA,oBACA,8BAGF,wBACE,gBACA,+BACA,aAEA,0BACE,YAGF,iCACE,OAIJ,0BACE,gBACA,aACA,aACA,mBACA,8BAEF,wBACE,gBAEF,2BACE,cACA,wBAEF,wBACE,gBACA,iBACA,kBAGJ,wBAEI,uBACE,cAEF,wBACE,YCnDJ,yBACE,gBCFJ,uDACE,yBACA,UACA,WACA,YACA,WCJA,oBACE,YACA,eACA,WACA,gBAKF,kCACE,cACA,iBACA,mBACA,WACA,gBACA,oBAGF,iCACE,gBACA,kBACA,mBACA,aACA,aACA,mBACA,8BACA,4BAGF,+BACE,gBACA,gBAIJ,mCACE,gCAGF,cACE,qBACA,qDACA,0CACA,iBACA,cACA,mBACA,qBAGF,8CAEE,YPxCF,MACE,yCACA,mDACA,mDAGA,iCAGA,4CACA,oDACA,qCACA,0CACA,mCACA,qCACA,6CACA,6CACA,+EAIA,+EAIA,6DACA,yCACA,6CACA,4BACA,4BACA,iEACA,oCACA,oEACA,qCACA,iCACA,mEACA,+BACA,iEACA,sCACA,4CACA,qCACA,uEACA,wCACA,0EACA,wCACA,8CAGF,0BACE,aACA,mBACA,uBACA,kBAEA,6BACE,eACA,mBAIJ,2BACE,aACA,cACA,uCACA,WACA,gBACA,qBACA,eACA,qBAGF,kCACE,kBACA,MACA,OACA,QACA,SACA,aACA,mBACA,oBACA,WAGF,sBACE,kBAGF,YACE,cAEA,gEAEE,kBAGF,yHAGE,yBACA,gBACA,gBACA,SAIA,2DACE,kBACA,aACA,gBACA,YACA,gBAEA,+DACE,0CAMJ,uEACE,qBAIJ,+BACE,gBACA,YAEA,2FAEE,oBACA,qBACA,eACA,SACA,SACA,eACA,wBACA,gBACA,iCACA,YACA,mBACA,sBACA,iBACA,kBACA,cACA,mBAGF,6CACE,mBACA,uCACA,WACA,qBACA,iBAMJ,uBACE,2BAEF,0BACE,iBACA,WACA,aACA,mBACA,uBAEF,kEAEE,gBAGF,6BACE,kBACA,mBACA,mBACA,wCACA,SACA,WAEA,oCARF,6BASI,UAIJ,wDACE,mBAGF,qEAEE,mBACA,kSAGA,0BACA,eACA,sBACA,UACA,gBACA,WACA,qBACA,+DAIJ,kBACE,gB","file":"analytics/admin-7f8d2917.css","sourcesContent":["* {\n box-sizing: inherit;\n}\n\n@import \"../scss/admin.scss\";\n@import \"../scss/datatable.scss\";\n@import \"./scss/utility.scss\";\n@import \"./scss/layout.scss\";\n@import \"./scss/typography.scss\";\n@import \"./scss/notices.scss\";\n@import \"./scss/components.scss\";\n\n:root {\n --wp-admin-theme-color: #7c3aed !important;\n --wp-admin-theme-color-darker-10: #6127c7 !important;\n --wp-admin-theme-color-darker-20: #501ea5 !important;\n // --litepickerDayIsEndBg: var(--wp-admin-theme-color, #7c3aed);\n // --litepickerDayIsStartBg: var(--wp-admin-theme-color, #7c3aed);\n --litepickerDayIsInRange: #f3f3f3;\n // --litepickerDayIsTodayColor: var(--wp-admin-theme-color, #7c3aed);\n\n --litepicker-container-months-color-bg: #fff;\n --litepicker-container-months-box-shadow-color: #ddd;\n --litepicker-footer-color-bg: #fafafa;\n --litepicker-footer-box-shadow-color: #ddd;\n --litepicker-tooltip-color-bg: #fff;\n --litepicker-month-header-color: #333;\n --litepicker-button-prev-month-color: #9e9e9e;\n --litepicker-button-next-month-color: #9e9e9e;\n --litepicker-button-prev-month-color-hover: var(\n --wp-admin-theme-color,\n #7c3aed\n );\n --litepicker-button-next-month-color-hover: var(\n --wp-admin-theme-color,\n #7c3aed\n );\n --litepicker-month-width: calc(var(--litepicker-day-width) * 7);\n --litepicker-month-weekday-color: #9e9e9e;\n --litepicker-month-week-number-color: #9e9e9e;\n --litepicker-day-width: 38px;\n --litepicker-day-color: #333;\n --litepicker-day-color-hover: var(--wp-admin-theme-color, #7c3aed);\n --litepicker-is-today-color: #f44336;\n --litepicker-is-in-range-color: #7c3aed1f;\n --litepicker-is-locked-color: #9e9e9e;\n --litepicker-is-start-color: #fff;\n --litepicker-is-start-color-bg: var(--wp-admin-theme-color, #7c3aed);\n --litepicker-is-end-color: #fff;\n --litepicker-is-end-color-bg: var(--wp-admin-theme-color, #7c3aed);\n --litepicker-button-cancel-color: #fff;\n --litepicker-button-cancel-color-bg: #9e9e9e;\n --litepicker-button-apply-color: #fff;\n --litepicker-button-apply-color-bg: var(--wp-admin-theme-color, #7c3aed);\n --litepicker-button-reset-color: #909090;\n --litepicker-button-reset-color-hover: var(--wp-admin-theme-color, #7c3aed);\n --litepicker-highlighted-day-color: #333;\n --litepicker-highlighted-day-color-bg: #ffeb3b;\n}\n\n.presto-player__stat-card {\n display: flex;\n align-items: center;\n justify-content: center;\n text-align: center;\n\n h1 {\n font-size: 3rem;\n margin-bottom: 0.4em;\n }\n}\n\n.presto-options__pro-badge {\n margin: 0 4px;\n line-height: 1;\n background: var(--wp-admin-theme-color);\n color: white;\n padding: 3px 6px;\n border-radius: 9999px;\n font-size: 10px;\n display: inline-block;\n}\n\n.presto-options__disabled-overlay {\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n display: flex;\n align-items: center;\n justify-self: center;\n z-index: 99;\n}\n\n.presto-options__card {\n position: relative;\n}\n\n.litepicker {\n font-size: 1em;\n\n .container__days > div,\n .container__days > a {\n margin-bottom: 5px;\n }\n\n .container__months,\n .container__footer,\n .container__main .container__predefined-ranges {\n border: 1px solid #e0e0e0;\n box-shadow: none;\n border-radius: 0;\n margin: 0;\n }\n\n .container__main {\n .container__predefined-ranges {\n margin-right: -1px;\n padding: 16px;\n max-width: 125px;\n width: 125px;\n border-radius: 0;\n\n > div {\n color: var(--wp-admin-theme-color, #007cba);\n }\n }\n }\n\n .container__months {\n .month-item-header div > .month-item-year {\n padding: 0 24px 0 8px;\n }\n }\n\n .container__footer {\n margin-top: -1px;\n padding: 8px;\n\n .button-cancel,\n .button-apply {\n display: inline-flex;\n text-decoration: none;\n font-size: 13px;\n margin: 0;\n border: 0;\n cursor: pointer;\n -webkit-appearance: none;\n background: none;\n transition: box-shadow 0.1s linear;\n height: 36px;\n align-items: center;\n box-sizing: border-box;\n padding: 6px 12px;\n border-radius: 2px;\n color: #1e1e1e;\n white-space: nowrap;\n }\n\n .button-apply {\n background: #007cba;\n background: var(--wp-admin-theme-color);\n color: #fff;\n text-decoration: none;\n text-shadow: none;\n }\n }\n}\n\n.presto-settings {\n &__page {\n margin: 25px 25px 25px auto;\n }\n &__loading {\n min-height: 200px;\n width: 100%;\n display: flex;\n align-items: center;\n justify-content: center;\n }\n &__setting,\n &__body .components-card {\n max-width: 800px;\n }\n\n &__navigation {\n margin-left: -20px;\n margin-right: -20px;\n padding-right: 20px;\n position: sticky;\n top: 32px;\n z-index: 99;\n\n @media screen and (max-width: 782px) {\n top: 46px;\n }\n }\n\n .components-snackbar.is-snackbar-error {\n background: #cc1818;\n }\n\n &__date-select,\n &__date-select:disabled {\n padding-right: 30px;\n background: #fff\n url(data:image/svg+xml;charset=US-ASCII,%3Csvg%20width%3D%2220%22%20height%3D%2220%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M5%206l5%205%205-5%202%201-7%207-7-7%202-1z%22%20fill%3D%22%23555%22%2F%3E%3C%2Fsvg%3E)\n no-repeat right 5px top 55%;\n background-size: 16px 16px;\n cursor: pointer;\n vertical-align: middle;\n opacity: 1;\n box-shadow: none;\n color: #444;\n border-color: #757575;\n user-select: none;\n }\n}\n\n.is-color-control {\n max-width: 250px;\n}\n",".presto-inline-edit {\n &__text {\n display: inline;\n margin: 0;\n margin-right: 8px;\n }\n &__input {\n flex-grow: 1;\n max-width: 640px;\n input {\n height: 36px;\n }\n }\n .presto-inline-edit__button {\n margin-right: 4px;\n }\n &__edit {\n cursor: pointer;\n display: inline-flex;\n justify-content: center;\n align-items: center;\n\n width: 28px;\n height: 28px;\n border-radius: 50%;\n border: none;\n opacity: 0.5;\n color: #fff;\n background-color: var(--wp-admin-theme-color);\n\n &:hover {\n opacity: 1;\n background-color: var(--wp-admin-theme-color-darker-10);\n }\n }\n &--editing {\n align-items: stretch;\n }\n}\n",".datatable {\n display: flex;\n flex-direction: column;\n background: #fff;\n border: 1px solid rgb(226, 228, 231);\n .table-card {\n border-bottom-left-radius: 0;\n border-bottom-right-radius: 0;\n border-bottom: none;\n border: none;\n }\n .pagination {\n border-top-left-radius: 0;\n border-top-right-radius: 0;\n border-top: none;\n margin-top: auto;\n border: none;\n }\n}\n",".presto-flow > * + * {\n margin-top: var(--presto-flow-space, 2em);\n}\n.presto-loading {\n display: flex;\n align-items: center;\n justify-content: center;\n min-height: 100px;\n}\n\ntable.presto-table {\n width: 100%;\n border-collapse: collapse;\n\n td {\n h2,\n h3 {\n margin: 0 0 8px 0;\n }\n }\n\n &.is-clickable {\n td {\n cursor: pointer;\n transition: background-color 0.25s ease;\n }\n\n tr:hover td {\n background-color: #f3f3f3;\n }\n }\n\n th,\n td {\n text-align: left;\n padding: 0.65rem;\n border-top: 1px solid rgb(226, 228, 231);\n }\n\n tr:first-child td {\n border-top: none;\n }\n\n th {\n color: #757575;\n background-color: #f7f7f7;\n border: none;\n font-size: 10px;\n font-weight: bold;\n text-transform: uppercase;\n letter-spacing: 1px;\n }\n}\n\n/*\n\tMax width before this PARTICULAR table gets nasty. This query will take effect for any screen smaller than 760px and also iPads specifically.\n\t*/\n@media only screen and (max-width: 760px),\n (min-device-width: 768px) and (max-device-width: 1024px) {\n table.presto-table {\n display: block;\n\n /* Force table to not be like tables anymore */\n thead,\n tbody,\n th,\n td,\n tr {\n display: block;\n }\n\n /* Hide table headers (but not display: none;, for accessibility) */\n thead tr {\n position: absolute;\n top: -9999px;\n left: -9999px;\n }\n\n tr {\n margin: 0 0 1rem 0;\n }\n\n tr:nth-child(odd) {\n background: #f3f3f3;\n }\n\n td {\n /* Behave like a \"row\" */\n border: none;\n border-bottom: 1px solid #fff;\n position: relative;\n padding: 10px;\n padding-left: 50%;\n }\n\n td:before {\n /* Now like a table header */\n position: absolute;\n /* Top/left values mimic padding */\n top: 10px;\n left: 10px;\n width: 45%;\n padding-right: 10px;\n white-space: nowrap;\n }\n\n td:before {\n content: attr(data-title);\n font-weight: bold;\n }\n }\n}\n",".presto-dashboard {\n &__row {\n --spacing: 1rem;\n --column-count: 2;\n\n display: flex;\n flex-wrap: wrap;\n margin: 0 calc(var(--spacing) * -0.5);\n align-items: stretch;\n justify-content: space-between;\n }\n\n &__item {\n flex: 0 1 33.33%;\n padding: calc(var(--spacing) / 3);\n width: 33.33%;\n\n > * {\n height: 100%;\n }\n\n &.is-large {\n flex: 1;\n }\n }\n\n &__header {\n background: #fff;\n padding: 20px;\n display: flex;\n align-items: center;\n justify-content: space-between;\n }\n &__logo {\n max-width: 175px;\n }\n &__content {\n margin: 25px 0;\n width: calc(100% - 20px);\n }\n &__body {\n max-width: 800px;\n margin-left: auto;\n margin-right: auto;\n }\n}\n@media (max-width: 767px) {\n .presto-dashboard {\n &__row {\n display: block;\n }\n &__item {\n width: 100%;\n }\n }\n}\n",".presto-dashboard {\n &__title {\n line-height: 1em;\n }\n}\n",".presto-settings-page-notices.components-snackbar-list {\n position: fixed !important;\n left: auto;\n right: 40px;\n bottom: 40px;\n width: auto;\n}\n",".presto-card {\n &__title {\n opacity: 0.75;\n font-size: 1rem;\n clear: both;\n margin: 0.75rem 0;\n }\n}\n\n.presto-player-dashboard {\n &__version {\n line-height: 1;\n padding: 6px 12px;\n background: #f1f1f1;\n color: #666;\n font-weight: 500;\n border-radius: 999px;\n }\n\n &__header {\n background: #fff;\n margin-left: -20px;\n margin-right: -20px;\n padding: 20px;\n display: flex;\n align-items: center;\n justify-content: space-between;\n max-width: calc(100% + 20px);\n }\n\n &__logo {\n max-height: 30px;\n max-width: 200px;\n }\n}\n\n.presto-module-tabs [role=\"tablist\"] {\n border-bottom: 1px solid rgb(226, 228, 231);\n}\n\n.presto-badge {\n border-radius: 9999px;\n border: 1px solid var(--wp-admin-theme-color, #007cba);\n color: var(--wp-admin-theme-color, #007cba);\n padding: 5px 10px;\n line-height: 1;\n white-space: nowrap;\n display: inline-block;\n}\n\n.apexcharts-xaxis text,\n.apexcharts-yaxis text {\n opacity: 0.35;\n}\n"],"sourceRoot":""}
 
dist/analytics/admin-9ff30d14.js DELETED
@@ -1,19 +0,0 @@
1
- /*!
2
- *
3
- * Presto Player
4
- *
5
- * @author Presto Made, Inc
6
- * @version 0.1.0
7
- * @link undefined
8
- * @license GPL
9
- *
10
- * Copyright (c) 2022 Presto Made, Inc
11
- *
12
- * This software is released under the GPL License
13
- * https://opensource.org/licenses/GPL
14
- *
15
- * Compiled with the help of https://wpack.io
16
- * A zero setup Webpack Bundler Script for WordPress
17
- */
18
- (window.wpackioprestoPlayeranalyticsJsonp=window.wpackioprestoPlayeranalyticsJsonp||[]).push([[0],{24:function(e,t){e.exports=window.wp.element},27:function(e,t){e.exports=window.wp.apiFetch},28:function(e,t){e.exports=window.wp.components},35:function(e,t,a){a(36),e.exports=a(49)},49:function(e,t,a){"use strict";a.r(t);var r=a(1),n=a(20),c=a(21),l=a(12),o=a(22),i=a(23),s=a(16),p=a(4),u=a(24),d=a(25),f=a.n(d);function m(e){return{path:e.pathname,hash:e.hash,query:f.a.parse(e.search)}}var b=a(32),h=Object(b.a)(),y=wp.element.createContext({route:m(h.location)}),v=a(8),w=wp.element.useContext,g="";function E(e){var t=e.path,a=e.onRoute,r=e.children,n=w(y).route,c=Object(v.a)("".concat(t))("".concat(n.hash.substr(1)));return c?(a&&(g!==c.path&&a(),g=c.path),React.createElement("div",null,wp.element.cloneElement(r,{route:c}))):null}var R=a(14),O=a.n(R);wp.element.useContext;function j(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var a,r=Object(s.a)(e);if(t){var n=Object(s.a)(this).constructor;a=Reflect.construct(r,arguments,n)}else a=r.apply(this,arguments);return Object(i.a)(this,a)}}var x=function(e){Object(o.a)(a,e);var t=j(a);function a(e){var r;Object(n.a)(this,a),r=t.call(this,e),Object(p.a)(Object(l.a)(r),"handleRouteChange",(function(e){var t=m(null==e?void 0:e.location);r.setState({route:t})})),r.routes=Object.keys(e.routes).map((function(t){return e.routes[t].path})),r.unlisten=h.listen(r.handleRouteChange);var c=m(h.location),o=h.location.search;return r.state={route:c,defaultRoute:null!=e&&e.defaultRoute?"".concat(o,"#").concat(null==e?void 0:e.defaultRoute):"".concat(o,"#/")},r}return Object(c.a)(a,[{key:"componentWillUnmount",value:function(){this.unlisten()}},{key:"render",value:function(){var e=this.props,t=e.children,a=(e.NotFound,this.state),r=a.route,n=a.defaultRoute;if(!r.hash)return h.push(n),React.createElement("div",null);var c=!1;(this.routes||[]).forEach((function(e){var t=Object(v.a)(r.hash.substr(1))("".concat(r.hash.substr(1)));t&&(c={name:e,data:t})}));var l={route:r,matched:c},o=!c;return React.createElement(y.Provider,{value:l},o?React.createElement("div",null,"Not found"):t)}}]),a}(u.Component),_=function(e){var t=e.width,a=e.height;return React.createElement("svg",{id:"e8f68bdd-4984-4f2e-95b7-7fc8ec281257","data-name":"Layer 1",width:t,height:a,xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink",viewBox:"0 0 918.14 765.54"},React.createElement("defs",null,React.createElement("linearGradient",{id:"27aa7b70-b106-4a00-be67-693c8380e41d",x1:"397.74",y1:"717.25",x2:"397.74",y2:"86.11",gradientUnits:"userSpaceOnUse"},React.createElement("stop",{offset:"0","stop-color":"gray","stop-opacity":"0.25"}),React.createElement("stop",{offset:"0.54","stop-color":"gray","stop-opacity":"0.12"}),React.createElement("stop",{offset:"1","stop-color":"gray","stop-opacity":"0.1"})),React.createElement("linearGradient",{id:"46a816da-c484-41ec-8a6f-fbf14454d910",x1:"288.88",y1:"378.44",x2:"288.88",y2:"209.65",xlinkHref:"#27aa7b70-b106-4a00-be67-693c8380e41d"}),React.createElement("linearGradient",{id:"32b634d8-28f1-48d9-a868-f602a2cad942",x1:"288.88",y1:"328.29",x2:"288.88",y2:"223.1",xlinkHref:"#27aa7b70-b106-4a00-be67-693c8380e41d"}),React.createElement("clipPath",{id:"7a4c6aff-0be0-461b-a111-b3ae1b8fbf73",transform:"translate(-140.93 -67.23)"},React.createElement("rect",{id:"8cc91f6d-19b0-43cc-9c18-2faa83ac34ba","data-name":"<Rectangle>",x:"354.51",y:"291.55",width:"150.6",height:"101.52",fill:"#fff"})),React.createElement("linearGradient",{id:"38f1cb81-8fac-4205-a0ff-a33ac00d354c",x1:"288.88",y1:"594.94",x2:"288.88",y2:"426.14",xlinkHref:"#27aa7b70-b106-4a00-be67-693c8380e41d"}),React.createElement("linearGradient",{id:"6fc01aaf-135e-403e-a209-43b2a4fe59f1",x1:"288.88",y1:"544.79",x2:"288.88",y2:"439.6",xlinkHref:"#27aa7b70-b106-4a00-be67-693c8380e41d"}),React.createElement("clipPath",{id:"79ce363a-d134-40e4-9f82-b96d04a36978",transform:"translate(-140.93 -67.23)"},React.createElement("rect",{id:"5b44e697-61fe-43bd-9a58-5f3e41301748","data-name":"<Rectangle>",x:"354.51",y:"508.05",width:"150.6",height:"101.52",fill:"#fff"})),React.createElement("linearGradient",{id:"54803c44-522d-4b9e-9a34-f1f7b43e8483",x1:"671.57",y1:"760.34",x2:"671.57",y2:"129.2",gradientTransform:"translate(1109.43 -194.1) rotate(90)",xlinkHref:"#27aa7b70-b106-4a00-be67-693c8380e41d"}),React.createElement("linearGradient",{id:"089a6a47-adaa-499b-aefb-cd6464b62fb8",x1:"670.96",y1:"553.63",x2:"670.96",y2:"387.28",gradientTransform:"translate(1129.51 -168.41) rotate(90)",xlinkHref:"#27aa7b70-b106-4a00-be67-693c8380e41d"}),React.createElement("linearGradient",{id:"fd8d88e0-7826-450d-9e0b-001d1be709c2",x1:"637.66",y1:"754.12",x2:"637.66",y2:"601.05",xlinkHref:"#27aa7b70-b106-4a00-be67-693c8380e41d"}),React.createElement("linearGradient",{id:"8d1793c5-b76e-44e2-a52e-569460402331",x1:"778.37",y1:"673.86",x2:"778.37",y2:"569.13",xlinkHref:"#27aa7b70-b106-4a00-be67-693c8380e41d"}),React.createElement("linearGradient",{id:"4745700d-8097-45ff-9f71-625443fc4ad8",x1:"778.37",y1:"774.41",x2:"778.37",y2:"713.66",xlinkHref:"#27aa7b70-b106-4a00-be67-693c8380e41d"})),React.createElement("title",null,"secure data"),React.createElement("g",{opacity:"0.5"},React.createElement("rect",{x:"162.9",y:"86.11",width:"469.69",height:"631.14",fill:"url(#27aa7b70-b106-4a00-be67-693c8380e41d)"})),React.createElement("rect",{x:"169.02",y:"94.67",width:"455.01",height:"609.12",fill:"#f2f2f2"}),React.createElement("rect",{x:"204.49",y:"120.36",width:"156.56",height:"4.89",fill:"#e0e0e0"}),React.createElement("rect",{x:"204.49",y:"142.37",width:"156.56",height:"4.89",fill:"#6c63ff",opacity:"0.7"}),React.createElement("rect",{x:"384.29",y:"120.36",width:"156.56",height:"4.89",fill:"#e0e0e0"}),React.createElement("rect",{x:"408.75",y:"259.8",width:"156.56",height:"4.89",fill:"#e0e0e0"}),React.createElement("rect",{x:"412.42",y:"273.25",width:"156.56",height:"4.89",fill:"#e0e0e0"}),React.createElement("rect",{x:"419.76",y:"286.7",width:"156.56",height:"4.89",fill:"#e0e0e0"}),React.createElement("rect",{x:"408.75",y:"476.29",width:"156.56",height:"4.89",fill:"#e0e0e0"}),React.createElement("rect",{x:"412.42",y:"489.75",width:"156.56",height:"4.89",fill:"#e0e0e0"}),React.createElement("rect",{x:"419.76",y:"503.2",width:"156.56",height:"4.89",fill:"#e0e0e0"}),React.createElement("g",{opacity:"0.5"},React.createElement("rect",{x:"205.71",y:"209.65",width:"166.35",height:"168.79",fill:"url(#46a816da-c484-41ec-8a6f-fbf14454d910)"})),React.createElement("rect",{x:"206.76",y:"213.32",width:"163.72",height:"161.45",fill:"#f5f5f5"}),React.createElement("g",{opacity:"0.5"},React.createElement("rect",{x:"212.53",y:"223.1",width:"152.7",height:"105.19",fill:"url(#32b634d8-28f1-48d9-a868-f602a2cad942)"})),React.createElement("rect",{id:"689f37f3-cc41-448d-b172-63ec123bc985","data-name":"<Rectangle>",x:"213.58",y:"224.32",width:"150.6",height:"101.52",fill:"#fff"}),React.createElement("g",{"clip-path":"url(#7a4c6aff-0be0-461b-a111-b3ae1b8fbf73)"},React.createElement("polygon",{points:"200.82 322.18 238.74 263.46 254.64 289.15 288.88 253.68 318.24 289.15 343.93 236.56 409.98 341.75 195.93 334.41 200.82 322.18",fill:"#6c63ff",opacity:"0.4"}),React.createElement("circle",{cx:"230.17",cy:"239",r:"11.01",fill:"#6c63ff",opacity:"0.4"})),React.createElement("g",{opacity:"0.5"},React.createElement("rect",{x:"205.71",y:"426.14",width:"166.35",height:"168.79",fill:"url(#38f1cb81-8fac-4205-a0ff-a33ac00d354c)"})),React.createElement("rect",{x:"206.76",y:"429.81",width:"163.72",height:"161.45",fill:"#f5f5f5"}),React.createElement("g",{opacity:"0.5"},React.createElement("rect",{x:"212.53",y:"439.6",width:"152.7",height:"105.19",fill:"url(#6fc01aaf-135e-403e-a209-43b2a4fe59f1)"})),React.createElement("rect",{id:"b429ac3a-f8a8-4171-bcce-5b6c002c0714","data-name":"<Rectangle>",x:"213.58",y:"440.82",width:"150.6",height:"101.52",fill:"#fff"}),React.createElement("g",{"clip-path":"url(#79ce363a-d134-40e4-9f82-b96d04a36978)"},React.createElement("polygon",{points:"200.82 538.67 238.74 479.96 254.64 505.65 288.88 470.18 318.24 505.65 343.93 453.05 409.98 558.24 195.93 550.9 200.82 538.67",fill:"#bdbdbd",opacity:"0.4"}),React.createElement("circle",{cx:"230.17",cy:"455.5",r:"11.01",fill:"#bdbdbd",opacity:"0.4"})),React.createElement("g",{opacity:"0.5"},React.createElement("rect",{x:"349.09",y:"242.63",width:"631.14",height:"469.69",transform:"translate(-74.16 969.06) rotate(-78.76)",fill:"url(#54803c44-522d-4b9e-9a34-f1f7b43e8483)"})),React.createElement("rect",{x:"359.37",y:"247.33",width:"609.12",height:"455.01",transform:"translate(-72.16 966.22) rotate(-78.76)",fill:"#fff"}),React.createElement("rect",{x:"523.5",y:"197.22",width:"322.91",height:"4.89",transform:"translate(-88.86 -196.94) rotate(11.24)",fill:"#e0e0e0"}),React.createElement("rect",{x:"433.36",y:"650.7",width:"322.91",height:"4.89",transform:"translate(-2.18 -170.66) rotate(11.24)",fill:"#e0e0e0"}),React.createElement("rect",{x:"428.58",y:"671.14",width:"249.52",height:"4.89",transform:"translate(1.01 -162.18) rotate(11.24)",fill:"#e0e0e0"}),React.createElement("rect",{x:"424.6",y:"683.47",width:"92.96",height:"4.89",transform:"translate(1.84 -145.91) rotate(11.24)",fill:"#6c63ff",opacity:"0.7"}),React.createElement("rect",{x:"519.57",y:"209.08",width:"161.45",height:"4.89",transform:"translate(-88.17 -180.2) rotate(11.24)",fill:"#6c63ff",opacity:"0.7"}),React.createElement("rect",{x:"512.84",y:"249.31",width:"291.11",height:"4.89",transform:"translate(-79.21 -190.76) rotate(11.24)",fill:"#e0e0e0"}),React.createElement("rect",{x:"509.47",y:"255.44",width:"70.94",height:"4.89",transform:"translate(-80.19 -168.52) rotate(11.24)",fill:"#3ad29f",opacity:"0.7"}),React.createElement("rect",{x:"501.56",y:"307.59",width:"322.91",height:"4.89",transform:"translate(-67.76 -190.54) rotate(11.24)",fill:"#e0e0e0"}),React.createElement("g",{opacity:"0.5"},React.createElement("rect",{x:"575.87",y:"357.6",width:"166.35",height:"289.88",transform:"translate(-103.27 983.74) rotate(-78.76)",fill:"url(#089a6a47-adaa-499b-aefb-cd6464b62fb8)"})),React.createElement("rect",{x:"516.06",y:"420.61",width:"286.22",height:"162.68",transform:"translate(-30.42 -186.11) rotate(11.24)",fill:"#fff"}),React.createElement("rect",{x:"496.08",y:"335.18",width:"322.91",height:"4.89",transform:"translate(-62.49 -188.94) rotate(11.24)",fill:"#e0e0e0"}),React.createElement("rect",{x:"547.86",y:"424.02",width:"35.47",height:"118.64",transform:"translate(-35.84 -168.22) rotate(11.24)",fill:"#6c63ff"}),React.createElement("rect",{x:"606.43",y:"475.19",width:"35.47",height:"79.5",transform:"translate(-28.56 -179.03) rotate(11.24)",fill:"#3ad29f"}),React.createElement("rect",{x:"665.23",y:"523.93",width:"35.47",height:"42.81",transform:"translate(-21.5 -189.92) rotate(11.24)",fill:"#f55f44"}),React.createElement("rect",{x:"731.91",y:"492.72",width:"35.47",height:"86.84",transform:"translate(-22.02 -203.09) rotate(11.24)",fill:"#fdd835"}),React.createElement("g",{opacity:"0.5"},React.createElement("rect",{x:"128.65",y:"645.09",width:"3.67",height:"20.79",fill:"#47e6b1"}),React.createElement("rect",{x:"269.58",y:"712.31",width:"3.67",height:"20.79",transform:"translate(853.2 384.07) rotate(90)",fill:"#47e6b1"})),React.createElement("path",{d:"M699.44,75.56a4.49,4.49,0,0,1-2.5-5.43,2.16,2.16,0,0,0,.1-.5h0a2.25,2.25,0,0,0-4-1.49h0a2.16,2.16,0,0,0-.25.44,4.49,4.49,0,0,1-5.43,2.5,2.16,2.16,0,0,0-.5-.1h0a2.25,2.25,0,0,0-1.49,4h0a2.16,2.16,0,0,0,.44.25,4.49,4.49,0,0,1,2.5,5.43,2.16,2.16,0,0,0-.1.5h0a2.25,2.25,0,0,0,4,1.49h0a2.16,2.16,0,0,0,.25-.44,4.49,4.49,0,0,1,5.43-2.5,2.16,2.16,0,0,0,.5.1h0a2.25,2.25,0,0,0,1.49-4h0A2.16,2.16,0,0,0,699.44,75.56Z",transform:"translate(-140.93 -67.23)",fill:"#4d8af0",opacity:"0.5"}),React.createElement("path",{d:"M286.33,179.4a4.49,4.49,0,0,1-2.5-5.43,2.16,2.16,0,0,0,.1-.5h0a2.25,2.25,0,0,0-4-1.49h0a2.16,2.16,0,0,0-.25.44,4.49,4.49,0,0,1-5.43,2.5,2.16,2.16,0,0,0-.5-.1h0a2.25,2.25,0,0,0-1.49,4h0a2.16,2.16,0,0,0,.44.25,4.49,4.49,0,0,1,2.5,5.43,2.16,2.16,0,0,0-.1.5h0a2.25,2.25,0,0,0,4,1.49h0a2.16,2.16,0,0,0,.25-.44,4.49,4.49,0,0,1,5.43-2.5,2.16,2.16,0,0,0,.5.1h0a2.25,2.25,0,0,0,1.49-4h0A2.16,2.16,0,0,0,286.33,179.4Z",transform:"translate(-140.93 -67.23)",fill:"#fdd835",opacity:"0.5"}),React.createElement("path",{d:"M253.63,484.46a4.49,4.49,0,0,1-2.5-5.43,2.16,2.16,0,0,0,.1-.5h0a2.25,2.25,0,0,0-4-1.49h0a2.16,2.16,0,0,0-.25.44,4.49,4.49,0,0,1-5.43,2.5,2.16,2.16,0,0,0-.5-.1h0a2.25,2.25,0,0,0-1.49,4h0a2.16,2.16,0,0,0,.44.25,4.49,4.49,0,0,1,2.5,5.43,2.16,2.16,0,0,0-.1.5h0a2.25,2.25,0,0,0,4,1.49h0a2.16,2.16,0,0,0,.25-.44,4.49,4.49,0,0,1,5.43-2.5,2.16,2.16,0,0,0,.5.1h0a2.25,2.25,0,0,0,1.49-4h0A2.16,2.16,0,0,0,253.63,484.46Z",transform:"translate(-140.93 -67.23)",fill:"#fdd835",opacity:"0.5"}),React.createElement("circle",{cx:"337.81",cy:"28.62",r:"7.34",fill:"#f55f44",opacity:"0.5"}),React.createElement("circle",{cx:"7.34",cy:"317.46",r:"7.34",fill:"#f55f44",opacity:"0.5"}),React.createElement("circle",{cx:"863.76",cy:"120.36",r:"7.34",fill:"#f55f44",opacity:"0.5"}),React.createElement("circle",{cx:"822.17",cy:"339.3",r:"7.34",fill:"#4d8af0",opacity:"0.5"}),React.createElement("circle",{cx:"37.68",cy:"145.22",r:"7.34",fill:"#47e6b1",opacity:"0.5"}),React.createElement("circle",{cx:"853.29",cy:"647.34",r:"7.34",fill:"#47e6b1",opacity:"0.5"}),React.createElement("circle",{cx:"910.8",cy:"430.97",r:"7.34",fill:"#47e6b1",opacity:"0.5"}),React.createElement("rect",{x:"544.42",y:"601.05",width:"186.48",height:"153.07",fill:"url(#fd8d88e0-7826-450d-9e0b-001d1be709c2)"}),React.createElement("path",{d:"M723.82,639a54.55,54.55,0,0,1,109.1,0v34.91h15.27V639a69.82,69.82,0,0,0-139.65,0v34.91h15.27Z",transform:"translate(-140.93 -67.23)",fill:"url(#8d1793c5-b76e-44e2-a52e-569460402331)"}),React.createElement("path",{d:"M726,638.25a52.37,52.37,0,1,1,104.74,0v33.52H845.4V638.25a67,67,0,0,0-134.06,0v33.52H726Z",transform:"translate(-140.93 -67.23)",fill:"#f5f5f5"}),React.createElement("rect",{x:"546.32",y:"602.45",width:"182.24",height:"148.73",fill:"#6c63ff"}),React.createElement("rect",{x:"546.32",y:"602.45",width:"182.24",height:"148.73",fill:"#f5f5f5"}),React.createElement("rect",{x:"546.32",y:"631.77",width:"182.24",height:"90.07",fill:"#6c63ff"}),React.createElement("path",{d:"M791.73,727a13.36,13.36,0,1,0-23.08,9.15v28.51a9.72,9.72,0,0,0,19.44,0V736.18A13.3,13.3,0,0,0,791.73,727Z",transform:"translate(-140.93 -67.23)",fill:"url(#4745700d-8097-45ff-9f71-625443fc4ad8)"}),React.createElement("path",{d:"M789.89,729.38a11.52,11.52,0,1,0-19.9,7.89v24.58a8.38,8.38,0,1,0,16.76,0V737.27A11.47,11.47,0,0,0,789.89,729.38Z",transform:"translate(-140.93 -67.23)",opacity:"0.2"}))},D=wp.i18n.__,P=wp.components,k=P.Flex,N=P.FlexItem,S=P.FlexBlock,C=function(){return React.createElement(k,{style:{padding:"30px",background:"#fff"}},React.createElement(N,null,React.createElement(_,{width:"250px"})),React.createElement(S,{style:{marginLeft:"20px"}},React.createElement("h1",null,D("Get detailed video insights.","presto-player")),React.createElement("p",null,D("Upgrade to Pro and get video insights like plays, watch-time, and drop off numbers.","presto-player")),React.createElement("a",{href:"https://prestoplayer.com",target:"_blank",className:"button button-primary"},D("Learn More","presto-player"))))},F=a(10),T=a(5),M=a(3),I=a.n(M);function B(e,t){var a=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a.push.apply(a,r)}return a}function A(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?B(Object(a),!0).forEach((function(t){Object(p.a)(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):B(Object(a)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}wp.i18n.__;var V=wp.apiFetch,H=wp.element.useState,L=wp.compose.createHigherOrderComponent,U=function(){return L((function(e){return function(t){var a=H(!1),n=Object(r.a)(a,2),c=n[0],l=n[1],o=H(1),i=Object(r.a)(o,2),s=i[0],p=i[1],u=H(0),d=Object(r.a)(u,2),f=d[0],m=d[1],b=H(0),h=Object(r.a)(b,2),y=h[0],v=h[1],w=H([]),g=Object(r.a)(w,2),E=g[0],R=g[1],O=H(""),j=Object(r.a)(O,2),x=j[0],_=j[1],D=function(){var e=Object(T.a)(I.a.mark((function e(t){var a,r,n,c;return I.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return a=t.endpoint,r=t.params,n=void 0===r?{}:r,l(!0),e.prev=2,e.next=5,V({path:wp.url.addQueryArgs(a,A({page:s,per_page:5},n)),parse:!1}).then((function(e){var t=e.headers?parseInt(e.headers.get("X-WP-Total")):0,a=e.headers?parseInt(e.headers.get("X-WP-TotalPages")):0;return m(t),v(a),e.json()}));case 5:c=e.sent,R(c),e.next=13;break;case 9:e.prev=9,e.t0=e.catch(2),console.error(e.t0),null!==e.t0&&void 0!==e.t0&&e.t0.message&&_(e.t0.message);case 13:return e.prev=13,l(!1),e.finish(13);case 16:case"end":return e.stop()}}),e,null,[[2,9,13,16]])})));return function(t){return e.apply(this,arguments)}}();return React.createElement(e,Object.assign({loading:c,setLoading:l,fetchData:D,page:s,setPage:p,total:f,setTotal:m,totalPages:y,setTotalPages:v,data:E,setData:R,error:x,setError:_},t))}}),"withDataList")},G=wp.i18n,W=G.__,Z=G.sprintf,z=function(e){var t=(new Date).getTimezoneOffset();return new Date(e.getTime()-60*t*1e3).toISOString().split("T")[0]+"T00:00:00.000Z"},Y=wp.components,Q=Y.Spinner,X=Y.Flex,q=Y.FlexItem,J=function(e){var t=e.height,a=void 0===t?100:t;return React.createElement(X,{style:{height:"".concat(a,"px")},align:"center",justify:"center"},React.createElement(q,null,React.createElement(Q,null)))},$=wp.i18n.__,K=wp.components,ee=K.Card,te=K.CardBody,ae=K.Flex,re=K.FlexBlock,ne=K.Button,ce=K.ButtonGroup,le=wp.element,oe=le.useState,ie=le.useEffect,se=function(e){var t=e.page,a=e.setPage,n=e.perPage,c=e.total,l=e.totalPages,o=oe(!1),i=Object(r.a)(o,2),s=i[0],p=i[1],u=oe(!1),d=Object(r.a)(u,2),f=d[0],m=d[1],b=oe(0),h=Object(r.a)(b,2),y=h[0],v=h[1],w=oe(0),g=Object(r.a)(w,2),E=g[0],R=g[1];ie((function(){v(Math.min(n*t,c)),R(n*(t-1)+1)}),[n,t,c]);return ie((function(){p(t-1>0),m(l>=t+1)}),[t,l]),React.createElement(ee,{size:"large",className:"presto-card pagination"},React.createElement(te,{className:"presto-flow"},React.createElement(ae,null,React.createElement(re,null,sprintf($("Showing %1s to %2s of %3s","presto-player"),E,y,c)),React.createElement(re,null,React.createElement(ae,{justify:"flex-end"},React.createElement(ce,null,React.createElement(ne,{isSecondary:!0,disabled:!s,onClick:function(){a(Math.max(t-1,0))}},$("Previous","presto-player")),React.createElement(ne,{isSecondary:!0,disabled:!f,onClick:function(){a(Math.min(l,t+1))}},$("Next","presto-player"))))))))},pe=wp.i18n.__,ue=wp.element,de=(ue.useRef,ue.useEffect,ue.useState,wp.components),fe=de.Card,me=de.CardBody,be=(de.Flex,de.FlexBlock,de.Button,de.ButtonGroup,function(e){var t=e.columns,a=e.data,r=e.onRowClick,n=e.title;return a.length?React.createElement(fe,{size:"large",className:"presto-card table-card"},React.createElement(me,{className:"presto-flow"},React.createElement("div",{className:"presto-card__title"},n),React.createElement("table",{role:"table",className:O()("presto-table",{"is-clickable":r})},React.createElement("thead",{role:"rowgroup"},React.createElement("tr",{role:"row"},t&&t.map((function(e){return React.createElement("th",{key:e.key,role:"columnheader"},e.label)})))),React.createElement("tbody",{role:"rowgroup"},a.map((function(e,a){return React.createElement("tr",{role:"row",key:"row-".concat(a),onClick:function(){return r&&r(e)}},t.map((function(t,r){return React.createElement("td",{role:"cell","data-title":t.label,key:"row-".concat(a,"-").concat(r),"aria-label":t.label},t.render?t.render(e):React.createElement("div",null,t.value(e)))})))})))))):React.createElement(fe,{size:"large",className:"presto-card table-card"},React.createElement(me,{className:"presto-flow"},React.createElement("div",{className:"presto-card__title"},n),React.createElement("div",{style:{opacity:.65}},pe("No data available.","presto-player"))))}),he=wp.i18n.__,ye=wp.element,ve=(ye.useEffect,ye.useState,wp.components),we=ve.Card,ge=ve.CardBody,Ee=function(e){var t=e.perPage,a=void 0===t?10:t,r=e.title,n=e.page,c=e.setPage,l=e.loading,o=e.total,i=e.totalPages,s=e.columns,p=e.data,u=e.onSelect;return l?React.createElement(we,null,React.createElement(J,null)):null!=p&&p.length?React.createElement("div",{className:"datatable"},React.createElement(be,{data:p,columns:s,perPage:a,onRowClick:u,title:r}),!!o&&React.createElement(se,{page:n,setPage:c,perPage:a,total:o,totalPages:i})):React.createElement(we,{size:"large",className:"presto-card"},React.createElement(ge,{className:"presto-flow"},React.createElement("div",{className:"presto-card__title"},r),React.createElement("div",{style:{opacity:.65}},he("No data available.","presto-player"))))};function Re(e,t){var a=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a.push.apply(a,r)}return a}function Oe(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?Re(Object(a),!0).forEach((function(t){Object(p.a)(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):Re(Object(a)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}var je=wp.i18n.__,xe=wp.element.useEffect,_e=(0,wp.compose.compose)([U()])((function(e){var t=e.loading,a=e.page,r=e.setPage,n=e.total,c=e.totalPages,l=e.data,o=e.error,i=e.fetchData,s=e.startDate,p=e.endDate;xe((function(){i({endpoint:"/presto-player/v1/analytics/top-users",params:Oe(Oe({per_page:5},s?{start:z(s)}:{}),p?{end:z(p)}:{})})}),[a,s,p]);var u=[{key:"name",label:je("Name","presto-player"),value:function(e){var t;return null==e||null===(t=e.user)||void 0===t?void 0:t.name}},{key:"total_view",label:je("Total View","presto-player"),value:function(e){var t,a;return null==e||null===(t=e.stats)||void 0===t||null===(a=t[0])||void 0===a?void 0:a.data}},{key:"avg_view_time",label:je("Avg View Time","presto-player"),render:function(e){var t,a;return React.createElement("div",{className:"presto-badge"},null==e||null===(t=e.stats)||void 0===t||null===(a=t[1])||void 0===a?void 0:a.data)}}];return o?{error:o}:React.createElement(Ee,{title:je("Top Users","presto-player"),page:a,perPage:5,setPage:r,loading:t,total:n,totalPages:c,columns:u,data:l,onSelect:function(e){var t,a;return a=null==e||null===(t=e.user)||void 0===t?void 0:t.id,void h.push("#/user/".concat(a))}})}));function De(e,t){var a=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a.push.apply(a,r)}return a}function Pe(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?De(Object(a),!0).forEach((function(t){Object(p.a)(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):De(Object(a)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}var ke=wp.i18n.__,Ne=wp.element.useEffect,Se=(0,wp.compose.compose)([U()])((function(e){var t=e.loading,a=e.page,r=e.setPage,n=e.total,c=e.totalPages,l=e.data,o=e.error,i=e.fetchData,s=e.startDate,p=e.endDate,u=e.userId;Ne((function(){i({endpoint:"/presto-player/v1/analytics/top-videos",params:Pe(Pe(Pe({per_page:10},s?{start:z(s)}:{}),p?{end:z(p)}:{}),u?{user_id:u}:{})})}),[a,s,p]);var d=[{key:"name",label:ke("Name","presto-player"),render:function(e){return React.createElement("h3",{style:{marginBottom:0,wordBreak:"break-all"}},e.video.title?e.video.title:ke("Untitled","presto-player"))}},{key:"total_view",label:ke("Total View","presto-player"),value:function(e){return e.stats[0].data}},{key:"avg_view_time",label:ke("Avg View Time","presto-player"),render:function(e){return React.createElement("div",{className:"presto-badge"},e.stats[1].data)}},{key:"view_more",label:"",render:function(e){return React.createElement("span",{style:{color:"var(--wp-admin-theme-color, #007cba)"}},ke("View Details","presto-player")," →")}}];return o?{error:o}:React.createElement(Ee,{title:ke("Top Media","presto-player"),perPage:10,page:a,setPage:r,loading:t,total:n,totalPages:c,columns:d,data:l,onSelect:function(e){var t,a;a=null==e||null===(t=e.video)||void 0===t?void 0:t.id,h.push("#/video/".concat(a))}})})),Ce=wp.apiFetch;Ce.use(Ce.createNonceMiddleware(prestoPlayer.nonce)),Ce.use(Ce.createRootURLMiddleware(prestoPlayer.root+prestoPlayer.prestoVersionString));var Fe=Ce,Te=a(9),Me=a.n(Te);function Ie(e,t){var a=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a.push.apply(a,r)}return a}function Be(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?Ie(Object(a),!0).forEach((function(t){Object(p.a)(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):Ie(Object(a)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}var Ae,Ve=wp.i18n,He=Ve.__,Le=Ve.sprintf,Ue=wp.components,Ge=(Ue.Card,Ue.CardBody),We=wp.element,Ze=We.useState,ze=We.useEffect,Ye=(We.useRef,function(e){var t=Ze(!0),a=Object(r.a)(t,2),n=a[0],c=a[1],l=Ze(0),o=Object(r.a)(l,2),i=o[0],s=o[1],p=e.startDate,u=e.endDate,d=Ze([{name:"Views",data:[]}]),f=Object(r.a)(d,2),m=f[0],b=f[1],h={options:{chart:{toolbar:{show:!1}},yaxis:{min:0,labels:{formatter:function(e){return e<1?0:Math.abs(e)>999?Math.sign(e)*(Math.abs(e)/1e3).toFixed(1)+"k":Math.sign(e)*Math.abs(e).toFixed(0)}}},colors:["#7c3aed"],xaxis:{type:"datetime",min:new Date(p).setHours(0,0,0,0),max:new Date(u).setHours(23,59,59,999)},dataLabels:{enabled:!1},stroke:{curve:"smooth"},fill:{type:"gradient",gradient:{shadeIntensity:1,opacityFrom:.7,opacityTo:.9,stops:[0,90,100]}}}};ze((function(){y()}),[e]);var y=function(){c(!0),Fe({path:"/presto-player/v1/analytics/views?"+jQuery.param(Be(Be({},p?{start:z(p)}:{}),u?{end:z(u)}:{})),parse:!1}).then(function(){var e=Object(T.a)(I.a.mark((function e(t){var a,r;return I.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return s(t.headers&&t.headers.get("X-WP-Total")),e.next=3,t.json();case 3:a=e.sent,r=[],a.length&&a.forEach((function(e){r.push({x:e.date_time,y:e.total})})),b([{name:"Views",data:r}]);case 7:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()).catch((function(e){console.error(e)})).finally((function(){c(!1)}))};return n?React.createElement(Ge,null,React.createElement(J,null)):React.createElement(Ge,{className:"presto-flow"},React.createElement("div",{className:"presto-card__title"},Le(He("%d Unique Views","presto-player"),i)),React.createElement(Me.a,{options:h.options,series:m,type:"area",height:280}))}),Qe=wp.i18n,Xe=Qe.__,qe=Qe.sprintf,Je=wp.components,$e=(Je.Card,Je.CardBody),Ke=wp.element,et=Ke.useState,tt=Ke.useEffect,at=(Ke.useRef,function(e){var t=et(!0),a=Object(r.a)(t,2),n=a[0],c=a[1],l=et(0),o=Object(r.a)(l,2),i=o[0],s=o[1],p=e.startDate,u=e.endDate,d=et([{name:"Views",data:[]}]),f=Object(r.a)(d,2),m=f[0],b=f[1],h={options:{chart:{toolbar:{show:!1}},yaxis:{labels:{formatter:function(e){return Math.abs(e)>999?Math.sign(e)*(Math.abs(e)/1e3).toFixed(1)+"k min":(Math.sign(e)*Math.abs(e)).toFixed(1)+"min"}}},colors:["#7c3aed"],xaxis:{type:"datetime",min:new Date(p).setHours(0,0,0,0),max:new Date(u).setHours(23,59,59,999)},dataLabels:{enabled:!1},stroke:{curve:"smooth"},fill:{type:"gradient",gradient:{shadeIntensity:1,opacityFrom:.7,opacityTo:.9,stops:[0,90,100]}}}};tt((function(){R()}),[e]);var y,v,w,g,E,R=function(){c(!0),Fe({path:"/presto-player/v1/analytics/watch-time?"+jQuery.param({start:z(p),end:z(u)}),parse:!1}).then(function(){var e=Object(T.a)(I.a.mark((function e(t){var a,r,n,c;return I.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,t.json();case 2:a=e.sent,r=a.data,n=a.average,s(parseFloat(n)),c=[],r.length&&r.forEach((function(e){c.push({x:e.date_time,y:(e.total/60).toFixed(2)})})),b([{name:"Watch Time",data:c}]);case 9:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()).catch((function(e){console.error(e)})).finally((function(){c(!1)}))};return n?React.createElement($e,null,React.createElement(J,null)):React.createElement($e,{className:"presto-flow"},React.createElement("div",{className:"presto-card__title"},qe(Xe("%s average watch time","presto-player"),(y=i,v=Math.floor(y/60/60),w=Math.floor(y/60)-60*v,g=y%60,E="",v&&(E+=Z(W("%d hours","presto-player"),v)+", "),w&&(E+=Z(W("%d minutes","presto-player"),w)+" "),(v||w)&&g&&(E+=W("and","presto-player")+" "),E+=Z(W("%d seconds","presto-player"),g)))),React.createElement(Me.a,{options:h.options,series:m,type:"area",height:280}))}),rt=wp.i18n.__,nt=wp.components,ct=nt.Panel,lt=nt.TabPanel,ot=function(e){var t=e.startDate,a=e.endDate;return React.createElement(ct,null,React.createElement(lt,{className:"presto-module-tabs",onSelect:function(){},tabs:[{name:"views",title:rt("Views","presto-player")},{name:"watch",title:rt("Watch Time","presto-player")}]},(function(e){switch(e.name){case"views":return React.createElement(Ye,{startDate:t,endDate:a});case"watch":return React.createElement(at,{startDate:t,endDate:a});default:return React.createElement(React.Fragment,null,"Not Found")}})))},it=a(26),st=a.n(it),pt=(a(44),wp.i18n.__),ut=wp.element,dt=ut.useRef,ft=ut.useEffect,mt=ut.useState,bt=function(e){var t=e.startDate,a=e.setStartDate,n=e.endDate,c=e.setEndDate,l=dt(),o=mt(25),i=Object(r.a)(o,2),s=i[0],p=i[1];return ft((function(){new st.a({element:null==l?void 0:l.current,singleMode:!1,format:"MMMM D YYYY",autoApply:!1,plugins:["ranges"],maxDate:new Date,numberOfMonths:2,buttonText:{apply:pt("Apply","presto-player"),cancel:pt("Cancel","presto-player")},dropdowns:{minYear:1990,maxYear:null,months:!0,years:!0},setup:function(e){e.setDateRange(t,n),e.on("button:apply",(function(e,t){a(e.dateInstance),c(t.dateInstance),p(l.current.value.length)}))}})}),[l]),React.createElement("div",{className:"component-base-control"},React.createElement("div",{className:"components-base-control__field"},React.createElement("input",{className:"components-text-control__input presto-settings__date-select",ref:l,size:s})))},ht=a(27),yt=a.n(ht),vt=a(28),wt=a(0),gt=wp.i18n.__,Et=wp.components,Rt=Et.Flex,Ot=Et.FlexBlock,jt=Et.FlexItem,xt=wp.element,_t=xt.useState,Dt=xt.useEffect,Pt=function(e){var t=e.startDate,a=e.endDate,n=e.setStartDate,c=e.setEndDate,l=_t(!1),o=Object(r.a)(l,2),i=o[0],s=o[1];return Dt((function(){yt()({path:"/wp/v2/settings"}).then((function(e){var t;!1===(null==e||null===(t=e.presto_player_analytics)||void 0===t?void 0:t.enable)&&s(!0)}))}),[]),Object(wt.b)(React.Fragment,null,i?Object(wt.b)(kt,null):"",Object(wt.b)(Rt,null,Object(wt.b)(Ot,null,Object(wt.b)("h1",null,gt("Analytics","presto-player"))),Object(wt.b)(jt,null,Object(wt.b)(bt,{startDate:t,setStartDate:n,endDate:a,setEndDate:c}))),Object(wt.b)("div",{className:"presto-flow"},Object(wt.b)("div",{className:"presto-dashboard"},Object(wt.b)("div",{className:"presto-dashboard__row"},Object(wt.b)("div",{className:"presto-dashboard__item is-large"},Object(wt.b)(ot,{startDate:t,endDate:a})),Object(wt.b)("div",{className:"presto-dashboard__item"},Object(wt.b)(_e,{startDate:t,endDate:a}))),Object(wt.b)("div",{className:"presto-dashboard__row"},Object(wt.b)("div",{className:"presto-dashboard__item is-large"},Object(wt.b)(Se,{startDate:t,endDate:a}))))))},kt=function(){return Object(wt.b)(vt.Notice,{css:Object(wt.a)(Ae||(Ae=Object(F.a)(["\n margin: 0 0 1em 0 !important;\n "]))),status:"warning",isDismissible:!1},Object(wt.b)("p",null,gt("Analytics are currently disabled. To collect analytics, turn them on in your settings page.","presto-player")))},Nt=wp.components,St=Nt.Card,Ct=Nt.CardBody,Ft=function(e){var t=e.loading,a=e.title,r=e.value,n=e.label;return t?React.createElement(St,null,React.createElement(Ct,null,React.createElement(J,null))):React.createElement(St,{className:"presto-player__stat-card"},React.createElement(Ct,null,React.createElement("div",{className:"presto-subtitle"},a),React.createElement("h1",null,r),React.createElement("div",null,n)))};function Tt(e,t){var a=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a.push.apply(a,r)}return a}function Mt(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?Tt(Object(a),!0).forEach((function(t){Object(p.a)(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):Tt(Object(a)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}var It,Bt,At,Vt=wp.apiFetch,Ht=wp.element.useState,Lt=wp.compose.createHigherOrderComponent,Ut=function(){return Lt((function(e){return function(t){var a=Ht(!1),n=Object(r.a)(a,2),c=n[0],l=n[1],o=Ht([]),i=Object(r.a)(o,2),s=i[0],p=i[1],u=Ht(""),d=Object(r.a)(u,2),f=d[0],m=d[1],b=function(){var e=Object(T.a)(I.a.mark((function e(t){var a,r,n,c;return I.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return a=t.endpoint,r=t.params,n=void 0===r?{}:r,l(!0),e.prev=2,e.next=5,Vt({path:wp.url.addQueryArgs(a,Mt({},n))});case 5:c=e.sent,p(c),e.next=13;break;case 9:e.prev=9,e.t0=e.catch(2),console.error(e.t0),null!==e.t0&&void 0!==e.t0&&e.t0.message&&m(e.t0.message);case 13:return e.prev=13,l(!1),e.finish(13);case 16:case"end":return e.stop()}}),e,null,[[2,9,13,16]])})));return function(t){return e.apply(this,arguments)}}();return React.createElement(e,Object.assign({loading:c,setLoading:l,fetchData:b,stat:s,setStat:p,error:f,setError:m},t))}}),"withStat")},Gt=wp.i18n.__,Wt=wp.compose.compose,Zt=wp.element.useEffect,zt=Wt([Ut()])((function(e){var t=e.userId,a=e.startDate,r=e.endDate,n=e.stat,c=e.fetchData,l=e.loading;return Zt((function(){c({endpoint:"/presto-player/v1/analytics/user/".concat(t,"/total-views"),params:{start:z(a),end:z(r)}})}),[a,r]),React.createElement(Ft,{loading:l,value:parseInt(null==n?void 0:n.view),title:Gt("Total Views","presto-player")})})),Yt=wp.i18n.__,Qt=wp.compose.compose,Xt=wp.element.useEffect,qt=Qt([Ut()])((function(e){var t=e.userId,a=e.startDate,r=e.endDate,n=e.stat,c=e.fetchData,l=e.loading;return Xt((function(){c({endpoint:"/presto-player/v1/analytics/user/".concat(t,"/average-watchtime"),params:{start:z(a),end:z(r)}})}),[a,r]),React.createElement(Ft,{loading:l,value:parseFloat(null==n?void 0:n.view).toFixed(2),title:Yt("Average Watch Time","presto-player"),label:Yt("seconds","presto-player")})})),Jt=wp.i18n.__,$t=wp.compose.compose,Kt=wp.element.useEffect,ea=$t([Ut()])((function(e){var t=e.userId,a=e.startDate,r=e.endDate,n=e.stat,c=e.fetchData,l=e.loading;return Kt((function(){c({endpoint:"/presto-player/v1/analytics/user/".concat(t,"/total-watchtime"),params:{start:z(a),end:z(r)}})}),[a,r]),React.createElement(Ft,{loading:l,value:parseFloat(null==n?void 0:n.view).toFixed(2),title:Jt("Total Watch Time","presto-player"),label:Jt("seconds","presto-player")})})),ta=wp.i18n.__,aa=wp.components,ra=aa.Flex,na=aa.FlexBlock,ca=aa.FlexItem,la=aa.Spinner,oa=aa.Button,ia=wp.element,sa=ia.useEffect,pa=ia.useState,ua=wp.apiFetch,da=function(e){var t,a,n,c,l=e.route,o=e.startDate,i=e.endDate,s=e.setStartDate,p=e.setEndDate,u=pa(!0),d=Object(r.a)(u,2),f=d[0],m=d[1],b=pa({}),y=Object(r.a)(b,2),v=y[0],w=y[1],g=pa(""),E=Object(r.a)(g,2),R=E[0],O=E[1],j=function(){var e=Object(T.a)(I.a.mark((function e(){var t,a;return I.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return m(!0),e.prev=1,e.next=4,ua({url:"/wp-json/wp/v2/users/".concat(null==l||null===(t=l.params)||void 0===t?void 0:t.id,"?context=edit")});case 4:a=e.sent,w(a),e.next=11;break;case 8:e.prev=8,e.t0=e.catch(1),"rest_no_route"===e.t0.code&&O("User Not Found");case 11:return e.prev=11,m(!1),e.finish(11);case 14:case"end":return e.stop()}}),e,null,[[1,8,11,14]])})));return function(){return e.apply(this,arguments)}}();return sa((function(){j()}),[]),R?Object(wt.b)("div",{className:"presto-flow"},Object(wt.b)(ra,null,Object(wt.b)(na,null,Object(wt.b)("h2",null,R)))):Object(wt.b)("div",{className:"presto-flow"},Object(wt.b)(ra,null,Object(wt.b)(na,null,Object(wt.b)(oa,{isSecondary:!0,onClick:function(){h.push("#/")}},"← ",ta("Back to Dashboard","presto-player")))),Object(wt.b)(ra,{wrap:!0},Object(wt.b)(na,null,f?Object(wt.b)(la,null):Object(wt.b)("div",{css:Object(wt.a)(It||(It=Object(F.a)(["\n display: flex;\n align-items: center;\n\n .presto__edit-user-button {\n opacity: 0;\n visibility: hidden;\n transition: opacity 0.3s ease;\n }\n\n &:hover {\n .presto__edit-user-button {\n opacity: 1;\n visibility: visible;\n }\n }\n "])))},Object(wt.b)("div",null,Object(wt.b)("h1",{className:"presto-dashboard__title"},null==v?void 0:v.name),Object(wt.b)("p",{css:Object(wt.a)(Bt||(Bt=Object(F.a)(["\n margin-top: -10px;\n opacity: 0.65;\n "])))},null==v?void 0:v.email)),!!v.id&&Object(wt.b)("div",{className:"presto__edit-user-button",css:Object(wt.a)(At||(At=Object(F.a)(["\n margin: 0 20px;\n "])))},Object(wt.b)(oa,{href:"/wp-admin/user-edit.php?user_id=".concat(null==v?void 0:v.id),isSecondary:!0,isSmall:!0},ta("View Profile","presto-player")," →")))),Object(wt.b)(ca,null,Object(wt.b)(bt,{startDate:o,setStartDate:s,endDate:i,setEndDate:p}))),Object(wt.b)("div",{className:"presto-dashboard presto-flow"},Object(wt.b)("div",{className:"presto-dashboard__row"},Object(wt.b)("div",{className:"presto-dashboard__item"},Object(wt.b)(zt,{userId:null==l||null===(t=l.params)||void 0===t?void 0:t.id,startDate:o,endDate:i})),Object(wt.b)("div",{className:"presto-dashboard__item"},Object(wt.b)(qt,{userId:null==l||null===(a=l.params)||void 0===a?void 0:a.id,startDate:o,endDate:i})),Object(wt.b)("div",{className:"presto-dashboard__item"},Object(wt.b)(ea,{userId:null==l||null===(n=l.params)||void 0===n?void 0:n.id,startDate:o,endDate:i}))),Object(wt.b)("div",{className:"presto-dashboard__row"},Object(wt.b)("div",{className:"presto-dashboard__item is-large"},Object(wt.b)(Se,{startDate:o,endDate:i,userId:null==l||null===(c=l.params)||void 0===c?void 0:c.id})))))},fa=wp.i18n.__,ma=wp.compose.compose,ba=wp.element.useEffect,ha=ma([Ut()])((function(e){var t=e.video_id,a=e.startDate,r=e.endDate,n=e.stat,c=e.fetchData,l=e.loading;return ba((function(){c({endpoint:"/presto-player/v1/analytics/video/".concat(t,"/average-watchtime"),params:{start:z(a),end:z(r)}})}),[a,r]),React.createElement(Ft,{loading:l,value:parseInt(n),title:fa("Average Watch Time","presto-player"),label:fa("seconds","presto-player")})})),ya=wp.i18n,va=ya.__,wa=(ya.sprintf,wp.components),ga=wa.Card,Ea=wa.CardBody,Ra=wp.element,Oa=Ra.useState,ja=Ra.useEffect,xa=(Ra.useRef,function(e){var t=e.video_id,a=e.startDate,n=e.endDate,c=Oa(!0),l=Object(r.a)(c,2),o=l[0],i=l[1],s=Oa([{name:"Views",data:[]}]),p=Object(r.a)(s,2),u=p[0],d=p[1];ja((function(){i(!0),Fe({path:wp.url.addQueryArgs("/presto-player/v1/analytics/video/".concat(t,"/timeline"),{start:z(a),end:z(n)})}).then((function(e){var t=[];e.length&&e.forEach((function(e){t.push({x:e.watch_time,y:e.total})})),d([{name:"Viewers",data:t}])})).catch((function(e){console.error(e)})).finally((function(){i(!1)}))}),[a,n]);var f={options:{chart:{toolbar:{show:!1}},tickAmount:1,yaxis:{labels:{formatter:function(e){return parseInt(e)}}},xaxis:{labels:{formatter:function(e){return t=e,t=1e3*parseInt(t||0),new Date(t).toISOString().substr(11,8);var t}}},colors:["#7c3aed"],dataLabels:{enabled:!1},stroke:{curve:"smooth"},fill:{type:"gradient",gradient:{shadeIntensity:1,opacityFrom:.7,opacityTo:.9,stops:[0,90,100]}}}};return o?React.createElement(ga,null,React.createElement(Ea,null,React.createElement(J,null))):React.createElement(ga,null,React.createElement(Ea,null,React.createElement("div",{className:"presto-card__title"},va("Audience Retention","presto-player")),React.createElement(Me.a,{options:f.options,series:u,type:"area",height:280})))}),_a=wp.i18n.__,Da=wp.compose.compose,Pa=wp.element.useEffect,ka=Da([Ut()])((function(e){var t=e.video_id,a=e.startDate,r=e.endDate,n=e.stat,c=e.fetchData,l=e.loading;return Pa((function(){c({endpoint:"/presto-player/v1/analytics/video/".concat(t,"/views"),params:{start:z(a),end:z(r)}})}),[a,r]),React.createElement(Ft,{loading:l,value:parseInt(n),title:_a("Unique Views","presto-player")})})),Na=a(29),Sa=a(30),Ca=a(33),Fa=a(34),Ta=a(17),Ma=a(11),Ia=a.n(Ma),Ba=function(e){return e.replace(/([A-Z])/g,(function(e){return"-".concat(e[0].toLowerCase())}))},Aa=a(31),Va=function(e,t,a){var r=t.className||t.class,n=a.className||a.class,c=Ua(e),l=Ua(r?r.split(" "):[]),o=Ua(n?n.split(" "):[]),i=[];return c.forEach((function(e){l.has(e)?(i.push(e),l.delete(e)):o.has(e)||i.push(e)})),l.forEach((function(e){return i.push(e)})),i.join(" ")},Ha=function(e){if("undefined"==typeof document)return!0;var t="on"+e,a=t in document;if(!a){var r=document.createElement("div");r.setAttribute(t,"return;"),a="function"==typeof r[t]}return a},La=function(e,t,a){var r=e.__events||(e.__events={}),n=r[t];n&&e.removeEventListener(t,n),e.addEventListener(t,r[t]=function(e){a&&a.call(this,e)})},Ua=function(e){var t=new Map;return e.forEach((function(e){return t.set(e,e)})),t},Ga=function(e,t){"function"==typeof e?e(t):null!=e&&(e.current=t)},Wa=function(){for(var e=arguments.length,t=new Array(e),a=0;a<e;a++)t[a]=arguments[a];return function(e){t.forEach((function(t){Ga(t,e)}))}};function Za(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var a,r=Object(Ta.a)(e);if(t){var n=Object(Ta.a)(this).constructor;a=Reflect.construct(r,arguments,n)}else a=r.apply(this,arguments);return Object(Fa.a)(this,a)}}var za=function(e,t){var a={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(a[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var n=0;for(r=Object.getOwnPropertySymbols(e);n<r.length;n++)t.indexOf(r[n])<0&&Object.prototype.propertyIsEnumerable.call(e,r[n])&&(a[r[n]]=e[r[n]])}return a},Ya=function(e,t,a,r){void 0!==r&&r();var n=e.toLowerCase().split("-").map((function(e){return e.charAt(0).toUpperCase()+e.slice(1)})).join(""),c=function(t){Object(Ca.a)(c,t);var r=Za(c);function c(e){var t;return Object(Na.a)(this,c),(t=r.call(this,e)).setComponentElRef=function(e){t.componentEl=e},t}return Object(Sa.a)(c,[{key:"componentDidMount",value:function(){this.componentDidUpdate(this.props)}},{key:"componentDidUpdate",value:function(e){!function(e,t){var a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};if(e instanceof Element){var r=Va(e.classList,t,a);""!==r&&(e.className=r),Object.keys(t).forEach((function(a){if("children"!==a&&"style"!==a&&"ref"!==a&&"class"!==a&&"className"!==a&&"forwardedRef"!==a)if(0===a.indexOf("on")&&a[2]===a[2].toUpperCase()){var r=a.substring(2),n=r[0].toLowerCase()+r.substring(1);Ha(n)||La(e,n,t[a])}else{e[a]=t[a],"string"===Object(Aa.a)(t[a])&&e.setAttribute(Ba(a),t[a])}}))}}(this.componentEl,this.props,e)}},{key:"render",value:function(){var t=this.props,r=t.children,n=t.forwardedRef,c=t.style,l=(t.className,t.ref,za(t,["children","forwardedRef","style","className","ref"])),o=Object.keys(l).reduce((function(e,t){if(0===t.indexOf("on")&&t[2]===t[2].toUpperCase()){var a=t.substring(2).toLowerCase();"undefined"!=typeof document&&Ha(a)&&(e[t]=l[t])}else e[t]=l[t];return e}),{});a&&(o=a(this.props,o));var i=Object.assign(Object.assign({},o),{ref:Wa(n,this.setComponentElRef),style:c});return Ia.a.createElement(e,i,r)}}],[{key:"displayName",get:function(){return n}}]),c}(Ia.a.Component);return t&&(c.contextType=t),function(e,t){var a=function(t,a){return Ia.a.createElement(e,Object.assign({},t,{forwardedRef:a}))};return a.displayName=t,Ia.a.forwardRef(a)}(c,n)},Qa=Ya("presto-player"),Xa=wp.element;Xa.useRef,Xa.useEffect;function qa(e){if(e){if(e.match(/^(?:https?:\/\/)?(?:www\.)?(?:youtu\.be\/|youtube\.com\/(?:embed\/|v\/|watch\?v=|watch\?.+&v=))((\w|-){11})(?:\S+)?$/))return"youtube";if(e.match(/(https?:\/\/)?(www\.)?(player\.)?vimeo\.com\/([a-z]*\/)*([‌​0-9]{6,11})[?]?.*/))return"vimeo";if(e.indexOf("https://vz-")>-1&&e.indexOf("b-cdn.net")>-1)return"bunny";if(e.indexOf(".mp3")>-1)return"audio"}return"self-hosted"}function Ja(e,t){var a=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a.push.apply(a,r)}return a}function $a(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?Ja(Object(a),!0).forEach((function(t){Object(p.a)(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):Ja(Object(a)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}var Ka=wp.data.useSelect,er=function(e){var t,a,r,n=e.src,c=e.classes,l=e.preset,o=e.branding,i=e.attributes,s=e.adminPreview,p=e.currentTime,u=e.preload,d=void 0===u?"metadata":u,f=e.overlays,m=e.type,b=i.chapters,h=i.mutedOverlay,y=i.mutedPreview,v=Ka((function(e){var t;return null===(t=e("presto-player/player"))||void 0===t?void 0:t.youtube()})),w=Ka((function(e){var t;return null===(t=e("presto-player/player"))||void 0===t?void 0:t.playerCSS()}));return React.createElement("div",{className:"wp-block-video presto-block-video",style:"audio"===m?$a($a($a({"--presto-player-border-radius":"".concat(null==l?void 0:l.border_radius,"px")},null!=l&&l.background_color?{"--plyr-audio-controls-background":l.background_color}:{"--plyr-audio-controls-background":null==o?void 0:o.color}),null!=l&&l.control_color?{"--plyr-audio-control-color":l.control_color,"--plyr-range-thumb-background":l.control_color,"--plyr-range-fill-background":l.control_color,"--plyr-audio-progress-buffered-background":function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,a=e.replace("#","");3===a.length&&(a=a[0]+a[0]+a[1]+a[1]+a[2]+a[2]);var r=parseInt(a.substring(0,2),16),n=parseInt(a.substring(2,4),16),c=parseInt(a.substring(4,6),16);return t>1&&t<=100&&(t/=100),"rgba("+r+","+n+","+c+","+t+")"}(l.control_color||(null==o?void 0:o.color)||"#00b3ff",.5)}:{"--plyr-audio-control-color":"#ffffff","--plyr-range-thumb-background":"#ffffff","--plyr-range-fill-background":"#ffffff"}),{},{"--plyr-range-thumb-shadow":"0px"}):$a($a($a({"--presto-player-border-radius":"".concat(null==l?void 0:l.border_radius,"px")},null!=l&&l.caption_background?{"--plyr-captions-background":l.caption_background}:{}),null!=o&&o.color?{"--plyr-color-main":o.color}:{}),{},{"--presto-player-email-border-radius":"".concat((null==l||null===(t=l.email_collection)||void 0===t?void 0:t.border_radius)||0,"px"),"--presto-player-logo-width":"".concat((null==o?void 0:o.logo_width)||75,"px")})},React.createElement(Qa,{src:n,css:w,classes:c,currentTime:p,overlays:f,isAdmin:!0,preload:d,preset:l,bunny:{thumbnail:null==i?void 0:i.previewThumbnail,preview:null==i?void 0:i.preview},youtube:{channelId:null==v?void 0:v.channel_id},tracks:!(null==l||!l.captions)&&[{kind:"captions",label:"English",srclang:"en",src:"/path/to/captions.en.vtt",default:!0}],branding:o,chapters:b,blockAttributes:i,poster:i.poster,provider:"audio"===m?"audio":qa(n),mediaTitle:i.title},React.createElement("div",{slot:"player-end"},(null==y?void 0:y.enabled)&&(null==h?void 0:h.enabled)&&React.createElement("div",{className:"presto-player__overlay is-image",style:{position:"absolute",width:"".concat((null==h?void 0:h.width)||100,"%"),left:"".concat(100*((null==h||null===(a=h.focalPoint)||void 0===a?void 0:a.x)||.5),"%"),top:"".concat(100*((null==h||null===(r=h.focalPoint)||void 0===r?void 0:r.y)||.5),"%")}},React.createElement("img",{src:null==h?void 0:h.src,style:{transform:"translateX(-50%) translateY(-50%)"}})),s)))};function tr(e,t){var a=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a.push.apply(a,r)}return a}function ar(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?tr(Object(a),!0).forEach((function(t){Object(p.a)(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):tr(Object(a)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}var rr=wp.i18n.__,nr=wp.components,cr=nr.Flex,lr=nr.FlexBlock,or=nr.FlexItem,ir=nr.Spinner,sr=nr.Button,pr=nr.TextControl,ur=wp.element,dr=ur.useEffect,fr=ur.useState,mr=wp.apiFetch,br=function(e){var t,a,n,c=e.route,l=e.startDate,o=e.endDate,i=e.setStartDate,s=e.setEndDate,p=fr(!0),u=Object(r.a)(p,2),d=u[0],f=u[1],m=fr({}),b=Object(r.a)(m,2),y=b[0],v=b[1],w=fr(""),g=Object(r.a)(w,2),E=g[0],R=g[1],O=fr(null),j=Object(r.a)(O,2),x=j[0],_=j[1],D=fr(!1),P=Object(r.a)(D,2),k=P[0],N=P[1],S=function(){var e=Object(T.a)(I.a.mark((function e(){var t,a,r,n;return I.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return f(!0),e.prev=1,e.next=4,mr({url:"".concat(null===(t=prestoPlayer)||void 0===t?void 0:t.root).concat(null===(a=prestoPlayer)||void 0===a?void 0:a.prestoVersionString,"videos/").concat(null==c||null===(r=c.params)||void 0===r?void 0:r.id)});case 4:n=e.sent,v(n),_(null==n?void 0:n.title),e.next=12;break;case 9:e.prev=9,e.t0=e.catch(1),"rest_no_route"===e.t0.code&&R("Video Not Found");case 12:return e.prev=12,f(!1),e.finish(12);case 15:case"end":return e.stop()}}),e,null,[[1,9,12,15]])})));return function(){return e.apply(this,arguments)}}(),C=function(){var e=Object(T.a)(I.a.mark((function e(){var t,a;return I.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return console.log("New Video title ".concat(x)),f(!0),e.prev=2,t=ar(ar({},y),{title:x}),e.next=6,wp.apiFetch({method:"POST",url:wp.url.addQueryArgs("".concat(prestoPlayer.root).concat(prestoPlayer.prestoVersionString,"videos/").concat(y.id),{_method:"PUT"}),data:t});case 6:if(a=e.sent){e.next=9;break}throw genericError;case 9:N(!1),v(a),e.next=16;break;case 13:e.prev=13,e.t0=e.catch(2),R(null!==e.t0&&void 0!==e.t0&&e.t0.message?e.t0.message:genericError);case 16:return e.prev=16,f(!1),e.finish(16);case 19:case"end":return e.stop()}}),e,null,[[2,13,16,19]])})));return function(){return e.apply(this,arguments)}}(),F=function(){_(null==y?void 0:y.title),N(!1)};return dr((function(){S()}),[]),E?React.createElement("div",{className:"presto-flow"},React.createElement(cr,null,React.createElement(lr,null,React.createElement("h2",null,E)))):React.createElement("div",{className:"presto-flow"},React.createElement(cr,null,React.createElement(lr,null,React.createElement(sr,{isSecondary:!0,onClick:function(){h.push("#/")}},"← ",rr("Back to Dashboard","presto-player")))),React.createElement(cr,{wrap:!0},React.createElement(lr,null,d?React.createElement(ir,null):k?React.createElement("div",{className:"presto-inline-edit presto-inline-edit--editing"},React.createElement(pr,{className:"presto-inline-edit__input",type:"text",value:x,onChange:function(e){return _(e)}}),React.createElement(sr,{className:"presto-inline-edit__button",isPrimary:!0,onClick:C}," ","Save"," "),React.createElement(sr,{className:"presto-inline-edit__button",isSecondary:!0,onClick:F}," ","Cancel"," ")):React.createElement("div",{className:"presto-inline-edit"},React.createElement("h1",{className:"presto-dashboard__title presto-inline-edit__text"},null==y?void 0:y.title),React.createElement("button",{className:"presto-inline-edit__edit",onClick:function(){return N(!0)}},React.createElement("span",{className:"dashicon dashicons dashicons-edit"})))),React.createElement(or,null,React.createElement(bt,{startDate:l,setStartDate:i,endDate:o,setEndDate:s}))),React.createElement("div",{className:"presto-dashboard presto-flow"},React.createElement("div",{className:"presto-dashboard__row"},React.createElement("div",{className:"presto-dashboard__item is-large"},React.createElement(ka,{video_id:null==c||null===(t=c.params)||void 0===t?void 0:t.id,startDate:l,endDate:o})),React.createElement("div",{className:"presto-dashboard__item"},!!Object.keys(y||{}).length&&React.createElement(er,{src:null==y?void 0:y.src,attributes:{title:y.title},type:qa(y.src),preset:{"play-large":!0,play:!0,progress:!0,rewind:!0,"fast-forward":!0,"current-time":!0,background_color:"#8421cb",volume:!0,mute:!0,i18n:window.prestoPlayer.i18n}})),React.createElement("div",{className:"presto-dashboard__item"},React.createElement(ha,{video_id:null==c||null===(a=c.params)||void 0===a?void 0:a.id,startDate:l,endDate:o}))),React.createElement("div",{className:"presto-dashboard__row"},React.createElement("div",{className:"presto-dashboard__item is-large"},React.createElement(xa,{video_id:null==c||null===(n=c.params)||void 0===n?void 0:n.id,startDate:l,endDate:o})))))},hr={dashboard:{path:"/"},video:{path:"/video/:id"},user:{path:"/user/:id"}},yr=wp.element.useState,vr=function(){var e,t=function(){window.scrollTo(0,0)},a=yr(new Date(Date.now()-6048e5)),n=Object(r.a)(a,2),c=n[0],l=n[1],o=yr(new Date),i=Object(r.a)(o,2),s=i[0],p=i[1];return null!==(e=prestoPlayer)&&void 0!==e&&e.isPremium?React.createElement("div",{className:"presto-dashboard__content"},React.createElement(x,{routes:hr},React.createElement(E,{path:hr.dashboard.path,onRoute:t},React.createElement(Pt,{startDate:c,endDate:s,setStartDate:l,setEndDate:p})),React.createElement(E,{path:hr.video.path,onRoute:t},React.createElement(br,{startDate:c,endDate:s,setStartDate:l,setEndDate:p})),React.createElement(E,{path:hr.user.path,onRoute:t},React.createElement(da,{startDate:c,endDate:s,setStartDate:l,setEndDate:p})))):React.createElement("div",{className:"presto-dashboard__content"},React.createElement(C,null))};(0,wp.element.render)(React.createElement(vr,null),document.getElementById("presto-analytics-page"))}},[[35,1,2]]]);
19
- //# sourceMappingURL=admin-9ff30d14.js.map
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
dist/analytics/admin-9ff30d14.js.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"sources":["webpack:///external [\"wp\",\"element\"]","webpack:///external [\"wp\",\"apiFetch\"]","webpack:///external [\"wp\",\"components\"]","webpack:///./src/router/utils.js","webpack:///./src/router/context.js","webpack:///./src/router/route.js","webpack:///./src/router/link.js","webpack:///./src/router/index.js","webpack:///./src/admin/analytics/pages/illustration.js","webpack:///./src/admin/analytics/pages/AnalyticsUpgrade.js","webpack:///./src/admin/analytics/hocs/withDataList.js","webpack:///./src/admin/analytics/util.js","webpack:///./src/admin/settings/components/Loading.js","webpack:///./src/admin/ui/Pagination.js","webpack:///./src/admin/ui/Table.js","webpack:///./src/admin/analytics/components/DataTable.js","webpack:///./src/admin/analytics/components/TopUsers.js","webpack:///./src/admin/analytics/components/TopVideos.js","webpack:///./src/shared/services/fetch.js","webpack:///./src/admin/analytics/components/TotalViewsGraph.js","webpack:///./src/admin/analytics/components/TotalWatchGraph.js","webpack:///./src/admin/analytics/components/OverviewPanel.js","webpack:///./src/admin/analytics/components/DatePicker.js","webpack:///./src/admin/analytics/pages/Dashboard.js","webpack:///./src/admin/ui/StatCard.js","webpack:///./src/admin/analytics/hocs/withStat.js","webpack:///./src/admin/analytics/components/TotalVideoViewsByUser.js","webpack:///./src/admin/analytics/components/VideoAverageWatchTimeByUser.js","webpack:///./src/admin/analytics/components/VideoTotalWatchTimeByUser.js","webpack:///./src/admin/analytics/pages/User.js","webpack:///./src/admin/analytics/components/VideoAverageWatchTime.js","webpack:///./src/admin/analytics/components/VideoTimeline.js","webpack:///./src/admin/analytics/components/VideoViews.js","webpack:///../../../src/components/react-component-lib/utils/case.ts","webpack:///../../../src/components/react-component-lib/utils/attachProps.ts","webpack:///../../../src/components/react-component-lib/utils/index.tsx","webpack:///../../src/components/react-component-lib/createComponent.tsx","webpack:///../src/components/index.ts","webpack:///./src/admin/blocks/util.js","webpack:///./src/admin/blocks/shared/Player.js","webpack:///./src/admin/analytics/pages/Video.js","webpack:///./src/admin/analytics/routes.js","webpack:///./src/admin/analytics/App.js","webpack:///./src/admin/analytics/index.js"],"names":["module","exports","window","locationToRoute","location","path","pathname","hash","query","qs","parse","search","history","createBrowserHistory","RouterContext","wp","element","createContext","route","useContext","prev","Route","onRoute","children","matched","match","checkMatch","substr","cloneElement","Router","props","setState","routes","Object","keys","map","key","unlisten","listen","handleRouteChange","state","defaultRoute","this","NotFound","push","forEach","name","isMatched","data","routerContextValue","is404","Provider","value","Component","width","height","id","data-name","xmlns","xmlnsXlink","viewBox","x1","y1","x2","y2","gradientUnits","offset","stop-color","stop-opacity","xlinkHref","transform","x","y","fill","gradientTransform","opacity","clip-path","points","cx","cy","r","d","__","i18n","components","Flex","FlexItem","FlexBlock","style","padding","background","marginLeft","href","target","className","apiFetch","useState","createHigherOrderComponent","compose","WrappedComponent","loading","setLoading","page","setPage","total","setTotal","totalPages","setTotalPages","setData","error","setError","fetchData","a","endpoint","params","url","addQueryArgs","per_page","then","res","headers","parseInt","get","json","responseData","console","message","sprintf","convertDateTimeToAbsoluteDate","dateTime","Date","getTimezoneOffset","getTime","toISOString","split","Spinner","align","justify","Card","CardBody","Button","ButtonGroup","useEffect","perPage","hasPrevious","setHasPrevious","hasNext","setHasNext","end","setEnd","start","setStart","Math","min","size","isSecondary","disabled","onClick","max","useRef","columns","onRowClick","title","length","role","classNames","column","label","row","rowIndex","columnIndex","data-title","aria-label","render","onSelect","Loading","Table","Pagination","withDataList","startDate","endDate","user","stats","DataTable","userId","user_id","marginBottom","wordBreak","video","color","use","createNonceMiddleware","prestoPlayer","nonce","createRootURLMiddleware","root","prestoVersionString","totalViews","setTotalViews","series","setSeries","chart","options","toolbar","show","yaxis","labels","formatter","num","abs","sign","toFixed","colors","xaxis","type","setHours","dataLabels","enabled","stroke","curve","gradient","shadeIntensity","opacityFrom","opacityTo","stops","fetchViews","jQuery","param","item","date_time","catch","e","finally","averageTime","setAverageTime","fetchMinutes","savedSeconds","hours","minutes","seconds","out","average","parseFloat","floor","Panel","TabPanel","tabs","tab","TotalViewsGraph","TotalWatchGraph","setStartDate","setEndDate","dateRef","inputSize","setInputSize","Litepicker","current","singleMode","format","autoApply","plugins","maxDate","numberOfMonths","buttonText","apply","cancel","dropdowns","minYear","maxYear","months","years","setup","picker","setDateRange","on","dateInstance","ref","noticeStatus","setNoticeStatus","post","presto_player_analytics","enable","DatePicker","OverviewPanel","TopUsers","TopVideos","MyNotice","css","status","isDismissible","stat","setStat","withStat","StatCard","view","User","setUser","getUser","code","wrap","email","isSmall","TotalVideoViewsByUser","VideoAverageWatchTimeByUser","VideoTotalWatchTimeByUser","video_id","watch_time","tickAmount","eventNameSuffix","getProvider","src","indexOf","useSelect","classes","preset","branding","attributes","adminPreview","currentTime","preload","overlays","chapters","mutedOverlay","mutedPreview","youtube","select","playerCSS","border_radius","background_color","control_color","hexCode","hex","replace","substring","g","b","convertHex","caption_background","email_collection","logo_width","PrestoPlayer","isAdmin","bunny","thumbnail","previewThumbnail","preview","channelId","channel_id","tracks","captions","kind","srclang","default","blockAttributes","poster","provider","mediaTitle","slot","position","left","focalPoint","top","TextControl","Video","setVideo","thisName","setThisName","editing","setEditing","getVideo","putVideo","log","method","_method","saved","genericError","cancelEditing","onChange","isPrimary","VideoViews","Player","play","progress","rewind","volume","mute","VideoAverageWatchTime","VideoTimeline","dashboard","scrollToTop","scrollTo","now","isPremium","Dashboard","AnalyticsUpgrade","App","document","getElementById"],"mappings":";;;;;;;;;;;;;;;;;oHAAcA,EAAOC,QAAUC,OAAW,GAAW,S,iBCAvCF,EAAOC,QAAUC,OAAW,GAAY,U,iBCAxCF,EAAOC,QAAUC,OAAW,GAAc,Y,4KCCjD,SAASC,EAAgBC,GAE9B,MAAO,CACLC,KAAMD,EAASE,SACfC,KAAMH,EAASG,KACfC,MAAOC,IAAGC,MAAMN,EAASO,S,YCHhBC,EAAUC,cACVC,EAAgBC,GAAGC,QAAQC,cAAc,CACpDC,MAAOf,EAAgBS,EAAQR,Y,OCJzBe,EAAeJ,GAAGC,QAAlBG,WAEJC,EAAO,GAEJ,SAASC,EAAT,GAA6C,IAA5BhB,EAA2B,EAA3BA,KAAMiB,EAAqB,EAArBA,QAASC,EAAY,EAAZA,SAE7BL,EAAUC,EAAWL,GAArBI,MAGFM,EADaC,YAAM,GAAD,OAAIpB,GACZqB,CAAW,GAAD,OAAIR,EAAMX,KAAKoB,OAAO,KAEhD,OAAKH,GAIDF,IACEF,IAASI,EAAQnB,MACnBiB,IAEFF,EAAOI,EAAQnB,MAGV,+BAAMU,GAAGC,QAAQY,aAAaL,EAAU,CAAEL,MAAOM,MAV/C,K,qBCbYT,GAAGC,QAAlBG,W,ycCOFU,E,wCACJ,WAAYC,GAAQ,IAAD,sBACjB,cAAMA,GADW,gDA4BC,SAAC1B,GACnB,IAAMc,EAAQf,EAAgBC,aAAD,EAACA,EAAUA,UACxC,EAAK2B,SAAS,CAAEb,MAAOA,OA1BvB,EAAKc,OAASC,OAAOC,KAAKJ,EAAME,QAAQG,KACtC,SAACC,GAAD,OAASN,EAAME,OAAOI,GAAK/B,QAI7B,EAAKgC,SAAWzB,EAAQ0B,OAAO,EAAKC,mBAEpC,IAAMrB,EAAQf,EAAgBS,EAAQR,UAC9BO,EAAWC,EAAQR,SAAnBO,OAZS,OAejB,EAAK6B,MAAQ,CACXtB,QACAuB,aAAcX,WAAOW,aAAP,UACP9B,EADO,YACGmB,aADH,EACGA,EAAOW,cADV,UAEP9B,EAFO,OAjBC,E,wDAuBnB,WAEE+B,KAAKL,a,oBAQP,WAEE,MAA+BK,KAAKZ,MAA5BP,EAAR,EAAQA,SACR,GADA,EAAkBoB,SACcD,KAAKF,OAA7BtB,EAAR,EAAQA,MAAOuB,EAAf,EAAeA,aAEf,IAAKvB,EAAMX,KAET,OADAK,EAAQgC,KAAKH,GACN,gCAGT,IAAIjB,GAAU,GAEbkB,KAAKV,QAAU,IAAIa,SAAQ,SAACC,GAC3B,IACMC,EADatB,YAAMP,EAAMX,KAAKoB,OAAO,GACzBD,CAAW,GAAD,OAAIR,EAAMX,KAAKoB,OAAO,KAC7CoB,IAGLvB,EAAU,CACRsB,OACAE,KAAMD,OAIV,IAAME,EAAqB,CAAE/B,QAAOM,WAG9B0B,GAAS1B,EAEf,OACE,oBAACV,EAAcqC,SAAf,CAAwBC,MAAOH,GAC5BC,EAAQ,4CAAuB3B,O,GAjEnB8B,aCPN,cAAwB,IAArBC,EAAoB,EAApBA,MAAOC,EAAa,EAAbA,OACvB,OACE,2BACEC,GAAG,uCACHC,YAAU,UACVH,MAAOA,EACPC,OAAQA,EACRG,MAAM,6BACNC,WAAW,+BACXC,QAAQ,qBAER,gCACE,sCACEJ,GAAG,uCACHK,GAAG,SACHC,GAAG,SACHC,GAAG,SACHC,GAAG,QACHC,cAAc,kBAEd,4BAAMC,OAAO,IAAIC,aAAW,OAAOC,eAAa,SAChD,4BAAMF,OAAO,OAAOC,aAAW,OAAOC,eAAa,SACnD,4BAAMF,OAAO,IAAIC,aAAW,OAAOC,eAAa,SAElD,sCACEZ,GAAG,uCACHK,GAAG,SACHC,GAAG,SACHC,GAAG,SACHC,GAAG,SACHK,UAAU,0CAEZ,sCACEb,GAAG,uCACHK,GAAG,SACHC,GAAG,SACHC,GAAG,SACHC,GAAG,QACHK,UAAU,0CAEZ,gCACEb,GAAG,uCACHc,UAAU,6BAEV,4BACEd,GAAG,uCACHC,YAAU,cACVc,EAAE,SACFC,EAAE,SACFlB,MAAM,QACNC,OAAO,SACPkB,KAAK,UAGT,sCACEjB,GAAG,uCACHK,GAAG,SACHC,GAAG,SACHC,GAAG,SACHC,GAAG,SACHK,UAAU,0CAEZ,sCACEb,GAAG,uCACHK,GAAG,SACHC,GAAG,SACHC,GAAG,SACHC,GAAG,QACHK,UAAU,0CAEZ,gCACEb,GAAG,uCACHc,UAAU,6BAEV,4BACEd,GAAG,uCACHC,YAAU,cACVc,EAAE,SACFC,EAAE,SACFlB,MAAM,QACNC,OAAO,SACPkB,KAAK,UAGT,sCACEjB,GAAG,uCACHK,GAAG,SACHC,GAAG,SACHC,GAAG,SACHC,GAAG,QACHU,kBAAkB,uCAClBL,UAAU,0CAEZ,sCACEb,GAAG,uCACHK,GAAG,SACHC,GAAG,SACHC,GAAG,SACHC,GAAG,SACHU,kBAAkB,wCAClBL,UAAU,0CAEZ,sCACEb,GAAG,uCACHK,GAAG,SACHC,GAAG,SACHC,GAAG,SACHC,GAAG,SACHK,UAAU,0CAEZ,sCACEb,GAAG,uCACHK,GAAG,SACHC,GAAG,SACHC,GAAG,SACHC,GAAG,SACHK,UAAU,0CAEZ,sCACEb,GAAG,uCACHK,GAAG,SACHC,GAAG,SACHC,GAAG,SACHC,GAAG,SACHK,UAAU,2CAGd,gDACA,yBAAGM,QAAQ,OACT,4BACEJ,EAAE,QACFC,EAAE,QACFlB,MAAM,SACNC,OAAO,SACPkB,KAAK,gDAGT,4BACEF,EAAE,SACFC,EAAE,QACFlB,MAAM,SACNC,OAAO,SACPkB,KAAK,YAEP,4BAAMF,EAAE,SAASC,EAAE,SAASlB,MAAM,SAASC,OAAO,OAAOkB,KAAK,YAC9D,4BACEF,EAAE,SACFC,EAAE,SACFlB,MAAM,SACNC,OAAO,OACPkB,KAAK,UACLE,QAAQ,QAEV,4BAAMJ,EAAE,SAASC,EAAE,SAASlB,MAAM,SAASC,OAAO,OAAOkB,KAAK,YAC9D,4BAAMF,EAAE,SAASC,EAAE,QAAQlB,MAAM,SAASC,OAAO,OAAOkB,KAAK,YAC7D,4BAAMF,EAAE,SAASC,EAAE,SAASlB,MAAM,SAASC,OAAO,OAAOkB,KAAK,YAC9D,4BAAMF,EAAE,SAASC,EAAE,QAAQlB,MAAM,SAASC,OAAO,OAAOkB,KAAK,YAC7D,4BAAMF,EAAE,SAASC,EAAE,SAASlB,MAAM,SAASC,OAAO,OAAOkB,KAAK,YAC9D,4BAAMF,EAAE,SAASC,EAAE,SAASlB,MAAM,SAASC,OAAO,OAAOkB,KAAK,YAC9D,4BAAMF,EAAE,SAASC,EAAE,QAAQlB,MAAM,SAASC,OAAO,OAAOkB,KAAK,YAC7D,yBAAGE,QAAQ,OACT,4BACEJ,EAAE,SACFC,EAAE,SACFlB,MAAM,SACNC,OAAO,SACPkB,KAAK,gDAGT,4BACEF,EAAE,SACFC,EAAE,SACFlB,MAAM,SACNC,OAAO,SACPkB,KAAK,YAEP,yBAAGE,QAAQ,OACT,4BACEJ,EAAE,SACFC,EAAE,QACFlB,MAAM,QACNC,OAAO,SACPkB,KAAK,gDAGT,4BACEjB,GAAG,uCACHC,YAAU,cACVc,EAAE,SACFC,EAAE,SACFlB,MAAM,QACNC,OAAO,SACPkB,KAAK,SAEP,yBAAGG,YAAU,8CACX,+BACEC,OAAO,gIACPJ,KAAK,UACLE,QAAQ,QAEV,8BAAQG,GAAG,SAASC,GAAG,MAAMC,EAAE,QAAQP,KAAK,UAAUE,QAAQ,SAEhE,yBAAGA,QAAQ,OACT,4BACEJ,EAAE,SACFC,EAAE,SACFlB,MAAM,SACNC,OAAO,SACPkB,KAAK,gDAGT,4BACEF,EAAE,SACFC,EAAE,SACFlB,MAAM,SACNC,OAAO,SACPkB,KAAK,YAEP,yBAAGE,QAAQ,OACT,4BACEJ,EAAE,SACFC,EAAE,QACFlB,MAAM,QACNC,OAAO,SACPkB,KAAK,gDAGT,4BACEjB,GAAG,uCACHC,YAAU,cACVc,EAAE,SACFC,EAAE,SACFlB,MAAM,QACNC,OAAO,SACPkB,KAAK,SAEP,yBAAGG,YAAU,8CACX,+BACEC,OAAO,+HACPJ,KAAK,UACLE,QAAQ,QAEV,8BAAQG,GAAG,SAASC,GAAG,QAAQC,EAAE,QAAQP,KAAK,UAAUE,QAAQ,SAElE,yBAAGA,QAAQ,OACT,4BACEJ,EAAE,SACFC,EAAE,SACFlB,MAAM,SACNC,OAAO,SACPe,UAAU,0CACVG,KAAK,gDAGT,4BACEF,EAAE,SACFC,EAAE,SACFlB,MAAM,SACNC,OAAO,SACPe,UAAU,0CACVG,KAAK,SAEP,4BACEF,EAAE,QACFC,EAAE,SACFlB,MAAM,SACNC,OAAO,OACPe,UAAU,0CACVG,KAAK,YAEP,4BACEF,EAAE,SACFC,EAAE,QACFlB,MAAM,SACNC,OAAO,OACPe,UAAU,yCACVG,KAAK,YAEP,4BACEF,EAAE,SACFC,EAAE,SACFlB,MAAM,SACNC,OAAO,OACPe,UAAU,wCACVG,KAAK,YAEP,4BACEF,EAAE,QACFC,EAAE,SACFlB,MAAM,QACNC,OAAO,OACPe,UAAU,wCACVG,KAAK,UACLE,QAAQ,QAEV,4BACEJ,EAAE,SACFC,EAAE,SACFlB,MAAM,SACNC,OAAO,OACPe,UAAU,yCACVG,KAAK,UACLE,QAAQ,QAEV,4BACEJ,EAAE,SACFC,EAAE,SACFlB,MAAM,SACNC,OAAO,OACPe,UAAU,0CACVG,KAAK,YAEP,4BACEF,EAAE,SACFC,EAAE,SACFlB,MAAM,QACNC,OAAO,OACPe,UAAU,0CACVG,KAAK,UACLE,QAAQ,QAEV,4BACEJ,EAAE,SACFC,EAAE,SACFlB,MAAM,SACNC,OAAO,OACPe,UAAU,0CACVG,KAAK,YAEP,yBAAGE,QAAQ,OACT,4BACEJ,EAAE,SACFC,EAAE,QACFlB,MAAM,SACNC,OAAO,SACPe,UAAU,2CACVG,KAAK,gDAGT,4BACEF,EAAE,SACFC,EAAE,SACFlB,MAAM,SACNC,OAAO,SACPe,UAAU,0CACVG,KAAK,SAEP,4BACEF,EAAE,SACFC,EAAE,SACFlB,MAAM,SACNC,OAAO,OACPe,UAAU,0CACVG,KAAK,YAEP,4BACEF,EAAE,SACFC,EAAE,SACFlB,MAAM,QACNC,OAAO,SACPe,UAAU,0CACVG,KAAK,YAEP,4BACEF,EAAE,SACFC,EAAE,SACFlB,MAAM,QACNC,OAAO,OACPe,UAAU,0CACVG,KAAK,YAEP,4BACEF,EAAE,SACFC,EAAE,SACFlB,MAAM,QACNC,OAAO,QACPe,UAAU,yCACVG,KAAK,YAEP,4BACEF,EAAE,SACFC,EAAE,SACFlB,MAAM,QACNC,OAAO,QACPe,UAAU,0CACVG,KAAK,YAEP,yBAAGE,QAAQ,OACT,4BACEJ,EAAE,SACFC,EAAE,SACFlB,MAAM,OACNC,OAAO,QACPkB,KAAK,YAEP,4BACEF,EAAE,SACFC,EAAE,SACFlB,MAAM,OACNC,OAAO,QACPe,UAAU,qCACVG,KAAK,aAGT,4BACEQ,EAAE,0ZACFX,UAAU,4BACVG,KAAK,UACLE,QAAQ,QAEV,4BACEM,EAAE,0ZACFX,UAAU,4BACVG,KAAK,UACLE,QAAQ,QAEV,4BACEM,EAAE,4ZACFX,UAAU,4BACVG,KAAK,UACLE,QAAQ,QAEV,8BAAQG,GAAG,SAASC,GAAG,QAAQC,EAAE,OAAOP,KAAK,UAAUE,QAAQ,QAC/D,8BAAQG,GAAG,OAAOC,GAAG,SAASC,EAAE,OAAOP,KAAK,UAAUE,QAAQ,QAC9D,8BAAQG,GAAG,SAASC,GAAG,SAASC,EAAE,OAAOP,KAAK,UAAUE,QAAQ,QAChE,8BAAQG,GAAG,SAASC,GAAG,QAAQC,EAAE,OAAOP,KAAK,UAAUE,QAAQ,QAC/D,8BAAQG,GAAG,QAAQC,GAAG,SAASC,EAAE,OAAOP,KAAK,UAAUE,QAAQ,QAC/D,8BAAQG,GAAG,SAASC,GAAG,SAASC,EAAE,OAAOP,KAAK,UAAUE,QAAQ,QAChE,8BAAQG,GAAG,QAAQC,GAAG,SAASC,EAAE,OAAOP,KAAK,UAAUE,QAAQ,QAC/D,4BACEJ,EAAE,SACFC,EAAE,SACFlB,MAAM,SACNC,OAAO,SACPkB,KAAK,+CAEP,4BACEQ,EAAE,gGACFX,UAAU,4BACVG,KAAK,+CAEP,4BACEQ,EAAE,4FACFX,UAAU,4BACVG,KAAK,YAEP,4BACEF,EAAE,SACFC,EAAE,SACFlB,MAAM,SACNC,OAAO,SACPkB,KAAK,YAEP,4BACEF,EAAE,SACFC,EAAE,SACFlB,MAAM,SACNC,OAAO,SACPkB,KAAK,YAEP,4BACEF,EAAE,SACFC,EAAE,SACFlB,MAAM,SACNC,OAAO,QACPkB,KAAK,YAEP,4BACEQ,EAAE,4GACFX,UAAU,4BACVG,KAAK,+CAEP,4BACEQ,EAAE,mHACFX,UAAU,4BACVK,QAAQ,UC3dRO,EAAOnE,GAAGoE,KAAVD,GAGR,EAAsCnE,GAAGqE,WAAjCC,EAAR,EAAQA,KAAMC,EAAd,EAAcA,SAAUC,EAAxB,EAAwBA,UAET,aACb,OACE,oBAACF,EAAD,CAAMG,MAAO,CAAEC,QAAS,OAAQC,WAAY,SAC1C,oBAACJ,EAAD,KACE,oBAAC,EAAD,CAAchC,MAAM,WAEtB,oBAACiC,EAAD,CAAWC,MAAO,CAAEG,WAAY,SAC9B,8BAAKT,EAAG,+BAAgC,kBACxC,6BACGA,EACC,sFACA,kBAGJ,yBACEU,KAAK,2BACLC,OAAO,SACPC,UAAU,yBAETZ,EAAG,aAAc,qB,wmBCrBbnE,GAAGoE,KAAVD,GAAR,IACQa,EAAahF,GAAbgF,SACAC,EAAajF,GAAGC,QAAhBgF,SACAC,EAA+BlF,GAAGmF,QAAlCD,2BAOO,oBACbA,GACE,SAACE,GAAD,OAAsB,SAACrE,GACrB,MAA8BkE,GAAS,GAAvC,mBAAOI,EAAP,KAAgBC,EAAhB,KACA,EAAwBL,EAAS,GAAjC,mBAAOM,EAAP,KAAaC,EAAb,KACA,EAA0BP,EAAS,GAAnC,mBAAOQ,EAAP,KAAcC,EAAd,KACA,EAAoCT,EAAS,GAA7C,mBAAOU,EAAP,KAAmBC,EAAnB,KACA,EAAwBX,EAAS,IAAjC,mBAAOhD,EAAP,KAAa4D,EAAb,KACA,EAA0BZ,EAAS,IAAnC,mBAAOa,EAAP,KAAcC,EAAd,KAKMC,EAAS,uCAAG,mCAAAC,EAAA,6DAASC,EAAT,EAASA,SAAT,IAAmBC,cAAnB,MAA4B,GAA5B,EAChBb,GAAW,GADK,kBAKON,EAAS,CAC5B1F,KAAMU,GAAGoG,IAAIC,aAAaH,EAApB,GACJX,OACAe,SAAU,GACPH,IAELxG,OAAO,IACN4G,MAAK,SAACC,GACP,IAAMf,EAAQe,EAAIC,QACdC,SAASF,EAAIC,QAAQE,IAAI,eACzB,EACEhB,EAAaa,EAAIC,QACnBC,SAASF,EAAIC,QAAQE,IAAI,oBACzB,EAGJ,OAFAjB,EAASD,GACTG,EAAcD,GACPa,EAAII,UArBC,OAKdC,EALc,OAwBdhB,EAAQgB,GAxBM,gDA0BdC,QAAQhB,MAAR,MACA,4BAAI,KAAGiB,SACLhB,EAAS,KAAEgB,SA5BC,yBA+BdzB,GAAW,GA/BG,4EAAH,sDAmCf,OACE,oBAACF,EAAD,eACEC,QAASA,EACTC,WAAYA,EACZU,UAAWA,EACXT,KAAMA,EACNC,QAASA,EACTC,MAAOA,EACPC,SAAUA,EACVC,WAAYA,EACZC,cAAeA,EACf3D,KAAMA,EACN4D,QAASA,EACTC,MAAOA,EACPC,SAAUA,GACNhF,OAIV,iBChFJ,EAAwBf,GAAGoE,KAAnBD,EAAR,EAAQA,GAAI6C,EAAZ,EAAYA,QAgCCC,EAAgC,SAACC,GAC5C,IAAM/D,GAAS,IAAIgE,MAAOC,oBAE1B,OADW,IAAID,KAAKD,EAASG,UAAqB,GAATlE,EAAc,KAC3CmE,cAAcC,MAAM,KAAK,GAAK,kBCnC5C,EAAoCvH,GAAGqE,WAA/BmD,EAAR,EAAQA,QAASlD,EAAjB,EAAiBA,KAAMC,EAAvB,EAAuBA,SACR,cAAuB,IAAD,IAAnB/B,cAAmB,MAAV,IAAU,EACnC,OACE,oBAAC,EAAD,CAAMiC,MAAO,CAAEjC,OAAO,GAAD,OAAKA,EAAL,OAAmBiF,MAAM,SAASC,QAAQ,UAC7D,oBAAC,EAAD,KACE,oBAACF,EAAD,SCLArD,EAAOnE,GAAGoE,KAAVD,GACR,EAAiEnE,GAAGqE,WAA5DsD,GAAR,EAAQA,KAAMC,GAAd,EAAcA,SAAUtD,GAAxB,EAAwBA,KAAME,GAA9B,EAA8BA,UAAWqD,GAAzC,EAAyCA,OAAQC,GAAjD,EAAiDA,YACjD,GAAgC9H,GAAGC,QAA3BgF,GAAR,GAAQA,SAAU8C,GAAlB,GAAkBA,UAEH,eAAoD,IAAjDxC,EAAgD,EAAhDA,KAAMC,EAA0C,EAA1CA,QAASwC,EAAiC,EAAjCA,QAASvC,EAAwB,EAAxBA,MAAOE,EAAiB,EAAjBA,WAE/C,EAAsCV,IAAS,GAA/C,mBAAOgD,EAAP,KAAoBC,EAApB,KACA,EAA8BjD,IAAS,GAAvC,mBAAOkD,EAAP,KAAgBC,EAAhB,KAGA,EAAsBnD,GAAS,GAA/B,mBAAOoD,EAAP,KAAYC,EAAZ,KACA,EAA0BrD,GAAS,GAAnC,mBAAOsD,EAAP,KAAcC,EAAd,KAGAT,IAAU,WACRO,EAAOG,KAAKC,IAAIV,EAAUzC,EAAME,IAChC+C,EAASR,GAAWzC,EAAO,GAAK,KAC/B,CAACyC,EAASzC,EAAME,IAgBnB,OALAsC,IAAU,WACRG,EAAe3C,EAAO,EAAI,GAC1B6C,EAAWzC,GAAcJ,EAAO,KAC/B,CAACA,EAAMI,IAGR,oBAACgC,GAAD,CAAMgB,KAAK,QAAQ5D,UAAU,0BAC3B,oBAAC6C,GAAD,CAAU7C,UAAU,eAClB,oBAAC,GAAD,KACE,oBAAC,GAAD,KACGiC,QACC7C,EAAG,4BAA6B,iBAChCoE,EACAF,EACA5C,IAGJ,oBAAC,GAAD,KACE,oBAAC,GAAD,CAAMiC,QAAQ,YAEV,oBAACI,GAAD,KACE,oBAACD,GAAD,CACEe,aAAW,EACXC,UAAWZ,EACXa,QA7BD,WACftD,EAAQiD,KAAKM,IAAIxD,EAAO,EAAG,MA8BVpB,EAAG,WAAY,kBAElB,oBAAC0D,GAAD,CAAQe,aAAW,EAACC,UAAWV,EAASW,QApCvC,WACftD,EAAQiD,KAAKC,IAAI/C,EAAYJ,EAAO,MAoCnBpB,EAAG,OAAQ,yBCzDxBA,GAAOnE,GAAGoE,KAAVD,GACR,GAAwCnE,GAAGC,QAC3C,IADA,GAAQ+I,OAAR,GAAgBjB,UAAhB,GAA2B9C,SACsCjF,GAAGqE,YAA5DsD,GAAR,GAAQA,KAAMC,GAAd,GAAcA,SAIC,IAJf,GAAwBtD,KAAxB,GAA8BE,UAA9B,GAAyCqD,OAAzC,GAAiDC,YAIlC,YAA2C,IAAxCmB,EAAuC,EAAvCA,QAAShH,EAA8B,EAA9BA,KAAMiH,EAAwB,EAAxBA,WAAYC,EAAY,EAAZA,MAC3C,OAAKlH,EAAKmH,OAcR,oBAAC,GAAD,CAAMT,KAAK,QAAQ5D,UAAU,0BAC3B,oBAAC,GAAD,CAAUA,UAAU,eAClB,2BAAKA,UAAU,sBAAsBoE,GACrC,6BACEE,KAAK,QACLtE,UAAWuE,IAAW,eAAgB,CAAE,eAAgBJ,KAExD,6BAAOG,KAAK,YACV,0BAAIA,KAAK,OACNJ,GACCA,EAAQ7H,KAAI,SAACmI,GACX,OACE,0BAAIlI,IAAKkI,EAAOlI,IAAKgI,KAAK,gBACvBE,EAAOC,YAOpB,6BAAOH,KAAK,YACTpH,EAAKb,KAAI,SAACqI,EAAKC,GACd,OACE,0BACEL,KAAK,MACLhI,IAAG,cAASqI,GACZZ,QAAS,kBAAMI,GAAcA,EAAWO,KAEvCR,EAAQ7H,KAAI,SAACmI,EAAQI,GACpB,OACE,0BACEN,KAAK,OACLO,aAAYL,EAAOC,MACnBnI,IAAG,cAASqI,EAAT,YAAqBC,GACxBE,aAAYN,EAAOC,OAElBD,EAAOO,OACNP,EAAOO,OAAOL,GAEd,+BAAMF,EAAOlH,MAAMoH,gBAnDvC,oBAAC,GAAD,CAAMd,KAAK,QAAQ5D,UAAU,0BAC3B,oBAAC,GAAD,CAAUA,UAAU,eAClB,2BAAKA,UAAU,sBAAsBoE,GACrC,2BAAK1E,MAAO,CAAEb,QAAS,MACpBO,GAAG,qBAAsB,sBCb9BA,GAAOnE,GAAGoE,KAAVD,GACR,GAAgCnE,GAAGC,QACnC,IADA,GAAQ8H,UAAR,GAAmB9C,SACQjF,GAAGqE,YAAtBsD,GAAR,GAAQA,KAAMC,GAAd,GAAcA,SAKC,eAWR,IAAD,IAVJI,eAUI,MAVM,GAUN,EATJmB,EASI,EATJA,MACA5D,EAQI,EARJA,KACAC,EAOI,EAPJA,QACAH,EAMI,EANJA,QACAI,EAKI,EALJA,MACAE,EAII,EAJJA,WACAsD,EAGI,EAHJA,QACAhH,EAEI,EAFJA,KACA8H,EACI,EADJA,SAEA,OAAI1E,EAEA,oBAAC,GAAD,KACE,oBAAC2E,EAAD,OAKD/H,WAAMmH,OAcT,2BAAKrE,UAAU,aACb,oBAACkF,GAAD,CACEhI,KAAMA,EACNgH,QAASA,EACTjB,QAASA,EACTkB,WAAYa,EACZZ,MAAOA,MAGN1D,GACD,oBAACyE,GAAD,CACE3E,KAAMA,EACNC,QAASA,EACTwC,QAASA,EACTvC,MAAOA,EACPE,WAAYA,KA3BhB,oBAAC,GAAD,CAAMgD,KAAK,QAAQ5D,UAAU,eAC3B,oBAAC,GAAD,CAAUA,UAAU,eAClB,2BAAKA,UAAU,sBAAsBoE,GACrC,2BAAK1E,MAAO,CAAEb,QAAS,MACpBO,GAAG,qBAAsB,qB,6kBCjCtC,IAAQA,GAAOnE,GAAGoE,KAAVD,GACA4D,GAAc/H,GAAGC,QAAjB8H,UAQO5C,MAPKnF,GAAGmF,QAAfA,SAOe,CAACgF,KAAThF,EACb,YAWO,IAVLE,EAUI,EAVJA,QACAE,EASI,EATJA,KACAC,EAQI,EARJA,QACAC,EAOI,EAPJA,MACAE,EAMI,EANJA,WACA1D,EAKI,EALJA,KACA6D,EAII,EAJJA,MACAE,EAGI,EAHJA,UACAoE,EAEI,EAFJA,UACAC,EACI,EADJA,QAMAtC,IAAU,WACR/B,EAAU,CACRE,SAAU,wCACVC,OAAO,OACLG,SAPW,GAQP8D,EACA,CAAE7B,MAAOtB,EAA8BmD,IACvC,IACAC,EAAU,CAAEhC,IAAKpB,EAA8BoD,IAAa,QAGnE,CAAC9E,EAAM6E,EAAWC,IAGrB,IAIMpB,EAAU,CACd,CACE5H,IAAK,OACLmI,MAAOrF,GAAG,OAAQ,iBAClB9B,MAAO,SAACoH,GAAD,aAASA,SAAT,UAASA,EAAKa,YAAd,aAAS,EAAWvI,OAE7B,CACEV,IAAK,aACLmI,MAAOrF,GAAG,aAAc,iBACxB9B,MAAO,SAACoH,GAAD,eAASA,SAAT,UAASA,EAAKc,aAAd,iBAAS,EAAa,UAAtB,aAAS,EAAiBtI,OAEnC,CACEZ,IAAK,gBACLmI,MAAOrF,GAAG,gBAAiB,iBAC3B2F,OAAQ,SAACL,GAAD,eACN,2BAAK1E,UAAU,gBAAgB0E,SAA/B,UAA+BA,EAAKc,aAApC,iBAA+B,EAAa,UAA5C,aAA+B,EAAiBtI,SAKtD,OAAI6D,EACK,CAAEA,SAIT,oBAAC0E,GAAD,CACErB,MAAOhF,GAAG,YAAa,iBACvBoB,KAAMA,EACNyC,QAjDa,EAkDbxC,QAASA,EACTH,QAASA,EACTI,MAAOA,EACPE,WAAYA,EACZsD,QAASA,EACThH,KAAMA,EACN8H,SAAU,SAACN,GAAD,MAvCIhH,EAuCJ,OAvCIA,EAuCcgH,SAAD,UAACA,EAAKa,YAAN,aAAC,EAAW7H,QAtCzC5C,EAAQgC,KAAR,iBAAuBY,U,6kBCzC7B,IAAQ0B,GAAOnE,GAAGoE,KAAVD,GACA4D,GAAc/H,GAAGC,QAAjB8H,UAQO5C,MAPKnF,GAAGmF,QAAfA,SAOe,CAACgF,KAAThF,EACb,YAYO,IAXLE,EAWI,EAXJA,QACAE,EAUI,EAVJA,KACAC,EASI,EATJA,QACAC,EAQI,EARJA,MACAE,EAOI,EAPJA,WACA1D,EAMI,EANJA,KACA6D,EAKI,EALJA,MACAE,EAII,EAJJA,UACAoE,EAGI,EAHJA,UACAC,EAEI,EAFJA,QACAI,EACI,EADJA,OAMA1C,IAAU,WACR/B,EAAU,CACRE,SAAU,yCACVC,OAAO,UACLG,SAPW,IAQP8D,EACA,CAAE7B,MAAOtB,EAA8BmD,IACvC,IACAC,EAAU,CAAEhC,IAAKpB,EAA8BoD,IAAa,IAC5DI,EAAS,CAAEC,QAASD,GAAW,QAGtC,CAAClF,EAAM6E,EAAWC,IAErB,IAIMpB,EAAU,CACd,CACE5H,IAAK,OACLmI,MAAOrF,GAAG,OAAQ,iBAClB2F,OAHF,SAGSL,GACL,OACE,0BAAIhF,MAAO,CAAEkG,aAAc,EAAGC,UAAW,cACtCnB,EAAIoB,MAAM1B,MACPM,EAAIoB,MAAM1B,MACVhF,GAAG,WAAY,oBAK3B,CACE9C,IAAK,aACLmI,MAAOrF,GAAG,aAAc,iBACxB9B,MAHF,SAGQoH,GACJ,OAAOA,EAAIc,MAAM,GAAGtI,OAGxB,CACEZ,IAAK,gBACLmI,MAAOrF,GAAG,gBAAiB,iBAC3B2F,OAHF,SAGSL,GACL,OAAO,2BAAK1E,UAAU,gBAAgB0E,EAAIc,MAAM,GAAGtI,QAGvD,CACEZ,IAAK,YACLmI,MAAO,GACPM,OAHF,SAGSL,GACL,OACE,4BACEhF,MAAO,CACLqG,MAAO,yCAGR3G,GAAG,eAAgB,iBALtB,SAYR,OAAI2B,EACK,CAAEA,SAIT,oBAAC0E,GAAD,CACErB,MAAOhF,GAAG,YAAa,iBACvB6D,QAzEa,GA0EbzC,KAAMA,EACNC,QAASA,EACTH,QAASA,EACTI,MAAOA,EACPE,WAAYA,EACZsD,QAASA,EACThH,KAAMA,EACN8H,SAAU,SAACN,GAAS,IAAD,EAhELhH,IAiEHgH,SAAD,UAACA,EAAKoB,aAAN,aAAC,EAAYpI,GAhEzB5C,EAAQgC,KAAR,kBAAwBY,UCzCtBuC,GAAahF,GAAbgF,SAGRA,GAAS+F,IAAI/F,GAASgG,sBAAsBC,aAAaC,QACzDlG,GAAS+F,IACP/F,GAASmG,wBACPF,aAAaG,KAAOH,aAAaI,sBAItBrG,U,gmBCXf,I,GAAA,GAAwBhF,GAAGoE,KAAnBD,GAAR,GAAQA,GAAI6C,GAAZ,GAAYA,QACZ,GAA2BhH,GAAGqE,WAAhBuD,IAAd,GAAQD,KAAR,GAAcC,UACd,GAAwC5H,GAAGC,QAAnCgF,GAAR,GAAQA,SAAU8C,GAAlB,GAAkBA,UAOH,IAPf,GAA6BiB,OAOd,SAACjI,GACd,MAA8BkE,IAAS,GAAvC,mBAAOI,EAAP,KAAgBC,EAAhB,KACA,EAAoCL,GAAS,GAA7C,mBAAOqG,EAAP,KAAmBC,EAAnB,KACQnB,EAAuBrJ,EAAvBqJ,UAAWC,EAAYtJ,EAAZsJ,QACnB,EAA4BpF,GAAS,CACnC,CACElD,KAAM,QACNE,KAAM,MAHV,mBAAOuJ,EAAP,KAAeC,EAAf,KAOMC,EAAQ,CACZC,QAAS,CACPD,MAAO,CACLE,QAAS,CACPC,MAAM,IAGVC,MAAO,CACLpD,IAAK,EACLqD,OAAQ,CACNC,UAAW,SAAUC,GACnB,OAAIA,EAAM,EACD,EAEFxD,KAAKyD,IAAID,GAAO,IACnBxD,KAAK0D,KAAKF,IAAQxD,KAAKyD,IAAID,GAAO,KAAMG,QAAQ,GAAK,IACrD3D,KAAK0D,KAAKF,GAAOxD,KAAKyD,IAAID,GAAKG,QAAQ,MAIjDC,OAAQ,CAAC,WACTC,MAAO,CACLC,KAAM,WACN7D,IAAK,IAAIvB,KAAKiD,GAAWoC,SAAS,EAAG,EAAG,EAAG,GAC3CzD,IAAK,IAAI5B,KAAKkD,GAASmC,SAAS,GAAI,GAAI,GAAI,MAE9CC,WAAY,CACVC,SAAS,GAEXC,OAAQ,CAAEC,MAAO,UACjBlJ,KAAM,CACJ6I,KAAM,WACNM,SAAU,CACRC,eAAgB,EAChBC,YAAa,GACbC,UAAW,GACXC,MAAO,CAAC,EAAG,GAAI,SAOvBlF,IAAU,WACRmF,MACC,CAACnM,IAEJ,IAAMmM,EAAa,WACjB5H,GAAW,GACXN,GAAS,CACP1F,KACE,qCACA6N,OAAOC,MAAP,SACMhD,EACA,CAAE7B,MAAOtB,EAA8BmD,IACvC,IACAC,EAAU,CAAEhC,IAAKpB,EAA8BoD,IAAa,KAEpE1K,OAAO,IAEN4G,KAXH,+BAAAN,EAAA,MAWQ,WAAOO,GAAP,iBAAAP,EAAA,6DACJsF,EAAc/E,EAAIC,SAAWD,EAAIC,QAAQE,IAAI,eADzC,SAEeH,EAAII,OAFnB,OAEE3E,EAFF,OAIAuJ,EAAS,GACTvJ,EAAKmH,QACPnH,EAAKH,SAAQ,SAACuL,GACZ7B,EAAO3J,KAAK,CACV2B,EAAG6J,EAAKC,UACR7J,EAAG4J,EAAK5H,WAIdgG,EAAU,CACR,CACE1J,KAAM,QACNE,KAAMuJ,KAhBN,2CAXR,uDA+BG+B,OAAM,SAACC,GACN1G,QAAQhB,MAAM0H,MAEfC,SAAQ,WACPnI,GAAW,OAIjB,OAAID,EAEA,oBAAC,GAAD,KACE,oBAAC2E,EAAD,OAMJ,oBAAC,GAAD,CAAUjF,UAAU,eAClB,2BAAKA,UAAU,sBACZiC,GAAQ7C,GAAG,kBAAmB,iBAAkBmH,IAEnD,oBAAC,KAAD,CAAOK,QAASD,EAAMC,QAASH,OAAQA,EAAQe,KAAK,OAAO/J,OAAQ,SCzHzE,GAAwBxC,GAAGoE,KAAnBD,GAAR,GAAQA,GAAI6C,GAAZ,GAAYA,QACZ,GAA2BhH,GAAGqE,WAAhBuD,IAAd,GAAQD,KAAR,GAAcC,UACd,GAAwC5H,GAAGC,QAAnCgF,GAAR,GAAQA,SAAU8C,GAAlB,GAAkBA,UAOH,IAPf,GAA6BiB,OAOd,SAACjI,GACd,MAA8BkE,IAAS,GAAvC,mBAAOI,EAAP,KAAgBC,EAAhB,KACA,EAAsCL,GAAS,GAA/C,mBAAOyI,EAAP,KAAoBC,EAApB,KACQvD,EAAuBrJ,EAAvBqJ,UAAWC,EAAYtJ,EAAZsJ,QACnB,EAA4BpF,GAAS,CACnC,CACElD,KAAM,QACNE,KAAM,MAHV,mBAAOuJ,EAAP,KAAeC,EAAf,KAOMC,EAAQ,CACZC,QAAS,CACPD,MAAO,CACLE,QAAS,CACPC,MAAM,IAGVC,MAAO,CACLC,OAAQ,CACNC,UAAW,SAAUC,GACnB,OAAOxD,KAAKyD,IAAID,GAAO,IACnBxD,KAAK0D,KAAKF,IAAQxD,KAAKyD,IAAID,GAAO,KAAMG,QAAQ,GAAK,SACpD3D,KAAK0D,KAAKF,GAAOxD,KAAKyD,IAAID,IAAMG,QAAQ,GAAK,SAIxDC,OAAQ,CAAC,WACTC,MAAO,CACLC,KAAM,WACN7D,IAAK,IAAIvB,KAAKiD,GAAWoC,SAAS,EAAG,EAAG,EAAG,GAC3CzD,IAAK,IAAI5B,KAAKkD,GAASmC,SAAS,GAAI,GAAI,GAAI,MAE9CC,WAAY,CACVC,SAAS,GAEXC,OAAQ,CAAEC,MAAO,UACjBlJ,KAAM,CACJ6I,KAAM,WACNM,SAAU,CACRC,eAAgB,EAChBC,YAAa,GACbC,UAAW,GACXC,MAAO,CAAC,EAAG,GAAI,SAOvBlF,IAAU,WACR6F,MACC,CAAC7M,IAEJ,IT7D2B8M,EACrBC,EACAC,EACAC,EAEFC,ESwDEL,EAAe,WACnBtI,GAAW,GACXN,GAAS,CACP1F,KACE,0CACA6N,OAAOC,MAAM,CACX7E,MAAOtB,EAA8BmD,GACrC/B,IAAKpB,EAA8BoD,KAEvC1K,OAAO,IAEN4G,KATH,+BAAAN,EAAA,MASQ,WAAOO,GAAP,qBAAAP,EAAA,sEAC4BO,EAAII,OADhC,gBACI3E,EADJ,EACIA,KAAMiM,EADV,EACUA,QAEdP,EAAeQ,WAAWD,IAEtB1C,EAAS,GACTvJ,EAAKmH,QACPnH,EAAKH,SAAQ,SAACuL,GACZ7B,EAAO3J,KAAK,CACV2B,EAAG6J,EAAKC,UACR7J,GAAI4J,EAAK5H,MAAQ,IAAI2G,QAAQ,QAInCX,EAAU,CACR,CACE1J,KAAM,aACNE,KAAMuJ,KAjBN,2CATR,uDA8BG+B,OAAM,SAACC,GACN1G,QAAQhB,MAAM0H,MAEfC,SAAQ,WACPnI,GAAW,OAIjB,OAAID,EAEA,oBAAC,GAAD,KACE,oBAAC2E,EAAD,OAMJ,oBAAC,GAAD,CAAUjF,UAAU,eAClB,2BAAKA,UAAU,sBACZiC,GACC7C,GAAG,wBAAyB,kBTjHT0J,ESkHNH,ETjHfI,EAAQrF,KAAK2F,MAAMP,EAAe,GAAK,IACvCE,EAAUtF,KAAK2F,MAAMP,EAAe,IAAc,GAARC,EAC1CE,EAAUH,EAAe,GAE3BI,EAAM,GACNH,IACFG,GAAOjH,EAAQ7C,EAAG,WAAY,iBAAkB2J,GAAS,MAEvDC,IACFE,GAAOjH,EAAQ7C,EAAG,aAAc,iBAAkB4J,GAAW,MAE1DD,GAASC,IAAYC,IACxBC,GAAO9J,EAAG,MAAO,iBAAmB,KAGtC8J,GAAOjH,EAAQ7C,EAAG,aAAc,iBAAkB6J,MSqG9C,oBAAC,KAAD,CAAOrC,QAASD,EAAMC,QAASH,OAAQA,EAAQe,KAAK,OAAO/J,OAAQ,SCvHjE2B,GAAOnE,GAAGoE,KAAVD,GACR,GAA4BnE,GAAGqE,WAAvBgK,GAAR,GAAQA,MAAOC,GAAf,GAAeA,SAKA,eAA6B,IAA1BlE,EAAyB,EAAzBA,UAAWC,EAAc,EAAdA,QAC3B,OACE,oBAACgE,GAAD,KACE,oBAACC,GAAD,CACEvJ,UAAU,qBACVgF,SAAU,aACVwE,KAAM,CACJ,CACExM,KAAM,QACNoH,MAAOhF,GAAG,QAAS,kBAErB,CACEpC,KAAM,QACNoH,MAAOhF,GAAG,aAAc,qBAI3B,SAACqK,GACA,OAAQA,EAAIzM,MACV,IAAK,QACH,OACE,oBAAC0M,GAAD,CAAiBrE,UAAWA,EAAWC,QAASA,IAEpD,IAAK,QACH,OACE,oBAACqE,GAAD,CAAiBtE,UAAWA,EAAWC,QAASA,IAEpD,QACE,OAAO,2D,oBClCblG,I,MAAOnE,GAAGoE,KAAVD,IACR,GAAwCnE,GAAGC,QAAnC+I,GAAR,GAAQA,OAAQjB,GAAhB,GAAgBA,UAAW9C,GAA3B,GAA2BA,SAKZ,eAAuD,IAApDmF,EAAmD,EAAnDA,UAAWuE,EAAwC,EAAxCA,aAActE,EAA0B,EAA1BA,QAASuE,EAAiB,EAAjBA,WAC5CC,EAAU7F,KAChB,EAAkC/D,GAAS,IAA3C,mBAAO6J,EAAP,KAAkBC,EAAlB,KAiCA,OA9BAhH,IAAU,WACK,IAAIiH,KAAW,CAC1B/O,QAAS4O,aAAF,EAAEA,EAASI,QAClBC,YAAY,EACZC,OAAQ,cACRC,WAAW,EACXC,QAAS,CAAC,UACVC,QAAS,IAAInI,KACboI,eAAgB,EAChBC,WAAY,CACVC,MAAOtL,GAAG,QAAS,iBACnBuL,OAAQvL,GAAG,SAAU,kBAEvBwL,UAAW,CACTC,QAAS,KACTC,QAAS,KACTC,QAAQ,EACRC,OAAO,GAETC,MAAO,SAACC,GACNA,EAAOC,aAAa9F,EAAWC,GAC/B4F,EAAOE,GAAG,gBAAgB,SAAC5H,EAAOF,GAChCsG,EAAapG,EAAM6H,cACnBxB,EAAWvG,EAAI+H,cACfrB,EAAaF,EAAQI,QAAQ5M,MAAM+G,gBAIxC,CAACyF,IAGF,2BAAK9J,UAAU,0BACb,2BAAKA,UAAU,kCACb,6BACEA,UAAU,8DACVsL,IAAKxB,EACLlG,KAAMmG,O,qCC7CR3K,GAAOnE,GAAGoE,KAAVD,GACR,GAAsCnE,GAAGqE,WAAjCC,GAAR,GAAQA,KAAME,GAAd,GAAcA,UAAWD,GAAzB,GAAyBA,SACzB,GAAgCvE,GAAGC,QAA3BgF,GAAR,GAAQA,SAAU8C,GAAlB,GAAkBA,UAUH,eAA6D,IAAjDqC,EAAgD,EAAhDA,UAAWC,EAAqC,EAArCA,QAASsE,EAA4B,EAA5BA,aAAcC,EAAc,EAAdA,WAC3D,EAAwC3J,IAAS,GAAjD,mBAAOqL,EAAP,KAAqBC,EAArB,KAWA,OARAxI,IAAU,WACR/C,KAAS,CAAE1F,KAAM,oBAAqBiH,MAAK,SAACiK,GAAU,IAAD,GACL,KAA1CA,SAAA,UAAAA,EAAMC,+BAAN,eAA+BC,SACjCH,GAAgB,QAGnB,IAGD,iCAEGD,EAAe,aAAC,GAAD,MAAe,GAC/B,aAAC,GAAD,KACE,aAAC,GAAD,KACE,uBAAKnM,GAAG,YAAa,mBAEvB,aAAC,GAAD,KACE,aAACwM,GAAD,CACEvG,UAAWA,EACXuE,aAAcA,EACdtE,QAASA,EACTuE,WAAYA,MAKlB,oBAAK7J,UAAU,eACb,oBAAKA,UAAU,oBACb,oBAAKA,UAAU,yBACb,oBAAKA,UAAU,mCACb,aAAC6L,GAAD,CAAexG,UAAWA,EAAWC,QAASA,KAEhD,oBAAKtF,UAAU,0BACb,aAAC8L,GAAD,CAAUzG,UAAWA,EAAWC,QAASA,MAI7C,oBAAKtF,UAAU,yBACb,oBAAKA,UAAU,mCACb,aAAC+L,GAAD,CAAW1G,UAAWA,EAAWC,QAASA,UASlD0G,GAAW,kBACf,aAAC,UAAD,CACEC,IAAKA,aAAF,uEAGHC,OAAO,UACPC,eAAe,GAEf,sBACG/M,GACC,8FACA,oBC7ER,GAA2BnE,GAAGqE,WAAtBsD,GAAR,GAAQA,KAAMC,GAAd,GAAcA,SAGC,eAAuC,IAApCvC,EAAmC,EAAnCA,QAAS8D,EAA0B,EAA1BA,MAAO9G,EAAmB,EAAnBA,MAAOmH,EAAY,EAAZA,MACvC,OAAInE,EAEA,oBAAC,GAAD,KACE,oBAAC,GAAD,KACE,oBAAC2E,EAAD,QAON,oBAAC,GAAD,CAAMjF,UAAU,4BACd,oBAAC,GAAD,KACE,2BAAKA,UAAU,mBAAmBoE,GAClC,8BAAK9G,GACL,+BAAMmH,M,6kBChBd,I,SAAQxE,GAAahF,GAAbgF,SACAC,GAAajF,GAAGC,QAAhBgF,SACAC,GAA+BlF,GAAGmF,QAAlCD,2BAOO,qBACbA,IACE,SAACE,GAAD,OAAsB,SAACrE,GACrB,MAA8BkE,IAAS,GAAvC,mBAAOI,EAAP,KAAgBC,EAAhB,KACA,EAAwBL,GAAS,IAAjC,mBAAOkM,EAAP,KAAaC,EAAb,KACA,EAA0BnM,GAAS,IAAnC,mBAAOa,EAAP,KAAcC,EAAd,KAKMC,EAAS,uCAAG,mCAAAC,EAAA,6DAASC,EAAT,EAASA,SAAT,IAAmBC,cAAnB,MAA4B,GAA5B,EAChBb,GAAW,GADK,kBAKON,GAAS,CAC5B1F,KAAMU,GAAGoG,IAAIC,aAAaH,EAApB,MACDC,MAPO,OAKdU,EALc,OAUduK,EAAQvK,GAVM,gDAYdC,QAAQhB,MAAR,MACA,4BAAI,KAAGiB,SACLhB,EAAS,KAAEgB,SAdC,yBAiBdzB,GAAW,GAjBG,4EAAH,sDAqBf,OACE,oBAACF,EAAD,eACEC,QAASA,EACTC,WAAYA,EACZU,UAAWA,EACXmL,KAAMA,EACNC,QAASA,EACTtL,MAAOA,EACPC,SAAUA,GACNhF,OAIV,aCxDIoD,GAAOnE,GAAGoE,KAAVD,GACAgB,GAAYnF,GAAGmF,QAAfA,QACA4C,GAAc/H,GAAGC,QAAjB8H,UAMO5C,MAAQ,CAACkM,MAATlM,EAAsB,SAACpE,GACpC,IAAQ0J,EAAyD1J,EAAzD0J,OAAQL,EAAiDrJ,EAAjDqJ,UAAWC,EAAsCtJ,EAAtCsJ,QAAS8G,EAA6BpQ,EAA7BoQ,KAAMnL,EAAuBjF,EAAvBiF,UAAWX,EAAYtE,EAAZsE,QAYrD,OAVA0C,IAAU,WACR/B,EAAU,CACRE,SAAS,oCAAD,OAAsCuE,EAAtC,gBACRtE,OAAQ,CACNoC,MAAOtB,EAA8BmD,GACrC/B,IAAKpB,EAA8BoD,QAGtC,CAACD,EAAWC,IAGb,oBAACiH,GAAD,CACEjM,QAASA,EACThD,MAAOqE,SAASyK,aAAD,EAACA,EAAMI,MACtBpI,MAAOhF,GAAG,cAAe,sBCzBvBA,GAAOnE,GAAGoE,KAAVD,GACAgB,GAAYnF,GAAGmF,QAAfA,QACA4C,GAAc/H,GAAGC,QAAjB8H,UAMO5C,MAAQ,CAACkM,MAATlM,EAAsB,SAACpE,GACpC,IAAQ0J,EAAyD1J,EAAzD0J,OAAQL,EAAiDrJ,EAAjDqJ,UAAWC,EAAsCtJ,EAAtCsJ,QAAS8G,EAA6BpQ,EAA7BoQ,KAAMnL,EAAuBjF,EAAvBiF,UAAWX,EAAYtE,EAAZsE,QAYrD,OAVA0C,IAAU,WACR/B,EAAU,CACRE,SAAS,oCAAD,OAAsCuE,EAAtC,sBACRtE,OAAQ,CACNoC,MAAOtB,EAA8BmD,GACrC/B,IAAKpB,EAA8BoD,QAGtC,CAACD,EAAWC,IAGb,oBAACiH,GAAD,CACEjM,QAASA,EACThD,MAAO8L,WAAWgD,aAAD,EAACA,EAAMI,MAAMnF,QAAQ,GACtCjD,MAAOhF,GAAG,qBAAsB,iBAChCqF,MAAOrF,GAAG,UAAW,sBC1BnBA,GAAOnE,GAAGoE,KAAVD,GACAgB,GAAYnF,GAAGmF,QAAfA,QACA4C,GAAc/H,GAAGC,QAAjB8H,UAMO5C,MAAQ,CAACkM,MAATlM,EAAsB,SAACpE,GACpC,IAAQ0J,EAAyD1J,EAAzD0J,OAAQL,EAAiDrJ,EAAjDqJ,UAAWC,EAAsCtJ,EAAtCsJ,QAAS8G,EAA6BpQ,EAA7BoQ,KAAMnL,EAAuBjF,EAAvBiF,UAAWX,EAAYtE,EAAZsE,QAYrD,OAVA0C,IAAU,WACR/B,EAAU,CACRE,SAAS,oCAAD,OAAsCuE,EAAtC,oBACRtE,OAAQ,CACNoC,MAAOtB,EAA8BmD,GACrC/B,IAAKpB,EAA8BoD,QAGtC,CAACD,EAAWC,IAGb,oBAACiH,GAAD,CACEjM,QAASA,EACThD,MAAO8L,WAAWgD,aAAD,EAACA,EAAMI,MAAMnF,QAAQ,GACtCjD,MAAOhF,GAAG,mBAAoB,iBAC9BqF,MAAOrF,GAAG,UAAW,sBCxBnBA,GAAOnE,GAAGoE,KAAVD,GAER,GAAuDnE,GAAGqE,WAAlDC,GAAR,GAAQA,KAAME,GAAd,GAAcA,UAAWD,GAAzB,GAAyBA,SAAUiD,GAAnC,GAAmCA,QAASK,GAA5C,GAA4CA,OAS5C,GAAgC7H,GAAGC,QAA3B8H,GAAR,GAAQA,UAAW9C,GAAnB,GAAmBA,SACXD,GAAahF,GAAbgF,SA4JOwM,GAxJF,SAAC,GAA6D,IAAD,QAA1DrR,EAA0D,EAA1DA,MAAOiK,EAAmD,EAAnDA,UAAWC,EAAwC,EAAxCA,QAASsE,EAA+B,EAA/BA,aAAcC,EAAiB,EAAjBA,WACvD,EAA8B3J,IAAS,GAAvC,mBAAOI,EAAP,KAAgBC,EAAhB,KACA,EAAwBL,GAAS,IAAjC,mBAAOqF,EAAP,KAAamH,EAAb,KACA,EAA0BxM,GAAS,IAAnC,mBAAOa,EAAP,KAAcC,EAAd,KAMM2L,EAAO,uCAAG,8BAAAzL,EAAA,6DACdX,GAAW,GADG,kBAGKN,GAAS,CACxBoB,IAAI,wBAAD,OAA0BjG,SAA1B,UAA0BA,EAAOgG,cAAjC,aAA0B,EAAe1D,GAAzC,mBAJO,OAGR6H,EAHQ,OAMZmH,EAAQnH,GANI,gDAQG,kBAAX,KAAEqH,MACJ5L,EAAS,kBATC,yBAYZT,GAAW,GAZC,4EAAH,qDAoBb,OAJAyC,IAAU,WACR2J,MACC,IAEC5L,EAEA,oBAAKf,UAAU,eACb,aAAC,GAAD,KACE,aAAC,GAAD,KACE,uBAAKe,MAQb,oBAAKf,UAAU,eACb,aAAC,GAAD,KACE,aAAC,GAAD,KACE,aAAC,GAAD,CAAQ6D,aAAW,EAACE,QAxCf,WACXjJ,EAAQgC,KAAR,QAuCM,KACUsC,GAAG,oBAAqB,oBAItC,aAAC,GAAD,CAAMyN,MAAI,GACR,aAAC,GAAD,KACGvM,EACC,aAAC,GAAD,MAEA,oBACE2L,IAAKA,aAAF,4eAkBH,wBACE,mBAAIjM,UAAU,2BAA2BuF,aAAzC,EAAyCA,EAAMvI,MAC/C,kBACEiP,IAAKA,aAAF,6HAKF1G,aANH,EAMGA,EAAMuH,UAGRvH,EAAK7H,IACN,oBACEsC,UAAU,2BACViM,IAAKA,aAAF,sFAIH,aAAC,GAAD,CACEnM,KAAI,0CAAqCyF,aAArC,EAAqCA,EAAM7H,IAC/CmG,aAAW,EACXkJ,SAAO,GAEN3N,GAAG,eAAgB,iBALtB,SAYV,aAAC,GAAD,KACE,aAACwM,GAAD,CACEvG,UAAWA,EACXuE,aAAcA,EACdtE,QAASA,EACTuE,WAAYA,MAKlB,oBAAK7J,UAAU,gCACb,oBAAKA,UAAU,yBACb,oBAAKA,UAAU,0BACb,aAACgN,GAAD,CACEtH,OAAQtK,SAAF,UAAEA,EAAOgG,cAAT,aAAE,EAAe1D,GACvB2H,UAAWA,EACXC,QAASA,KAGb,oBAAKtF,UAAU,0BACb,aAACiN,GAAD,CACEvH,OAAQtK,SAAF,UAAEA,EAAOgG,cAAT,aAAE,EAAe1D,GACvB2H,UAAWA,EACXC,QAASA,KAGb,oBAAKtF,UAAU,0BACb,aAACkN,GAAD,CACExH,OAAQtK,SAAF,UAAEA,EAAOgG,cAAT,aAAE,EAAe1D,GACvB2H,UAAWA,EACXC,QAASA,MAIf,oBAAKtF,UAAU,yBACb,oBAAKA,UAAU,mCACb,aAAC+L,GAAD,CACE1G,UAAWA,EACXC,QAASA,EACTI,OAAQtK,SAAF,UAAEA,EAAOgG,cAAT,aAAE,EAAe1D,UCjK7B0B,GAAOnE,GAAGoE,KAAVD,GACAgB,GAAYnF,GAAGmF,QAAfA,QACA4C,GAAc/H,GAAGC,QAAjB8H,UAMO5C,MAAQ,CAACkM,MAATlM,EAAsB,SAACpE,GACpC,IAAQmR,EAA2DnR,EAA3DmR,SAAU9H,EAAiDrJ,EAAjDqJ,UAAWC,EAAsCtJ,EAAtCsJ,QAAS8G,EAA6BpQ,EAA7BoQ,KAAMnL,EAAuBjF,EAAvBiF,UAAWX,EAAYtE,EAAZsE,QAYvD,OAVA0C,IAAU,WACR/B,EAAU,CACRE,SAAS,qCAAD,OAAuCgM,EAAvC,sBACR/L,OAAQ,CACNoC,MAAOtB,EAA8BmD,GACrC/B,IAAKpB,EAA8BoD,QAGtC,CAACD,EAAWC,IAGb,oBAACiH,GAAD,CACEjM,QAASA,EACThD,MAAOqE,SAASyK,GAChBhI,MAAOhF,GAAG,qBAAsB,iBAChCqF,MAAOrF,GAAG,UAAW,sBC1B3B,GAAwBnE,GAAGoE,KAAnBD,GAAR,GAAQA,GACR,IADA,GAAY6C,QACehH,GAAGqE,YAAtBsD,GAAR,GAAQA,KAAMC,GAAd,GAAcA,SACd,GAAwC5H,GAAGC,QAAnCgF,GAAR,GAAQA,SAAU8C,GAAlB,GAAkBA,UAOH,IAPf,GAA6BiB,OAOd,SAACjI,GACd,IAAQmR,EAAiCnR,EAAjCmR,SAAU9H,EAAuBrJ,EAAvBqJ,UAAWC,EAAYtJ,EAAZsJ,QAC7B,EAA8BpF,IAAS,GAAvC,mBAAOI,EAAP,KAAgBC,EAAhB,KAEA,EAA4BL,GAAS,CACnC,CACElD,KAAM,QACNE,KAAM,MAHV,mBAAOuJ,EAAP,KAAeC,EAAf,KA4CA1D,IAAU,WApCRzC,GAAW,GACXN,GAAS,CACP1F,KAAMU,GAAGoG,IAAIC,aAAP,4CACiC6L,EADjC,aAEJ,CACE3J,MAAOtB,EAA8BmD,GACrC/B,IAAKpB,EAA8BoD,OAItC9D,MAAK,SAACtE,GACL,IAAIuJ,EAAS,GACTvJ,EAAKmH,QACPnH,EAAKH,SAAQ,SAACuL,GAEZ7B,EAAO3J,KAAK,CACV2B,EAAG6J,EAAK8E,WACR1O,EAAG4J,EAAK5H,WAIdgG,EAAU,CACR,CACE1J,KAAM,UACNE,KAAMuJ,QAIX+B,OAAM,SAACC,GACN1G,QAAQhB,MAAM0H,MAEfC,SAAQ,WACPnI,GAAW,QAMd,CAAC8E,EAAWC,IAEf,IAAMqB,EAAQ,CACZC,QAAS,CACPD,MAAO,CACLE,QAAS,CACPC,MAAM,IAGVuG,WAAY,EACZtG,MAAO,CACLC,OAAQ,CACNC,UAAW,SAAUC,GACnB,OAAOvF,SAASuF,MAItBK,MAAO,CACLP,OAAQ,CACNC,UAAW,SAAUC,GACnB,OpBxDc+B,EoBwDG/B,EpBvD3B+B,EAAmC,IAAzBtH,SAASsH,GAAW,GACvB,IAAI7G,KAAK6G,GAAS1G,cAAc1G,OAAO,GAAI,GAF3B,IAACoN,KoB4DpB3B,OAAQ,CAAC,WACTI,WAAY,CACVC,SAAS,GAEXC,OAAQ,CAAEC,MAAO,UACjBlJ,KAAM,CACJ6I,KAAM,WACNM,SAAU,CACRC,eAAgB,EAChBC,YAAa,GACbC,UAAW,GACXC,MAAO,CAAC,EAAG,GAAI,SAMvB,OAAI5H,EAEA,oBAAC,GAAD,KACE,oBAAC,GAAD,KACE,oBAAC2E,EAAD,QAON,oBAAC,GAAD,KACE,oBAAC,GAAD,KACE,2BAAKjF,UAAU,sBACZZ,GAAG,qBAAsB,kBAE5B,oBAAC,KAAD,CACEwH,QAASD,EAAMC,QACfH,OAAQA,EACRe,KAAK,OACL/J,OAAQ,UCxHV2B,GAAOnE,GAAGoE,KAAVD,GACAgB,GAAYnF,GAAGmF,QAAfA,QACA4C,GAAc/H,GAAGC,QAAjB8H,UAMO5C,MAAQ,CAACkM,MAATlM,EAAsB,SAACpE,GACpC,IAAQmR,EAA2DnR,EAA3DmR,SAAU9H,EAAiDrJ,EAAjDqJ,UAAWC,EAAsCtJ,EAAtCsJ,QAAS8G,EAA6BpQ,EAA7BoQ,KAAMnL,EAAuBjF,EAAvBiF,UAAWX,EAAYtE,EAAZsE,QAavD,OAVA0C,IAAU,WACR/B,EAAU,CACRE,SAAS,qCAAD,OAAuCgM,EAAvC,UACR/L,OAAQ,CACNoC,MAAOtB,EAA8BmD,GACrC/B,IAAKpB,EAA8BoD,QAGtC,CAACD,EAAWC,IAGb,oBAACiH,GAAD,CACEjM,QAASA,EACThD,MAAOqE,SAASyK,GAChBhI,MAAOhF,GAAG,eAAgB,sB,iECpBnB,GAAkB,SAAC,GAAD,OAC7B,EAAI,QAAQ,YAAY,SAAC,GAAD,iBAAmB,EAAE,GAAG,mB,SCiCrC,GAAe,SAAC,EAAyB,EAAe,GACnE,IAAM,EAAuB,EAAS,WAAa,EAAS,MACtD,EAAuB,EAAS,WAAa,EAAS,MAEtD,EAAiB,GAAW,GAC5B,EAAsB,GAAW,EAAe,EAAa,MAAM,KAAO,IAC1E,EAAiB,GAAW,EAAe,EAAa,MAAM,KAAO,IACpE,EAA2B,GAclC,OAXA,EAAe,SAAQ,SAAC,GAClB,EAAoB,IAAI,IAE1B,EAAgB,KAAK,GACrB,EAAoB,OAAO,IACjB,EAAe,IAAI,IAE7B,EAAgB,KAAK,MAGzB,EAAoB,SAAQ,SAAC,GAAD,OAAQ,EAAe,KAAK,MACjD,EAAgB,KAAK,MAOhB,GAAkB,SAACkO,GAC/B,GAAwB,oBAAb,SACT,OAAO,EAEP,IAAO,EAAW,KAAO,EACpB,EAAa,KAAa,SAE/B,IAAK,EAAa,CAChB,IAAM,EAAU,SAAS,cAAc,OACvC,EAAQ,aAAa,EAAW,WAChC,EAAqD,mBAA/B,EAAgB,GAGxC,OAAO,GAIE,GAAY,SACvB,EACA,EACA,GAEA,IAAM,EAAa,EAAK,WAAa,EAAK,SAAW,IAC/C,EAAkB,EAAW,GAG/B,GACF,EAAK,oBAAoB,EAAW,GAItC,EAAK,iBACH,EACC,EAAW,GAAa,SAAiB,GACpC,GACF,EAAgB,KAAK,KAAM,MAM7B,GAAa,SAAC,GAClB,IAAM,EAAM,IAAI,IAEhB,OADC,EAAiB,SAAQ,SAAC,GAAD,OAAe,EAAI,IAAI,EAAG,MAC7C,GCrGI,GAAS,SAAC,EAAiE,GACnE,mBAAR,EACT,EAAI,GACY,MAAP,IAER,EAAoC,QAAU,IAItC,GAAY,WAEG,2BADvB,EACuB,yBADvB,EACuB,gBAC1B,OAAO,SAAC,GACN,EAAK,SAAQ,YACX,GAAO,EAAK,Q,0xBCNL,GAAuB,SAMlC,EACA,EACA,EAIA,QAE4B,IAAxB,GACF,IAGF,IAAO,EAA8B,EHnClC,cACA,MAAM,KACN,KAAI,SAAC,GAAD,OAAa,EAAQ,OAAO,GAAG,cAAgB,EAAQ,MAAM,MACjE,KAAK,IGiCD,EAAa,0CAOlB,WAAY,GAA6C,mCACvD,cAAM,IALR,kBAAoB,SAAC,GACnB,EAAK,YAAc,GAGoC,EAPvC,sDAWlB,WACE,KAAK,mBAAmB,KAAK,SAZb,gCAelB,SAAmB,IFnDI,SAAC,EAAmB,GAAqC,IAAtB,EAAsB,uDAAN,GAE5E,GAAI,aAAgB,QAAS,CAE3B,IAAO,EAAW,GAAa,EAAK,UAAW,EAAU,GACvC,KAAd,IACF,EAAK,UAAY,GAGnB,OAAO,KAAK,GAAU,SAAQ,SAAC,GAC7B,GACW,aAAT,GACS,UAAT,GACS,QAAT,GACS,UAAT,GACS,cAAT,GACS,iBAAT,EAIF,GAA2B,IAAvB,EAAK,QAAQ,OAAe,EAAK,KAAO,EAAK,GAAG,cAAe,CACjE,IAAO,EAAW,EAAK,UAAU,GAC3B,EAAc,EAAU,GAAG,cAAgB,EAAU,UAAU,GAEhE,GAAiB,IACpB,GAAU,EAAM,EAAa,EAAS,QAEnC,CACJ,EAAa,GAAQ,EAAS,GAEd,WADH,aAAU,EAAS,KAE/B,EAAK,aAAa,GAAgB,GAAO,EAAS,SEqBtD,CAAY,KAAK,YAAa,KAAK,MAAO,KAhB1B,oBAmBlB,WACQ,MAA+D,KAA/D,MAAE,EAA6C,EAA7C,SAAU,EAAmC,EAAnC,aAAc,EAAqB,EAArB,MAA0B,GAAL,EAAd,UAAc,EAAH,IAAc,KAA1D,wDAEF,EAAc,OAAO,KAAK,GAAQ,QAAO,SAAC,EAAK,GACjD,GAA2B,IAAvB,EAAK,QAAQ,OAAe,EAAK,KAAO,EAAK,GAAG,cAAe,CACjE,IAAM,EAAY,EAAK,UAAU,GAAG,cACZ,oBAAb,UAA4B,GAAiB,KACrD,EAAY,GAAS,EAAe,SAGtC,EAAY,GAAS,EAAe,GAEvC,OAAO,IACN,IAEC,IACF,EAAc,EAAwB,KAAK,MAAO,IAGpD,IAAM,EAAQ,+BACT,GAAW,CACd,IAAK,GAAU,EAAc,KAAK,mBAClC,UAGF,OAAO,KAAM,cAAc,EAAS,EAAU,MA5C9B,wBA+ClB,WACE,OAAO,MAhDS,GAAiB,KAAM,WAyD3C,OAJI,IACF,EAAe,YAAc,GD9DD,SAC9B,EACA,GAEA,IAAM,EAAa,SACjB,EACA,GAEA,OAAO,mBAAC,EAAc,iBAAK,EAAK,CAAE,aAAc,MAIlD,OAFA,EAAW,YAAc,EAElB,KAAM,WAAW,GCqDjB,CAAwC,EAAgB,ICtEpD,GAA4B,GAAgE,iBCzBzG,GAA8BrS,GAAGC,QAAjC,GAAQ+I,OAAR,GAAgBjB,UAsFT,SAASuK,GAAYC,GAG1B,GAAIA,EAAK,CAIP,GAF0BA,EAAI7R,MADhB,wHAIZ,MAAO,UAMT,GAFwB6R,EAAI7R,MADd,iFAIZ,MAAO,QAGT,GAAI6R,EAAIC,QAAQ,gBAAkB,GAAKD,EAAIC,QAAQ,cAAgB,EACjE,MAAO,QAGT,GAAID,EAAIC,QAAQ,SAAW,EACzB,MAAO,QAGX,MAzBiB,c,6kBCrFnB,IAAQC,GAAczS,GAAGiC,KAAjBwQ,UAEO,eAWR,IAAD,EA8B8B,IAxClCF,EAUI,EAVJA,IACAG,EASI,EATJA,QACAC,EAQI,EARJA,OACAC,EAOI,EAPJA,SACAC,EAMI,EANJA,WACAC,EAKI,EALJA,aACAC,EAII,EAJJA,YAII,IAHJC,eAGI,MAHM,WAGN,EAFJC,EAEI,EAFJA,SACA1G,EACI,EADJA,KAEQ2G,EAAyCL,EAAzCK,SAAUC,EAA+BN,EAA/BM,aAAcC,EAAiBP,EAAjBO,aAE1BC,EAAUZ,IAAU,SAACa,GAAY,IAAD,EACpC,iBAAOA,EAAO,+BAAd,aAAO,EAAgCD,aAGnCrC,EAAMyB,IAAU,SAACa,GAAY,IAAD,EAChC,iBAAOA,EAAO,+BAAd,aAAO,EAAgCC,eA2CzC,OACE,2BACExO,UAAW,oCACXN,MACW,UAAT8H,EAAA,UAEM,gCAAgC,GAAhC,OAAoCoG,aAApC,EAAoCA,EAAQa,cAA5C,OACIb,WAAQc,iBACR,CACE,mCAAoCd,EAAOc,kBAE7C,CAAE,mCAAoCb,aAApC,EAAoCA,EAAU9H,QAChD6H,WAAQe,cACR,CACE,6BAA8Bf,EAAOe,cACrC,gCAAiCf,EAAOe,cACxC,+BAAgCf,EAAOe,cACvC,4CAzDC,SAACC,GAA0B,IAAjB/P,EAAgB,uDAAN,EACjCgQ,EAAMD,EAAQE,QAAQ,IAAK,IAEZ,IAAfD,EAAIxK,SACNwK,EAAMA,EAAI,GAAKA,EAAI,GAAKA,EAAI,GAAKA,EAAI,GAAKA,EAAI,GAAKA,EAAI,IAGzD,IAAI3P,EAAIyC,SAASkN,EAAIE,UAAU,EAAG,GAAI,IACpCC,EAAIrN,SAASkN,EAAIE,UAAU,EAAG,GAAI,IAClCE,EAAItN,SAASkN,EAAIE,UAAU,EAAG,GAAI,IAOpC,OAJIlQ,EAAU,GAAKA,GAAW,MAC5BA,GAAoB,KAGf,QAAUK,EAAI,IAAM8P,EAAI,IAAMC,EAAI,IAAMpQ,EAAU,IAyCIqQ,CAC3CtB,EAAOe,gBAAiBd,aAAxB,EAAwBA,EAAU9H,QAAS,UAC3C,KAGJ,CACE,6BAA8B,UAC9B,gCAAiC,UACjC,+BAAgC,YArB5C,IAuBM,4BAA4B,QAvBlC,UA0BM,gCAAgC,GAAhC,OAAoC6H,aAApC,EAAoCA,EAAQa,cAA5C,OACIb,WAAQuB,mBACR,CAAE,6BAA8BvB,EAAOuB,oBACvC,IACAtB,WAAU9H,MACV,CAAE,oBAAqB8H,EAAS9H,OAChC,IAhCV,IAiCM,sCAAsC,GAAtC,QACE6H,SAAA,UAAAA,EAAQwB,wBAAR,eAA0BX,gBAAiB,EAD7C,MAGA,6BAA6B,GAA7B,QAAiCZ,aAAA,EAAAA,EAAUwB,aAAc,GAAzD,SAIR,oBAACC,GAAD,CACE9B,IAAKA,EACLvB,IAAKA,EACL0B,QAASA,EACTK,YAAaA,EACbE,SAAUA,EACVqB,SAAS,EACTtB,QAASA,EACTL,OAAQA,EACR4B,MAAO,CACLC,UAAW3B,aAAF,EAAEA,EAAY4B,iBACvBC,QAAS7B,aAAF,EAAEA,EAAY6B,SAEvBrB,QAAS,CACPsB,UAAWtB,aAAF,EAAEA,EAASuB,YAEtBC,SACIlC,YAAQmC,WAAY,CACpB,CACEC,KAAM,WACNvL,MAAO,UACPwL,QAAS,KACTzC,IAAK,2BACL0C,SAAS,IAIfrC,SAAUA,EACVM,SAAUA,EACVgC,gBAAiBrC,EACjBsC,OAAQtC,EAAWsC,OACnBC,SAAmB,UAAT7I,EAAmB,QAAU+F,GAAYC,GACnD8C,WAAYxC,EAAW1J,OAEvB,2BAAKmM,KAAK,eACPlC,aAAA,EAAAA,EAAc1G,WACbyG,aADD,EACCA,EAAczG,UAnGpB,2BACE3H,UAAU,kCACVN,MAAO,CACL8Q,SAAU,WACVhT,MAAM,GAAD,QAAK4Q,aAAA,EAAAA,EAAc5Q,QAAS,IAA5B,KACLiT,KAAK,GAAD,OAA4C,MAAtCrC,SAAA,UAAAA,EAAcsC,kBAAd,eAA0BjS,IAAK,IAArC,KACJkS,IAAI,GAAD,OAA4C,MAAtCvC,SAAA,UAAAA,EAAcsC,kBAAd,eAA0BhS,IAAK,IAArC,OAGL,2BACE8O,IAAKY,aAAF,EAAEA,EAAcZ,IACnB9N,MAAO,CACLlB,UAAW,wCAyFZuP,M,6kBCpJX,IAAQ3O,GAAOnE,GAAGoE,KAAVD,GAER,GAOInE,GAAGqE,WANLC,GADF,GACEA,KACAE,GAFF,GAEEA,UACAD,GAHF,GAGEA,SACAiD,GAJF,GAIEA,QACAK,GALF,GAKEA,OACA8N,GANF,GAMEA,YAWF,GAAgC3V,GAAGC,QAA3B8H,GAAR,GAAQA,UAAW9C,GAAnB,GAAmBA,SACXD,GAAahF,GAAbgF,SA2MO4Q,GAzMD,SAAC,GAA6D,IAAD,MAA1DzV,EAA0D,EAA1DA,MAAOiK,EAAmD,EAAnDA,UAAWC,EAAwC,EAAxCA,QAASsE,EAA+B,EAA/BA,aAAcC,EAAiB,EAAjBA,WACxD,EAA8B3J,IAAS,GAAvC,mBAAOI,EAAP,KAAgBC,EAAhB,KACA,EAA0BL,GAAS,IAAnC,mBAAO4F,EAAP,KAAcgL,EAAd,KACA,EAA0B5Q,GAAS,IAAnC,mBAAOa,EAAP,KAAcC,EAAd,KACA,EAAgCd,GAAS,MAAzC,mBAAO6Q,EAAP,KAAiBC,EAAjB,KACA,EAA8B9Q,IAAS,GAAvC,mBAAO+Q,EAAP,KAAgBC,EAAhB,KAMMC,EAAQ,uCAAG,kCAAAjQ,EAAA,6DACfX,GAAW,GADI,kBAGKN,GAAS,CACzBoB,IAAI,GAAD,iBAAK6E,oBAAL,aAAK,EAAcG,MAAnB,iBAA0BH,oBAA1B,aAA0B,EAAcI,oBAAxC,kBAAqElL,SAArE,UAAqEA,EAAOgG,cAA5E,aAAqE,EAAe1D,MAJ5E,OAGToI,EAHS,OAMbgL,EAAShL,GACTkL,EAAYlL,aAAD,EAACA,EAAO1B,OAPN,gDASE,kBAAX,KAAEwI,MACJ5L,EAAS,mBAVE,yBAabT,GAAW,GAbE,4EAAH,qDAiBR6Q,EAAQ,uCAAG,8BAAAlQ,EAAA,6DACfa,QAAQsP,IAAR,2BAAgCN,IAChCxQ,GAAW,GAFI,SAIPrD,EAJO,SAKR4I,GACA,CAAE1B,MAAO2M,IAND,SAQK9V,GAAGgF,SAAS,CAC5BqR,OAAQ,OACRjQ,IAAKpG,GAAGoG,IAAIC,aAAP,UACA4E,aAAaG,MADb,OACoBH,aAAaI,oBADjC,kBAC8DR,EAAMpI,IACvE,CAAE6T,QAAS,QAEbrU,SAdW,UAQTsU,EARS,6BAkBLC,aAlBK,OAoBbP,GAAW,GACXJ,EAASU,GArBI,kDAuBbxQ,EAAS,iCAAGgB,QAAU,KAAEA,QAAUyP,cAvBrB,yBAyBblR,GAAW,GAzBE,6EAAH,qDA6BRmR,EAAgB,WACpBV,EAAYlL,aAAD,EAACA,EAAO1B,OACnB8M,GAAW,IAuDb,OAJAlO,IAAU,WACRmO,MACC,IAECpQ,EAEA,2BAAKf,UAAU,eACb,oBAAC,GAAD,KACE,oBAAC,GAAD,KACE,8BAAKe,MAQb,2BAAKf,UAAU,eACb,oBAAC,GAAD,KACE,oBAAC,GAAD,KACE,oBAAC,GAAD,CAAQ6D,aAAW,EAACE,QA3Hf,WACXjJ,EAAQgC,KAAR,QA0HM,KACUsC,GAAG,oBAAqB,oBAItC,oBAAC,GAAD,CAAMyN,MAAI,GACR,oBAAC,GAAD,KAzEAvM,EACK,oBAAC,GAAD,MACE2Q,EAEP,2BAAKjR,UAAU,kDACb,oBAAC4Q,GAAD,CACE5Q,UAAU,4BACVwH,KAAK,OACLlK,MAAOyT,EACPY,SAAU,SAACvN,GAAD,OAAW4M,EAAY5M,MAEnC,oBAAC,GAAD,CACEpE,UAAU,6BACV4R,WAAS,EACT7N,QAASqN,GAER,IALH,OAMO,KAEP,oBAAC,GAAD,CACEpR,UAAU,6BACV6D,aAAW,EACXE,QAAS2N,GAER,IALH,SAMS,MAMX,2BAAK1R,UAAU,sBACb,0BAAIA,UAAU,oDACX8F,aADH,EACGA,EAAO1B,OAGV,8BACEpE,UAAU,2BACV+D,QAAS,kBAAMmN,GAAW,KAE1B,4BAAMlR,UAAU,yCAkCpB,oBAAC,GAAD,KACE,oBAAC4L,GAAD,CACEvG,UAAWA,EACXuE,aAAcA,EACdtE,QAASA,EACTuE,WAAYA,MAKlB,2BAAK7J,UAAU,gCACb,2BAAKA,UAAU,yBACb,2BAAKA,UAAU,mCACb,oBAAC6R,GAAD,CACE1E,SAAU/R,SAAF,UAAEA,EAAOgG,cAAT,aAAE,EAAe1D,GACzB2H,UAAWA,EACXC,QAASA,KAGb,2BAAKtF,UAAU,4BACV7D,OAAOC,KAAK0J,GAAS,IAAIzB,QAC1B,oBAACyN,GAAD,CACEtE,IAAK1H,aAAF,EAAEA,EAAO0H,IACZM,WAAY,CACV1J,MAAO0B,EAAM1B,OAEfoD,KAAM+F,GAAYzH,EAAM0H,KACxBI,OAAQ,CACN,cAAc,EACdmE,MAAM,EACNC,UAAU,EACVC,QAAQ,EACR,gBAAgB,EAChB,gBAAgB,EAChBvD,iBAAkB,UAClBwD,QAAQ,EACRC,MAAM,EACN9S,KAAMjF,OAAO8L,aAAa7G,SAKlC,2BAAKW,UAAU,0BACb,oBAACoS,GAAD,CACEjF,SAAU/R,SAAF,UAAEA,EAAOgG,cAAT,aAAE,EAAe1D,GACzB2H,UAAWA,EACXC,QAASA,MAIf,2BAAKtF,UAAU,yBACb,2BAAKA,UAAU,mCACb,oBAACqS,GAAD,CACElF,SAAU/R,SAAF,UAAEA,EAAOgG,cAAT,aAAE,EAAe1D,GACzB2H,UAAWA,EACXC,QAASA,SCtNVpJ,GAAS,CACpBoW,UAAW,CACT/X,KAAM,KAERuL,MAAO,CACLvL,KAAM,cAERgL,KAAM,CACJhL,KAAM,cCRF2F,GAAajF,GAAGC,QAAhBgF,SAWO,cAAO,IAAD,EACbqS,EAAc,WAClBnY,OAAOoY,SAAS,EAAG,IAGrB,EAAkCtS,GAChC,IAAIkC,KAAKA,KAAKqQ,MAAQ,SADxB,mBAAOpN,EAAP,KAAkBuE,EAAlB,KAGA,EAA8B1J,GAAS,IAAIkC,MAA3C,mBAAOkD,EAAP,KAAgBuE,EAAhB,KAEA,OAAI,UAAC3D,oBAAD,OAAC,EAAcwM,UASjB,2BAAK1S,UAAU,6BACb,oBAAC,EAAD,CAAQ9D,OAAQA,IACd,oBAACX,EAAD,CAAOhB,KAAM2B,GAAOoW,UAAU/X,KAAMiB,QAAS+W,GAC3C,oBAACI,GAAD,CACEtN,UAAWA,EACXC,QAASA,EACTsE,aAAcA,EACdC,WAAYA,KAGhB,oBAACtO,EAAD,CAAOhB,KAAM2B,GAAO4J,MAAMvL,KAAMiB,QAAS+W,GACvC,oBAAC,GAAD,CACElN,UAAWA,EACXC,QAASA,EACTsE,aAAcA,EACdC,WAAYA,KAGhB,oBAACtO,EAAD,CAAOhB,KAAM2B,GAAOqJ,KAAKhL,KAAMiB,QAAS+W,GACtC,oBAAC,GAAD,CACElN,UAAWA,EACXC,QAASA,EACTsE,aAAcA,EACdC,WAAYA,OA9BlB,2BAAK7J,UAAU,6BACb,oBAAC4S,EAAD,SCTR7N,EAfmB9J,GAAGC,QAAd6J,QAeD,oBAAC8N,GAAD,MAASC,SAASC,eAAe,4B","file":"analytics/admin-9ff30d14.js","sourcesContent":["(function() { module.exports = window[\"wp\"][\"element\"]; }());","(function() { module.exports = window[\"wp\"][\"apiFetch\"]; }());","(function() { module.exports = window[\"wp\"][\"components\"]; }());","import qs from \"querystringify\";\nexport function locationToRoute(location) {\n // location comes from the history package\n return {\n path: location.pathname,\n hash: location.hash,\n query: qs.parse(location.search),\n };\n}\n","import { createBrowserHistory } from \"history\";\nimport { locationToRoute } from \"./utils\";\n\nexport const history = createBrowserHistory();\nexport const RouterContext = wp.element.createContext({\n route: locationToRoute(history.location),\n});\n","import { RouterContext } from \"./context\";\nconst { useContext } = wp.element;\nimport { match } from \"path-to-regexp\";\nlet prev = \"\";\n\nexport function Route({ path, onRoute, children }) {\n // Extract route from RouterContext\n const { route } = useContext(RouterContext);\n\n const checkMatch = match(`${path}`);\n const matched = checkMatch(`${route.hash.substr(1)}`);\n\n if (!matched) {\n return null;\n }\n\n if (onRoute) {\n if (prev !== matched.path) {\n onRoute();\n }\n prev = matched.path;\n }\n\n return <div>{wp.element.cloneElement(children, { route: matched })}</div>;\n}\n","const { useContext } = wp.element;\nimport { RouterContext, history } from \"./context\";\nimport classNames from \"classnames\";\nimport { match } from \"path-to-regexp\";\n\nexport function Link(props) {\n const { to, onClick, children, activeClassName } = props;\n const { route } = useContext(RouterContext);\n\n let state = { ...props };\n delete state.activeClassName;\n\n const isActive = () => {\n const checkMatch = match(`${to}`);\n return checkMatch(`${route.hash.substr(1)}`);\n };\n\n const handleClick = (e) => {\n e.preventDefault();\n // Dont' navigate if current path\n if (route.path === to) {\n return;\n }\n // Trigger onClick prop manually\n if (onClick) {\n onClick(e);\n }\n const { search } = history.location;\n\n // Use history API to navigate page\n history.push(`${search}#${to}`);\n };\n\n return (\n <a\n {...state}\n className={classNames({ [activeClassName]: isActive() }, props.className)}\n onClick={handleClick}\n >\n {children}\n </a>\n );\n}\n","import { Component } from \"@wordpress/element\";\nimport { locationToRoute } from \"./utils\";\nimport { history, RouterContext } from \"./context\";\nimport { Route } from \"./route\";\nimport { Link } from \"./link\";\nimport { match } from \"path-to-regexp\";\n\nclass Router extends Component {\n constructor(props) {\n super(props);\n\n // Convert our routes into an array for easy 404 checking\n this.routes = Object.keys(props.routes).map(\n (key) => props.routes[key].path\n );\n\n // Listen for path changes from the history API\n this.unlisten = history.listen(this.handleRouteChange);\n\n const route = locationToRoute(history.location);\n const { search } = history.location;\n\n // Define the initial RouterContext value\n this.state = {\n route,\n defaultRoute: props?.defaultRoute\n ? `${search}#${props?.defaultRoute}`\n : `${search}#/`,\n };\n }\n\n componentWillUnmount() {\n // Stop listening for changes if the Router component unmounts\n this.unlisten();\n }\n\n handleRouteChange = (location) => {\n const route = locationToRoute(location?.location);\n this.setState({ route: route });\n };\n\n render() {\n // Define our variables\n const { children, NotFound } = this.props;\n const { route, defaultRoute } = this.state;\n\n if (!route.hash) {\n history.push(defaultRoute);\n return <div></div>;\n }\n\n let matched = false;\n // match route\n (this.routes || []).forEach((name) => {\n const checkMatch = match(route.hash.substr(1));\n const isMatched = checkMatch(`${route.hash.substr(1)}`);\n if (!isMatched) {\n return;\n }\n matched = {\n name,\n data: isMatched,\n };\n });\n\n const routerContextValue = { route, matched };\n\n // Check if 404 if no route matched\n const is404 = !matched;\n\n return (\n <RouterContext.Provider value={routerContextValue}>\n {is404 ? <div>Not found</div> : children}\n </RouterContext.Provider>\n );\n }\n}\nexport { history, RouterContext, Router, Route, Link };\n","export default ({ width, height }) => {\n return (\n <svg\n id=\"e8f68bdd-4984-4f2e-95b7-7fc8ec281257\"\n data-name=\"Layer 1\"\n width={width}\n height={height}\n xmlns=\"http://www.w3.org/2000/svg\"\n xmlnsXlink=\"http://www.w3.org/1999/xlink\"\n viewBox=\"0 0 918.14 765.54\"\n >\n <defs>\n <linearGradient\n id=\"27aa7b70-b106-4a00-be67-693c8380e41d\"\n x1=\"397.74\"\n y1=\"717.25\"\n x2=\"397.74\"\n y2=\"86.11\"\n gradientUnits=\"userSpaceOnUse\"\n >\n <stop offset=\"0\" stop-color=\"gray\" stop-opacity=\"0.25\" />\n <stop offset=\"0.54\" stop-color=\"gray\" stop-opacity=\"0.12\" />\n <stop offset=\"1\" stop-color=\"gray\" stop-opacity=\"0.1\" />\n </linearGradient>\n <linearGradient\n id=\"46a816da-c484-41ec-8a6f-fbf14454d910\"\n x1=\"288.88\"\n y1=\"378.44\"\n x2=\"288.88\"\n y2=\"209.65\"\n xlinkHref=\"#27aa7b70-b106-4a00-be67-693c8380e41d\"\n />\n <linearGradient\n id=\"32b634d8-28f1-48d9-a868-f602a2cad942\"\n x1=\"288.88\"\n y1=\"328.29\"\n x2=\"288.88\"\n y2=\"223.1\"\n xlinkHref=\"#27aa7b70-b106-4a00-be67-693c8380e41d\"\n />\n <clipPath\n id=\"7a4c6aff-0be0-461b-a111-b3ae1b8fbf73\"\n transform=\"translate(-140.93 -67.23)\"\n >\n <rect\n id=\"8cc91f6d-19b0-43cc-9c18-2faa83ac34ba\"\n data-name=\"&lt;Rectangle&gt;\"\n x=\"354.51\"\n y=\"291.55\"\n width=\"150.6\"\n height=\"101.52\"\n fill=\"#fff\"\n />\n </clipPath>\n <linearGradient\n id=\"38f1cb81-8fac-4205-a0ff-a33ac00d354c\"\n x1=\"288.88\"\n y1=\"594.94\"\n x2=\"288.88\"\n y2=\"426.14\"\n xlinkHref=\"#27aa7b70-b106-4a00-be67-693c8380e41d\"\n />\n <linearGradient\n id=\"6fc01aaf-135e-403e-a209-43b2a4fe59f1\"\n x1=\"288.88\"\n y1=\"544.79\"\n x2=\"288.88\"\n y2=\"439.6\"\n xlinkHref=\"#27aa7b70-b106-4a00-be67-693c8380e41d\"\n />\n <clipPath\n id=\"79ce363a-d134-40e4-9f82-b96d04a36978\"\n transform=\"translate(-140.93 -67.23)\"\n >\n <rect\n id=\"5b44e697-61fe-43bd-9a58-5f3e41301748\"\n data-name=\"&lt;Rectangle&gt;\"\n x=\"354.51\"\n y=\"508.05\"\n width=\"150.6\"\n height=\"101.52\"\n fill=\"#fff\"\n />\n </clipPath>\n <linearGradient\n id=\"54803c44-522d-4b9e-9a34-f1f7b43e8483\"\n x1=\"671.57\"\n y1=\"760.34\"\n x2=\"671.57\"\n y2=\"129.2\"\n gradientTransform=\"translate(1109.43 -194.1) rotate(90)\"\n xlinkHref=\"#27aa7b70-b106-4a00-be67-693c8380e41d\"\n />\n <linearGradient\n id=\"089a6a47-adaa-499b-aefb-cd6464b62fb8\"\n x1=\"670.96\"\n y1=\"553.63\"\n x2=\"670.96\"\n y2=\"387.28\"\n gradientTransform=\"translate(1129.51 -168.41) rotate(90)\"\n xlinkHref=\"#27aa7b70-b106-4a00-be67-693c8380e41d\"\n />\n <linearGradient\n id=\"fd8d88e0-7826-450d-9e0b-001d1be709c2\"\n x1=\"637.66\"\n y1=\"754.12\"\n x2=\"637.66\"\n y2=\"601.05\"\n xlinkHref=\"#27aa7b70-b106-4a00-be67-693c8380e41d\"\n />\n <linearGradient\n id=\"8d1793c5-b76e-44e2-a52e-569460402331\"\n x1=\"778.37\"\n y1=\"673.86\"\n x2=\"778.37\"\n y2=\"569.13\"\n xlinkHref=\"#27aa7b70-b106-4a00-be67-693c8380e41d\"\n />\n <linearGradient\n id=\"4745700d-8097-45ff-9f71-625443fc4ad8\"\n x1=\"778.37\"\n y1=\"774.41\"\n x2=\"778.37\"\n y2=\"713.66\"\n xlinkHref=\"#27aa7b70-b106-4a00-be67-693c8380e41d\"\n />\n </defs>\n <title>secure data</title>\n <g opacity=\"0.5\">\n <rect\n x=\"162.9\"\n y=\"86.11\"\n width=\"469.69\"\n height=\"631.14\"\n fill=\"url(#27aa7b70-b106-4a00-be67-693c8380e41d)\"\n />\n </g>\n <rect\n x=\"169.02\"\n y=\"94.67\"\n width=\"455.01\"\n height=\"609.12\"\n fill=\"#f2f2f2\"\n />\n <rect x=\"204.49\" y=\"120.36\" width=\"156.56\" height=\"4.89\" fill=\"#e0e0e0\" />\n <rect\n x=\"204.49\"\n y=\"142.37\"\n width=\"156.56\"\n height=\"4.89\"\n fill=\"#6c63ff\"\n opacity=\"0.7\"\n />\n <rect x=\"384.29\" y=\"120.36\" width=\"156.56\" height=\"4.89\" fill=\"#e0e0e0\" />\n <rect x=\"408.75\" y=\"259.8\" width=\"156.56\" height=\"4.89\" fill=\"#e0e0e0\" />\n <rect x=\"412.42\" y=\"273.25\" width=\"156.56\" height=\"4.89\" fill=\"#e0e0e0\" />\n <rect x=\"419.76\" y=\"286.7\" width=\"156.56\" height=\"4.89\" fill=\"#e0e0e0\" />\n <rect x=\"408.75\" y=\"476.29\" width=\"156.56\" height=\"4.89\" fill=\"#e0e0e0\" />\n <rect x=\"412.42\" y=\"489.75\" width=\"156.56\" height=\"4.89\" fill=\"#e0e0e0\" />\n <rect x=\"419.76\" y=\"503.2\" width=\"156.56\" height=\"4.89\" fill=\"#e0e0e0\" />\n <g opacity=\"0.5\">\n <rect\n x=\"205.71\"\n y=\"209.65\"\n width=\"166.35\"\n height=\"168.79\"\n fill=\"url(#46a816da-c484-41ec-8a6f-fbf14454d910)\"\n />\n </g>\n <rect\n x=\"206.76\"\n y=\"213.32\"\n width=\"163.72\"\n height=\"161.45\"\n fill=\"#f5f5f5\"\n />\n <g opacity=\"0.5\">\n <rect\n x=\"212.53\"\n y=\"223.1\"\n width=\"152.7\"\n height=\"105.19\"\n fill=\"url(#32b634d8-28f1-48d9-a868-f602a2cad942)\"\n />\n </g>\n <rect\n id=\"689f37f3-cc41-448d-b172-63ec123bc985\"\n data-name=\"&lt;Rectangle&gt;\"\n x=\"213.58\"\n y=\"224.32\"\n width=\"150.6\"\n height=\"101.52\"\n fill=\"#fff\"\n />\n <g clip-path=\"url(#7a4c6aff-0be0-461b-a111-b3ae1b8fbf73)\">\n <polygon\n points=\"200.82 322.18 238.74 263.46 254.64 289.15 288.88 253.68 318.24 289.15 343.93 236.56 409.98 341.75 195.93 334.41 200.82 322.18\"\n fill=\"#6c63ff\"\n opacity=\"0.4\"\n />\n <circle cx=\"230.17\" cy=\"239\" r=\"11.01\" fill=\"#6c63ff\" opacity=\"0.4\" />\n </g>\n <g opacity=\"0.5\">\n <rect\n x=\"205.71\"\n y=\"426.14\"\n width=\"166.35\"\n height=\"168.79\"\n fill=\"url(#38f1cb81-8fac-4205-a0ff-a33ac00d354c)\"\n />\n </g>\n <rect\n x=\"206.76\"\n y=\"429.81\"\n width=\"163.72\"\n height=\"161.45\"\n fill=\"#f5f5f5\"\n />\n <g opacity=\"0.5\">\n <rect\n x=\"212.53\"\n y=\"439.6\"\n width=\"152.7\"\n height=\"105.19\"\n fill=\"url(#6fc01aaf-135e-403e-a209-43b2a4fe59f1)\"\n />\n </g>\n <rect\n id=\"b429ac3a-f8a8-4171-bcce-5b6c002c0714\"\n data-name=\"&lt;Rectangle&gt;\"\n x=\"213.58\"\n y=\"440.82\"\n width=\"150.6\"\n height=\"101.52\"\n fill=\"#fff\"\n />\n <g clip-path=\"url(#79ce363a-d134-40e4-9f82-b96d04a36978)\">\n <polygon\n points=\"200.82 538.67 238.74 479.96 254.64 505.65 288.88 470.18 318.24 505.65 343.93 453.05 409.98 558.24 195.93 550.9 200.82 538.67\"\n fill=\"#bdbdbd\"\n opacity=\"0.4\"\n />\n <circle cx=\"230.17\" cy=\"455.5\" r=\"11.01\" fill=\"#bdbdbd\" opacity=\"0.4\" />\n </g>\n <g opacity=\"0.5\">\n <rect\n x=\"349.09\"\n y=\"242.63\"\n width=\"631.14\"\n height=\"469.69\"\n transform=\"translate(-74.16 969.06) rotate(-78.76)\"\n fill=\"url(#54803c44-522d-4b9e-9a34-f1f7b43e8483)\"\n />\n </g>\n <rect\n x=\"359.37\"\n y=\"247.33\"\n width=\"609.12\"\n height=\"455.01\"\n transform=\"translate(-72.16 966.22) rotate(-78.76)\"\n fill=\"#fff\"\n />\n <rect\n x=\"523.5\"\n y=\"197.22\"\n width=\"322.91\"\n height=\"4.89\"\n transform=\"translate(-88.86 -196.94) rotate(11.24)\"\n fill=\"#e0e0e0\"\n />\n <rect\n x=\"433.36\"\n y=\"650.7\"\n width=\"322.91\"\n height=\"4.89\"\n transform=\"translate(-2.18 -170.66) rotate(11.24)\"\n fill=\"#e0e0e0\"\n />\n <rect\n x=\"428.58\"\n y=\"671.14\"\n width=\"249.52\"\n height=\"4.89\"\n transform=\"translate(1.01 -162.18) rotate(11.24)\"\n fill=\"#e0e0e0\"\n />\n <rect\n x=\"424.6\"\n y=\"683.47\"\n width=\"92.96\"\n height=\"4.89\"\n transform=\"translate(1.84 -145.91) rotate(11.24)\"\n fill=\"#6c63ff\"\n opacity=\"0.7\"\n />\n <rect\n x=\"519.57\"\n y=\"209.08\"\n width=\"161.45\"\n height=\"4.89\"\n transform=\"translate(-88.17 -180.2) rotate(11.24)\"\n fill=\"#6c63ff\"\n opacity=\"0.7\"\n />\n <rect\n x=\"512.84\"\n y=\"249.31\"\n width=\"291.11\"\n height=\"4.89\"\n transform=\"translate(-79.21 -190.76) rotate(11.24)\"\n fill=\"#e0e0e0\"\n />\n <rect\n x=\"509.47\"\n y=\"255.44\"\n width=\"70.94\"\n height=\"4.89\"\n transform=\"translate(-80.19 -168.52) rotate(11.24)\"\n fill=\"#3ad29f\"\n opacity=\"0.7\"\n />\n <rect\n x=\"501.56\"\n y=\"307.59\"\n width=\"322.91\"\n height=\"4.89\"\n transform=\"translate(-67.76 -190.54) rotate(11.24)\"\n fill=\"#e0e0e0\"\n />\n <g opacity=\"0.5\">\n <rect\n x=\"575.87\"\n y=\"357.6\"\n width=\"166.35\"\n height=\"289.88\"\n transform=\"translate(-103.27 983.74) rotate(-78.76)\"\n fill=\"url(#089a6a47-adaa-499b-aefb-cd6464b62fb8)\"\n />\n </g>\n <rect\n x=\"516.06\"\n y=\"420.61\"\n width=\"286.22\"\n height=\"162.68\"\n transform=\"translate(-30.42 -186.11) rotate(11.24)\"\n fill=\"#fff\"\n />\n <rect\n x=\"496.08\"\n y=\"335.18\"\n width=\"322.91\"\n height=\"4.89\"\n transform=\"translate(-62.49 -188.94) rotate(11.24)\"\n fill=\"#e0e0e0\"\n />\n <rect\n x=\"547.86\"\n y=\"424.02\"\n width=\"35.47\"\n height=\"118.64\"\n transform=\"translate(-35.84 -168.22) rotate(11.24)\"\n fill=\"#6c63ff\"\n />\n <rect\n x=\"606.43\"\n y=\"475.19\"\n width=\"35.47\"\n height=\"79.5\"\n transform=\"translate(-28.56 -179.03) rotate(11.24)\"\n fill=\"#3ad29f\"\n />\n <rect\n x=\"665.23\"\n y=\"523.93\"\n width=\"35.47\"\n height=\"42.81\"\n transform=\"translate(-21.5 -189.92) rotate(11.24)\"\n fill=\"#f55f44\"\n />\n <rect\n x=\"731.91\"\n y=\"492.72\"\n width=\"35.47\"\n height=\"86.84\"\n transform=\"translate(-22.02 -203.09) rotate(11.24)\"\n fill=\"#fdd835\"\n />\n <g opacity=\"0.5\">\n <rect\n x=\"128.65\"\n y=\"645.09\"\n width=\"3.67\"\n height=\"20.79\"\n fill=\"#47e6b1\"\n />\n <rect\n x=\"269.58\"\n y=\"712.31\"\n width=\"3.67\"\n height=\"20.79\"\n transform=\"translate(853.2 384.07) rotate(90)\"\n fill=\"#47e6b1\"\n />\n </g>\n <path\n d=\"M699.44,75.56a4.49,4.49,0,0,1-2.5-5.43,2.16,2.16,0,0,0,.1-.5h0a2.25,2.25,0,0,0-4-1.49h0a2.16,2.16,0,0,0-.25.44,4.49,4.49,0,0,1-5.43,2.5,2.16,2.16,0,0,0-.5-.1h0a2.25,2.25,0,0,0-1.49,4h0a2.16,2.16,0,0,0,.44.25,4.49,4.49,0,0,1,2.5,5.43,2.16,2.16,0,0,0-.1.5h0a2.25,2.25,0,0,0,4,1.49h0a2.16,2.16,0,0,0,.25-.44,4.49,4.49,0,0,1,5.43-2.5,2.16,2.16,0,0,0,.5.1h0a2.25,2.25,0,0,0,1.49-4h0A2.16,2.16,0,0,0,699.44,75.56Z\"\n transform=\"translate(-140.93 -67.23)\"\n fill=\"#4d8af0\"\n opacity=\"0.5\"\n />\n <path\n d=\"M286.33,179.4a4.49,4.49,0,0,1-2.5-5.43,2.16,2.16,0,0,0,.1-.5h0a2.25,2.25,0,0,0-4-1.49h0a2.16,2.16,0,0,0-.25.44,4.49,4.49,0,0,1-5.43,2.5,2.16,2.16,0,0,0-.5-.1h0a2.25,2.25,0,0,0-1.49,4h0a2.16,2.16,0,0,0,.44.25,4.49,4.49,0,0,1,2.5,5.43,2.16,2.16,0,0,0-.1.5h0a2.25,2.25,0,0,0,4,1.49h0a2.16,2.16,0,0,0,.25-.44,4.49,4.49,0,0,1,5.43-2.5,2.16,2.16,0,0,0,.5.1h0a2.25,2.25,0,0,0,1.49-4h0A2.16,2.16,0,0,0,286.33,179.4Z\"\n transform=\"translate(-140.93 -67.23)\"\n fill=\"#fdd835\"\n opacity=\"0.5\"\n />\n <path\n d=\"M253.63,484.46a4.49,4.49,0,0,1-2.5-5.43,2.16,2.16,0,0,0,.1-.5h0a2.25,2.25,0,0,0-4-1.49h0a2.16,2.16,0,0,0-.25.44,4.49,4.49,0,0,1-5.43,2.5,2.16,2.16,0,0,0-.5-.1h0a2.25,2.25,0,0,0-1.49,4h0a2.16,2.16,0,0,0,.44.25,4.49,4.49,0,0,1,2.5,5.43,2.16,2.16,0,0,0-.1.5h0a2.25,2.25,0,0,0,4,1.49h0a2.16,2.16,0,0,0,.25-.44,4.49,4.49,0,0,1,5.43-2.5,2.16,2.16,0,0,0,.5.1h0a2.25,2.25,0,0,0,1.49-4h0A2.16,2.16,0,0,0,253.63,484.46Z\"\n transform=\"translate(-140.93 -67.23)\"\n fill=\"#fdd835\"\n opacity=\"0.5\"\n />\n <circle cx=\"337.81\" cy=\"28.62\" r=\"7.34\" fill=\"#f55f44\" opacity=\"0.5\" />\n <circle cx=\"7.34\" cy=\"317.46\" r=\"7.34\" fill=\"#f55f44\" opacity=\"0.5\" />\n <circle cx=\"863.76\" cy=\"120.36\" r=\"7.34\" fill=\"#f55f44\" opacity=\"0.5\" />\n <circle cx=\"822.17\" cy=\"339.3\" r=\"7.34\" fill=\"#4d8af0\" opacity=\"0.5\" />\n <circle cx=\"37.68\" cy=\"145.22\" r=\"7.34\" fill=\"#47e6b1\" opacity=\"0.5\" />\n <circle cx=\"853.29\" cy=\"647.34\" r=\"7.34\" fill=\"#47e6b1\" opacity=\"0.5\" />\n <circle cx=\"910.8\" cy=\"430.97\" r=\"7.34\" fill=\"#47e6b1\" opacity=\"0.5\" />\n <rect\n x=\"544.42\"\n y=\"601.05\"\n width=\"186.48\"\n height=\"153.07\"\n fill=\"url(#fd8d88e0-7826-450d-9e0b-001d1be709c2)\"\n />\n <path\n d=\"M723.82,639a54.55,54.55,0,0,1,109.1,0v34.91h15.27V639a69.82,69.82,0,0,0-139.65,0v34.91h15.27Z\"\n transform=\"translate(-140.93 -67.23)\"\n fill=\"url(#8d1793c5-b76e-44e2-a52e-569460402331)\"\n />\n <path\n d=\"M726,638.25a52.37,52.37,0,1,1,104.74,0v33.52H845.4V638.25a67,67,0,0,0-134.06,0v33.52H726Z\"\n transform=\"translate(-140.93 -67.23)\"\n fill=\"#f5f5f5\"\n />\n <rect\n x=\"546.32\"\n y=\"602.45\"\n width=\"182.24\"\n height=\"148.73\"\n fill=\"#6c63ff\"\n />\n <rect\n x=\"546.32\"\n y=\"602.45\"\n width=\"182.24\"\n height=\"148.73\"\n fill=\"#f5f5f5\"\n />\n <rect\n x=\"546.32\"\n y=\"631.77\"\n width=\"182.24\"\n height=\"90.07\"\n fill=\"#6c63ff\"\n />\n <path\n d=\"M791.73,727a13.36,13.36,0,1,0-23.08,9.15v28.51a9.72,9.72,0,0,0,19.44,0V736.18A13.3,13.3,0,0,0,791.73,727Z\"\n transform=\"translate(-140.93 -67.23)\"\n fill=\"url(#4745700d-8097-45ff-9f71-625443fc4ad8)\"\n />\n <path\n d=\"M789.89,729.38a11.52,11.52,0,1,0-19.9,7.89v24.58a8.38,8.38,0,1,0,16.76,0V737.27A11.47,11.47,0,0,0,789.89,729.38Z\"\n transform=\"translate(-140.93 -67.23)\"\n opacity=\"0.2\"\n />\n </svg>\n );\n};\n","const { __ } = wp.i18n;\n\nimport Illustration from \"./illustration\";\nconst { Flex, FlexItem, FlexBlock } = wp.components;\n\nexport default () => {\n return (\n <Flex style={{ padding: \"30px\", background: \"#fff\" }}>\n <FlexItem>\n <Illustration width=\"250px\" />\n </FlexItem>\n <FlexBlock style={{ marginLeft: \"20px\" }}>\n <h1>{__(\"Get detailed video insights.\", \"presto-player\")}</h1>\n <p>\n {__(\n \"Upgrade to Pro and get video insights like plays, watch-time, and drop off numbers.\",\n \"presto-player\"\n )}\n </p>\n <a\n href=\"https://prestoplayer.com\"\n target=\"_blank\"\n className=\"button button-primary\"\n >\n {__(\"Learn More\", \"presto-player\")}\n </a>\n </FlexBlock>\n </Flex>\n );\n};\n","/**\n * WordPress dependencies\n */\nconst { __ } = wp.i18n;\nconst { apiFetch } = wp;\nconst { useState } = wp.element;\nconst { createHigherOrderComponent } = wp.compose;\n\n/**\n * Higher order component factory\n *\n * @return {Function} The higher order component.\n */\nexport default () =>\n createHigherOrderComponent(\n (WrappedComponent) => (props) => {\n const [loading, setLoading] = useState(false);\n const [page, setPage] = useState(1);\n const [total, setTotal] = useState(0);\n const [totalPages, setTotalPages] = useState(0);\n const [data, setData] = useState([]);\n const [error, setError] = useState(\"\");\n\n // fetch data\n // we could also abstract this function to make it reusable\n // or do a higher order component\n const fetchData = async ({ endpoint, params = {} }) => {\n setLoading(true);\n\n let responseData;\n try {\n responseData = await apiFetch({\n path: wp.url.addQueryArgs(endpoint, {\n page,\n per_page: 5,\n ...params,\n }),\n parse: false,\n }).then((res) => {\n const total = res.headers\n ? parseInt(res.headers.get(\"X-WP-Total\"))\n : 0;\n const totalPages = res.headers\n ? parseInt(res.headers.get(\"X-WP-TotalPages\"))\n : 0;\n setTotal(total);\n setTotalPages(totalPages);\n return res.json();\n });\n\n setData(responseData);\n } catch (e) {\n console.error(e);\n if (e?.message) {\n setError(e.message);\n }\n } finally {\n setLoading(false);\n }\n };\n\n return (\n <WrappedComponent\n loading={loading}\n setLoading={setLoading}\n fetchData={fetchData}\n page={page}\n setPage={setPage}\n total={total}\n setTotal={setTotal}\n totalPages={totalPages}\n setTotalPages={setTotalPages}\n data={data}\n setData={setData}\n error={error}\n setError={setError}\n {...props}\n />\n );\n },\n \"withDataList\"\n );\n","const { __, sprintf } = wp.i18n;\n\nexport const humanSeconds = (savedSeconds) => {\n const hours = Math.floor(savedSeconds / 60 / 60);\n const minutes = Math.floor(savedSeconds / 60) - hours * 60;\n const seconds = savedSeconds % 60;\n\n let out = \"\";\n if (hours) {\n out += sprintf(__(\"%d hours\", \"presto-player\"), hours) + \", \";\n }\n if (minutes) {\n out += sprintf(__(\"%d minutes\", \"presto-player\"), minutes) + \" \";\n }\n if ((hours || minutes) && seconds) {\n out += __(\"and\", \"presto-player\") + \" \";\n }\n\n out += sprintf(__(\"%d seconds\", \"presto-player\"), seconds);\n\n return out;\n};\n\nexport const timestamp = (seconds) => {\n seconds = parseInt(seconds || 0) * 1000;\n return new Date(seconds).toISOString().substr(11, 8);\n};\n\n/*\n * This function remove the user timezone from new Date()\n * https://stackoverflow.com/a/29774197/1972413\n */\nexport const convertDateTimeToAbsoluteDate = (dateTime) => {\n const offset = new Date().getTimezoneOffset();\n var date = new Date(dateTime.getTime() - offset * 60 * 1000);\n return date.toISOString().split(\"T\")[0] + \"T00:00:00.000Z\";\n};\n","const { Spinner, Flex, FlexItem } = wp.components;\nexport default ({ height = 100 }) => {\n return (\n <Flex style={{ height: `${height}px` }} align=\"center\" justify=\"center\">\n <FlexItem>\n <Spinner />\n </FlexItem>\n </Flex>\n );\n};\n","const { __ } = wp.i18n;\nconst { Card, CardBody, Flex, FlexBlock, Button, ButtonGroup } = wp.components;\nconst { useState, useEffect } = wp.element;\n\nexport default ({ page, setPage, perPage, total, totalPages }) => {\n // do we have prev/next\n const [hasPrevious, setHasPrevious] = useState(false);\n const [hasNext, setHasNext] = useState(false);\n\n // end and start cursors\n const [end, setEnd] = useState(0);\n const [start, setStart] = useState(0);\n\n // set end and start\n useEffect(() => {\n setEnd(Math.min(perPage * page, total));\n setStart(perPage * (page - 1) + 1);\n }, [perPage, page, total]);\n\n // update page when pagination is clicked\n const nextPage = () => {\n setPage(Math.min(totalPages, page + 1));\n };\n const prevPage = () => {\n setPage(Math.max(page - 1, 0));\n };\n\n // set prev/next\n useEffect(() => {\n setHasPrevious(page - 1 > 0);\n setHasNext(totalPages >= page + 1);\n }, [page, totalPages]);\n\n return (\n <Card size=\"large\" className=\"presto-card pagination\">\n <CardBody className=\"presto-flow\">\n <Flex>\n <FlexBlock>\n {sprintf(\n __(\"Showing %1s to %2s of %3s\", \"presto-player\"),\n start,\n end,\n total\n )}\n </FlexBlock>\n <FlexBlock>\n <Flex justify=\"flex-end\">\n {\n <ButtonGroup>\n <Button\n isSecondary\n disabled={!hasPrevious}\n onClick={prevPage}\n >\n {__(\"Previous\", \"presto-player\")}\n </Button>\n <Button isSecondary disabled={!hasNext} onClick={nextPage}>\n {__(\"Next\", \"presto-player\")}\n </Button>\n </ButtonGroup>\n }\n </Flex>\n </FlexBlock>\n </Flex>\n </CardBody>\n </Card>\n );\n};\n","const { __ } = wp.i18n;\nconst { useRef, useEffect, useState } = wp.element;\nconst { Card, CardBody, Flex, FlexBlock, Button, ButtonGroup } = wp.components;\n\nimport classNames from \"classnames\";\n\nexport default ({ columns, data, onRowClick, title }) => {\n if (!data.length) {\n return (\n <Card size=\"large\" className=\"presto-card table-card\">\n <CardBody className=\"presto-flow\">\n <div className=\"presto-card__title\">{title}</div>\n <div style={{ opacity: 0.65 }}>\n {__(\"No data available.\", \"presto-player\")}\n </div>\n </CardBody>\n </Card>\n );\n }\n\n return (\n <Card size=\"large\" className=\"presto-card table-card\">\n <CardBody className=\"presto-flow\">\n <div className=\"presto-card__title\">{title}</div>\n <table\n role=\"table\"\n className={classNames(\"presto-table\", { \"is-clickable\": onRowClick })}\n >\n <thead role=\"rowgroup\">\n <tr role=\"row\">\n {columns &&\n columns.map((column) => {\n return (\n <th key={column.key} role=\"columnheader\">\n {column.label}\n </th>\n );\n })}\n </tr>\n </thead>\n\n <tbody role=\"rowgroup\">\n {data.map((row, rowIndex) => {\n return (\n <tr\n role=\"row\"\n key={`row-${rowIndex}`}\n onClick={() => onRowClick && onRowClick(row)}\n >\n {columns.map((column, columnIndex) => {\n return (\n <td\n role=\"cell\"\n data-title={column.label}\n key={`row-${rowIndex}-${columnIndex}`}\n aria-label={column.label}\n >\n {column.render ? (\n column.render(row)\n ) : (\n <div>{column.value(row)}</div>\n )}\n </td>\n );\n })}\n </tr>\n );\n })}\n </tbody>\n </table>\n </CardBody>\n </Card>\n );\n};\n","const { __ } = wp.i18n;\nconst { useEffect, useState } = wp.element;\nconst { Card, CardBody } = wp.components;\nimport Loading from \"@/admin/settings/components/Loading\";\nimport Pagination from \"@/admin/ui/Pagination\";\nimport Table from \"@/admin/ui/Table\";\n\nexport default ({\n perPage = 10,\n title,\n page,\n setPage,\n loading,\n total,\n totalPages,\n columns,\n data,\n onSelect,\n}) => {\n if (loading) {\n return (\n <Card>\n <Loading />\n </Card>\n );\n }\n\n if (!data?.length) {\n return (\n <Card size=\"large\" className=\"presto-card\">\n <CardBody className=\"presto-flow\">\n <div className=\"presto-card__title\">{title}</div>\n <div style={{ opacity: 0.65 }}>\n {__(\"No data available.\", \"presto-player\")}\n </div>\n </CardBody>\n </Card>\n );\n }\n\n return (\n <div className=\"datatable\">\n <Table\n data={data}\n columns={columns}\n perPage={perPage}\n onRowClick={onSelect}\n title={title}\n />\n\n {!!total && (\n <Pagination\n page={page}\n setPage={setPage}\n perPage={perPage}\n total={total}\n totalPages={totalPages}\n />\n )}\n </div>\n );\n};\n","const { __ } = wp.i18n;\nconst { useEffect } = wp.element;\nconst { compose } = wp.compose;\n\nimport { history } from \"@/router/context\";\nimport withDataList from \"../hocs/withDataList\";\nimport { convertDateTimeToAbsoluteDate } from \"../util\";\nimport DataTable from \"./DataTable\";\n\nexport default compose([withDataList()])(\n ({\n loading,\n page,\n setPage,\n total,\n totalPages,\n data,\n error,\n fetchData,\n startDate,\n endDate,\n }) => {\n // 10 per page\n const per_page = 5;\n\n // fetch data when page changes\n useEffect(() => {\n fetchData({\n endpoint: \"/presto-player/v1/analytics/top-users\",\n params: {\n per_page,\n ...(startDate\n ? { start: convertDateTimeToAbsoluteDate(startDate) }\n : {}),\n ...(endDate ? { end: convertDateTimeToAbsoluteDate(endDate) } : {}),\n },\n });\n }, [page, startDate, endDate]);\n\n // navigate to user screen here\n const navigate = (id) => {\n history.push(`#/user/${id}`);\n };\n\n const columns = [\n {\n key: \"name\",\n label: __(\"Name\", \"presto-player\"),\n value: (row) => row?.user?.name,\n },\n {\n key: \"total_view\",\n label: __(\"Total View\", \"presto-player\"),\n value: (row) => row?.stats?.[0]?.data,\n },\n {\n key: \"avg_view_time\",\n label: __(\"Avg View Time\", \"presto-player\"),\n render: (row) => (\n <div className=\"presto-badge\">{row?.stats?.[1]?.data}</div>\n ),\n },\n ];\n\n if (error) {\n return { error };\n }\n\n return (\n <DataTable\n title={__(\"Top Users\", \"presto-player\")}\n page={page}\n perPage={per_page}\n setPage={setPage}\n loading={loading}\n total={total}\n totalPages={totalPages}\n columns={columns}\n data={data}\n onSelect={(row) => navigate(row?.user?.id)}\n />\n );\n }\n);\n","const { __ } = wp.i18n;\nconst { useEffect } = wp.element;\nconst { compose } = wp.compose;\n\nimport { history } from \"@/router/context\";\nimport withDataList from \"../hocs/withDataList\";\nimport { convertDateTimeToAbsoluteDate } from \"../util\";\nimport DataTable from \"./DataTable\";\n\nexport default compose([withDataList()])(\n ({\n loading,\n page,\n setPage,\n total,\n totalPages,\n data,\n error,\n fetchData,\n startDate,\n endDate,\n userId,\n }) => {\n // 10 per page\n const per_page = 10;\n\n // fetch data when page changes\n useEffect(() => {\n fetchData({\n endpoint: \"/presto-player/v1/analytics/top-videos\",\n params: {\n per_page,\n ...(startDate\n ? { start: convertDateTimeToAbsoluteDate(startDate) }\n : {}),\n ...(endDate ? { end: convertDateTimeToAbsoluteDate(endDate) } : {}),\n ...(userId ? { user_id: userId } : {}),\n },\n });\n }, [page, startDate, endDate]);\n\n const navigate = (id) => {\n history.push(`#/video/${id}`);\n };\n\n const columns = [\n {\n key: \"name\",\n label: __(\"Name\", \"presto-player\"),\n render(row) {\n return (\n <h3 style={{ marginBottom: 0, wordBreak: \"break-all\" }}>\n {row.video.title\n ? row.video.title\n : __(\"Untitled\", \"presto-player\")}\n </h3>\n );\n },\n },\n {\n key: \"total_view\",\n label: __(\"Total View\", \"presto-player\"),\n value(row) {\n return row.stats[0].data;\n },\n },\n {\n key: \"avg_view_time\",\n label: __(\"Avg View Time\", \"presto-player\"),\n render(row) {\n return <div className=\"presto-badge\">{row.stats[1].data}</div>;\n },\n },\n {\n key: \"view_more\",\n label: \"\",\n render(row) {\n return (\n <span\n style={{\n color: \"var(--wp-admin-theme-color, #007cba)\",\n }}\n >\n {__(\"View Details\", \"presto-player\")} &rarr;\n </span>\n );\n },\n },\n ];\n\n if (error) {\n return { error };\n }\n\n return (\n <DataTable\n title={__(\"Top Media\", \"presto-player\")}\n perPage={per_page}\n page={page}\n setPage={setPage}\n loading={loading}\n total={total}\n totalPages={totalPages}\n columns={columns}\n data={data}\n onSelect={(row) => {\n navigate(row?.video?.id);\n }}\n />\n );\n }\n);\n","// import apiFetch from \"@wordpress/api-fetch\";\nconst { apiFetch } = wp;\n\n// nonce and root\napiFetch.use(apiFetch.createNonceMiddleware(prestoPlayer.nonce));\napiFetch.use(\n apiFetch.createRootURLMiddleware(\n prestoPlayer.root + prestoPlayer.prestoVersionString\n )\n);\n\nexport default apiFetch;\n","const { __, sprintf } = wp.i18n;\nconst { Card, CardBody } = wp.components;\nconst { useState, useEffect, useRef } = wp.element;\n\nimport Loading from \"@/admin/settings/components/Loading\";\nimport apiFetch from \"@/shared/services/fetch\";\nimport Chart from \"react-apexcharts\";\nimport { convertDateTimeToAbsoluteDate } from \"../util\";\n\nexport default (props) => {\n const [loading, setLoading] = useState(true);\n const [totalViews, setTotalViews] = useState(0);\n const { startDate, endDate } = props;\n const [series, setSeries] = useState([\n {\n name: \"Views\",\n data: [],\n },\n ]);\n\n const chart = {\n options: {\n chart: {\n toolbar: {\n show: false,\n },\n },\n yaxis: {\n min: 0,\n labels: {\n formatter: function (num) {\n if (num < 1) {\n return 0;\n }\n return Math.abs(num) > 999\n ? Math.sign(num) * (Math.abs(num) / 1000).toFixed(1) + \"k\"\n : Math.sign(num) * Math.abs(num).toFixed(0);\n },\n },\n },\n colors: [\"#7c3aed\"],\n xaxis: {\n type: \"datetime\",\n min: new Date(startDate).setHours(0, 0, 0, 0),\n max: new Date(endDate).setHours(23, 59, 59, 999),\n },\n dataLabels: {\n enabled: false,\n },\n stroke: { curve: \"smooth\" },\n fill: {\n type: \"gradient\",\n gradient: {\n shadeIntensity: 1,\n opacityFrom: 0.7,\n opacityTo: 0.9,\n stops: [0, 90, 100],\n },\n },\n },\n };\n\n // fetch only if we already mounted\n useEffect(() => {\n fetchViews();\n }, [props]);\n\n const fetchViews = () => {\n setLoading(true);\n apiFetch({\n path:\n \"/presto-player/v1/analytics/views?\" +\n jQuery.param({\n ...(startDate\n ? { start: convertDateTimeToAbsoluteDate(startDate) }\n : {}),\n ...(endDate ? { end: convertDateTimeToAbsoluteDate(endDate) } : {}),\n }),\n parse: false,\n })\n .then(async (res) => {\n setTotalViews(res.headers && res.headers.get(\"X-WP-Total\"));\n const data = await res.json();\n\n let series = [];\n if (data.length) {\n data.forEach((item) => {\n series.push({\n x: item.date_time,\n y: item.total,\n });\n });\n }\n setSeries([\n {\n name: \"Views\",\n data: series,\n },\n ]);\n })\n .catch((e) => {\n console.error(e);\n })\n .finally(() => {\n setLoading(false);\n });\n };\n\n if (loading) {\n return (\n <CardBody>\n <Loading />\n </CardBody>\n );\n }\n\n return (\n <CardBody className=\"presto-flow\">\n <div className=\"presto-card__title\">\n {sprintf(__(\"%d Unique Views\", \"presto-player\"), totalViews)}\n </div>\n <Chart options={chart.options} series={series} type=\"area\" height={280} />\n </CardBody>\n );\n};\n","const { __, sprintf } = wp.i18n;\nconst { Card, CardBody } = wp.components;\nconst { useState, useEffect, useRef } = wp.element;\n\nimport Loading from \"@/admin/settings/components/Loading\";\nimport apiFetch from \"@/shared/services/fetch\";\nimport Chart from \"react-apexcharts\";\nimport { convertDateTimeToAbsoluteDate, humanSeconds } from \"../util\";\n\nexport default (props) => {\n const [loading, setLoading] = useState(true);\n const [averageTime, setAverageTime] = useState(0);\n const { startDate, endDate } = props;\n const [series, setSeries] = useState([\n {\n name: \"Views\",\n data: [],\n },\n ]);\n\n const chart = {\n options: {\n chart: {\n toolbar: {\n show: false,\n },\n },\n yaxis: {\n labels: {\n formatter: function (num) {\n return Math.abs(num) > 999\n ? Math.sign(num) * (Math.abs(num) / 1000).toFixed(1) + \"k min\"\n : (Math.sign(num) * Math.abs(num)).toFixed(1) + \"min\";\n },\n },\n },\n colors: [\"#7c3aed\"],\n xaxis: {\n type: \"datetime\",\n min: new Date(startDate).setHours(0, 0, 0, 0),\n max: new Date(endDate).setHours(23, 59, 59, 999),\n },\n dataLabels: {\n enabled: false,\n },\n stroke: { curve: \"smooth\" },\n fill: {\n type: \"gradient\",\n gradient: {\n shadeIntensity: 1,\n opacityFrom: 0.7,\n opacityTo: 0.9,\n stops: [0, 90, 100],\n },\n },\n },\n };\n\n // fetch only if we already mounted\n useEffect(() => {\n fetchMinutes();\n }, [props]);\n\n const fetchMinutes = () => {\n setLoading(true);\n apiFetch({\n path:\n \"/presto-player/v1/analytics/watch-time?\" +\n jQuery.param({\n start: convertDateTimeToAbsoluteDate(startDate),\n end: convertDateTimeToAbsoluteDate(endDate),\n }),\n parse: false,\n })\n .then(async (res) => {\n const { data, average } = await res.json();\n\n setAverageTime(parseFloat(average));\n\n let series = [];\n if (data.length) {\n data.forEach((item) => {\n series.push({\n x: item.date_time,\n y: (item.total / 60).toFixed(2),\n });\n });\n }\n setSeries([\n {\n name: \"Watch Time\",\n data: series,\n },\n ]);\n })\n .catch((e) => {\n console.error(e);\n })\n .finally(() => {\n setLoading(false);\n });\n };\n\n if (loading) {\n return (\n <CardBody>\n <Loading />\n </CardBody>\n );\n }\n\n return (\n <CardBody className=\"presto-flow\">\n <div className=\"presto-card__title\">\n {sprintf(\n __(\"%s average watch time\", \"presto-player\"),\n humanSeconds(averageTime)\n )}\n </div>\n <Chart options={chart.options} series={series} type=\"area\" height={280} />\n </CardBody>\n );\n};\n","const { __ } = wp.i18n;\nconst { Panel, TabPanel } = wp.components;\n\nimport TotalViewsGraph from \"./TotalViewsGraph\";\nimport TotalWatchGraph from \"./TotalWatchGraph\";\n\nexport default ({ startDate, endDate }) => {\n return (\n <Panel>\n <TabPanel\n className=\"presto-module-tabs\"\n onSelect={() => {}}\n tabs={[\n {\n name: \"views\",\n title: __(\"Views\", \"presto-player\"),\n },\n {\n name: \"watch\",\n title: __(\"Watch Time\", \"presto-player\"),\n },\n ]}\n >\n {(tab) => {\n switch (tab.name) {\n case \"views\":\n return (\n <TotalViewsGraph startDate={startDate} endDate={endDate} />\n );\n case \"watch\":\n return (\n <TotalWatchGraph startDate={startDate} endDate={endDate} />\n );\n default:\n return <>Not Found</>;\n }\n }}\n </TabPanel>\n </Panel>\n );\n};\n","const { __ } = wp.i18n;\nconst { useRef, useEffect, useState } = wp.element;\n\nimport Litepicker from \"litepicker\";\nimport \"litepicker/dist/plugins/ranges\";\n\nexport default ({ startDate, setStartDate, endDate, setEndDate }) => {\n const dateRef = useRef();\n const [inputSize, setInputSize] = useState(25);\n\n let datepicker;\n useEffect(() => {\n datepicker = new Litepicker({\n element: dateRef?.current,\n singleMode: false,\n format: \"MMMM D YYYY\",\n autoApply: false,\n plugins: [\"ranges\"],\n maxDate: new Date(),\n numberOfMonths: 2,\n buttonText: {\n apply: __(\"Apply\", \"presto-player\"),\n cancel: __(\"Cancel\", \"presto-player\"),\n },\n dropdowns: {\n minYear: 1990,\n maxYear: null,\n months: true,\n years: true,\n },\n setup: (picker) => {\n picker.setDateRange(startDate, endDate);\n picker.on(\"button:apply\", (start, end) => {\n setStartDate(start.dateInstance);\n setEndDate(end.dateInstance);\n setInputSize(dateRef.current.value.length);\n });\n },\n });\n }, [dateRef]);\n\n return (\n <div className=\"component-base-control\">\n <div className=\"components-base-control__field\">\n <input\n className=\"components-text-control__input presto-settings__date-select\"\n ref={dateRef}\n size={inputSize}\n />\n </div>\n </div>\n );\n};\n","/** @jsx jsx */\n\nconst { __ } = wp.i18n;\nconst { Flex, FlexBlock, FlexItem } = wp.components;\nconst { useState, useEffect } = wp.element;\n\nimport TopUsers from \"../components/TopUsers\";\nimport TopVideos from \"../components/TopVideos\";\nimport OverviewPanel from \"../components/OverviewPanel\";\nimport DatePicker from \"../components/DatePicker\";\nimport apiFetch from \"@wordpress/api-fetch\";\nimport { Notice } from \"@wordpress/components\";\nimport { css, jsx } from \"@emotion/core\";\n\nexport default function ({ startDate, endDate, setStartDate, setEndDate }) {\n const [noticeStatus, setNoticeStatus] = useState(false);\n\n // run this only on mount.\n useEffect(() => {\n apiFetch({ path: \"/wp/v2/settings\" }).then((post) => {\n if (post?.presto_player_analytics?.enable === false) {\n setNoticeStatus(true);\n }\n });\n }, []);\n\n return (\n <>\n {/* Component decleared below this code */}\n {noticeStatus ? <MyNotice /> : \"\"}\n <Flex>\n <FlexBlock>\n <h1>{__(\"Analytics\", \"presto-player\")}</h1>\n </FlexBlock>\n <FlexItem>\n <DatePicker\n startDate={startDate}\n setStartDate={setStartDate}\n endDate={endDate}\n setEndDate={setEndDate}\n />\n </FlexItem>\n </Flex>\n\n <div className=\"presto-flow\">\n <div className=\"presto-dashboard\">\n <div className=\"presto-dashboard__row\">\n <div className=\"presto-dashboard__item is-large\">\n <OverviewPanel startDate={startDate} endDate={endDate} />\n </div>\n <div className=\"presto-dashboard__item\">\n <TopUsers startDate={startDate} endDate={endDate} />\n </div>\n </div>\n\n <div className=\"presto-dashboard__row\">\n <div className=\"presto-dashboard__item is-large\">\n <TopVideos startDate={startDate} endDate={endDate} />\n </div>\n </div>\n </div>\n </div>\n </>\n );\n}\n\nconst MyNotice = () => (\n <Notice\n css={css`\n margin: 0 0 1em 0 !important;\n `}\n status=\"warning\"\n isDismissible={false}\n >\n <p>\n {__(\n \"Analytics are currently disabled. To collect analytics, turn them on in your settings page.\",\n \"presto-player\"\n )}\n </p>\n </Notice>\n);\n","const { Card, CardBody } = wp.components;\nimport Loading from \"@/admin/settings/components/Loading\";\n\nexport default ({ loading, title, value, label }) => {\n if (loading) {\n return (\n <Card>\n <CardBody>\n <Loading />\n </CardBody>\n </Card>\n );\n }\n\n return (\n <Card className=\"presto-player__stat-card\">\n <CardBody>\n <div className=\"presto-subtitle\">{title}</div>\n <h1>{value}</h1>\n <div>{label}</div>\n </CardBody>\n </Card>\n );\n};\n","/**\n * WordPress dependencies\n */\nconst { apiFetch } = wp;\nconst { useState } = wp.element;\nconst { createHigherOrderComponent } = wp.compose;\n\n/**\n * Higher order component factory\n *\n * @return {Function} The higher order component.\n */\nexport default () =>\n createHigherOrderComponent(\n (WrappedComponent) => (props) => {\n const [loading, setLoading] = useState(false);\n const [stat, setStat] = useState([]);\n const [error, setError] = useState(\"\");\n\n // fetch data\n // we could also abstract this function to make it reusable\n // or do a higher order component\n const fetchData = async ({ endpoint, params = {} }) => {\n setLoading(true);\n\n let responseData;\n try {\n responseData = await apiFetch({\n path: wp.url.addQueryArgs(endpoint, {\n ...params,\n }),\n });\n setStat(responseData);\n } catch (e) {\n console.error(e);\n if (e?.message) {\n setError(e.message);\n }\n } finally {\n setLoading(false);\n }\n };\n\n return (\n <WrappedComponent\n loading={loading}\n setLoading={setLoading}\n fetchData={fetchData}\n stat={stat}\n setStat={setStat}\n error={error}\n setError={setError}\n {...props}\n />\n );\n },\n \"withStat\"\n );\n","const { __ } = wp.i18n;\nconst { compose } = wp.compose;\nconst { useEffect } = wp.element;\n\nimport StatCard from \"@/admin/ui/StatCard\";\nimport withStat from \"../hocs/withStat\";\nimport { convertDateTimeToAbsoluteDate } from \"../util\";\n\nexport default compose([withStat()])((props) => {\n const { userId, startDate, endDate, stat, fetchData, loading } = props;\n\n useEffect(() => {\n fetchData({\n endpoint: `/presto-player/v1/analytics/user/${userId}/total-views`,\n params: {\n start: convertDateTimeToAbsoluteDate(startDate),\n end: convertDateTimeToAbsoluteDate(endDate),\n },\n });\n }, [startDate, endDate]);\n\n return (\n <StatCard\n loading={loading}\n value={parseInt(stat?.view)}\n title={__(\"Total Views\", \"presto-player\")}\n />\n );\n});\n","const { __ } = wp.i18n;\nconst { compose } = wp.compose;\nconst { useEffect } = wp.element;\n\nimport StatCard from \"@/admin/ui/StatCard\";\nimport withStat from \"../hocs/withStat\";\nimport { convertDateTimeToAbsoluteDate } from \"../util\";\n\nexport default compose([withStat()])((props) => {\n const { userId, startDate, endDate, stat, fetchData, loading } = props;\n\n useEffect(() => {\n fetchData({\n endpoint: `/presto-player/v1/analytics/user/${userId}/average-watchtime`,\n params: {\n start: convertDateTimeToAbsoluteDate(startDate),\n end: convertDateTimeToAbsoluteDate(endDate),\n },\n });\n }, [startDate, endDate]);\n\n return (\n <StatCard\n loading={loading}\n value={parseFloat(stat?.view).toFixed(2)}\n title={__(\"Average Watch Time\", \"presto-player\")}\n label={__(\"seconds\", \"presto-player\")}\n />\n );\n});\n","const { __ } = wp.i18n;\nconst { compose } = wp.compose;\nconst { useEffect } = wp.element;\n\nimport StatCard from \"@/admin/ui/StatCard\";\nimport withStat from \"../hocs/withStat\";\nimport { convertDateTimeToAbsoluteDate } from \"../util\";\n\nexport default compose([withStat()])((props) => {\n const { userId, startDate, endDate, stat, fetchData, loading } = props;\n\n useEffect(() => {\n fetchData({\n endpoint: `/presto-player/v1/analytics/user/${userId}/total-watchtime`,\n params: {\n start: convertDateTimeToAbsoluteDate(startDate),\n end: convertDateTimeToAbsoluteDate(endDate),\n },\n });\n }, [startDate, endDate]);\n\n return (\n <StatCard\n loading={loading}\n value={parseFloat(stat?.view).toFixed(2)}\n title={__(\"Total Watch Time\", \"presto-player\")}\n label={__(\"seconds\", \"presto-player\")}\n />\n );\n});\n","/** @jsx jsx */\n\nconst { __ } = wp.i18n;\n\nconst { Flex, FlexBlock, FlexItem, Spinner, Button } = wp.components;\n\nimport { history } from \"@/router/context\";\nimport DatePicker from \"../components/DatePicker\";\nimport TopVideos from \"../components/TopVideos\";\nimport TotalVideoViewsByUser from \"../components/TotalVideoViewsByUser\";\nimport VideoAverageWatchTimeByUser from \"../components/VideoAverageWatchTimeByUser\";\nimport VideoTotalWatchTimeByUser from \"../components/VideoTotalWatchTimeByUser\";\n\nconst { useEffect, useState } = wp.element;\nconst { apiFetch } = wp;\n\nimport { css, jsx } from \"@emotion/core\";\n\nconst User = ({ route, startDate, endDate, setStartDate, setEndDate }) => {\n const [loading, setLoading] = useState(true);\n const [user, setUser] = useState({});\n const [error, setError] = useState(\"\");\n\n const back = () => {\n history.push(`#/`);\n };\n\n const getUser = async () => {\n setLoading(true);\n try {\n let user = await apiFetch({\n url: `/wp-json/wp/v2/users/${route?.params?.id}?context=edit`,\n });\n setUser(user);\n } catch (e) {\n if (e.code === \"rest_no_route\") {\n setError(\"User Not Found\");\n }\n } finally {\n setLoading(false);\n }\n };\n\n useEffect(() => {\n getUser();\n }, []);\n\n if (error) {\n return (\n <div className=\"presto-flow\">\n <Flex>\n <FlexBlock>\n <h2>{error}</h2>\n </FlexBlock>\n </Flex>\n </div>\n );\n }\n\n return (\n <div className=\"presto-flow\">\n <Flex>\n <FlexBlock>\n <Button isSecondary onClick={back}>\n &larr; {__(\"Back to Dashboard\", \"presto-player\")}\n </Button>\n </FlexBlock>\n </Flex>\n <Flex wrap>\n <FlexBlock>\n {loading ? (\n <Spinner />\n ) : (\n <div\n css={css`\n display: flex;\n align-items: center;\n\n .presto__edit-user-button {\n opacity: 0;\n visibility: hidden;\n transition: opacity 0.3s ease;\n }\n\n &:hover {\n .presto__edit-user-button {\n opacity: 1;\n visibility: visible;\n }\n }\n `}\n >\n <div>\n <h1 className=\"presto-dashboard__title\">{user?.name}</h1>\n <p\n css={css`\n margin-top: -10px;\n opacity: 0.65;\n `}\n >\n {user?.email}\n </p>\n </div>\n {!!user.id && (\n <div\n className=\"presto__edit-user-button\"\n css={css`\n margin: 0 20px;\n `}\n >\n <Button\n href={`/wp-admin/user-edit.php?user_id=${user?.id}`}\n isSecondary\n isSmall\n >\n {__(\"View Profile\", \"presto-player\")} &rarr;\n </Button>\n </div>\n )}\n </div>\n )}\n </FlexBlock>\n <FlexItem>\n <DatePicker\n startDate={startDate}\n setStartDate={setStartDate}\n endDate={endDate}\n setEndDate={setEndDate}\n />\n </FlexItem>\n </Flex>\n\n <div className=\"presto-dashboard presto-flow\">\n <div className=\"presto-dashboard__row\">\n <div className=\"presto-dashboard__item\">\n <TotalVideoViewsByUser\n userId={route?.params?.id}\n startDate={startDate}\n endDate={endDate}\n />\n </div>\n <div className=\"presto-dashboard__item\">\n <VideoAverageWatchTimeByUser\n userId={route?.params?.id}\n startDate={startDate}\n endDate={endDate}\n />\n </div>\n <div className=\"presto-dashboard__item\">\n <VideoTotalWatchTimeByUser\n userId={route?.params?.id}\n startDate={startDate}\n endDate={endDate}\n />\n </div>\n </div>\n <div className=\"presto-dashboard__row\">\n <div className=\"presto-dashboard__item is-large\">\n <TopVideos\n startDate={startDate}\n endDate={endDate}\n userId={route?.params?.id}\n />\n </div>\n </div>\n </div>\n </div>\n );\n};\n\nexport default User;\n","const { __ } = wp.i18n;\nconst { compose } = wp.compose;\nconst { useEffect } = wp.element;\n\nimport StatCard from \"@/admin/ui/StatCard\";\nimport withStat from \"../hocs/withStat\";\nimport { convertDateTimeToAbsoluteDate } from \"../util\";\n\nexport default compose([withStat()])((props) => {\n const { video_id, startDate, endDate, stat, fetchData, loading } = props;\n\n useEffect(() => {\n fetchData({\n endpoint: `/presto-player/v1/analytics/video/${video_id}/average-watchtime`,\n params: {\n start: convertDateTimeToAbsoluteDate(startDate),\n end: convertDateTimeToAbsoluteDate(endDate),\n },\n });\n }, [startDate, endDate]);\n\n return (\n <StatCard\n loading={loading}\n value={parseInt(stat)}\n title={__(\"Average Watch Time\", \"presto-player\")}\n label={__(\"seconds\", \"presto-player\")}\n />\n );\n});\n","const { __, sprintf } = wp.i18n;\nconst { Card, CardBody } = wp.components;\nconst { useState, useEffect, useRef } = wp.element;\n\nimport Loading from \"@/admin/settings/components/Loading\";\nimport apiFetch from \"@/shared/services/fetch\";\nimport Chart from \"react-apexcharts\";\nimport { convertDateTimeToAbsoluteDate, timestamp } from \"../util\";\n\nexport default (props) => {\n const { video_id, startDate, endDate } = props;\n const [loading, setLoading] = useState(true);\n\n const [series, setSeries] = useState([\n {\n name: \"Views\",\n data: [],\n },\n ]);\n\n const fetchTimeline = () => {\n setLoading(true);\n apiFetch({\n path: wp.url.addQueryArgs(\n `/presto-player/v1/analytics/video/${video_id}/timeline`,\n {\n start: convertDateTimeToAbsoluteDate(startDate),\n end: convertDateTimeToAbsoluteDate(endDate),\n }\n ),\n })\n .then((data) => {\n let series = [];\n if (data.length) {\n data.forEach((item) => {\n // add another to them\n series.push({\n x: item.watch_time,\n y: item.total,\n });\n });\n }\n setSeries([\n {\n name: \"Viewers\",\n data: series,\n },\n ]);\n })\n .catch((e) => {\n console.error(e);\n })\n .finally(() => {\n setLoading(false);\n });\n };\n\n useEffect(() => {\n fetchTimeline();\n }, [startDate, endDate]);\n\n const chart = {\n options: {\n chart: {\n toolbar: {\n show: false,\n },\n },\n tickAmount: 1,\n yaxis: {\n labels: {\n formatter: function (num) {\n return parseInt(num);\n },\n },\n },\n xaxis: {\n labels: {\n formatter: function (num) {\n return timestamp(num);\n },\n },\n },\n colors: [\"#7c3aed\"],\n dataLabels: {\n enabled: false,\n },\n stroke: { curve: \"smooth\" },\n fill: {\n type: \"gradient\",\n gradient: {\n shadeIntensity: 1,\n opacityFrom: 0.7,\n opacityTo: 0.9,\n stops: [0, 90, 100],\n },\n },\n },\n };\n\n if (loading) {\n return (\n <Card>\n <CardBody>\n <Loading />\n </CardBody>\n </Card>\n );\n }\n\n return (\n <Card>\n <CardBody>\n <div className=\"presto-card__title\">\n {__(\"Audience Retention\", \"presto-player\")}\n </div>\n <Chart\n options={chart.options}\n series={series}\n type=\"area\"\n height={280}\n />\n </CardBody>\n </Card>\n );\n};\n","const { __ } = wp.i18n;\nconst { compose } = wp.compose;\nconst { useEffect } = wp.element;\n\nimport StatCard from \"@/admin/ui/StatCard\";\nimport withStat from \"../hocs/withStat\";\nimport { convertDateTimeToAbsoluteDate } from \"../util\";\n\nexport default compose([withStat()])((props) => {\n const { video_id, startDate, endDate, stat, fetchData, loading } = props;\n\n // fetch data when page changes\n useEffect(() => {\n fetchData({\n endpoint: `/presto-player/v1/analytics/video/${video_id}/views`,\n params: {\n start: convertDateTimeToAbsoluteDate(startDate),\n end: convertDateTimeToAbsoluteDate(endDate),\n },\n });\n }, [startDate, endDate]);\n\n return (\n <StatCard\n loading={loading}\n value={parseInt(stat)}\n title={__(\"Unique Views\", \"presto-player\")}\n />\n );\n});\n","export const dashToPascalCase = (str) => str\n .toLowerCase()\n .split('-')\n .map((segment) => segment.charAt(0).toUpperCase() + segment.slice(1))\n .join('');\nexport const camelToDashCase = (str) => str.replace(/([A-Z])/g, (m) => `-${m[0].toLowerCase()}`);\n//# sourceMappingURL=case.js.map","import { camelToDashCase } from './case';\nexport const attachProps = (node, newProps, oldProps = {}) => {\n // some test frameworks don't render DOM elements, so we test here to make sure we are dealing with DOM first\n if (node instanceof Element) {\n // add any classes in className to the class list\n const className = getClassName(node.classList, newProps, oldProps);\n if (className !== '') {\n node.className = className;\n }\n Object.keys(newProps).forEach((name) => {\n if (name === 'children' ||\n name === 'style' ||\n name === 'ref' ||\n name === 'class' ||\n name === 'className' ||\n name === 'forwardedRef') {\n return;\n }\n if (name.indexOf('on') === 0 && name[2] === name[2].toUpperCase()) {\n const eventName = name.substring(2);\n const eventNameLc = eventName[0].toLowerCase() + eventName.substring(1);\n if (!isCoveredByReact(eventNameLc)) {\n syncEvent(node, eventNameLc, newProps[name]);\n }\n }\n else {\n node[name] = newProps[name];\n const propType = typeof newProps[name];\n if (propType === 'string') {\n node.setAttribute(camelToDashCase(name), newProps[name]);\n }\n }\n });\n }\n};\nexport const getClassName = (classList, newProps, oldProps) => {\n const newClassProp = newProps.className || newProps.class;\n const oldClassProp = oldProps.className || oldProps.class;\n // map the classes to Maps for performance\n const currentClasses = arrayToMap(classList);\n const incomingPropClasses = arrayToMap(newClassProp ? newClassProp.split(' ') : []);\n const oldPropClasses = arrayToMap(oldClassProp ? oldClassProp.split(' ') : []);\n const finalClassNames = [];\n // loop through each of the current classes on the component\n // to see if it should be a part of the classNames added\n currentClasses.forEach((currentClass) => {\n if (incomingPropClasses.has(currentClass)) {\n // add it as its already included in classnames coming in from newProps\n finalClassNames.push(currentClass);\n incomingPropClasses.delete(currentClass);\n }\n else if (!oldPropClasses.has(currentClass)) {\n // add it as it has NOT been removed by user\n finalClassNames.push(currentClass);\n }\n });\n incomingPropClasses.forEach((s) => finalClassNames.push(s));\n return finalClassNames.join(' ');\n};\n/**\n * Checks if an event is supported in the current execution environment.\n * @license Modernizr 3.0.0pre (Custom Build) | MIT\n */\nexport const isCoveredByReact = (eventNameSuffix) => {\n if (typeof document === 'undefined') {\n return true;\n }\n else {\n const eventName = 'on' + eventNameSuffix;\n let isSupported = eventName in document;\n if (!isSupported) {\n const element = document.createElement('div');\n element.setAttribute(eventName, 'return;');\n isSupported = typeof element[eventName] === 'function';\n }\n return isSupported;\n }\n};\nexport const syncEvent = (node, eventName, newEventHandler) => {\n const eventStore = node.__events || (node.__events = {});\n const oldEventHandler = eventStore[eventName];\n // Remove old listener so they don't double up.\n if (oldEventHandler) {\n node.removeEventListener(eventName, oldEventHandler);\n }\n // Bind new listener.\n node.addEventListener(eventName, (eventStore[eventName] = function handler(e) {\n if (newEventHandler) {\n newEventHandler.call(this, e);\n }\n }));\n};\nconst arrayToMap = (arr) => {\n const map = new Map();\n arr.forEach((s) => map.set(s, s));\n return map;\n};\n//# sourceMappingURL=attachProps.js.map","import React from 'react';\nexport const setRef = (ref, value) => {\n if (typeof ref === 'function') {\n ref(value);\n }\n else if (ref != null) {\n // Cast as a MutableRef so we can assign current\n ref.current = value;\n }\n};\nexport const mergeRefs = (...refs) => {\n return (value) => {\n refs.forEach(ref => {\n setRef(ref, value);\n });\n };\n};\nexport const createForwardRef = (ReactComponent, displayName) => {\n const forwardRef = (props, ref) => {\n return React.createElement(ReactComponent, Object.assign({}, props, { forwardedRef: ref }));\n };\n forwardRef.displayName = displayName;\n return React.forwardRef(forwardRef);\n};\nexport const defineCustomElement = (tagName, customElement) => {\n if (customElement !== undefined &&\n typeof customElements !== 'undefined' &&\n !customElements.get(tagName)) {\n customElements.define(tagName, customElement);\n }\n};\nexport * from './attachProps';\nexport * from './case';\n//# sourceMappingURL=index.js.map","var __rest = (this && this.__rest) || function (s, e) {\n var t = {};\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)\n t[p] = s[p];\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\")\n for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))\n t[p[i]] = s[p[i]];\n }\n return t;\n};\nimport React from 'react';\nimport { attachProps, createForwardRef, dashToPascalCase, isCoveredByReact, mergeRefs, } from './utils';\nexport const createReactComponent = (tagName, ReactComponentContext, manipulatePropsFunction, defineCustomElement) => {\n if (defineCustomElement !== undefined) {\n defineCustomElement();\n }\n const displayName = dashToPascalCase(tagName);\n const ReactComponent = class extends React.Component {\n constructor(props) {\n super(props);\n this.setComponentElRef = (element) => {\n this.componentEl = element;\n };\n }\n componentDidMount() {\n this.componentDidUpdate(this.props);\n }\n componentDidUpdate(prevProps) {\n attachProps(this.componentEl, this.props, prevProps);\n }\n render() {\n const _a = this.props, { children, forwardedRef, style, className, ref } = _a, cProps = __rest(_a, [\"children\", \"forwardedRef\", \"style\", \"className\", \"ref\"]);\n let propsToPass = Object.keys(cProps).reduce((acc, name) => {\n if (name.indexOf('on') === 0 && name[2] === name[2].toUpperCase()) {\n const eventName = name.substring(2).toLowerCase();\n if (typeof document !== 'undefined' && isCoveredByReact(eventName)) {\n acc[name] = cProps[name];\n }\n }\n else {\n acc[name] = cProps[name];\n }\n return acc;\n }, {});\n if (manipulatePropsFunction) {\n propsToPass = manipulatePropsFunction(this.props, propsToPass);\n }\n const newProps = Object.assign(Object.assign({}, propsToPass), { ref: mergeRefs(forwardedRef, this.setComponentElRef), style });\n return React.createElement(tagName, newProps, children);\n }\n static get displayName() {\n return displayName;\n }\n };\n // If context was passed to createReactComponent then conditionally add it to the Component Class\n if (ReactComponentContext) {\n ReactComponent.contextType = ReactComponentContext;\n }\n return createForwardRef(ReactComponent, displayName);\n};\n//# sourceMappingURL=createComponent.js.map","/* eslint-disable */\n/* tslint:disable */\n/* auto-generated react proxies */\nimport { createReactComponent } from './react-component-lib';\nexport const PrestoActionBar = /*@__PURE__*/ createReactComponent('presto-action-bar');\nexport const PrestoActionBarController = /*@__PURE__*/ createReactComponent('presto-action-bar-controller');\nexport const PrestoActionBarUi = /*@__PURE__*/ createReactComponent('presto-action-bar-ui');\nexport const PrestoAudio = /*@__PURE__*/ createReactComponent('presto-audio');\nexport const PrestoBunny = /*@__PURE__*/ createReactComponent('presto-bunny');\nexport const PrestoBusinessSkin = /*@__PURE__*/ createReactComponent('presto-business-skin');\nexport const PrestoCtaOverlay = /*@__PURE__*/ createReactComponent('presto-cta-overlay');\nexport const PrestoCtaOverlayController = /*@__PURE__*/ createReactComponent('presto-cta-overlay-controller');\nexport const PrestoCtaOverlayUi = /*@__PURE__*/ createReactComponent('presto-cta-overlay-ui');\nexport const PrestoDynamicOverlayUi = /*@__PURE__*/ createReactComponent('presto-dynamic-overlay-ui');\nexport const PrestoDynamicOverlays = /*@__PURE__*/ createReactComponent('presto-dynamic-overlays');\nexport const PrestoEmailOverlay = /*@__PURE__*/ createReactComponent('presto-email-overlay');\nexport const PrestoEmailOverlayController = /*@__PURE__*/ createReactComponent('presto-email-overlay-controller');\nexport const PrestoEmailOverlayUi = /*@__PURE__*/ createReactComponent('presto-email-overlay-ui');\nexport const PrestoModernSkin = /*@__PURE__*/ createReactComponent('presto-modern-skin');\nexport const PrestoMutedOverlay = /*@__PURE__*/ createReactComponent('presto-muted-overlay');\nexport const PrestoPlayer = /*@__PURE__*/ createReactComponent('presto-player');\nexport const PrestoPlayerButton = /*@__PURE__*/ createReactComponent('presto-player-button');\nexport const PrestoPlayerSkeleton = /*@__PURE__*/ createReactComponent('presto-player-skeleton');\nexport const PrestoPlayerSpinner = /*@__PURE__*/ createReactComponent('presto-player-spinner');\nexport const PrestoStackedSkin = /*@__PURE__*/ createReactComponent('presto-stacked-skin');\nexport const PrestoTimestamp = /*@__PURE__*/ createReactComponent('presto-timestamp');\nexport const PrestoVideo = /*@__PURE__*/ createReactComponent('presto-video');\nexport const PrestoVideoCurtainUi = /*@__PURE__*/ createReactComponent('presto-video-curtain-ui');\nexport const PrestoVimeo = /*@__PURE__*/ createReactComponent('presto-vimeo');\nexport const PrestoYoutube = /*@__PURE__*/ createReactComponent('presto-youtube');\nexport const PrestoYoutubeSubscribeButton = /*@__PURE__*/ createReactComponent('presto-youtube-subscribe-button');\n//# sourceMappingURL=index.js.map","const { useRef, useEffect } = wp.element;\n\nexport function usePrevious(value) {\n const ref = useRef();\n useEffect(() => {\n ref.current = value;\n });\n return ref.current;\n}\n\nexport function snackbarNotice({ status = \"success\", message }) {\n wp.data.dispatch(\"core/notices\").createNotice(\n status, // Can be one of: success, info, warning, error.\n message, // Text string to display.\n { type: \"snackbar\" }\n );\n}\n\nexport const bytesToSize = (bytes) => {\n var sizes = [\"Bytes\", \"KB\", \"MB\", \"GB\", \"TB\"];\n if (bytes == 0) return \"0 Byte\";\n var i = parseInt(Math.floor(Math.log(bytes) / Math.log(1024)));\n return Math.round(bytes / Math.pow(1024, i), 2) + \" \" + sizes[i];\n};\n\nexport const toDate = (d) => {\n d = new Date(d);\n var hours = d.getHours();\n var minutes = d.getMinutes();\n var ampm = hours >= 12 ? \"pm\" : \"am\";\n hours = hours % 12;\n hours = hours ? hours : 12;\n minutes = minutes < 10 ? \"0\" + minutes : minutes;\n\n return (\n d.getDate() +\n \"-\" +\n (d.getMonth() + 1) +\n \"-\" +\n d.getFullYear() +\n \" at \" +\n hours +\n \":\" +\n minutes +\n ampm\n );\n};\n\nexport function timeToSeconds(time) {\n let pieces = time.split(\":\");\n let seconds;\n if (pieces.length > 1) {\n seconds = parseInt(pieces[0]) * 60;\n }\n return parseInt(pieces[1]) + parseInt(seconds);\n}\n\nexport function secondsToTime(number) {\n let seconds = parseInt(number, 10);\n let minutes = Math.floor(seconds / 60);\n if (seconds < 10) {\n seconds = \"0\" + seconds;\n }\n return minutes + \":\" + seconds;\n}\n\nexport function sanitizeTime(time) {\n let draft = time;\n // remove any letters\n draft = draft.replace(/[^\\d\\d:\\d\\d.-]/g, \"\");\n // make sure we have :\n if (!draft.includes(\":\")) {\n return `${draft}:00`;\n }\n\n // must have something before :00\n if (draft.substr(0, draft.indexOf(\":\")).length === 0) {\n draft = `0${draft}`;\n }\n\n // only allow 2 characters after :\n let index = draft.indexOf(\":\");\n draft = draft.substring(0, index + 3);\n return draft;\n}\n\nexport function getProvider(src) {\n const provider = \"self-hosted\";\n\n if (src) {\n const yt_rx = /^(?:https?:\\/\\/)?(?:www\\.)?(?:youtu\\.be\\/|youtube\\.com\\/(?:embed\\/|v\\/|watch\\?v=|watch\\?.+&v=))((\\w|-){11})(?:\\S+)?$/;\n const has_match_youtube = src.match(yt_rx);\n\n if (has_match_youtube) {\n return \"youtube\";\n }\n\n const vm_rx = /(https?:\\/\\/)?(www\\.)?(player\\.)?vimeo\\.com\\/([a-z]*\\/)*([‌​0-9]{6,11})[?]?.*/;\n const has_match_vimeo = src.match(vm_rx);\n\n if (has_match_vimeo) {\n return \"vimeo\";\n }\n\n if (src.indexOf(\"https://vz-\") > -1 && src.indexOf(\"b-cdn.net\") > -1) {\n return \"bunny\";\n }\n\n if (src.indexOf(\".mp3\") > -1) {\n return \"audio\";\n }\n }\n return provider;\n}\n","import { PrestoPlayer } from \"@presto-player/react\";\nimport { getProvider } from \"../util\";\nconst { useSelect } = wp.data;\n\nexport default ({\n src,\n classes,\n preset,\n branding,\n attributes,\n adminPreview,\n currentTime,\n preload = \"metadata\",\n overlays,\n type,\n}) => {\n const { chapters, mutedOverlay, mutedPreview } = attributes;\n\n const youtube = useSelect((select) => {\n return select(\"presto-player/player\")?.youtube();\n });\n\n const css = useSelect((select) => {\n return select(\"presto-player/player\")?.playerCSS();\n });\n\n const convertHex = (hexCode, opacity = 1) => {\n var hex = hexCode.replace(\"#\", \"\");\n\n if (hex.length === 3) {\n hex = hex[0] + hex[0] + hex[1] + hex[1] + hex[2] + hex[2];\n }\n\n var r = parseInt(hex.substring(0, 2), 16),\n g = parseInt(hex.substring(2, 4), 16),\n b = parseInt(hex.substring(4, 6), 16);\n\n /* Backward compatibility for whole number based opacity values. */\n if (opacity > 1 && opacity <= 100) {\n opacity = opacity / 100;\n }\n\n return \"rgba(\" + r + \",\" + g + \",\" + b + \",\" + opacity + \")\";\n };\n\n const mutedOverlayContent = () => {\n return (\n <div\n className=\"presto-player__overlay is-image\"\n style={{\n position: \"absolute\",\n width: `${mutedOverlay?.width || 100}%`,\n left: `${(mutedOverlay?.focalPoint?.x || 0.5) * 100}%`,\n top: `${(mutedOverlay?.focalPoint?.y || 0.5) * 100}%`,\n }}\n >\n <img\n src={mutedOverlay?.src}\n style={{\n transform: \"translateX(-50%) translateY(-50%)\",\n }}\n />\n </div>\n );\n };\n\n return (\n <div\n className={\"wp-block-video presto-block-video\"}\n style={\n type === \"audio\"\n ? {\n \"--presto-player-border-radius\": `${preset?.border_radius}px`,\n ...(preset?.background_color\n ? {\n \"--plyr-audio-controls-background\": preset.background_color,\n }\n : { \"--plyr-audio-controls-background\": branding?.color }),\n ...(preset?.control_color\n ? {\n \"--plyr-audio-control-color\": preset.control_color,\n \"--plyr-range-thumb-background\": preset.control_color,\n \"--plyr-range-fill-background\": preset.control_color,\n \"--plyr-audio-progress-buffered-background\": convertHex(\n preset.control_color || branding?.color || \"#00b3ff\",\n 0.5\n ),\n }\n : {\n \"--plyr-audio-control-color\": \"#ffffff\",\n \"--plyr-range-thumb-background\": \"#ffffff\",\n \"--plyr-range-fill-background\": \"#ffffff\",\n }),\n \"--plyr-range-thumb-shadow\": `0px`,\n }\n : {\n \"--presto-player-border-radius\": `${preset?.border_radius}px`,\n ...(preset?.caption_background\n ? { \"--plyr-captions-background\": preset.caption_background }\n : {}),\n ...(branding?.color\n ? { \"--plyr-color-main\": branding.color }\n : {}),\n \"--presto-player-email-border-radius\": `${\n preset?.email_collection?.border_radius || 0\n }px`,\n \"--presto-player-logo-width\": `${branding?.logo_width || 75}px`,\n }\n }\n >\n <PrestoPlayer\n src={src}\n css={css}\n classes={classes}\n currentTime={currentTime}\n overlays={overlays}\n isAdmin={true}\n preload={preload}\n preset={preset}\n bunny={{\n thumbnail: attributes?.previewThumbnail,\n preview: attributes?.preview,\n }}\n youtube={{\n channelId: youtube?.channel_id,\n }}\n tracks={\n !!preset?.captions && [\n {\n kind: \"captions\",\n label: \"English\",\n srclang: \"en\",\n src: \"/path/to/captions.en.vtt\",\n default: true,\n },\n ]\n }\n branding={branding}\n chapters={chapters}\n blockAttributes={attributes}\n poster={attributes.poster}\n provider={type === \"audio\" ? \"audio\" : getProvider(src)}\n mediaTitle={attributes.title}\n >\n <div slot=\"player-end\">\n {mutedPreview?.enabled &&\n mutedOverlay?.enabled &&\n mutedOverlayContent()}\n {adminPreview}\n </div>\n </PrestoPlayer>\n </div>\n );\n};\n","const { __ } = wp.i18n;\n\nconst {\n Flex,\n FlexBlock,\n FlexItem,\n Spinner,\n Button,\n TextControl,\n} = wp.components;\n\nimport { history } from \"@/router/context\";\nimport DatePicker from \"../components/DatePicker\";\nimport VideoAverageWatchTime from \"../components/VideoAverageWatchTime\";\nimport VideoTimeline from \"../components/VideoTimeline\";\nimport VideoViews from \"../components/VideoViews\";\nimport Player from \"../../blocks/shared/Player\";\nimport { getProvider } from \"../../blocks/util\";\n\nconst { useEffect, useState } = wp.element;\nconst { apiFetch } = wp;\n\nconst Video = ({ route, startDate, endDate, setStartDate, setEndDate }) => {\n const [loading, setLoading] = useState(true);\n const [video, setVideo] = useState({});\n const [error, setError] = useState(\"\");\n const [thisName, setThisName] = useState(null);\n const [editing, setEditing] = useState(false);\n\n const back = () => {\n history.push(`#/`);\n };\n\n const getVideo = async () => {\n setLoading(true);\n try {\n let video = await apiFetch({\n url: `${prestoPlayer?.root}${prestoPlayer?.prestoVersionString}videos/${route?.params?.id}`,\n });\n setVideo(video);\n setThisName(video?.title);\n } catch (e) {\n if (e.code === \"rest_no_route\") {\n setError(\"Video Not Found\");\n }\n } finally {\n setLoading(false);\n }\n };\n\n const putVideo = async () => {\n console.log(`New Video title ${thisName}`);\n setLoading(true);\n try {\n const data = {\n ...video,\n ...{ title: thisName },\n };\n let saved = await wp.apiFetch({\n method: \"POST\",\n url: wp.url.addQueryArgs(\n `${prestoPlayer.root}${prestoPlayer.prestoVersionString}videos/${video.id}`,\n { _method: \"PUT\" }\n ),\n data,\n });\n\n if (!saved) {\n throw genericError;\n }\n setEditing(false);\n setVideo(saved);\n } catch (e) {\n setError(e?.message ? e.message : genericError);\n } finally {\n setLoading(false);\n }\n };\n\n const cancelEditing = () => {\n setThisName(video?.title);\n setEditing(false);\n };\n\n const renderVideoEditableTitle = () => {\n if (loading) {\n return <Spinner />;\n } else if (editing) {\n return (\n <div className=\"presto-inline-edit presto-inline-edit--editing\">\n <TextControl\n className=\"presto-inline-edit__input\"\n type=\"text\"\n value={thisName}\n onChange={(title) => setThisName(title)}\n />\n <Button\n className=\"presto-inline-edit__button\"\n isPrimary\n onClick={putVideo}\n >\n {\" \"}\n Save{\" \"}\n </Button>\n <Button\n className=\"presto-inline-edit__button\"\n isSecondary\n onClick={cancelEditing}\n >\n {\" \"}\n Cancel{\" \"}\n </Button>\n </div>\n );\n } else {\n return (\n <div className=\"presto-inline-edit\">\n <h1 className=\"presto-dashboard__title presto-inline-edit__text\">\n {video?.title}\n </h1>\n\n <button\n className=\"presto-inline-edit__edit\"\n onClick={() => setEditing(true)}\n >\n <span className=\"dashicon dashicons dashicons-edit\"></span>\n </button>\n </div>\n );\n }\n };\n\n useEffect(() => {\n getVideo();\n }, []);\n\n if (error) {\n return (\n <div className=\"presto-flow\">\n <Flex>\n <FlexBlock>\n <h2>{error}</h2>\n </FlexBlock>\n </Flex>\n </div>\n );\n }\n\n return (\n <div className=\"presto-flow\">\n <Flex>\n <FlexBlock>\n <Button isSecondary onClick={back}>\n &larr; {__(\"Back to Dashboard\", \"presto-player\")}\n </Button>\n </FlexBlock>\n </Flex>\n <Flex wrap>\n <FlexBlock>{renderVideoEditableTitle()}</FlexBlock>\n <FlexItem>\n <DatePicker\n startDate={startDate}\n setStartDate={setStartDate}\n endDate={endDate}\n setEndDate={setEndDate}\n />\n </FlexItem>\n </Flex>\n\n <div className=\"presto-dashboard presto-flow\">\n <div className=\"presto-dashboard__row\">\n <div className=\"presto-dashboard__item is-large\">\n <VideoViews\n video_id={route?.params?.id}\n startDate={startDate}\n endDate={endDate}\n />\n </div>\n <div className=\"presto-dashboard__item\">\n {!!Object.keys(video || {}).length && (\n <Player\n src={video?.src}\n attributes={{\n title: video.title,\n }}\n type={getProvider(video.src)}\n preset={{\n \"play-large\": true,\n play: true,\n progress: true,\n rewind: true,\n \"fast-forward\": true,\n \"current-time\": true,\n background_color: \"#8421cb\",\n volume: true,\n mute: true,\n i18n: window.prestoPlayer.i18n,\n }}\n />\n )}\n </div>\n <div className=\"presto-dashboard__item\">\n <VideoAverageWatchTime\n video_id={route?.params?.id}\n startDate={startDate}\n endDate={endDate}\n />\n </div>\n </div>\n <div className=\"presto-dashboard__row\">\n <div className=\"presto-dashboard__item is-large\">\n <VideoTimeline\n video_id={route?.params?.id}\n startDate={startDate}\n endDate={endDate}\n />\n </div>\n </div>\n </div>\n </div>\n );\n};\n\nexport default Video;\n","export const routes = {\n dashboard: {\n path: \"/\",\n },\n video: {\n path: \"/video/:id\",\n },\n user: {\n path: \"/user/:id\",\n },\n};\n","const { useState } = wp.element;\n\nimport { Route, Router } from \"@/router\";\n\nimport AnalyticsUpgrade from \"./pages/AnalyticsUpgrade\";\nimport Dashboard from \"./pages/Dashboard\";\n\nimport User from \"./pages/User\";\nimport Video from \"./pages/Video\";\nimport { routes } from \"./routes\";\n\nexport default () => {\n const scrollToTop = () => {\n window.scrollTo(0, 0);\n };\n\n const [startDate, setStartDate] = useState(\n new Date(Date.now() - 7 * 24 * 60 * 60 * 1000)\n );\n const [endDate, setEndDate] = useState(new Date());\n\n if (!prestoPlayer?.isPremium) {\n return (\n <div className=\"presto-dashboard__content\">\n <AnalyticsUpgrade />\n </div>\n );\n }\n\n return (\n <div className=\"presto-dashboard__content\">\n <Router routes={routes}>\n <Route path={routes.dashboard.path} onRoute={scrollToTop}>\n <Dashboard\n startDate={startDate}\n endDate={endDate}\n setStartDate={setStartDate}\n setEndDate={setEndDate}\n />\n </Route>\n <Route path={routes.video.path} onRoute={scrollToTop}>\n <Video\n startDate={startDate}\n endDate={endDate}\n setStartDate={setStartDate}\n setEndDate={setEndDate}\n />\n </Route>\n <Route path={routes.user.path} onRoute={scrollToTop}>\n <User\n startDate={startDate}\n endDate={endDate}\n setStartDate={setStartDate}\n setEndDate={setEndDate}\n />\n </Route>\n </Router>\n </div>\n );\n};\n","const { render } = wp.element;\n\n/**\n * App\n */\nimport App from \"./App\";\n\n/**\n * styles\n */\nimport \"./analytics.scss\";\n\n/**\n * Render\n */\nrender(<App />, document.getElementById(\"presto-analytics-page\"));\n"],"sourceRoot":""}
 
dist/analytics/admin.dependencies.wp.json DELETED
@@ -1,8 +0,0 @@
1
- {
2
- "dependencies": [
3
- "wp-api-fetch",
4
- "wp-components",
5
- "wp-element"
6
- ],
7
- "version": "aa66148550c83ff143ada9c4e3b1d8ef"
8
- }
 
 
 
 
 
 
 
 
dist/analytics/manifest.json DELETED
@@ -1,32 +0,0 @@
1
- {
2
- "admin.css": "analytics/admin-7f8d2917.css",
3
- "admin.css.map": "analytics/admin-7f8d2917.css.map",
4
- "admin.js": "analytics/admin-9ff30d14.js",
5
- "admin.js.map": "analytics/admin-9ff30d14.js.map",
6
- "runtime.js": "analytics/runtime-42c36a43.js",
7
- "runtime.js.map": "analytics/runtime-42c36a43.js.map",
8
- "vendors--presto-player--admin.js": "analytics/vendors--presto-player--admin-44989e87.js",
9
- "vendors--presto-player--admin.js.map": "analytics/vendors--presto-player--admin-44989e87.js.map",
10
- "wpackioEp": {
11
- "admin": {
12
- "assets": {
13
- "js": [
14
- "analytics/runtime-42c36a43.js",
15
- "analytics/vendors--presto-player--admin-44989e87.js",
16
- "analytics/admin-9ff30d14.js"
17
- ],
18
- "js.map": [
19
- "analytics/runtime-42c36a43.js.map",
20
- "analytics/vendors--presto-player--admin-44989e87.js.map",
21
- "analytics/admin-9ff30d14.js.map"
22
- ],
23
- "css": [
24
- "analytics/admin-7f8d2917.css"
25
- ],
26
- "css.map": [
27
- "analytics/admin-7f8d2917.css.map"
28
- ]
29
- }
30
- }
31
- }
32
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
dist/analytics/runtime-42c36a43.js DELETED
@@ -1,18 +0,0 @@
1
- /*!
2
- *
3
- * Presto Player
4
- *
5
- * @author Presto Made, Inc
6
- * @version 0.1.0
7
- * @link undefined
8
- * @license GPL
9
- *
10
- * Copyright (c) 2022 Presto Made, Inc
11
- *
12
- * This software is released under the GPL License
13
- * https://opensource.org/licenses/GPL
14
- *
15
- * Compiled with the help of https://wpack.io
16
- * A zero setup Webpack Bundler Script for WordPress
17
- */!function(e){function r(r){for(var n,l,a=r[0],i=r[1],p=r[2],c=0,s=[];c<a.length;c++)l=a[c],Object.prototype.hasOwnProperty.call(o,l)&&o[l]&&s.push(o[l][0]),o[l]=0;for(n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n]);for(f&&f(r);s.length;)s.shift()();return u.push.apply(u,p||[]),t()}function t(){for(var e,r=0;r<u.length;r++){for(var t=u[r],n=!0,a=1;a<t.length;a++){var i=t[a];0!==o[i]&&(n=!1)}n&&(u.splice(r--,1),e=l(l.s=t[0]))}return e}var n={},o={1:0},u=[];function l(r){if(n[r])return n[r].exports;var t=n[r]={i:r,l:!1,exports:{}};return e[r].call(t.exports,t,t.exports,l),t.l=!0,t.exports}l.m=e,l.c=n,l.d=function(e,r,t){l.o(e,r)||Object.defineProperty(e,r,{enumerable:!0,get:t})},l.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},l.t=function(e,r){if(1&r&&(e=l(e)),8&r)return e;if(4&r&&"object"==typeof e&&e&&e.__esModule)return e;var t=Object.create(null);if(l.r(t),Object.defineProperty(t,"default",{enumerable:!0,value:e}),2&r&&"string"!=typeof e)for(var n in e)l.d(t,n,function(r){return e[r]}.bind(null,n));return t},l.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return l.d(r,"a",r),r},l.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},l.p="";var a=window.wpackioprestoPlayeranalyticsJsonp=window.wpackioprestoPlayeranalyticsJsonp||[],i=a.push.bind(a);a.push=r,a=a.slice();for(var p=0;p<a.length;p++)r(a[p]);var f=i;t()}([]);
18
- //# sourceMappingURL=runtime-42c36a43.js.map
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
dist/analytics/runtime-42c36a43.js.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"sources":["webpack:///webpack/bootstrap"],"names":["webpackJsonpCallback","data","moduleId","chunkId","chunkIds","moreModules","executeModules","i","resolves","length","Object","prototype","hasOwnProperty","call","installedChunks","push","modules","parentJsonpFunction","shift","deferredModules","apply","checkDeferredModules","result","deferredModule","fulfilled","j","depId","splice","__webpack_require__","s","installedModules","1","exports","module","l","m","c","d","name","getter","o","defineProperty","enumerable","get","r","Symbol","toStringTag","value","t","mode","__esModule","ns","create","key","bind","n","object","property","p","jsonpArray","window","oldJsonpFunction","slice"],"mappings":";;;;;;;;;;;;;;;;gBACE,SAASA,EAAqBC,GAQ7B,IAPA,IAMIC,EAAUC,EANVC,EAAWH,EAAK,GAChBI,EAAcJ,EAAK,GACnBK,EAAiBL,EAAK,GAIHM,EAAI,EAAGC,EAAW,GACpCD,EAAIH,EAASK,OAAQF,IACzBJ,EAAUC,EAASG,GAChBG,OAAOC,UAAUC,eAAeC,KAAKC,EAAiBX,IAAYW,EAAgBX,IACpFK,EAASO,KAAKD,EAAgBX,GAAS,IAExCW,EAAgBX,GAAW,EAE5B,IAAID,KAAYG,EACZK,OAAOC,UAAUC,eAAeC,KAAKR,EAAaH,KACpDc,EAAQd,GAAYG,EAAYH,IAKlC,IAFGe,GAAqBA,EAAoBhB,GAEtCO,EAASC,QACdD,EAASU,OAATV,GAOD,OAHAW,EAAgBJ,KAAKK,MAAMD,EAAiBb,GAAkB,IAGvDe,IAER,SAASA,IAER,IADA,IAAIC,EACIf,EAAI,EAAGA,EAAIY,EAAgBV,OAAQF,IAAK,CAG/C,IAFA,IAAIgB,EAAiBJ,EAAgBZ,GACjCiB,GAAY,EACRC,EAAI,EAAGA,EAAIF,EAAed,OAAQgB,IAAK,CAC9C,IAAIC,EAAQH,EAAeE,GACG,IAA3BX,EAAgBY,KAAcF,GAAY,GAE3CA,IACFL,EAAgBQ,OAAOpB,IAAK,GAC5Be,EAASM,EAAoBA,EAAoBC,EAAIN,EAAe,KAItE,OAAOD,EAIR,IAAIQ,EAAmB,GAKnBhB,EAAkB,CACrBiB,EAAG,GAGAZ,EAAkB,GAGtB,SAASS,EAAoB1B,GAG5B,GAAG4B,EAAiB5B,GACnB,OAAO4B,EAAiB5B,GAAU8B,QAGnC,IAAIC,EAASH,EAAiB5B,GAAY,CACzCK,EAAGL,EACHgC,GAAG,EACHF,QAAS,IAUV,OANAhB,EAAQd,GAAUW,KAAKoB,EAAOD,QAASC,EAAQA,EAAOD,QAASJ,GAG/DK,EAAOC,GAAI,EAGJD,EAAOD,QAKfJ,EAAoBO,EAAInB,EAGxBY,EAAoBQ,EAAIN,EAGxBF,EAAoBS,EAAI,SAASL,EAASM,EAAMC,GAC3CX,EAAoBY,EAAER,EAASM,IAClC5B,OAAO+B,eAAeT,EAASM,EAAM,CAAEI,YAAY,EAAMC,IAAKJ,KAKhEX,EAAoBgB,EAAI,SAASZ,GACX,oBAAXa,QAA0BA,OAAOC,aAC1CpC,OAAO+B,eAAeT,EAASa,OAAOC,YAAa,CAAEC,MAAO,WAE7DrC,OAAO+B,eAAeT,EAAS,aAAc,CAAEe,OAAO,KAQvDnB,EAAoBoB,EAAI,SAASD,EAAOE,GAEvC,GADU,EAAPA,IAAUF,EAAQnB,EAAoBmB,IAC/B,EAAPE,EAAU,OAAOF,EACpB,GAAW,EAAPE,GAA8B,iBAAVF,GAAsBA,GAASA,EAAMG,WAAY,OAAOH,EAChF,IAAII,EAAKzC,OAAO0C,OAAO,MAGvB,GAFAxB,EAAoBgB,EAAEO,GACtBzC,OAAO+B,eAAeU,EAAI,UAAW,CAAET,YAAY,EAAMK,MAAOA,IACtD,EAAPE,GAA4B,iBAATF,EAAmB,IAAI,IAAIM,KAAON,EAAOnB,EAAoBS,EAAEc,EAAIE,EAAK,SAASA,GAAO,OAAON,EAAMM,IAAQC,KAAK,KAAMD,IAC9I,OAAOF,GAIRvB,EAAoB2B,EAAI,SAAStB,GAChC,IAAIM,EAASN,GAAUA,EAAOiB,WAC7B,WAAwB,OAAOjB,EAAgB,SAC/C,WAA8B,OAAOA,GAEtC,OADAL,EAAoBS,EAAEE,EAAQ,IAAKA,GAC5BA,GAIRX,EAAoBY,EAAI,SAASgB,EAAQC,GAAY,OAAO/C,OAAOC,UAAUC,eAAeC,KAAK2C,EAAQC,IAGzG7B,EAAoB8B,EAAI,GAExB,IAAIC,EAAaC,OAA0C,kCAAIA,OAA0C,mCAAK,GAC1GC,EAAmBF,EAAW5C,KAAKuC,KAAKK,GAC5CA,EAAW5C,KAAOf,EAClB2D,EAAaA,EAAWG,QACxB,IAAI,IAAIvD,EAAI,EAAGA,EAAIoD,EAAWlD,OAAQF,IAAKP,EAAqB2D,EAAWpD,IAC3E,IAAIU,EAAsB4C,EAI1BxC,I","file":"analytics/runtime-42c36a43.js","sourcesContent":[" \t// install a JSONP callback for chunk loading\n \tfunction webpackJsonpCallback(data) {\n \t\tvar chunkIds = data[0];\n \t\tvar moreModules = data[1];\n \t\tvar executeModules = data[2];\n\n \t\t// add \"moreModules\" to the modules object,\n \t\t// then flag all \"chunkIds\" as loaded and fire callback\n \t\tvar moduleId, chunkId, i = 0, resolves = [];\n \t\tfor(;i < chunkIds.length; i++) {\n \t\t\tchunkId = chunkIds[i];\n \t\t\tif(Object.prototype.hasOwnProperty.call(installedChunks, chunkId) && installedChunks[chunkId]) {\n \t\t\t\tresolves.push(installedChunks[chunkId][0]);\n \t\t\t}\n \t\t\tinstalledChunks[chunkId] = 0;\n \t\t}\n \t\tfor(moduleId in moreModules) {\n \t\t\tif(Object.prototype.hasOwnProperty.call(moreModules, moduleId)) {\n \t\t\t\tmodules[moduleId] = moreModules[moduleId];\n \t\t\t}\n \t\t}\n \t\tif(parentJsonpFunction) parentJsonpFunction(data);\n\n \t\twhile(resolves.length) {\n \t\t\tresolves.shift()();\n \t\t}\n\n \t\t// add entry modules from loaded chunk to deferred list\n \t\tdeferredModules.push.apply(deferredModules, executeModules || []);\n\n \t\t// run deferred modules when all chunks ready\n \t\treturn checkDeferredModules();\n \t};\n \tfunction checkDeferredModules() {\n \t\tvar result;\n \t\tfor(var i = 0; i < deferredModules.length; i++) {\n \t\t\tvar deferredModule = deferredModules[i];\n \t\t\tvar fulfilled = true;\n \t\t\tfor(var j = 1; j < deferredModule.length; j++) {\n \t\t\t\tvar depId = deferredModule[j];\n \t\t\t\tif(installedChunks[depId] !== 0) fulfilled = false;\n \t\t\t}\n \t\t\tif(fulfilled) {\n \t\t\t\tdeferredModules.splice(i--, 1);\n \t\t\t\tresult = __webpack_require__(__webpack_require__.s = deferredModule[0]);\n \t\t\t}\n \t\t}\n\n \t\treturn result;\n \t}\n\n \t// The module cache\n \tvar installedModules = {};\n\n \t// object to store loaded and loading chunks\n \t// undefined = chunk not loaded, null = chunk preloaded/prefetched\n \t// Promise = chunk loading, 0 = chunk loaded\n \tvar installedChunks = {\n \t\t1: 0\n \t};\n\n \tvar deferredModules = [];\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n \tvar jsonpArray = window[\"wpackioprestoPlayeranalyticsJsonp\"] = window[\"wpackioprestoPlayeranalyticsJsonp\"] || [];\n \tvar oldJsonpFunction = jsonpArray.push.bind(jsonpArray);\n \tjsonpArray.push = webpackJsonpCallback;\n \tjsonpArray = jsonpArray.slice();\n \tfor(var i = 0; i < jsonpArray.length; i++) webpackJsonpCallback(jsonpArray[i]);\n \tvar parentJsonpFunction = oldJsonpFunction;\n\n\n \t// run deferred modules from other chunks\n \tcheckDeferredModules();\n"],"sourceRoot":""}
 
dist/analytics/vendors--presto-player--admin-44989e87.js DELETED
@@ -1,74 +0,0 @@
1
- /*!
2
- *
3
- * Presto Player
4
- *
5
- * @author Presto Made, Inc
6
- * @version 0.1.0
7
- * @link undefined
8
- * @license GPL
9
- *
10
- * Copyright (c) 2022 Presto Made, Inc
11
- *
12
- * This software is released under the GPL License
13
- * https://opensource.org/licenses/GPL
14
- *
15
- * Compiled with the help of https://wpack.io
16
- * A zero setup Webpack Bundler Script for WordPress
17
- */
18
- (window.wpackioprestoPlayeranalyticsJsonp=window.wpackioprestoPlayeranalyticsJsonp||[]).push([[2],[function(t,e,i){"use strict";i.d(e,"a",(function(){return Y})),i.d(e,"b",(function(){return R}));var a=i(6),s=i(13);var n=i(2);var r=function(){function t(t){this.isSpeedy=void 0===t.speedy||t.speedy,this.tags=[],this.ctr=0,this.nonce=t.nonce,this.key=t.key,this.container=t.container,this.before=null}var e=t.prototype;return e.insert=function(t){if(this.ctr%(this.isSpeedy?65e3:1)==0){var e,i=function(t){var e=document.createElement("style");return e.setAttribute("data-emotion",t.key),void 0!==t.nonce&&e.setAttribute("nonce",t.nonce),e.appendChild(document.createTextNode("")),e}(this);e=0===this.tags.length?this.before:this.tags[this.tags.length-1].nextSibling,this.container.insertBefore(i,e),this.tags.push(i)}var a=this.tags[this.tags.length-1];if(this.isSpeedy){var s=function(t){if(t.sheet)return t.sheet;for(var e=0;e<document.styleSheets.length;e++)if(document.styleSheets[e].ownerNode===t)return document.styleSheets[e]}(a);try{var n=105===t.charCodeAt(1)&&64===t.charCodeAt(0);s.insertRule(t,n?0:s.cssRules.length)}catch(t){0}}else a.appendChild(document.createTextNode(t));this.ctr++},e.flush=function(){this.tags.forEach((function(t){return t.parentNode.removeChild(t)})),this.tags=[],this.ctr=0},t}();var o=function(t){function e(t,e,a){var s=e.trim().split(g);e=s;var n=s.length,r=t.length;switch(r){case 0:case 1:var o=0;for(t=0===r?"":t[0]+" ";o<n;++o)e[o]=i(t,e[o],a).trim();break;default:var l=o=0;for(e=[];o<n;++o)for(var c=0;c<r;++c)e[l++]=i(t[c]+" ",s[o],a).trim()}return e}function i(t,e,i){var a=e.charCodeAt(0);switch(33>a&&(a=(e=e.trim()).charCodeAt(0)),a){case 38:return e.replace(x,"$1"+t.trim());case 58:return t.trim()+e.replace(x,"$1"+t.trim());default:if(0<1*i&&0<e.indexOf("\f"))return e.replace(x,(58===t.charCodeAt(0)?"":"$1")+t.trim())}return t+e}function s(t,e,i,a){var r=t+";",o=2*e+3*i+4*a;if(944===o){t=r.indexOf(":",9)+1;var l=r.substring(t,r.length-1).trim();return l=r.substring(0,t).trim()+l+";",1===E||2===E&&n(l,1)?"-webkit-"+l+l:l}if(0===E||2===E&&!n(r,1))return r;switch(o){case 1015:return 97===r.charCodeAt(10)?"-webkit-"+r+r:r;case 951:return 116===r.charCodeAt(3)?"-webkit-"+r+r:r;case 963:return 110===r.charCodeAt(5)?"-webkit-"+r+r:r;case 1009:if(100!==r.charCodeAt(4))break;case 969:case 942:return"-webkit-"+r+r;case 978:return"-webkit-"+r+"-moz-"+r+r;case 1019:case 983:return"-webkit-"+r+"-moz-"+r+"-ms-"+r+r;case 883:if(45===r.charCodeAt(8))return"-webkit-"+r+r;if(0<r.indexOf("image-set(",11))return r.replace(L,"$1-webkit-$2")+r;break;case 932:if(45===r.charCodeAt(4))switch(r.charCodeAt(5)){case 103:return"-webkit-box-"+r.replace("-grow","")+"-webkit-"+r+"-ms-"+r.replace("grow","positive")+r;case 115:return"-webkit-"+r+"-ms-"+r.replace("shrink","negative")+r;case 98:return"-webkit-"+r+"-ms-"+r.replace("basis","preferred-size")+r}return"-webkit-"+r+"-ms-"+r+r;case 964:return"-webkit-"+r+"-ms-flex-"+r+r;case 1023:if(99!==r.charCodeAt(8))break;return"-webkit-box-pack"+(l=r.substring(r.indexOf(":",15)).replace("flex-","").replace("space-between","justify"))+"-webkit-"+r+"-ms-flex-pack"+l+r;case 1005:return p.test(r)?r.replace(u,":-webkit-")+r.replace(u,":-moz-")+r:r;case 1e3:switch(e=(l=r.substring(13).trim()).indexOf("-")+1,l.charCodeAt(0)+l.charCodeAt(e)){case 226:l=r.replace(y,"tb");break;case 232:l=r.replace(y,"tb-rl");break;case 220:l=r.replace(y,"lr");break;default:return r}return"-webkit-"+r+"-ms-"+l+r;case 1017:if(-1===r.indexOf("sticky",9))break;case 975:switch(e=(r=t).length-10,o=(l=(33===r.charCodeAt(e)?r.substring(0,e):r).substring(t.indexOf(":",7)+1).trim()).charCodeAt(0)+(0|l.charCodeAt(7))){case 203:if(111>l.charCodeAt(8))break;case 115:r=r.replace(l,"-webkit-"+l)+";"+r;break;case 207:case 102:r=r.replace(l,"-webkit-"+(102<o?"inline-":"")+"box")+";"+r.replace(l,"-webkit-"+l)+";"+r.replace(l,"-ms-"+l+"box")+";"+r}return r+";";case 938:if(45===r.charCodeAt(5))switch(r.charCodeAt(6)){case 105:return l=r.replace("-items",""),"-webkit-"+r+"-webkit-box-"+l+"-ms-flex-"+l+r;case 115:return"-webkit-"+r+"-ms-flex-item-"+r.replace(A,"")+r;default:return"-webkit-"+r+"-ms-flex-line-pack"+r.replace("align-content","").replace(A,"")+r}break;case 973:case 989:if(45!==r.charCodeAt(3)||122===r.charCodeAt(4))break;case 931:case 953:if(!0===C.test(t))return 115===(l=t.substring(t.indexOf(":")+1)).charCodeAt(0)?s(t.replace("stretch","fill-available"),e,i,a).replace(":fill-available",":stretch"):r.replace(l,"-webkit-"+l)+r.replace(l,"-moz-"+l.replace("fill-",""))+r;break;case 962:if(r="-webkit-"+r+(102===r.charCodeAt(5)?"-ms-"+r:"")+r,211===i+a&&105===r.charCodeAt(13)&&0<r.indexOf("transform",10))return r.substring(0,r.indexOf(";",27)+1).replace(f,"$1-webkit-$2")+r}return r}function n(t,e){var i=t.indexOf(1===e?":":"{"),a=t.substring(0,3!==e?i:10);return i=t.substring(i+1,t.length-1),z(2!==e?a:a.replace(S,"$1"),i,e)}function r(t,e){var i=s(e,e.charCodeAt(0),e.charCodeAt(1),e.charCodeAt(2));return i!==e+";"?i.replace(k," or ($1)").substring(4):"("+e+")"}function o(t,e,i,a,s,n,r,o,l,h){for(var d,u=0,p=e;u<O;++u)switch(d=I[u].call(c,t,p,i,a,s,n,r,o,l,h)){case void 0:case!1:case!0:case null:break;default:p=d}if(p!==e)return p}function l(t){return void 0!==(t=t.prefix)&&(z=null,t?"function"!=typeof t?E=1:(E=2,z=t):E=0),l}function c(t,i){var a=t;if(33>a.charCodeAt(0)&&(a=a.trim()),a=[a],0<O){var l=o(-1,i,a,a,T,P,0,0,0,0);void 0!==l&&"string"==typeof l&&(i=l)}var c=function t(i,a,l,c,u){for(var p,f,g,x,y,k=0,A=0,S=0,C=0,L=0,I=0,z=g=p=0,R=0,X=0,F=0,N=0,H=l.length,_=H-1,W="",B="",j="",V="";R<H;){if(f=l.charCodeAt(R),R===_&&0!==A+C+S+k&&(0!==A&&(f=47===A?10:47),C=S=k=0,H++,_++),0===A+C+S+k){if(R===_&&(0<X&&(W=W.replace(d,"")),0<W.trim().length)){switch(f){case 32:case 9:case 59:case 13:case 10:break;default:W+=l.charAt(R)}f=59}switch(f){case 123:for(p=(W=W.trim()).charCodeAt(0),g=1,N=++R;R<H;){switch(f=l.charCodeAt(R)){case 123:g++;break;case 125:g--;break;case 47:switch(f=l.charCodeAt(R+1)){case 42:case 47:t:{for(z=R+1;z<_;++z)switch(l.charCodeAt(z)){case 47:if(42===f&&42===l.charCodeAt(z-1)&&R+2!==z){R=z+1;break t}break;case 10:if(47===f){R=z+1;break t}}R=z}}break;case 91:f++;case 40:f++;case 34:case 39:for(;R++<_&&l.charCodeAt(R)!==f;);}if(0===g)break;R++}switch(g=l.substring(N,R),0===p&&(p=(W=W.replace(h,"").trim()).charCodeAt(0)),p){case 64:switch(0<X&&(W=W.replace(d,"")),f=W.charCodeAt(1)){case 100:case 109:case 115:case 45:X=a;break;default:X=D}if(N=(g=t(a,X,g,f,u+1)).length,0<O&&(y=o(3,g,X=e(D,W,F),a,T,P,N,f,u,c),W=X.join(""),void 0!==y&&0===(N=(g=y.trim()).length)&&(f=0,g="")),0<N)switch(f){case 115:W=W.replace(w,r);case 100:case 109:case 45:g=W+"{"+g+"}";break;case 107:g=(W=W.replace(m,"$1 $2"))+"{"+g+"}",g=1===E||2===E&&n("@"+g,3)?"@-webkit-"+g+"@"+g:"@"+g;break;default:g=W+g,112===c&&(B+=g,g="")}else g="";break;default:g=t(a,e(a,W,F),g,c,u+1)}j+=g,g=F=X=z=p=0,W="",f=l.charCodeAt(++R);break;case 125:case 59:if(1<(N=(W=(0<X?W.replace(d,""):W).trim()).length))switch(0===z&&(p=W.charCodeAt(0),45===p||96<p&&123>p)&&(N=(W=W.replace(" ",":")).length),0<O&&void 0!==(y=o(1,W,a,i,T,P,B.length,c,u,c))&&0===(N=(W=y.trim()).length)&&(W="\0\0"),p=W.charCodeAt(0),f=W.charCodeAt(1),p){case 0:break;case 64:if(105===f||99===f){V+=W+l.charAt(R);break}default:58!==W.charCodeAt(N-1)&&(B+=s(W,p,f,W.charCodeAt(2)))}F=X=z=p=0,W="",f=l.charCodeAt(++R)}}switch(f){case 13:case 10:47===A?A=0:0===1+p&&107!==c&&0<W.length&&(X=1,W+="\0"),0<O*Y&&o(0,W,a,i,T,P,B.length,c,u,c),P=1,T++;break;case 59:case 125:if(0===A+C+S+k){P++;break}default:switch(P++,x=l.charAt(R),f){case 9:case 32:if(0===C+k+A)switch(L){case 44:case 58:case 9:case 32:x="";break;default:32!==f&&(x=" ")}break;case 0:x="\\0";break;case 12:x="\\f";break;case 11:x="\\v";break;case 38:0===C+A+k&&(X=F=1,x="\f"+x);break;case 108:if(0===C+A+k+M&&0<z)switch(R-z){case 2:112===L&&58===l.charCodeAt(R-3)&&(M=L);case 8:111===I&&(M=I)}break;case 58:0===C+A+k&&(z=R);break;case 44:0===A+S+C+k&&(X=1,x+="\r");break;case 34:case 39:0===A&&(C=C===f?0:0===C?f:C);break;case 91:0===C+A+S&&k++;break;case 93:0===C+A+S&&k--;break;case 41:0===C+A+k&&S--;break;case 40:if(0===C+A+k){if(0===p)switch(2*L+3*I){case 533:break;default:p=1}S++}break;case 64:0===A+S+C+k+z+g&&(g=1);break;case 42:case 47:if(!(0<C+k+S))switch(A){case 0:switch(2*f+3*l.charCodeAt(R+1)){case 235:A=47;break;case 220:N=R,A=42}break;case 42:47===f&&42===L&&N+2!==R&&(33===l.charCodeAt(N+2)&&(B+=l.substring(N,R+1)),x="",A=0)}}0===A&&(W+=x)}I=L,L=f,R++}if(0<(N=B.length)){if(X=a,0<O&&(void 0!==(y=o(2,B,X,i,T,P,N,c,u,c))&&0===(B=y).length))return V+B+j;if(B=X.join(",")+"{"+B+"}",0!=E*M){switch(2!==E||n(B,2)||(M=0),M){case 111:B=B.replace(v,":-moz-$1")+B;break;case 112:B=B.replace(b,"::-webkit-input-$1")+B.replace(b,"::-moz-$1")+B.replace(b,":-ms-input-$1")+B}M=0}}return V+B+j}(D,a,i,0,0);return 0<O&&(void 0!==(l=o(-2,c,a,a,T,P,c.length,0,0,0))&&(c=l)),"",M=0,P=T=1,c}var h=/^\0+/g,d=/[\0\r\f]/g,u=/: */g,p=/zoo|gra/,f=/([,: ])(transform)/g,g=/,\r+?/g,x=/([\t\r\n ])*\f?&/g,m=/@(k\w+)\s*(\S*)\s*/,b=/::(place)/g,v=/:(read-only)/g,y=/[svh]\w+-[tblr]{2}/,w=/\(\s*(.*)\s*\)/g,k=/([\s\S]*?);/g,A=/-self|flex-/g,S=/[^]*?(:[rp][el]a[\w-]+)[^]*/,C=/stretch|:\s*\w+\-(?:conte|avail)/,L=/([^-])(image-set\()/,P=1,T=1,M=0,E=1,D=[],I=[],O=0,z=null,Y=0;return c.use=function t(e){switch(e){case void 0:case null:O=I.length=0;break;default:if("function"==typeof e)I[O++]=e;else if("object"===Object(a.a)(e))for(var i=0,s=e.length;i<s;++i)t(e[i]);else Y=0|!!e}return t},c.set=l,void 0!==t&&l(t),c};function l(t){t&&c.current.insert(t+"}")}var c={current:null},h=function(t,e,i,a,s,n,r,o,h,d){switch(t){case 1:switch(e.charCodeAt(0)){case 64:return c.current.insert(e+";"),"";case 108:if(98===e.charCodeAt(2))return""}break;case 2:if(0===o)return e+"/*|*/";break;case 3:switch(o){case 102:case 112:return c.current.insert(i[0]+e),"";default:return e+(0===d?"/*|*/":"")}case-2:e.split("/*|*/}").forEach(l)}},d=function(t){void 0===t&&(t={});var e,i=t.key||"css";void 0!==t.prefix&&(e={prefix:t.prefix});var a=new o(e);var s,n={};s=t.container||document.head;var l,d=document.querySelectorAll("style[data-emotion-"+i+"]");Array.prototype.forEach.call(d,(function(t){t.getAttribute("data-emotion-"+i).split(" ").forEach((function(t){n[t]=!0})),t.parentNode!==s&&s.appendChild(t)})),a.use(t.stylisPlugins)(h),l=function(t,e,i,s){var n=e.name;c.current=i,a(t,e.styles),s&&(u.inserted[n]=!0)};var u={key:i,sheet:new r({key:i,container:s,nonce:t.nonce,speedy:t.speedy}),nonce:t.nonce,inserted:n,registered:{},insert:l};return u};i(45);function u(t,e,i){var a="";return i.split(" ").forEach((function(i){void 0!==t[i]?e.push(t[i]):a+=i+" "})),a}var p=function(t,e,i){var a=t.key+"-"+e.name;if(!1===i&&void 0===t.registered[a]&&(t.registered[a]=e.styles),void 0===t.inserted[e.name]){var s=e;do{t.insert("."+a,s,t.sheet,!0);s=s.next}while(void 0!==s)}};var f=function(t){for(var e,i=0,a=0,s=t.length;s>=4;++a,s-=4)e=1540483477*(65535&(e=255&t.charCodeAt(a)|(255&t.charCodeAt(++a))<<8|(255&t.charCodeAt(++a))<<16|(255&t.charCodeAt(++a))<<24))+(59797*(e>>>16)<<16),i=1540483477*(65535&(e^=e>>>24))+(59797*(e>>>16)<<16)^1540483477*(65535&i)+(59797*(i>>>16)<<16);switch(s){case 3:i^=(255&t.charCodeAt(a+2))<<16;case 2:i^=(255&t.charCodeAt(a+1))<<8;case 1:i=1540483477*(65535&(i^=255&t.charCodeAt(a)))+(59797*(i>>>16)<<16)}return(((i=1540483477*(65535&(i^=i>>>13))+(59797*(i>>>16)<<16))^i>>>15)>>>0).toString(36)},g={animationIterationCount:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1};var x=/[A-Z]|^ms/g,m=/_EMO_([^_]+?)_([^]*?)_EMO_/g,b=function(t){return 45===t.charCodeAt(1)},v=function(t){return null!=t&&"boolean"!=typeof t},y=function(t){var e={};return function(i){return void 0===e[i]&&(e[i]=t(i)),e[i]}}((function(t){return b(t)?t:t.replace(x,"-$&").toLowerCase()})),w=function(t,e){switch(t){case"animation":case"animationName":if("string"==typeof e)return e.replace(m,(function(t,e,i){return A={name:e,styles:i,next:A},e}))}return 1===g[t]||b(t)||"number"!=typeof e||0===e?e:e+"px"};function k(t,e,i,s){if(null==i)return"";if(void 0!==i.__emotion_styles)return i;switch(Object(a.a)(i)){case"boolean":return"";case"object":if(1===i.anim)return A={name:i.name,styles:i.styles,next:A},i.name;if(void 0!==i.styles){var n=i.next;if(void 0!==n)for(;void 0!==n;)A={name:n.name,styles:n.styles,next:A},n=n.next;return i.styles+";"}return function(t,e,i){var s="";if(Array.isArray(i))for(var n=0;n<i.length;n++)s+=k(t,e,i[n],!1);else for(var r in i){var o=i[r];if("object"!==Object(a.a)(o))null!=e&&void 0!==e[o]?s+=r+"{"+e[o]+"}":v(o)&&(s+=y(r)+":"+w(r,o)+";");else if(!Array.isArray(o)||"string"!=typeof o[0]||null!=e&&void 0!==e[o[0]]){var l=k(t,e,o,!1);switch(r){case"animation":case"animationName":s+=y(r)+":"+l+";";break;default:s+=r+"{"+l+"}"}}else for(var c=0;c<o.length;c++)v(o[c])&&(s+=y(r)+":"+w(r,o[c])+";")}return s}(t,e,i);case"function":if(void 0!==t){var r=A,o=i(t);return A=r,k(t,e,o,s)}break;case"string":}if(null==e)return i;var l=e[i];return void 0===l||s?i:l}var A,S=/label:\s*([^\s;\n{]+)\s*;/g;var C=function(t,e,i){if(1===t.length&&"object"===Object(a.a)(t[0])&&null!==t[0]&&void 0!==t[0].styles)return t[0];var s=!0,n="";A=void 0;var r=t[0];null==r||void 0===r.raw?(s=!1,n+=k(i,e,r,!1)):n+=r[0];for(var o=1;o<t.length;o++)n+=k(i,e,t[o],46===n.charCodeAt(n.length-1)),s&&(n+=r[o]);S.lastIndex=0;for(var l,c="";null!==(l=S.exec(n));)c+="-"+l[1];return{name:f(n)+c,styles:n,next:A}},L=Object.prototype.hasOwnProperty,P=Object(n.createContext)("undefined"!=typeof HTMLElement?d():null),T=Object(n.createContext)({}),M=(P.Provider,function(t){var e=function(e,i){return Object(n.createElement)(P.Consumer,null,(function(a){return t(e,a,i)}))};return Object(n.forwardRef)(e)}),E="__EMOTION_TYPE_PLEASE_DO_NOT_USE__",D=function(t,e){var i={};for(var a in e)L.call(e,a)&&(i[a]=e[a]);return i[E]=t,i},I=function(){return null},O=function(t,e,i,a){var s=null===i?e.css:e.css(i);"string"==typeof s&&void 0!==t.registered[s]&&(s=t.registered[s]);var r=e[E],o=[s],l="";"string"==typeof e.className?l=u(t.registered,o,e.className):null!=e.className&&(l=e.className+" ");var c=C(o);p(t,c,"string"==typeof r);l+=t.key+"-"+c.name;var h={};for(var d in e)L.call(e,d)&&"css"!==d&&d!==E&&(h[d]=e[d]);h.ref=a,h.className=l;var f=Object(n.createElement)(r,h),g=Object(n.createElement)(I,null);return Object(n.createElement)(n.Fragment,null,g,f)},z=M((function(t,e,i){return"function"==typeof t.css?Object(n.createElement)(T.Consumer,null,(function(a){return O(e,t,a,i)})):O(e,t,null,i)}));var Y=function(){for(var t=arguments.length,e=new Array(t),i=0;i<t;i++)e[i]=arguments[i];return C(e)},R=function(t,e){var i=arguments;if(null==e||!L.call(e,"css"))return n.createElement.apply(void 0,i);var a=i.length,s=new Array(a);s[0]=z,s[1]=D(t,e);for(var r=2;r<a;r++)s[r]=i[r];return n.createElement.apply(null,s)},X=(n.Component,function t(e){for(var i=e.length,s=0,n="";s<i;s++){var r=e[s];if(null!=r){var o=void 0;switch(Object(a.a)(r)){case"boolean":break;case"object":if(Array.isArray(r))o=t(r);else for(var l in o="",r)r[l]&&l&&(o&&(o+=" "),o+=l);break;default:o=r}o&&(n&&(n+=" "),n+=o)}}return n});function F(t,e,i){var a=[],s=u(t,a,i);return a.length<2?i:s+e(a)}var N=function(){return null};M((function(t,e){return Object(n.createElement)(T.Consumer,null,(function(i){var a=function(){for(var t=arguments.length,i=new Array(t),a=0;a<t;a++)i[a]=arguments[a];var s=C(i,e.registered);return p(e,s,!1),e.key+"-"+s.name},s={css:a,cx:function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];return F(e.registered,a,X(i))},theme:i},r=t.children(s);var o=Object(n.createElement)(N,null);return Object(n.createElement)(n.Fragment,null,o,r)}))}))},function(t,e,i){"use strict";function a(t,e){(null==e||e>t.length)&&(e=t.length);for(var i=0,a=new Array(e);i<e;i++)a[i]=t[i];return a}function s(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var i=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=i){var a,s,n=[],r=!0,o=!1;try{for(i=i.call(t);!(r=(a=i.next()).done)&&(n.push(a.value),!e||n.length!==e);r=!0);}catch(t){o=!0,s=t}finally{try{r||null==i.return||i.return()}finally{if(o)throw s}}return n}}(t,e)||function(t,e){if(t){if("string"==typeof t)return a(t,e);var i=Object.prototype.toString.call(t).slice(8,-1);return"Object"===i&&t.constructor&&(i=t.constructor.name),"Map"===i||"Set"===i?Array.from(t):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?a(t,e):void 0}}(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}i.d(e,"a",(function(){return s}))},function(t,e,i){"use strict";t.exports=i(39)},function(t,e,i){t.exports=i(37)},function(t,e,i){"use strict";function a(t,e,i){return e in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}i.d(e,"a",(function(){return a}))},function(t,e,i){"use strict";function a(t,e,i,a,s,n,r){try{var o=t[n](r),l=o.value}catch(t){return void i(t)}o.done?e(l):Promise.resolve(l).then(a,s)}function s(t){return function(){var e=this,i=arguments;return new Promise((function(s,n){var r=t.apply(e,i);function o(t){a(r,s,n,o,l,"next",t)}function l(t){a(r,s,n,o,l,"throw",t)}o(void 0)}))}}i.d(e,"a",(function(){return s}))},function(t,e,i){"use strict";function a(t){return(a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}i.d(e,"a",(function(){return a}))},function(t,e){function i(e){return t.exports=i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},t.exports.__esModule=!0,t.exports.default=t.exports,i(e)}t.exports=i,t.exports.__esModule=!0,t.exports.default=t.exports},function(t,e,i){"use strict";i.d(e,"a",(function(){return s}));i(6);function a(t,e){void 0===e&&(e={});for(var i=function(t){for(var e=[],i=0;i<t.length;){var a=t[i];if("*"!==a&&"+"!==a&&"?"!==a)if("\\"!==a)if("{"!==a)if("}"!==a)if(":"!==a)if("("!==a)e.push({type:"CHAR",index:i,value:t[i++]});else{var s=1,n="";if("?"===t[o=i+1])throw new TypeError('Pattern cannot start with "?" at '+o);for(;o<t.length;)if("\\"!==t[o]){if(")"===t[o]){if(0===--s){o++;break}}else if("("===t[o]&&(s++,"?"!==t[o+1]))throw new TypeError("Capturing groups are not allowed at "+o);n+=t[o++]}else n+=t[o++]+t[o++];if(s)throw new TypeError("Unbalanced pattern at "+i);if(!n)throw new TypeError("Missing pattern at "+i);e.push({type:"PATTERN",index:i,value:n}),i=o}else{for(var r="",o=i+1;o<t.length;){var l=t.charCodeAt(o);if(!(l>=48&&l<=57||l>=65&&l<=90||l>=97&&l<=122||95===l))break;r+=t[o++]}if(!r)throw new TypeError("Missing parameter name at "+i);e.push({type:"NAME",index:i,value:r}),i=o}else e.push({type:"CLOSE",index:i,value:t[i++]});else e.push({type:"OPEN",index:i,value:t[i++]});else e.push({type:"ESCAPED_CHAR",index:i++,value:t[i++]});else e.push({type:"MODIFIER",index:i,value:t[i++]})}return e.push({type:"END",index:i,value:""}),e}(t),a=e.prefixes,s=void 0===a?"./":a,r="[^"+n(e.delimiter||"/#?")+"]+?",o=[],l=0,c=0,h="",d=function(t){if(c<i.length&&i[c].type===t)return i[c++].value},u=function(t){var e=d(t);if(void 0!==e)return e;var a=i[c],s=a.type,n=a.index;throw new TypeError("Unexpected "+s+" at "+n+", expected "+t)},p=function(){for(var t,e="";t=d("CHAR")||d("ESCAPED_CHAR");)e+=t;return e};c<i.length;){var f=d("CHAR"),g=d("NAME"),x=d("PATTERN");if(g||x){var m=f||"";-1===s.indexOf(m)&&(h+=m,m=""),h&&(o.push(h),h=""),o.push({name:g||l++,prefix:m,suffix:"",pattern:x||r,modifier:d("MODIFIER")||""})}else{var b=f||d("ESCAPED_CHAR");if(b)h+=b;else if(h&&(o.push(h),h=""),d("OPEN")){m=p();var v=d("NAME")||"",y=d("PATTERN")||"",w=p();u("CLOSE"),o.push({name:v||(y?l++:""),pattern:v&&!y?r:y,prefix:m,suffix:w,modifier:d("MODIFIER")||""})}else u("END")}}return o}function s(t,e){var i=[];return function(t,e,i){void 0===i&&(i={});var a=i.decode,s=void 0===a?function(t){return t}:a;return function(i){var a=t.exec(i);if(!a)return!1;for(var n=a[0],r=a.index,o=Object.create(null),l=function(t){if(void 0===a[t])return"continue";var i=e[t-1];"*"===i.modifier||"+"===i.modifier?o[i.name]=a[t].split(i.prefix+i.suffix).map((function(t){return s(t,i)})):o[i.name]=s(a[t],i)},c=1;c<a.length;c++)l(c);return{path:n,index:r,params:o}}}(l(t,i,e),i,e)}function n(t){return t.replace(/([.+*?=^!:${}()[\]|/\\])/g,"\\$1")}function r(t){return t&&t.sensitive?"":"i"}function o(t,e,i){return function(t,e,i){void 0===i&&(i={});for(var a=i.strict,s=void 0!==a&&a,o=i.start,l=void 0===o||o,c=i.end,h=void 0===c||c,d=i.encode,u=void 0===d?function(t){return t}:d,p="["+n(i.endsWith||"")+"]|$",f="["+n(i.delimiter||"/#?")+"]",g=l?"^":"",x=0,m=t;x<m.length;x++){var b=m[x];if("string"==typeof b)g+=n(u(b));else{var v=n(u(b.prefix)),y=n(u(b.suffix));if(b.pattern)if(e&&e.push(b),v||y)if("+"===b.modifier||"*"===b.modifier){var w="*"===b.modifier?"?":"";g+="(?:"+v+"((?:"+b.pattern+")(?:"+y+v+"(?:"+b.pattern+"))*)"+y+")"+w}else g+="(?:"+v+"("+b.pattern+")"+y+")"+b.modifier;else g+="("+b.pattern+")"+b.modifier;else g+="(?:"+v+y+")"+b.modifier}}if(h)s||(g+=f+"?"),g+=i.endsWith?"(?="+p+")":"$";else{var k=t[t.length-1],A="string"==typeof k?f.indexOf(k[k.length-1])>-1:void 0===k;s||(g+="(?:"+f+"(?="+p+"))?"),A||(g+="(?="+f+"|"+p+")")}return new RegExp(g,r(i))}(a(t,i),e,i)}function l(t,e,i){return t instanceof RegExp?function(t,e){if(!e)return t;for(var i=/\((?:\?<(.*?)>)?(?!\?)/g,a=0,s=i.exec(t.source);s;)e.push({name:s[1]||a++,prefix:"",suffix:"",modifier:"",pattern:""}),s=i.exec(t.source);return t}(t,e):Array.isArray(t)?function(t,e,i){var a=t.map((function(t){return l(t,e,i).source}));return new RegExp("(?:"+a.join("|")+")",r(i))}(t,e,i):o(t,e,i)}},function(t,e,i){"use strict";var a=i(7);Object.defineProperty(e,"__esModule",{value:!0});var s="function"==typeof Symbol&&"symbol"==a(Symbol.iterator)?function(t){return a(t)}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":a(t)},n=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var i=arguments[e];for(var a in i)Object.prototype.hasOwnProperty.call(i,a)&&(t[a]=i[a])}return t},r=function(){function t(t,e){for(var i=0;i<e.length;i++){var a=e[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(t,a.key,a)}}return function(e,i,a){return i&&t(e.prototype,i),a&&t(e,a),e}}(),o=d(i(38)),l=i(2),c=d(l),h=d(i(41));function d(t){return t&&t.__esModule?t:{default:t}}window.ApexCharts=o.default;var u=function(){function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t);var i=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=a(e)&&"function"!=typeof e?t:e}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return c.default.createRef?i.chartRef=c.default.createRef():i.setRef=function(t){return i.chartRef=t},i.chart=null,i}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+a(e));t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(t,l.Component),r(t,[{key:"render",value:function(){var t=function(t,e){var i={};for(var a in t)0<=e.indexOf(a)||Object.prototype.hasOwnProperty.call(t,a)&&(i[a]=t[a]);return i}(this.props,[]);return c.default.createElement("div",n({ref:c.default.createRef?this.chartRef:this.setRef},t))}},{key:"componentDidMount",value:function(){var t=c.default.createRef?this.chartRef.current:this.chartRef;this.chart=new o.default(t,this.getConfig()),this.chart.render()}},{key:"getConfig",value:function(){var t=this.props,e=t.type,i=t.height,a=t.width,s=t.series,n=t.options,r={chart:{type:e,height:i,width:a},series:s};return this.extend(n,r)}},{key:"isObject",value:function(t){return t&&"object"===(void 0===t?"undefined":s(t))&&!Array.isArray(t)&&null!=t}},{key:"extend",value:function(t,e){var i=this;"function"!=typeof Object.assign&&(Object.assign=function(t){if(null==t)throw new TypeError("Cannot convert undefined or null to object");for(var e=Object(t),i=1;i<arguments.length;i++){var a=arguments[i];if(null!=a)for(var s in a)a.hasOwnProperty(s)&&(e[s]=a[s])}return e});var a=Object.assign({},t);return this.isObject(t)&&this.isObject(e)&&Object.keys(e).forEach((function(s){i.isObject(e[s])&&s in t?a[s]=i.extend(t[s],e[s]):Object.assign(a,function(t,e,i){return e in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}({},s,e[s]))})),a}},{key:"componentDidUpdate",value:function(t){if(!this.chart)return null;var e=this.props,i=e.options,a=e.series,s=e.height,n=e.width,r=JSON.stringify(t.options),o=JSON.stringify(t.series),l=JSON.stringify(i),c=JSON.stringify(a);r===l&&o===c&&s===t.height&&n===t.width||(o===c?this.chart.updateOptions(this.getConfig()):r===l&&s===t.height&&n===t.width?this.chart.updateSeries(a):this.chart.updateOptions(this.getConfig()))}},{key:"componentWillUnmount",value:function(){this.chart&&"function"==typeof this.chart.destroy&&this.chart.destroy()}}]),t}();(e.default=u).propTypes={type:h.default.string.isRequired,width:h.default.any,height:h.default.any,series:h.default.array.isRequired,options:h.default.object.isRequired},u.defaultProps={type:"line",width:"100%",height:"auto"}},function(t,e,i){"use strict";function a(t,e){return e||(e=t.slice(0)),Object.freeze(Object.defineProperties(t,{raw:{value:Object.freeze(e)}}))}i.d(e,"a",(function(){return a}))},function(t,e,i){"use strict";t.exports=i(47)},function(t,e,i){"use strict";function a(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}i.d(e,"a",(function(){return a}))},function(t,e,i){"use strict";function a(t,e){return(a=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}i.d(e,"a",(function(){return a}))},function(t,e,i){var a,s=i(7);
19
- /*!
20
- Copyright (c) 2018 Jed Watson.
21
- Licensed under the MIT License (MIT), see
22
- http://jedwatson.github.io/classnames
23
- */!function(){"use strict";var n={}.hasOwnProperty;function r(){for(var t=[],e=0;e<arguments.length;e++){var i=arguments[e];if(i){var a=s(i);if("string"===a||"number"===a)t.push(i);else if(Array.isArray(i)){if(i.length){var o=r.apply(null,i);o&&t.push(o)}}else if("object"===a)if(i.toString===Object.prototype.toString)for(var l in i)n.call(i,l)&&i[l]&&t.push(l);else t.push(i.toString())}}return t.join(" ")}t.exports?(r.default=r,t.exports=r):"object"===s(i(18))&&i(18)?void 0===(a=function(){return r}.apply(e,[]))||(t.exports=a):window.classNames=r}()},function(t,e){function i(e){return t.exports=i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},t.exports.__esModule=!0,t.exports.default=t.exports,i(e)}t.exports=i,t.exports.__esModule=!0,t.exports.default=t.exports},function(t,e,i){"use strict";function a(t){return(a=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}i.d(e,"a",(function(){return a}))},function(t,e,i){"use strict";function a(t){return(a=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}i.d(e,"a",(function(){return a}))},function(t,e){(function(e){t.exports=e}).call(this,{})},function(t,e){t.exports=function(t){return t.webpackPolyfill||(t.deprecate=function(){},t.paths=[],t.children||(t.children=[]),Object.defineProperty(t,"loaded",{enumerable:!0,get:function(){return t.l}}),Object.defineProperty(t,"id",{enumerable:!0,get:function(){return t.i}}),t.webpackPolyfill=1),t}},function(t,e,i){"use strict";function a(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}i.d(e,"a",(function(){return a}))},function(t,e,i){"use strict";function a(t,e){for(var i=0;i<e.length;i++){var a=e[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(t,a.key,a)}}function s(t,e,i){return e&&a(t.prototype,e),i&&a(t,i),Object.defineProperty(t,"prototype",{writable:!1}),t}i.d(e,"a",(function(){return s}))},function(t,e,i){"use strict";i.d(e,"a",(function(){return s}));var a=i(13);function s(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");Object.defineProperty(t,"prototype",{value:Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),writable:!1}),e&&Object(a.a)(t,e)}},function(t,e,i){"use strict";i.d(e,"a",(function(){return r}));var a=i(7),s=i.n(a),n=i(12);function r(t,e){if(e&&("object"===s()(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return Object(n.a)(t)}},,function(t,e,i){"use strict";var a=Object.prototype.hasOwnProperty;function s(t){try{return decodeURIComponent(t.replace(/\+/g," "))}catch(t){return null}}function n(t){try{return encodeURIComponent(t)}catch(t){return null}}e.stringify=function(t,e){e=e||"";var i,s,r=[];for(s in"string"!=typeof e&&(e="?"),t)if(a.call(t,s)){if((i=t[s])||null!=i&&!isNaN(i)||(i=""),s=n(s),i=n(i),null===s||null===i)continue;r.push(s+"="+i)}return r.length?e+r.join("&"):""},e.parse=function(t){for(var e,i=/([^=?#&]+)=?([^&]*)/g,a={};e=i.exec(t);){var n=s(e[1]),r=s(e[2]);null===n||null===r||n in a||(a[n]=r)}return a}},function(t,e,i){(function(t){var a,s,n,r,o=i(7);window,r=function(){return function(t){var e={};function i(a){if(e[a])return e[a].exports;var s=e[a]={i:a,l:!1,exports:{}};return t[a].call(s.exports,s,s.exports,i),s.l=!0,s.exports}return i.m=t,i.c=e,i.d=function(t,e,a){i.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:a})},i.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},i.t=function(t,e){if(1&e&&(t=i(t)),8&e)return t;if(4&e&&"object"==o(t)&&t&&t.__esModule)return t;var a=Object.create(null);if(i.r(a),Object.defineProperty(a,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var s in t)i.d(a,s,function(e){return t[e]}.bind(null,s));return a},i.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return i.d(e,"a",e),e},i.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},i.p="",i(i.s=4)}([function(t,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var a=function(){function t(e,i,a){void 0===e&&(e=null),void 0===i&&(i=null),void 0===a&&(a="en-US"),this.dateInstance="object"==o(i)&&null!==i?i.parse(e instanceof t?e.clone().toJSDate():e):"string"==typeof i?t.parseDateTime(e,i,a):e?t.parseDateTime(e):t.parseDateTime(new Date),this.lang=a}return t.parseDateTime=function(e,i,a){if(void 0===i&&(i="YYYY-MM-DD"),void 0===a&&(a="en-US"),!e)return new Date(NaN);if(e instanceof Date)return new Date(e);if(e instanceof t)return e.clone().toJSDate();if(/^-?\d{10,}$/.test(e))return t.getDateZeroTime(new Date(Number(e)));if("string"==typeof e){for(var s=[],n=null;null!=(n=t.regex.exec(i));)"\\"!==n[1]&&s.push(n);if(s.length){var r={year:null,month:null,shortMonth:null,longMonth:null,day:null,value:""};s[0].index>0&&(r.value+=".*?");for(var o=0,l=Object.entries(s);o<l.length;o++){var c=l[o],h=c[0],d=c[1],u=Number(h),p=t.formatPatterns(d[0],a),f=p.group,g=p.pattern;r[f]=u+1,r.value+=g,r.value+=".*?"}var x=new RegExp("^"+r.value+"$");if(x.test(e)){var m=x.exec(e),b=Number(m[r.year]),v=null;r.month?v=Number(m[r.month])-1:r.shortMonth?v=t.shortMonths(a).indexOf(m[r.shortMonth]):r.longMonth&&(v=t.longMonths(a).indexOf(m[r.longMonth]));var y=Number(m[r.day])||1;return new Date(b,v,y,0,0,0,0)}}}return t.getDateZeroTime(new Date(e))},t.convertArray=function(e,i){return e.map((function(e){return e instanceof Array?e.map((function(e){return new t(e,i)})):new t(e,i)}))},t.getDateZeroTime=function(t){return new Date(t.getFullYear(),t.getMonth(),t.getDate(),0,0,0,0)},t.shortMonths=function(e){return t.MONTH_JS.map((function(t){return new Date(2019,t).toLocaleString(e,{month:"short"})}))},t.longMonths=function(e){return t.MONTH_JS.map((function(t){return new Date(2019,t).toLocaleString(e,{month:"long"})}))},t.formatPatterns=function(e,i){switch(e){case"YY":case"YYYY":return{group:"year",pattern:"(\\d{"+e.length+"})"};case"M":return{group:"month",pattern:"(\\d{1,2})"};case"MM":return{group:"month",pattern:"(\\d{2})"};case"MMM":return{group:"shortMonth",pattern:"("+t.shortMonths(i).join("|")+")"};case"MMMM":return{group:"longMonth",pattern:"("+t.longMonths(i).join("|")+")"};case"D":return{group:"day",pattern:"(\\d{1,2})"};case"DD":return{group:"day",pattern:"(\\d{2})"}}},t.prototype.toJSDate=function(){return this.dateInstance},t.prototype.toLocaleString=function(t,e){return this.dateInstance.toLocaleString(t,e)},t.prototype.toDateString=function(){return this.dateInstance.toDateString()},t.prototype.getSeconds=function(){return this.dateInstance.getSeconds()},t.prototype.getDay=function(){return this.dateInstance.getDay()},t.prototype.getTime=function(){return this.dateInstance.getTime()},t.prototype.getDate=function(){return this.dateInstance.getDate()},t.prototype.getMonth=function(){return this.dateInstance.getMonth()},t.prototype.getFullYear=function(){return this.dateInstance.getFullYear()},t.prototype.setMonth=function(t){return this.dateInstance.setMonth(t)},t.prototype.setHours=function(t,e,i,a){void 0===t&&(t=0),void 0===e&&(e=0),void 0===i&&(i=0),void 0===a&&(a=0),this.dateInstance.setHours(t,e,i,a)},t.prototype.setSeconds=function(t){return this.dateInstance.setSeconds(t)},t.prototype.setDate=function(t){return this.dateInstance.setDate(t)},t.prototype.setFullYear=function(t){return this.dateInstance.setFullYear(t)},t.prototype.getWeek=function(t){var e=new Date(this.timestamp()),i=(this.getDay()+(7-t))%7;e.setDate(e.getDate()-i);var a=e.getTime();return e.setMonth(0,1),e.getDay()!==t&&e.setMonth(0,1+(4-e.getDay()+7)%7),1+Math.ceil((a-e.getTime())/6048e5)},t.prototype.clone=function(){return new t(this.toJSDate())},t.prototype.isBetween=function(t,e,i){switch(void 0===i&&(i="()"),i){default:case"()":return this.timestamp()>t.getTime()&&this.timestamp()<e.getTime();case"[)":return this.timestamp()>=t.getTime()&&this.timestamp()<e.getTime();case"(]":return this.timestamp()>t.getTime()&&this.timestamp()<=e.getTime();case"[]":return this.timestamp()>=t.getTime()&&this.timestamp()<=e.getTime()}},t.prototype.isBefore=function(t,e){switch(void 0===e&&(e="seconds"),e){case"second":case"seconds":return t.getTime()>this.getTime();case"day":case"days":return new Date(t.getFullYear(),t.getMonth(),t.getDate()).getTime()>new Date(this.getFullYear(),this.getMonth(),this.getDate()).getTime();case"month":case"months":return new Date(t.getFullYear(),t.getMonth(),1).getTime()>new Date(this.getFullYear(),this.getMonth(),1).getTime();case"year":case"years":return t.getFullYear()>this.getFullYear()}throw new Error("isBefore: Invalid unit!")},t.prototype.isSameOrBefore=function(t,e){switch(void 0===e&&(e="seconds"),e){case"second":case"seconds":return t.getTime()>=this.getTime();case"day":case"days":return new Date(t.getFullYear(),t.getMonth(),t.getDate()).getTime()>=new Date(this.getFullYear(),this.getMonth(),this.getDate()).getTime();case"month":case"months":return new Date(t.getFullYear(),t.getMonth(),1).getTime()>=new Date(this.getFullYear(),this.getMonth(),1).getTime()}throw new Error("isSameOrBefore: Invalid unit!")},t.prototype.isAfter=function(t,e){switch(void 0===e&&(e="seconds"),e){case"second":case"seconds":return this.getTime()>t.getTime();case"day":case"days":return new Date(this.getFullYear(),this.getMonth(),this.getDate()).getTime()>new Date(t.getFullYear(),t.getMonth(),t.getDate()).getTime();case"month":case"months":return new Date(this.getFullYear(),this.getMonth(),1).getTime()>new Date(t.getFullYear(),t.getMonth(),1).getTime();case"year":case"years":return this.getFullYear()>t.getFullYear()}throw new Error("isAfter: Invalid unit!")},t.prototype.isSameOrAfter=function(t,e){switch(void 0===e&&(e="seconds"),e){case"second":case"seconds":return this.getTime()>=t.getTime();case"day":case"days":return new Date(this.getFullYear(),this.getMonth(),this.getDate()).getTime()>=new Date(t.getFullYear(),t.getMonth(),t.getDate()).getTime();case"month":case"months":return new Date(this.getFullYear(),this.getMonth(),1).getTime()>=new Date(t.getFullYear(),t.getMonth(),1).getTime()}throw new Error("isSameOrAfter: Invalid unit!")},t.prototype.isSame=function(t,e){switch(void 0===e&&(e="seconds"),e){case"second":case"seconds":return this.getTime()===t.getTime();case"day":case"days":return new Date(this.getFullYear(),this.getMonth(),this.getDate()).getTime()===new Date(t.getFullYear(),t.getMonth(),t.getDate()).getTime();case"month":case"months":return new Date(this.getFullYear(),this.getMonth(),1).getTime()===new Date(t.getFullYear(),t.getMonth(),1).getTime()}throw new Error("isSame: Invalid unit!")},t.prototype.add=function(t,e){switch(void 0===e&&(e="seconds"),e){case"second":case"seconds":this.setSeconds(this.getSeconds()+t);break;case"day":case"days":this.setDate(this.getDate()+t);break;case"month":case"months":this.setMonth(this.getMonth()+t)}return this},t.prototype.subtract=function(t,e){switch(void 0===e&&(e="seconds"),e){case"second":case"seconds":this.setSeconds(this.getSeconds()-t);break;case"day":case"days":this.setDate(this.getDate()-t);break;case"month":case"months":this.setMonth(this.getMonth()-t)}return this},t.prototype.diff=function(t,e){switch(void 0===e&&(e="seconds"),e){default:case"second":case"seconds":return this.getTime()-t.getTime();case"day":case"days":return Math.round((this.timestamp()-t.getTime())/864e5);case"month":case"months":}},t.prototype.format=function(e,i){if(void 0===i&&(i="en-US"),"object"==o(e))return e.output(this.clone().toJSDate());for(var a="",s=[],n=null;null!=(n=t.regex.exec(e));)"\\"!==n[1]&&s.push(n);if(s.length){s[0].index>0&&(a+=e.substring(0,s[0].index));for(var r=0,l=Object.entries(s);r<l.length;r++){var c=l[r],h=c[0],d=c[1],u=Number(h);a+=this.formatTokens(d[0],i),s[u+1]&&(a+=e.substring(d.index+d[0].length,s[u+1].index)),u===s.length-1&&(a+=e.substring(d.index+d[0].length))}}return a.replace(/\\/g,"")},t.prototype.timestamp=function(){return new Date(this.getFullYear(),this.getMonth(),this.getDate(),0,0,0,0).getTime()},t.prototype.formatTokens=function(e,i){switch(e){case"YY":return String(this.getFullYear()).slice(-2);case"YYYY":return String(this.getFullYear());case"M":return String(this.getMonth()+1);case"MM":return("0"+(this.getMonth()+1)).slice(-2);case"MMM":return t.shortMonths(i)[this.getMonth()];case"MMMM":return t.longMonths(i)[this.getMonth()];case"D":return String(this.getDate());case"DD":return("0"+this.getDate()).slice(-2);default:return""}},t.regex=/(\\)?(Y{2,4}|M{1,4}|D{1,2}|d{1,4})/g,t.MONTH_JS=[0,1,2,3,4,5,6,7,8,9,10,11],t}();e.DateTime=a},function(t,e,i){"use strict";var a,s=this&&this.__extends||(a=function(t,e){return(a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var i in e)e.hasOwnProperty(i)&&(t[i]=e[i])})(t,e)},function(t,e){function i(){this.constructor=t}a(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}),n=this&&this.__spreadArrays||function(){for(var t=0,e=0,i=arguments.length;e<i;e++)t+=arguments[e].length;var a=Array(t),s=0;for(e=0;e<i;e++)for(var n=arguments[e],r=0,o=n.length;r<o;r++,s++)a[s]=n[r];return a};Object.defineProperty(e,"__esModule",{value:!0});var r=i(5),o=i(0),l=i(3),c=i(2),h=function(t){function e(e){var i=t.call(this,e)||this;return i.preventClick=!1,i.bindEvents(),i}return s(e,t),e.prototype.scrollToDate=function(t){if(this.options.scrollToDate){var e=this.options.startDate instanceof o.DateTime?this.options.startDate.clone():null,i=this.options.endDate instanceof o.DateTime?this.options.endDate.clone():null;!this.options.startDate||t&&t!==this.options.element?t&&this.options.endDate&&t===this.options.elementEnd&&(i.setDate(1),this.options.numberOfMonths>1&&i.isAfter(e)&&i.setMonth(i.getMonth()-(this.options.numberOfMonths-1)),this.calendars[0]=i.clone()):(e.setDate(1),this.calendars[0]=e.clone())}},e.prototype.bindEvents=function(){document.addEventListener("click",this.onClick.bind(this),!0),this.ui=document.createElement("div"),this.ui.className=l.litepicker,this.ui.style.display="none",this.ui.addEventListener("mouseenter",this.onMouseEnter.bind(this),!0),this.ui.addEventListener("mouseleave",this.onMouseLeave.bind(this),!1),this.options.autoRefresh?(this.options.element instanceof HTMLElement&&this.options.element.addEventListener("keyup",this.onInput.bind(this),!0),this.options.elementEnd instanceof HTMLElement&&this.options.elementEnd.addEventListener("keyup",this.onInput.bind(this),!0)):(this.options.element instanceof HTMLElement&&this.options.element.addEventListener("change",this.onInput.bind(this),!0),this.options.elementEnd instanceof HTMLElement&&this.options.elementEnd.addEventListener("change",this.onInput.bind(this),!0)),this.options.parentEl?this.options.parentEl instanceof HTMLElement?this.options.parentEl.appendChild(this.ui):document.querySelector(this.options.parentEl).appendChild(this.ui):this.options.inlineMode?this.options.element instanceof HTMLInputElement?this.options.element.parentNode.appendChild(this.ui):this.options.element.appendChild(this.ui):document.body.appendChild(this.ui),this.updateInput(),this.init(),"function"==typeof this.options.setup&&this.options.setup.call(this,this),this.render(),this.options.inlineMode&&this.show()},e.prototype.updateInput=function(){if(this.options.element instanceof HTMLInputElement){var t=this.options.startDate,e=this.options.endDate;if(this.options.singleMode&&t)this.options.element.value=t.format(this.options.format,this.options.lang);else if(!this.options.singleMode&&t&&e){var i=t.format(this.options.format,this.options.lang),a=e.format(this.options.format,this.options.lang);this.options.elementEnd instanceof HTMLInputElement?(this.options.element.value=i,this.options.elementEnd.value=a):this.options.element.value=""+i+this.options.delimiter+a}t||e||(this.options.element.value="",this.options.elementEnd instanceof HTMLInputElement&&(this.options.elementEnd.value=""))}},e.prototype.isSamePicker=function(t){return t.closest("."+l.litepicker)===this.ui},e.prototype.shouldShown=function(t){return!t.disabled&&(t===this.options.element||this.options.elementEnd&&t===this.options.elementEnd)},e.prototype.shouldResetDatePicked=function(){return this.options.singleMode||2===this.datePicked.length},e.prototype.shouldSwapDatePicked=function(){return 2===this.datePicked.length&&this.datePicked[0].getTime()>this.datePicked[1].getTime()},e.prototype.shouldCheckLockDays=function(){return this.options.disallowLockDaysInRange&&2===this.datePicked.length},e.prototype.onClick=function(t){var e=t.target;if(t.target.shadowRoot&&(e=t.composedPath()[0]),e&&this.ui)if(this.shouldShown(e))this.show(e);else if(e.closest("."+l.litepicker)||!this.isShowning()){if(this.isSamePicker(e))if(this.emit("before:click",e),this.preventClick)this.preventClick=!1;else{if(e.classList.contains(l.dayItem)){if(t.preventDefault(),e.classList.contains(l.isLocked))return;if(this.shouldResetDatePicked()&&(this.datePicked.length=0),this.datePicked[this.datePicked.length]=new o.DateTime(e.dataset.time),this.shouldSwapDatePicked()){var i=this.datePicked[1].clone();this.datePicked[1]=this.datePicked[0].clone(),this.datePicked[0]=i.clone()}return this.shouldCheckLockDays()&&c.rangeIsLocked(this.datePicked,this.options)&&(this.emit("error:range",this.datePicked),this.datePicked.length=0),this.render(),this.emit.apply(this,n(["preselect"],n(this.datePicked).map((function(t){return t.clone()})))),void(this.options.autoApply&&(this.options.singleMode&&this.datePicked.length?(this.setDate(this.datePicked[0]),this.hide()):this.options.singleMode||2!==this.datePicked.length||(this.setDateRange(this.datePicked[0],this.datePicked[1]),this.hide())))}if(e.classList.contains(l.buttonPreviousMonth)){t.preventDefault();var a=0,s=this.options.switchingMonths||this.options.numberOfMonths;if(this.options.splitView){var r=e.closest("."+l.monthItem);a=c.findNestedMonthItem(r),s=1}return this.calendars[a].setMonth(this.calendars[a].getMonth()-s),this.gotoDate(this.calendars[a],a),void this.emit("change:month",this.calendars[a],a)}if(e.classList.contains(l.buttonNextMonth))return t.preventDefault(),a=0,s=this.options.switchingMonths||this.options.numberOfMonths,this.options.splitView&&(r=e.closest("."+l.monthItem),a=c.findNestedMonthItem(r),s=1),this.calendars[a].setMonth(this.calendars[a].getMonth()+s),this.gotoDate(this.calendars[a],a),void this.emit("change:month",this.calendars[a],a);e.classList.contains(l.buttonCancel)&&(t.preventDefault(),this.hide(),this.emit("button:cancel")),e.classList.contains(l.buttonApply)&&(t.preventDefault(),this.options.singleMode&&this.datePicked.length?this.setDate(this.datePicked[0]):this.options.singleMode||2!==this.datePicked.length||this.setDateRange(this.datePicked[0],this.datePicked[1]),this.hide(),this.emit("button:apply",this.options.startDate,this.options.endDate))}}else this.hide()},e.prototype.showTooltip=function(t,e){var i=this.ui.querySelector("."+l.containerTooltip);i.style.visibility="visible",i.innerHTML=e;var a=this.ui.getBoundingClientRect(),s=i.getBoundingClientRect(),n=t.getBoundingClientRect(),r=n.top,o=n.left;if(this.options.inlineMode&&this.options.parentEl){var c=this.ui.parentNode.getBoundingClientRect();r-=c.top,o-=c.left}else r-=a.top,o-=a.left;r-=s.height,o-=s.width/2,o+=n.width/2,i.style.top=r+"px",i.style.left=o+"px",this.emit("tooltip",i,t)},e.prototype.hideTooltip=function(){this.ui.querySelector("."+l.containerTooltip).style.visibility="hidden"},e.prototype.shouldAllowMouseEnter=function(t){return!this.options.singleMode&&!t.classList.contains(l.isLocked)},e.prototype.shouldAllowRepick=function(){return this.options.elementEnd&&this.options.allowRepick&&this.options.startDate&&this.options.endDate},e.prototype.isDayItem=function(t){return t.classList.contains(l.dayItem)},e.prototype.onMouseEnter=function(t){var e=this,i=t.target;if(this.isDayItem(i)&&this.shouldAllowMouseEnter(i)){if(this.shouldAllowRepick()&&(this.triggerElement===this.options.element?this.datePicked[0]=this.options.endDate.clone():this.triggerElement===this.options.elementEnd&&(this.datePicked[0]=this.options.startDate.clone())),1!==this.datePicked.length)return;var a=this.ui.querySelector("."+l.dayItem+'[data-time="'+this.datePicked[0].getTime()+'"]'),s=this.datePicked[0].clone(),n=new o.DateTime(i.dataset.time),r=!1;if(s.getTime()>n.getTime()){var c=s.clone();s=n.clone(),n=c.clone(),r=!0}if(Array.prototype.slice.call(this.ui.querySelectorAll("."+l.dayItem)).forEach((function(t){var i=new o.DateTime(t.dataset.time),a=e.renderDay(i);i.isBetween(s,n)&&a.classList.add(l.isInRange),t.className=a.className})),i.classList.add(l.isEndDate),r?(a&&a.classList.add(l.isFlipped),i.classList.add(l.isFlipped)):(a&&a.classList.remove(l.isFlipped),i.classList.remove(l.isFlipped)),this.options.showTooltip){var h=n.diff(s,"day")+1;if("function"==typeof this.options.tooltipNumber&&(h=this.options.tooltipNumber.call(this,h)),h>0){var d=this.pluralSelector(h),u=h+" "+(this.options.tooltipText[d]?this.options.tooltipText[d]:"["+d+"]");this.showTooltip(i,u);var p=window.navigator.userAgent,f=/(iphone|ipad)/i.test(p),g=/OS 1([0-2])/i.test(p);f&&g&&i.dispatchEvent(new Event("click"))}else this.hideTooltip()}}},e.prototype.onMouseLeave=function(t){t.target,this.options.allowRepick&&(!this.options.allowRepick||this.options.startDate||this.options.endDate)&&(this.datePicked.length=0,this.render())},e.prototype.onInput=function(t){var e=this.parseInput(),i=e[0],a=e[1],s=this.options.format;if(this.options.elementEnd?i instanceof o.DateTime&&a instanceof o.DateTime&&i.format(s)===this.options.element.value&&a.format(s)===this.options.elementEnd.value:this.options.singleMode?i instanceof o.DateTime&&i.format(s)===this.options.element.value:i instanceof o.DateTime&&a instanceof o.DateTime&&""+i.format(s)+this.options.delimiter+a.format(s)===this.options.element.value){if(a&&i.getTime()>a.getTime()){var n=i.clone();i=a.clone(),a=n.clone()}this.options.startDate=new o.DateTime(i,this.options.format,this.options.lang),a&&(this.options.endDate=new o.DateTime(a,this.options.format,this.options.lang)),this.updateInput(),this.render();var r=i.clone(),l=0;(this.options.elementEnd?i.format(s)===t.target.value:t.target.value.startsWith(i.format(s)))||(r=a.clone(),l=this.options.numberOfMonths-1),this.emit("selected",this.getStartDate(),this.getEndDate()),this.gotoDate(r,l)}},e}(r.Calendar);e.Litepicker=h},function(t,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.findNestedMonthItem=function(t){for(var e=t.parentNode.childNodes,i=0;i<e.length;i+=1)if(e.item(i)===t)return i;return 0},e.dateIsLocked=function(t,e,i){var a=!1;return e.lockDays.length&&(a=e.lockDays.filter((function(i){return i instanceof Array?t.isBetween(i[0],i[1],e.lockDaysInclusivity):i.isSame(t,"day")})).length),a||"function"!=typeof e.lockDaysFilter||(a=e.lockDaysFilter.call(this,t.clone(),null,i)),a},e.rangeIsLocked=function(t,e){var i=!1;return e.lockDays.length&&(i=e.lockDays.filter((function(i){if(i instanceof Array){var a=t[0].toDateString()===i[0].toDateString()&&t[1].toDateString()===i[1].toDateString();return i[0].isBetween(t[0],t[1],e.lockDaysInclusivity)||i[1].isBetween(t[0],t[1],e.lockDaysInclusivity)||a}return i.isBetween(t[0],t[1],e.lockDaysInclusivity)})).length),i||"function"!=typeof e.lockDaysFilter||(i=e.lockDaysFilter.call(this,t[0].clone(),t[1].clone(),t)),i}},function(t,e,i){var a=i(8);"string"==typeof a&&(a=[[t.i,a,""]]);var s={insert:function(t){var e=document.querySelector("head"),i=window._lastElementInsertedByStyleLoader;window.disableLitepickerStyles||(i?i.nextSibling?e.insertBefore(t,i.nextSibling):e.appendChild(t):e.insertBefore(t,e.firstChild),window._lastElementInsertedByStyleLoader=t)},singleton:!1};i(10)(a,s),a.locals&&(t.exports=a.locals)},function(t,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var a=i(1);e.Litepicker=a.Litepicker,i(11),window.Litepicker=a.Litepicker,e.default=a.Litepicker},function(t,e,i){"use strict";var a,s=this&&this.__extends||(a=function(t,e){return(a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var i in e)e.hasOwnProperty(i)&&(t[i]=e[i])})(t,e)},function(t,e){function i(){this.constructor=t}a(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)});Object.defineProperty(e,"__esModule",{value:!0});var n=i(6),r=i(0),o=i(3),l=i(2),c=function(t){function e(e){return t.call(this,e)||this}return s(e,t),e.prototype.render=function(){var t=this;this.emit("before:render",this.ui);var e=document.createElement("div");e.className=o.containerMain;var i=document.createElement("div");i.className=o.containerMonths,o["columns"+this.options.numberOfColumns]&&(i.classList.remove(o.columns2,o.columns3,o.columns4),i.classList.add(o["columns"+this.options.numberOfColumns])),this.options.splitView&&i.classList.add(o.splitView),this.options.showWeekNumbers&&i.classList.add(o.showWeekNumbers);for(var a=this.calendars[0].clone(),s=a.getMonth(),n=a.getMonth()+this.options.numberOfMonths,r=0,l=s;l<n;l+=1){var c=a.clone();c.setDate(1),c.setHours(0,0,0,0),this.options.splitView?c=this.calendars[r].clone():c.setMonth(l),i.appendChild(this.renderMonth(c,r)),r+=1}if(this.ui.innerHTML="",e.appendChild(i),this.options.resetButton){var h=void 0;"function"==typeof this.options.resetButton?h=this.options.resetButton.call(this):((h=document.createElement("button")).type="button",h.className=o.resetButton,h.innerHTML=this.options.buttonText.reset),h.addEventListener("click",(function(e){e.preventDefault(),t.clearSelection()})),e.querySelector("."+o.monthItem+":last-child").querySelector("."+o.monthItemHeader).appendChild(h)}this.ui.appendChild(e),this.options.autoApply&&!this.options.footerHTML||this.ui.appendChild(this.renderFooter()),this.options.showTooltip&&this.ui.appendChild(this.renderTooltip()),this.ui.dataset.plugins=(this.options.plugins||[]).join("|"),this.emit("render",this.ui)},e.prototype.renderMonth=function(t,e){var i=this,a=t.clone(),s=32-new Date(a.getFullYear(),a.getMonth(),32).getDate(),n=document.createElement("div");n.className=o.monthItem;var c=document.createElement("div");c.className=o.monthItemHeader;var h=document.createElement("div");if(this.options.dropdowns.months){var d=document.createElement("select");d.className=o.monthItemName;for(var u=0;u<12;u+=1){var p=document.createElement("option"),f=new r.DateTime(new Date(t.getFullYear(),u,2,0,0,0)),g=new r.DateTime(new Date(t.getFullYear(),u,1,0,0,0));p.value=String(u),p.text=f.toLocaleString(this.options.lang,{month:"long"}),p.disabled=this.options.minDate&&g.isBefore(new r.DateTime(this.options.minDate),"month")||this.options.maxDate&&g.isAfter(new r.DateTime(this.options.maxDate),"month"),p.selected=g.getMonth()===t.getMonth(),d.appendChild(p)}d.addEventListener("change",(function(t){var e=t.target,a=0;if(i.options.splitView){var s=e.closest("."+o.monthItem);a=l.findNestedMonthItem(s)}i.calendars[a].setMonth(Number(e.value)),i.render(),i.emit("change:month",i.calendars[a],a,t)})),h.appendChild(d)}else(f=document.createElement("strong")).className=o.monthItemName,f.innerHTML=t.toLocaleString(this.options.lang,{month:"long"}),h.appendChild(f);if(this.options.dropdowns.years){var x=document.createElement("select");x.className=o.monthItemYear;var m=this.options.dropdowns.minYear,b=this.options.dropdowns.maxYear?this.options.dropdowns.maxYear:(new Date).getFullYear();for(t.getFullYear()>b&&((p=document.createElement("option")).value=String(t.getFullYear()),p.text=String(t.getFullYear()),p.selected=!0,p.disabled=!0,x.appendChild(p)),u=b;u>=m;u-=1){p=document.createElement("option");var v=new r.DateTime(new Date(u,0,1,0,0,0));p.value=String(u),p.text=String(u),p.disabled=this.options.minDate&&v.isBefore(new r.DateTime(this.options.minDate),"year")||this.options.maxDate&&v.isAfter(new r.DateTime(this.options.maxDate),"year"),p.selected=t.getFullYear()===u,x.appendChild(p)}if(t.getFullYear()<m&&((p=document.createElement("option")).value=String(t.getFullYear()),p.text=String(t.getFullYear()),p.selected=!0,p.disabled=!0,x.appendChild(p)),"asc"===this.options.dropdowns.years){var y=Array.prototype.slice.call(x.childNodes).reverse();x.innerHTML="",y.forEach((function(t){t.innerHTML=t.value,x.appendChild(t)}))}x.addEventListener("change",(function(t){var e=t.target,a=0;if(i.options.splitView){var s=e.closest("."+o.monthItem);a=l.findNestedMonthItem(s)}i.calendars[a].setFullYear(Number(e.value)),i.render(),i.emit("change:year",i.calendars[a],a,t)})),h.appendChild(x)}else{var w=document.createElement("span");w.className=o.monthItemYear,w.innerHTML=String(t.getFullYear()),h.appendChild(w)}var k=document.createElement("button");k.type="button",k.className=o.buttonPreviousMonth,k.innerHTML=this.options.buttonText.previousMonth;var A=document.createElement("button");A.type="button",A.className=o.buttonNextMonth,A.innerHTML=this.options.buttonText.nextMonth,c.appendChild(k),c.appendChild(h),c.appendChild(A),this.options.minDate&&a.isSameOrBefore(new r.DateTime(this.options.minDate),"month")&&n.classList.add(o.noPreviousMonth),this.options.maxDate&&a.isSameOrAfter(new r.DateTime(this.options.maxDate),"month")&&n.classList.add(o.noNextMonth);var S=document.createElement("div");S.className=o.monthItemWeekdaysRow,this.options.showWeekNumbers&&(S.innerHTML="<div>W</div>");for(var C=1;C<=7;C+=1){var L=3+this.options.firstDay+C,P=document.createElement("div");P.innerHTML=this.weekdayName(L),P.title=this.weekdayName(L,"long"),S.appendChild(P)}var T=document.createElement("div");T.className=o.containerDays;var M=this.calcSkipDays(a);this.options.showWeekNumbers&&M&&T.appendChild(this.renderWeekNumber(a));for(var E=0;E<M;E+=1){var D=document.createElement("div");T.appendChild(D)}for(E=1;E<=s;E+=1)a.setDate(E),this.options.showWeekNumbers&&a.getDay()===this.options.firstDay&&T.appendChild(this.renderWeekNumber(a)),T.appendChild(this.renderDay(a));return n.appendChild(c),n.appendChild(S),n.appendChild(T),this.emit("render:month",n,t),n},e.prototype.renderDay=function(t){t.setHours();var e=document.createElement("div");if(e.className=o.dayItem,e.innerHTML=String(t.getDate()),e.dataset.time=String(t.getTime()),t.toDateString()===(new Date).toDateString()&&e.classList.add(o.isToday),this.datePicked.length)this.datePicked[0].toDateString()===t.toDateString()&&(e.classList.add(o.isStartDate),this.options.singleMode&&e.classList.add(o.isEndDate)),2===this.datePicked.length&&this.datePicked[1].toDateString()===t.toDateString()&&e.classList.add(o.isEndDate),2===this.datePicked.length&&t.isBetween(this.datePicked[0],this.datePicked[1])&&e.classList.add(o.isInRange);else if(this.options.startDate){var i=this.options.startDate,a=this.options.endDate;i.toDateString()===t.toDateString()&&(e.classList.add(o.isStartDate),this.options.singleMode&&e.classList.add(o.isEndDate)),a&&a.toDateString()===t.toDateString()&&e.classList.add(o.isEndDate),i&&a&&t.isBetween(i,a)&&e.classList.add(o.isInRange)}if(this.options.minDate&&t.isBefore(new r.DateTime(this.options.minDate))&&e.classList.add(o.isLocked),this.options.maxDate&&t.isAfter(new r.DateTime(this.options.maxDate))&&e.classList.add(o.isLocked),this.options.minDays>1&&1===this.datePicked.length){var s=this.options.minDays-1,n=this.datePicked[0].clone().subtract(s,"day"),c=this.datePicked[0].clone().add(s,"day");t.isBetween(n,this.datePicked[0],"(]")&&e.classList.add(o.isLocked),t.isBetween(this.datePicked[0],c,"[)")&&e.classList.add(o.isLocked)}if(this.options.maxDays&&1===this.datePicked.length){var h=this.options.maxDays;n=this.datePicked[0].clone().subtract(h,"day"),c=this.datePicked[0].clone().add(h,"day"),t.isSameOrBefore(n)&&e.classList.add(o.isLocked),t.isSameOrAfter(c)&&e.classList.add(o.isLocked)}return this.options.selectForward&&1===this.datePicked.length&&t.isBefore(this.datePicked[0])&&e.classList.add(o.isLocked),this.options.selectBackward&&1===this.datePicked.length&&t.isAfter(this.datePicked[0])&&e.classList.add(o.isLocked),l.dateIsLocked(t,this.options,this.datePicked)&&e.classList.add(o.isLocked),this.options.highlightedDays.length&&this.options.highlightedDays.filter((function(e){return e instanceof Array?t.isBetween(e[0],e[1],"[]"):e.isSame(t,"day")})).length&&e.classList.add(o.isHighlighted),e.tabIndex=e.classList.contains("is-locked")?-1:0,this.emit("render:day",e,t),e},e.prototype.renderFooter=function(){var t=document.createElement("div");if(t.className=o.containerFooter,this.options.footerHTML?t.innerHTML=this.options.footerHTML:t.innerHTML='\n <span class="'+o.previewDateRange+'"></span>\n <button type="button" class="'+o.buttonCancel+'">'+this.options.buttonText.cancel+'</button>\n <button type="button" class="'+o.buttonApply+'">'+this.options.buttonText.apply+"</button>\n ",this.options.singleMode){if(1===this.datePicked.length){var e=this.datePicked[0].format(this.options.format,this.options.lang);t.querySelector("."+o.previewDateRange).innerHTML=e}}else if(1===this.datePicked.length&&t.querySelector("."+o.buttonApply).setAttribute("disabled",""),2===this.datePicked.length){e=this.datePicked[0].format(this.options.format,this.options.lang);var i=this.datePicked[1].format(this.options.format,this.options.lang);t.querySelector("."+o.previewDateRange).innerHTML=""+e+this.options.delimiter+i}return this.emit("render:footer",t),t},e.prototype.renderWeekNumber=function(t){var e=document.createElement("div"),i=t.getWeek(this.options.firstDay);return e.className=o.weekNumber,e.innerHTML=53===i&&0===t.getMonth()?"53 / 1":i,e},e.prototype.renderTooltip=function(){var t=document.createElement("div");return t.className=o.containerTooltip,t},e.prototype.weekdayName=function(t,e){return void 0===e&&(e="short"),new Date(1970,0,t,12,0,0,0).toLocaleString(this.options.lang,{weekday:e})},e.prototype.calcSkipDays=function(t){var e=t.getDay()-this.options.firstDay;return e<0&&(e+=7),e},e}(n.LPCore);e.Calendar=c},function(t,e,i){"use strict";var a,s=this&&this.__extends||(a=function(t,e){return(a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var i in e)e.hasOwnProperty(i)&&(t[i]=e[i])})(t,e)},function(t,e){function i(){this.constructor=t}a(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}),n=this&&this.__assign||function(){return(n=Object.assign||function(t){for(var e,i=1,a=arguments.length;i<a;i++)for(var s in e=arguments[i])Object.prototype.hasOwnProperty.call(e,s)&&(t[s]=e[s]);return t}).apply(this,arguments)};Object.defineProperty(e,"__esModule",{value:!0});var r=i(7),o=i(0),l=i(1),c=function(t){function e(e){var i=t.call(this)||this;i.datePicked=[],i.calendars=[],i.options={element:null,elementEnd:null,parentEl:null,firstDay:1,format:"YYYY-MM-DD",lang:"en-US",delimiter:" - ",numberOfMonths:1,numberOfColumns:1,startDate:null,endDate:null,zIndex:9999,position:"auto",selectForward:!1,selectBackward:!1,splitView:!1,inlineMode:!1,singleMode:!0,autoApply:!0,allowRepick:!1,showWeekNumbers:!1,showTooltip:!0,scrollToDate:!0,mobileFriendly:!0,resetButton:!1,autoRefresh:!1,lockDaysFormat:"YYYY-MM-DD",lockDays:[],disallowLockDaysInRange:!1,lockDaysInclusivity:"[]",highlightedDaysFormat:"YYYY-MM-DD",highlightedDays:[],dropdowns:{minYear:1990,maxYear:null,months:!1,years:!1},buttonText:{apply:"Apply",cancel:"Cancel",previousMonth:'<svg width="11" height="16" xmlns="http://www.w3.org/2000/svg"><path d="M7.919 0l2.748 2.667L5.333 8l5.334 5.333L7.919 16 0 8z" fill-rule="nonzero"/></svg>',nextMonth:'<svg width="11" height="16" xmlns="http://www.w3.org/2000/svg"><path d="M2.748 16L0 13.333 5.333 8 0 2.667 2.748 0l7.919 8z" fill-rule="nonzero"/></svg>',reset:'<svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" width="24">\n <path d="M0 0h24v24H0z" fill="none"/>\n <path d="M13 3c-4.97 0-9 4.03-9 9H1l3.89 3.89.07.14L9 12H6c0-3.87 3.13-7 7-7s7 3.13 7 7-3.13 7-7 7c-1.93 0-3.68-.79-4.94-2.06l-1.42 1.42C8.27 19.99 10.51 21 13 21c4.97 0 9-4.03 9-9s-4.03-9-9-9zm-1 5v5l4.28 2.54.72-1.21-3.5-2.08V8H12z"/>\n </svg>'},tooltipText:{one:"day",other:"days"}},i.options=n(n({},i.options),e.element.dataset),Object.keys(i.options).forEach((function(t){"true"!==i.options[t]&&"false"!==i.options[t]||(i.options[t]="true"===i.options[t])}));var a=n(n({},i.options.dropdowns),e.dropdowns),s=n(n({},i.options.buttonText),e.buttonText),r=n(n({},i.options.tooltipText),e.tooltipText);i.options=n(n({},i.options),e),i.options.dropdowns=n({},a),i.options.buttonText=n({},s),i.options.tooltipText=n({},r),i.options.elementEnd||(i.options.allowRepick=!1),i.options.lockDays.length&&(i.options.lockDays=o.DateTime.convertArray(i.options.lockDays,i.options.lockDaysFormat)),i.options.highlightedDays.length&&(i.options.highlightedDays=o.DateTime.convertArray(i.options.highlightedDays,i.options.highlightedDaysFormat));var l=i.parseInput(),c=l[0],h=l[1];i.options.startDate&&(i.options.singleMode||i.options.endDate)&&(c=new o.DateTime(i.options.startDate,i.options.format,i.options.lang)),c&&i.options.endDate&&(h=new o.DateTime(i.options.endDate,i.options.format,i.options.lang)),c instanceof o.DateTime&&!isNaN(c.getTime())&&(i.options.startDate=c),i.options.startDate&&h instanceof o.DateTime&&!isNaN(h.getTime())&&(i.options.endDate=h),!i.options.singleMode||i.options.startDate instanceof o.DateTime||(i.options.startDate=null),i.options.singleMode||i.options.startDate instanceof o.DateTime&&i.options.endDate instanceof o.DateTime||(i.options.startDate=null,i.options.endDate=null);for(var d=0;d<i.options.numberOfMonths;d+=1){var u=i.options.startDate instanceof o.DateTime?i.options.startDate.clone():new o.DateTime;if(!i.options.startDate&&(0===d||i.options.splitView)){var p=i.options.maxDate?new o.DateTime(i.options.maxDate):null,f=i.options.minDate?new o.DateTime(i.options.minDate):null,g=i.options.numberOfMonths-1;f&&p&&u.isAfter(p)?(u=f.clone()).setDate(1):!f&&p&&u.isAfter(p)&&((u=p.clone()).setDate(1),u.setMonth(u.getMonth()-g))}u.setDate(1),u.setMonth(u.getMonth()+d),i.calendars[d]=u}if(i.options.showTooltip)if(i.options.tooltipPluralSelector)i.pluralSelector=i.options.tooltipPluralSelector;else try{var x=new Intl.PluralRules(i.options.lang);i.pluralSelector=x.select.bind(x)}catch(t){i.pluralSelector=function(t){return 0===Math.abs(t)?"one":"other"}}return i}return s(e,t),e.add=function(t,e){l.Litepicker.prototype[t]=e},e.prototype.DateTime=function(t,e){return t?new o.DateTime(t,e):new o.DateTime},e.prototype.init=function(){var t=this;this.options.plugins&&this.options.plugins.length&&this.options.plugins.forEach((function(e){l.Litepicker.prototype.hasOwnProperty(e)?l.Litepicker.prototype[e].init.call(t,t):console.warn("Litepicker: plugin «"+e+"» not found.")}))},e.prototype.parseInput=function(){var t=this.options.delimiter,e=new RegExp(""+t),i=this.options.element instanceof HTMLInputElement?this.options.element.value.split(t):[];if(this.options.elementEnd){if(this.options.element instanceof HTMLInputElement&&this.options.element.value.length&&this.options.elementEnd instanceof HTMLInputElement&&this.options.elementEnd.value.length)return[new o.DateTime(this.options.element.value,this.options.format),new o.DateTime(this.options.elementEnd.value,this.options.format)]}else if(this.options.singleMode){if(this.options.element instanceof HTMLInputElement&&this.options.element.value.length)return[new o.DateTime(this.options.element.value,this.options.format)]}else if(this.options.element instanceof HTMLInputElement&&e.test(this.options.element.value)&&i.length&&i.length%2==0){var a=i.slice(0,i.length/2).join(t),s=i.slice(i.length/2).join(t);return[new o.DateTime(a,this.options.format),new o.DateTime(s,this.options.format)]}return[]},e.prototype.isShowning=function(){return this.ui&&"none"!==this.ui.style.display},e.prototype.findPosition=function(t){var e=t.getBoundingClientRect(),i=this.ui.getBoundingClientRect(),a=this.options.position.split(" "),s=window.scrollX||window.pageXOffset,n=window.scrollY||window.pageYOffset,r=0,o=0;if("auto"!==a[0]&&/top|bottom/.test(a[0]))r=e[a[0]]+n,"top"===a[0]&&(r-=i.height);else{r=e.bottom+n;var l=e.bottom+i.height>window.innerHeight,c=e.top+n-i.height>=i.height;l&&c&&(r=e.top+n-i.height)}if(/left|right/.test(a[0])||a[1]&&"auto"!==a[1]&&/left|right/.test(a[1]))o=/left|right/.test(a[0])?e[a[0]]+s:e[a[1]]+s,"right"!==a[0]&&"right"!==a[1]||(o-=i.width);else{o=e.left+s,l=e.left+i.width>window.innerWidth;var h=e.right+s-i.width>=0;l&&h&&(o=e.right+s-i.width)}return{left:o,top:r}},e}(r.EventEmitter);e.LPCore=c},function(t,e,i){"use strict";var a,s="object"==("undefined"==typeof Reflect?"undefined":o(Reflect))?Reflect:null,n=s&&"function"==typeof s.apply?s.apply:function(t,e,i){return Function.prototype.apply.call(t,e,i)};a=s&&"function"==typeof s.ownKeys?s.ownKeys:Object.getOwnPropertySymbols?function(t){return Object.getOwnPropertyNames(t).concat(Object.getOwnPropertySymbols(t))}:function(t){return Object.getOwnPropertyNames(t)};var r=Number.isNaN||function(t){return t!=t};function l(){l.init.call(this)}t.exports=l,l.EventEmitter=l,l.prototype._events=void 0,l.prototype._eventsCount=0,l.prototype._maxListeners=void 0;var c=10;function h(t){return void 0===t._maxListeners?l.defaultMaxListeners:t._maxListeners}function d(t,e,i,a){var s,n,r,l;if("function"!=typeof i)throw new TypeError('The "listener" argument must be of type Function. Received type '+o(i));if(void 0===(n=t._events)?(n=t._events=Object.create(null),t._eventsCount=0):(void 0!==n.newListener&&(t.emit("newListener",e,i.listener?i.listener:i),n=t._events),r=n[e]),void 0===r)r=n[e]=i,++t._eventsCount;else if("function"==typeof r?r=n[e]=a?[i,r]:[r,i]:a?r.unshift(i):r.push(i),(s=h(t))>0&&r.length>s&&!r.warned){r.warned=!0;var c=new Error("Possible EventEmitter memory leak detected. "+r.length+" "+String(e)+" listeners added. Use emitter.setMaxListeners() to increase limit");c.name="MaxListenersExceededWarning",c.emitter=t,c.type=e,c.count=r.length,l=c,console&&console.warn&&console.warn(l)}return t}function u(){for(var t=[],e=0;e<arguments.length;e++)t.push(arguments[e]);this.fired||(this.target.removeListener(this.type,this.wrapFn),this.fired=!0,n(this.listener,this.target,t))}function p(t,e,i){var a={fired:!1,wrapFn:void 0,target:t,type:e,listener:i},s=u.bind(a);return s.listener=i,a.wrapFn=s,s}function f(t,e,i){var a=t._events;if(void 0===a)return[];var s=a[e];return void 0===s?[]:"function"==typeof s?i?[s.listener||s]:[s]:i?function(t){for(var e=new Array(t.length),i=0;i<e.length;++i)e[i]=t[i].listener||t[i];return e}(s):x(s,s.length)}function g(t){var e=this._events;if(void 0!==e){var i=e[t];if("function"==typeof i)return 1;if(void 0!==i)return i.length}return 0}function x(t,e){for(var i=new Array(e),a=0;a<e;++a)i[a]=t[a];return i}Object.defineProperty(l,"defaultMaxListeners",{enumerable:!0,get:function(){return c},set:function(t){if("number"!=typeof t||t<0||r(t))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+t+".");c=t}}),l.init=function(){void 0!==this._events&&this._events!==Object.getPrototypeOf(this)._events||(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},l.prototype.setMaxListeners=function(t){if("number"!=typeof t||t<0||r(t))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+t+".");return this._maxListeners=t,this},l.prototype.getMaxListeners=function(){return h(this)},l.prototype.emit=function(t){for(var e=[],i=1;i<arguments.length;i++)e.push(arguments[i]);var a="error"===t,s=this._events;if(void 0!==s)a=a&&void 0===s.error;else if(!a)return!1;if(a){var r;if(e.length>0&&(r=e[0]),r instanceof Error)throw r;var o=new Error("Unhandled error."+(r?" ("+r.message+")":""));throw o.context=r,o}var l=s[t];if(void 0===l)return!1;if("function"==typeof l)n(l,this,e);else{var c=l.length,h=x(l,c);for(i=0;i<c;++i)n(h[i],this,e)}return!0},l.prototype.addListener=function(t,e){return d(this,t,e,!1)},l.prototype.on=l.prototype.addListener,l.prototype.prependListener=function(t,e){return d(this,t,e,!0)},l.prototype.once=function(t,e){if("function"!=typeof e)throw new TypeError('The "listener" argument must be of type Function. Received type '+o(e));return this.on(t,p(this,t,e)),this},l.prototype.prependOnceListener=function(t,e){if("function"!=typeof e)throw new TypeError('The "listener" argument must be of type Function. Received type '+o(e));return this.prependListener(t,p(this,t,e)),this},l.prototype.removeListener=function(t,e){var i,a,s,n,r;if("function"!=typeof e)throw new TypeError('The "listener" argument must be of type Function. Received type '+o(e));if(void 0===(a=this._events))return this;if(void 0===(i=a[t]))return this;if(i===e||i.listener===e)0==--this._eventsCount?this._events=Object.create(null):(delete a[t],a.removeListener&&this.emit("removeListener",t,i.listener||e));else if("function"!=typeof i){for(s=-1,n=i.length-1;n>=0;n--)if(i[n]===e||i[n].listener===e){r=i[n].listener,s=n;break}if(s<0)return this;0===s?i.shift():function(t,e){for(;e+1<t.length;e++)t[e]=t[e+1];t.pop()}(i,s),1===i.length&&(a[t]=i[0]),void 0!==a.removeListener&&this.emit("removeListener",t,r||e)}return this},l.prototype.off=l.prototype.removeListener,l.prototype.removeAllListeners=function(t){var e,i,a;if(void 0===(i=this._events))return this;if(void 0===i.removeListener)return 0===arguments.length?(this._events=Object.create(null),this._eventsCount=0):void 0!==i[t]&&(0==--this._eventsCount?this._events=Object.create(null):delete i[t]),this;if(0===arguments.length){var s,n=Object.keys(i);for(a=0;a<n.length;++a)"removeListener"!==(s=n[a])&&this.removeAllListeners(s);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if("function"==typeof(e=i[t]))this.removeListener(t,e);else if(void 0!==e)for(a=e.length-1;a>=0;a--)this.removeListener(t,e[a]);return this},l.prototype.listeners=function(t){return f(this,t,!0)},l.prototype.rawListeners=function(t){return f(this,t,!1)},l.listenerCount=function(t,e){return"function"==typeof t.listenerCount?t.listenerCount(e):g.call(t,e)},l.prototype.listenerCount=g,l.prototype.eventNames=function(){return this._eventsCount>0?a(this._events):[]}},function(t,e,i){(e=i(9)(!1)).push([t.i,':root{--litepicker-container-months-color-bg: #fff;--litepicker-container-months-box-shadow-color: #ddd;--litepicker-footer-color-bg: #fafafa;--litepicker-footer-box-shadow-color: #ddd;--litepicker-tooltip-color-bg: #fff;--litepicker-month-header-color: #333;--litepicker-button-prev-month-color: #9e9e9e;--litepicker-button-next-month-color: #9e9e9e;--litepicker-button-prev-month-color-hover: #2196f3;--litepicker-button-next-month-color-hover: #2196f3;--litepicker-month-width: calc(var(--litepicker-day-width) * 7);--litepicker-month-weekday-color: #9e9e9e;--litepicker-month-week-number-color: #9e9e9e;--litepicker-day-width: 38px;--litepicker-day-color: #333;--litepicker-day-color-hover: #2196f3;--litepicker-is-today-color: #f44336;--litepicker-is-in-range-color: #bbdefb;--litepicker-is-locked-color: #9e9e9e;--litepicker-is-start-color: #fff;--litepicker-is-start-color-bg: #2196f3;--litepicker-is-end-color: #fff;--litepicker-is-end-color-bg: #2196f3;--litepicker-button-cancel-color: #fff;--litepicker-button-cancel-color-bg: #9e9e9e;--litepicker-button-apply-color: #fff;--litepicker-button-apply-color-bg: #2196f3;--litepicker-button-reset-color: #909090;--litepicker-button-reset-color-hover: #2196f3;--litepicker-highlighted-day-color: #333;--litepicker-highlighted-day-color-bg: #ffeb3b}.show-week-numbers{--litepicker-month-width: calc(var(--litepicker-day-width) * 8)}.litepicker{font-family:-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;font-size:0.8em;display:none}.litepicker button{border:none;background:none}.litepicker .container__main{display:-webkit-box;display:-ms-flexbox;display:flex}.litepicker .container__months{display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;background-color:var(--litepicker-container-months-color-bg);border-radius:5px;-webkit-box-shadow:0 0 5px var(--litepicker-container-months-box-shadow-color);box-shadow:0 0 5px var(--litepicker-container-months-box-shadow-color);width:calc(var(--litepicker-month-width) + 10px);-webkit-box-sizing:content-box;box-sizing:content-box}.litepicker .container__months.columns-2{width:calc((var(--litepicker-month-width) * 2) + 20px)}.litepicker .container__months.columns-3{width:calc((var(--litepicker-month-width) * 3) + 30px)}.litepicker .container__months.columns-4{width:calc((var(--litepicker-month-width) * 4) + 40px)}.litepicker .container__months.split-view .month-item-header .button-previous-month,.litepicker .container__months.split-view .month-item-header .button-next-month{visibility:visible}.litepicker .container__months .month-item{padding:5px;width:var(--litepicker-month-width);-webkit-box-sizing:content-box;box-sizing:content-box}.litepicker .container__months .month-item-header{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;font-weight:500;padding:10px 5px;text-align:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;color:var(--litepicker-month-header-color)}.litepicker .container__months .month-item-header div{-webkit-box-flex:1;-ms-flex:1;flex:1}.litepicker .container__months .month-item-header div>.month-item-name{margin-right:5px}.litepicker .container__months .month-item-header div>.month-item-year{padding:0}.litepicker .container__months .month-item-header .reset-button{color:var(--litepicker-button-reset-color)}.litepicker .container__months .month-item-header .reset-button>svg{fill:var(--litepicker-button-reset-color)}.litepicker .container__months .month-item-header .reset-button *{pointer-events:none}.litepicker .container__months .month-item-header .reset-button:hover{color:var(--litepicker-button-reset-color-hover)}.litepicker .container__months .month-item-header .reset-button:hover>svg{fill:var(--litepicker-button-reset-color-hover)}.litepicker .container__months .month-item-header .button-previous-month,.litepicker .container__months .month-item-header .button-next-month{visibility:hidden;text-decoration:none;padding:3px 5px;border-radius:3px;-webkit-transition:color 0.3s, border 0.3s;transition:color 0.3s, border 0.3s;cursor:default}.litepicker .container__months .month-item-header .button-previous-month *,.litepicker .container__months .month-item-header .button-next-month *{pointer-events:none}.litepicker .container__months .month-item-header .button-previous-month{color:var(--litepicker-button-prev-month-color)}.litepicker .container__months .month-item-header .button-previous-month>svg,.litepicker .container__months .month-item-header .button-previous-month>img{fill:var(--litepicker-button-prev-month-color)}.litepicker .container__months .month-item-header .button-previous-month:hover{color:var(--litepicker-button-prev-month-color-hover)}.litepicker .container__months .month-item-header .button-previous-month:hover>svg{fill:var(--litepicker-button-prev-month-color-hover)}.litepicker .container__months .month-item-header .button-next-month{color:var(--litepicker-button-next-month-color)}.litepicker .container__months .month-item-header .button-next-month>svg,.litepicker .container__months .month-item-header .button-next-month>img{fill:var(--litepicker-button-next-month-color)}.litepicker .container__months .month-item-header .button-next-month:hover{color:var(--litepicker-button-next-month-color-hover)}.litepicker .container__months .month-item-header .button-next-month:hover>svg{fill:var(--litepicker-button-next-month-color-hover)}.litepicker .container__months .month-item-weekdays-row{display:-webkit-box;display:-ms-flexbox;display:flex;justify-self:center;-webkit-box-pack:start;-ms-flex-pack:start;justify-content:flex-start;color:var(--litepicker-month-weekday-color)}.litepicker .container__months .month-item-weekdays-row>div{padding:5px 0;font-size:85%;-webkit-box-flex:1;-ms-flex:1;flex:1;width:var(--litepicker-day-width);text-align:center}.litepicker .container__months .month-item:first-child .button-previous-month{visibility:visible}.litepicker .container__months .month-item:last-child .button-next-month{visibility:visible}.litepicker .container__months .month-item.no-previous-month .button-previous-month{visibility:hidden}.litepicker .container__months .month-item.no-next-month .button-next-month{visibility:hidden}.litepicker .container__days{display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;justify-self:center;-webkit-box-pack:start;-ms-flex-pack:start;justify-content:flex-start;text-align:center;-webkit-box-sizing:content-box;box-sizing:content-box}.litepicker .container__days>div,.litepicker .container__days>a{padding:5px 0;width:var(--litepicker-day-width)}.litepicker .container__days .day-item{color:var(--litepicker-day-color);text-align:center;text-decoration:none;border-radius:3px;-webkit-transition:color 0.3s, border 0.3s;transition:color 0.3s, border 0.3s;cursor:default}.litepicker .container__days .day-item:hover{color:var(--litepicker-day-color-hover);-webkit-box-shadow:inset 0 0 0 1px var(--litepicker-day-color-hover);box-shadow:inset 0 0 0 1px var(--litepicker-day-color-hover)}.litepicker .container__days .day-item.is-today{color:var(--litepicker-is-today-color)}.litepicker .container__days .day-item.is-locked{color:var(--litepicker-is-locked-color)}.litepicker .container__days .day-item.is-locked:hover{color:var(--litepicker-is-locked-color);-webkit-box-shadow:none;box-shadow:none;cursor:default}.litepicker .container__days .day-item.is-in-range{background-color:var(--litepicker-is-in-range-color);border-radius:0}.litepicker .container__days .day-item.is-start-date{color:var(--litepicker-is-start-color);background-color:var(--litepicker-is-start-color-bg);border-top-left-radius:5px;border-bottom-left-radius:5px;border-top-right-radius:0;border-bottom-right-radius:0}.litepicker .container__days .day-item.is-start-date.is-flipped{border-top-left-radius:0;border-bottom-left-radius:0;border-top-right-radius:5px;border-bottom-right-radius:5px}.litepicker .container__days .day-item.is-end-date{color:var(--litepicker-is-end-color);background-color:var(--litepicker-is-end-color-bg);border-top-left-radius:0;border-bottom-left-radius:0;border-top-right-radius:5px;border-bottom-right-radius:5px}.litepicker .container__days .day-item.is-end-date.is-flipped{border-top-left-radius:5px;border-bottom-left-radius:5px;border-top-right-radius:0;border-bottom-right-radius:0}.litepicker .container__days .day-item.is-start-date.is-end-date{border-top-left-radius:5px;border-bottom-left-radius:5px;border-top-right-radius:5px;border-bottom-right-radius:5px}.litepicker .container__days .day-item.is-highlighted{color:var(--litepicker-highlighted-day-color);background-color:var(--litepicker-highlighted-day-color-bg)}.litepicker .container__days .week-number{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;color:var(--litepicker-month-week-number-color);font-size:85%}.litepicker .container__footer{text-align:right;padding:10px 5px;margin:0 5px;background-color:var(--litepicker-footer-color-bg);-webkit-box-shadow:inset 0px 3px 3px 0px var(--litepicker-footer-box-shadow-color);box-shadow:inset 0px 3px 3px 0px var(--litepicker-footer-box-shadow-color);border-bottom-left-radius:5px;border-bottom-right-radius:5px}.litepicker .container__footer .preview-date-range{margin-right:10px;font-size:90%}.litepicker .container__footer .button-cancel{background-color:var(--litepicker-button-cancel-color-bg);color:var(--litepicker-button-cancel-color);border:0;padding:3px 7px 4px;border-radius:3px}.litepicker .container__footer .button-cancel *{pointer-events:none}.litepicker .container__footer .button-apply{background-color:var(--litepicker-button-apply-color-bg);color:var(--litepicker-button-apply-color);border:0;padding:3px 7px 4px;border-radius:3px;margin-left:10px;margin-right:10px}.litepicker .container__footer .button-apply:disabled{opacity:0.7}.litepicker .container__footer .button-apply *{pointer-events:none}.litepicker .container__tooltip{position:absolute;margin-top:-4px;padding:4px 8px;border-radius:4px;background-color:var(--litepicker-tooltip-color-bg);-webkit-box-shadow:0 1px 3px rgba(0,0,0,0.25);box-shadow:0 1px 3px rgba(0,0,0,0.25);white-space:nowrap;font-size:11px;pointer-events:none;visibility:hidden}.litepicker .container__tooltip:before{position:absolute;bottom:-5px;left:calc(50% - 5px);border-top:5px solid rgba(0,0,0,0.12);border-right:5px solid transparent;border-left:5px solid transparent;content:""}.litepicker .container__tooltip:after{position:absolute;bottom:-4px;left:calc(50% - 4px);border-top:4px solid var(--litepicker-tooltip-color-bg);border-right:4px solid transparent;border-left:4px solid transparent;content:""}\n',""]),e.locals={showWeekNumbers:"show-week-numbers",litepicker:"litepicker",containerMain:"container__main",containerMonths:"container__months",columns2:"columns-2",columns3:"columns-3",columns4:"columns-4",splitView:"split-view",monthItemHeader:"month-item-header",buttonPreviousMonth:"button-previous-month",buttonNextMonth:"button-next-month",monthItem:"month-item",monthItemName:"month-item-name",monthItemYear:"month-item-year",resetButton:"reset-button",monthItemWeekdaysRow:"month-item-weekdays-row",noPreviousMonth:"no-previous-month",noNextMonth:"no-next-month",containerDays:"container__days",dayItem:"day-item",isToday:"is-today",isLocked:"is-locked",isInRange:"is-in-range",isStartDate:"is-start-date",isFlipped:"is-flipped",isEndDate:"is-end-date",isHighlighted:"is-highlighted",weekNumber:"week-number",containerFooter:"container__footer",previewDateRange:"preview-date-range",buttonCancel:"button-cancel",buttonApply:"button-apply",containerTooltip:"container__tooltip"},t.exports=e},function(t,e,i){"use strict";t.exports=function(t){var e=[];return e.toString=function(){return this.map((function(e){var i=function(t,e){var i,a,s,n=t[1]||"",r=t[3];if(!r)return n;if(e&&"function"==typeof btoa){var o=(i=r,a=btoa(unescape(encodeURIComponent(JSON.stringify(i)))),s="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(a),"/*# ".concat(s," */")),l=r.sources.map((function(t){return"/*# sourceURL=".concat(r.sourceRoot||"").concat(t," */")}));return[n].concat(l).concat([o]).join("\n")}return[n].join("\n")}(e,t);return e[2]?"@media ".concat(e[2]," {").concat(i,"}"):i})).join("")},e.i=function(t,i,a){"string"==typeof t&&(t=[[null,t,""]]);var s={};if(a)for(var n=0;n<this.length;n++){var r=this[n][0];null!=r&&(s[r]=!0)}for(var o=0;o<t.length;o++){var l=[].concat(t[o]);a&&s[l[0]]||(i&&(l[2]?l[2]="".concat(i," and ").concat(l[2]):l[2]=i),e.push(l))}},e}},function(t,e,i){"use strict";var a,s={},n=function(){var t={};return function(e){if(void 0===t[e]){var i=document.querySelector(e);if(window.HTMLIFrameElement&&i instanceof window.HTMLIFrameElement)try{i=i.contentDocument.head}catch(t){i=null}t[e]=i}return t[e]}}();function r(t,e){for(var i=[],a={},s=0;s<t.length;s++){var n=t[s],r=e.base?n[0]+e.base:n[0],o={css:n[1],media:n[2],sourceMap:n[3]};a[r]?a[r].parts.push(o):i.push(a[r]={id:r,parts:[o]})}return i}function l(t,e){for(var i=0;i<t.length;i++){var a=t[i],n=s[a.id],r=0;if(n){for(n.refs++;r<n.parts.length;r++)n.parts[r](a.parts[r]);for(;r<a.parts.length;r++)n.parts.push(x(a.parts[r],e))}else{for(var o=[];r<a.parts.length;r++)o.push(x(a.parts[r],e));s[a.id]={id:a.id,refs:1,parts:o}}}}function c(t){var e=document.createElement("style");if(void 0===t.attributes.nonce){var a=i.nc;a&&(t.attributes.nonce=a)}if(Object.keys(t.attributes).forEach((function(i){e.setAttribute(i,t.attributes[i])})),"function"==typeof t.insert)t.insert(e);else{var s=n(t.insert||"head");if(!s)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");s.appendChild(e)}return e}var h,d=(h=[],function(t,e){return h[t]=e,h.filter(Boolean).join("\n")});function u(t,e,i,a){var s=i?"":a.css;if(t.styleSheet)t.styleSheet.cssText=d(e,s);else{var n=document.createTextNode(s),r=t.childNodes;r[e]&&t.removeChild(r[e]),r.length?t.insertBefore(n,r[e]):t.appendChild(n)}}function p(t,e,i){var a=i.css,s=i.media,n=i.sourceMap;if(s&&t.setAttribute("media",s),n&&btoa&&(a+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(n))))," */")),t.styleSheet)t.styleSheet.cssText=a;else{for(;t.firstChild;)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(a))}}var f=null,g=0;function x(t,e){var i,a,s;if(e.singleton){var n=g++;i=f||(f=c(e)),a=u.bind(null,i,n,!1),s=u.bind(null,i,n,!0)}else i=c(e),a=p.bind(null,i,e),s=function(){!function(t){if(null===t.parentNode)return!1;t.parentNode.removeChild(t)}(i)};return a(t),function(e){if(e){if(e.css===t.css&&e.media===t.media&&e.sourceMap===t.sourceMap)return;a(t=e)}else s()}}t.exports=function(t,e){(e=e||{}).attributes="object"==o(e.attributes)?e.attributes:{},e.singleton||"boolean"==typeof e.singleton||(e.singleton=(void 0===a&&(a=Boolean(window&&document&&document.all&&!window.atob)),a));var i=r(t,e);return l(i,e),function(t){for(var a=[],n=0;n<i.length;n++){var o=i[n],c=s[o.id];c&&(c.refs--,a.push(c))}t&&l(r(t,e),e);for(var h=0;h<a.length;h++){var d=a[h];if(0===d.refs){for(var u=0;u<d.parts.length;u++)d.parts[u]();delete s[d.id]}}}}},function(t,e,i){"use strict";var a=this&&this.__assign||function(){return(a=Object.assign||function(t){for(var e,i=1,a=arguments.length;i<a;i++)for(var s in e=arguments[i])Object.prototype.hasOwnProperty.call(e,s)&&(t[s]=e[s]);return t}).apply(this,arguments)};Object.defineProperty(e,"__esModule",{value:!0});var s=i(0),n=i(1),r=i(2);n.Litepicker.prototype.show=function(t){void 0===t&&(t=null),this.emit("before:show",t);var e=t||this.options.element;if(this.triggerElement=e,!this.isShowning()){if(this.options.inlineMode)return this.ui.style.position="relative",this.ui.style.display="inline-block",this.ui.style.top=null,this.ui.style.left=null,this.ui.style.bottom=null,void(this.ui.style.right=null);this.scrollToDate(t),this.render(),this.ui.style.position="absolute",this.ui.style.display="block",this.ui.style.zIndex=this.options.zIndex;var i=this.findPosition(e);this.ui.style.top=i.top+"px",this.ui.style.left=i.left+"px",this.ui.style.right=null,this.ui.style.bottom=null,this.emit("show",t)}},n.Litepicker.prototype.hide=function(){this.isShowning()&&(this.datePicked.length=0,this.updateInput(),this.options.inlineMode?this.render():(this.ui.style.display="none",this.emit("hide")))},n.Litepicker.prototype.getDate=function(){return this.getStartDate()},n.Litepicker.prototype.getStartDate=function(){return this.options.startDate?this.options.startDate.clone():null},n.Litepicker.prototype.getEndDate=function(){return this.options.endDate?this.options.endDate.clone():null},n.Litepicker.prototype.setDate=function(t,e){void 0===e&&(e=!1);var i=new s.DateTime(t,this.options.format,this.options.lang);r.dateIsLocked(i,this.options,[i])&&!e?this.emit("error:date",i):(this.setStartDate(t),this.options.inlineMode&&this.render(),this.emit("selected",this.getDate()))},n.Litepicker.prototype.setStartDate=function(t){t&&(this.options.startDate=new s.DateTime(t,this.options.format,this.options.lang),this.updateInput())},n.Litepicker.prototype.setEndDate=function(t){t&&(this.options.endDate=new s.DateTime(t,this.options.format,this.options.lang),this.options.startDate.getTime()>this.options.endDate.getTime()&&(this.options.endDate=this.options.startDate.clone(),this.options.startDate=new s.DateTime(t,this.options.format,this.options.lang)),this.updateInput())},n.Litepicker.prototype.setDateRange=function(t,e,i){void 0===i&&(i=!1),this.triggerElement=void 0;var a=new s.DateTime(t,this.options.format,this.options.lang),n=new s.DateTime(e,this.options.format,this.options.lang);(this.options.disallowLockDaysInRange?r.rangeIsLocked([a,n],this.options):r.dateIsLocked(a,this.options,[a,n])||r.dateIsLocked(n,this.options,[a,n]))&&!i?this.emit("error:range",[a,n]):(this.setStartDate(a),this.setEndDate(n),this.options.inlineMode&&this.render(),this.updateInput(),this.emit("selected",this.getStartDate(),this.getEndDate()))},n.Litepicker.prototype.gotoDate=function(t,e){void 0===e&&(e=0);var i=new s.DateTime(t);i.setDate(1),this.calendars[e]=i.clone(),this.render()},n.Litepicker.prototype.setLockDays=function(t){this.options.lockDays=s.DateTime.convertArray(t,this.options.lockDaysFormat),this.render()},n.Litepicker.prototype.setHighlightedDays=function(t){this.options.highlightedDays=s.DateTime.convertArray(t,this.options.highlightedDaysFormat),this.render()},n.Litepicker.prototype.setOptions=function(t){delete t.element,delete t.elementEnd,delete t.parentEl,t.startDate&&(t.startDate=new s.DateTime(t.startDate,this.options.format,this.options.lang)),t.endDate&&(t.endDate=new s.DateTime(t.endDate,this.options.format,this.options.lang));var e=a(a({},this.options.dropdowns),t.dropdowns),i=a(a({},this.options.buttonText),t.buttonText),n=a(a({},this.options.tooltipText),t.tooltipText);this.options=a(a({},this.options),t),this.options.dropdowns=a({},e),this.options.buttonText=a({},i),this.options.tooltipText=a({},n),!this.options.singleMode||this.options.startDate instanceof s.DateTime||(this.options.startDate=null,this.options.endDate=null),this.options.singleMode||this.options.startDate instanceof s.DateTime&&this.options.endDate instanceof s.DateTime||(this.options.startDate=null,this.options.endDate=null);for(var r=0;r<this.options.numberOfMonths;r+=1){var o=this.options.startDate?this.options.startDate.clone():new s.DateTime;o.setDate(1),o.setMonth(o.getMonth()+r),this.calendars[r]=o}this.options.lockDays.length&&(this.options.lockDays=s.DateTime.convertArray(this.options.lockDays,this.options.lockDaysFormat)),this.options.highlightedDays.length&&(this.options.highlightedDays=s.DateTime.convertArray(this.options.highlightedDays,this.options.highlightedDaysFormat)),this.render(),this.options.inlineMode&&this.show(),this.updateInput()},n.Litepicker.prototype.clearSelection=function(){this.options.startDate=null,this.options.endDate=null,this.datePicked.length=0,this.updateInput(),this.isShowning()&&this.render(),this.emit("clear:selection")},n.Litepicker.prototype.destroy=function(){this.ui&&this.ui.parentNode&&(this.ui.parentNode.removeChild(this.ui),this.ui=null),this.emit("destroy")}}])},"object"==o(e)&&"object"==o(t)?t.exports=r():(s=[],void 0===(n="function"==typeof(a=r)?a.apply(e,s):a)||(t.exports=n))}).call(this,i(19)(t))},,,function(t,e,i){"use strict";function a(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}i.d(e,"a",(function(){return a}))},function(t,e,i){"use strict";function a(t,e){for(var i=0;i<e.length;i++){var a=e[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(t,a.key,a)}}function s(t,e,i){return e&&a(t.prototype,e),i&&a(t,i),Object.defineProperty(t,"prototype",{writable:!1}),t}i.d(e,"a",(function(){return s}))},function(t,e,i){"use strict";function a(t){return(a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}i.d(e,"a",(function(){return a}))},function(t,e,i){"use strict";function a(){return(a=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var i=arguments[e];for(var a in i)Object.prototype.hasOwnProperty.call(i,a)&&(t[a]=i[a])}return t}).apply(this,arguments)}i.d(e,"a",(function(){return u}));var s,n=s||(s={});n.Pop="POP",n.Push="PUSH",n.Replace="REPLACE";var r=function(t){return t};function o(t){t.preventDefault(),t.returnValue=""}function l(){var t=[];return{get length(){return t.length},push:function(e){return t.push(e),function(){t=t.filter((function(t){return t!==e}))}},call:function(e){t.forEach((function(t){return t&&t(e)}))}}}function c(){return Math.random().toString(36).substr(2,8)}function h(t){var e=t.pathname;e=void 0===e?"/":e;var i=t.search;return i=void 0===i?"":i,t=void 0===(t=t.hash)?"":t,i&&"?"!==i&&(e+="?"===i.charAt(0)?i:"?"+i),t&&"#"!==t&&(e+="#"===t.charAt(0)?t:"#"+t),e}function d(t){var e={};if(t){var i=t.indexOf("#");0<=i&&(e.hash=t.substr(i),t=t.substr(0,i)),0<=(i=t.indexOf("?"))&&(e.search=t.substr(i),t=t.substr(0,i)),t&&(e.pathname=t)}return e}function u(t){function e(){var t=f.location,e=g.state||{};return[e.idx,r({pathname:t.pathname,search:t.search,hash:t.hash,state:e.usr||null,key:e.key||"default"})]}function i(t){return"string"==typeof t?t:h(t)}function n(t,e){return void 0===e&&(e=null),r(a({pathname:v.pathname,hash:"",search:""},"string"==typeof t?d(t):t,{state:e,key:c()}))}function u(t){m=t,t=e(),b=t[0],v=t[1],y.call({action:m,location:v})}function p(t){g.go(t)}void 0===t&&(t={});var f=void 0===(t=t.window)?document.defaultView:t,g=f.history,x=null;f.addEventListener("popstate",(function(){if(x)w.call(x),x=null;else{var t=s.Pop,i=e(),a=i[0];if(i=i[1],w.length){if(null!=a){var n=b-a;n&&(x={action:t,location:i,retry:function(){p(-1*n)}},p(n))}}else u(t)}}));var m=s.Pop,b=(t=e())[0],v=t[1],y=l(),w=l();return null==b&&(b=0,g.replaceState(a({},g.state,{idx:b}),"")),{get action(){return m},get location(){return v},createHref:i,push:function t(e,a){var r=s.Push,o=n(e,a);if(!w.length||(w.call({action:r,location:o,retry:function(){t(e,a)}}),0)){var l=[{usr:o.state,key:o.key,idx:b+1},i(o)];o=l[0],l=l[1];try{g.pushState(o,"",l)}catch(t){f.location.assign(l)}u(r)}},replace:function t(e,a){var r=s.Replace,o=n(e,a);w.length&&(w.call({action:r,location:o,retry:function(){t(e,a)}}),1)||(o=[{usr:o.state,key:o.key,idx:b},i(o)],g.replaceState(o[0],"",o[1]),u(r))},go:p,back:function(){p(-1)},forward:function(){p(1)},listen:function(t){return y.push(t)},block:function(t){var e=w.push(t);return 1===w.length&&f.addEventListener("beforeunload",o),function(){e(),w.length||f.removeEventListener("beforeunload",o)}}}}},function(t,e,i){"use strict";function a(t,e){return(a=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function s(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");Object.defineProperty(t,"prototype",{value:Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),writable:!1}),e&&a(t,e)}i.d(e,"a",(function(){return s}))},function(t,e,i){"use strict";i.d(e,"a",(function(){return n}));var a=i(15),s=i.n(a);function n(t,e){if(e&&("object"===s()(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}},,function(t,e,i){var a="prestoPlayerdist".replace(/[^a-zA-Z0-9_-]/g,"");i.p=window["__wpackIo".concat(a)]},function(t,e,i){(function(t){var e=i(7),a=function(t){"use strict";var i=Object.prototype,a=i.hasOwnProperty,s="function"==typeof Symbol?Symbol:{},n=s.iterator||"@@iterator",r=s.asyncIterator||"@@asyncIterator",o=s.toStringTag||"@@toStringTag";function l(t,e,i){return Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{l({},"")}catch(t){l=function(t,e,i){return t[e]=i}}function c(t,e,i,a){var s=e&&e.prototype instanceof u?e:u,n=Object.create(s.prototype),r=new S(a||[]);return n._invoke=function(t,e,i){var a="suspendedStart";return function(s,n){if("executing"===a)throw new Error("Generator is already running");if("completed"===a){if("throw"===s)throw n;return L()}for(i.method=s,i.arg=n;;){var r=i.delegate;if(r){var o=w(r,i);if(o){if(o===d)continue;return o}}if("next"===i.method)i.sent=i._sent=i.arg;else if("throw"===i.method){if("suspendedStart"===a)throw a="completed",i.arg;i.dispatchException(i.arg)}else"return"===i.method&&i.abrupt("return",i.arg);a="executing";var l=h(t,e,i);if("normal"===l.type){if(a=i.done?"completed":"suspendedYield",l.arg===d)continue;return{value:l.arg,done:i.done}}"throw"===l.type&&(a="completed",i.method="throw",i.arg=l.arg)}}}(t,i,r),n}function h(t,e,i){try{return{type:"normal",arg:t.call(e,i)}}catch(t){return{type:"throw",arg:t}}}t.wrap=c;var d={};function u(){}function p(){}function f(){}var g={};l(g,n,(function(){return this}));var x=Object.getPrototypeOf,m=x&&x(x(C([])));m&&m!==i&&a.call(m,n)&&(g=m);var b=f.prototype=u.prototype=Object.create(g);function v(t){["next","throw","return"].forEach((function(e){l(t,e,(function(t){return this._invoke(e,t)}))}))}function y(t,i){var s;this._invoke=function(n,r){function o(){return new i((function(s,o){!function s(n,r,o,l){var c=h(t[n],t,r);if("throw"!==c.type){var d=c.arg,u=d.value;return u&&"object"===e(u)&&a.call(u,"__await")?i.resolve(u.__await).then((function(t){s("next",t,o,l)}),(function(t){s("throw",t,o,l)})):i.resolve(u).then((function(t){d.value=t,o(d)}),(function(t){return s("throw",t,o,l)}))}l(c.arg)}(n,r,s,o)}))}return s=s?s.then(o,o):o()}}function w(t,e){var i=t.iterator[e.method];if(void 0===i){if(e.delegate=null,"throw"===e.method){if(t.iterator.return&&(e.method="return",e.arg=void 0,w(t,e),"throw"===e.method))return d;e.method="throw",e.arg=new TypeError("The iterator does not provide a 'throw' method")}return d}var a=h(i,t.iterator,e.arg);if("throw"===a.type)return e.method="throw",e.arg=a.arg,e.delegate=null,d;var s=a.arg;return s?s.done?(e[t.resultName]=s.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,d):s:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,d)}function k(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function A(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function S(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(k,this),this.reset(!0)}function C(t){if(t){var e=t[n];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var i=-1,s=function e(){for(;++i<t.length;)if(a.call(t,i))return e.value=t[i],e.done=!1,e;return e.value=void 0,e.done=!0,e};return s.next=s}}return{next:L}}function L(){return{value:void 0,done:!0}}return p.prototype=f,l(b,"constructor",f),l(f,"constructor",p),p.displayName=l(f,o,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===p||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,f):(t.__proto__=f,l(t,o,"GeneratorFunction")),t.prototype=Object.create(b),t},t.awrap=function(t){return{__await:t}},v(y.prototype),l(y.prototype,r,(function(){return this})),t.AsyncIterator=y,t.async=function(e,i,a,s,n){void 0===n&&(n=Promise);var r=new y(c(e,i,a,s),n);return t.isGeneratorFunction(i)?r:r.next().then((function(t){return t.done?t.value:r.next()}))},v(b),l(b,o,"Generator"),l(b,n,(function(){return this})),l(b,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e=[];for(var i in t)e.push(i);return e.reverse(),function i(){for(;e.length;){var a=e.pop();if(a in t)return i.value=a,i.done=!1,i}return i.done=!0,i}},t.values=C,S.prototype={constructor:S,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(A),!t)for(var e in this)"t"===e.charAt(0)&&a.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function i(i,a){return r.type="throw",r.arg=t,e.next=i,a&&(e.method="next",e.arg=void 0),!!a}for(var s=this.tryEntries.length-1;s>=0;--s){var n=this.tryEntries[s],r=n.completion;if("root"===n.tryLoc)return i("end");if(n.tryLoc<=this.prev){var o=a.call(n,"catchLoc"),l=a.call(n,"finallyLoc");if(o&&l){if(this.prev<n.catchLoc)return i(n.catchLoc,!0);if(this.prev<n.finallyLoc)return i(n.finallyLoc)}else if(o){if(this.prev<n.catchLoc)return i(n.catchLoc,!0)}else{if(!l)throw new Error("try statement without catch or finally");if(this.prev<n.finallyLoc)return i(n.finallyLoc)}}}},abrupt:function(t,e){for(var i=this.tryEntries.length-1;i>=0;--i){var s=this.tryEntries[i];if(s.tryLoc<=this.prev&&a.call(s,"finallyLoc")&&this.prev<s.finallyLoc){var n=s;break}}n&&("break"===t||"continue"===t)&&n.tryLoc<=e&&e<=n.finallyLoc&&(n=null);var r=n?n.completion:{};return r.type=t,r.arg=e,n?(this.method="next",this.next=n.finallyLoc,d):this.complete(r)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),d},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var i=this.tryEntries[e];if(i.finallyLoc===t)return this.complete(i.completion,i.afterLoc),A(i),d}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var i=this.tryEntries[e];if(i.tryLoc===t){var a=i.completion;if("throw"===a.type){var s=a.arg;A(i)}return s}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,i){return this.delegate={iterator:C(t),resultName:e,nextLoc:i},"next"===this.method&&(this.arg=void 0),d}},t}("object"===e(t)?t.exports:{});try{regeneratorRuntime=a}catch(t){"object"===("undefined"==typeof globalThis?"undefined":e(globalThis))?globalThis.regeneratorRuntime=a:Function("r","regeneratorRuntime = r")(a)}}).call(this,i(19)(t))},function(t,e,i){"use strict";var a,s=i(7);
24
- /*!
25
- * ApexCharts v3.32.1
26
- * (c) 2018-2021 ApexCharts
27
- * Released under the MIT License.
28
- */function n(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),i.push.apply(i,a)}return i}function r(t){for(var e=1;e<arguments.length;e++){var i=null!=arguments[e]?arguments[e]:{};e%2?n(Object(i),!0).forEach((function(e){d(t,e,i[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):n(Object(i)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(i,e))}))}return t}function o(t){return(o="function"==typeof Symbol&&"symbol"==s(Symbol.iterator)?function(t){return s(t)}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":s(t)})(t)}function l(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function c(t,e){for(var i=0;i<e.length;i++){var a=e[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(t,a.key,a)}}function h(t,e,i){return e&&c(t.prototype,e),i&&c(t,i),t}function d(t,e,i){return e in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}function u(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&function(t,e){(Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}(t,e)}function p(t){return(p=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function f(t,e){if(e&&("object"==s(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}function g(t){var e=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}();return function(){var i,a=p(t);if(e){var s=p(this).constructor;i=Reflect.construct(a,arguments,s)}else i=a.apply(this,arguments);return f(this,i)}}function x(t){return function(t){if(Array.isArray(t))return m(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||function(t,e){if(t){if("string"==typeof t)return m(t,e);var i=Object.prototype.toString.call(t).slice(8,-1);return"Object"===i&&t.constructor&&(i=t.constructor.name),"Map"===i||"Set"===i?Array.from(t):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?m(t,e):void 0}}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function m(t,e){(null==e||e>t.length)&&(e=t.length);for(var i=0,a=new Array(e);i<e;i++)a[i]=t[i];return a}var b=function(){function t(){l(this,t)}return h(t,[{key:"shadeRGBColor",value:function(t,e){var i=e.split(","),a=t<0?0:255,s=t<0?-1*t:t,n=parseInt(i[0].slice(4),10),r=parseInt(i[1],10),o=parseInt(i[2],10);return"rgb("+(Math.round((a-n)*s)+n)+","+(Math.round((a-r)*s)+r)+","+(Math.round((a-o)*s)+o)+")"}},{key:"shadeHexColor",value:function(t,e){var i=parseInt(e.slice(1),16),a=t<0?0:255,s=t<0?-1*t:t,n=i>>16,r=i>>8&255,o=255&i;return"#"+(16777216+65536*(Math.round((a-n)*s)+n)+256*(Math.round((a-r)*s)+r)+(Math.round((a-o)*s)+o)).toString(16).slice(1)}},{key:"shadeColor",value:function(e,i){return t.isColorHex(i)?this.shadeHexColor(e,i):this.shadeRGBColor(e,i)}}],[{key:"bind",value:function(t,e){return function(){return t.apply(e,arguments)}}},{key:"isObject",value:function(t){return t&&"object"===o(t)&&!Array.isArray(t)&&null!=t}},{key:"is",value:function(t,e){return Object.prototype.toString.call(e)==="[object "+t+"]"}},{key:"listToArray",value:function(t){var e,i=[];for(e=0;e<t.length;e++)i[e]=t[e];return i}},{key:"extend",value:function(t,e){var i=this;"function"!=typeof Object.assign&&(Object.assign=function(t){if(null==t)throw new TypeError("Cannot convert undefined or null to object");for(var e=Object(t),i=1;i<arguments.length;i++){var a=arguments[i];if(null!=a)for(var s in a)a.hasOwnProperty(s)&&(e[s]=a[s])}return e});var a=Object.assign({},t);return this.isObject(t)&&this.isObject(e)&&Object.keys(e).forEach((function(s){i.isObject(e[s])&&s in t?a[s]=i.extend(t[s],e[s]):Object.assign(a,d({},s,e[s]))})),a}},{key:"extendArray",value:function(e,i){var a=[];return e.map((function(e){a.push(t.extend(i,e))})),a}},{key:"monthMod",value:function(t){return t%12}},{key:"clone",value:function(e){if(t.is("Array",e)){for(var i=[],a=0;a<e.length;a++)i[a]=this.clone(e[a]);return i}if(t.is("Null",e))return null;if(t.is("Date",e))return e;if("object"===o(e)){var s={};for(var n in e)e.hasOwnProperty(n)&&(s[n]=this.clone(e[n]));return s}return e}},{key:"log10",value:function(t){return Math.log(t)/Math.LN10}},{key:"roundToBase10",value:function(t){return Math.pow(10,Math.floor(Math.log10(t)))}},{key:"roundToBase",value:function(t,e){return Math.pow(e,Math.floor(Math.log(t)/Math.log(e)))}},{key:"parseNumber",value:function(t){return null===t?t:parseFloat(t)}},{key:"randomId",value:function(){return(Math.random()+1).toString(36).substring(4)}},{key:"noExponents",value:function(t){var e=String(t).split(/[eE]/);if(1===e.length)return e[0];var i="",a=t<0?"-":"",s=e[0].replace(".",""),n=Number(e[1])+1;if(n<0){for(i=a+"0.";n++;)i+="0";return i+s.replace(/^-/,"")}for(n-=s.length;n--;)i+="0";return s+i}},{key:"getDimensions",value:function(t){var e=getComputedStyle(t,null),i=t.clientHeight,a=t.clientWidth;return i-=parseFloat(e.paddingTop)+parseFloat(e.paddingBottom),[a-=parseFloat(e.paddingLeft)+parseFloat(e.paddingRight),i]}},{key:"getBoundingClientRect",value:function(t){var e=t.getBoundingClientRect();return{top:e.top,right:e.right,bottom:e.bottom,left:e.left,width:t.clientWidth,height:t.clientHeight,x:e.left,y:e.top}}},{key:"getLargestStringFromArr",value:function(t){return t.reduce((function(t,e){return Array.isArray(e)&&(e=e.reduce((function(t,e){return t.length>e.length?t:e}))),t.length>e.length?t:e}),0)}},{key:"hexToRgba",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"#999999",e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:.6;"#"!==t.substring(0,1)&&(t="#999999");var i=t.replace("#","");i=i.match(new RegExp("(.{"+i.length/3+"})","g"));for(var a=0;a<i.length;a++)i[a]=parseInt(1===i[a].length?i[a]+i[a]:i[a],16);return void 0!==e&&i.push(e),"rgba("+i.join(",")+")"}},{key:"getOpacityFromRGBA",value:function(t){return parseFloat(t.replace(/^.*,(.+)\)/,"$1"))}},{key:"rgb2hex",value:function(t){return(t=t.match(/^rgba?[\s+]?\([\s+]?(\d+)[\s+]?,[\s+]?(\d+)[\s+]?,[\s+]?(\d+)[\s+]?/i))&&4===t.length?"#"+("0"+parseInt(t[1],10).toString(16)).slice(-2)+("0"+parseInt(t[2],10).toString(16)).slice(-2)+("0"+parseInt(t[3],10).toString(16)).slice(-2):""}},{key:"isColorHex",value:function(t){return/(^#[0-9A-F]{6}$)|(^#[0-9A-F]{3}$)|(^#[0-9A-F]{8}$)/i.test(t)}},{key:"getPolygonPos",value:function(t,e){for(var i=[],a=2*Math.PI/e,s=0;s<e;s++){var n={};n.x=t*Math.sin(s*a),n.y=-t*Math.cos(s*a),i.push(n)}return i}},{key:"polarToCartesian",value:function(t,e,i,a){var s=(a-90)*Math.PI/180;return{x:t+i*Math.cos(s),y:e+i*Math.sin(s)}}},{key:"escapeString",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"x",i=t.toString().slice();return i.replace(/[` ~!@#$%^&*()_|+\-=?;:'",.<>{}[\]\\/]/gi,e)}},{key:"negToZero",value:function(t){return t<0?0:t}},{key:"moveIndexInArray",value:function(t,e,i){if(i>=t.length)for(var a=i-t.length+1;a--;)t.push(void 0);return t.splice(i,0,t.splice(e,1)[0]),t}},{key:"extractNumber",value:function(t){return parseFloat(t.replace(/[^\d.]*/g,""))}},{key:"findAncestor",value:function(t,e){for(;(t=t.parentElement)&&!t.classList.contains(e););return t}},{key:"setELstyles",value:function(t,e){for(var i in e)e.hasOwnProperty(i)&&(t.style.key=e[i])}},{key:"isNumber",value:function(t){return!isNaN(t)&&parseFloat(Number(t))===t&&!isNaN(parseInt(t,10))}},{key:"isFloat",value:function(t){return Number(t)===t&&t%1!=0}},{key:"isSafari",value:function(){return/^((?!chrome|android).)*safari/i.test(navigator.userAgent)}},{key:"isFirefox",value:function(){return navigator.userAgent.toLowerCase().indexOf("firefox")>-1}},{key:"isIE11",value:function(){if(-1!==window.navigator.userAgent.indexOf("MSIE")||window.navigator.appVersion.indexOf("Trident/")>-1)return!0}},{key:"isIE",value:function(){var t=window.navigator.userAgent,e=t.indexOf("MSIE ");if(e>0)return parseInt(t.substring(e+5,t.indexOf(".",e)),10);if(t.indexOf("Trident/")>0){var i=t.indexOf("rv:");return parseInt(t.substring(i+3,t.indexOf(".",i)),10)}var a=t.indexOf("Edge/");return a>0&&parseInt(t.substring(a+5,t.indexOf(".",a)),10)}}]),t}(),v=function(){function t(e){l(this,t),this.ctx=e,this.w=e.w,this.setEasingFunctions()}return h(t,[{key:"setEasingFunctions",value:function(){var t;if(!this.w.globals.easing){switch(this.w.config.chart.animations.easing){case"linear":t="-";break;case"easein":t="<";break;case"easeout":t=">";break;case"easeinout":t="<>";break;case"swing":t=function(t){var e=1.70158;return(t-=1)*t*((e+1)*t+e)+1};break;case"bounce":t=function(t){return t<1/2.75?7.5625*t*t:t<2/2.75?7.5625*(t-=1.5/2.75)*t+.75:t<2.5/2.75?7.5625*(t-=2.25/2.75)*t+.9375:7.5625*(t-=2.625/2.75)*t+.984375};break;case"elastic":t=function(t){return t===!!t?t:Math.pow(2,-10*t)*Math.sin((t-.075)*(2*Math.PI)/.3)+1};break;default:t="<>"}this.w.globals.easing=t}}},{key:"animateLine",value:function(t,e,i,a){t.attr(e).animate(a).attr(i)}},{key:"animateMarker",value:function(t,e,i,a,s,n){e||(e=0),t.attr({r:e,width:e,height:e}).animate(a,s).attr({r:i,width:i.width,height:i.height}).afterAll((function(){n()}))}},{key:"animateCircle",value:function(t,e,i,a,s){t.attr({r:e.r,cx:e.cx,cy:e.cy}).animate(a,s).attr({r:i.r,cx:i.cx,cy:i.cy})}},{key:"animateRect",value:function(t,e,i,a,s){t.attr(e).animate(a).attr(i).afterAll((function(){return s()}))}},{key:"animatePathsGradually",value:function(t){var e=t.el,i=t.realIndex,a=t.j,s=t.fill,n=t.pathFrom,r=t.pathTo,o=t.speed,l=t.delay,c=this.w,h=0;c.config.chart.animations.animateGradually.enabled&&(h=c.config.chart.animations.animateGradually.delay),c.config.chart.animations.dynamicAnimation.enabled&&c.globals.dataChanged&&"bar"!==c.config.chart.type&&(h=0),this.morphSVG(e,i,a,"line"!==c.config.chart.type||c.globals.comboCharts?s:"stroke",n,r,o,l*h)}},{key:"showDelayedElements",value:function(){this.w.globals.delayedElements.forEach((function(t){t.el.classList.remove("apexcharts-element-hidden")}))}},{key:"animationCompleted",value:function(t){var e=this.w;e.globals.animationEnded||(e.globals.animationEnded=!0,this.showDelayedElements(),"function"==typeof e.config.chart.events.animationEnd&&e.config.chart.events.animationEnd(this.ctx,{el:t,w:e}))}},{key:"morphSVG",value:function(t,e,i,a,s,n,r,o){var l=this,c=this.w;s||(s=t.attr("pathFrom")),n||(n=t.attr("pathTo"));var h=function(t){return"radar"===c.config.chart.type&&(r=1),"M 0 ".concat(c.globals.gridHeight)};(!s||s.indexOf("undefined")>-1||s.indexOf("NaN")>-1)&&(s=h()),(!n||n.indexOf("undefined")>-1||n.indexOf("NaN")>-1)&&(n=h()),c.globals.shouldAnimate||(r=1),t.plot(s).animate(1,c.globals.easing,o).plot(s).animate(r,c.globals.easing,o).plot(n).afterAll((function(){b.isNumber(i)?i===c.globals.series[c.globals.maxValsInArrayIndex].length-2&&c.globals.shouldAnimate&&l.animationCompleted(t):"none"!==a&&c.globals.shouldAnimate&&(!c.globals.comboCharts&&e===c.globals.series.length-1||c.globals.comboCharts)&&l.animationCompleted(t),l.showDelayedElements()}))}}]),t}(),y=function(){function t(e){l(this,t),this.ctx=e,this.w=e.w}return h(t,[{key:"getDefaultFilter",value:function(t,e){var i=this.w;t.unfilter(!0),(new window.SVG.Filter).size("120%","180%","-5%","-40%"),"none"!==i.config.states.normal.filter?this.applyFilter(t,e,i.config.states.normal.filter.type,i.config.states.normal.filter.value):i.config.chart.dropShadow.enabled&&this.dropShadow(t,i.config.chart.dropShadow,e)}},{key:"addNormalFilter",value:function(t,e){var i=this.w;i.config.chart.dropShadow.enabled&&!t.node.classList.contains("apexcharts-marker")&&this.dropShadow(t,i.config.chart.dropShadow,e)}},{key:"addLightenFilter",value:function(t,e,i){var a=this,s=this.w,n=i.intensity;t.unfilter(!0),new window.SVG.Filter,t.filter((function(t){var i=s.config.chart.dropShadow;(i.enabled?a.addShadow(t,e,i):t).componentTransfer({rgb:{type:"linear",slope:1.5,intercept:n}})})),t.filterer.node.setAttribute("filterUnits","userSpaceOnUse"),this._scaleFilterSize(t.filterer.node)}},{key:"addDarkenFilter",value:function(t,e,i){var a=this,s=this.w,n=i.intensity;t.unfilter(!0),new window.SVG.Filter,t.filter((function(t){var i=s.config.chart.dropShadow;(i.enabled?a.addShadow(t,e,i):t).componentTransfer({rgb:{type:"linear",slope:n}})})),t.filterer.node.setAttribute("filterUnits","userSpaceOnUse"),this._scaleFilterSize(t.filterer.node)}},{key:"applyFilter",value:function(t,e,i){var a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:.5;switch(i){case"none":this.addNormalFilter(t,e);break;case"lighten":this.addLightenFilter(t,e,{intensity:a});break;case"darken":this.addDarkenFilter(t,e,{intensity:a})}}},{key:"addShadow",value:function(t,e,i){var a=i.blur,s=i.top,n=i.left,r=i.color,o=i.opacity,l=t.flood(Array.isArray(r)?r[e]:r,o).composite(t.sourceAlpha,"in").offset(n,s).gaussianBlur(a).merge(t.source);return t.blend(t.source,l)}},{key:"dropShadow",value:function(t,e){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,a=e.top,s=e.left,n=e.blur,r=e.color,o=e.opacity,l=e.noUserSpaceOnUse,c=this.w;return t.unfilter(!0),b.isIE()&&"radialBar"===c.config.chart.type||(r=Array.isArray(r)?r[i]:r,t.filter((function(t){var e;e=b.isSafari()||b.isFirefox()||b.isIE()?t.flood(r,o).composite(t.sourceAlpha,"in").offset(s,a).gaussianBlur(n):t.flood(r,o).composite(t.sourceAlpha,"in").offset(s,a).gaussianBlur(n).merge(t.source),t.blend(t.source,e)})),l||t.filterer.node.setAttribute("filterUnits","userSpaceOnUse"),this._scaleFilterSize(t.filterer.node)),t}},{key:"setSelectionFilter",value:function(t,e,i){var a=this.w;if(void 0!==a.globals.selectedDataPoints[e]&&a.globals.selectedDataPoints[e].indexOf(i)>-1){t.node.setAttribute("selected",!0);var s=a.config.states.active.filter;"none"!==s&&this.applyFilter(t,e,s.type,s.value)}}},{key:"_scaleFilterSize",value:function(t){!function(e){for(var i in e)e.hasOwnProperty(i)&&t.setAttribute(i,e[i])}({width:"200%",height:"200%",x:"-50%",y:"-50%"})}}]),t}(),w=function(){function t(e){l(this,t),this.ctx=e,this.w=e.w}return h(t,[{key:"drawLine",value:function(t,e,i,a){var s=arguments.length>4&&void 0!==arguments[4]?arguments[4]:"#a8a8a8",n=arguments.length>5&&void 0!==arguments[5]?arguments[5]:0,r=arguments.length>6&&void 0!==arguments[6]?arguments[6]:null,o=arguments.length>7&&void 0!==arguments[7]?arguments[7]:"butt",l=this.w,c=l.globals.dom.Paper.line().attr({x1:t,y1:e,x2:i,y2:a,stroke:s,"stroke-dasharray":n,"stroke-width":r,"stroke-linecap":o});return c}},{key:"drawRect",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,s=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0,n=arguments.length>5&&void 0!==arguments[5]?arguments[5]:"#fefefe",r=arguments.length>6&&void 0!==arguments[6]?arguments[6]:1,o=arguments.length>7&&void 0!==arguments[7]?arguments[7]:null,l=arguments.length>8&&void 0!==arguments[8]?arguments[8]:null,c=arguments.length>9&&void 0!==arguments[9]?arguments[9]:0,h=this.w,d=h.globals.dom.Paper.rect();return d.attr({x:t,y:e,width:i>0?i:0,height:a>0?a:0,rx:s,ry:s,opacity:r,"stroke-width":null!==o?o:0,stroke:null!==l?l:"none","stroke-dasharray":c}),d.node.setAttribute("fill",n),d}},{key:"drawPolygon",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"#e1e1e1",i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"none",s=this.w,n=s.globals.dom.Paper.polygon(t).attr({fill:a,stroke:e,"stroke-width":i});return n}},{key:"drawCircle",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,i=this.w;t<0&&(t=0);var a=i.globals.dom.Paper.circle(2*t);return null!==e&&a.attr(e),a}},{key:"drawPath",value:function(t){var e=t.d,i=void 0===e?"":e,a=t.stroke,s=void 0===a?"#a8a8a8":a,n=t.strokeWidth,r=void 0===n?1:n,o=t.fill,l=t.fillOpacity,c=void 0===l?1:l,h=t.strokeOpacity,d=void 0===h?1:h,u=t.classes,p=t.strokeLinecap,f=void 0===p?null:p,g=t.strokeDashArray,x=void 0===g?0:g,m=this.w;return null===f&&(f=m.config.stroke.lineCap),(i.indexOf("undefined")>-1||i.indexOf("NaN")>-1)&&(i="M 0 ".concat(m.globals.gridHeight)),m.globals.dom.Paper.path(i).attr({fill:o,"fill-opacity":c,stroke:s,"stroke-opacity":d,"stroke-linecap":f,"stroke-width":r,"stroke-dasharray":x,class:u})}},{key:"group",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,e=this.w,i=e.globals.dom.Paper.group();return null!==t&&i.attr(t),i}},{key:"move",value:function(t,e){return["M",t,e].join(" ")}},{key:"line",value:function(t,e){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,a=null;return null===i?a=["L",t,e].join(" "):"H"===i?a=["H",t].join(" "):"V"===i&&(a=["V",e].join(" ")),a}},{key:"curve",value:function(t,e,i,a,s,n){return["C",t,e,i,a,s,n].join(" ")}},{key:"quadraticCurve",value:function(t,e,i,a){return["Q",t,e,i,a].join(" ")}},{key:"arc",value:function(t,e,i,a,s,n,r){var o=arguments.length>7&&void 0!==arguments[7]&&arguments[7],l="A";o&&(l="a");var c=[l,t,e,i,a,s,n,r].join(" ");return c}},{key:"renderPaths",value:function(t){var e,i=t.j,a=t.realIndex,s=t.pathFrom,n=t.pathTo,o=t.stroke,l=t.strokeWidth,c=t.strokeLinecap,h=t.fill,d=t.animationDelay,u=t.initialSpeed,p=t.dataChangeSpeed,f=t.className,g=t.shouldClipToGrid,x=void 0===g||g,m=t.bindEventsOnPaths,b=void 0===m||m,w=t.drawShadow,k=void 0===w||w,A=this.w,S=new y(this.ctx),C=new v(this.ctx),L=this.w.config.chart.animations.enabled,P=L&&this.w.config.chart.animations.dynamicAnimation.enabled,T=!!(L&&!A.globals.resized||P&&A.globals.dataChanged&&A.globals.shouldAnimate);T?e=s:(e=n,A.globals.animationEnded=!0);var M,E=A.config.stroke.dashArray;M=Array.isArray(E)?E[a]:A.config.stroke.dashArray;var D=this.drawPath({d:e,stroke:o,strokeWidth:l,fill:h,fillOpacity:1,classes:f,strokeLinecap:c,strokeDashArray:M});if(D.attr("index",a),x&&D.attr({"clip-path":"url(#gridRectMask".concat(A.globals.cuid,")")}),"none"!==A.config.states.normal.filter.type)S.getDefaultFilter(D,a);else if(A.config.chart.dropShadow.enabled&&k&&(!A.config.chart.dropShadow.enabledOnSeries||A.config.chart.dropShadow.enabledOnSeries&&-1!==A.config.chart.dropShadow.enabledOnSeries.indexOf(a))){var I=A.config.chart.dropShadow;S.dropShadow(D,I,a)}b&&(D.node.addEventListener("mouseenter",this.pathMouseEnter.bind(this,D)),D.node.addEventListener("mouseleave",this.pathMouseLeave.bind(this,D)),D.node.addEventListener("mousedown",this.pathMouseDown.bind(this,D))),D.attr({pathTo:n,pathFrom:s});var O={el:D,j:i,realIndex:a,pathFrom:s,pathTo:n,fill:h,strokeWidth:l,delay:d};return!L||A.globals.resized||A.globals.dataChanged?!A.globals.resized&&A.globals.dataChanged||C.showDelayedElements():C.animatePathsGradually(r(r({},O),{},{speed:u})),A.globals.dataChanged&&P&&T&&C.animatePathsGradually(r(r({},O),{},{speed:p})),D}},{key:"drawPattern",value:function(t,e,i){var a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"#a8a8a8",s=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0,n=this.w,r=n.globals.dom.Paper.pattern(e,i,(function(n){"horizontalLines"===t?n.line(0,0,i,0).stroke({color:a,width:s+1}):"verticalLines"===t?n.line(0,0,0,e).stroke({color:a,width:s+1}):"slantedLines"===t?n.line(0,0,e,i).stroke({color:a,width:s}):"squares"===t?n.rect(e,i).fill("none").stroke({color:a,width:s}):"circles"===t&&n.circle(e).fill("none").stroke({color:a,width:s})}));return r}},{key:"drawGradient",value:function(t,e,i,a,s){var n,r=arguments.length>5&&void 0!==arguments[5]?arguments[5]:null,o=arguments.length>6&&void 0!==arguments[6]?arguments[6]:null,l=arguments.length>7&&void 0!==arguments[7]?arguments[7]:null,c=arguments.length>8&&void 0!==arguments[8]?arguments[8]:0,h=this.w;e.length<9&&0===e.indexOf("#")&&(e=b.hexToRgba(e,a)),i.length<9&&0===i.indexOf("#")&&(i=b.hexToRgba(i,s));var d=0,u=1,p=1,f=null;null!==o&&(d=void 0!==o[0]?o[0]/100:0,u=void 0!==o[1]?o[1]/100:1,p=void 0!==o[2]?o[2]/100:1,f=void 0!==o[3]?o[3]/100:null);var g=!("donut"!==h.config.chart.type&&"pie"!==h.config.chart.type&&"polarArea"!==h.config.chart.type&&"bubble"!==h.config.chart.type);if(n=null===l||0===l.length?h.globals.dom.Paper.gradient(g?"radial":"linear",(function(t){t.at(d,e,a),t.at(u,i,s),t.at(p,i,s),null!==f&&t.at(f,e,a)})):h.globals.dom.Paper.gradient(g?"radial":"linear",(function(t){(Array.isArray(l[c])?l[c]:l).forEach((function(e){t.at(e.offset/100,e.color,e.opacity)}))})),g){var x=h.globals.gridWidth/2,m=h.globals.gridHeight/2;"bubble"!==h.config.chart.type?n.attr({gradientUnits:"userSpaceOnUse",cx:x,cy:m,r:r}):n.attr({cx:.5,cy:.5,r:.8,fx:.2,fy:.2})}else"vertical"===t?n.from(0,0).to(0,1):"diagonal"===t?n.from(0,0).to(1,1):"horizontal"===t?n.from(0,1).to(1,1):"diagonal2"===t&&n.from(1,0).to(0,1);return n}},{key:"drawText",value:function(t){var e,i=t.x,a=t.y,s=t.text,n=t.textAnchor,r=t.fontSize,o=t.fontFamily,l=t.fontWeight,c=t.foreColor,h=t.opacity,d=t.cssClass,u=void 0===d?"":d,p=t.isPlainText,f=void 0===p||p,g=this.w;return void 0===s&&(s=""),n||(n="start"),c&&c.length||(c=g.config.chart.foreColor),o=o||g.config.chart.fontFamily,l=l||"regular",(e=Array.isArray(s)?g.globals.dom.Paper.text((function(t){for(var e=0;e<s.length;e++)0===e?t.tspan(s[e]):t.tspan(s[e]).newLine()})):f?g.globals.dom.Paper.plain(s):g.globals.dom.Paper.text((function(t){return t.tspan(s)}))).attr({x:i,y:a,"text-anchor":n,"dominant-baseline":"auto","font-size":r,"font-family":o,"font-weight":l,fill:c,class:"apexcharts-text "+u}),e.node.style.fontFamily=o,e.node.style.opacity=h,e}},{key:"drawMarker",value:function(t,e,i){t=t||0;var a=i.pSize||0,s=null;if("square"===i.shape||"rect"===i.shape){var n=void 0===i.pRadius?a/2:i.pRadius;null!==e&&a||(a=0,n=0);var r=1.2*a+n,o=this.drawRect(r,r,r,r,n);o.attr({x:t-r/2,y:e-r/2,cx:t,cy:e,class:i.class?i.class:"",fill:i.pointFillColor,"fill-opacity":i.pointFillOpacity?i.pointFillOpacity:1,stroke:i.pointStrokeColor,"stroke-width":i.pointStrokeWidth?i.pointStrokeWidth:0,"stroke-opacity":i.pointStrokeOpacity?i.pointStrokeOpacity:1}),s=o}else"circle"!==i.shape&&i.shape||(b.isNumber(e)||(a=0,e=0),s=this.drawCircle(a,{cx:t,cy:e,class:i.class?i.class:"",stroke:i.pointStrokeColor,fill:i.pointFillColor,"fill-opacity":i.pointFillOpacity?i.pointFillOpacity:1,"stroke-width":i.pointStrokeWidth?i.pointStrokeWidth:0,"stroke-opacity":i.pointStrokeOpacity?i.pointStrokeOpacity:1}));return s}},{key:"pathMouseEnter",value:function(t,e){var i=this.w,a=new y(this.ctx),s=parseInt(t.node.getAttribute("index"),10),n=parseInt(t.node.getAttribute("j"),10);if("function"==typeof i.config.chart.events.dataPointMouseEnter&&i.config.chart.events.dataPointMouseEnter(e,this.ctx,{seriesIndex:s,dataPointIndex:n,w:i}),this.ctx.events.fireEvent("dataPointMouseEnter",[e,this.ctx,{seriesIndex:s,dataPointIndex:n,w:i}]),("none"===i.config.states.active.filter.type||"true"!==t.node.getAttribute("selected"))&&"none"!==i.config.states.hover.filter.type&&!i.globals.isTouchDevice){var r=i.config.states.hover.filter;a.applyFilter(t,s,r.type,r.value)}}},{key:"pathMouseLeave",value:function(t,e){var i=this.w,a=new y(this.ctx),s=parseInt(t.node.getAttribute("index"),10),n=parseInt(t.node.getAttribute("j"),10);"function"==typeof i.config.chart.events.dataPointMouseLeave&&i.config.chart.events.dataPointMouseLeave(e,this.ctx,{seriesIndex:s,dataPointIndex:n,w:i}),this.ctx.events.fireEvent("dataPointMouseLeave",[e,this.ctx,{seriesIndex:s,dataPointIndex:n,w:i}]),"none"!==i.config.states.active.filter.type&&"true"===t.node.getAttribute("selected")||"none"!==i.config.states.hover.filter.type&&a.getDefaultFilter(t,s)}},{key:"pathMouseDown",value:function(t,e){var i=this.w,a=new y(this.ctx),s=parseInt(t.node.getAttribute("index"),10),n=parseInt(t.node.getAttribute("j"),10),r="false";if("true"===t.node.getAttribute("selected")){if(t.node.setAttribute("selected","false"),i.globals.selectedDataPoints[s].indexOf(n)>-1){var o=i.globals.selectedDataPoints[s].indexOf(n);i.globals.selectedDataPoints[s].splice(o,1)}}else{if(!i.config.states.active.allowMultipleDataPointsSelection&&i.globals.selectedDataPoints.length>0){i.globals.selectedDataPoints=[];var l=i.globals.dom.Paper.select(".apexcharts-series path").members,c=i.globals.dom.Paper.select(".apexcharts-series circle, .apexcharts-series rect").members,h=function(t){Array.prototype.forEach.call(t,(function(t){t.node.setAttribute("selected","false"),a.getDefaultFilter(t,s)}))};h(l),h(c)}t.node.setAttribute("selected","true"),r="true",void 0===i.globals.selectedDataPoints[s]&&(i.globals.selectedDataPoints[s]=[]),i.globals.selectedDataPoints[s].push(n)}if("true"===r){var d=i.config.states.active.filter;"none"!==d&&a.applyFilter(t,s,d.type,d.value)}else"none"!==i.config.states.active.filter.type&&a.getDefaultFilter(t,s);"function"==typeof i.config.chart.events.dataPointSelection&&i.config.chart.events.dataPointSelection(e,this.ctx,{selectedDataPoints:i.globals.selectedDataPoints,seriesIndex:s,dataPointIndex:n,w:i}),e&&this.ctx.events.fireEvent("dataPointSelection",[e,this.ctx,{selectedDataPoints:i.globals.selectedDataPoints,seriesIndex:s,dataPointIndex:n,w:i}])}},{key:"rotateAroundCenter",value:function(t){var e={};return t&&"function"==typeof t.getBBox&&(e=t.getBBox()),{x:e.x+e.width/2,y:e.y+e.height/2}}},{key:"getTextRects",value:function(t,e,i,a){var s=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],n=this.w,r=this.drawText({x:-200,y:-200,text:t,textAnchor:"start",fontSize:e,fontFamily:i,foreColor:"#fff",opacity:0});a&&r.attr("transform",a),n.globals.dom.Paper.add(r);var o=r.bbox();return s||(o=r.node.getBoundingClientRect()),r.remove(),{width:o.width,height:o.height}}},{key:"placeTextWithEllipsis",value:function(t,e,i){if("function"==typeof t.getComputedTextLength&&(t.textContent=e,e.length>0&&t.getComputedTextLength()>=i/1.1)){for(var a=e.length-3;a>0;a-=3)if(t.getSubStringLength(0,a)<=i/1.1)return void(t.textContent=e.substring(0,a)+"...");t.textContent="."}}}],[{key:"setAttrs",value:function(t,e){for(var i in e)e.hasOwnProperty(i)&&t.setAttribute(i,e[i])}}]),t}(),k=function(){function t(e){l(this,t),this.w=e.w,this.annoCtx=e}return h(t,[{key:"setOrientations",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,i=this.w;if("vertical"===t.label.orientation){var a=null!==e?e:0,s=i.globals.dom.baseEl.querySelector(".apexcharts-xaxis-annotations .apexcharts-xaxis-annotation-label[rel='".concat(a,"']"));if(null!==s){var n=s.getBoundingClientRect();s.setAttribute("x",parseFloat(s.getAttribute("x"))-n.height+4),"top"===t.label.position?s.setAttribute("y",parseFloat(s.getAttribute("y"))+n.width):s.setAttribute("y",parseFloat(s.getAttribute("y"))-n.width);var r=this.annoCtx.graphics.rotateAroundCenter(s),o=r.x,l=r.y;s.setAttribute("transform","rotate(-90 ".concat(o," ").concat(l,")"))}}}},{key:"addBackgroundToAnno",value:function(t,e){var i=this.w;if(!t||void 0===e.label.text||void 0!==e.label.text&&!String(e.label.text).trim())return null;var a=i.globals.dom.baseEl.querySelector(".apexcharts-grid").getBoundingClientRect(),s=t.getBoundingClientRect(),n=e.label.style.padding.left,r=e.label.style.padding.right,o=e.label.style.padding.top,l=e.label.style.padding.bottom;"vertical"===e.label.orientation&&(o=e.label.style.padding.left,l=e.label.style.padding.right,n=e.label.style.padding.top,r=e.label.style.padding.bottom);var c=s.left-a.left-n,h=s.top-a.top-o,d=this.annoCtx.graphics.drawRect(c-i.globals.barPadForNumericAxis,h,s.width+n+r,s.height+o+l,e.label.borderRadius,e.label.style.background,1,e.label.borderWidth,e.label.borderColor,0);return e.id&&d.node.classList.add(b.escapeString(e.id)),d}},{key:"annotationsBackground",value:function(){var t=this,e=this.w,i=function(i,a,s){var n=e.globals.dom.baseEl.querySelector(".apexcharts-".concat(s,"-annotations .apexcharts-").concat(s,"-annotation-label[rel='").concat(a,"']"));if(n){var r=n.parentNode,o=t.addBackgroundToAnno(n,i);o&&(r.insertBefore(o.node,n),i.label.mouseEnter&&o.node.addEventListener("mouseenter",i.label.mouseEnter.bind(t,i)),i.label.mouseLeave&&o.node.addEventListener("mouseleave",i.label.mouseLeave.bind(t,i)))}};e.config.annotations.xaxis.map((function(t,e){i(t,e,"xaxis")})),e.config.annotations.yaxis.map((function(t,e){i(t,e,"yaxis")})),e.config.annotations.points.map((function(t,e){i(t,e,"point")}))}},{key:"getStringX",value:function(t){var e=this.w,i=t;e.config.xaxis.convertedCatToNumeric&&e.globals.categoryLabels.length&&(t=e.globals.categoryLabels.indexOf(t)+1);var a=e.globals.labels.indexOf(t),s=e.globals.dom.baseEl.querySelector(".apexcharts-xaxis-texts-g text:nth-child("+(a+1)+")");return s&&(i=parseFloat(s.getAttribute("x"))),i}}]),t}(),A=function(){function t(e){l(this,t),this.w=e.w,this.annoCtx=e,this.invertAxis=this.annoCtx.invertAxis}return h(t,[{key:"addXaxisAnnotation",value:function(t,e,i){var a=this.w,s=this.invertAxis?a.globals.minY:a.globals.minX,n=this.invertAxis?a.globals.maxY:a.globals.maxX,r=this.invertAxis?a.globals.yRange[0]:a.globals.xRange,o=(t.x-s)/(r/a.globals.gridWidth);this.annoCtx.inversedReversedAxis&&(o=(n-t.x)/(r/a.globals.gridWidth));var l=t.label.text;"category"!==a.config.xaxis.type&&!a.config.xaxis.convertedCatToNumeric||this.invertAxis||a.globals.dataFormatXNumeric||(o=this.annoCtx.helpers.getStringX(t.x));var c=t.strokeDashArray;if(b.isNumber(o)){if(null===t.x2||void 0===t.x2){var h=this.annoCtx.graphics.drawLine(o+t.offsetX,0+t.offsetY,o+t.offsetX,a.globals.gridHeight+t.offsetY,t.borderColor,c,t.borderWidth);e.appendChild(h.node),t.id&&h.node.classList.add(t.id)}else{var d=(t.x2-s)/(r/a.globals.gridWidth);if(this.annoCtx.inversedReversedAxis&&(d=(n-t.x2)/(r/a.globals.gridWidth)),"category"!==a.config.xaxis.type&&!a.config.xaxis.convertedCatToNumeric||this.invertAxis||a.globals.dataFormatXNumeric||(d=this.annoCtx.helpers.getStringX(t.x2)),d<o){var u=o;o=d,d=u}var p=this.annoCtx.graphics.drawRect(o+t.offsetX,0+t.offsetY,d-o,a.globals.gridHeight+t.offsetY,0,t.fillColor,t.opacity,1,t.borderColor,c);p.node.classList.add("apexcharts-annotation-rect"),p.attr("clip-path","url(#gridRectMask".concat(a.globals.cuid,")")),e.appendChild(p.node),t.id&&p.node.classList.add(t.id)}var f="top"===t.label.position?4:a.globals.gridHeight,g=this.annoCtx.graphics.getTextRects(l,parseFloat(t.label.style.fontSize)),x=this.annoCtx.graphics.drawText({x:o+t.label.offsetX,y:f+t.label.offsetY-("vertical"===t.label.orientation?"top"===t.label.position?g.width/2-12:-g.width/2:0),text:l,textAnchor:t.label.textAnchor,fontSize:t.label.style.fontSize,fontFamily:t.label.style.fontFamily,fontWeight:t.label.style.fontWeight,foreColor:t.label.style.color,cssClass:"apexcharts-xaxis-annotation-label ".concat(t.label.style.cssClass," ").concat(t.id?t.id:"")});x.attr({rel:i}),e.appendChild(x.node),this.annoCtx.helpers.setOrientations(t,i)}}},{key:"drawXAxisAnnotations",value:function(){var t=this,e=this.w,i=this.annoCtx.graphics.group({class:"apexcharts-xaxis-annotations"});return e.config.annotations.xaxis.map((function(e,a){t.addXaxisAnnotation(e,i.node,a)})),i}}]),t}(),S=function(){function t(e){l(this,t),this.ctx=e,this.w=e.w}return h(t,[{key:"getStackedSeriesTotals",value:function(){var t=this.w,e=[];if(0===t.globals.series.length)return e;for(var i=0;i<t.globals.series[t.globals.maxValsInArrayIndex].length;i++){for(var a=0,s=0;s<t.globals.series.length;s++)void 0!==t.globals.series[s][i]&&(a+=t.globals.series[s][i]);e.push(a)}return t.globals.stackedSeriesTotals=e,e}},{key:"getSeriesTotalByIndex",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;return null===t?this.w.config.series.reduce((function(t,e){return t+e}),0):this.w.globals.series[t].reduce((function(t,e){return t+e}),0)}},{key:"isSeriesNull",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;return 0===(null===t?this.w.config.series.filter((function(t){return null!==t})):this.w.config.series[t].data.filter((function(t){return null!==t}))).length}},{key:"seriesHaveSameValues",value:function(t){return this.w.globals.series[t].every((function(t,e,i){return t===i[0]}))}},{key:"getCategoryLabels",value:function(t){var e=this.w,i=t.slice();return e.config.xaxis.convertedCatToNumeric&&(i=t.map((function(t,i){return e.config.xaxis.labels.formatter(t-e.globals.minX+1)}))),i}},{key:"getLargestSeries",value:function(){var t=this.w;t.globals.maxValsInArrayIndex=t.globals.series.map((function(t){return t.length})).indexOf(Math.max.apply(Math,t.globals.series.map((function(t){return t.length}))))}},{key:"getLargestMarkerSize",value:function(){var t=this.w,e=0;return t.globals.markers.size.forEach((function(t){e=Math.max(e,t)})),t.globals.markers.largestSize=e,e}},{key:"getSeriesTotals",value:function(){var t=this.w;t.globals.seriesTotals=t.globals.series.map((function(t,e){var i=0;if(Array.isArray(t))for(var a=0;a<t.length;a++)i+=t[a];else i+=t;return i}))}},{key:"getSeriesTotalsXRange",value:function(t,e){var i=this.w;return i.globals.series.map((function(a,s){for(var n=0,r=0;r<a.length;r++)i.globals.seriesX[s][r]>t&&i.globals.seriesX[s][r]<e&&(n+=a[r]);return n}))}},{key:"getPercentSeries",value:function(){var t=this.w;t.globals.seriesPercent=t.globals.series.map((function(e,i){var a=[];if(Array.isArray(e))for(var s=0;s<e.length;s++){var n=t.globals.stackedSeriesTotals[s],r=0;n&&(r=100*e[s]/n),a.push(r)}else{var o=100*e/t.globals.seriesTotals.reduce((function(t,e){return t+e}),0);a.push(o)}return a}))}},{key:"getCalculatedRatios",value:function(){var t,e,i,a,s=this.w.globals,n=[],r=0,o=[],l=.1,c=0;if(s.yRange=[],s.isMultipleYAxis)for(var h=0;h<s.minYArr.length;h++)s.yRange.push(Math.abs(s.minYArr[h]-s.maxYArr[h])),o.push(0);else s.yRange.push(Math.abs(s.minY-s.maxY));s.xRange=Math.abs(s.maxX-s.minX),s.zRange=Math.abs(s.maxZ-s.minZ);for(var d=0;d<s.yRange.length;d++)n.push(s.yRange[d]/s.gridHeight);if(e=s.xRange/s.gridWidth,i=Math.abs(s.initialMaxX-s.initialMinX)/s.gridWidth,t=s.yRange/s.gridWidth,a=s.xRange/s.gridHeight,(r=s.zRange/s.gridHeight*16)||(r=1),s.minY!==Number.MIN_VALUE&&0!==Math.abs(s.minY)&&(s.hasNegs=!0),s.isMultipleYAxis){o=[];for(var u=0;u<n.length;u++)o.push(-s.minYArr[u]/n[u])}else o.push(-s.minY/n[0]),s.minY!==Number.MIN_VALUE&&0!==Math.abs(s.minY)&&(l=-s.minY/t,c=s.minX/e);return{yRatio:n,invertedYRatio:t,zRatio:r,xRatio:e,initialXRatio:i,invertedXRatio:a,baseLineInvertedY:l,baseLineY:o,baseLineX:c}}},{key:"getLogSeries",value:function(t){var e=this,i=this.w;return i.globals.seriesLog=t.map((function(t,a){return i.config.yaxis[a]&&i.config.yaxis[a].logarithmic?t.map((function(t){return null===t?null:e.getLogVal(t,a)})):t})),i.globals.invalidLogScale?t:i.globals.seriesLog}},{key:"getLogVal",value:function(t,e){var i=this.w,a=(Math.log(t)-Math.log(i.globals.minYArr[e]))/(Math.log(i.globals.maxYArr[e])-Math.log(i.globals.minYArr[e]));return isNaN(a)?t:a}},{key:"getLogYRatios",value:function(t){var e=this,i=this.w,a=this.w.globals;return a.yLogRatio=t.slice(),a.logYRange=a.yRange.map((function(t,s){if(i.config.yaxis[s]&&e.w.config.yaxis[s].logarithmic){var n,r=-Number.MAX_VALUE,o=Number.MIN_VALUE;return a.seriesLog.forEach((function(t,e){t.forEach((function(t){i.config.yaxis[e]&&i.config.yaxis[e].logarithmic&&(r=Math.max(t,r),o=Math.min(t,o))}))})),n=Math.pow(a.yRange[s],Math.abs(o-r)/a.yRange[s]),a.yLogRatio[s]=n/a.gridHeight,n}})),a.invalidLogScale?t.slice():a.yLogRatio}}],[{key:"checkComboSeries",value:function(t){var e=!1,i=0,a=0;return t.length&&void 0!==t[0].type&&t.forEach((function(t){"bar"!==t.type&&"column"!==t.type&&"candlestick"!==t.type&&"boxPlot"!==t.type||i++,void 0!==t.type&&a++})),a>0&&(e=!0),{comboBarCount:i,comboCharts:e}}},{key:"extendArrayProps",value:function(t,e,i){return e.yaxis&&(e=t.extendYAxis(e,i)),e.annotations&&(e.annotations.yaxis&&(e=t.extendYAxisAnnotations(e)),e.annotations.xaxis&&(e=t.extendXAxisAnnotations(e)),e.annotations.points&&(e=t.extendPointAnnotations(e))),e}}]),t}(),C=function(){function t(e){l(this,t),this.w=e.w,this.annoCtx=e}return h(t,[{key:"addYaxisAnnotation",value:function(t,e,i){var a,s=this.w,n=t.strokeDashArray,r=this._getY1Y2("y1",t),o=t.label.text;if(null===t.y2||void 0===t.y2){var l=this.annoCtx.graphics.drawLine(0+t.offsetX,r+t.offsetY,this._getYAxisAnnotationWidth(t),r+t.offsetY,t.borderColor,n,t.borderWidth);e.appendChild(l.node),t.id&&l.node.classList.add(t.id)}else{if((a=this._getY1Y2("y2",t))>r){var c=r;r=a,a=c}var h=this.annoCtx.graphics.drawRect(0+t.offsetX,a+t.offsetY,this._getYAxisAnnotationWidth(t),r-a,0,t.fillColor,t.opacity,1,t.borderColor,n);h.node.classList.add("apexcharts-annotation-rect"),h.attr("clip-path","url(#gridRectMask".concat(s.globals.cuid,")")),e.appendChild(h.node),t.id&&h.node.classList.add(t.id)}var d="right"===t.label.position?s.globals.gridWidth:0,u=this.annoCtx.graphics.drawText({x:d+t.label.offsetX,y:(null!=a?a:r)+t.label.offsetY-3,text:o,textAnchor:t.label.textAnchor,fontSize:t.label.style.fontSize,fontFamily:t.label.style.fontFamily,fontWeight:t.label.style.fontWeight,foreColor:t.label.style.color,cssClass:"apexcharts-yaxis-annotation-label ".concat(t.label.style.cssClass," ").concat(t.id?t.id:"")});u.attr({rel:i}),e.appendChild(u.node)}},{key:"_getY1Y2",value:function(t,e){var i,a="y1"===t?e.y:e.y2,s=this.w;if(this.annoCtx.invertAxis){var n=s.globals.labels.indexOf(a);s.config.xaxis.convertedCatToNumeric&&(n=s.globals.categoryLabels.indexOf(a));var r=s.globals.dom.baseEl.querySelector(".apexcharts-yaxis-texts-g text:nth-child("+(n+1)+")");r&&(i=parseFloat(r.getAttribute("y")))}else{var o;o=s.config.yaxis[e.yAxisIndex].logarithmic?(a=new S(this.annoCtx.ctx).getLogVal(a,e.yAxisIndex))/s.globals.yLogRatio[e.yAxisIndex]:(a-s.globals.minYArr[e.yAxisIndex])/(s.globals.yRange[e.yAxisIndex]/s.globals.gridHeight),i=s.globals.gridHeight-o,s.config.yaxis[e.yAxisIndex]&&s.config.yaxis[e.yAxisIndex].reversed&&(i=o)}return i}},{key:"_getYAxisAnnotationWidth",value:function(t){var e=this.w;return e.globals.gridWidth,(t.width.indexOf("%")>-1?e.globals.gridWidth*parseInt(t.width,10)/100:parseInt(t.width,10))+t.offsetX}},{key:"drawYAxisAnnotations",value:function(){var t=this,e=this.w,i=this.annoCtx.graphics.group({class:"apexcharts-yaxis-annotations"});return e.config.annotations.yaxis.map((function(e,a){t.addYaxisAnnotation(e,i.node,a)})),i}}]),t}(),L=function(){function t(e){l(this,t),this.w=e.w,this.annoCtx=e}return h(t,[{key:"addPointAnnotation",value:function(t,e,i){var a=this.w,s=0,n=0