handsontable 0.34.1 → 0.34.5
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of handsontable might be problematic. Click here for more details.
- package/.travis.yml +2 -0
- package/README.md +127 -96
- package/commonjs/core.js +11 -6
- package/commonjs/helpers/dom/element.js +4 -3
- package/commonjs/helpers/mixed.js +8 -4
- package/commonjs/index.js +5 -4
- package/commonjs/pluginHooks.js +18 -2
- package/commonjs/plugins/copyPaste/clipboardData.js +31 -0
- package/commonjs/plugins/copyPaste/contextMenuItem/copy.js +1 -2
- package/commonjs/plugins/copyPaste/contextMenuItem/cut.js +1 -2
- package/commonjs/plugins/copyPaste/copyPaste.js +127 -134
- package/commonjs/plugins/copyPaste/pasteEvent.js +19 -0
- package/commonjs/plugins/copyPaste/test/copyPaste.e2e.js +90 -189
- package/commonjs/plugins/copyPaste/test/textarea.unit.js +2 -2
- package/commonjs/plugins/copyPaste/textarea.js +2 -1
- package/commonjs/plugins/manualColumnMove/manualColumnMove.js +8 -11
- package/commonjs/plugins/manualColumnMove/test/manualColumnMoveUI.e2e.js +35 -0
- package/commonjs/plugins/manualRowMove/manualRowMove.js +9 -12
- package/commonjs/plugins/manualRowMove/test/manualRowMove.e2e.js +256 -60
- package/commonjs/plugins/manualRowMove/test/manualRowMoveUI.e2e.js +40 -182
- package/commonjs/plugins/manualRowMove/ui/_base.js +2 -2
- package/commonjs/tableView.js +1 -0
- package/dist/handsontable.css +6 -5
- package/dist/handsontable.css.map +1 -1
- package/dist/handsontable.full.css +6 -5
- package/dist/handsontable.full.js +37721 -42290
- package/dist/handsontable.full.min.css +4 -4
- package/dist/handsontable.full.min.js +5 -5
- package/dist/handsontable.js +28732 -28433
- package/dist/handsontable.js.map +1 -1
- package/dist/handsontable.min.css +4 -4
- package/dist/handsontable.min.js +3 -3
- package/es/core.js +11 -6
- package/es/helpers/dom/element.js +4 -3
- package/es/helpers/mixed.js +4 -4
- package/es/index.js +3 -4
- package/es/pluginHooks.js +18 -2
- package/es/plugins/copyPaste/clipboardData.js +27 -0
- package/es/plugins/copyPaste/contextMenuItem/copy.js +1 -2
- package/es/plugins/copyPaste/contextMenuItem/cut.js +1 -2
- package/es/plugins/copyPaste/copyPaste.js +124 -132
- package/es/plugins/copyPaste/pasteEvent.js +11 -0
- package/es/plugins/copyPaste/test/copyPaste.e2e.js +90 -189
- package/es/plugins/copyPaste/test/textarea.unit.js +2 -2
- package/es/plugins/copyPaste/textarea.js +2 -1
- package/es/plugins/manualColumnMove/manualColumnMove.js +8 -11
- package/es/plugins/manualColumnMove/test/manualColumnMoveUI.e2e.js +35 -0
- package/es/plugins/manualRowMove/manualRowMove.js +9 -12
- package/es/plugins/manualRowMove/test/manualRowMove.e2e.js +256 -60
- package/es/plugins/manualRowMove/test/manualRowMoveUI.e2e.js +40 -182
- package/es/plugins/manualRowMove/ui/_base.js +2 -2
- package/es/tableView.js +1 -0
- package/handsontable.jquery.json +1 -1
- package/hot.config.js +1 -1
- package/package.json +5 -5
- package/src/3rdparty/walkontable/dist/walkontable.js +27234 -11175
- package/src/3rdparty/walkontable/dist/walkontable.js.map +1 -1
- package/src/3rdparty/walkontable/test/dist/helpers.entry.js +32 -36
- package/src/3rdparty/walkontable/test/dist/helpers.entry.js.map +1 -1
- package/src/3rdparty/walkontable/test/dist/specs.entry.js +36 -39
- package/src/3rdparty/walkontable/test/dist/specs.entry.js.map +1 -1
- package/src/core.js +11 -6
- package/src/css/handsontable.css +1 -2
- package/src/helpers/dom/element.js +4 -3
- package/src/helpers/mixed.js +3 -3
- package/src/index.js +1 -2
- package/src/pluginHooks.js +18 -2
- package/src/plugins/copyPaste/clipboardData.js +11 -0
- package/src/plugins/copyPaste/contextMenuItem/copy.js +1 -2
- package/src/plugins/copyPaste/contextMenuItem/cut.js +1 -2
- package/src/plugins/copyPaste/copyPaste.css +3 -1
- package/src/plugins/copyPaste/copyPaste.js +120 -127
- package/src/plugins/copyPaste/pasteEvent.js +7 -0
- package/src/plugins/copyPaste/test/copyPaste.e2e.js +75 -193
- package/src/plugins/copyPaste/test/textarea.unit.js +2 -2
- package/src/plugins/copyPaste/textarea.js +2 -1
- package/src/plugins/manualColumnMove/manualColumnMove.js +6 -9
- package/src/plugins/manualColumnMove/test/manualColumnMoveUI.e2e.js +35 -0
- package/src/plugins/manualRowMove/manualRowMove.js +7 -10
- package/src/plugins/manualRowMove/test/manualRowMove.e2e.js +282 -86
- package/src/plugins/manualRowMove/test/manualRowMoveUI.e2e.js +51 -190
- package/src/plugins/manualRowMove/ui/_base.js +2 -2
- package/test/dist/e2e.entry.js +31381 -31131
- package/test/dist/e2e.entry.js.map +1 -1
- package/test/dist/helpers.entry.js +16 -19
- package/test/dist/helpers.entry.js.map +1 -1
- package/test/e2e/Core_listen.spec.js +32 -0
- package/test/e2e/Core_selection.spec.js +1 -1
- package/test/e2e/Core_validate.spec.js +29 -0
- package/test/e2e/renderers/checkboxRenderer.spec.js +20 -7
- package/test/e2e/settings/fragmentSelection.spec.js +12 -9
- package/test/scripts/trigger-pro-tests.sh +41 -0
- package/yarn.lock +260 -208
- package/.npmignore +0 -19
- package/demo/bower_components/numbro/package.json +0 -63
package/dist/handsontable.min.js
CHANGED
@@ -23,7 +23,7 @@
|
|
23
23
|
* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
24
24
|
* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
25
25
|
*
|
26
|
-
* Version: 0.34.
|
27
|
-
* Release date:
|
26
|
+
* Version: 0.34.5
|
27
|
+
* Release date: 12/10/2017 (built at 12/10/2017 10:04:52)
|
28
28
|
*/
|
29
|
-
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("moment"),require("numbro"),require("pikaday")):"function"==typeof define&&define.amd?define("Handsontable",["moment","numbro","pikaday"],t):"object"==typeof exports?exports.Handsontable=t(require("moment"),require("numbro"),require("pikaday")):e.Handsontable=t(e.moment,e.numbro,e.Pikaday)}(this,function(e,t,o){return function(e){function t(n){if(o[n])return o[n].exports;var r=o[n]={i:n,l:!1,exports:{}};return e[n].call(r.exports,r,r.exports,t),r.l=!0,r.exports}var o={};return t.m=e,t.c=o,t.i=function(e){return e},t.d=function(e,o,n){t.o(e,o)||Object.defineProperty(e,o,{configurable:!1,enumerable:!0,get:n})},t.n=function(e){var o=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(o,"a",o),o},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=210)}([function(e,t,o){"use strict";function n(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,o=-1,n=null;null!=e;){if(o===t){n=e;break}e.host&&e.nodeType===Node.DOCUMENT_FRAGMENT_NODE?e=e.host:(o++,e=e.parentNode)}return n}function r(e,t,o){for(;null!=e&&e!==o;){if(e.nodeType===Node.ELEMENT_NODE&&(t.indexOf(e.nodeName)>-1||t.indexOf(e)>-1))return e;e=e.host&&e.nodeType===Node.DOCUMENT_FRAGMENT_NODE?e.host:e.parentNode}return null}function i(e,t,o){for(var n=[];e&&(e=r(e,t,o))&&(!o||o.contains(e));)n.push(e),e=e.host&&e.nodeType===Node.DOCUMENT_FRAGMENT_NODE?e.host:e.parentNode;var i=n.length;return i?n[i-1]:null}function s(e,t){var o=e.parentNode,n=[];for("string"==typeof t?n=Array.prototype.slice.call(document.querySelectorAll(t),0):n.push(t);null!=o;){if(n.indexOf(o)>-1)return!0;o=o.parentNode}return!1}function l(e){function t(e){return e.nodeType===Node.ELEMENT_NODE&&e.nodeName===n.toUpperCase()}var o,n="hot-table",r=!1;for(o=a(e);null!=o;){if(t(o)){r=!0;break}if(o.host&&o.nodeType===Node.DOCUMENT_FRAGMENT_NODE){if(r=t(o.host))break;o=o.host}o=o.parentNode}return r}function a(e){return"undefined"!=typeof Polymer&&"function"==typeof wrap?wrap(e):e}function u(e){return"undefined"!=typeof Polymer&&"function"==typeof unwrap?unwrap(e):e}function c(e){var t=0;if(e.previousSibling)for(;e=e.previousSibling;)++t;return t}function h(e,t){var o=document.querySelector(".ht_clone_"+e);return o?o.contains(t):null}function d(e){var t=0,o=[];if(!e||!e.length)return o;for(;e[t];)o.push(e[t]),t++;return o}function f(e,t){return q(e,t)}function p(e,t){return Q(e,t)}function g(e,t){return J(e,t)}function v(e,t){if(3===e.nodeType)t.removeChild(e);else if(["TABLE","THEAD","TBODY","TFOOT","TR"].indexOf(e.nodeName)>-1)for(var o=e.childNodes,n=o.length-1;n>=0;n--)v(o[n],e)}function m(e){for(var t;t=e.lastChild;)e.removeChild(t)}function y(e,t){re.test(t)?e.innerHTML=t:w(e,t)}function w(e,t){var o=e.firstChild;o&&3===o.nodeType&&null===o.nextSibling?ie?o.textContent=t:o.data=t:(m(e),e.appendChild(document.createTextNode(t)))}function C(e){for(var t=e;u(t)!==document.documentElement;){if(null===t)return!1;if(t.nodeType===Node.DOCUMENT_FRAGMENT_NODE){if(t.host){if(t.host.impl)return C(t.host.impl);if(t.host)return C(t.host);throw Error("Lost in Web Components world")}return!1}if("none"===t.style.display)return!1;t=t.parentNode}return!0}function b(e){var t,o,n,r,i;if(r=document.documentElement,(0,Z.hasCaptionProblem)()&&e.firstChild&&"CAPTION"===e.firstChild.nodeName)return i=e.getBoundingClientRect(),{top:i.top+(window.pageYOffset||r.scrollTop)-(r.clientTop||0),left:i.left+(window.pageXOffset||r.scrollLeft)-(r.clientLeft||0)};for(t=e.offsetLeft,o=e.offsetTop,n=e;(e=e.offsetParent)&&e!==document.body;)t+=e.offsetLeft,o+=e.offsetTop,n=e;return n&&"fixed"===n.style.position&&(t+=window.pageXOffset||r.scrollLeft,o+=window.pageYOffset||r.scrollTop),{left:t,top:o}}function S(){var e=window.scrollY;return void 0===e&&(e=document.documentElement.scrollTop),e}function E(){var e=window.scrollX;return void 0===e&&(e=document.documentElement.scrollLeft),e}function R(e){return e===window?S():e.scrollTop}function O(e){return e===window?E():e.scrollLeft}function k(e){for(var t,o,n,r=e.parentNode,i=["auto","scroll"],s="",l="",a="",u="";r&&r.style&&document.body!==r;){if(t=r.style.overflow,o=r.style.overflowX,n=r.style.overflowY,"scroll"==t||"scroll"==o||"scroll"==n)return r;if(window.getComputedStyle&&(s=window.getComputedStyle(r),l=s.getPropertyValue("overflow"),a=s.getPropertyValue("overflow-y"),u=s.getPropertyValue("overflow-x"),"scroll"===l||"scroll"===u||"scroll"===a))return r;if(r.scrollHeight>=r.clientHeight&&(-1!==i.indexOf(n)||-1!==i.indexOf(t)||-1!==i.indexOf(l)||-1!==i.indexOf(a)))return r;if(r.scrollWidth>=r.clientWidth&&(-1!==i.indexOf(o)||-1!==i.indexOf(t)||-1!==i.indexOf(l)||-1!==i.indexOf(u)))return r;r=r.parentNode}return window}function T(e){for(var t=e.parentNode;t&&t.style&&document.body!==t;){if("visible"!==t.style.overflow&&""!==t.style.overflow)return t;if(window.getComputedStyle){var o=window.getComputedStyle(t);if("visible"!==o.getPropertyValue("overflow")&&""!==o.getPropertyValue("overflow"))return t}t=t.parentNode}return window}function _(e,t){if(e){if(e!==window){var o,n=e.style[t];return""!==n&&void 0!==n?n:(o=M(e),""!==o[t]&&void 0!==o[t]?o[t]:void 0)}if("width"===t)return window.innerWidth+"px";if("height"===t)return window.innerHeight+"px"}}function M(e){return e.currentStyle||document.defaultView.getComputedStyle(e)}function H(e){return e.offsetWidth}function A(e){return(0,Z.hasCaptionProblem)()&&e.firstChild&&"CAPTION"===e.firstChild.nodeName?e.offsetHeight+e.firstChild.offsetHeight:e.offsetHeight}function P(e){return e.clientHeight||e.innerHeight}function x(e){return e.clientWidth||e.innerWidth}function D(e,t,o){window.addEventListener?e.addEventListener(t,o,!1):e.attachEvent("on"+t,o)}function L(e,t,o){window.removeEventListener?e.removeEventListener(t,o,!1):e.detachEvent("on"+t,o)}function N(e){if(e.selectionStart)return e.selectionStart;if(document.selection){e.focus();var t=document.selection.createRange();if(null==t)return 0;var o=e.createTextRange(),n=o.duplicate();return o.moveToBookmark(t.getBookmark()),n.setEndPoint("EndToStart",o),n.text.length}return 0}function I(e){if(e.selectionEnd)return e.selectionEnd;if(document.selection){var t=document.selection.createRange();if(null==t)return 0;return e.createTextRange().text.indexOf(t.text)+t.text.length}return 0}function j(){var e="";return window.getSelection?e=""+window.getSelection():document.selection&&"Control"!==document.selection.type&&(e=document.selection.createRange().text),e}function W(e,t,o){if(void 0===o&&(o=t),e.setSelectionRange){e.focus();try{e.setSelectionRange(t,o)}catch(i){var n=e.parentNode,r=n.style.display;n.style.display="block",e.setSelectionRange(t,o),n.style.display=r}}else if(e.createTextRange){var i=e.createTextRange();i.collapse(!0),i.moveEnd("character",o),i.moveStart("character",t),i.select()}}function B(){var e=document.createElement("div");e.style.height="200px",e.style.width="100%";var t=document.createElement("div");t.style.boxSizing="content-box",t.style.height="150px",t.style.left="0px",t.style.overflow="hidden",t.style.position="absolute",t.style.top="0px",t.style.width="200px",t.style.visibility="hidden",t.appendChild(e),(document.body||document.documentElement).appendChild(t);var o=e.offsetWidth;t.style.overflow="scroll";var n=e.offsetWidth;return o==n&&(n=t.clientWidth),(document.body||document.documentElement).removeChild(t),o-n}function F(){return void 0===ne&&(ne=B()),ne}function V(e){return e.offsetWidth!==e.clientWidth}function z(e){return e.offsetHeight!==e.clientHeight}function U(e,t,o){(0,$.isIE8)()||(0,$.isIE9)()?(e.style.top=o,e.style.left=t):(0,$.isSafari)()?e.style["-webkit-transform"]="translate3d("+t+","+o+",0)":e.style.transform="translate3d("+t+","+o+",0)"}function K(e){var t;return e.style.transform&&""!==(t=e.style.transform)?["transform",t]:e.style["-webkit-transform"]&&""!==(t=e.style["-webkit-transform"])?["-webkit-transform",t]:-1}function Y(e){e.style.transform&&""!==e.style.transform?e.style.transform="":e.style["-webkit-transform"]&&""!==e.style["-webkit-transform"]&&(e.style["-webkit-transform"]="")}function G(e){var t=["INPUT","SELECT","TEXTAREA"];return e&&(t.indexOf(e.nodeName)>-1||"true"===e.contentEditable)}function X(e){return G(e)&&-1==e.className.indexOf("handsontableInput")&&-1==e.className.indexOf("copyPaste")}t.__esModule=!0,t.HTML_CHARACTERS=void 0,t.getParent=n,t.closest=r,t.closestDown=i,t.isChildOf=s,t.isChildOfWebComponentTable=l,t.polymerWrap=a,t.polymerUnwrap=u,t.index=c,t.overlayContainsElement=h,t.hasClass=f,t.addClass=p,t.removeClass=g,t.removeTextNodes=v,t.empty=m,t.fastInnerHTML=y,t.fastInnerText=w,t.isVisible=C,t.offset=b,t.getWindowScrollTop=S,t.getWindowScrollLeft=E,t.getScrollTop=R,t.getScrollLeft=O,t.getScrollableElement=k,t.getTrimmingContainer=T,t.getStyle=_,t.getComputedStyle=M,t.outerWidth=H,t.outerHeight=A,t.innerHeight=P,t.innerWidth=x,t.addEvent=D,t.removeEvent=L,t.getCaretPosition=N,t.getSelectionEndPosition=I,t.getSelectionText=j,t.setCaretPosition=W,t.getScrollbarWidth=F,t.hasVerticalScrollbar=V,t.hasHorizontalScrollbar=z,t.setOverlayPosition=U,t.getCssTransform=K,t.resetCssTransform=Y,t.isInput=G,t.isOutsideInput=X;var q,Q,J,$=o(25),Z=o(34),ee=!!document.documentElement.classList;if(ee){var te=function(){var e=document.createElement("div");return e.classList.add("test","test2"),e.classList.contains("test2")}();q=function(e,t){return void 0!==e.classList&&""!==t&&e.classList.contains(t)},Q=function(e,t){var o=0;if("string"==typeof t&&(t=t.split(" ")),t=d(t),te)e.classList.add.apply(e.classList,t);else for(;t&&t[o];)e.classList.add(t[o]),o++},J=function(e,t){var o=0;if("string"==typeof t&&(t=t.split(" ")),t=d(t),te)e.classList.remove.apply(e.classList,t);else for(;t&&t[o];)e.classList.remove(t[o]),o++}}else{var oe=function(e){return RegExp("(\\s|^)"+e+"(\\s|$)")};q=function(e,t){return void 0!==e.className&&e.className.test(oe(t))},Q=function(e,t){var o=0,n=e.className;if("string"==typeof t&&(t=t.split(" ")),""===n)n=t.join(" ");else for(;t&&t[o];)oe(t[o]).test(n)||(n+=" "+t[o]),o++;e.className=n},J=function(e,t){var o=0,n=e.className;for("string"==typeof t&&(t=t.split(" "));t&&t[o];)n=n.replace(oe(t[o])," ").trim(),o++;e.className!==n&&(e.className=n)}}var ne,re=t.HTML_CHARACTERS=/(<(.*)>|&(.*);)/,ie=!!document.createTextNode("test").textContent},function(e,t,o){"use strict";function n(e,t,o){return t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o,e}function r(e){var t;return Array.isArray(e)?t=[]:(t={},p(e,function(e,o){"__children"!==o&&(t[o]=e&&"object"===(void 0===e?"undefined":w(e))&&!Array.isArray(e)?r(e):Array.isArray(e)?e.length&&"object"===w(e[0])&&!Array.isArray(e[0])?[r(e[0])]:[]:null)})),t}function i(e,t){return t.prototype.constructor=t,e.prototype=new t,e.prototype.constructor=e,e}function s(e,t){return p(t,function(t,o){e[o]=t}),e}function l(e,t){p(t,function(o,n){t[n]&&"object"===w(t[n])?(e[n]||(e[n]=Array.isArray(t[n])?[]:"[object Date]"===Object.prototype.toString.call(t[n])?t[n]:{}),l(e[n],t[n])):e[n]=t[n]})}function a(e){return"object"===(void 0===e?"undefined":w(e))?JSON.parse(JSON.stringify(e)):e}function u(e){var t={};return p(e,function(e,o){t[o]=e}),t}function c(e){e.MIXINS||(e.MIXINS=[]);for(var t=arguments.length,o=Array(t>1?t-1:0),n=1;t>n;n++)o[n-1]=arguments[n];return(0,C.arrayEach)(o,function(t){e.MIXINS.push(t.MIXIN_NAME),p(t,function(t,o){if(void 0!==e.prototype[o])throw Error("Mixin conflict. Property '"+o+"' already exist and cannot be overwritten.");if("function"==typeof t)e.prototype[o]=t;else{Object.defineProperty(e.prototype,o,{get:function(e,t){e="_"+e;var o=function(e){return(Array.isArray(e)||d(e))&&(e=a(e)),e};return function(){return void 0===this[e]&&(this[e]=o(t)),this[e]}}(o,t),set:function(e){return e="_"+e,function(t){this[e]=t}}(o),configurable:!0})}})}),e}function h(e,t){return JSON.stringify(e)===JSON.stringify(t)}function d(e){return"[object Object]"==Object.prototype.toString.call(e)}function f(e,t,o,n){n.value=o,n.writable=!1!==n.writable,n.enumerable=!1!==n.enumerable,n.configurable=!1!==n.configurable,Object.defineProperty(e,t,n)}function p(e,t){for(var o in e)if((!e.hasOwnProperty||e.hasOwnProperty&&Object.prototype.hasOwnProperty.call(e,o))&&!1===t(e[o],o,e))break;return e}function g(e,t){var o=t.split("."),n=e;return p(o,function(e){if(void 0===(n=n[e]))return n=void 0,!1}),n}function v(e){if(!d(e))return 0;return function e(t){var o=0;return d(t)?p(t,function(t){o+=e(t)}):o++,o}(e)}function m(e){var t,o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"value",r="_"+o,i=(t={_touched:!1},n(t,r,e),n(t,"isTouched",function(){return this._touched}),t);return Object.defineProperty(i,o,{get:function(){return this[r]},set:function(e){this._touched=!0,this[r]=e},enumerable:!0,configurable:!0}),i}function y(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.__esModule=!0;var w="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.duckSchema=r,t.inherit=i,t.extend=s,t.deepExtend=l,t.deepClone=a,t.clone=u,t.mixin=c,t.isObjectEquals=h,t.isObject=d,t.defineGetter=f,t.objectEach=p,t.getProperty=g,t.deepObjectSize=v,t.createObjectPropListener=m,t.hasOwnProperty=y;var C=o(2)},function(e,t,o){"use strict";function n(e){for(var t=0,o=e.length;o>t;)e[t]=[e[t]],t++}function r(e,t){for(var o=0,n=t.length;n>o;)e.push(t[o]),o++}function i(e){var t=[];if(!e||0===e.length||!e[0]||0===e[0].length)return t;for(var o=e.length,n=e[0].length,r=0;o>r;r++)for(var i=0;n>i;i++)t[i]||(t[i]=[]),t[i][r]=e[r][i];return t}function s(e,t,o,n){var r=-1,i=e.length;for(n&&i&&(o=e[++r]);++r<i;)o=t(o,e[r],r,e);return o}function l(e,t){for(var o=-1,n=e.length,r=-1,i=[];++o<n;){var s=e[o];t(s,o,e)&&(i[++r]=s)}return i}function a(e,t){for(var o=-1,n=e.length,r=-1,i=[];++o<n;){var s=e[o];i[++r]=t(s,o,e)}return i}function u(e,t){for(var o=-1,n=e.length;++o<n&&!1!==t(e[o],o,e););return e}function c(e){return s(e,function(e,t){return e+t},0)}function h(e){return s(e,function(e,t){return e>t?e:t},Array.isArray(e)?e[0]:void 0)}function d(e){return s(e,function(e,t){return t>e?e:t},Array.isArray(e)?e[0]:void 0)}function f(e){return e.length?c(e)/e.length:0}function p(e){return s(e,function(e,t){return e.concat(Array.isArray(t)?p(t):t)},[])}function g(e){var t=[];return u(e,function(e){-1===t.indexOf(e)&&t.push(e)}),t}t.__esModule=!0,t.to2dArray=n,t.extendArray=r,t.pivot=i,t.arrayReduce=s,t.arrayFilter=l,t.arrayMap=a,t.arrayEach=u,t.arraySum=c,t.arrayMax=h,t.arrayMin=d,t.arrayAvg=f,t.arrayFlatten=p,t.arrayUnique=g},function(e,t,o){var n=o(13),r=o(44),i=o(32),s=o(33),l=o(29),a=function(e,t,o){var u,c,h,d,f=e&a.F,p=e&a.G,g=e&a.S,v=e&a.P,m=e&a.B,y=p?n:g?n[t]||(n[t]={}):(n[t]||{}).prototype,w=p?r:r[t]||(r[t]={}),C=w.prototype||(w.prototype={});p&&(o=t);for(u in o)c=!f&&y&&void 0!==y[u],h=(c?y:o)[u],d=m&&c?l(h,n):v&&"function"==typeof h?l(Function.call,h):h,y&&s(y,u,h,e&a.U),w[u]!=h&&i(w,u,d),v&&C[u]!=h&&(C[u]=h)};n.core=r,a.F=1,a.G=2,a.S=4,a.P=8,a.B=16,a.W=32,a.U=64,a.R=128,e.exports=a},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){var o=void 0,n=void 0,r=void 0,i=void 0,s=void 0,h=void 0;if(t.isTargetWebComponent=!1,t.realTarget=t.target,h=t.stopImmediatePropagation,t.stopImmediatePropagation=function(){h.apply(this),(0,c.stopImmediatePropagation)(this)},!d.isHotTableEnv)return t;for(t=(0,l.polymerWrap)(t),s=t.path?t.path.length:0;s--;){if("HOT-TABLE"===t.path[s].nodeName)o=!0;else if(o&&t.path[s].shadowRoot){i=t.path[s];break}0!==s||i||(i=t.path[s])}return i||(i=t.target),t.isTargetWebComponent=!0,(0,u.isWebComponentSupportedNatively)()?t.realTarget=t.srcElement||t.toElement:((0,a.hasOwnProperty)(e,"hot")||e.isHotTableEnv||e.wtTable)&&((0,a.hasOwnProperty)(e,"hot")?n=e.hot?e.hot.view.wt.wtTable.TABLE:null:e.isHotTableEnv?n=e.view.activeWt.wtTable.TABLE.parentNode.parentNode:e.wtTable&&(n=e.wtTable.TABLE.parentNode.parentNode),r=(0,l.closest)(t.target,["HOT-TABLE"],n),t.realTarget=r?n.querySelector("HOT-TABLE")||t.target:t.target),Object.defineProperty(t,"target",{get:function(){return(0,l.polymerWrap)(i)},enumerable:!0,configurable:!0}),t}function i(){return h}t.__esModule=!0;var s=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}();t.getListenersCounter=i;var l=o(0),a=o(1),u=o(34),c=o(7),h=0,d=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;n(this,e),this.context=t||this,this.context.eventListeners||(this.context.eventListeners=[])}return s(e,[{key:"addEventListener",value:function(e,t,o){function n(e){e=r(s,e),o.call(this,e)}var i=this,s=this.context;return this.context.eventListeners.push({element:e,event:t,callback:o,callbackProxy:n}),window.addEventListener?e.addEventListener(t,n,!1):e.attachEvent("on"+t,n),h++,function(){i.removeEventListener(e,t,o)}}},{key:"removeEventListener",value:function(e,t,o){for(var n=this.context.eventListeners.length,r=void 0;n--;)if(r=this.context.eventListeners[n],r.event==t&&r.element==e){if(o&&o!=r.callback)continue;this.context.eventListeners.splice(n,1),r.element.removeEventListener?r.element.removeEventListener(r.event,r.callbackProxy,!1):r.element.detachEvent("on"+r.event,r.callbackProxy),h--}}},{key:"clearEvents",value:function(){if(this.context)for(var e=this.context.eventListeners.length;e--;){var t=this.context.eventListeners[e];t&&this.removeEventListener(t.element,t.event,t.callback)}}},{key:"clear",value:function(){this.clearEvents()}},{key:"destroy",value:function(){this.clearEvents(),this.context=null}},{key:"fireEvent",value:function(e,t){var o,n={bubbles:!0,cancelable:"mousemove"!==t,view:window,detail:0,screenX:0,screenY:0,clientX:1,clientY:1,ctrlKey:!1,altKey:!1,shiftKey:!1,metaKey:!1,button:0,relatedTarget:void 0};document.createEvent?(o=document.createEvent("MouseEvents"),o.initMouseEvent(t,n.bubbles,n.cancelable,n.view,n.detail,n.screenX,n.screenY,n.clientX,n.clientY,n.ctrlKey,n.altKey,n.shiftKey,n.metaKey,n.button,n.relatedTarget||document.body.parentNode)):o=document.createEventObject(),e.dispatchEvent?e.dispatchEvent(o):e.fireEvent("on"+t,o)}}]),e}();t.default=d},function(e,t,o){"use strict";function n(e,t){e=(0,c.toUpperCaseFirst)(e),a.default.getSingleton().add("construct",function(){var o=void 0;h.has(this)||h.set(this,{}),o=h.get(this),o[e]||(o[e]=new t(this))}),a.default.getSingleton().add("afterDestroy",function(){if(h.has(this)){var e=h.get(this);(0,u.objectEach)(e,function(e){return e.destroy()}),h.delete(this)}})}function r(e,t){if("string"!=typeof t)throw Error('Only strings can be passed as "plugin" parameter');var o=(0,c.toUpperCaseFirst)(t);if(h.has(e)&&h.get(e)[o])return h.get(e)[o]}function i(e){return h.has(e)?Object.keys(h.get(e)):[]}function s(e,t){var o=null;return h.has(e)&&(0,u.objectEach)(h.get(e),function(e,n){e===t&&(o=n)}),o}t.__esModule=!0,t.getPluginName=t.getRegistredPluginNames=t.getPlugin=t.registerPlugin=void 0;var l=o(8),a=function(e){return e&&e.__esModule?e:{default:e}}(l),u=o(1),c=o(27),h=new WeakMap;t.registerPlugin=n,t.getPlugin=r,t.getRegistredPluginNames=i,t.getPluginName=s},function(e,t,o){"use strict";function n(e){var t=void 0===e?"undefined":l(e);return"number"==t?!isNaN(e)&&isFinite(e):"string"==t?!!e.length&&(1==e.length?/\d/.test(e):/^\s*[+-]?\s*(?:(?:\d+(?:\.\d+)?(?:e[+-]?\d+)?)|(?:0x[a-f\d]+))\s*$/i.test(e)):"object"==t&&!(!e||"number"!=typeof e.valueOf()||e instanceof Date)}function r(e,t,o){var n=-1;for("function"==typeof t?(o=t,t=e):n=e-1;++n<=t&&!1!==o(n););}function i(e,t,o){var n=e+1;for("function"==typeof t&&(o=t,t=0);--n>=t&&!1!==o(n););}function s(e,t){return t=parseInt((""+t).replace("%",""),10),t=parseInt(e*t/100,10)}t.__esModule=!0;var l="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.isNumeric=n,t.rangeEach=r,t.rangeEachReverse=i,t.valueAccordingPercent=s},function(e,t,o){"use strict";function n(e){e.isImmediatePropagationEnabled=!1,e.cancelBubble=!0}function r(e){return!1===e.isImmediatePropagationEnabled}function i(e){"function"==typeof e.stopPropagation?e.stopPropagation():e.cancelBubble=!0}function s(e){return e.pageX?e.pageX:e.clientX+(0,c.getWindowScrollLeft)()}function l(e){return e.pageY?e.pageY:e.clientY+(0,c.getWindowScrollTop)()}function a(e){return 2===e.button}function u(e){return 0===e.button}t.__esModule=!0,t.stopImmediatePropagation=n,t.isImmediatePropagationStopped=r,t.stopPropagation=i,t.pageX=s,t.pageY=l,t.isRightClick=a,t.isLeftClick=u;var c=o(0)},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=o(2),s=o(1),l=["afterCellMetaReset","afterChange","afterChangesObserved","afterContextMenuDefaultOptions","beforeContextMenuSetItems","afterDropdownMenuDefaultOptions","beforeDropdownMenuSetItems","afterContextMenuHide","afterContextMenuShow","afterCopyLimit","beforeCreateCol","afterCreateCol","beforeCreateRow","afterCreateRow","afterDeselect","afterDestroy","afterDocumentKeyDown","afterGetCellMeta","afterGetColHeader","afterGetRowHeader","afterInit","afterLoadData","afterMomentumScroll","afterOnCellCornerMouseDown","afterOnCellCornerDblClick","afterOnCellMouseDown","afterOnCellMouseOver","afterOnCellMouseOut","afterRemoveCol","afterRemoveRow","afterRender","beforeRenderer","afterRenderer","afterScrollHorizontally","afterScrollVertically","afterSelection","afterSelectionByProp","afterSelectionEnd","afterSelectionEndByProp","afterSetCellMeta","afterRemoveCellMeta","afterSetDataAtCell","afterSetDataAtRowProp","afterUpdateSettings","afterValidate","beforeAutofill","beforeCellAlignment","beforeChange","beforeChangeRender","beforeDrawBorders","beforeGetCellMeta","beforeRemoveCellMeta","beforeInit","beforeInitWalkontable","beforeKeyDown","beforeOnCellMouseDown","beforeOnCellMouseOver","beforeOnCellMouseOut","beforeRemoveCol","beforeRemoveRow","beforeRender","beforeSetRangeStart","beforeSetRangeEnd","beforeTouchScroll","beforeValidate","beforeValueRender","construct","init","modifyCol","unmodifyCol","unmodifyRow","modifyColHeader","modifyColWidth","modifyRow","modifyRowHeader","modifyRowHeight","modifyData","modifyRowData","persistentStateLoad","persistentStateReset","persistentStateSave","beforeColumnSort","afterColumnSort","modifyAutofillRange","modifyCopyableRange","beforeCut","afterCut","beforeCopy","afterCopy","beforePaste","afterPaste","beforeColumnMove","afterColumnMove","beforeRowMove","afterRowMove","beforeColumnResize","afterColumnResize","beforeRowResize","afterRowResize","afterGetColumnHeaderRenderers","afterGetRowHeaderRenderers","beforeStretchingColumnWidth","beforeFilter","afterFilter","modifyColumnHeaderHeight","beforeUndo","afterUndo","beforeRedo","afterRedo","modifyRowHeaderWidth","beforeAutofillInsidePopulate","modifyTransformStart","modifyTransformEnd","afterModifyTransformStart","afterModifyTransformEnd","afterViewportRowCalculatorOverride","afterViewportColumnCalculatorOverride","afterPluginsInitialized","manualRowHeights","skipLengthCache","afterTrimRow","afterUntrimRow","afterDropdownMenuShow","afterDropdownMenuHide","hiddenRow","hiddenColumn","beforeAddChild","afterAddChild","beforeDetachChild","afterDetachChild","afterBeginEditing"],a=function(){function e(){n(this,e),this.globalBucket=this.createEmptyBucket()}return r(e,null,[{key:"getSingleton",value:function(){return u}}]),r(e,[{key:"createEmptyBucket",value:function(){var e=Object.create(null);return(0,i.arrayEach)(l,function(t){return e[t]=[]}),e}},{key:"getBucket",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;return e?(e.pluginHookBucket||(e.pluginHookBucket=this.createEmptyBucket()),e.pluginHookBucket):this.globalBucket}},{key:"add",value:function(e,t){var o=this,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;if(Array.isArray(t))(0,i.arrayEach)(t,function(t){return o.add(e,t,n)});else{var r=this.getBucket(n);if(void 0===r[e]&&(this.register(e),r[e]=[]),t.skip=!1,-1===r[e].indexOf(t)){var s=!1;t.initialHook&&(0,i.arrayEach)(r[e],function(o,n){if(o.initialHook)return r[e][n]=t,s=!0,!1}),s||r[e].push(t)}}return this}},{key:"once",value:function(e,t){var o=this,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;Array.isArray(t)?(0,i.arrayEach)(t,function(t){return o.once(e,t,n)}):(t.runOnce=!0,this.add(e,t,n))}},{key:"remove",value:function(e,t){var o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,n=this.getBucket(o);return void 0!==n[e]&&n[e].indexOf(t)>=0&&(t.skip=!0,!0)}},{key:"has",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,o=this.getBucket(t);return!(void 0===o[e]||!o[e].length)}},{key:"run",value:function(e,t,o,n,r,i,s,l){var a=this.globalBucket[t],u=-1,c=a?a.length:0;if(c)for(;++u<c;)if(a[u]&&!a[u].skip){var h=a[u].call(e,o,n,r,i,s,l);void 0!==h&&(o=h),a[u]&&a[u].runOnce&&this.remove(t,a[u])}var d=this.getBucket(e)[t],f=-1,p=d?d.length:0;if(p)for(;++f<p;)if(d[f]&&!d[f].skip){var g=d[f].call(e,o,n,r,i,s,l);void 0!==g&&(o=g),d[f]&&d[f].runOnce&&this.remove(t,d[f],e)}return o}},{key:"destroy",value:function(){(0,s.objectEach)(this.getBucket(arguments.length>0&&void 0!==arguments[0]?arguments[0]:null),function(e,t,o){return o[t].length=0})}},{key:"register",value:function(e){this.isRegistered(e)||l.push(e)}},{key:"deregister",value:function(e){this.isRegistered(e)&&l.splice(l.indexOf(e),1)}},{key:"isRegistered",value:function(e){return l.indexOf(e)>=0}},{key:"getRegistered",value:function(){return l}}]),e}(),u=new a;t.default=a},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e){if("function"==typeof e)return e;if(!R(e))throw Error('No registered renderer found under "'+e+'" name');return E(e)}t.__esModule=!0,t.getRegisteredRenderers=t.getRegisteredRendererNames=t.hasRenderer=t.getRenderer=t.registerRenderer=void 0;var i=o(50),s=n(i),l=o(264),a=n(l),u=o(265),c=n(u),h=o(266),d=n(h),f=o(267),p=n(f),g=o(268),v=n(g),m=o(269),y=n(m),w=o(270),C=n(w),b=(0,s.default)("renderers"),S=b.register,E=b.getItem,R=b.hasItem,O=b.getNames,k=b.getValues;S("base",a.default),S("autocomplete",c.default),S("checkbox",d.default),S("html",p.default),S("numeric",v.default),S("password",y.default),S("text",C.default),t.registerRenderer=S,t.getRenderer=r,t.hasRenderer=R,t.getRegisteredRendererNames=O,t.getRegisteredRenderers=k},function(e,t,o){var n=o(83)("wks"),r=o(49),i=o(13).Symbol,s="function"==typeof i;(e.exports=function(e){return n[e]||(n[e]=s&&i[e]||(s?i:r)("Symbol."+e))}).store=n},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}t.__esModule=!0,t.Viewport=t.TableRenderer=t.Table=t.Settings=t.Selection=t.Scroll=t.Overlays=t.Event=t.Core=t.default=t.Border=t.TopLeftCornerOverlay=t.TopOverlay=t.LeftOverlay=t.DebugOverlay=t.RowFilter=t.ColumnFilter=t.CellRange=t.CellCoords=t.ViewportRowsCalculator=t.ViewportColumnsCalculator=void 0,o(98),o(115),o(124),o(125),o(109),o(123),o(106),o(107),o(108),o(97),o(120),o(118),o(116),o(121),o(122),o(117),o(119),o(110),o(111),o(112),o(114),o(113),o(95),o(96),o(91),o(94),o(93),o(92),o(67),o(100),o(101),o(103),o(102),o(99),o(105),o(104),o(126),o(129),o(127),o(128),o(131),o(130),o(133),o(132);var r=o(137),i=n(r),s=o(138),l=n(s),a=o(42),u=n(a),c=o(68),h=n(c),d=o(141),f=n(d),p=o(142),g=n(p),v=o(185),m=n(v),y=o(186),w=n(y),C=o(187),b=n(C),S=o(188),E=n(S),R=o(136),O=n(R),k=o(139),T=n(k),_=o(140),M=n(_),H=o(143),A=n(H),P=o(144),x=n(P),D=o(189),L=n(D),N=o(145),I=n(N),j=o(146),W=n(j),B=o(147),F=n(B),V=o(148),z=n(V);t.ViewportColumnsCalculator=i.default,t.ViewportRowsCalculator=l.default,t.CellCoords=u.default,t.CellRange=h.default,t.ColumnFilter=f.default,t.RowFilter=g.default,t.DebugOverlay=m.default,t.LeftOverlay=w.default,t.TopOverlay=b.default,t.TopLeftCornerOverlay=E.default,t.Border=O.default,t.default=T.default,t.Core=T.default,t.Event=M.default,t.Overlays=A.default,t.Scroll=x.default,t.Selection=L.default,t.Settings=I.default,t.Table=W.default,t.TableRenderer=F.default,t.Viewport=z.default},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=o(1),s=o(2),l=o(154),a=o(5),u=new WeakMap,c=null;t.default=function(){function e(t){var o=this;n(this,e),(0,i.defineGetter)(this,"hot",t,{writable:!1}),(0,i.defineGetter)(this,"t",(0,l.getTranslator)(t),{writable:!1}),u.set(this,{hooks:{}}),c=null,this.pluginName=null,this.pluginsInitializedCallbacks=[],this.isPluginsReady=!1,this.enabled=!1,this.initialized=!1,this.hot.addHook("afterPluginsInitialized",function(){return o.onAfterPluginsInitialized()}),this.hot.addHook("afterUpdateSettings",function(){return o.onUpdateSettings()}),this.hot.addHook("beforeInit",function(){return o.init()})}return r(e,[{key:"init",value:function(){this.pluginName=(0,a.getPluginName)(this.hot,this),this.isEnabled&&this.isEnabled()&&this.enablePlugin(),c||(c=(0,a.getRegistredPluginNames)(this.hot)),0>c.indexOf(this.pluginName)||c.splice(c.indexOf(this.pluginName),1),c.length||this.hot.runHooks("afterPluginsInitialized"),this.initialized=!0}},{key:"enablePlugin",value:function(){this.enabled=!0}},{key:"disablePlugin",value:function(){this.eventManager&&this.eventManager.clear(),this.clearHooks(),this.enabled=!1}},{key:"addHook",value:function(e,t){u.get(this).hooks[e]=u.get(this).hooks[e]||[];var o=u.get(this).hooks[e];this.hot.addHook(e,t),o.push(t),u.get(this).hooks[e]=o}},{key:"removeHooks",value:function(e){var t=this;(0,s.arrayEach)(u.get(this).hooks[e]||[],function(o){t.hot.removeHook(e,o)})}},{key:"clearHooks",value:function(){var e=this,t=u.get(this).hooks;(0,i.objectEach)(t,function(t,o){return e.removeHooks(o)}),t.length=0}},{key:"callOnPluginsReady",value:function(e){this.isPluginsReady?e():this.pluginsInitializedCallbacks.push(e)}},{key:"onAfterPluginsInitialized",value:function(){(0,s.arrayEach)(this.pluginsInitializedCallbacks,function(e){return e()}),this.pluginsInitializedCallbacks.length=0,this.isPluginsReady=!0}},{key:"onUpdateSettings",value:function(){this.isEnabled&&(this.enabled&&!this.isEnabled()&&this.disablePlugin(),!this.enabled&&this.isEnabled()&&this.enablePlugin(),this.enabled&&this.isEnabled()&&this.updatePlugin())}},{key:"updatePlugin",value:function(){}},{key:"destroy",value:function(){var e=this;this.eventManager&&this.eventManager.destroy(),this.clearHooks(),(0,i.objectEach)(this,function(t,o){"hot"!==o&&"t"!==o&&(e[o]=null)}),delete this.t,delete this.hot}}]),e}()},function(e,t){var o=e.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=o)},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e){var t={},o=e;this.getConstructor=function(){return e},this.getInstance=function(e){return e.guid in t||(t[e.guid]=new o(e)),t[e.guid]},h.default.getSingleton().add("afterDestroy",function(){t={}})}function i(e,t){var o=void 0;if("function"==typeof e)D.get(e)||l(null,e),o=D.get(e);else{if("string"!=typeof e)throw Error('Only strings and functions can be passed as "editor" parameter');o=I(e)}if(!o)throw Error('No editor registered under name "'+e+'"');return o.getInstance(t)}function s(e){if(!j(e))throw Error('No registered editor found under "'+e+'" name');return I(e).getConstructor()}function l(e,t){var o=new r(t);"string"==typeof e&&N(e,o),D.set(t,o)}t.__esModule=!0,t.getRegisteredEditors=t.getRegisteredEditorNames=t.hasEditor=t.getEditorInstance=t.getEditor=t.registerEditor=void 0,t.RegisteredEditor=r,t._getEditorInstance=i;var a=o(50),u=n(a),c=o(8),h=n(c),d=o(36),f=n(d),p=o(149),g=n(p),v=o(202),m=n(v),y=o(203),w=n(y),C=o(204),b=n(C),S=o(150),E=n(S),R=o(205),O=n(R),k=o(206),T=n(k),_=o(207),M=n(_),H=o(208),A=n(H),P=o(43),x=n(P),D=new WeakMap,L=(0,u.default)("editors"),N=L.register,I=L.getItem,j=L.hasItem,W=L.getNames,B=L.getValues;l("base",f.default),l("autocomplete",g.default),l("checkbox",m.default),l("date",w.default),l("dropdown",b.default),l("handsontable",E.default),l("mobile",O.default),l("numeric",T.default),l("password",M.default),l("select",A.default),l("text",x.default),t.registerEditor=l,t.getEditor=s,t.getEditorInstance=i,t.hasEditor=j,t.getRegisteredEditorNames=W,t.getRegisteredEditors=B},function(e,t){e.exports=function(e){return"object"==typeof e?null!==e:"function"==typeof e}},function(e,t,o){"use strict";function n(e){return 32==e||e>=48&&57>=e||e>=96&&111>=e||e>=186&&192>=e||e>=219&&222>=e||e>=226||e>=65&&90>=e}function r(e){return-1!==[a.ARROW_DOWN,a.ARROW_UP,a.ARROW_LEFT,a.ARROW_RIGHT,a.HOME,a.END,a.DELETE,a.BACKSPACE,a.F1,a.F2,a.F3,a.F4,a.F5,a.F6,a.F7,a.F8,a.F9,a.F10,a.F11,a.F12,a.TAB,a.PAGE_DOWN,a.PAGE_UP,a.ENTER,a.ESCAPE,a.SHIFT,a.CAPS_LOCK,a.ALT].indexOf(e)}function i(e){return-1!==[a.CONTROL_LEFT,224,a.COMMAND_LEFT,a.COMMAND_RIGHT].indexOf(e)}function s(e,t){var o=t.split("|"),n=!1;return(0,l.arrayEach)(o,function(t){if(e===a[t])return n=!0,!1}),n}t.__esModule=!0,t.KEY_CODES=void 0,t.isPrintableChar=n,t.isMetaKey=r,t.isCtrlKey=i,t.isKey=s;var l=o(2),a=t.KEY_CODES={MOUSE_LEFT:1,MOUSE_RIGHT:3,MOUSE_MIDDLE:2,BACKSPACE:8,COMMA:188,INSERT:45,DELETE:46,END:35,ENTER:13,ESCAPE:27,CONTROL_LEFT:91,COMMAND_LEFT:17,COMMAND_RIGHT:93,ALT:18,HOME:36,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,SPACE:32,SHIFT:16,CAPS_LOCK:20,TAB:9,ARROW_RIGHT:39,ARROW_LEFT:37,ARROW_UP:38,ARROW_DOWN:40,F1:112,F2:113,F3:114,F4:115,F5:116,F6:117,F7:118,F8:119,F9:120,F10:121,F11:122,F12:123,A:65,X:88,C:67,V:86}},function(e,t,o){"use strict";function n(e){return{start:e.getTopLeftCorner(),end:e.getBottomRightCorner()}}function r(e){return(0,S.hasClass)(e,"htSeparator")}function i(e){return(0,S.hasClass)(e,"htSubmenu")}function s(e){return(0,S.hasClass)(e,"htDisabled")}function l(e){return(0,S.hasClass)(e,"htSelectionDisabled")}function a(e){var t=e.getSelected();return t?0>t[0]?null:t:null}function u(e,t){return-1!=e.indexOf(t)?e:(e=e.replace("htTop","").replace("htMiddle","").replace("htBottom","").replace(" ",""),e+=" "+t)}function c(e,t){return-1!=e.indexOf(t)?e:(e=e.replace("htLeft","").replace("htCenter","").replace("htRight","").replace("htJustify","").replace(" ",""),e+=" "+t)}function h(e,t){for(var o={},n=e.from.row;e.to.row>=n;n++)for(var r=e.from.col;e.to.col>=r;r++)o[n]||(o[n]=[]),o[n][r]=t(n,r);return o}function d(e,t,o,n,r){if(e.from.row==e.to.row&&e.from.col==e.to.col)f(e.from.row,e.from.col,t,o,n,r);else for(var i=e.from.row;e.to.row>=i;i++)for(var s=e.from.col;e.to.col>=s;s++)f(i,s,t,o,n,r)}function f(e,t,o,n,r,i){var s=r(e,t),l=n;s.className&&(l="vertical"===o?u(s.className,n):c(s.className,n)),i(e,t,"className",l)}function p(e,t){var o=!1;return e&&e.forAll(function(e,n){if(t(e,n))return o=!0,!1}),o}function g(e){return'<span class="selected">'+String.fromCharCode(10003)+"</span>"+e}function v(e,t){return!e.hidden||!("function"==typeof e.hidden&&e.hidden.call(t))}function m(e,t){for(var o=e.slice(0);o.length>0&&o[0].name===t;)o.shift();return o}function y(e,t){var o=e.slice(0);return o.reverse(),o=m(o,t),o.reverse(),o}function w(e){var t=[];return(0,b.arrayEach)(e,function(e,o){o>0?t[t.length-1].name!==e.name&&t.push(e):t.push(e)}),t}function C(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:E.KEY,o=e.slice(0);return o=m(o,t),o=y(o,t),o=w(o)}t.__esModule=!0,t.normalizeSelection=n,t.isSeparator=r,t.hasSubMenu=i,t.isDisabled=s,t.isSelectionDisabled=l,t.getValidSelection=a,t.prepareVerticalAlignClass=u,t.prepareHorizontalAlignClass=c,t.getAlignmentClasses=h,t.align=d,t.checkSelectionConsistency=p,t.markLabelAsSelected=g,t.isItemHidden=v,t.filterSeparators=C;var b=o(2),S=o(0),E=o(71)},function(e,t,o){var n=o(15);e.exports=function(e){if(!n(e))throw TypeError(e+" is not an object!");return e}},function(e,t,o){var n=o(18),r=o(161),i=o(86),s=Object.defineProperty;t.f=o(21)?Object.defineProperty:function(e,t,o){if(n(e),t=i(t,!0),n(o),r)try{return s(e,t,o)}catch(e){}if("get"in o||"set"in o)throw TypeError("Accessors not supported!");return"value"in o&&(e[t]=o.value),e}},function(e,t,o){"use strict";function n(e){var t=void 0;switch(void 0===e?"undefined":c(e)){case"string":case"number":t=""+e;break;case"object":t=null===e?"":""+e;break;case"undefined":t="";break;default:t=""+e}return t}function r(e){return void 0!==e}function i(e){return void 0===e}function s(e){return null===e||""===e||i(e)}function l(e){return"[object RegExp]"===Object.prototype.toString.call(e)}function a(e,t){e=w(e||"");var o="",n=!0,r=u(e),i=b(),l=s(e)||"trial"===e;if(l||r)if(r){var a=Math.floor(moment("06/09/2017","DD/MM/YYYY").toDate().getTime()/864e5),c=C(e);(c>45e3||c!==parseInt(c,10))&&(o="The license key provided to Handsontable Pro is invalid. Make sure you pass it correctly."),o||(a>c+1&&(o=(0,f.toSingleLine)(h)),n=a>c+15)}else o="Evaluation version of Handsontable Pro. Not licensed for use in a production environment.";else o="The license key provided to Handsontable Pro is invalid. Make sure you pass it correctly.";if(i&&(o=!1,n=!1),o&&!S&&(console[l?"info":"warn"](o),S=!0),n&&t.parentNode){var p=document.createElement("div");(0,d.addClass)(p,"display-license-info"),p.appendChild(document.createTextNode("Evaluation version of Handsontable Pro.")),p.appendChild(document.createElement("br")),p.appendChild(document.createTextNode("Not licensed for production use.")),t.parentNode.insertBefore(p,t.nextSibling)}}function u(e){var t=[][p],o=t;if(e[p]!==y("Z"))return!1;for(var n="",r="B<H4P+".split(""),i=y(r.shift());i;i=y(r.shift()||"A"))--i<""[p]?o|=(v(""+v(g(n)+(g(m(e,Math.abs(i),2))+[]).padStart(2,"0")))%y("¢")||2)>>1:n=m(e,i,i?1===r[p]?9:8:6);return o===t}t.__esModule=!0;var c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},h=function(e,t){return Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}(["\n Your license key of Handsontable Pro has expired. \n Renew your maintenance plan at https://handsontable.com or downgrade to the previous version of the software.\n "],["\n Your license key of Handsontable Pro has expired.\\x20\n Renew your maintenance plan at https://handsontable.com or downgrade to the previous version of the software.\n "]);t.stringify=n,t.isDefined=r,t.isUndefined=i,t.isEmpty=s,t.isRegExp=l,t._injectProductInfo=a;var d=o(0),f=o(209),p="length",g=function(e){return parseInt(e,16)},v=function(e){return parseInt(e,10)},m=function(e,t,o){return e.substr(t,o)},y=function(e){return e.codePointAt(0)-65},w=function(e){return e.replace(/\-/g,"")},C=function(e){return g(m(w(e),g("12"),y("F")))/(g(m(w(e),y("B"),~~![][p]))||9)},b=function(){return"undefined"!=typeof location&&/^([a-z0-9\-]+\.)?\x68\x61\x6E\x64\x73\x6F\x6E\x74\x61\x62\x6C\x65\x2E\x63\x6F\x6D$/i.test(location.host)},S=!1},function(e,t,o){e.exports=!o(31)(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})},function(e,t){var o={}.hasOwnProperty;e.exports=function(e,t){return o.call(e,t)}},function(e,t,o){var n=o(77),r=o(30);e.exports=function(e){return n(r(e))}},function(e,t,o){var n=o(60),r=Math.min;e.exports=function(e){return e>0?r(n(e),9007199254740991):0}},function(e,t,o){"use strict";function n(){return a}function r(){return u}function i(){return c}function s(){return h}function l(e){return e||(e=navigator.userAgent),/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(e)}t.__esModule=!0,t.isIE8=n,t.isIE9=r,t.isSafari=i,t.isChrome=s,t.isMobileBrowser=l;var a=!document.createTextNode("test").textContent,u=!!document.documentMode,c=/Safari/.test(navigator.userAgent)&&/Apple Computer/.test(navigator.vendor),h=/Chrome/.test(navigator.userAgent)&&/Google/.test(navigator.vendor)},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e){if("function"==typeof e)return e;if(!y(e))throw Error('No registered validator found under "'+e+'" name');return m(e)}t.__esModule=!0,t.getRegisteredValidators=t.getRegisteredValidatorNames=t.hasValidator=t.getValidator=t.registerValidator=void 0;var i=o(50),s=n(i),l=o(275),a=n(l),u=o(276),c=n(u),h=o(277),d=n(h),f=o(278),p=n(f),g=(0,s.default)("validators"),v=g.register,m=g.getItem,y=g.hasItem,w=g.getNames,C=g.getValues;v("autocomplete",a.default),v("date",c.default),v("numeric",d.default),v("time",p.default),t.registerValidator=v,t.getValidator=r,t.hasValidator=y,t.getRegisteredValidatorNames=w,t.getRegisteredValidators=C},function(e,t,o){"use strict";function n(e){return e[0].toUpperCase()+e.substr(1)}function r(){for(var e=[],t=arguments.length,o=Array(t),n=0;t>n;n++)o[n]=arguments[n];for(var r=o.length;r--;){var i=(0,u.stringify)(o[r]).toLowerCase();-1===e.indexOf(i)&&e.push(i)}return 1===e.length}function i(){function e(){return Math.floor(65536*(1+Math.random())).toString(16).substring(1)}return e()+e()+e()+e()}function s(e){return/^([0-9][0-9]?%$)|(^100%$)/.test(e)}function l(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return(""+e).replace(/(?:\\)?\[([^[\]]+)]/g,function(e,o){return"\\"===e.charAt(0)?e.substr(1,e.length-1):void 0===t[o]?"":t[o]})}function a(e){return e+="",e.replace(c,"")}t.__esModule=!0,t.toUpperCaseFirst=n,t.equalsIgnoreCase=r,t.randomString=i,t.isPercentValue=s,t.substitute=l,t.stripTags=a;var u=o(20),c=(o(6),/<\/?\w+\/?>|<\w+[\s|\/][^>]*>/gi)},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var i=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),s=o(0),l=o(1),a=o(2),u=o(4),c=n(u),h=o(139),d=n(h),f={};t.default=function(){function e(t){r(this,e),(0,l.defineGetter)(this,"wot",t,{writable:!1}),this.instance=this.wot,this.type="",this.mainTableScrollableElement=null,this.TABLE=this.wot.wtTable.TABLE,this.hider=this.wot.wtTable.hider,this.spreader=this.wot.wtTable.spreader,this.holder=this.wot.wtTable.holder,this.wtRootElement=this.wot.wtTable.wtRootElement,this.trimmingContainer=(0,s.getTrimmingContainer)(this.hider.parentNode.parentNode),this.areElementSizesAdjusted=!1,this.updateStateOfRendering()}return i(e,null,[{key:"registerOverlay",value:function(t,o){if(-1===e.CLONE_TYPES.indexOf(t))throw Error("Unsupported overlay ("+t+").");f[t]=o}},{key:"createOverlay",value:function(e,t){return new f[e](t)}},{key:"hasOverlay",value:function(e){return void 0!==f[e]}},{key:"isOverlayTypeOf",value:function(e,t){return!(!e||!f[t])&&e instanceof f[t]}},{key:"CLONE_TOP",get:function(){return"top"}},{key:"CLONE_BOTTOM",get:function(){return"bottom"}},{key:"CLONE_LEFT",get:function(){return"left"}},{key:"CLONE_TOP_LEFT_CORNER",get:function(){return"top_left_corner"}},{key:"CLONE_BOTTOM_LEFT_CORNER",get:function(){return"bottom_left_corner"}},{key:"CLONE_DEBUG",get:function(){return"debug"}},{key:"CLONE_TYPES",get:function(){return[e.CLONE_TOP,e.CLONE_BOTTOM,e.CLONE_LEFT,e.CLONE_TOP_LEFT_CORNER,e.CLONE_BOTTOM_LEFT_CORNER,e.CLONE_DEBUG]}}]),i(e,[{key:"updateStateOfRendering",value:function(){var e=this.needFullRender;this.needFullRender=this.shouldBeRendered();var t=e!==this.needFullRender;return t&&!this.needFullRender&&this.reset(),t}},{key:"shouldBeRendered",value:function(){return!0}},{key:"updateTrimmingContainer",value:function(){this.trimmingContainer=(0,s.getTrimmingContainer)(this.hider.parentNode.parentNode)}},{key:"updateMainScrollableElement",value:function(){this.mainTableScrollableElement=(0,s.getScrollableElement)(this.wot.wtTable.TABLE)}},{key:"makeClone",value:function(t){if(-1===e.CLONE_TYPES.indexOf(t))throw Error('Clone type "'+t+'" is not supported.');var o=document.createElement("DIV"),n=document.createElement("TABLE");o.className="ht_clone_"+t+" handsontable",o.style.position="absolute",o.style.top=0,o.style.left=0,o.style.overflow="hidden",n.className=this.wot.wtTable.TABLE.className,o.appendChild(n),this.type=t,this.wot.wtTable.wtRootElement.parentNode.appendChild(o);var r=this.wot.getSetting("preventOverflow");return this.mainTableScrollableElement=!0===r||"horizontal"===r&&this.type===e.CLONE_TOP||"vertical"===r&&this.type===e.CLONE_LEFT?window:(0,s.getScrollableElement)(this.wot.wtTable.TABLE),new d.default({cloneSource:this.wot,cloneOverlay:this,table:n})}},{key:"refresh",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=this.shouldBeRendered();this.clone&&(this.needFullRender||t)&&this.clone.draw(e),this.needFullRender=t}},{key:"reset",value:function(){if(this.clone){var e=this.clone.wtTable.holder;(0,a.arrayEach)([e.style,this.clone.wtTable.hider.style,e.parentNode.style],function(e){e.width="",e.height=""})}}},{key:"destroy",value:function(){new c.default(this.clone).destroy()}}]),e}()},function(e,t,o){var n=o(72);e.exports=function(e,t,o){if(n(e),void 0===t)return e;switch(o){case 1:return function(o){return e.call(t,o)};case 2:return function(o,n){return e.call(t,o,n)};case 3:return function(o,n,r){return e.call(t,o,n,r)}}return function(){return e.apply(t,arguments)}}},function(e,t){e.exports=function(e){if(void 0==e)throw TypeError("Can't call method on "+e);return e}},function(e,t){e.exports=function(e){try{return!!e()}catch(e){return!0}}},function(e,t,o){var n=o(19),r=o(40);e.exports=o(21)?function(e,t,o){return n.f(e,t,r(1,o))}:function(e,t,o){return e[t]=o,e}},function(e,t,o){var n=o(13),r=o(32),i=o(22),s=o(49)("src"),l=Function.toString,a=(""+l).split("toString");o(44).inspectSource=function(e){return l.call(e)},(e.exports=function(e,t,o,l){var u="function"==typeof o;u&&(i(o,"name")||r(o,"name",t)),e[t]!==o&&(u&&(i(o,s)||r(o,s,e[t]?""+e[t]:a.join(t+""))),e===n?e[t]=o:l?e[t]?e[t]=o:r(e,t,o):(delete e[t],r(e,t,o)))})(Function.prototype,"toString",function(){return"function"==typeof this&&this[s]||l.call(this)})},function(e,t,o){"use strict";function n(e){return f.call(window,e)}function r(e){p.call(window,e)}function i(){return"ontouchstart"in window}function s(){var e=document.createElement("div");return!(!e.createShadowRoot||!(""+e.createShadowRoot).match(/\[native code\]/))}function l(){var e=document.createElement("TABLE");e.style.borderSpacing=0,e.style.borderWidth=0,e.style.padding=0;var t=document.createElement("TBODY");e.appendChild(t),t.appendChild(document.createElement("TR")),t.firstChild.appendChild(document.createElement("TD")),t.firstChild.firstChild.innerHTML="<tr><td>t<br>t</td></tr>";var o=document.createElement("CAPTION");o.innerHTML="c<br>c<br>c<br>c",o.style.padding=0,o.style.margin=0,e.insertBefore(o,t),document.body.appendChild(e),v=2*e.lastChild.offsetHeight>e.offsetHeight,document.body.removeChild(e)}function a(){return void 0===v&&l(),v}function u(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return m||(m="object"===("undefined"==typeof Intl?"undefined":c(Intl))?new Intl.Collator(e,t).compare:"function"==typeof String.prototype.localeCompare?function(e,t){return(""+e).localeCompare(t)}:function(e,t){return e===t?0:e>t?-1:1})}t.__esModule=!0;var c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.requestAnimationFrame=n,t.cancelAnimationFrame=r,t.isTouchSupported=i,t.isWebComponentSupportedNatively=s,t.hasCaptionProblem=a,t.getComparisonFunction=u;for(var h=0,d=["ms","moz","webkit","o"],f=window.requestAnimationFrame,p=window.cancelAnimationFrame,g=0;4>g&&!f;++g)f=window[d[g]+"RequestAnimationFrame"],p=window[d[g]+"CancelAnimationFrame"]||window[d[g]+"CancelRequestAnimationFrame"];f||(f=function(e){var t=(new Date).getTime(),o=Math.max(0,16-(t-h)),n=window.setTimeout(function(){e(t+o)},o);return h=t+o,n}),p||(p=function(e){clearTimeout(e)});var v,m=void 0},function(e,t,o){"use strict";function n(e){return"function"==typeof e}function r(e){function t(){var t=this,s=arguments,l=Date.now(),a=!1;r.lastCallThrottled=!0,n||(n=l,a=!0);var u=o-(l-n);return a?(r.lastCallThrottled=!1,e.apply(this,s)):(i&&clearTimeout(i),i=setTimeout(function(){r.lastCallThrottled=!1,e.apply(t,s),n=0,i=void 0},u)),r}var o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:200,n=0,r={lastCallThrottled:!0},i=null;return t}function i(e){function t(){l=i}function o(){return l?(l--,e.apply(this,arguments)):s.apply(this,arguments)}var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:200,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:10,s=r(e,n),l=i;return o.clearHits=t,o}function s(e){function t(){var t=this,i=arguments;return n&&clearTimeout(n),n=setTimeout(function(){r=e.apply(t,i)},o),r}var o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:200,n=null,r=void 0;return t}function l(){for(var e=arguments.length,t=Array(e),o=0;e>o;o++)t[o]=arguments[o];var n=t[0],r=t.slice(1);return function(){return(0,h.arrayReduce)(r,function(e,t){return t(e)},n.apply(this,arguments))}}function a(e){for(var t=arguments.length,o=Array(t>1?t-1:0),n=1;t>n;n++)o[n-1]=arguments[n];return function(){for(var t=arguments.length,n=Array(t),r=0;t>r;r++)n[r]=arguments[r];return e.apply(this,o.concat(n))}}function u(e){function t(n){return function(){for(var r=arguments.length,i=Array(r),s=0;r>s;s++)i[s]=arguments[s];var l=n.concat(i);return o>l.length?t(l):e.apply(this,l)}}var o=e.length;return t([])}function c(e){function t(n){return function(){for(var r=arguments.length,i=Array(r),s=0;r>s;s++)i[s]=arguments[s];var l=n.concat(i.reverse());return o>l.length?t(l):e.apply(this,l)}}var o=e.length;return t([])}t.__esModule=!0,t.isFunction=n,t.throttle=r,t.throttleAfterHits=i,t.debounce=s,t.pipe=l,t.partial=a,t.curry=u,t.curryRight=c;var h=o(2)},function(e,t,o){"use strict";function n(e){this.instance=e,this.state=s.VIRGIN,this._opened=!1,this._fullEditMode=!1,this._closeCallback=null,this.init()}t.__esModule=!0,t.EditorState=void 0;var r=o(11),i=o(20),s=t.EditorState={VIRGIN:"STATE_VIRGIN",EDITING:"STATE_EDITING",WAITING:"STATE_WAITING",FINISHED:"STATE_FINISHED"};n.prototype._fireCallbacks=function(e){this._closeCallback&&(this._closeCallback(e),this._closeCallback=null)},n.prototype.init=function(){},n.prototype.getValue=function(){throw Error("Editor getValue() method unimplemented")},n.prototype.setValue=function(e){throw Error("Editor setValue() method unimplemented")},n.prototype.open=function(){throw Error("Editor open() method unimplemented")},n.prototype.close=function(){throw Error("Editor close() method unimplemented")},n.prototype.prepare=function(e,t,o,n,r,i){this.TD=n,this.row=e,this.col=t,this.prop=o,this.originalValue=r,this.cellProperties=i,this.state=s.VIRGIN},n.prototype.extend=function(){function e(){t.apply(this,arguments)}var t=this.constructor;return function(e,t){function o(){}return o.prototype=t.prototype,e.prototype=new o,e.prototype.constructor=e,e}(e,t)},n.prototype.saveValue=function(e,t){var o=void 0,n=void 0;t?(o=this.instance.getSelected(),o[0]>o[2]&&(n=o[0],o[0]=o[2],o[2]=n),o[1]>o[3]&&(n=o[1],o[1]=o[3],o[3]=n)):o=[this.row,this.col,null,null],this.instance.populateFromArray(o[0],o[1],e,o[2],o[3],"edit")},n.prototype.beginEditing=function(e,t){this.state==s.VIRGIN&&(this.instance.view.scrollViewport(new r.CellCoords(this.row,this.col)),this.instance.view.render(),this.state=s.EDITING,e="string"==typeof e?e:this.originalValue,this.setValue((0,i.stringify)(e)),this.open(t),this._opened=!0,this.focus(),this.instance.view.render(),this.instance.runHooks("afterBeginEditing",this.row,this.col))},n.prototype.finishEditing=function(e,t,o){var n,r=this;if(o){var i=this._closeCallback;this._closeCallback=function(e){i&&i(e),o(e),r.instance.view.render()}}if(!this.isWaiting()){if(this.state==s.VIRGIN)return void this.instance._registerTimeout(setTimeout(function(){r._fireCallbacks(!0)},0));if(this.state==s.EDITING){if(e)return this.cancelChanges(),void this.instance.view.render();var l=this.getValue();n=this.instance.getSettings().trimWhitespace?[["string"==typeof l?String.prototype.trim.call(l||""):l]]:[[l]],this.state=s.WAITING,this.saveValue(n,t),this.instance.getCellValidator(this.cellProperties)?this.instance.addHookOnce("postAfterValidate",function(e){r.state=s.FINISHED,r.discardEditor(e)}):(this.state=s.FINISHED,this.discardEditor(!0))}}},n.prototype.cancelChanges=function(){this.state=s.FINISHED,this.discardEditor()},n.prototype.discardEditor=function(e){this.state===s.FINISHED&&(!1===e&&!0!==this.cellProperties.allowInvalid?(this.instance.selectCell(this.row,this.col),this.focus(),this.state=s.EDITING,this._fireCallbacks(!1)):(this.close(),this._opened=!1,this._fullEditMode=!1,this.state=s.VIRGIN,this._fireCallbacks(!0)))},n.prototype.enableFullEditMode=function(){this._fullEditMode=!0},n.prototype.isInFullEditMode=function(){return this._fullEditMode},n.prototype.isOpened=function(){return this._opened},n.prototype.isWaiting=function(){return this.state===s.WAITING},n.prototype.checkEditorSection=function(){var e=this.instance.countRows(),t="";return this.row<this.instance.getSettings().fixedRowsTop?t=this.col<this.instance.getSettings().fixedColumnsLeft?"top-left-corner":"top":this.instance.getSettings().fixedRowsBottom&&this.row>=e-this.instance.getSettings().fixedRowsBottom?t=this.col<this.instance.getSettings().fixedColumnsLeft?"bottom-left-corner":"bottom":this.col<this.instance.getSettings().fixedColumnsLeft&&(t="left"),t},t.default=n},function(e,t,o){var n=o(10)("unscopables"),r=Array.prototype;void 0==r[n]&&o(32)(r,n,{}),e.exports=function(e){r[n][e]=!0}},function(e,t){var o={}.toString;e.exports=function(e){return o.call(e).slice(8,-1)}},function(e,t,o){var n=o(170),r=o(75);e.exports=Object.keys||function(e){return n(e,r)}},function(e,t){e.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},function(e,t,o){var n=o(30);e.exports=function(e){return Object(n(e))}},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}();t.default=function(){function e(t,o){n(this,e),void 0!==t&&void 0!==o?(this.row=t,this.col=o):(this.row=null,this.col=null)}return r(e,[{key:"isValid",value:function(e){return this.row>=0&&this.col>=0&&(this.row<e.getSetting("totalRows")&&this.col<e.getSetting("totalColumns"))}},{key:"isEqual",value:function(e){return e===this||this.row===e.row&&this.col===e.col}},{key:"isSouthEastOf",value:function(e){return this.row>=e.row&&this.col>=e.col}},{key:"isNorthWestOf",value:function(e){return e.row>=this.row&&e.col>=this.col}},{key:"isSouthWestOf",value:function(e){return this.row>=e.row&&e.col>=this.col}},{key:"isNorthEastOf",value:function(e){return e.row>=this.row&&this.col>=e.col}}]),e}()},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}t.__esModule=!0;var r=o(0),i=o(184),s=n(i),l=o(36),a=n(l),u=o(4),c=n(u),h=o(16),d=o(7),f=a.default.prototype.extend();f.prototype.init=function(){var e=this;this.createElements(),this.eventManager=new c.default(this),this.bindEvents(),this.autoResize=(0,s.default)(),this.instance.addHook("afterDestroy",function(){e.destroy()})},f.prototype.getValue=function(){return this.TEXTAREA.value},f.prototype.setValue=function(e){this.TEXTAREA.value=e};var p=function(e){var t,o=this,n=o.getActiveEditor();if(t=(e.ctrlKey||e.metaKey)&&!e.altKey,e.target===n.TEXTAREA&&!(0,d.isImmediatePropagationStopped)(e)){if(17===e.keyCode||224===e.keyCode||91===e.keyCode||93===e.keyCode)return void(0,d.stopImmediatePropagation)(e);switch(e.keyCode){case h.KEY_CODES.ARROW_RIGHT:case h.KEY_CODES.ARROW_LEFT:n.isInFullEditMode()&&(!n.isWaiting()&&!n.allowKeyEventPropagation||!n.isWaiting()&&n.allowKeyEventPropagation&&!n.allowKeyEventPropagation(e.keyCode))&&(0,d.stopImmediatePropagation)(e);break;case h.KEY_CODES.ARROW_UP:case h.KEY_CODES.ARROW_DOWN:n.isInFullEditMode()&&(!n.isWaiting()&&!n.allowKeyEventPropagation||!n.isWaiting()&&n.allowKeyEventPropagation&&!n.allowKeyEventPropagation(e.keyCode))&&(0,d.stopImmediatePropagation)(e);break;case h.KEY_CODES.ENTER:var i=n.instance.getSelected(),s=!(i[0]===i[2]&&i[1]===i[3]);if(t&&!s||e.altKey){if(n.isOpened()){var l=(0,r.getCaretPosition)(n.TEXTAREA),a=n.getValue();n.setValue(a.slice(0,l)+"\n"+a.slice(l)),(0,r.setCaretPosition)(n.TEXTAREA,l+1)}else n.beginEditing(n.originalValue+"\n");(0,d.stopImmediatePropagation)(e)}e.preventDefault();break;case h.KEY_CODES.A:case h.KEY_CODES.X:case h.KEY_CODES.C:case h.KEY_CODES.V:t&&(0,d.stopImmediatePropagation)(e);break;case h.KEY_CODES.BACKSPACE:case h.KEY_CODES.DELETE:case h.KEY_CODES.HOME:case h.KEY_CODES.END:(0,d.stopImmediatePropagation)(e)}-1===[h.KEY_CODES.ARROW_UP,h.KEY_CODES.ARROW_RIGHT,h.KEY_CODES.ARROW_DOWN,h.KEY_CODES.ARROW_LEFT].indexOf(e.keyCode)&&n.autoResize.resize(String.fromCharCode(e.keyCode))}};f.prototype.open=function(){this.refreshDimensions(),this.instance.addHook("beforeKeyDown",p)},f.prototype.close=function(e){this.textareaParentStyle.display="none",this.autoResize.unObserve(),document.activeElement===this.TEXTAREA&&this.instance.listen(),this.instance.removeHook("beforeKeyDown",p)},f.prototype.focus=function(){this.TEXTAREA.focus(),(0,r.setCaretPosition)(this.TEXTAREA,this.TEXTAREA.value.length)},f.prototype.createElements=function(){this.TEXTAREA=document.createElement("TEXTAREA"),(0,r.addClass)(this.TEXTAREA,"handsontableInput"),this.textareaStyle=this.TEXTAREA.style,this.textareaStyle.width=0,this.textareaStyle.height=0,this.TEXTAREA_PARENT=document.createElement("DIV"),(0,r.addClass)(this.TEXTAREA_PARENT,"handsontableInputHolder"),this.textareaParentStyle=this.TEXTAREA_PARENT.style,this.textareaParentStyle.top=0,this.textareaParentStyle.left=0,this.textareaParentStyle.display="none",this.TEXTAREA_PARENT.appendChild(this.TEXTAREA),this.instance.rootElement.appendChild(this.TEXTAREA_PARENT);var e=this;this.instance._registerTimeout(setTimeout(function(){e.refreshDimensions()},0))},f.prototype.getEditedCell=function(){var e,t=this.checkEditorSection();switch(t){case"top":e=this.instance.view.wt.wtOverlays.topOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.textareaParentStyle.zIndex=101;break;case"top-left-corner":e=this.instance.view.wt.wtOverlays.topLeftCornerOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.textareaParentStyle.zIndex=103;break;case"bottom-left-corner":e=this.instance.view.wt.wtOverlays.bottomLeftCornerOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.textareaParentStyle.zIndex=103;break;case"left":e=this.instance.view.wt.wtOverlays.leftOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.textareaParentStyle.zIndex=102;break;case"bottom":e=this.instance.view.wt.wtOverlays.bottomOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.textareaParentStyle.zIndex=102;break;default:e=this.instance.getCell(this.row,this.col),this.textareaParentStyle.zIndex=""}return-1!=e&&-2!=e?e:void 0},f.prototype.refreshValue=function(){var e=this.instance.getSourceDataAtCell(this.row,this.prop);this.originalValue=e,this.setValue(e),this.refreshDimensions()},f.prototype.refreshDimensions=function(){if(this.state===l.EditorState.EDITING){if(!(this.TD=this.getEditedCell()))return void this.close(!0);var e,t=(0,r.offset)(this.TD),o=(0,r.offset)(this.instance.rootElement),n=(0,r.getScrollableElement)(this.TD),i=this.instance.countRows(),s=t.top===o.top?0:1,a=t.top-o.top-s-(n.scrollTop||0),u=t.left-o.left-1-(n.scrollLeft||0),c=this.instance.getSettings(),h=(this.instance.hasRowHeaders(),this.instance.hasColHeaders()),d=this.checkEditorSection(),f=this.TD.style.backgroundColor;switch(d){case"top":e=(0,r.getCssTransform)(this.instance.view.wt.wtOverlays.topOverlay.clone.wtTable.holder.parentNode);break;case"left":e=(0,r.getCssTransform)(this.instance.view.wt.wtOverlays.leftOverlay.clone.wtTable.holder.parentNode);break;case"top-left-corner":e=(0,r.getCssTransform)(this.instance.view.wt.wtOverlays.topLeftCornerOverlay.clone.wtTable.holder.parentNode);break;case"bottom-left-corner":e=(0,r.getCssTransform)(this.instance.view.wt.wtOverlays.bottomLeftCornerOverlay.clone.wtTable.holder.parentNode);break;case"bottom":e=(0,r.getCssTransform)(this.instance.view.wt.wtOverlays.bottomOverlay.clone.wtTable.holder.parentNode)}(h&&0===this.instance.getSelected()[0]||c.fixedRowsBottom&&this.instance.getSelected()[0]===i-c.fixedRowsBottom)&&(a+=1),0===this.instance.getSelected()[1]&&(u+=1),e&&-1!=e?this.textareaParentStyle[e[0]]=e[1]:(0,r.resetCssTransform)(this.TEXTAREA_PARENT),this.textareaParentStyle.top=a+"px",this.textareaParentStyle.left=u+"px";var p=this.instance.view.wt.wtViewport.rowsRenderCalculator.startPosition,g=this.instance.view.wt.wtViewport.columnsRenderCalculator.startPosition,v=this.instance.view.wt.wtOverlays.leftOverlay.getScrollPosition(),m=this.instance.view.wt.wtOverlays.topOverlay.getScrollPosition(),y=(0,r.getScrollbarWidth)(),w=this.TD.offsetTop+p-m,C=this.TD.offsetLeft+g-v,b=(0,r.innerWidth)(this.TD)-8,S=(0,r.hasVerticalScrollbar)(n)?y:0,E=(0,r.hasHorizontalScrollbar)(n)?y:0,R=this.instance.view.maximumVisibleElementWidth(C)-9-S,O=this.TD.scrollHeight+1,k=Math.max(this.instance.view.maximumVisibleElementHeight(w)-E,23),T=(0,r.getComputedStyle)(this.TD);this.TEXTAREA.style.fontSize=T.fontSize,this.TEXTAREA.style.fontFamily=T.fontFamily,this.TEXTAREA.style.backgroundColor="",this.TEXTAREA.style.backgroundColor=f||(0,r.getComputedStyle)(this.TEXTAREA).backgroundColor,this.autoResize.init(this.TEXTAREA,{minHeight:Math.min(O,k),maxHeight:k,minWidth:Math.min(b,R),maxWidth:R},!0),this.textareaParentStyle.display="block"}},f.prototype.bindEvents=function(){var e=this;this.eventManager.addEventListener(this.TEXTAREA,"cut",function(e){(0,d.stopPropagation)(e)}),this.eventManager.addEventListener(this.TEXTAREA,"paste",function(e){(0,d.stopPropagation)(e)}),this.instance.addHook("afterScrollHorizontally",function(){e.refreshDimensions()}),this.instance.addHook("afterScrollVertically",function(){e.refreshDimensions()}),this.instance.addHook("afterColumnResize",function(){e.refreshDimensions(),e.focus()}),this.instance.addHook("afterRowResize",function(){e.refreshDimensions(),e.focus()}),this.instance.addHook("afterDestroy",function(){e.eventManager.destroy()})},f.prototype.destroy=function(){this.eventManager.destroy()},t.default=f},function(e,t){var o=e.exports={version:"2.4.0"};"number"==typeof __e&&(__e=o)},function(e,t){e.exports={}},function(e,t,o){var n=o(49)("meta"),r=o(15),i=o(22),s=o(19).f,l=0,a=Object.isExtensible||function(){return!0},u=!o(31)(function(){return a(Object.preventExtensions({}))}),c=function(e){s(e,n,{value:{i:"O"+ ++l,w:{}}})},h=function(e,t){if(!r(e))return"symbol"==typeof e?e:("string"==typeof e?"S":"P")+e;if(!i(e,n)){if(!a(e))return"F";if(!t)return"E";c(e)}return e[n].i},d=function(e,t){if(!i(e,n)){if(!a(e))return!0;if(!t)return!1;c(e)}return e[n].w},f=function(e){return u&&p.NEED&&a(e)&&!i(e,n)&&c(e),e},p=e.exports={KEY:n,NEED:!1,fastKey:h,getWeak:d,onFreeze:f}},function(e,t){t.f={}.propertyIsEnumerable},function(e,t,o){var n=o(19).f,r=o(22),i=o(10)("toStringTag");e.exports=function(e,t,o){e&&!r(e=o?e:e.prototype,i)&&n(e,i,{configurable:!0,value:t})}},function(e,t){var o=0,n=Math.random();e.exports=function(e){return"Symbol(".concat(void 0===e?"":e,")_",(++o+n).toString(36))}},function(e,t,o){"use strict";function n(e){if(Array.isArray(e)){for(var t=0,o=Array(e.length);e.length>t;t++)o[t]=e[t];return o}return Array.from(e)}function r(){function e(e,t){a.set(e,t)}function t(e){return a.get(e)}function o(e){return a.has(e)}function r(){return[].concat(n(a.keys()))}function s(){return[].concat(n(a.values()))}var l=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"common";i.has(l)||i.set(l,new Map);var a=i.get(l);return{register:e,getItem:t,hasItem:o,getNames:r,getValues:s}}t.__esModule=!0,t.default=r;var i=t.collection=new Map},function(e,t){e.exports=function(e,t,o,n){if(!(e instanceof t)||void 0!==n&&n in e)throw TypeError(o+": incorrect invocation!");return e}},function(e,t,o){var n=o(29),r=o(77),i=o(41),s=o(24),l=o(282);e.exports=function(e,t){var o=1==e,a=2==e,u=3==e,c=4==e,h=6==e,d=5==e||h,f=t||l;return function(t,l,p){for(var g,v,m=i(t),y=r(m),w=n(l,p,3),C=s(y.length),b=0,S=o?f(t,C):a?f(t,0):void 0;C>b;b++)if((d||b in y)&&(g=y[b],v=w(g,b,m),e))if(o)S[b]=v;else if(v)switch(e){case 3:return!0;case 5:return g;case 6:return b;case 2:S.push(g)}else if(c)return!1;return h?-1:u||c?c:S}}},function(e,t,o){"use strict";var n=o(13),r=o(3),i=o(33),s=o(58),l=o(46),a=o(55),u=o(51),c=o(15),h=o(31),d=o(78),f=o(48),p=o(285);e.exports=function(e,t,o,g,v,m){var y=n[e],w=y,C=v?"set":"add",b=w&&w.prototype,S={},E=function(e){var t=b[e];i(b,e,"delete"==e?function(e){return!(m&&!c(e))&&t.call(this,0===e?0:e)}:"has"==e?function(e){return!(m&&!c(e))&&t.call(this,0===e?0:e)}:"get"==e?function(e){return m&&!c(e)?void 0:t.call(this,0===e?0:e)}:"add"==e?function(e){return t.call(this,0===e?0:e),this}:function(e,o){return t.call(this,0===e?0:e,o),this})};if("function"==typeof w&&(m||b.forEach&&!h(function(){(new w).entries().next()}))){var R=new w,O=R[C](m?{}:-0,1)!=R,k=h(function(){R.has(1)}),T=d(function(e){new w(e)}),_=!m&&h(function(){for(var e=new w,t=5;t--;)e[C](t,t);return!e.has(-0)});T||(w=t(function(t,o){u(t,w,e);var n=p(new y,t,w);return void 0!=o&&a(o,v,n[C],n),n}),w.prototype=b,b.constructor=w),(k||_)&&(E("delete"),E("has"),v&&E("get")),(_||O)&&E(C),m&&b.clear&&delete b.clear}else w=g.getConstructor(t,e,v,C),s(w.prototype,o),l.NEED=!0;return f(w,e),S[e]=w,r(r.G+r.W+r.F*(w!=y),S),m||g.setStrong(w,e,v),w}},function(e,t,o){"use strict";var n=o(32),r=o(33),i=o(31),s=o(30),l=o(10);e.exports=function(e,t,o){var a=l(e),u=o(s,a,""[e]),c=u[0],h=u[1];i(function(){var t={};return t[a]=function(){return 7},7!=""[e](t)})&&(r(String.prototype,e,c),n(RegExp.prototype,a,2==t?function(e,t){return h.call(e,this,t)}:function(e){return h.call(e,this)}))}},function(e,t,o){var n=o(29),r=o(166),i=o(162),s=o(18),l=o(24),a=o(177),u={},c={},t=e.exports=function(e,t,o,h,d){var f,p,g,v,m=d?function(){return e}:a(e),y=n(o,h,t?2:1),w=0;if("function"!=typeof m)throw TypeError(e+" is not iterable!");if(i(m)){for(f=l(e.length);f>w;w++)if((v=t?y(s(p=e[w])[0],p[1]):y(e[w]))===u||v===c)return v}else for(g=m.call(e);!(p=g.next()).done;)if((v=r(g,y,p.value,t))===u||v===c)return v};t.BREAK=u,t.RETURN=c},function(e,t){e.exports=!1},function(e,t){t.f=Object.getOwnPropertySymbols},function(e,t,o){var n=o(33);e.exports=function(e,t,o){for(var r in t)n(e,r,t[r],o);return e}},function(e,t,o){var n=o(60),r=Math.max,i=Math.min;e.exports=function(e,t){return e=n(e),0>e?r(e+t,0):i(e,t)}},function(e,t){var o=Math.ceil,n=Math.floor;e.exports=function(e){return isNaN(e=+e)?0:(e>0?n:o)(e)}},function(t,o){t.exports=e},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e){if(!P(e))throw Error('You declared cell type "'+e+'" as a string that is not mapped to a known object.\n Cell type must be an object or a string mapped to an object registered by "Handsontable.cellTypes.registerCellType" method');return A(e)}function i(e,t){var o=t.editor,n=t.renderer,r=t.validator;o&&(0,a.registerEditor)(e,o),n&&(0,u.registerRenderer)(e,n),r&&(0,c.registerValidator)(e,r),H(e,t)}t.__esModule=!0,t.getRegisteredCellTypes=t.getRegisteredCellTypeNames=t.hasCellType=t.getCellType=t.registerCellType=void 0;var s=o(50),l=n(s),a=o(14),u=o(9),c=o(26),h=o(190),d=n(h),f=o(191),p=n(f),g=o(192),v=n(g),m=o(193),y=n(m),w=o(194),C=n(w),b=o(195),S=n(b),E=o(196),R=n(E),O=o(197),k=n(O),T=o(198),_=n(T),M=(0,l.default)("cellTypes"),H=M.register,A=M.getItem,P=M.hasItem,x=M.getNames,D=M.getValues;i("autocomplete",d.default),i("checkbox",p.default),i("date",v.default),i("dropdown",y.default),i("handsontable",C.default),i("numeric",S.default),i("password",R.default),i("text",k.default),i("time",_.default),t.registerCellType=i,t.getCellType=r,t.hasCellType=P,t.getRegisteredCellTypeNames=x,t.getRegisteredCellTypes=D},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e){if(Array.isArray(e)){for(var t=0,o=Array(e.length);e.length>t;t++)o[t]=e[t];return o}return Array.from(e)}function i(e,t){function o(){var e=!1;return{validatorsInQueue:0,valid:!0,addValidatorToQueue:function(){this.validatorsInQueue++,e=!1},removeValidatorFormQueue:function(){this.validatorsInQueue=0>this.validatorsInQueue-1?0:this.validatorsInQueue-1,this.checkIfQueueIsEmpty()},onQueueEmpty:function(e){},checkIfQueueIsEmpty:function(){0==this.validatorsInQueue&&0==e&&(e=!0,this.onQueueEmpty(this.valid))}}}function n(e,t,n){function r(){var o;e.length&&(o=U.runHooks("beforeChange",e,t),(0,d.isFunction)(o)?console.warn("Your beforeChange callback returns a function. It's not supported since Handsontable 0.12.1 (and the returned function will not be executed)."):!1===o&&e.splice(0,e.length)),n()}var i=new o;i.onQueueEmpty=r;for(var s=e.length-1;s>=0;s--)if(null===e[s])e.splice(s,1);else{var l=e[s][0],a=_.propToCol(e[s][1]),h=U.getCellMeta(l,a);if("numeric"===h.type&&"string"==typeof e[s][3]&&e[s][3].length>0&&(/^-?[\d\s]*(\.|,)?\d*$/.test(e[s][3])||h.format)){var p=e[s][3].length;u.default.culture((0,f.isUndefined)(h.language)?"en-US":e[s][3].indexOf(".")===p-3&&-1===e[s][3].indexOf(",")?"en-US":h.language);u.default.cultureData(u.default.culture());e[s][3]=u.default.validate(e[s][3])&&!isNaN(e[s][3])?parseFloat(e[s][3]):(0,u.default)().unformat(e[s][3])||e[s][3]}U.getCellValidator(h)&&(i.addValidatorToQueue(),U.validateCell(e[s][3],h,function(t,o){return function(n){if("boolean"!=typeof n)throw Error("Validation error: result is not boolean");if(!1===n&&!1===o.allowInvalid){e.splice(t,1),o.valid=!0;var r=U.getCell(o.row,o.col);(0,c.removeClass)(r,U.getSettings().invalidCellClassName),--t}i.removeValidatorFormQueue()}}(s,h),t))}i.checkIfQueueIsEmpty()}function i(e,t){var o=e.length-1;if(o>=0){for(;o>=0;o--){var n=!1;if(null!==e[o]){if(null!=e[o][2]||null!=e[o][3]){if(w.settings.allowInsertRow)for(;e[o][0]>U.countRows()-1;){var r=_.createRow(void 0,void 0,t);if(0===r){n=!0;break}}if(!n){if("array"===U.dataType&&(!w.settings.columns||0===w.settings.columns.length)&&w.settings.allowInsertColumn)for(;_.propToCol(e[o][1])>U.countCols()-1;)_.createCol(void 0,void 0,t);_.set(e[o][0],e[o][1],e[o][3])}}}else e.splice(o,1)}U.forceFullRender=!0,N.adjustRowsAndCols(),U.runHooks("beforeChangeRender",e,t),j.refreshBorders(null,!0),U.view.wt.wtOverlays.adjustElementsSize(),U.runHooks("afterChange",e,t||"edit");var i=U.getActiveEditor();i&&(0,f.isDefined)(i.refreshValue)&&i.refreshValue()}}function a(e,t,o){return"object"===(void 0===e?"undefined":l(e))?e:[[e,t,o]]}function g(e){if((0,b.hasOwnProperty)(e,"type")){var t,o={};"object"===l(e.type)?t=e.type:"string"==typeof e.type&&(t=(0,B.getCellType)(e.type));for(var n in t)(0,b.hasOwnProperty)(t,n)&&!(0,b.hasOwnProperty)(e,n)&&(o[n]=t[n]);return o}}function m(){throw Error("This method cannot be called because this Handsontable instance has been destroyed")}var w,_,H,N,j,V,z=arguments.length>2&&void 0!==arguments[2]&&arguments[2],U=this,K=function(){},Y=new C.default(U);(0,b.extend)(K.prototype,W.default.prototype),(0,b.extend)(K.prototype,t),(0,b.extend)(K.prototype,g(t)),(0,D.hasValidParameter)(z)&&(0,D.registerAsRootInstance)(this),this.rootElement=e,this.isHotTableEnv=(0,c.isChildOfWebComponentTable)(this.rootElement),C.default.isHotTableEnv=this.isHotTableEnv,this.container=document.createElement("div"),this.renderCall=!1,e.insertBefore(this.container,e.firstChild),this.guid="ht_"+(0,k.randomString)();var G=(0,x.getTranslator)(U);H=new A.default(U),this.rootElement.id&&"ht_"!==this.rootElement.id.substring(0,3)||(this.rootElement.id=this.guid),w={cellSettings:[],columnSettings:[],columnsSettingConflicts:["data","width"],settings:new K,selRange:null,isPopulated:null,scrollable:null,firstRun:!0},N={alter:function(e,t,o,n,i){function s(e,t,o,n){var i=function(){var e=void 0;return"array"===n?e=[]:"object"===n&&(e={}),e},s=(0,S.arrayMap)(Array(o),function(){return i()});s.unshift(t,0),e.splice.apply(e,r(s))}var l;switch(o=o||1,e){case"insert_row":var a=U.countSourceRows();if(U.getSettings().maxRows===a)return;t=(0,f.isDefined)(t)?t:a,l=_.createRow(t,o,n),s(w.cellSettings,t,o,"array"),l&&(j.isSelected()&&w.selRange.from.row>=t?(w.selRange.from.row+=l,j.transformEnd(l,0)):j.refreshBorders());break;case"insert_col":l=_.createCol(t,o,n);for(var u=0,c=U.countSourceRows();c>u;u++)w.cellSettings[u]&&s(w.cellSettings[u],t,o);if(l){if(Array.isArray(U.getSettings().colHeaders)){var h=[t,0];h.length+=l,Array.prototype.splice.apply(U.getSettings().colHeaders,h)}j.isSelected()&&w.selRange.from.col>=t?(w.selRange.from.col+=l,j.transformEnd(0,l)):j.refreshBorders()}break;case"remove_row":_.removeRow(t,o,n),w.cellSettings.splice(t,o);var d=U.countRows(),p=U.getSettings().fixedRowsTop;t+1>p||(U.getSettings().fixedRowsTop-=Math.min(o,p-t));var g=U.getSettings().fixedRowsBottom;g&&t>=d-g&&(U.getSettings().fixedRowsBottom-=Math.min(o,g)),N.adjustRowsAndCols(),j.refreshBorders();break;case"remove_col":var v=G.toPhysicalColumn(t);_.removeCol(t,o,n);for(var m=0,y=U.countSourceRows();y>m;m++)w.cellSettings[m]&&w.cellSettings[m].splice(v,o);var C=U.getSettings().fixedColumnsLeft;t+1>C||(U.getSettings().fixedColumnsLeft-=Math.min(o,C-t)),Array.isArray(U.getSettings().colHeaders)&&(void 0===v&&(v=-1),U.getSettings().colHeaders.splice(v,o)),N.adjustRowsAndCols(),j.refreshBorders();break;default:throw Error('There is no such action "'+e+'"')}i||N.adjustRowsAndCols()},adjustRowsAndCols:function(){if(w.settings.minRows){var e=U.countRows();if(w.settings.minRows>e)for(var t=0,o=w.settings.minRows;o-e>t;t++)_.createRow(U.countRows(),1,"auto")}if(w.settings.minSpareRows){var n=U.countEmptyRows(!0);if(w.settings.minSpareRows>n)for(;w.settings.minSpareRows>n&&U.countSourceRows()<w.settings.maxRows;n++)_.createRow(U.countRows(),1,"auto")}var r=void 0;if((w.settings.minCols||w.settings.minSpareCols)&&(r=U.countEmptyCols(!0)),w.settings.minCols&&!w.settings.columns&&U.countCols()<w.settings.minCols)for(;U.countCols()<w.settings.minCols;r++)_.createCol(U.countCols(),1,"auto");if(w.settings.minSpareCols&&!w.settings.columns&&"array"===U.dataType&&w.settings.minSpareCols>r)for(;w.settings.minSpareCols>r&&U.countCols()<w.settings.maxCols;r++)_.createCol(U.countCols(),1,"auto");var i=U.countRows(),s=U.countCols();if(0!==i&&0!==s||j.deselect(),j.isSelected()){var l=!1,a=w.selRange.from.row,u=w.selRange.from.col,c=w.selRange.to.row,h=w.selRange.to.col;a>i-1?(a=i-1,l=!0,c>a&&(c=a)):c>i-1&&(c=i-1,l=!0,a>c&&(a=c)),u>s-1?(u=s-1,l=!0,h>u&&(h=u)):h>s-1&&(h=s-1,l=!0,u>h&&(u=h)),l&&U.selectCell(a,u,c,h)}U.view&&U.view.wt.wtOverlays.adjustElementsSize()},populateFromArray:function(e,t,o,n,i,s,a){var u,c,h,d,p=[],g={};if(0===(c=t.length))return!1;var v,m,y,C;switch(i){case"shift_down":for(v=o?o.col-e.col+1:0,m=o?o.row-e.row+1:0,t=(0,P.translateRowsToColumns)(t),h=0,d=t.length,y=Math.max(d,v);y>h;h++)if(d>h){var S;for(u=0,c=t[h].length;m-c>u;u++)t[h].push(t[h][u%c]);t[h].unshift(e.col+h,e.row,0),(S=U).spliceCol.apply(S,r(t[h]))}else{var E;t[h%d][0]=e.col+h,(E=U).spliceCol.apply(E,r(t[h%d]))}break;case"shift_right":for(v=o?o.col-e.col+1:0,m=o?o.row-e.row+1:0,u=0,c=t.length,C=Math.max(c,m);C>u;u++)if(c>u){var R;for(h=0,d=t[u].length;v-d>h;h++)t[u].push(t[u][h%d]);t[u].unshift(e.row+u,e.col,0),(R=U).spliceRow.apply(R,r(t[u]))}else{var O;t[u%c][0]=e.row+u,(O=U).spliceRow.apply(O,r(t[u%c]))}break;case"overwrite":default:g.row=e.row,g.col=e.col;var k={row:o&&e?o.row-e.row+1:1,col:o&&e?o.col-e.col+1:1},T=0,_=0,M=!0,H=void 0,A=function(e){var o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=t[e%t.length];return null!==o?n[o%n.length]:n},x=t.length,D=o?o.row-e.row+1:0;for(c=o?D:Math.max(x,D),u=0;c>u&&(!(o&&g.row>o.row&&D>x||!w.settings.allowInsertRow&&g.row>U.countRows()-1)&&g.row<w.settings.maxRows);u++){var L=u-T,N=A(L).length,I=o?o.col-e.col+1:0;if(d=o?I:Math.max(N,I),g.col=e.col,H=U.getCellMeta(g.row,g.col),"CopyPaste.paste"!==n&&"Autofill.autofill"!==n||!H.skipRowOnPaste){for(_=0,h=0;d>h&&(!(o&&g.col>o.col&&I>N||!w.settings.allowInsertColumn&&g.col>U.countCols()-1)&&g.col<w.settings.maxCols);h++)if(H=U.getCellMeta(g.row,g.col),"CopyPaste.paste"!==n&&"Autofill.fill"!==n||!H.skipColumnOnPaste)if(H.readOnly)g.col++;else{var j=h-_,W=A(L,j),B=U.getDataAtCell(g.row,g.col),F={row:L,col:j};if("Autofill.fill"===n){var V=U.runHooks("beforeAutofillInsidePopulate",F,s,t,a,{},k);V&&(W=(0,f.isUndefined)(V.value)?W:V.value)}if(null!==W&&"object"===(void 0===W?"undefined":l(W)))if(null===B||"object"!==(void 0===B?"undefined":l(B)))M=!1;else{var z=(0,b.duckSchema)(B[0]||B),K=(0,b.duckSchema)(W[0]||W);(0,b.isObjectEquals)(z,K)?W=(0,b.deepClone)(W):M=!1}else null!==B&&"object"===(void 0===B?"undefined":l(B))&&(M=!1);M&&p.push([g.row,g.col,W]),M=!0,g.col++}else _++,g.col++,d++;g.row++}else T++,g.row++,c++}U.setDataAtCell(p,null,null,n||"populateFromArray")}}},this.selection=j={inProgress:!1,selectedHeader:{cols:!1,rows:!1},setSelectedHeaders:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],o=arguments.length>2&&void 0!==arguments[2]&&arguments[2];U.selection.selectedHeader.rows=e,U.selection.selectedHeader.cols=t,U.selection.selectedHeader.corner=o},begin:function(){U.selection.inProgress=!0},finish:function(){var e=U.getSelected();U.runHooks("afterSelectionEnd",e[0],e[1],e[2],e[3]),U.runHooks("afterSelectionEndByProp",e[0],U.colToProp(e[1]),e[2],U.colToProp(e[3])),U.selection.inProgress=!1},isInProgress:function(){return U.selection.inProgress},setRangeStart:function(e,t){U.runHooks("beforeSetRangeStart",e),w.selRange=new L.CellRange(e,e,e),j.setRangeEnd(e,null,t)},setRangeStartOnly:function(e){U.runHooks("beforeSetRangeStartOnly",e),w.selRange=new L.CellRange(e,e,e)},setRangeEnd:function(e,t,o){if(null!==w.selRange){var n,r=!1,i=!0,s=U.view.wt.wtTable.getFirstVisibleRow(),l=U.view.wt.wtTable.getFirstVisibleColumn(),a={row:null,col:null};U.runHooks("beforeSetRangeEnd",e),U.selection.begin(),a.row=0>e.row?s:e.row,a.col=0>e.col?l:e.col,w.selRange.to=new L.CellCoords(a.row,a.col),w.settings.multiSelect||(w.selRange.from=e),U.view.wt.selections.current.clear(),n=U.getCellMeta(w.selRange.highlight.row,w.selRange.highlight.col).disableVisualSelection,"string"==typeof n&&(n=[n]),(!1===n||Array.isArray(n)&&-1===n.indexOf("current"))&&U.view.wt.selections.current.add(w.selRange.highlight),U.view.wt.selections.area.clear(),(!1===n||Array.isArray(n)&&-1===n.indexOf("area"))&&j.isMultiple()&&(U.view.wt.selections.area.add(w.selRange.from),U.view.wt.selections.area.add(w.selRange.to)),(w.settings.currentHeaderClassName||w.settings.currentRowClassName||w.settings.currentColClassName)&&(U.view.wt.selections.highlight.clear(),U.view.wt.selections.highlight.add(w.selRange.from),U.view.wt.selections.highlight.add(w.selRange.to));var u=(0,b.createObjectPropListener)("value");U.runHooks("afterSelection",w.selRange.from.row,w.selRange.from.col,w.selRange.to.row,w.selRange.to.col,u),U.runHooks("afterSelectionByProp",w.selRange.from.row,_.colToProp(w.selRange.from.col),w.selRange.to.row,_.colToProp(w.selRange.to.col),u),(0===w.selRange.from.row&&w.selRange.to.row===U.countRows()-1&&U.countRows()>1||0===w.selRange.from.col&&w.selRange.to.col===U.countCols()-1&&U.countCols()>1)&&(r=!0),(0>e.row||0>e.col)&&(i=!1),u.isTouched()&&(t=!u.value),!1!==t&&!r&&i&&U.view.scrollViewport(w.selRange.from&&!j.isMultiple()?w.selRange.from:e),j.selectedHeader.rows&&j.selectedHeader.cols?(0,c.addClass)(U.rootElement,["ht__selection--rows","ht__selection--columns"]):j.selectedHeader.rows?((0,c.removeClass)(U.rootElement,"ht__selection--columns"),(0,c.addClass)(U.rootElement,"ht__selection--rows")):j.selectedHeader.cols?((0,c.removeClass)(U.rootElement,"ht__selection--rows"),(0,c.addClass)(U.rootElement,"ht__selection--columns")):(0,c.removeClass)(U.rootElement,["ht__selection--rows","ht__selection--columns"]),j.refreshBorders(null,o)}},refreshBorders:function(e,t){t||V.destroyEditor(e),U.view.render(),j.isSelected()&&!t&&V.prepareEditor()},isMultiple:function(){var e=!(w.selRange.to.col===w.selRange.from.col&&w.selRange.to.row===w.selRange.from.row),t=U.runHooks("afterIsMultipleSelection",e);if(e)return t},transformStart:function(e,t,o,n){var r,i,s,l,a=new L.CellCoords(e,t),u=0,c=0;U.runHooks("modifyTransformStart",a),r=U.countRows(),i=U.countCols(),l=U.getSettings().fixedRowsBottom,w.selRange.highlight.row+e>r-1?o&&w.settings.minSpareRows>0&&(!l||r-l-1>w.selRange.highlight.row)?(U.alter("insert_row",r),r=U.countRows()):w.settings.autoWrapCol&&(a.row=1-r,a.col=w.selRange.highlight.col+a.col==i-1?1-i:1):w.settings.autoWrapCol&&0>w.selRange.highlight.row+a.row&&w.selRange.highlight.col+a.col>=0&&(a.row=r-1,a.col=w.selRange.highlight.col+a.col==0?i-1:-1),w.selRange.highlight.col+a.col>i-1?o&&w.settings.minSpareCols>0?(U.alter("insert_col",i),i=U.countCols()):w.settings.autoWrapRow&&(a.row=w.selRange.highlight.row+a.row==r-1?1-r:1,a.col=1-i):w.settings.autoWrapRow&&0>w.selRange.highlight.col+a.col&&w.selRange.highlight.row+a.row>=0&&(a.row=w.selRange.highlight.row+a.row==0?r-1:-1,a.col=i-1),s=new L.CellCoords(w.selRange.highlight.row+a.row,w.selRange.highlight.col+a.col),0>s.row?(u=-1,s.row=0):s.row>0&&s.row>=r&&(u=1,s.row=r-1),0>s.col?(c=-1,s.col=0):s.col>0&&s.col>=i&&(c=1,s.col=i-1),U.runHooks("afterModifyTransformStart",s,u,c),j.setRangeStart(s,n)},transformEnd:function(e,t){var o,n,r,i=new L.CellCoords(e,t),s=0,l=0;U.runHooks("modifyTransformEnd",i),o=U.countRows(),n=U.countCols(),r=new L.CellCoords(w.selRange.to.row+i.row,w.selRange.to.col+i.col),0>r.row?(s=-1,r.row=0):r.row>0&&r.row>=o&&(s=1,r.row=o-1),0>r.col?(l=-1,r.col=0):r.col>0&&r.col>=n&&(l=1,r.col=n-1),U.runHooks("afterModifyTransformEnd",r,s,l),j.setRangeEnd(r,!0)},isSelected:function(){return null!==w.selRange},inInSelection:function(e){return!!j.isSelected()&&w.selRange.includes(e)},deselect:function(){j.isSelected()&&(U.selection.inProgress=!1,w.selRange=null,U.view.wt.selections.current.clear(),U.view.wt.selections.area.clear(),(w.settings.currentHeaderClassName||w.settings.currentRowClassName||w.settings.currentColClassName)&&U.view.wt.selections.highlight.clear(),V.destroyEditor(),j.refreshBorders(),(0,c.removeClass)(U.rootElement,["ht__selection--rows","ht__selection--columns"]),U.runHooks("afterDeselect"))},selectAll:function(){w.settings.multiSelect&&(j.setSelectedHeaders(!0,!0,!0),j.setRangeStart(new L.CellCoords(0,0)),j.setRangeEnd(new L.CellCoords(U.countRows()-1,U.countCols()-1),!1))},empty:function(){if(j.isSelected()){var e,t,o=w.selRange.getTopLeftCorner(),n=w.selRange.getBottomRightCorner(),r=[];for(e=o.row;n.row>=e;e++)for(t=o.col;n.col>=t;t++)U.getCellMeta(e,t).readOnly||r.push([e,t,""]);U.setDataAtCell(r)}}},this.init=function(){H.setData(w.settings.data),U.runHooks("beforeInit"),(0,p.isMobileBrowser)()&&(0,c.addClass)(U.rootElement,"mobile"),this.updateSettings(w.settings,!0),this.view=new M.default(this),V=new y.default(U,w,j,_),this.forceFullRender=!0,U.runHooks("init"),this.view.render(),"object"===l(w.firstRun)&&(U.runHooks("afterChange",w.firstRun[0],w.firstRun[1]),w.firstRun=!1),U.runHooks("afterInit")},this.validateCell=function(e,t,o,n){function r(e){var n=t.visualCol,r=t.visualRow,i=U.getCell(r,n,!0);i&&"TH"!=i.nodeName&&U.view.wt.wtSettings.settings.cellRenderer(r,n,i),o(e)}var i=U.getCellValidator(t);(0,f.isRegExp)(i)&&(i=function(e){return function(t,o){o(e.test(t))}}(i)),(0,d.isFunction)(i)?(e=U.runHooks("beforeValidate",e,t.visualRow,t.prop,n),U._registerTimeout(setTimeout(function(){i.call(t,e,function(o){o=U.runHooks("afterValidate",o,e,t.visualRow,t.prop,n),t.valid=o,r(o),U.runHooks("postAfterValidate",o,e,t.visualRow,t.prop,n)})},0))):U._registerTimeout(setTimeout(function(){t.valid=!0,r(t.valid)},0))},this.setDataAtCell=function(e,t,o,r){var s,u,c,h=a(e,t,o),d=[];for(s=0,u=h.length;u>s;s++){if("object"!==l(h[s]))throw Error("Method `setDataAtCell` accepts row number or changes array of arrays as its first parameter");if("number"!=typeof h[s][1])throw Error("Method `setDataAtCell` accepts row and column number as its parameters. If you want to use object property name, use method `setDataAtRowProp`");c=_.colToProp(h[s][1]),d.push([h[s][0],c,H.getAtCell(G.toPhysicalRow(h[s][0]),h[s][1]),h[s][2]])}r||"object"!==(void 0===e?"undefined":l(e))||(r=t),U.runHooks("afterSetDataAtCell",d,r),n(d,r,function(){i(d,r)})},this.setDataAtRowProp=function(e,t,o,r){var s,u,c=a(e,t,o),h=[];for(s=0,u=c.length;u>s;s++)h.push([c[s][0],c[s][1],H.getAtCell(G.toPhysicalRow(c[s][0]),c[s][1]),c[s][2]]);r||"object"!==(void 0===e?"undefined":l(e))||(r=t),U.runHooks("afterSetDataAtRowProp",h,r),n(h,r,function(){i(h,r)})},this.listen=function(){var e=!document.activeElement||document.activeElement&&void 0===document.activeElement.nodeName;document.activeElement&&document.activeElement!==document.body&&!e?document.activeElement.blur():e&&document.body.focus(),F=U.guid},this.unlisten=function(){this.isListening()&&(F=null)},this.isListening=function(){return F===U.guid},this.destroyEditor=function(e){j.refreshBorders(e)},this.populateFromArray=function(e,t,o,n,r,i,s,a,u){var c;if("object"!==(void 0===o?"undefined":l(o))||"object"!==l(o[0]))throw Error("populateFromArray parameter `input` must be an array of arrays");return c="number"==typeof n?new L.CellCoords(n,r):null,N.populateFromArray(new L.CellCoords(e,t),o,c,i,s,a,u)},this.spliceCol=function(e,t,o){var n;return(n=_).spliceCol.apply(n,arguments)},this.spliceRow=function(e,t,o){var n;return(n=_).spliceRow.apply(n,arguments)},this.getSelected=function(){if(j.isSelected())return[w.selRange.from.row,w.selRange.from.col,w.selRange.to.row,w.selRange.to.col]},this.getSelectedRange=function(){if(j.isSelected())return w.selRange},this.render=function(){U.view&&(U.renderCall=!0,U.forceFullRender=!0,j.refreshBorders(null,!0))},this.loadData=function(e){if(U.dataType=Array.isArray(w.settings.dataSchema)?"array":(0,d.isFunction)(w.settings.dataSchema)?"function":"object",_&&_.destroy(),_=new v.default(U,w,K),"object"===(void 0===e?"undefined":l(e))&&null!==e)e.push&&e.splice||(e=[e]);else{if(null!==e)throw Error("loadData only accepts array of objects or array of arrays ("+(void 0===e?"undefined":l(e))+" given)");e=[];var t,o=0,n=0,r=_.getSchema();for(o=0,n=w.settings.startRows;n>o;o++)if("object"!==U.dataType&&"function"!==U.dataType||!w.settings.dataSchema)if("array"===U.dataType)t=(0,b.deepClone)(r[0]),e.push(t);else{t=[];for(var i=0,s=w.settings.startCols;s>i;i++)t.push(null);e.push(t)}else t=(0,b.deepClone)(r),e.push(t)}w.isPopulated=!1,K.prototype.data=e,Array.isArray(e[0])&&(U.dataType="array"),_.dataSource=e,H.data=e,H.dataType=U.dataType,H.colToProp=_.colToProp.bind(_),H.propToCol=_.propToCol.bind(_),function(){w.cellSettings.length=0}(),N.adjustRowsAndCols(),U.runHooks("afterLoadData",w.firstRun),w.firstRun?w.firstRun=[null,"loadData"]:(U.runHooks("afterChange",null,"loadData"),U.render()),w.isPopulated=!0},this.getData=function(e,t,o,n){return(0,f.isUndefined)(e)?_.getAll():_.getRange(new L.CellCoords(e,t),new L.CellCoords(o,n),_.DESTINATION_RENDERER)},this.getCopyableText=function(e,t,o,n){return _.getCopyableText(new L.CellCoords(e,t),new L.CellCoords(o,n))},this.getCopyableData=function(e,t){return _.getCopyable(e,_.colToProp(t))},this.getSchema=function(){return _.getSchema()},this.updateSettings=function(e,t){var o=!1,n=void 0,r=void 0,i=void 0;if((0,f.isDefined)(e.rows))throw Error('"rows" setting is no longer supported. do you mean startRows, minRows or maxRows?');if((0,f.isDefined)(e.cols))throw Error('"cols" setting is no longer supported. do you mean startCols, minCols or maxCols?');for(n in e)"data"!==n&&(I.default.getSingleton().getRegistered().indexOf(n)>-1?((0,d.isFunction)(e[n])||Array.isArray(e[n]))&&(e[n].initialHook=!0,U.addHook(n,e[n])):!t&&(0,b.hasOwnProperty)(e,n)&&(K.prototype[n]=e[n]));void 0===e.data&&void 0===w.settings.data?U.loadData(null):void 0!==e.data?U.loadData(e.data):void 0!==e.columns&&_.createMap(),i=U.countCols();var s=e.columns||K.prototype.columns;if(s&&(0,d.isFunction)(s)&&(i=U.countSourceCols(),o=!0),void 0===e.cell&&void 0===e.cells&&void 0===e.columns||(w.cellSettings.length=0),i>0){var l=void 0,a=void 0;for(n=0,r=0;i>n;n++)o&&!s(n)||(w.columnSettings[r]=(0,h.columnFactory)(K,w.columnsSettingConflicts),l=w.columnSettings[r].prototype,s&&(a=o?s(n):s[r])&&((0,b.extend)(l,a),(0,b.extend)(l,g(a))),r++)}if((0,f.isDefined)(e.cell))for(var u in e.cell)if((0,b.hasOwnProperty)(e.cell,u)){var p=e.cell[u];U.setCellMetaObject(p.row,p.col,p)}U.runHooks("afterCellMetaReset"),(0,f.isDefined)(e.className)&&(K.prototype.className&&(0,c.removeClass)(U.rootElement,K.prototype.className),e.className&&(0,c.addClass)(U.rootElement,e.className));var v=U.rootElement.style.height;""!==v&&(v=parseInt(U.rootElement.style.height,10));var m=e.height;if((0,d.isFunction)(m)&&(m=m()),t){U.rootElement.getAttribute("style")&&U.rootElement.setAttribute("data-initialstyle",U.rootElement.getAttribute("style"))}if(null===m){var y=U.rootElement.getAttribute("data-initialstyle");y&&(y.indexOf("height")>-1||y.indexOf("overflow")>-1)?U.rootElement.setAttribute("style",y):(U.rootElement.style.height="",U.rootElement.style.overflow="")}else void 0!==m&&(U.rootElement.style.height=m+"px",U.rootElement.style.overflow="hidden");if(void 0!==e.width){var C=e.width;(0,d.isFunction)(C)&&(C=C()),U.rootElement.style.width=C+"px"}t||(_.clearLengthCache(),U.view&&U.view.wt.wtViewport.resetHasOversizedColumnHeadersMarked(),U.runHooks("afterUpdateSettings",e)),N.adjustRowsAndCols(),U.view&&!w.firstRun&&(U.forceFullRender=!0,j.refreshBorders(null,!0)),t||!U.view||""!==v&&""!==m&&void 0!==m||v===m||U.view.wt.wtOverlays.updateMainScrollableElements()},this.getValue=function(){var e=U.getSelected();if(K.prototype.getValue){if((0,d.isFunction)(K.prototype.getValue))return K.prototype.getValue.call(U);if(e)return U.getData()[e[0]][K.prototype.getValue]}else if(e)return U.getDataAtCell(e[0],e[1])},this.getSettings=function(){return w.settings},this.clear=function(){j.selectAll(),j.empty()},this.alter=function(e,t,o,n,r){N.alter(e,t,o,n,r)},this.getCell=function(e,t,o){return U.view.getCellAtCoords(new L.CellCoords(e,t),o)},this.getCoords=function(e){return this.view.wt.wtTable.getCoords.call(this.view.wt.wtTable,e)},this.colToProp=function(e){return _.colToProp(e)},this.propToCol=function(e){return _.propToCol(e)},this.toVisualRow=function(e){return G.toVisualRow(e)},this.toVisualColumn=function(e){return G.toVisualColumn(e)},this.toPhysicalRow=function(e){return G.toPhysicalRow(e)},this.toPhysicalColumn=function(e){return G.toPhysicalColumn(e)},this.getDataAtCell=function(e,t){return _.get(e,_.colToProp(t))},this.getDataAtRowProp=function(e,t){return _.get(e,t)},this.getDataAtCol=function(e){var t=[];return t.concat.apply(t,r(_.getRange(new L.CellCoords(0,e),new L.CellCoords(w.settings.data.length-1,e),_.DESTINATION_RENDERER)))},this.getDataAtProp=function(e){var t,o=[];return t=_.getRange(new L.CellCoords(0,_.propToCol(e)),new L.CellCoords(w.settings.data.length-1,_.propToCol(e)),_.DESTINATION_RENDERER),o.concat.apply(o,r(t))},this.getSourceData=function(e,t,o,n){return void 0===e?H.getData():H.getByRange(new L.CellCoords(e,t),new L.CellCoords(o,n))},this.getSourceDataArray=function(e,t,o,n){return void 0===e?H.getData(!0):H.getByRange(new L.CellCoords(e,t),new L.CellCoords(o,n),!0)},this.getSourceDataAtCol=function(e){return H.getAtColumn(e)},this.getSourceDataAtRow=function(e){return H.getAtRow(e)},this.getSourceDataAtCell=function(e,t){return H.getAtCell(e,t)},this.getDataAtRow=function(e){return _.getRange(new L.CellCoords(e,0),new L.CellCoords(e,this.countCols()-1),_.DESTINATION_RENDERER)[0]||[]},this.getDataType=function(e,t,o,n){var r=this,i=null,s=null;void 0===e&&(e=0,o=this.countRows(),t=0,n=this.countCols()),void 0===o&&(o=e),void 0===n&&(n=t);var l="mixed";return(0,T.rangeEach)(Math.min(e,o),Math.max(e,o),function(e){var o=!0;return(0,T.rangeEach)(Math.min(t,n),Math.max(t,n),function(t){var n=r.getCellMeta(e,t);return s=n.type,i?o=i===s:i=s,o}),l=o?s:"mixed",o}),l},this.removeCellMeta=function(e,t,o){var n=G.toPhysical(e,t),r=s(n,2),i=r[0],l=r[1],a=w.cellSettings[i][l][o];!1!==U.runHooks("beforeRemoveCellMeta",e,t,o,a)&&(delete w.cellSettings[i][l][o],U.runHooks("afterRemoveCellMeta",e,t,o,a)),a=null},this.spliceCellsMeta=function(e,t){for(var o,n=arguments.length,r=Array(n>2?n-2:0),i=2;n>i;i++)r[i-2]=arguments[i];(o=w.cellSettings).splice.apply(o,[e,t].concat(r))},this.setCellMetaObject=function(e,t,o){if("object"===(void 0===o?"undefined":l(o)))for(var n in o)if((0,b.hasOwnProperty)(o,n)){var r=o[n];this.setCellMeta(e,t,n,r)}},this.setCellMeta=function(e,t,o,n){var r=G.toPhysical(e,t),i=s(r,2),l=i[0],a=i[1];w.columnSettings[a]||(w.columnSettings[a]=(0,h.columnFactory)(K,w.columnsSettingConflicts)),w.cellSettings[l]||(w.cellSettings[l]=[]),w.cellSettings[l][a]||(w.cellSettings[l][a]=new w.columnSettings[a]),w.cellSettings[l][a][o]=n,U.runHooks("afterSetCellMeta",e,t,o,n)},this.getCellsMeta=function(){return(0,S.arrayFlatten)(w.cellSettings)},this.getCellMeta=function(e,t){var o=_.colToProp(t),n=void 0,r=G.toPhysical(e,t),i=s(r,2),l=i[0],a=i[1];if(w.columnSettings[a]||(w.columnSettings[a]=(0,h.columnFactory)(K,w.columnsSettingConflicts)),w.cellSettings[l]||(w.cellSettings[l]=[]),w.cellSettings[l][a]||(w.cellSettings[l][a]=new w.columnSettings[a]),n=w.cellSettings[l][a],n.row=l,n.col=a,n.visualRow=e,n.visualCol=t,n.prop=o,n.instance=U,U.runHooks("beforeGetCellMeta",e,t,n),(0,b.extend)(n,g(n)),n.cells){var u=n.cells.call(n,l,a,o);u&&((0,b.extend)(n,u),(0,b.extend)(n,g(u)))}return U.runHooks("afterGetCellMeta",e,t,n),n},this.getCellMetaAtRow=function(e){return w.cellSettings[e]},this.isColumnModificationAllowed=function(){return!("object"===U.dataType||U.getSettings().columns)};var X=(0,P.cellMethodLookupFactory)("renderer");this.getCellRenderer=function(e,t){return(0,R.getRenderer)(X.call(this,e,t))},this.getCellEditor=(0,P.cellMethodLookupFactory)("editor");var q=(0,P.cellMethodLookupFactory)("validator");this.getCellValidator=function(e,t){var o=q.call(this,e,t);return"string"==typeof o&&(o=(0,O.getValidator)(o)),o},this.validateCells=function(e){var t=new o;e&&(t.onQueueEmpty=e);for(var n=U.countRows()-1;n>=0;){for(var r=U.countCols()-1;r>=0;)t.addValidatorToQueue(),U.validateCell(U.getDataAtCell(n,r),U.getCellMeta(n,r),function(e){if("boolean"!=typeof e)throw Error("Validation error: result is not boolean");!1===e&&(t.valid=!1),t.removeValidatorFormQueue()},"validateCells"),r--;n--}t.checkIfQueueIsEmpty()},this.getRowHeader=function(e){var t=w.settings.rowHeaders;return void 0!==e&&(e=U.runHooks("modifyRowHeader",e)),void 0===e?(t=[],(0,T.rangeEach)(U.countRows()-1,function(e){t.push(U.getRowHeader(e))})):Array.isArray(t)&&void 0!==t[e]?t=t[e]:(0,d.isFunction)(t)?t=t(e):t&&"string"!=typeof t&&"number"!=typeof t&&(t=e+1),t},this.hasRowHeaders=function(){return!!w.settings.rowHeaders},this.hasColHeaders=function(){if(void 0!==w.settings.colHeaders&&null!==w.settings.colHeaders)return!!w.settings.colHeaders;for(var e=0,t=U.countCols();t>e;e++)if(U.getColHeader(e))return!0;return!1},this.getColHeader=function(e){var t=w.settings.columns&&(0,d.isFunction)(w.settings.columns),o=w.settings.colHeaders;if(void 0===(e=U.runHooks("modifyColHeader",e))){for(var n=[],r=t?U.countSourceCols():U.countCols(),i=0;r>i;i++)n.push(U.getColHeader(i));o=n}else{var s=e;e=U.runHooks("modifyCol",e);var l=function(e){for(var t=[],o=U.countSourceCols(),n=0;o>n;n++)(0,d.isFunction)(U.getSettings().columns)&&U.getSettings().columns(n)&&t.push(n);return t[e]}(e);w.settings.columns&&(0,d.isFunction)(w.settings.columns)&&w.settings.columns(l)&&w.settings.columns(l).title?o=w.settings.columns(l).title:w.settings.columns&&w.settings.columns[e]&&w.settings.columns[e].title?o=w.settings.columns[e].title:Array.isArray(w.settings.colHeaders)&&void 0!==w.settings.colHeaders[e]?o=w.settings.colHeaders[e]:(0,d.isFunction)(w.settings.colHeaders)?o=w.settings.colHeaders(e):w.settings.colHeaders&&"string"!=typeof w.settings.colHeaders&&"number"!=typeof w.settings.colHeaders&&(o=(0,P.spreadsheetColumnLabel)(s))}return o},this._getColWidthFromSettings=function(e){var t=U.getCellMeta(0,e),o=t.width;if(void 0!==o&&o!==w.settings.width||(o=t.colWidths),void 0!==o&&null!==o){switch(void 0===o?"undefined":l(o)){case"object":o=o[e];break;case"function":o=o(e)}"string"==typeof o&&(o=parseInt(o,10))}return o},this.getColWidth=function(e){var t=U._getColWidthFromSettings(e);return t=U.runHooks("modifyColWidth",t,e),void 0===t&&(t=L.ViewportColumnsCalculator.DEFAULT_WIDTH),t},this._getRowHeightFromSettings=function(e){var t=w.settings.rowHeights;if(void 0!==t&&null!==t){switch(void 0===t?"undefined":l(t)){case"object":t=t[e];break;case"function":t=t(e)}"string"==typeof t&&(t=parseInt(t,10))}return t},this.getRowHeight=function(e){var t=U._getRowHeightFromSettings(e);return t=U.runHooks("modifyRowHeight",t,e)},this.countSourceRows=function(){return U.runHooks("modifySourceLength")||(U.getSourceData()?U.getSourceData().length:0)},this.countSourceCols=function(){var e=U.getSourceData()&&U.getSourceData()[0]?U.getSourceData()[0]:[];return(0,b.isObject)(e)?(0,b.deepObjectSize)(e):e.length||0},this.countRows=function(){return _.getLength()},this.countCols=function(){var e=this.getSettings().maxCols,t=!1,o=0;if("array"===U.dataType&&(t=w.settings.data&&w.settings.data[0]&&w.settings.data[0].length),t&&(o=w.settings.data[0].length),w.settings.columns){if((0,d.isFunction)(w.settings.columns))if("array"===U.dataType){for(var n=0,r=0;o>r;r++)w.settings.columns(r)&&n++;o=n}else"object"!==U.dataType&&"function"!==U.dataType||(o=_.colToPropCache.length);else o=w.settings.columns.length}else"object"!==U.dataType&&"function"!==U.dataType||(o=_.colToPropCache.length);return Math.min(e,o)},this.rowOffset=function(){return U.view.wt.wtTable.getFirstRenderedRow()},this.colOffset=function(){return U.view.wt.wtTable.getFirstRenderedColumn()},this.countRenderedRows=function(){return U.view.wt.drawn?U.view.wt.wtTable.getRenderedRowsCount():-1},this.countVisibleRows=function(){return U.view.wt.drawn?U.view.wt.wtTable.getVisibleRowsCount():-1},this.countRenderedCols=function(){return U.view.wt.drawn?U.view.wt.wtTable.getRenderedColumnsCount():-1},this.countVisibleCols=function(){return U.view.wt.drawn?U.view.wt.wtTable.getVisibleColumnsCount():-1},this.countEmptyRows=function(e){for(var t,o=U.countRows()-1,n=0;o>=0;){if(t=U.runHooks("modifyRow",o),U.isEmptyRow(t))n++;else if(e)break;o--}return n},this.countEmptyCols=function(e){if(1>U.countRows())return 0;for(var t=U.countCols()-1,o=0;t>=0;){if(U.isEmptyCol(t))o++;else if(e)break;t--}return o},this.isEmptyRow=function(e){return w.settings.isEmptyRow.call(U,e)},this.isEmptyCol=function(e){return w.settings.isEmptyCol.call(U,e)},this.selectCell=function(e,t,o,n,r,i){var s;if(i=(0,f.isUndefined)(i)||!0===i,"number"!=typeof e||0>e||e>=U.countRows())return!1;if("number"!=typeof t||0>t||t>=U.countCols())return!1;if((0,f.isDefined)(o)){if("number"!=typeof o||0>o||o>=U.countRows())return!1;if("number"!=typeof n||0>n||n>=U.countCols())return!1}return s=new L.CellCoords(e,t),w.selRange=new L.CellRange(s,s,s),i&&U.listen(),(0,f.isUndefined)(o)?j.setRangeEnd(w.selRange.from,r):j.setRangeEnd(new L.CellCoords(o,n),r),U.selection.finish(),!0},this.selectCellByProp=function(e,t,o,n,r){var i;return arguments[1]=_.propToCol(arguments[1]),(0,f.isDefined)(arguments[3])&&(arguments[3]=_.propToCol(arguments[3])),(i=U).selectCell.apply(i,arguments)},this.deselectCell=function(){j.deselect()},this.scrollViewportTo=function(e,t){var o=arguments.length>2&&void 0!==arguments[2]&&arguments[2],n=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(void 0!==e&&(0>e||e>=U.countRows()))return!1;if(void 0!==t&&(0>t||t>=U.countCols()))return!1;var r=!1;return void 0!==e&&void 0!==t&&(U.view.wt.wtOverlays.topOverlay.scrollTo(e,o),U.view.wt.wtOverlays.leftOverlay.scrollTo(t,n),r=!0),"number"==typeof e&&"number"!=typeof t&&(U.view.wt.wtOverlays.topOverlay.scrollTo(e,o),r=!0),"number"==typeof t&&"number"!=typeof e&&(U.view.wt.wtOverlays.leftOverlay.scrollTo(t,n),r=!0),r},this.destroy=function(){U._clearTimeouts(),U.view&&U.view.destroy(),H&&H.destroy(),H=null;var e=U.rootElement.nextSibling;(0,D.isRootInstance)(U)&&e&&U.rootElement.parentNode.removeChild(e),(0,c.empty)(U.rootElement),Y.destroy(),U.runHooks("afterDestroy"),I.default.getSingleton().destroy(U);for(var t in U)(0,b.hasOwnProperty)(U,t)&&((0,d.isFunction)(U[t])?U[t]=m:"guid"!==t&&(U[t]=null));_&&_.destroy(),_=null,w=null,N=null,j=null,V=null,U=null,K=null},this.getActiveEditor=function(){return V.getActiveEditor()},this.getPlugin=function(e){return(0,E.getPlugin)(this,e)},this.getInstance=function(){return U},this.addHook=function(e,t){I.default.getSingleton().add(e,t,U)},this.hasHook=function(e){return I.default.getSingleton().has(e,U)},this.addHookOnce=function(e,t){I.default.getSingleton().once(e,t,U)},this.removeHook=function(e,t){I.default.getSingleton().remove(e,t,U)},this.runHooks=function(e,t,o,n,r,i,s){return I.default.getSingleton().run(U,e,t,o,n,r,i,s)},this.timeouts=[],this._registerTimeout=function(e){this.timeouts.push(e)},this._clearTimeouts=function(){for(var e=0,t=this.timeouts.length;t>e;e++)clearTimeout(this.timeouts[e])},I.default.getSingleton().run(U,"construct")}t.__esModule=!0;var s=function(){function e(e,t){var o=[],n=!0,r=!1,i=void 0;try{for(var s,l=e[Symbol.iterator]();!(n=(s=l.next()).done)&&(o.push(s.value),!t||o.length!==t);n=!0);}catch(e){r=!0,i=e}finally{try{!n&&l.return&&l.return()}finally{if(r)throw i}}return o}return function(t,o){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,o);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),l="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.default=i;var a=o(87),u=n(a),c=o(0),h=o(65),d=o(35),f=o(20),p=o(25),g=o(199),v=n(g),m=o(201),y=n(m),w=o(4),C=n(w),b=o(1),S=o(2),E=o(5),R=o(9),O=o(26),k=o(27),T=o(6),_=o(271),M=n(_),H=o(200),A=n(H),P=o(64),x=o(154),D=o(90),L=o(11),N=o(8),I=n(N),j=o(88),W=n(j),B=o(62),F=null},function(e,t,o){"use strict";function n(e){for(var t=e+1,o="",n=void 0;t>0;)n=(t-1)%f,o=String.fromCharCode(65+n)+o,t=parseInt((t-n)/f,10);return o}function r(e){var t=0;if(e)for(var o=0,n=e.length-1;e.length>o;o+=1,n-=1)t+=Math.pow(f,n)*(d.indexOf(e[o])+1);return--t}function i(){var e,t,o=arguments.length>0&&void 0!==arguments[0]?arguments[0]:100,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:4,i=[];for(e=0;o>e;e++){var s=[];for(t=0;r>t;t++)s.push(n(t)+(e+1));i.push(s)}return i}function s(){var e,t,o=arguments.length>0&&void 0!==arguments[0]?arguments[0]:100,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:4,i=[];for(e=0;o>e;e++){var s={};for(t=0;r>t;t++)s["prop"+t]=n(t)+(e+1);i.push(s)}return i}function l(e,t){for(var o=[],n=void 0,r=0;e>r;r++){n=[];for(var i=0;t>i;i++)n.push("");o.push(n)}return o}function a(e){var t,o,n,r,i=[],s=0;for(t=0,o=e.length;o>t;t++)for(n=0,r=e[t].length;r>n;n++)n==s&&(i.push([]),s++),i[n].push(e[t][n]);return i}function u(e,t){return t=void 0===t||t,function(o,n){return function o(n){if(n){if((0,h.hasOwnProperty)(n,e)&&void 0!==n[e])return n[e];if((0,h.hasOwnProperty)(n,"type")&&n.type){var r;if("string"!=typeof n.type)throw Error("Cell type must be a string ");if(r=(0,c.getCellType)(n.type),(0,h.hasOwnProperty)(r,e))return r[e];if(t)return}return o(Object.getPrototypeOf(n))}}("number"==typeof o?this.getCellMeta(o,n):o)}}t.__esModule=!0,t.spreadsheetColumnLabel=n,t.spreadsheetColumnIndex=r,t.createSpreadsheetData=i,t.createSpreadsheetObjectData=s,t.createEmptySpreadsheetData=l,t.translateRowsToColumns=a,t.cellMethodLookupFactory=u;var c=o(62),h=o(1),d="ABCDEFGHIJKLMNOPQRSTUVWXYZ",f=d.length},function(e,t,o){"use strict";function n(e,t){function o(){}(0,r.inherit)(o,e);for(var n=0,i=t.length;i>n;n++)o.prototype[t[n]]=void 0;return o}t.__esModule=!0,t.columnFactory=n;var r=o(1)},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=o(0),s=o(2);t.default=function(){function e(t){n(this,e),this.hot=t,this.container=null,this.injected=!1,this.rows=[],this.columns=[],this.samples=null,this.settings={useHeaders:!0}}return r(e,[{key:"addRow",value:function(e,t){if(this.columns.length)throw Error("Doesn't support multi-dimensional table");this.rows.length||(this.container=this.createContainer(this.hot.rootElement.className));var o={row:e};this.rows.push(o),this.samples=t,this.table=this.createTable(this.hot.table.className),this.table.colGroup.appendChild(this.createColGroupsCol()),this.table.tr.appendChild(this.createRow(e)),this.container.container.appendChild(this.table.fragment),o.table=this.table.table}},{key:"addColumnHeadersRow",value:function(e){if(null!=this.hot.getColHeader(0)){var t={row:-1};this.rows.push(t),this.container=this.createContainer(this.hot.rootElement.className),this.samples=e,this.table=this.createTable(this.hot.table.className),this.table.colGroup.appendChild(this.createColGroupsCol()),this.table.tHead.appendChild(this.createColumnHeadersRow()),this.container.container.appendChild(this.table.fragment),t.table=this.table.table}}},{key:"addColumn",value:function(e,t){if(this.rows.length)throw Error("Doesn't support multi-dimensional table");this.columns.length||(this.container=this.createContainer(this.hot.rootElement.className));var o={col:e};this.columns.push(o),this.samples=t,this.table=this.createTable(this.hot.table.className),this.getSetting("useHeaders")&&null!==this.hot.getColHeader(e)&&this.hot.view.appendColHeader(e,this.table.th),this.table.tBody.appendChild(this.createCol(e)),this.container.container.appendChild(this.table.fragment),o.table=this.table.table}},{key:"getHeights",value:function(e){this.injected||this.injectTable(),(0,s.arrayEach)(this.rows,function(t){e(t.row,(0,i.outerHeight)(t.table)-1)})}},{key:"getWidths",value:function(e){this.injected||this.injectTable(),(0,s.arrayEach)(this.columns,function(t){e(t.col,(0,i.outerWidth)(t.table))})}},{key:"setSettings",value:function(e){this.settings=e}},{key:"setSetting",value:function(e,t){this.settings||(this.settings={}),this.settings[e]=t}},{key:"getSettings",value:function(){return this.settings}},{key:"getSetting",value:function(e){return this.settings?this.settings[e]:null}},{key:"createColGroupsCol",value:function(){var e=this,t=document,o=t.createDocumentFragment();return this.hot.hasRowHeaders()&&o.appendChild(this.createColElement(-1)),this.samples.forEach(function(t){(0,s.arrayEach)(t.strings,function(t){o.appendChild(e.createColElement(t.col))})}),o}},{key:"createRow",value:function(e){var t=this,o=document,n=o.createDocumentFragment(),r=o.createElement("th");return this.hot.hasRowHeaders()&&(this.hot.view.appendRowHeader(e,r),n.appendChild(r)),this.samples.forEach(function(r){(0,s.arrayEach)(r.strings,function(r){var i=r.col,s=t.hot.getCellMeta(e,i);s.col=i,s.row=e;var l=t.hot.getCellRenderer(s),a=o.createElement("td");l(t.hot,a,e,i,t.hot.colToProp(i),r.value,s),n.appendChild(a)})}),n}},{key:"createColumnHeadersRow",value:function(){var e=this,t=document,o=t.createDocumentFragment();if(this.hot.hasRowHeaders()){var n=t.createElement("th");this.hot.view.appendColHeader(-1,n),o.appendChild(n)}return this.samples.forEach(function(n){(0,s.arrayEach)(n.strings,function(n){var r=n.col,i=t.createElement("th");e.hot.view.appendColHeader(r,i),o.appendChild(i)})}),o}},{key:"createCol",value:function(e){var t=this,o=document,n=o.createDocumentFragment();return this.samples.forEach(function(r){(0,s.arrayEach)(r.strings,function(r){var i=r.row,s=t.hot.getCellMeta(i,e);s.col=e,s.row=i;var l=t.hot.getCellRenderer(s),a=o.createElement("td"),u=o.createElement("tr");l(t.hot,a,i,e,t.hot.colToProp(e),r.value,s),u.appendChild(a),n.appendChild(u)})}),n}},{key:"clean",value:function(){this.rows.length=0,this.rows[-1]=void 0,this.columns.length=0,this.samples&&this.samples.clear(),this.samples=null,this.removeTable()}},{key:"injectTable",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;this.injected||((e||this.hot.rootElement).appendChild(this.container.fragment),this.injected=!0)}},{key:"removeTable",value:function(){this.injected&&this.container.container.parentNode&&(this.container.container.parentNode.removeChild(this.container.container),this.container=null,this.injected=!1)}},{key:"createColElement",value:function(e){var t=document,o=t.createElement("col");return o.style.width=this.hot.view.wt.wtTable.getStretchedColumnWidth(e)+"px",o}},{key:"createTable",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=document,o=t.createDocumentFragment(),n=t.createElement("table"),r=t.createElement("thead"),s=t.createElement("tbody"),l=t.createElement("colgroup"),a=t.createElement("tr"),u=t.createElement("th");return this.isVertical()&&n.appendChild(l),this.isHorizontal()&&(a.appendChild(u),r.appendChild(a),n.style.tableLayout="auto",n.style.width="auto"),n.appendChild(r),this.isVertical()&&s.appendChild(a),n.appendChild(s),(0,i.addClass)(n,e),o.appendChild(n),{fragment:o,table:n,tHead:r,tBody:s,colGroup:l,tr:a,th:u}}},{key:"createContainer",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=document,o=t.createDocumentFragment(),n=t.createElement("div");return e="htGhostTable htAutoSize "+e.trim(),(0,i.addClass)(n,e),o.appendChild(n),{fragment:o,container:n}}},{key:"isVertical",value:function(){return!(!this.rows.length||this.columns.length)}},{key:"isHorizontal",value:function(){return!(!this.columns.length||this.rows.length)}}]),e}()},function(e,t,o){"use strict";var n=o(37),r=o(168),i=o(45),s=o(23);e.exports=o(167)(Array,"Array",function(e,t){this._t=s(e),this._i=0,this._k=t},function(){var e=this._t,t=this._k,o=this._i++;return e&&e.length>o?"keys"==t?r(0,o):"values"==t?r(0,e[o]):r(0,[o,e[o]]):(this._t=void 0,r(1))},"values"),i.Arguments=i.Array,n("keys"),n("values"),n("entries")},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=o(42),s=function(e){return e&&e.__esModule?e:{default:e}}(i);t.default=function(){function e(t,o,r){n(this,e),this.highlight=t,this.from=o,this.to=r}return r(e,[{key:"isValid",value:function(e){return this.from.isValid(e)&&this.to.isValid(e)}},{key:"isSingle",value:function(){return this.from.row===this.to.row&&this.from.col===this.to.col}},{key:"getHeight",value:function(){return Math.max(this.from.row,this.to.row)-Math.min(this.from.row,this.to.row)+1}},{key:"getWidth",value:function(){return Math.max(this.from.col,this.to.col)-Math.min(this.from.col,this.to.col)+1}},{key:"includes",value:function(e){var t=e.row,o=e.col,n=this.getTopLeftCorner(),r=this.getBottomRightCorner();return!(n.row>t||t>r.row||n.col>o||o>r.col)}},{key:"includesRange",value:function(e){return this.includes(e.getTopLeftCorner())&&this.includes(e.getBottomRightCorner())}},{key:"isEqual",value:function(e){return Math.min(this.from.row,this.to.row)==Math.min(e.from.row,e.to.row)&&Math.max(this.from.row,this.to.row)==Math.max(e.from.row,e.to.row)&&Math.min(this.from.col,this.to.col)==Math.min(e.from.col,e.to.col)&&Math.max(this.from.col,this.to.col)==Math.max(e.from.col,e.to.col)}},{key:"overlaps",value:function(e){return e.isSouthEastOf(this.getTopLeftCorner())&&e.isNorthWestOf(this.getBottomRightCorner())}},{key:"isSouthEastOf",value:function(e){return this.getTopLeftCorner().isSouthEastOf(e)||this.getBottomRightCorner().isSouthEastOf(e)}},{key:"isNorthWestOf",value:function(e){return this.getTopLeftCorner().isNorthWestOf(e)||this.getBottomRightCorner().isNorthWestOf(e)}},{key:"expand",value:function(e){var t=this.getTopLeftCorner(),o=this.getBottomRightCorner();return(t.row>e.row||t.col>e.col||e.row>o.row||e.col>o.col)&&(this.from=new s.default(Math.min(t.row,e.row),Math.min(t.col,e.col)),this.to=new s.default(Math.max(o.row,e.row),Math.max(o.col,e.col)),!0)}},{key:"expandByRange",value:function(t){if(this.includesRange(t)||!this.overlaps(t))return!1;var o=this.getTopLeftCorner(),n=this.getBottomRightCorner(),r=(this.getTopRightCorner(),this.getBottomLeftCorner(),t.getTopLeftCorner()),i=t.getBottomRightCorner(),l=Math.min(o.row,r.row),a=Math.min(o.col,r.col),u=Math.max(n.row,i.row),c=Math.max(n.col,i.col),h=new s.default(l,a),d=new s.default(u,c),f=new e(h,h,d).isCorner(this.from,t),p=t.isEqual(new e(h,h,d));return f&&!p&&(this.from.col>h.col&&(h.col=c,d.col=a),this.from.row>h.row&&(h.row=u,d.row=l)),this.from=h,this.to=d,!0}},{key:"getDirection",value:function(){return this.from.isNorthWestOf(this.to)?"NW-SE":this.from.isNorthEastOf(this.to)?"NE-SW":this.from.isSouthEastOf(this.to)?"SE-NW":this.from.isSouthWestOf(this.to)?"SW-NE":void 0}},{key:"setDirection",value:function(e){switch(e){case"NW-SE":var t=[this.getTopLeftCorner(),this.getBottomRightCorner()];this.from=t[0],this.to=t[1];break;case"NE-SW":var o=[this.getTopRightCorner(),this.getBottomLeftCorner()];this.from=o[0],this.to=o[1];break;case"SE-NW":var n=[this.getBottomRightCorner(),this.getTopLeftCorner()];this.from=n[0],this.to=n[1];break;case"SW-NE":var r=[this.getBottomLeftCorner(),this.getTopRightCorner()];this.from=r[0],this.to=r[1]}}},{key:"getTopLeftCorner",value:function(){return new s.default(Math.min(this.from.row,this.to.row),Math.min(this.from.col,this.to.col))}},{key:"getBottomRightCorner",value:function(){return new s.default(Math.max(this.from.row,this.to.row),Math.max(this.from.col,this.to.col))}},{key:"getTopRightCorner",value:function(){return new s.default(Math.min(this.from.row,this.to.row),Math.max(this.from.col,this.to.col))}},{key:"getBottomLeftCorner",value:function(){return new s.default(Math.max(this.from.row,this.to.row),Math.min(this.from.col,this.to.col))}},{key:"isCorner",value:function(e,t){return!!(t&&t.includes(e)&&(this.getTopLeftCorner().isEqual(new s.default(t.from.row,t.from.col))||this.getTopRightCorner().isEqual(new s.default(t.from.row,t.to.col))||this.getBottomLeftCorner().isEqual(new s.default(t.to.row,t.from.col))||this.getBottomRightCorner().isEqual(new s.default(t.to.row,t.to.col))))||(e.isEqual(this.getTopLeftCorner())||e.isEqual(this.getTopRightCorner())||e.isEqual(this.getBottomLeftCorner())||e.isEqual(this.getBottomRightCorner()))}},{key:"getOppositeCorner",value:function(e,t){if(!(e instanceof s.default))return!1;if(t&&t.includes(e)){if(this.getTopLeftCorner().isEqual(new s.default(t.from.row,t.from.col)))return this.getBottomRightCorner();if(this.getTopRightCorner().isEqual(new s.default(t.from.row,t.to.col)))return this.getBottomLeftCorner();if(this.getBottomLeftCorner().isEqual(new s.default(t.to.row,t.from.col)))return this.getTopRightCorner();if(this.getBottomRightCorner().isEqual(new s.default(t.to.row,t.to.col)))return this.getTopLeftCorner()}return e.isEqual(this.getBottomRightCorner())?this.getTopLeftCorner():e.isEqual(this.getTopLeftCorner())?this.getBottomRightCorner():e.isEqual(this.getTopRightCorner())?this.getBottomLeftCorner():e.isEqual(this.getBottomLeftCorner())?this.getTopRightCorner():void 0}},{key:"getBordersSharedWith",value:function(e){if(!this.includesRange(e))return[];var t={top:Math.min(this.from.row,this.to.row),bottom:Math.max(this.from.row,this.to.row),left:Math.min(this.from.col,this.to.col),right:Math.max(this.from.col,this.to.col)},o={top:Math.min(e.from.row,e.to.row),bottom:Math.max(e.from.row,e.to.row),left:Math.min(e.from.col,e.to.col),right:Math.max(e.from.col,e.to.col)},n=[];return t.top==o.top&&n.push("top"),t.right==o.right&&n.push("right"),t.bottom==o.bottom&&n.push("bottom"),t.left==o.left&&n.push("left"),n}},{key:"getInner",value:function(){for(var e=this.getTopLeftCorner(),t=this.getBottomRightCorner(),o=[],n=e.row;t.row>=n;n++)for(var r=e.col;t.col>=r;r++)this.from.row===n&&this.from.col===r||this.to.row===n&&this.to.col===r||o.push(new s.default(n,r));return o}},{key:"getAll",value:function(){for(var e=this.getTopLeftCorner(),t=this.getBottomRightCorner(),o=[],n=e.row;t.row>=n;n++)for(var r=e.col;t.col>=r;r++)o.push(e.row===n&&e.col===r?e:t.row===n&&t.col===r?t:new s.default(n,r));return o}},{key:"forAll",value:function(e){for(var t=this.getTopLeftCorner(),o=this.getBottomRightCorner(),n=t.row;o.row>=n;n++)for(var r=t.col;o.col>=r;r++){var i=e(n,r);if(!1===i)return}}}]),e}()},function(e,t,o){"use strict";t.__esModule=!0;var n=o(2),r=o(1),i={_localHooks:Object.create(null),addLocalHook:function(e,t){this._localHooks[e]||(this._localHooks[e]=[]),this._localHooks[e].push(t)},runLocalHooks:function(e){for(var t=this,o=arguments.length,r=Array(o>1?o-1:0),i=1;o>i;i++)r[i-1]=arguments[i];this._localHooks[e]&&(0,n.arrayEach)(this._localHooks[e],function(e){return e.apply(t,r)})},clearLocalHooks:function(){this._localHooks={}}};(0,r.defineGetter)(i,"MIXIN_NAME","localHooks",{writable:!1,enumerable:!1}),t.default=i},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t,o){return t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o,e}function i(){var e={};return(0,C.objectEach)(D,function(t,o){e[o]=t()}),e}function s(e,t){-1===x.indexOf(e)&&(D[e]=t)}t.__esModule=!0,t.ITEMS=t.UNDO=t.SEPARATOR=t.ROW_BELOW=t.ROW_ABOVE=t.REMOVE_ROW=t.REMOVE_COLUMN=t.REDO=t.READ_ONLY=t.COLUMN_RIGHT=t.COLUMN_LEFT=t.CLEAR_COLUMN=t.ALIGNMENT=void 0;var l,a=o(225);Object.defineProperty(t,"ALIGNMENT",{enumerable:!0,get:function(){return a.KEY}});var u=o(226);Object.defineProperty(t,"CLEAR_COLUMN",{enumerable:!0,get:function(){return u.KEY}});var c=o(227);Object.defineProperty(t,"COLUMN_LEFT",{enumerable:!0,get:function(){return c.KEY}});var h=o(228);Object.defineProperty(t,"COLUMN_RIGHT",{enumerable:!0,get:function(){return h.KEY}});var d=o(229);Object.defineProperty(t,"READ_ONLY",{enumerable:!0,get:function(){return d.KEY}});var f=o(230);Object.defineProperty(t,"REDO",{enumerable:!0,get:function(){return f.KEY}});var p=o(231);Object.defineProperty(t,"REMOVE_COLUMN",{enumerable:!0,get:function(){return p.KEY}});var g=o(232);Object.defineProperty(t,"REMOVE_ROW",{enumerable:!0,get:function(){return g.KEY}});var v=o(233);Object.defineProperty(t,"ROW_ABOVE",{enumerable:!0,get:function(){return v.KEY}});var m=o(234);Object.defineProperty(t,"ROW_BELOW",{enumerable:!0,get:function(){return m.KEY}});var y=o(71);Object.defineProperty(t,"SEPARATOR",{enumerable:!0,get:function(){return y.KEY}});var w=o(235);Object.defineProperty(t,"UNDO",{enumerable:!0,get:function(){return w.KEY}}),t.predefinedItems=i,t.addItem=s;var C=o(1),b=n(a),S=n(u),E=n(c),R=n(h),O=n(d),k=n(f),T=n(p),_=n(g),M=n(v),H=n(m),A=n(y),P=n(w),x=t.ITEMS=[v.KEY,m.KEY,c.KEY,h.KEY,u.KEY,g.KEY,p.KEY,w.KEY,f.KEY,d.KEY,a.KEY,y.KEY],D=(l={},r(l,y.KEY,A.default),r(l,v.KEY,M.default),r(l,m.KEY,H.default),r(l,c.KEY,E.default),r(l,h.KEY,R.default),r(l,u.KEY,S.default),r(l,g.KEY,_.default),r(l,p.KEY,T.default),r(l,w.KEY,P.default),r(l,f.KEY,k.default),r(l,d.KEY,O.default),r(l,a.KEY,b.default),l)},function(e,t,o){"use strict";function n(){return{name:r}}t.__esModule=!0,t.default=n;var r=t.KEY="---------"},function(e,t){e.exports=function(e){if("function"!=typeof e)throw TypeError(e+" is not a function!");return e}},function(e,t,o){"use strict";var n=o(19),r=o(40);e.exports=function(e,t,o){t in e?n.f(e,t,r(0,o)):e[t]=o}},function(e,t,o){var n=o(15),r=o(13).document,i=n(r)&&n(r.createElement);e.exports=function(e){return i?r.createElement(e):{}}},function(e,t){e.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},function(e,t,o){var n=o(10)("match");e.exports=function(e){var t=/./;try{"/./"[e](t)}catch(o){try{return t[n]=!1,!"/./"[e](t)}catch(e){}}return!0}},function(e,t,o){var n=o(38);e.exports=Object("z").propertyIsEnumerable(0)?Object:function(e){return"String"==n(e)?e.split(""):Object(e)}},function(e,t,o){var n=o(10)("iterator"),r=!1;try{var i=[7][n]();i.return=function(){r=!0},Array.from(i,function(){throw 2})}catch(e){}e.exports=function(e,t){if(!t&&!r)return!1;var o=!1;try{var i=[7],s=i[n]();s.next=function(){return{done:o=!0}},i[n]=function(){return s},e(i)}catch(e){}return o}},function(e,t,o){var n=o(18),r=o(290),i=o(75),s=o(82)("IE_PROTO"),l=function(){},a=function(){var e,t=o(74)("iframe"),n=i.length;for(t.style.display="none",o(160).appendChild(t),t.src="javascript:",e=t.contentWindow.document,e.open(),e.write("<script>document.F=Object<\/script>"),e.close(),a=e.F;n--;)delete a.prototype[i[n]];return a()};e.exports=Object.create||function(e,t){var o;return null!==e?(l.prototype=n(e),o=new l,l.prototype=null,o[s]=e):o=a(),void 0===t?o:r(o,t)}},function(e,t,o){var n=o(47),r=o(40),i=o(23),s=o(86),l=o(22),a=o(161),u=Object.getOwnPropertyDescriptor;t.f=o(21)?u:function(e,t){if(e=i(e),t=s(t,!0),a)try{return u(e,t)}catch(e){}if(l(e,t))return r(!n.f.call(e,t),e[t])}},function(e,t,o){var n=o(170),r=o(75).concat("length","prototype");t.f=Object.getOwnPropertyNames||function(e){return n(e,r)}},function(e,t,o){var n=o(83)("keys"),r=o(49);e.exports=function(e){return n[e]||(n[e]=r(e))}},function(e,t,o){var n=o(13),r=n["__core-js_shared__"]||(n["__core-js_shared__"]={});e.exports=function(e){return r[e]||(r[e]={})}},function(e,t,o){var n=o(165),r=o(30);e.exports=function(e,t,o){if(n(t))throw TypeError("String#"+o+" doesn't accept regex!");return r(e)+""}},function(e,t,o){var n,r,i,s=o(29),l=o(286),a=o(160),u=o(74),c=o(13),h=c.process,d=c.setImmediate,f=c.clearImmediate,p=c.MessageChannel,g=0,v={},m=function(){var e=+this;if(v.hasOwnProperty(e)){var t=v[e];delete v[e],t()}},y=function(e){m.call(e.data)};d&&f||(d=function(e){for(var t=[],o=1;arguments.length>o;)t.push(arguments[o++]);return v[++g]=function(){l("function"==typeof e?e:Function(e),t)},n(g),g},f=function(e){delete v[e]},"process"==o(38)(h)?n=function(e){h.nextTick(s(m,e,1))}:p?(r=new p,i=r.port2,r.port1.onmessage=y,n=s(i.postMessage,i,1)):c.addEventListener&&"function"==typeof postMessage&&!c.importScripts?(n=function(e){c.postMessage(e+"","*")},c.addEventListener("message",y,!1)):n="onreadystatechange"in u("script")?function(e){a.appendChild(u("script")).onreadystatechange=function(){a.removeChild(this),m.call(e)}}:function(e){setTimeout(s(m,e,1),0)}),e.exports={set:d,clear:f}},function(e,t,o){var n=o(15);e.exports=function(e,t){if(!n(e))return e;var o,r;if(t&&"function"==typeof(o=e.toString)&&!n(r=o.call(e)))return r;if("function"==typeof(o=e.valueOf)&&!n(r=o.call(e)))return r;if(!t&&"function"==typeof(o=e.toString)&&!n(r=o.call(e)))return r;throw TypeError("Can't convert object to primitive value")}},function(e,o){e.exports=t},function(e,t,o){"use strict";function n(){}t.__esModule=!0;var r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i=o(20),s=o(1);n.prototype={licenseKey:"trial",data:void 0,dataSchema:void 0,width:void 0,height:void 0,startRows:5,startCols:5,rowHeaders:void 0,colHeaders:null,colWidths:void 0,rowHeights:void 0,columns:void 0,cells:void 0,cell:[],comments:!1,customBorders:!1,minRows:0,minCols:0,maxRows:1/0,maxCols:1/0,minSpareRows:0,minSpareCols:0,allowInsertRow:!0,allowInsertColumn:!0,allowRemoveRow:!0,allowRemoveColumn:!0,multiSelect:!0,fillHandle:!0,fixedRowsTop:0,fixedRowsBottom:0,fixedColumnsLeft:0,outsideClickDeselects:!0,enterBeginsEditing:!0,enterMoves:{row:1,col:0},tabMoves:{row:0,col:1},autoWrapRow:!1,autoWrapCol:!1,persistentState:void 0,currentRowClassName:void 0,currentColClassName:void 0,currentHeaderClassName:"ht__highlight",className:void 0,tableClassName:void 0,stretchH:"none",isEmptyRow:function(e){var t,o,n,l;for(t=0,o=this.countCols();o>t;t++)if(""!==(n=this.getDataAtCell(e,t))&&null!==n&&(0,i.isDefined)(n))return"object"===(void 0===n?"undefined":r(n))&&(l=this.getCellMeta(e,t),(0,s.isObjectEquals)(this.getSchema()[l.prop],n));return!0},isEmptyCol:function(e){var t,o,n;for(t=0,o=this.countRows();o>t;t++)if(""!==(n=this.getDataAtCell(t,e))&&null!==n&&(0,i.isDefined)(n))return!1;return!0},observeDOMVisibility:!0,allowInvalid:!0,allowEmpty:!0,invalidCellClassName:"htInvalid",placeholder:!1,placeholderCellClassName:"htPlaceholder",readOnlyCellClassName:"htDimmed",renderer:void 0,commentedCellClassName:"htCommentCell",fragmentSelection:!1,readOnly:!1,skipColumnOnPaste:!1,search:!1,type:"text",copyable:!0,editor:void 0,autoComplete:void 0,visibleRows:10,trimDropdown:!0,debug:!1,wordWrap:!0,noWordWrapClassName:"htNoWrap",contextMenu:void 0,copyPaste:!0,undo:void 0,columnSorting:void 0,manualColumnMove:void 0,manualColumnResize:void 0,manualRowMove:void 0,manualRowResize:void 0,mergeCells:!1,viewportRowRenderingOffset:"auto",viewportColumnRenderingOffset:"auto",validator:void 0,disableVisualSelection:!1,sortIndicator:void 0,manualColumnFreeze:void 0,trimWhitespace:!0,settings:void 0,source:void 0,title:void 0,checkedTemplate:void 0,uncheckedTemplate:void 0,label:void 0,format:void 0,language:void 0,selectOptions:void 0,autoColumnSize:void 0,autoRowSize:void 0,dateFormat:void 0,correctFormat:!1,defaultDate:void 0,strict:void 0,allowHtml:!1,renderAllRows:void 0,preventOverflow:!1,bindRowsWithHeaders:void 0,collapsibleColumns:void 0,columnSummary:void 0,dropdownMenu:void 0,filters:void 0,formulas:void 0,ganttChart:void 0,headerTooltips:void 0,hiddenColumns:void 0,hiddenRows:void 0,nestedHeaders:void 0,trimRows:void 0,rowHeaderWidth:void 0,columnHeaderHeight:void 0,observeChanges:void 0,sortFunction:void 0,sortByRelevance:!0,filter:!0,filteringCaseSensitive:!1},t.default=n},function(e,t,o){"use strict";function n(e){var t=new Date(e);return isNaN(new Date(e+"T00:00").getDate())?t:new Date(t.getTime()+6e4*t.getTimezoneOffset())}t.__esModule=!0,t.getNormalizedDate=n},function(e,t,o){"use strict";function n(e){s.set(e,!0)}function r(e){return e===l}function i(e){return s.has(e)}t.__esModule=!0,t.registerAsRootInstance=n,t.hasValidParameter=r,t.isRootInstance=i;var s=t.holder=new WeakMap,l=t.rootInstanceSymbol=Symbol("rootInstance")},function(e,t,o){var n=o(3);n(n.P,"Array",{copyWithin:o(279)}),o(37)("copyWithin")},function(e,t,o){var n=o(3);n(n.P,"Array",{fill:o(280)}),o(37)("fill")},function(e,t,o){"use strict";var n=o(3),r=o(52)(6),i="findIndex",s=!0;i in[]&&Array(1)[i](function(){s=!1}),n(n.P+n.F*s,"Array",{findIndex:function(e){return r(this,e,arguments.length>1?arguments[1]:void 0)}}),o(37)(i)},function(e,t,o){"use strict";var n=o(3),r=o(52)(5),i=!0;"find"in[]&&Array(1).find(function(){i=!1}),n(n.P+n.F*i,"Array",{find:function(e){return r(this,e,arguments.length>1?arguments[1]:void 0)}}),o(37)("find")},function(e,t,o){"use strict";var n=o(29),r=o(3),i=o(41),s=o(166),l=o(162),a=o(24),u=o(73),c=o(177);r(r.S+r.F*!o(78)(function(e){Array.from(e)}),"Array",{from:function(e){var t,o,r,h,d=i(e),f="function"==typeof this?this:Array,p=arguments.length,g=p>1?arguments[1]:void 0,v=void 0!==g,m=0,y=c(d);if(v&&(g=n(g,p>2?arguments[2]:void 0,2)),void 0==y||f==Array&&l(y))for(t=a(d.length),o=new f(t);t>m;m++)u(o,m,v?g(d[m],m):d[m]);else for(h=y.call(d),o=new f;!(r=h.next()).done;m++)u(o,m,v?s(h,g,[r.value,m],!0):r.value);return o.length=m,o}})},function(e,t,o){"use strict";var n=o(3),r=o(73);n(n.S+n.F*o(31)(function(){function e(){}return!(Array.of.call(e)instanceof e)}),"Array",{of:function(){for(var e=0,t=arguments.length,o=new("function"==typeof this?this:Array)(t);t>e;)r(o,e,arguments[e++]);return o.length=t,o}})},function(e,t,o){var n=o(19).f,r=o(40),i=o(22),s=Function.prototype,l=/^\s*function ([^ (]*)/,a=Object.isExtensible||function(){return!0};"name"in s||o(21)&&n(s,"name",{configurable:!0,get:function(){try{var e=this,t=(""+e).match(l)[1];return i(e,"name")||!a(e)||n(e,"name",r(5,t)),t}catch(e){return""}}})},function(e,t,o){"use strict";var n=o(158);e.exports=o(53)("Map",function(e){return function(){return e(this,arguments.length>0?arguments[0]:void 0)}},{get:function(e){var t=n.getEntry(this,e);return t&&t.v},set:function(e,t){return n.def(this,0===e?0:e,t)}},n,!0)},function(e,t,o){var n=o(3);n(n.S,"Number",{EPSILON:Math.pow(2,-52)})},function(e,t,o){var n=o(3),r=o(13).isFinite;n(n.S,"Number",{isFinite:function(e){return"number"==typeof e&&r(e)}})},function(e,t,o){var n=o(3);n(n.S,"Number",{isInteger:o(164)})},function(e,t,o){var n=o(3);n(n.S,"Number",{isNaN:function(e){return e!=e}})},function(e,t,o){var n=o(3),r=o(164),i=Math.abs;n(n.S,"Number",{isSafeInteger:function(e){return r(e)&&9007199254740991>=i(e)}})},function(e,t,o){var n=o(3);n(n.S,"Number",{MAX_SAFE_INTEGER:9007199254740991})},function(e,t,o){var n=o(3);n(n.S,"Number",{MIN_SAFE_INTEGER:-9007199254740991})},function(e,t,o){var n=o(3);n(n.S+n.F,"Object",{assign:o(169)})},function(e,t,o){var n=o(3);n(n.S,"Object",{is:o(294)})},function(e,t,o){var n=o(3);n(n.S,"Object",{setPrototypeOf:o(172).set})},function(e,t,o){"use strict";var n,r,i,s=o(56),l=o(13),a=o(29),u=o(157),c=o(3),h=o(15),d=o(72),f=o(51),p=o(55),g=o(295),v=o(85).set,m=o(289)(),y=l.TypeError,w=l.process,C=l.Promise,w=l.process,b="process"==u(w),S=function(){},E=!!function(){try{var e=C.resolve(1),t=(e.constructor={})[o(10)("species")]=function(e){e(S,S)};return(b||"function"==typeof PromiseRejectionEvent)&&e.then(S)instanceof t}catch(e){}}(),R=function(e,t){return e===t||e===C&&t===i},O=function(e){var t;return!(!h(e)||"function"!=typeof(t=e.then))&&t},k=function(e){return R(C,e)?new T(e):new r(e)},T=r=function(e){var t,o;this.promise=new e(function(e,n){if(void 0!==t||void 0!==o)throw y("Bad Promise constructor");t=e,o=n}),this.resolve=d(t),this.reject=d(o)},_=function(e){try{e()}catch(e){return{error:e}}},M=function(e,t){if(!e._n){e._n=!0;var o=e._c;m(function(){for(var n=e._v,r=1==e._s,i=0;o.length>i;)!function(t){var o,i,s=r?t.ok:t.fail,l=t.resolve,a=t.reject,u=t.domain;try{s?(r||(2==e._h&&P(e),e._h=1),!0===s?o=n:(u&&u.enter(),o=s(n),u&&u.exit()),o===t.promise?a(y("Promise-chain cycle")):(i=O(o))?i.call(o,l,a):l(o)):a(n)}catch(e){a(e)}}(o[i++]);e._c=[],e._n=!1,t&&!e._h&&H(e)})}},H=function(e){v.call(l,function(){var t,o,n,r=e._v;if(A(e)&&(t=_(function(){b?w.emit("unhandledRejection",r,e):(o=l.onunhandledrejection)?o({promise:e,reason:r}):(n=l.console)&&n.error&&n.error("Unhandled promise rejection",r)}),e._h=b||A(e)?2:1),e._a=void 0,t)throw t.error})},A=function(e){if(1==e._h)return!1;for(var t,o=e._a||e._c,n=0;o.length>n;)if(t=o[n++],t.fail||!A(t.promise))return!1;return!0},P=function(e){v.call(l,function(){var t;b?w.emit("rejectionHandled",e):(t=l.onrejectionhandled)&&t({promise:e,reason:e._v})})},x=function(e){var t=this;t._d||(t._d=!0,t=t._w||t,t._v=e,t._s=2,t._a||(t._a=t._c.slice()),M(t,!0))},D=function(e){var t,o=this;if(!o._d){o._d=!0,o=o._w||o;try{if(o===e)throw y("Promise can't be resolved itself");(t=O(e))?m(function(){var n={_w:o,_d:!1};try{t.call(e,a(D,n,1),a(x,n,1))}catch(e){x.call(n,e)}}):(o._v=e,o._s=1,M(o,!1))}catch(e){x.call({_w:o,_d:!1},e)}}};E||(C=function(e){f(this,C,"Promise","_h"),d(e),n.call(this);try{e(a(D,this,1),a(x,this,1))}catch(e){x.call(this,e)}},n=function(e){this._c=[],this._a=void 0,this._s=0,this._d=!1,this._v=void 0,this._h=0,this._n=!1},n.prototype=o(58)(C.prototype,{then:function(e,t){var o=k(g(this,C));return o.ok="function"!=typeof e||e,o.fail="function"==typeof t&&t,o.domain=b?w.domain:void 0,this._c.push(o),this._a&&this._a.push(o),this._s&&M(this,!1),o.promise},catch:function(e){return this.then(void 0,e)}}),T=function(){var e=new n;this.promise=e,this.resolve=a(D,e,1),this.reject=a(x,e,1)}),c(c.G+c.W+c.F*!E,{Promise:C}),o(48)(C,"Promise"),o(173)("Promise"),i=o(44).Promise,c(c.S+c.F*!E,"Promise",{reject:function(e){var t=k(this);return(0,t.reject)(e),t.promise}}),c(c.S+c.F*(s||!E),"Promise",{resolve:function(e){if(e instanceof C&&R(e.constructor,this))return e;var t=k(this);return(0,t.resolve)(e),t.promise}}),c(c.S+c.F*!(E&&o(78)(function(e){C.all(e).catch(S)})),"Promise",{all:function(e){var t=this,o=k(t),n=o.resolve,r=o.reject,i=_(function(){var o=[],i=0,s=1;p(e,!1,function(e){var l=i++,a=!1;o.push(void 0),s++,t.resolve(e).then(function(e){a||(a=!0,o[l]=e,--s||n(o))},r)}),--s||n(o)});return i&&r(i.error),o.promise},race:function(e){var t=this,o=k(t),n=o.reject,r=_(function(){p(e,!1,function(e){t.resolve(e).then(o.resolve,n)})});return r&&n(r.error),o.promise}})},function(e,t,o){o(21)&&"g"!=/./g.flags&&o(19).f(RegExp.prototype,"flags",{configurable:!0,get:o(284)})},function(e,t,o){o(54)("match",1,function(e,t,o){return[function(o){"use strict";var n=e(this),r=void 0==o?void 0:o[t];return void 0!==r?r.call(o,n):RegExp(o)[t](n+"")},o]})},function(e,t,o){o(54)("replace",2,function(e,t,o){return[function(n,r){"use strict";var i=e(this),s=void 0==n?void 0:n[t];return void 0!==s?s.call(n,i,r):o.call(i+"",n,r)},o]})},function(e,t,o){o(54)("search",1,function(e,t,o){return[function(o){"use strict";var n=e(this),r=void 0==o?void 0:o[t];return void 0!==r?r.call(o,n):RegExp(o)[t](n+"")},o]})},function(e,t,o){o(54)("split",2,function(e,t,n){"use strict";var r=o(165),i=n,s=[].push,l="length";if("c"=="abbc".split(/(b)*/)[1]||4!="test".split(/(?:)/,-1)[l]||2!="ab".split(/(?:ab)*/)[l]||4!=".".split(/(.?)(.?)/)[l]||".".split(/()()/)[l]>1||"".split(/.?/)[l]){var a=void 0===/()??/.exec("")[1];n=function(e,t){var o=this+"";if(void 0===e&&0===t)return[];if(!r(e))return i.call(o,e,t);var n,u,c,h,d,f=[],p=(e.ignoreCase?"i":"")+(e.multiline?"m":"")+(e.unicode?"u":"")+(e.sticky?"y":""),g=0,v=void 0===t?4294967295:t>>>0,m=RegExp(e.source,p+"g");for(a||(n=RegExp("^"+m.source+"$(?!\\s)",p));(u=m.exec(o))&&((c=u.index+u[0][l])<=g||(f.push(o.slice(g,u.index)),!a&&u[l]>1&&u[0].replace(n,function(){for(d=1;arguments[l]-2>d;d++)void 0===arguments[d]&&(u[d]=void 0)}),u[l]>1&&o[l]>u.index&&s.apply(f,u.slice(1)),h=u[0][l],g=c,v>f[l]));)m.lastIndex===u.index&&m.lastIndex++;return g===o[l]?!h&&m.test("")||f.push(""):f.push(o.slice(g)),f[l]>v?f.slice(0,v):f}}else"0".split(void 0,0)[l]&&(n=function(e,t){return void 0===e&&0===t?[]:i.call(this,e,t)});return[function(o,r){var i=e(this),s=void 0==o?void 0:o[t];return void 0!==s?s.call(o,i,r):n.call(i+"",o,r)},n]})},function(e,t,o){"use strict";var n=o(158);e.exports=o(53)("Set",function(e){return function(){return e(this,arguments.length>0?arguments[0]:void 0)}},{add:function(e){return n.def(this,e=0===e?0:e,e)}},n)},function(e,t,o){"use strict";var n=o(3),r=o(296)(!1);n(n.P,"String",{codePointAt:function(e){return r(this,e)}})},function(e,t,o){"use strict";var n=o(3),r=o(24),i=o(84),s="".endsWith;n(n.P+n.F*o(76)("endsWith"),"String",{endsWith:function(e){var t=i(this,e,"endsWith"),o=arguments.length>1?arguments[1]:void 0,n=r(t.length),l=void 0===o?n:Math.min(r(o),n),a=e+"";return s?s.call(t,a,l):t.slice(l-a.length,l)===a}})},function(e,t,o){var n=o(3),r=o(59),i=String.fromCharCode,s=String.fromCodePoint;n(n.S+n.F*(!!s&&1!=s.length),"String",{fromCodePoint:function(e){for(var t,o=[],n=arguments.length,s=0;n>s;){if(t=+arguments[s++],r(t,1114111)!==t)throw RangeError(t+" is not a valid code point");o.push(65536>t?i(t):i(55296+((t-=65536)>>10),t%1024+56320))}return o.join("")}})},function(e,t,o){"use strict";var n=o(3),r=o(84);n(n.P+n.F*o(76)("includes"),"String",{includes:function(e){return!!~r(this,e,"includes").indexOf(e,arguments.length>1?arguments[1]:void 0)}})},function(e,t,o){var n=o(3),r=o(23),i=o(24);n(n.S,"String",{raw:function(e){for(var t=r(e.raw),o=i(t.length),n=arguments.length,s=[],l=0;o>l;)s.push(t[l++]+""),n>l&&s.push(arguments[l]+"");return s.join("")}})},function(e,t,o){var n=o(3);n(n.P,"String",{repeat:o(175)})},function(e,t,o){"use strict";var n=o(3),r=o(24),i=o(84),s="".startsWith;n(n.P+n.F*o(76)("startsWith"),"String",{startsWith:function(e){var t=i(this,e,"startsWith"),o=r(Math.min(arguments.length>1?arguments[1]:void 0,t.length)),n=e+"";return s?s.call(t,n,o):t.slice(o,o+n.length)===n}})},function(e,t,o){"use strict";var n=o(13),r=o(22),i=o(21),s=o(3),l=o(33),a=o(46).KEY,u=o(31),c=o(83),h=o(48),d=o(49),f=o(10),p=o(176),g=o(297),v=o(288),m=o(283),y=o(163),w=o(18),C=o(23),b=o(86),S=o(40),E=o(79),R=o(291),O=o(80),k=o(19),T=o(39),_=O.f,M=k.f,H=R.f,A=n.Symbol,P=n.JSON,x=P&&P.stringify,D=f("_hidden"),L=f("toPrimitive"),N={}.propertyIsEnumerable,I=c("symbol-registry"),j=c("symbols"),W=c("op-symbols"),B=Object.prototype,F="function"==typeof A,V=n.QObject,z=!V||!V.prototype||!V.prototype.findChild,U=i&&u(function(){return 7!=E(M({},"a",{get:function(){return M(this,"a",{value:7}).a}})).a})?function(e,t,o){var n=_(B,t);n&&delete B[t],M(e,t,o),n&&e!==B&&M(B,t,n)}:M,K=function(e){var t=j[e]=E(A.prototype);return t._k=e,t},Y=F&&"symbol"==typeof A.iterator?function(e){return"symbol"==typeof e}:function(e){return e instanceof A},G=function(e,t,o){return e===B&&G(W,t,o),w(e),t=b(t,!0),w(o),r(j,t)?(o.enumerable?(r(e,D)&&e[D][t]&&(e[D][t]=!1),o=E(o,{enumerable:S(0,!1)})):(r(e,D)||M(e,D,S(1,{})),e[D][t]=!0),U(e,t,o)):M(e,t,o)},X=function(e,t){w(e);for(var o,n=m(t=C(t)),r=0,i=n.length;i>r;)G(e,o=n[r++],t[o]);return e},q=function(e,t){return void 0===t?E(e):X(E(e),t)},Q=function(e){var t=N.call(this,e=b(e,!0));return!(this===B&&r(j,e)&&!r(W,e))&&(!(t||!r(this,e)||!r(j,e)||r(this,D)&&this[D][e])||t)},J=function(e,t){if(e=C(e),t=b(t,!0),e!==B||!r(j,t)||r(W,t)){var o=_(e,t);return!o||!r(j,t)||r(e,D)&&e[D][t]||(o.enumerable=!0),o}},$=function(e){for(var t,o=H(C(e)),n=[],i=0;o.length>i;)r(j,t=o[i++])||t==D||t==a||n.push(t);return n},Z=function(e){for(var t,o=e===B,n=H(o?W:C(e)),i=[],s=0;n.length>s;)!r(j,t=n[s++])||o&&!r(B,t)||i.push(j[t]);return i};F||(A=function(){if(this instanceof A)throw TypeError("Symbol is not a constructor!");var e=d(arguments.length>0?arguments[0]:void 0),t=function(o){this===B&&t.call(W,o),r(this,D)&&r(this[D],e)&&(this[D][e]=!1),U(this,e,S(1,o))};return i&&z&&U(B,e,{configurable:!0,set:t}),K(e)},l(A.prototype,"toString",function(){return this._k}),O.f=J,k.f=G,o(81).f=R.f=$,o(47).f=Q,o(57).f=Z,i&&!o(56)&&l(B,"propertyIsEnumerable",Q,!0),p.f=function(e){return K(f(e))}),s(s.G+s.W+s.F*!F,{Symbol:A});for(var ee="hasInstance,isConcatSpreadable,iterator,match,replace,search,species,split,toPrimitive,toStringTag,unscopables".split(","),te=0;ee.length>te;)f(ee[te++]);for(var ee=T(f.store),te=0;ee.length>te;)g(ee[te++]);s(s.S+s.F*!F,"Symbol",{for:function(e){return r(I,e+="")?I[e]:I[e]=A(e)},keyFor:function(e){if(Y(e))return v(I,e);throw TypeError(e+" is not a symbol!")},useSetter:function(){z=!0},useSimple:function(){z=!1}}),s(s.S+s.F*!F,"Object",{create:q,defineProperty:G,defineProperties:X,getOwnPropertyDescriptor:J,getOwnPropertyNames:$,getOwnPropertySymbols:Z}),P&&s(s.S+s.F*(!F||u(function(){var e=A();return"[null]"!=x([e])||"{}"!=x({a:e})||"{}"!=x(Object(e))})),"JSON",{stringify:function(e){if(void 0!==e&&!Y(e)){for(var t,o,n=[e],r=1;arguments.length>r;)n.push(arguments[r++]);return t=n[1],"function"==typeof t&&(o=t),!o&&y(t)||(t=function(e,t){if(o&&(t=o.call(this,e,t)),!Y(t))return t}),n[1]=t,x.apply(P,n)}}}),A.prototype[L]||o(32)(A.prototype,L,A.prototype.valueOf),h(A,"Symbol"),h(Math,"Math",!0),h(n.JSON,"JSON",!0)},function(e,t,o){"use strict";var n,r=o(52)(0),i=o(33),s=o(46),l=o(169),a=o(159),u=o(15),c=s.getWeak,h=Object.isExtensible,d=a.ufstore,f={},p=function(e){return function(){return e(this,arguments.length>0?arguments[0]:void 0)}},g={get:function(e){if(u(e)){var t=c(e);return!0===t?d(this).get(e):t?t[this._i]:void 0}},set:function(e,t){return a.def(this,e,t)}},v=e.exports=o(53)("WeakMap",p,g,a,!0,!0);7!=(new v).set((Object.freeze||Object)(f),7).get(f)&&(n=a.getConstructor(p),l(n.prototype,g),s.NEED=!0,r(["delete","has","get","set"],function(e){var t=v.prototype,o=t[e];i(t,e,function(t,r){if(u(t)&&!h(t)){this._f||(this._f=new n);var i=this._f[e](t,r);return"set"==e?this:i}return o.call(this,t,r)})}))},function(e,t,o){"use strict";var n=o(159);o(53)("WeakSet",function(e){return function(){return e(this,arguments.length>0?arguments[0]:void 0)}},{add:function(e){return n.def(this,e,!0)}},n,!1,!0)},function(e,t,o){"use strict";var n=o(3),r=o(156)(!0);n(n.P,"Array",{includes:function(e){return r(this,e,arguments.length>1?arguments[1]:void 0)}}),o(37)("includes")},function(e,t,o){var n=o(3),r=o(171)(!0);n(n.S,"Object",{entries:function(e){return r(e)}})},function(e,t,o){var n=o(3),r=o(293),i=o(23),s=o(80),l=o(73);n(n.S,"Object",{getOwnPropertyDescriptors:function(e){for(var t,o=i(e),n=s.f,a=r(o),u={},c=0;a.length>c;)l(u,t=a[c++],n(o,t));return u}})},function(e,t,o){var n=o(3),r=o(171)(!1);n(n.S,"Object",{values:function(e){return r(e)}})},function(e,t,o){"use strict";var n=o(3),r=o(174);n(n.P,"String",{padEnd:function(e){return r(this,e,arguments.length>1?arguments[1]:void 0,!1)}})},function(e,t,o){"use strict";var n=o(3),r=o(174);n(n.P,"String",{padStart:function(e){return r(this,e,arguments.length>1?arguments[1]:void 0,!0)}})},function(e,t,o){for(var n=o(67),r=o(33),i=o(13),s=o(32),l=o(45),a=o(10),u=a("iterator"),c=a("toStringTag"),h=l.Array,d=["NodeList","DOMTokenList","MediaList","StyleSheetList","CSSRuleList"],f=0;5>f;f++){var p,g=d[f],v=i[g],m=v&&v.prototype;if(m){m[u]||s(m,u,h),m[c]||s(m,c,g),l[g]=h;for(p in n)m[p]||r(m,p,n[p],!0)}}},function(e,t,o){var n=o(3),r=o(85);n(n.G+n.B,{setImmediate:r.set,clearImmediate:r.clear})},function(e,t,o){"use strict";!function(e){function o(e){return e.split('"').length-1}var n={parse:function(e){var t,n,r,i,s,l,a,u=[],c=0;for(r=e.split("\n"),r.length>1&&""===r[r.length-1]&&r.pop(),t=0,n=r.length;n>t;t+=1){for(r[t]=r[t].split("\t"),i=0,s=r[t].length;s>i;i+=1)u[c]||(u[c]=[]),l&&0===i?(a=u[c].length-1,u[c][a]=u[c][a]+"\n"+r[t][0],l&&1&o(r[t][0])&&(l=!1,u[c][a]=u[c][a].substring(0,u[c][a].length-1).replace(/""/g,'"'))):i===s-1&&0===r[t][i].indexOf('"')&&1&o(r[t][i])?(u[c].push(r[t][i].substring(1).replace(/""/g,'"')),l=!0):(u[c].push(r[t][i].replace(/""/g,'"')),l=!1);l||(c+=1)}return u},stringify:function(e){var t,o,n,r,i,s="";for(t=0,o=e.length;o>t;t+=1){for(r=e[t].length,n=0;r>n;n+=1)n>0&&(s+="\t"),i=e[t][n],"string"==typeof i?i.indexOf("\n")>-1?s+='"'+i.replace(/"/g,'""')+'"':s+=i:s+=null===i||void 0===i?"":i;t!==o-1&&(s+="\n")}return s}};t.parse=n.parse,t.stringify=n.stringify}(window)},function(e,t,o){"use strict";var n,r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i=function(e,t){function o(){this.constructor=e}for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n]);e.prototype=null===t?Object.create(t):(o.prototype=t.prototype,new o)},s=Error;!function(e){function t(e,o){switch(void 0===e?"undefined":r(e)){case"undefined":case"boolean":case"string":case"number":return e===o;case"object":if(null===e)return null===o;if(T(e)){if(!T(o)||e.length!==o.length)return!1;for(var n=0,i=e.length;i>n;n++)if(!t(e[n],o[n]))return!1;return!0}var s=C(o),l=s.length;if(C(e).length!==l)return!1;for(var n=0;l>n;n++)if(!t(e[n],o[n]))return!1;return!0;default:return!1}}function o(e){return-1===e.indexOf("/")&&-1===e.indexOf("~")?e:e.replace(/~/g,"~0").replace(/\//g,"~1")}function n(e){for(var t=0,o=R.length;o>t;t++)if(R[t].obj===e)return R[t]}function l(e,t){for(var o=0,n=e.observers.length;n>o;o++)if(e.observers[o].callback===t)return e.observers[o].observer}function a(e,t){for(var o=0,n=e.observers.length;n>o;o++)if(e.observers[o].observer===t)return void e.observers.splice(o,1)}function u(e,t){t.unobserve()}function c(e){return"object"===(void 0===e?"undefined":r(e))?JSON.parse(JSON.stringify(e)):e}function h(e,t){var o,r=[],i=n(e);if(i?o=l(i,t):(i=new O(e),R.push(i)),o)return o;if(o={},i.value=c(e),t){o.callback=t,o.next=null;var u=this.intervals||[100,1e3,1e4,6e4];if(void 0===u.push)throw new s("jsonpatch.intervals must be an array");var h=0,f=function(){d(o)},p=function(){clearTimeout(o.next),o.next=setTimeout(function(){f(),h=0,o.next=setTimeout(g,u[h++])},0)},g=function e(){f(),h==u.length&&(h=u.length-1),o.next=setTimeout(e,u[h++])};"undefined"!=typeof window&&(window.addEventListener?(window.addEventListener("mousedown",p),window.addEventListener("mouseup",p),window.addEventListener("keydown",p)):(document.documentElement.attachEvent("onmousedown",p),document.documentElement.attachEvent("onmouseup",p),document.documentElement.attachEvent("onkeydown",p))),o.next=setTimeout(g,u[h++])}return o.patches=r,o.object=e,o.unobserve=function(){d(o),clearTimeout(o.next),a(i,o),"undefined"!=typeof window&&(window.removeEventListener?(window.removeEventListener("mousedown",p),window.removeEventListener("mouseup",p),window.removeEventListener("keydown",p)):(document.documentElement.detachEvent("onmousedown",p),document.documentElement.detachEvent("onmouseup",p),document.documentElement.detachEvent("onkeydown",p)))},i.observers.push(new k(t,o)),o}function d(e){for(var t,o=0,n=R.length;n>o;o++)if(R[o].obj===e.object){t=R[o];break}f(t.value,e.object,e.patches,""),e.patches.length&&g(t.value,e.patches);var r=e.patches;return r.length>0&&(e.patches=[],e.callback&&e.callback(r)),r}function f(e,t,n,i){for(var s=C(t),l=C(e),a=!1,u=l.length-1;u>=0;u--){var h=l[u],d=e[h];if(t.hasOwnProperty(h)){var p=t[h];"object"==(void 0===d?"undefined":r(d))&&null!=d&&"object"==(void 0===p?"undefined":r(p))&&null!=p?f(d,p,n,i+"/"+o(h)):d!=p&&(!0,n.push({op:"replace",path:i+"/"+o(h),value:c(p)}))}else n.push({op:"remove",path:i+"/"+o(h)}),a=!0}if(a||s.length!=l.length)for(var u=0;s.length>u;u++){var h=s[u];e.hasOwnProperty(h)||n.push({op:"add",path:i+"/"+o(h),value:c(t[h])})}}function p(e){for(var t,o=0,n=e.length;n>o;){t=e.charCodeAt(o);{if(48>t||t>57)return!1;o++}}return!0}function g(e,t,o){for(var n,r,i=!1,s=0,l=t.length;l>s;){n=t[s],s++;for(var a=n.path||"",u=a.split("/"),c=e,h=1,d=u.length,f=void 0;;){if(r=u[h],o&&void 0===f&&(void 0===c[r]?f=u.slice(0,h).join("/"):h==d-1&&(f=n.path),void 0!==f&&this.validator(n,s-1,e,f)),h++,void 0===r&&h>=d){i=E[n.op].call(n,c,r,e);break}if(T(c)){if("-"===r)r=c.length;else{if(o&&!p(r))throw new _("Expected an unsigned base-10 integer value, making the new referenced value the array element with the zero-based index","OPERATION_PATH_ILLEGAL_ARRAY_INDEX",s-1,n.path,n);r=parseInt(r,10)}if(h>=d){if(o&&"add"===n.op&&r>c.length)throw new _("The specified index MUST NOT be greater than the number of elements in the array","OPERATION_VALUE_OUT_OF_BOUNDS",s-1,n.path,n);i=S[n.op].call(n,c,r,e);break}}else if(r&&-1!=r.indexOf("~")&&(r=r.replace(/~1/g,"/").replace(/~0/g,"~")),h>=d){i=b[n.op].call(n,c,r,e);break}c=c[r]}}return i}function v(e,t){var o=[];return f(e,t,o,""),o}function m(e){if(void 0===e)return!0;if("array"==typeof e||"object"==(void 0===e?"undefined":r(e)))for(var t in e)if(m(e[t]))return!0;return!1}function y(t,o,n,i){if("object"!==(void 0===t?"undefined":r(t))||null===t||T(t))throw new _("Operation is not an object","OPERATION_NOT_AN_OBJECT",o,t,n);if(!b[t.op])throw new _("Operation `op` property is not one of operations defined in RFC-6902","OPERATION_OP_INVALID",o,t,n);if("string"!=typeof t.path)throw new _("Operation `path` property is not a string","OPERATION_PATH_INVALID",o,t,n);if(("move"===t.op||"copy"===t.op)&&"string"!=typeof t.from)throw new _("Operation `from` property is not present (applicable in `move` and `copy` operations)","OPERATION_FROM_REQUIRED",o,t,n);if(("add"===t.op||"replace"===t.op||"test"===t.op)&&void 0===t.value)throw new _("Operation `value` property is not present (applicable in `add`, `replace` and `test` operations)","OPERATION_VALUE_REQUIRED",o,t,n);if(("add"===t.op||"replace"===t.op||"test"===t.op)&&m(t.value))throw new _("Operation `value` property is not present (applicable in `add`, `replace` and `test` operations)","OPERATION_VALUE_CANNOT_CONTAIN_UNDEFINED",o,t,n);if(n)if("add"==t.op){var s=t.path.split("/").length,l=i.split("/").length;if(s!==l+1&&s!==l)throw new _("Cannot perform an `add` operation at the desired path","OPERATION_PATH_CANNOT_ADD",o,t,n)}else if("replace"===t.op||"remove"===t.op||"_get"===t.op){if(t.path!==i)throw new _("Cannot perform the operation at a path that does not exist","OPERATION_PATH_UNRESOLVABLE",o,t,n)}else if("move"===t.op||"copy"===t.op){var a={op:"_get",path:t.from,value:void 0},u=e.validate([a],n);if(u&&"OPERATION_PATH_UNRESOLVABLE"===u.name)throw new _("Cannot perform the operation from a path that does not exist","OPERATION_FROM_UNRESOLVABLE",o,t,n)}}function w(e,t){try{if(!T(e))throw new _("Patch sequence must be an array","SEQUENCE_NOT_AN_ARRAY");if(t)t=JSON.parse(JSON.stringify(t)),g.call(this,t,e,!0);else for(var o=0;e.length>o;o++)this.validator(e[o],o)}catch(e){if(e instanceof _)return e;throw e}}var C=function(e){if(T(e)){for(var t=Array(e.length),o=0;t.length>o;o++)t[o]=""+o;return t}if(Object.keys)return Object.keys(e);var t=[];for(var n in e)e.hasOwnProperty(n)&&t.push(n);return t},b={add:function(e,t){return e[t]=this.value,!0},remove:function(e,t){return delete e[t],!0},replace:function(e,t){return e[t]=this.value,!0},move:function(e,t,o){var n={op:"_get",path:this.from};return g(o,[n]),g(o,[{op:"remove",path:this.from}]),g(o,[{op:"add",path:this.path,value:n.value}]),!0},copy:function(e,t,o){var n={op:"_get",path:this.from};return g(o,[n]),g(o,[{op:"add",path:this.path,value:n.value}]),!0},test:function(e,o){return t(e[o],this.value)},_get:function(e,t){this.value=e[t]}},S={add:function(e,t){return e.splice(t,0,this.value),!0},remove:function(e,t){return e.splice(t,1),!0},replace:function(e,t){return e[t]=this.value,!0},move:b.move,copy:b.copy,test:b.test,_get:b._get},E={add:function(e){E.remove.call(this,e);for(var t in this.value)this.value.hasOwnProperty(t)&&(e[t]=this.value[t]);return!0},remove:function(e){for(var t in e)e.hasOwnProperty(t)&&b.remove.call(this,e,t);return!0},replace:function(e){return g(e,[{op:"remove",path:this.path}]),g(e,[{op:"add",path:this.path,value:this.value}]),!0},move:b.move,copy:b.copy,test:function(e){return JSON.stringify(e)===JSON.stringify(this.value)},_get:function(e){this.value=e}},R=[],O=function(){function e(e){this.observers=[],this.obj=e}return e}(),k=function(){function e(e,t){this.callback=e,this.observer=t}return e}();e.unobserve=u,e.observe=h,e.generate=d;var T;T=Array.isArray?Array.isArray:function(e){return e.push&&"number"==typeof e.length},e.apply=g,e.compare=v;var _=function(e){function t(t,o,n,r,i){e.call(this,t),this.message=t,this.name=o,this.index=n,this.operation=r,this.tree=i}return i(t,e),t}(s);e.JsonPatchError=_,e.Error=_,e.validator=y,e.validate=w}(n||(n={})),t.apply=n.apply,t.observe=n.observe,t.unobserve=n.unobserve,t.generate=n.generate,t.compare=n.compare,t.validate=n.validate,t.validator=n.validator,t.JsonPatchError=n.JsonPatchError,t.Error=n.Error},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var i=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),s=o(0),l=o(7),a=o(1),u=o(25),c=o(4),h=n(c),d=o(42),f=n(d),p=o(28);n(p);t.default=function(){function e(t,o){r(this,e),o&&(this.eventManager=new h.default(t),this.instance=t,this.wot=t,this.settings=o,this.mouseDown=!1,this.main=null,this.top=null,this.left=null,this.bottom=null,this.right=null,this.topStyle=null,this.leftStyle=null,this.bottomStyle=null,this.rightStyle=null,this.cornerDefaultStyle={width:"5px",height:"5px",borderWidth:"2px",borderStyle:"solid",borderColor:"#FFF"},this.corner=null,this.cornerStyle=null,this.createBorders(o),this.registerListeners())}return i(e,[{key:"registerListeners",value:function(){var e=this;this.eventManager.addEventListener(document.body,"mousedown",function(){return e.onMouseDown()}),this.eventManager.addEventListener(document.body,"mouseup",function(){return e.onMouseUp()});for(var t=0,o=this.main.childNodes.length;o>t;t++)!function(t,o){e.eventManager.addEventListener(e.main.childNodes[t],"mouseenter",function(o){return e.onMouseEnter(o,e.main.childNodes[t])})}(t)}},{key:"onMouseDown",value:function(){this.mouseDown=!0}},{key:"onMouseUp",value:function(){this.mouseDown=!1}},{key:"onMouseEnter",value:function(e,t){function o(e){return e.clientY<Math.floor(i.top)||(e.clientY>Math.ceil(i.top+i.height)||(e.clientX<Math.floor(i.left)||(e.clientX>Math.ceil(i.left+i.width)||void 0)))}function n(e){o(e)&&(r.eventManager.removeEventListener(document.body,"mousemove",n),t.style.display="block")}if(this.mouseDown&&this.wot.getSetting("hideBorderOnMouseDownOver")){e.preventDefault(),(0,l.stopImmediatePropagation)(e);var r=this,i=t.getBoundingClientRect();t.style.display="none",this.eventManager.addEventListener(document.body,"mousemove",n)}}},{key:"createBorders",value:function(e){this.main=document.createElement("div");var t=["top","left","bottom","right","corner"],o=this.main.style;o.position="absolute",o.top=0,o.left=0;for(var n=0;5>n;n++){var r=t[n],i=document.createElement("div");i.className="wtBorder "+(this.settings.className||""),this.settings[r]&&this.settings[r].hide&&(i.className+=" hidden"),o=i.style,o.backgroundColor=this.settings[r]&&this.settings[r].color?this.settings[r].color:e.border.color,o.height=this.settings[r]&&this.settings[r].width?this.settings[r].width+"px":e.border.width+"px",o.width=this.settings[r]&&this.settings[r].width?this.settings[r].width+"px":e.border.width+"px",this.main.appendChild(i)}this.top=this.main.childNodes[0],this.left=this.main.childNodes[1],this.bottom=this.main.childNodes[2],this.right=this.main.childNodes[3],this.topStyle=this.top.style,this.leftStyle=this.left.style,this.bottomStyle=this.bottom.style,this.rightStyle=this.right.style,this.corner=this.main.childNodes[4],this.corner.className+=" corner",this.cornerStyle=this.corner.style,this.cornerStyle.width=this.cornerDefaultStyle.width,this.cornerStyle.height=this.cornerDefaultStyle.height,this.cornerStyle.border=[this.cornerDefaultStyle.borderWidth,this.cornerDefaultStyle.borderStyle,this.cornerDefaultStyle.borderColor].join(" "),(0,u.isMobileBrowser)()&&this.createMultipleSelectorHandles(),this.disappear(),this.wot.wtTable.bordersHolder||(this.wot.wtTable.bordersHolder=document.createElement("div"),this.wot.wtTable.bordersHolder.className="htBorders",this.wot.wtTable.spreader.appendChild(this.wot.wtTable.bordersHolder)),this.wot.wtTable.bordersHolder.insertBefore(this.main,this.wot.wtTable.bordersHolder.firstChild)}},{key:"createMultipleSelectorHandles",value:function(){this.selectionHandles={topLeft:document.createElement("DIV"),topLeftHitArea:document.createElement("DIV"),bottomRight:document.createElement("DIV"),bottomRightHitArea:document.createElement("DIV")};this.selectionHandles.topLeft.className="topLeftSelectionHandle",this.selectionHandles.topLeftHitArea.className="topLeftSelectionHandle-HitArea",this.selectionHandles.bottomRight.className="bottomRightSelectionHandle",this.selectionHandles.bottomRightHitArea.className="bottomRightSelectionHandle-HitArea",this.selectionHandles.styles={topLeft:this.selectionHandles.topLeft.style,topLeftHitArea:this.selectionHandles.topLeftHitArea.style,bottomRight:this.selectionHandles.bottomRight.style,bottomRightHitArea:this.selectionHandles.bottomRightHitArea.style};var e={position:"absolute",height:"40px",width:"40px","border-radius":parseInt(40/1.5,10)+"px"};for(var t in e)(0,a.hasOwnProperty)(e,t)&&(this.selectionHandles.styles.bottomRightHitArea[t]=e[t],this.selectionHandles.styles.topLeftHitArea[t]=e[t]);var o={position:"absolute",height:"10px",width:"10px","border-radius":parseInt(10/1.5,10)+"px",background:"#F5F5FF",border:"1px solid #4285c8"};for(var n in o)(0,a.hasOwnProperty)(o,n)&&(this.selectionHandles.styles.bottomRight[n]=o[n],this.selectionHandles.styles.topLeft[n]=o[n]);this.main.appendChild(this.selectionHandles.topLeft),this.main.appendChild(this.selectionHandles.bottomRight),this.main.appendChild(this.selectionHandles.topLeftHitArea),this.main.appendChild(this.selectionHandles.bottomRightHitArea)}},{key:"isPartRange",value:function(e,t){return!(!this.wot.selections.area.cellRange||e==this.wot.selections.area.cellRange.to.row&&t==this.wot.selections.area.cellRange.to.col)}},{key:"updateMultipleSelectionHandlesPosition",value:function(e,t,o,n,r,i){var s=parseInt(this.selectionHandles.styles.topLeft.width,10),l=parseInt(this.selectionHandles.styles.topLeftHitArea.width,10);this.selectionHandles.styles.topLeft.top=parseInt(o-s,10)+"px",this.selectionHandles.styles.topLeft.left=parseInt(n-s,10)+"px",this.selectionHandles.styles.topLeftHitArea.top=parseInt(o-l/4*3,10)+"px",this.selectionHandles.styles.topLeftHitArea.left=parseInt(n-l/4*3,10)+"px",this.selectionHandles.styles.bottomRight.top=parseInt(o+i,10)+"px",this.selectionHandles.styles.bottomRight.left=parseInt(n+r,10)+"px",this.selectionHandles.styles.bottomRightHitArea.top=parseInt(o+i-l/4,10)+"px",this.selectionHandles.styles.bottomRightHitArea.left=parseInt(n+r-l/4,10)+"px",this.settings.border.multipleSelectionHandlesVisible&&this.settings.border.multipleSelectionHandlesVisible()?(this.selectionHandles.styles.topLeft.display="block",this.selectionHandles.styles.topLeftHitArea.display="block",this.isPartRange(e,t)?(this.selectionHandles.styles.bottomRight.display="none",this.selectionHandles.styles.bottomRightHitArea.display="none"):(this.selectionHandles.styles.bottomRight.display="block",this.selectionHandles.styles.bottomRightHitArea.display="block")):(this.selectionHandles.styles.topLeft.display="none",this.selectionHandles.styles.bottomRight.display="none",this.selectionHandles.styles.topLeftHitArea.display="none",this.selectionHandles.styles.bottomRightHitArea.display="none"),e==this.wot.wtSettings.getSetting("fixedRowsTop")||t==this.wot.wtSettings.getSetting("fixedColumnsLeft")?(this.selectionHandles.styles.topLeft.zIndex="9999",this.selectionHandles.styles.topLeftHitArea.zIndex="9999"):(this.selectionHandles.styles.topLeft.zIndex="",this.selectionHandles.styles.topLeftHitArea.zIndex="")}},{key:"appear",value:function(e){if(!this.disabled){var t,o,n,r,i,l,a,c,h,d,p,g,v,m,y,w,C,b;b=this.wot.wtTable.getRenderedRowsCount();for(var S=0;b>S;S++){var E=this.wot.wtTable.rowFilter.renderedToSource(S);if(E>=e[0]&&e[2]>=E){v=E;break}}for(var R=b-1;R>=0;R--){var O=this.wot.wtTable.rowFilter.renderedToSource(R);if(O>=e[0]&&e[2]>=O){y=O;break}}b=this.wot.wtTable.getRenderedColumnsCount();for(var k=0;b>k;k++){var T=this.wot.wtTable.columnFilter.renderedToSource(k);if(T>=e[1]&&e[3]>=T){m=T;break}}for(var _=b-1;_>=0;_--){var M=this.wot.wtTable.columnFilter.renderedToSource(_);if(M>=e[1]&&e[3]>=M){w=M;break}}if(void 0===v||void 0===m)return void this.disappear();t=v!==y||m!==w,o=this.wot.wtTable.getCell(new f.default(v,m)),n=t?this.wot.wtTable.getCell(new f.default(y,w)):o,r=(0,s.offset)(o),i=t?(0,s.offset)(n):r,l=(0,s.offset)(this.wot.wtTable.TABLE),c=r.top,p=i.top+(0,s.outerHeight)(n)-c,d=r.left,g=i.left+(0,s.outerWidth)(n)-d,a=c-l.top-1,h=d-l.left-1;var H=(0,s.getComputedStyle)(o);parseInt(H.borderTopWidth,10)>0&&(a+=1,p=p>0?p-1:0),parseInt(H.borderLeftWidth,10)>0&&(h+=1,g=g>0?g-1:0),this.topStyle.top=a+"px",this.topStyle.left=h+"px",this.topStyle.width=g+"px",this.topStyle.display="block",this.leftStyle.top=a+"px",this.leftStyle.left=h+"px",this.leftStyle.height=p+"px",this.leftStyle.display="block";var A=Math.floor(this.settings.border.width/2);this.bottomStyle.top=a+p-A+"px",this.bottomStyle.left=h+"px",this.bottomStyle.width=g+"px",this.bottomStyle.display="block",this.rightStyle.top=a+"px",this.rightStyle.left=h+g-A+"px",this.rightStyle.height=p+1+"px",this.rightStyle.display="block",(0,u.isMobileBrowser)()||!this.hasSetting(this.settings.border.cornerVisible)||this.isPartRange(y,w)?this.cornerStyle.display="none":(this.cornerStyle.top=a+p-4+"px",this.cornerStyle.left=h+g-4+"px",this.cornerStyle.borderRightWidth=this.cornerDefaultStyle.borderWidth,this.cornerStyle.width=this.cornerDefaultStyle.width,this.cornerStyle.display="none",C=(0,s.getTrimmingContainer)(this.wot.wtTable.TABLE),w===this.wot.getSetting("totalColumns")-1&&n.offsetLeft+(0,s.outerWidth)(n)+parseInt(this.cornerDefaultStyle.width,10)/2>=(0,s.innerWidth)(C)&&(this.cornerStyle.left=Math.floor(h+g-3-parseInt(this.cornerDefaultStyle.width,10)/2)+"px",this.cornerStyle.borderRightWidth=0),y===this.wot.getSetting("totalRows")-1&&n.offsetTop+(0,s.outerHeight)(n)+parseInt(this.cornerDefaultStyle.height,10)/2>=(0,s.innerHeight)(C)&&(this.cornerStyle.top=Math.floor(a+p-3-parseInt(this.cornerDefaultStyle.height,10)/2)+"px",this.cornerStyle.borderBottomWidth=0),this.cornerStyle.display="block"),(0,u.isMobileBrowser)()&&this.updateMultipleSelectionHandlesPosition(v,m,a,h,g,p)}}},{key:"disappear",value:function(){this.topStyle.display="none",this.leftStyle.display="none",this.bottomStyle.display="none",this.rightStyle.display="none",this.cornerStyle.display="none",(0,u.isMobileBrowser)()&&(this.selectionHandles.styles.topLeft.display="none",this.selectionHandles.styles.bottomRight.display="none")}},{key:"hasSetting",value:function(e){return"function"==typeof e?e():!!e}}]),e}()},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=new WeakMap;t.default=function(){function e(t,o,r,s,l,a,u){var c=arguments.length>7&&void 0!==arguments[7]?arguments[7]:function(e){return e};n(this,e),i.set(this,{viewportWidth:t,scrollOffset:o,totalColumns:r,columnWidthFn:s,overrideFn:l,onlyFullyVisible:a,stretchingColumnWidthFn:c}),this.count=0,this.startColumn=null,this.endColumn=null,this.startPosition=null,this.stretchAllRatio=0,this.stretchLastWidth=0,this.stretch=u,this.totalTargetWidth=0,this.needVerifyLastColumnWidth=!0,this.stretchAllColumnsWidth=[],this.calculate()}return r(e,null,[{key:"DEFAULT_WIDTH",get:function(){return 50}}]),r(e,[{key:"calculate",value:function(){for(var e=0,t=!0,o=[],n=void 0,r=i.get(this),s=r.onlyFullyVisible,l=r.overrideFn,a=r.scrollOffset,u=r.totalColumns,c=r.viewportWidth,h=0;u>h;h++){n=this._getColumnWidth(h),e>a||s||(this.startColumn=h);var d=a>0?c+1:c;if(a>e||e+n>a+d||(null==this.startColumn&&(this.startColumn=h),this.endColumn=h),o.push(e),e+=n,s||(this.endColumn=h),e>=a+c){t=!1;break}}if(this.endColumn===u-1&&t)for(this.startColumn=this.endColumn;this.startColumn>0;){var f=o[this.endColumn]+n-o[this.startColumn-1];if(f>c&&s||this.startColumn--,f>c)break}null!==this.startColumn&&l&&l(this),this.startPosition=o[this.startColumn],void 0==this.startPosition&&(this.startPosition=null),null!==this.startColumn&&(this.count=this.endColumn-this.startColumn+1)}},{key:"refreshStretching",value:function(e){if("none"!==this.stretch){this.totalTargetWidth=e;for(var t=i.get(this),o=t.totalColumns,n=0,r=0;o>r;r++){var s=this._getColumnWidth(r),l=t.stretchingColumnWidthFn(void 0,r);"number"==typeof l?e-=l:n+=s}var a=e-n;if("all"===this.stretch&&a>0)this.stretchAllRatio=e/n,this.stretchAllColumnsWidth=[],this.needVerifyLastColumnWidth=!0;else if("last"===this.stretch&&e!==1/0){var u=this._getColumnWidth(o-1),c=a+u;this.stretchLastWidth=0>c?u:c}}}},{key:"getStretchedColumnWidth",value:function(e,t){var o=null;return"all"===this.stretch&&0!==this.stretchAllRatio?o=this._getStretchedAllColumnWidth(e,t):"last"===this.stretch&&0!==this.stretchLastWidth&&(o=this._getStretchedLastColumnWidth(e)),o}},{key:"_getStretchedAllColumnWidth",value:function(e,t){var o=0,n=i.get(this),r=n.totalColumns;if(!this.stretchAllColumnsWidth[e]){var s=Math.round(t*this.stretchAllRatio),l=n.stretchingColumnWidthFn(s,e);this.stretchAllColumnsWidth[e]=void 0===l?s:isNaN(l)?this._getColumnWidth(e):l}if(this.stretchAllColumnsWidth.length===r&&this.needVerifyLastColumnWidth){this.needVerifyLastColumnWidth=!1;for(var a=0;this.stretchAllColumnsWidth.length>a;a++)o+=this.stretchAllColumnsWidth[a];o!==this.totalTargetWidth&&(this.stretchAllColumnsWidth[this.stretchAllColumnsWidth.length-1]+=this.totalTargetWidth-o)}return this.stretchAllColumnsWidth[e]}},{key:"_getStretchedLastColumnWidth",value:function(e){return e===i.get(this).totalColumns-1?this.stretchLastWidth:null}},{key:"_getColumnWidth",value:function(t){var o=i.get(this).columnWidthFn(t);return void 0===o&&(o=e.DEFAULT_WIDTH),o}}]),e}()},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=new WeakMap;t.default=function(){function e(t,o,r,s,l,a,u){n(this,e),i.set(this,{viewportHeight:t,scrollOffset:o,totalRows:r,rowHeightFn:s,overrideFn:l,onlyFullyVisible:a,horizontalScrollbarHeight:u}),this.count=0,this.startRow=null,this.endRow=null,this.startPosition=null,this.calculate()}return r(e,null,[{key:"DEFAULT_HEIGHT",get:function(){return 23}}]),r(e,[{key:"calculate",value:function(){for(var t=0,o=!0,n=[],r=i.get(this),s=r.onlyFullyVisible,l=r.overrideFn,a=r.rowHeightFn,u=r.scrollOffset,c=r.totalRows,h=r.viewportHeight,d=r.horizontalScrollbarHeight||0,f=void 0,p=0;c>p;p++)if(f=a(p),void 0===f&&(f=e.DEFAULT_HEIGHT),t>u||s||(this.startRow=p),u>t||t+f>u+h-d||(null===this.startRow&&(this.startRow=p),this.endRow=p),n.push(t),t+=f,s||(this.endRow=p),t>=u+h-d){o=!1;break}if(this.endRow===c-1&&o)for(this.startRow=this.endRow;this.startRow>0;){var g=n[this.endRow]+f-n[this.startRow-1];if(g>h-d&&s||this.startRow--,g>=h-d)break}null!==this.startRow&&l&&l(this),this.startPosition=n[this.startRow],void 0==this.startPosition&&(this.startPosition=null),null!==this.startRow&&(this.count=this.endRow-this.startRow+1)}}]),e}()},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var i=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),s=o(0),l=o(1),a=o(27),u=o(140),c=n(u),h=o(143),d=n(h),f=o(144),p=n(f),g=o(145),v=n(g),m=o(146),y=n(m),w=o(148),C=n(w);t.default=function(){function e(t){r(this,e);var o=[];if(this.guid="wt_"+(0,a.randomString)(),t.cloneSource?(this.cloneSource=t.cloneSource,this.cloneOverlay=t.cloneOverlay,this.wtSettings=t.cloneSource.wtSettings,this.wtTable=new y.default(this,t.table,t.wtRootElement),this.wtScroll=new p.default(this),this.wtViewport=t.cloneSource.wtViewport,this.wtEvent=new c.default(this),this.selections=this.cloneSource.selections):(this.wtSettings=new v.default(this,t),this.wtTable=new y.default(this,t.table),this.wtScroll=new p.default(this),this.wtViewport=new C.default(this),this.wtEvent=new c.default(this),this.selections=this.getSetting("selections"),this.wtOverlays=new d.default(this),this.exportSettingsAsClassNames()),this.wtTable.THEAD.childNodes.length&&this.wtTable.THEAD.childNodes[0].childNodes.length){for(var n=0,i=this.wtTable.THEAD.childNodes[0].childNodes.length;i>n;n++)o.push(this.wtTable.THEAD.childNodes[0].childNodes[n].innerHTML);this.getSetting("columnHeaders").length||this.update("columnHeaders",[function(e,t){(0,s.fastInnerText)(t,o[e])}])}this.drawn=!1,this.drawInterrupted=!1}return i(e,[{key:"draw",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return this.drawInterrupted=!1,e||(0,s.isVisible)(this.wtTable.TABLE)?this.wtTable.draw(e):this.drawInterrupted=!0,this}},{key:"getCell",value:function(e){if(1>=arguments.length||void 0===arguments[1]||!arguments[1])return this.wtTable.getCell(e);var t=this.wtSettings.getSetting("totalRows"),o=this.wtSettings.getSetting("fixedRowsTop"),n=this.wtSettings.getSetting("fixedRowsBottom"),r=this.wtSettings.getSetting("fixedColumnsLeft");if(o>e.row&&r>e.col)return this.wtOverlays.topLeftCornerOverlay.clone.wtTable.getCell(e);if(o>e.row)return this.wtOverlays.topOverlay.clone.wtTable.getCell(e);if(r>e.col&&e.row>=t-n){if(this.wtOverlays.bottomLeftCornerOverlay&&this.wtOverlays.bottomLeftCornerOverlay.clone)return this.wtOverlays.bottomLeftCornerOverlay.clone.wtTable.getCell(e)}else{if(r>e.col)return this.wtOverlays.leftOverlay.clone.wtTable.getCell(e);if(t>e.row&&e.row>t-n&&this.wtOverlays.bottomOverlay&&this.wtOverlays.bottomOverlay.clone)return this.wtOverlays.bottomOverlay.clone.wtTable.getCell(e)}return this.wtTable.getCell(e)}},{key:"update",value:function(e,t){return this.wtSettings.update(e,t)}},{key:"scrollVertical",value:function(e){return this.wtOverlays.topOverlay.scrollTo(e),this.getSetting("onScrollVertically"),this}},{key:"scrollHorizontal",value:function(e){return this.wtOverlays.leftOverlay.scrollTo(e),this.getSetting("onScrollHorizontally"),this}},{key:"scrollViewport",value:function(e){return this.wtScroll.scrollViewport(e),this}},{key:"getViewport",value:function(){return[this.wtTable.getFirstVisibleRow(),this.wtTable.getFirstVisibleColumn(),this.wtTable.getLastVisibleRow(),this.wtTable.getLastVisibleColumn()]}},{key:"getOverlayName",value:function(){return this.cloneOverlay?this.cloneOverlay.type:"master"}},{key:"isOverlayName",value:function(e){return!!this.cloneOverlay&&this.cloneOverlay.type===e}},{key:"exportSettingsAsClassNames",value:function(){var e=this,t={rowHeaders:["array"],columnHeaders:["array"]},o=[],n=[];(0,l.objectEach)(t,function(t,r){t.indexOf("array")>-1&&e.getSetting(r).length&&n.push("ht"+(0,a.toUpperCaseFirst)(r)),o.push("ht"+(0,a.toUpperCaseFirst)(r))}),(0,s.removeClass)(this.wtTable.wtRootElement.parentNode,o),(0,s.addClass)(this.wtTable.wtRootElement.parentNode,n)}},{key:"getSetting",value:function(e,t,o,n,r){return this.wtSettings.getSetting(e,t,o,n,r)}},{key:"hasSetting",value:function(e){return this.wtSettings.has(e)}},{key:"destroy",value:function(){this.wtOverlays.destroy(),this.wtEvent.destroy()}}]),e}()},function(e,t,o){"use strict";function n(e){var t=this,o=new a.default(e);this.instance=e;var n=[null,null];this.dblClickTimeout=[null,null];var l=function(e){var o=document.activeElement,s=(0,i.partial)(r.getParent,e.realTarget),l=e.realTarget;if(l!==o&&s(0)!==o&&s(1)!==o){var a=t.parentCell(l);(0,r.hasClass)(l,"corner")?t.instance.getSetting("onCellCornerMouseDown",e,l):a.TD&&t.instance.hasSetting("onCellMouseDown")&&t.instance.getSetting("onCellMouseDown",e,a.coords,a.TD,t.instance),2!==e.button&&a.TD&&(n[0]=a.TD,clearTimeout(t.dblClickTimeout[0]),t.dblClickTimeout[0]=setTimeout(function(){n[0]=null},1e3))}},u=function(e){t.instance.touchMoving=!0},c=function(e){o.addEventListener(this,"touchmove",u),t.checkIfTouchMove=setTimeout(function(){!0===t.instance.touchMoving&&(t.instance.touchMoving=void 0,o.removeEventListener("touchmove",u,!1)),l(e)},30)},h=function(e){var o,n,i;t.instance.hasSetting("onCellMouseOver")&&(o=t.instance.wtTable.TABLE,n=(0,r.closestDown)(e.realTarget,["TD","TH"],o),i=t.instance.cloneSource||t.instance,n&&n!==i.lastMouseOver&&(0,r.isChildOf)(n,o)&&(i.lastMouseOver=n,t.instance.getSetting("onCellMouseOver",e,t.instance.wtTable.getCoords(n),n,t.instance)))},d=function(e){var o=void 0,n=void 0,i=void 0;t.instance.hasSetting("onCellMouseOut")&&(o=t.instance.wtTable.TABLE,n=(0,r.closestDown)(e.realTarget,["TD","TH"],o),i=(0,r.closestDown)(e.relatedTarget,["TD","TH"],o),n&&n!==i&&(0,r.isChildOf)(n,o)&&t.instance.getSetting("onCellMouseOut",e,t.instance.wtTable.getCoords(n),n,t.instance))},f=function(e){if(2!==e.button){var o=t.parentCell(e.realTarget);o.TD===n[0]&&o.TD===n[1]?((0,r.hasClass)(e.realTarget,"corner")?t.instance.getSetting("onCellCornerDblClick",e,o.coords,o.TD,t.instance):t.instance.getSetting("onCellDblClick",e,o.coords,o.TD,t.instance),n[0]=null,n[1]=null):o.TD===n[0]?(t.instance.getSetting("onCellMouseUp",e,o.coords,o.TD,t.instance),n[1]=o.TD,clearTimeout(t.dblClickTimeout[1]),t.dblClickTimeout[1]=setTimeout(function(){n[1]=null},500)):o.TD&&t.instance.hasSetting("onCellMouseUp")&&t.instance.getSetting("onCellMouseUp",e,o.coords,o.TD,t.instance)}},p=function(e){clearTimeout(void 0),e.preventDefault(),f(e)};if(o.addEventListener(this.instance.wtTable.holder,"mousedown",l),o.addEventListener(this.instance.wtTable.TABLE,"mouseover",h),o.addEventListener(this.instance.wtTable.TABLE,"mouseout",d),o.addEventListener(this.instance.wtTable.holder,"mouseup",f),this.instance.wtTable.holder.parentNode.parentNode&&(0,s.isMobileBrowser)()&&!t.instance.wtTable.isWorkingOnClone()){var g="."+this.instance.wtTable.holder.parentNode.className.split(" ").join(".");o.addEventListener(this.instance.wtTable.holder,"touchstart",function(e){t.instance.touchApplied=!0,(0,r.isChildOf)(e.target,g)&&c.call(e.target,e)}),o.addEventListener(this.instance.wtTable.holder,"touchend",function(e){t.instance.touchApplied=!1,(0,r.isChildOf)(e.target,g)&&p.call(e.target,e)}),t.instance.momentumScrolling||(t.instance.momentumScrolling={}),o.addEventListener(this.instance.wtTable.holder,"scroll",function(e){clearTimeout(t.instance.momentumScrolling._timeout),t.instance.momentumScrolling.ongoing||t.instance.getSetting("onBeforeTouchScroll"),t.instance.momentumScrolling.ongoing=!0,t.instance.momentumScrolling._timeout=setTimeout(function(){t.instance.touchApplied||(t.instance.momentumScrolling.ongoing=!1,t.instance.getSetting("onAfterMomentumScroll"))},200)})}o.addEventListener(window,"resize",function(){"none"!==t.instance.getSetting("stretchH")&&t.instance.draw()}),this.destroy=function(){clearTimeout(this.dblClickTimeout[0]),clearTimeout(this.dblClickTimeout[1]),o.destroy()}}t.__esModule=!0;var r=o(0),i=o(35),s=o(25),l=o(4),a=function(e){return e&&e.__esModule?e:{default:e}}(l);n.prototype.parentCell=function(e){var t={},o=this.instance.wtTable.TABLE,n=(0,r.closestDown)(e,["TD","TH"],o);return n?(t.coords=this.instance.wtTable.getCoords(n),t.TD=n):(0,r.hasClass)(e,"wtBorder")&&(0,r.hasClass)(e,"current")?(t.coords=this.instance.selections.current.cellRange.highlight,t.TD=this.instance.wtTable.getCell(t.coords)):(0,r.hasClass)(e,"wtBorder")&&(0,r.hasClass)(e,"area")&&this.instance.selections.area.cellRange&&(t.coords=this.instance.selections.area.cellRange.to,t.TD=this.instance.wtTable.getCell(t.coords)),t},t.default=n},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}();t.default=function(){function e(t,o,r){n(this,e),this.offset=t,this.total=o,this.countTH=r}return r(e,[{key:"offsetted",value:function(e){return e+this.offset}},{key:"unOffsetted",value:function(e){return e-this.offset}},{key:"renderedToSource",value:function(e){return this.offsetted(e)}},{key:"sourceToRendered",value:function(e){return this.unOffsetted(e)}},{key:"offsettedTH",value:function(e){return e-this.countTH}},{key:"unOffsettedTH",value:function(e){return e+this.countTH}},{key:"visibleRowHeadedColumnToSourceColumn",value:function(e){return this.renderedToSource(this.offsettedTH(e))}},{key:"sourceColumnToVisibleRowHeadedColumn",value:function(e){return this.unOffsettedTH(this.sourceToRendered(e))}}]),e}()},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}();t.default=function(){function e(t,o,r){n(this,e),this.offset=t,this.total=o,this.countTH=r}return r(e,[{key:"offsetted",value:function(e){return e+this.offset}},{key:"unOffsetted",value:function(e){return e-this.offset}},{key:"renderedToSource",value:function(e){return this.offsetted(e)}},{key:"sourceToRendered",value:function(e){return this.unOffsetted(e)}},{key:"offsettedTH",value:function(e){return e-this.countTH}},{key:"unOffsettedTH",value:function(e){return e+this.countTH}},{key:"visibleColHeadedRowToSourceRow",value:function(e){return this.renderedToSource(this.offsettedTH(e))}},{key:"sourceRowToVisibleColHeadedRow",value:function(e){return this.unOffsettedTH(this.sourceToRendered(e))}}]),e}()},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var i=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),s=o(0),l=o(2),a=o(16),u=o(25),c=o(4),h=n(c),d=o(28),f=n(d);t.default=function(){function e(t){r(this,e),this.wot=t,this.instance=this.wot,this.eventManager=new h.default(this.wot),this.wot.update("scrollbarWidth",(0,s.getScrollbarWidth)()),this.wot.update("scrollbarHeight",(0,s.getScrollbarWidth)()),this.scrollableElement=(0,s.getScrollableElement)(this.wot.wtTable.TABLE),this.prepareOverlays(),this.destroyed=!1,this.keyPressed=!1,this.spreaderLastSize={width:null,height:null},this.overlayScrollPositions={master:{top:0,left:0},top:{top:null,left:0},bottom:{top:null,left:0},left:{top:0,left:null}},this.pendingScrollCallbacks={master:{top:0,left:0},top:{left:0},bottom:{left:0},left:{top:0}},this.verticalScrolling=!1,this.horizontalScrolling=!1,this.delegatedScrollCallback=!1,this.registeredListeners=[],this.registerListeners()}return i(e,[{key:"prepareOverlays",value:function(){var e=!1;return this.topOverlay?e=this.topOverlay.updateStateOfRendering()||e:this.topOverlay=f.default.createOverlay(f.default.CLONE_TOP,this.wot),f.default.hasOverlay(f.default.CLONE_BOTTOM)||(this.bottomOverlay={needFullRender:!1,updateStateOfRendering:function(){return!1}}),f.default.hasOverlay(f.default.CLONE_BOTTOM_LEFT_CORNER)||(this.bottomLeftCornerOverlay={needFullRender:!1,updateStateOfRendering:function(){return!1}}),this.bottomOverlay?e=this.bottomOverlay.updateStateOfRendering()||e:this.bottomOverlay=f.default.createOverlay(f.default.CLONE_BOTTOM,this.wot),this.leftOverlay?e=this.leftOverlay.updateStateOfRendering()||e:this.leftOverlay=f.default.createOverlay(f.default.CLONE_LEFT,this.wot),this.topOverlay.needFullRender&&this.leftOverlay.needFullRender&&(this.topLeftCornerOverlay?e=this.topLeftCornerOverlay.updateStateOfRendering()||e:this.topLeftCornerOverlay=f.default.createOverlay(f.default.CLONE_TOP_LEFT_CORNER,this.wot)),this.bottomOverlay.needFullRender&&this.leftOverlay.needFullRender&&(this.bottomLeftCornerOverlay?e=this.bottomLeftCornerOverlay.updateStateOfRendering()||e:this.bottomLeftCornerOverlay=f.default.createOverlay(f.default.CLONE_BOTTOM_LEFT_CORNER,this.wot)),this.wot.getSetting("debug")&&!this.debug&&(this.debug=f.default.createOverlay(f.default.CLONE_DEBUG,this.wot)),e}},{key:"refreshAll",value:function(){if(this.wot.drawn){if(!this.wot.wtTable.holder.parentNode)return void this.destroy();this.wot.draw(!0),this.verticalScrolling&&this.leftOverlay.onScroll(),this.horizontalScrolling&&this.topOverlay.onScroll(),this.verticalScrolling=!1,this.horizontalScrolling=!1}}},{key:"registerListeners",value:function(){var e=this,t=this.topOverlay.mainTableScrollableElement,o=this.leftOverlay.mainTableScrollableElement,n=[];for(n.push([document.documentElement,"keydown",function(t){return e.onKeyDown(t)}]),n.push([document.documentElement,"keyup",function(){return e.onKeyUp()}]),n.push([document,"visibilitychange",function(){return e.onKeyUp()}]),n.push([t,"scroll",function(t){return e.onTableScroll(t)}]),t!==o&&n.push([o,"scroll",function(t){return e.onTableScroll(t)}]),this.topOverlay.needFullRender&&(n.push([this.topOverlay.clone.wtTable.holder,"scroll",function(t){return e.onTableScroll(t)}]),n.push([this.topOverlay.clone.wtTable.holder,"wheel",function(t){return e.onTableScroll(t)}])),this.bottomOverlay.needFullRender&&(n.push([this.bottomOverlay.clone.wtTable.holder,"scroll",function(t){return e.onTableScroll(t)}]),n.push([this.bottomOverlay.clone.wtTable.holder,"wheel",function(t){return e.onTableScroll(t)}])),this.leftOverlay.needFullRender&&(n.push([this.leftOverlay.clone.wtTable.holder,"scroll",function(t){return e.onTableScroll(t)}]),n.push([this.leftOverlay.clone.wtTable.holder,"wheel",function(t){return e.onTableScroll(t)}])),this.topLeftCornerOverlay&&this.topLeftCornerOverlay.needFullRender&&n.push([this.topLeftCornerOverlay.clone.wtTable.holder,"wheel",function(t){return e.onTableScroll(t)}]),this.bottomLeftCornerOverlay&&this.bottomLeftCornerOverlay.needFullRender&&n.push([this.bottomLeftCornerOverlay.clone.wtTable.holder,"wheel",function(t){return e.onTableScroll(t)}]),this.topOverlay.trimmingContainer!==window&&this.leftOverlay.trimmingContainer!==window&&n.push([window,"wheel",function(t){var o=void 0,n=t.wheelDeltaY||t.deltaY,r=t.wheelDeltaX||t.deltaX;e.topOverlay.clone.wtTable.holder.contains(t.realTarget)?o="top":e.bottomOverlay.clone&&e.bottomOverlay.clone.wtTable.holder.contains(t.realTarget)?o="bottom":e.leftOverlay.clone.wtTable.holder.contains(t.realTarget)?o="left":e.topLeftCornerOverlay&&e.topLeftCornerOverlay.clone&&e.topLeftCornerOverlay.clone.wtTable.holder.contains(t.realTarget)?o="topLeft":e.bottomLeftCornerOverlay&&e.bottomLeftCornerOverlay.clone&&e.bottomLeftCornerOverlay.clone.wtTable.holder.contains(t.realTarget)&&(o="bottomLeft"),("top"==o&&0!==n||"left"==o&&0!==r||"bottom"==o&&0!==n||("topLeft"===o||"bottomLeft"===o)&&(0!==n||0!==r))&&t.preventDefault()}]);n.length;){var r=n.pop();this.eventManager.addEventListener(r[0],r[1],r[2]),this.registeredListeners.push(r)}}},{key:"deregisterListeners",value:function(){for(;this.registeredListeners.length;){var e=this.registeredListeners.pop();this.eventManager.removeEventListener(e[0],e[1],e[2])}}},{key:"onTableScroll",value:function(e){if(!(0,u.isMobileBrowser)()){var t=this.leftOverlay.mainTableScrollableElement,o=this.topOverlay.mainTableScrollableElement,n=e.target;this.keyPressed&&(o!==window&&n!==window&&!e.target.contains(o)||t!==window&&n!==window&&!e.target.contains(t))||("scroll"===e.type?this.syncScrollPositions(e):this.translateMouseWheelToScroll(e))}}},{key:"onKeyDown",value:function(e){this.keyPressed=(0,a.isKey)(e.keyCode,"ARROW_UP|ARROW_RIGHT|ARROW_DOWN|ARROW_LEFT")}},{key:"onKeyUp",value:function(){this.keyPressed=!1}},{key:"translateMouseWheelToScroll",value:function(e){var t=this.topOverlay.clone.wtTable.holder,o=this.bottomOverlay.clone?this.bottomOverlay.clone.wtTable.holder:null,n=this.leftOverlay.clone.wtTable.holder,r=this.topLeftCornerOverlay&&this.topLeftCornerOverlay.clone?this.topLeftCornerOverlay.clone.wtTable.holder:null,i=this.bottomLeftCornerOverlay&&this.bottomLeftCornerOverlay.clone?this.bottomLeftCornerOverlay.clone.wtTable.holder:null,s=e.wheelDeltaY||-1*e.deltaY,l=e.wheelDeltaX||-1*e.deltaX,a=null,u={type:"wheel"},c=e.target,h=null;for(1===e.deltaMode&&(s*=120,l*=120);c!=document&&null!=c;){if(c.className.indexOf("wtHolder")>-1){a=c;break}c=c.parentNode}return u.target=a,a===r||a===i?(this.syncScrollPositions(u,-.2*l,"x"),this.syncScrollPositions(u,-.2*s,"y")):(a===t||a===o?h=s:a===n&&(h=l),this.syncScrollPositions(u,-.2*h)),!1}},{key:"syncScrollPositions",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;if(!this.destroyed){if(0===arguments.length)return void this.syncScrollWithMaster();var n=this.leftOverlay.mainTableScrollableElement,r=this.topOverlay.mainTableScrollableElement,i=e.target,l=0,a=!1,u=void 0,c=void 0,h=void 0,d=void 0,f=void 0,p=!1,g=this.wot.getSetting("preventOverflow");this.topOverlay.needFullRender&&(u=this.topOverlay.clone.wtTable.holder),this.bottomOverlay.needFullRender&&(f=this.bottomOverlay.clone.wtTable.holder),this.leftOverlay.needFullRender&&(c=this.leftOverlay.clone.wtTable.holder),this.leftOverlay.needFullRender&&this.topOverlay.needFullRender&&(h=this.topLeftCornerOverlay.clone.wtTable.holder),this.leftOverlay.needFullRender&&this.bottomOverlay.needFullRender&&(d=this.bottomLeftCornerOverlay.clone.wtTable.holder),i===document&&(i=window),i===n||i===r?(l=(0,s.getScrollLeft)(g?this.scrollableElement:i),this.horizontalScrolling=!0,this.overlayScrollPositions.master.left=l,a=!0,this.pendingScrollCallbacks.master.left>0?this.pendingScrollCallbacks.master.left--:(u&&u.scrollLeft!==l&&(null==t&&this.pendingScrollCallbacks.top.left++,u.scrollLeft=l,p=n!==window),f&&f.scrollLeft!==l&&(null==t&&this.pendingScrollCallbacks.bottom.left++,f.scrollLeft=l,p=n!==window)),l=(0,s.getScrollTop)(i),this.verticalScrolling=!0,this.overlayScrollPositions.master.top=l,a=!0,this.pendingScrollCallbacks.master.top>0?this.pendingScrollCallbacks.master.top--:c&&c.scrollTop!==l&&(null==t&&this.pendingScrollCallbacks.left.top++,c.scrollTop=l,p=r!==window)):i===f?(l=(0,s.getScrollLeft)(i),this.horizontalScrolling=!0,this.overlayScrollPositions.bottom.left=l,a=!0,this.pendingScrollCallbacks.bottom.left>0?this.pendingScrollCallbacks.bottom.left--:(null==t&&this.pendingScrollCallbacks.master.left++,n.scrollLeft=l,u&&u.scrollLeft!==l&&(null==t&&this.pendingScrollCallbacks.top.left++,u.scrollLeft=l,p=r!==window)),null!==t&&(a=!0,r.scrollTop+=t)):i===u?(l=(0,s.getScrollLeft)(i),this.horizontalScrolling=!0,this.overlayScrollPositions.top.left=l,a=!0,this.pendingScrollCallbacks.top.left>0?this.pendingScrollCallbacks.top.left--:(null==t&&this.pendingScrollCallbacks.master.left++,n.scrollLeft=l),null!==t&&(a=!0,r.scrollTop+=t),f&&f.scrollLeft!==l&&(null==t&&this.pendingScrollCallbacks.bottom.left++,f.scrollLeft=l,p=r!==window)):i===c?(l=(0,s.getScrollTop)(i),this.overlayScrollPositions.left.top!==l&&(this.verticalScrolling=!0,this.overlayScrollPositions.left.top=l,a=!0,this.pendingScrollCallbacks.left.top>0?this.pendingScrollCallbacks.left.top--:(null==t&&this.pendingScrollCallbacks.master.top++,r.scrollTop=l)),null!==t&&(a=!0,r.scrollLeft+=t)):i!==h&&i!==d||null!==t&&(a=!0,"x"===o?r.scrollLeft+=t:"y"===o&&(r.scrollTop+=t)),!this.keyPressed&&a&&"scroll"===e.type&&(this.delegatedScrollCallback?this.delegatedScrollCallback=!1:this.refreshAll(),p&&(this.delegatedScrollCallback=!0))}}},{key:"syncScrollWithMaster",value:function(){var e=this.topOverlay.mainTableScrollableElement,t=e.scrollLeft,o=e.scrollTop;this.topOverlay.needFullRender&&(this.topOverlay.clone.wtTable.holder.scrollLeft=t),this.bottomOverlay.needFullRender&&(this.bottomOverlay.clone.wtTable.holder.scrollLeft=t),this.leftOverlay.needFullRender&&(this.leftOverlay.clone.wtTable.holder.scrollTop=o)}},{key:"updateMainScrollableElements",value:function(){this.deregisterListeners(),this.leftOverlay.updateMainScrollableElement(),this.topOverlay.updateMainScrollableElement(),this.bottomOverlay.needFullRender&&this.bottomOverlay.updateMainScrollableElement(),this.scrollableElement=(0,s.getScrollableElement)(this.wot.wtTable.TABLE),this.registerListeners()}},{key:"destroy",value:function(){this.eventManager.destroy(),this.topOverlay.destroy(),this.bottomOverlay.clone&&this.bottomOverlay.destroy(),this.leftOverlay.destroy(),this.topLeftCornerOverlay&&this.topLeftCornerOverlay.destroy(),this.bottomLeftCornerOverlay&&this.bottomLeftCornerOverlay.clone&&this.bottomLeftCornerOverlay.destroy(),this.debug&&this.debug.destroy(),this.destroyed=!0}},{key:"refresh",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(this.topOverlay.areElementSizesAdjusted&&this.leftOverlay.areElementSizesAdjusted){var t=this.wot.wtTable.wtRootElement.parentNode||this.wot.wtTable.wtRootElement,o=t.clientWidth,n=t.clientHeight;o===this.spreaderLastSize.width&&n===this.spreaderLastSize.height||(this.spreaderLastSize.width=o,this.spreaderLastSize.height=n,this.adjustElementsSize())}this.bottomOverlay.clone&&this.bottomOverlay.refresh(e),this.leftOverlay.refresh(e),this.topOverlay.refresh(e),this.topLeftCornerOverlay&&this.topLeftCornerOverlay.refresh(e),this.bottomLeftCornerOverlay&&this.bottomLeftCornerOverlay.clone&&this.bottomLeftCornerOverlay.refresh(e),this.debug&&this.debug.refresh(e)}},{key:"adjustElementsSize",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=this.wot.getSetting("totalColumns"),o=this.wot.getSetting("totalRows"),n=this.wot.wtViewport.getRowHeaderWidth(),r=this.wot.wtViewport.getColumnHeaderHeight(),i=this.wot.wtTable.hider.style;i.width=n+this.leftOverlay.sumCellSizes(0,t)+"px",i.height=r+this.topOverlay.sumCellSizes(0,o)+1+"px",this.topOverlay.adjustElementsSize(e),this.leftOverlay.adjustElementsSize(e),this.bottomOverlay.clone&&this.bottomOverlay.adjustElementsSize(e)}},{key:"applyToDOM",value:function(){this.topOverlay.areElementSizesAdjusted&&this.leftOverlay.areElementSizesAdjusted||this.adjustElementsSize(),this.topOverlay.applyToDOM(),this.bottomOverlay.clone&&this.bottomOverlay.applyToDOM(),this.leftOverlay.applyToDOM()}},{key:"getParentOverlay",value:function(e){if(!e)return null;var t=[this.topOverlay,this.leftOverlay,this.bottomOverlay,this.topLeftCornerOverlay,this.bottomLeftCornerOverlay],o=null;return(0,l.arrayEach)(t,function(t,n){t&&t.clone&&t.clone.wtTable.TABLE.contains(e)&&(o=t.clone)}),o}}]),e}()},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=o(0),s=o(6);t.default=function(){function e(t){n(this,e),this.wot=t,this.instance=t}return r(e,[{key:"scrollViewport",value:function(e){if(this.wot.drawn){var t=this._getVariables(),o=t.topOverlay,n=t.leftOverlay,r=t.totalRows,i=t.totalColumns,s=t.fixedRowsTop,l=t.fixedRowsBottom,a=t.fixedColumnsLeft;if(0>e.row||e.row>Math.max(r-1,0))throw Error("row "+e.row+" does not exist");if(0>e.col||e.col>Math.max(i-1,0))throw Error("column "+e.col+" does not exist");e.row>=s&&e.row<this.getFirstVisibleRow()?o.scrollTo(e.row):e.row>this.getLastVisibleRow()&&r-l>e.row&&o.scrollTo(e.row,!0),e.col>=a&&e.col<this.getFirstVisibleColumn()?n.scrollTo(e.col):e.col>this.getLastVisibleColumn()&&n.scrollTo(e.col,!0)}}},{key:"getFirstVisibleRow",value:function(){var e=this._getVariables(),t=e.topOverlay,o=e.wtTable,n=e.wtViewport,r=e.totalRows,l=e.fixedRowsTop,a=o.getFirstVisibleRow();if(t.mainTableScrollableElement===window){var u=(0,i.offset)(o.wtRootElement),c=(0,i.innerHeight)(o.hider),h=(0,i.innerHeight)(window),d=(0,i.getScrollTop)(window);if(d>=u.top+c-h){var f=n.getColumnHeaderHeight();f+=t.sumCellSizes(0,l),(0,s.rangeEachReverse)(r,1,function(e){if(f+=t.sumCellSizes(e-1,e),d>=u.top+c-f)return a=e,!1})}}return a}},{key:"getLastVisibleRow",value:function(){var e=this._getVariables(),t=e.topOverlay,o=e.wtTable,n=e.wtViewport,r=e.totalRows,l=o.getLastVisibleRow();if(t.mainTableScrollableElement===window){var a=(0,i.offset)(o.wtRootElement),u=(0,i.innerHeight)(window),c=(0,i.getScrollTop)(window);if(a.top>c){var h=n.getColumnHeaderHeight();(0,s.rangeEach)(1,r,function(e){if(h+=t.sumCellSizes(e-1,e),a.top+h-c>=u)return l=e-2,!1})}}return l}},{key:"getFirstVisibleColumn",value:function(){var e=this._getVariables(),t=e.leftOverlay,o=e.wtTable,n=e.wtViewport,r=e.totalColumns,l=o.getFirstVisibleColumn();if(t.mainTableScrollableElement===window){var a=(0,i.offset)(o.wtRootElement),u=(0,i.innerWidth)(o.hider),c=(0,i.innerWidth)(window),h=(0,i.getScrollLeft)(window);if(h>=a.left+u-c){var d=n.getRowHeaderWidth();(0,s.rangeEachReverse)(r,1,function(e){if(d+=t.sumCellSizes(e-1,e),h>=a.left+u-d)return l=e,!1})}}return l}},{key:"getLastVisibleColumn",value:function(){var e=this._getVariables(),t=e.leftOverlay,o=e.wtTable,n=e.wtViewport,r=e.totalColumns,l=o.getLastVisibleColumn();if(t.mainTableScrollableElement===window){var a=(0,i.offset)(o.wtRootElement),u=(0,i.innerWidth)(window),c=(0,i.getScrollLeft)(window);if(a.left>c){var h=n.getRowHeaderWidth();(0,s.rangeEach)(1,r,function(e){if(h+=t.sumCellSizes(e-1,e),a.left+h-c>=u)return l=e-2,!1})}}return l}},{key:"_getVariables",value:function(){var e=this.wot;return{topOverlay:e.wtOverlays.topOverlay,leftOverlay:e.wtOverlays.leftOverlay,wtTable:e.wtTable,wtViewport:e.wtViewport,totalRows:e.getSetting("totalRows"),totalColumns:e.getSetting("totalColumns"),fixedRowsTop:e.getSetting("fixedRowsTop"),fixedRowsBottom:e.getSetting("fixedRowsBottom"),fixedColumnsLeft:e.getSetting("fixedColumnsLeft")}}}]),e}()},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=o(0),s=o(1);t.default=function(){function e(t,o){var r=this;n(this,e),this.wot=t,this.instance=t,this.defaults={table:void 0,debug:!1,externalRowCalculator:!1,stretchH:"none",currentRowClassName:null,currentColumnClassName:null,preventOverflow:function(){return!1},data:void 0,freezeOverlays:!1,fixedColumnsLeft:0,fixedRowsTop:0,fixedRowsBottom:0,minSpareRows:0,rowHeaders:function(){return[]},columnHeaders:function(){return[]},totalRows:void 0,totalColumns:void 0,cellRenderer:function(e,t,o){var n=r.getSetting("data",e,t);(0,i.fastInnerText)(o,void 0===n||null===n?"":n)},columnWidth:function(e){},rowHeight:function(e){},defaultRowHeight:23,defaultColumnWidth:50,selections:null,hideBorderOnMouseDownOver:!1,viewportRowCalculatorOverride:null,viewportColumnCalculatorOverride:null,onCellMouseDown:null,onCellMouseOver:null,onCellMouseOut:null,onCellMouseUp:null,onCellDblClick:null,onCellCornerMouseDown:null,onCellCornerDblClick:null,beforeDraw:null,onDraw:null,onBeforeDrawBorders:null,onScrollVertically:null,onScrollHorizontally:null,onBeforeTouchScroll:null,onAfterMomentumScroll:null,onBeforeStretchingColumnWidth:function(e){return e},onModifyRowHeaderWidth:null,scrollbarWidth:10,scrollbarHeight:10,renderAllRows:!1,groups:!1,rowHeaderWidth:null,columnHeaderHeight:null,headerClassName:null},this.settings={};for(var l in this.defaults)if((0,s.hasOwnProperty)(this.defaults,l))if(void 0!==o[l])this.settings[l]=o[l];else{if(void 0===this.defaults[l])throw Error('A required setting "'+l+'" was not provided');this.settings[l]=this.defaults[l]}}return r(e,[{key:"update",value:function(e,t){if(void 0===t)for(var o in e)(0,s.hasOwnProperty)(e,o)&&(this.settings[o]=e[o]);else this.settings[e]=t;return this.wot}},{key:"getSetting",value:function(e,t,o,n,r){return"function"==typeof this.settings[e]?this.settings[e](t,o,n,r):void 0!==t&&Array.isArray(this.settings[e])?this.settings[e][t]:this.settings[e]}},{key:"has",value:function(e){return!!this.settings[e]}}]),e}()},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e){if(Array.isArray(e)){for(var t=0,o=Array(e.length);e.length>t;t++)o[t]=e[t];return o}return Array.from(e)}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},l=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),a=o(0),u=o(35),c=o(42),h=n(c),d=o(68),f=(n(d),o(141)),p=n(f),g=o(142),v=n(g),m=o(147),y=n(m),w=o(28),C=n(w);t.default=function(){function e(t,o){var n=this;i(this,e),this.wot=t,this.instance=this.wot,this.TABLE=o,this.TBODY=null,this.THEAD=null,this.COLGROUP=null,this.tableOffset=0,this.holderOffset=0,(0,a.removeTextNodes)(this.TABLE),this.spreader=this.createSpreader(this.TABLE),this.hider=this.createHider(this.spreader),this.holder=this.createHolder(this.hider),this.wtRootElement=this.holder.parentNode,this.alignOverlaysWithTrimmingContainer(),this.fixTableDomTree(),this.colgroupChildrenLength=this.COLGROUP.childNodes.length,this.theadChildrenLength=this.THEAD.firstChild?this.THEAD.firstChild.childNodes.length:0,this.tbodyChildrenLength=this.TBODY.childNodes.length,this.rowFilter=null,this.columnFilter=null,this.correctHeaderWidth=!1;var r=this.wot.wtSettings.settings.rowHeaderWidth;this.wot.wtSettings.settings.rowHeaderWidth=function(){return n._modifyRowHeaderWidth(r)}}return l(e,[{key:"fixTableDomTree",value:function(){this.TBODY=this.TABLE.querySelector("tbody"),this.TBODY||(this.TBODY=document.createElement("tbody"),this.TABLE.appendChild(this.TBODY)),this.THEAD=this.TABLE.querySelector("thead"),this.THEAD||(this.THEAD=document.createElement("thead"),this.TABLE.insertBefore(this.THEAD,this.TBODY)),this.COLGROUP=this.TABLE.querySelector("colgroup"),this.COLGROUP||(this.COLGROUP=document.createElement("colgroup"),this.TABLE.insertBefore(this.COLGROUP,this.THEAD)),this.wot.getSetting("columnHeaders").length&&!this.THEAD.childNodes.length&&this.THEAD.appendChild(document.createElement("TR"))}},{key:"createSpreader",value:function(e){var t=e.parentNode,o=void 0;return t&&1===t.nodeType&&(0,a.hasClass)(t,"wtHolder")||(o=document.createElement("div"),o.className="wtSpreader",t&&t.insertBefore(o,e),o.appendChild(e)),o.style.position="relative",o}},{key:"createHider",value:function(e){var t=e.parentNode,o=void 0;return t&&1===t.nodeType&&(0,a.hasClass)(t,"wtHolder")||(o=document.createElement("div"),o.className="wtHider",t&&t.insertBefore(o,e),o.appendChild(e)),o}},{key:"createHolder",value:function(e){var t=e.parentNode,o=void 0;return t&&1===t.nodeType&&(0,a.hasClass)(t,"wtHolder")||(o=document.createElement("div"),o.style.position="relative",o.className="wtHolder",t&&t.insertBefore(o,e),this.isWorkingOnClone()||(o.parentNode.className+="ht_master handsontable"),o.appendChild(e)),o}},{key:"alignOverlaysWithTrimmingContainer",value:function(){var e=(0,a.getTrimmingContainer)(this.wtRootElement);if(!this.isWorkingOnClone())if(this.holder.parentNode.style.position="relative",e===window){var t=this.wot.getSetting("preventOverflow");t||(this.holder.style.overflow="visible",this.wtRootElement.style.overflow="visible")}else this.holder.style.width=(0,a.getStyle)(e,"width"),this.holder.style.height=(0,a.getStyle)(e,"height"),this.holder.style.overflow=""}},{key:"isWorkingOnClone",value:function(){return!!this.wot.cloneSource}},{key:"draw",value:function(e){var t=this.wot,o=t.wtOverlays,n=t.wtViewport,r=this.instance.getSetting("totalRows"),i=this.wot.getSetting("rowHeaders").length,s=this.wot.getSetting("columnHeaders").length,l=!1;if(!this.isWorkingOnClone()&&(this.holderOffset=(0,a.offset)(this.holder),e=n.createRenderCalculators(e),i&&!this.wot.getSetting("fixedColumnsLeft"))){var u=o.leftOverlay.getScrollPosition(),c=this.correctHeaderWidth;this.correctHeaderWidth=u>0,c!==this.correctHeaderWidth&&(e=!1)}if(this.isWorkingOnClone()||(l=o.prepareOverlays()),e)this.isWorkingOnClone()||n.createVisibleCalculators(),o&&o.refresh(!0);else{this.tableOffset=this.isWorkingOnClone()?this.wot.cloneSource.wtTable.tableOffset:(0,a.offset)(this.TABLE);var h=void 0;h=C.default.isOverlayTypeOf(this.wot.cloneOverlay,C.default.CLONE_DEBUG)||C.default.isOverlayTypeOf(this.wot.cloneOverlay,C.default.CLONE_TOP)||C.default.isOverlayTypeOf(this.wot.cloneOverlay,C.default.CLONE_TOP_LEFT_CORNER)?0:C.default.isOverlayTypeOf(this.instance.cloneOverlay,C.default.CLONE_BOTTOM)||C.default.isOverlayTypeOf(this.instance.cloneOverlay,C.default.CLONE_BOTTOM_LEFT_CORNER)?Math.max(r-this.wot.getSetting("fixedRowsBottom"),0):n.rowsRenderCalculator.startRow;var d=void 0;d=C.default.isOverlayTypeOf(this.wot.cloneOverlay,C.default.CLONE_DEBUG)||C.default.isOverlayTypeOf(this.wot.cloneOverlay,C.default.CLONE_LEFT)||C.default.isOverlayTypeOf(this.wot.cloneOverlay,C.default.CLONE_TOP_LEFT_CORNER)||C.default.isOverlayTypeOf(this.wot.cloneOverlay,C.default.CLONE_BOTTOM_LEFT_CORNER)?0:n.columnsRenderCalculator.startColumn,this.rowFilter=new v.default(h,r,s),this.columnFilter=new p.default(d,this.wot.getSetting("totalColumns"),i),this.alignOverlaysWithTrimmingContainer(),this._doDraw()}return this.refreshSelections(e),this.isWorkingOnClone()||(o.topOverlay.resetFixedPosition(),o.bottomOverlay.clone&&o.bottomOverlay.resetFixedPosition(),o.leftOverlay.resetFixedPosition(),o.topLeftCornerOverlay&&o.topLeftCornerOverlay.resetFixedPosition(),o.bottomLeftCornerOverlay&&o.bottomLeftCornerOverlay.clone&&o.bottomLeftCornerOverlay.resetFixedPosition()),l&&o.syncScrollWithMaster(),this.wot.drawn=!0,this}},{key:"_doDraw",value:function(){new y.default(this).render()}},{key:"removeClassFromCells",value:function(e){for(var t=this.TABLE.querySelectorAll("."+e),o=0,n=t.length;n>o;o++)(0,a.removeClass)(t[o],e)}},{key:"refreshSelections",value:function(e){if(this.wot.selections){var t=this.wot.selections.length;if(e)for(var o=0;t>o;o++)this.wot.selections[o].settings.className&&this.removeClassFromCells(this.wot.selections[o].settings.className),this.wot.selections[o].settings.highlightHeaderClassName&&this.removeClassFromCells(this.wot.selections[o].settings.highlightHeaderClassName),this.wot.selections[o].settings.highlightRowClassName&&this.removeClassFromCells(this.wot.selections[o].settings.highlightRowClassName),this.wot.selections[o].settings.highlightColumnClassName&&this.removeClassFromCells(this.wot.selections[o].settings.highlightColumnClassName);for(var n=0;t>n;n++)this.wot.selections[n].draw(this.wot,e)}}},{key:"getCell",value:function(e){if(this.isRowBeforeRenderedRows(e.row))return-1;if(this.isRowAfterRenderedRows(e.row))return-2;var t=this.TBODY.childNodes[this.rowFilter.sourceToRendered(e.row)];return t?t.childNodes[this.columnFilter.sourceColumnToVisibleRowHeadedColumn(e.col)]:void 0}},{key:"getColumnHeader",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,o=this.THEAD.childNodes[t];if(o)return o.childNodes[this.columnFilter.sourceColumnToVisibleRowHeadedColumn(e)]}},{key:"getRowHeader",value:function(e){if(0===this.columnFilter.sourceColumnToVisibleRowHeadedColumn(0))return null;var t=this.TBODY.childNodes[this.rowFilter.sourceToRendered(e)];return t?t.childNodes[0]:void 0}},{key:"getCoords",value:function(e){if("TD"!==e.nodeName&&"TH"!==e.nodeName&&(e=(0,a.closest)(e,["TD","TH"])),null===e)return null;var t=e.parentNode,o=t.parentNode,n=(0,a.index)(t),r=e.cellIndex;return(0,a.overlayContainsElement)(C.default.CLONE_TOP_LEFT_CORNER,e)||(0,a.overlayContainsElement)(C.default.CLONE_TOP,e)?"THEAD"===o.nodeName&&(n-=o.childNodes.length):n=o===this.THEAD?this.rowFilter.visibleColHeadedRowToSourceRow(n):this.rowFilter.renderedToSource(n),r=(0,a.overlayContainsElement)(C.default.CLONE_TOP_LEFT_CORNER,e)||(0,a.overlayContainsElement)(C.default.CLONE_LEFT,e)?this.columnFilter.offsettedTH(r):this.columnFilter.visibleRowHeadedColumnToSourceColumn(r),new h.default(n,r)}},{key:"getTrForRow",value:function(e){return this.TBODY.childNodes[this.rowFilter.sourceToRendered(e)]}},{key:"getFirstRenderedRow",value:function(){return this.wot.wtViewport.rowsRenderCalculator.startRow}},{key:"getFirstVisibleRow",value:function(){return this.wot.wtViewport.rowsVisibleCalculator.startRow}},{key:"getFirstRenderedColumn",value:function(){return this.wot.wtViewport.columnsRenderCalculator.startColumn}},{key:"getFirstVisibleColumn",value:function(){return this.wot.wtViewport.columnsVisibleCalculator.startColumn}},{key:"getLastRenderedRow",value:function(){return this.wot.wtViewport.rowsRenderCalculator.endRow}},{key:"getLastVisibleRow",value:function(){return this.wot.wtViewport.rowsVisibleCalculator.endRow}},{key:"getLastRenderedColumn",value:function(){return this.wot.wtViewport.columnsRenderCalculator.endColumn}},{key:"getLastVisibleColumn",value:function(){return this.wot.wtViewport.columnsVisibleCalculator.endColumn}},{key:"isRowBeforeRenderedRows",value:function(e){return this.rowFilter&&0>this.rowFilter.sourceToRendered(e)&&e>=0}},{key:"isRowAfterViewport",value:function(e){return this.rowFilter&&this.rowFilter.sourceToRendered(e)>this.getLastVisibleRow()}},{key:"isRowAfterRenderedRows",value:function(e){return this.rowFilter&&this.rowFilter.sourceToRendered(e)>this.getLastRenderedRow()}},{key:"isColumnBeforeViewport",value:function(e){return this.columnFilter&&0>this.columnFilter.sourceToRendered(e)&&e>=0}},{key:"isColumnAfterViewport",value:function(e){return this.columnFilter&&this.columnFilter.sourceToRendered(e)>this.getLastVisibleColumn()}},{key:"isLastRowFullyVisible",value:function(){return this.getLastVisibleRow()===this.getLastRenderedRow()}},{key:"isLastColumnFullyVisible",value:function(){return this.getLastVisibleColumn()===this.getLastRenderedColumn()}},{key:"getRenderedColumnsCount",value:function(){var e=this.wot.wtViewport.columnsRenderCalculator.count,t=this.wot.getSetting("totalColumns");if(this.wot.isOverlayName(C.default.CLONE_DEBUG))e=t;else if(this.wot.isOverlayName(C.default.CLONE_LEFT)||this.wot.isOverlayName(C.default.CLONE_TOP_LEFT_CORNER)||this.wot.isOverlayName(C.default.CLONE_BOTTOM_LEFT_CORNER))return Math.min(this.wot.getSetting("fixedColumnsLeft"),t);return e}},{key:"getRenderedRowsCount",value:function(){var e=this.wot.wtViewport.rowsRenderCalculator.count,t=this.wot.getSetting("totalRows");return this.wot.isOverlayName(C.default.CLONE_DEBUG)?e=t:this.wot.isOverlayName(C.default.CLONE_TOP)||this.wot.isOverlayName(C.default.CLONE_TOP_LEFT_CORNER)?e=Math.min(this.wot.getSetting("fixedRowsTop"),t):(this.wot.isOverlayName(C.default.CLONE_BOTTOM)||this.wot.isOverlayName(C.default.CLONE_BOTTOM_LEFT_CORNER))&&(e=Math.min(this.wot.getSetting("fixedRowsBottom"),t)),e}},{key:"getVisibleRowsCount",value:function(){return this.wot.wtViewport.rowsVisibleCalculator.count}},{key:"allRowsInViewport",value:function(){return this.wot.getSetting("totalRows")==this.getVisibleRowsCount()}},{key:"getRowHeight",value:function(e){var t=this.wot.wtSettings.settings.rowHeight(e),o=this.wot.wtViewport.oversizedRows[e];return void 0!==o&&(t=void 0===t?o:Math.max(t,o)),t}},{key:"getColumnHeaderHeight",value:function(e){var t=this.wot.wtSettings.settings.defaultRowHeight,o=this.wot.wtViewport.oversizedColumnHeaders[e];return void 0!==o&&(t=t?Math.max(t,o):o),t}},{key:"getVisibleColumnsCount",value:function(){return this.wot.wtViewport.columnsVisibleCalculator.count}},{key:"allColumnsInViewport",value:function(){return this.wot.getSetting("totalColumns")==this.getVisibleColumnsCount()}},{key:"getColumnWidth",value:function(e){var t=this.wot.wtSettings.settings.columnWidth;return"function"==typeof t?t=t(e):"object"===(void 0===t?"undefined":s(t))&&(t=t[e]),t||this.wot.wtSettings.settings.defaultColumnWidth}},{key:"getStretchedColumnWidth",value:function(e){var t=this.getColumnWidth(e),o=null==t?this.instance.wtSettings.settings.defaultColumnWidth:t,n=this.wot.wtViewport.columnsRenderCalculator;if(n){var r=n.getStretchedColumnWidth(e,o);r&&(o=r)}return o}},{key:"_modifyRowHeaderWidth",value:function(e){var t=(0,u.isFunction)(e)?e():null;return Array.isArray(t)?(t=[].concat(r(t)),t[t.length-1]=this._correctRowHeaderWidth(t[t.length-1])):t=this._correctRowHeaderWidth(t),t}},{key:"_correctRowHeaderWidth",value:function(e){return"number"!=typeof e&&(e=this.wot.getSetting("defaultColumnWidth")),this.correctHeaderWidth&&e++,e}}]),e}()},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){var o=document.createElement("TH");return t.insertBefore(o,e),t.removeChild(e),o}function i(e,t){var o=document.createElement("TD");return t.insertBefore(o,e),t.removeChild(e),o}t.__esModule=!0;var s=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),l=o(0),a=o(28),u=function(e){return e&&e.__esModule?e:{default:e}}(a),c=!1;t.default=function(){function e(t){n(this,e),this.wtTable=t,this.wot=t.instance,this.instance=t.instance,this.rowFilter=t.rowFilter,this.columnFilter=t.columnFilter,this.TABLE=t.TABLE,this.THEAD=t.THEAD,this.TBODY=t.TBODY,this.COLGROUP=t.COLGROUP,this.rowHeaders=[],this.rowHeaderCount=0,this.columnHeaders=[],this.columnHeaderCount=0,this.fixedRowsTop=0,this.fixedRowsBottom=0}return s(e,[{key:"render",value:function(){if(!this.wtTable.isWorkingOnClone()){var e={};if(this.wot.getSetting("beforeDraw",!0,e),!0===e.skipRender)return}this.rowHeaders=this.wot.getSetting("rowHeaders"),this.rowHeaderCount=this.rowHeaders.length,this.fixedRowsTop=this.wot.getSetting("fixedRowsTop"),this.fixedRowsBottom=this.wot.getSetting("fixedRowsBottom"),this.columnHeaders=this.wot.getSetting("columnHeaders"),this.columnHeaderCount=this.columnHeaders.length;var t=this.wtTable.getRenderedColumnsCount(),o=this.wtTable.getRenderedRowsCount(),n=this.wot.getSetting("totalColumns"),r=this.wot.getSetting("totalRows"),i=void 0,s=!1;if((u.default.isOverlayTypeOf(this.wot.cloneOverlay,u.default.CLONE_BOTTOM)||u.default.isOverlayTypeOf(this.wot.cloneOverlay,u.default.CLONE_BOTTOM_LEFT_CORNER))&&(this.columnHeaders=[],this.columnHeaderCount=0),0>n||(this.adjustAvailableNodes(),s=!0,this.renderColumnHeaders(),this.renderRows(r,o,t),this.wtTable.isWorkingOnClone()||(i=this.wot.wtViewport.getWorkspaceWidth(),this.wot.wtViewport.containerWidth=null),this.adjustColumnWidths(t),this.markOversizedColumnHeaders(),this.adjustColumnHeaderHeights()),s||this.adjustAvailableNodes(),this.removeRedundantRows(o),this.wtTable.isWorkingOnClone()&&!this.wot.isOverlayName(u.default.CLONE_BOTTOM)||this.markOversizedRows(),this.wtTable.isWorkingOnClone())this.wot.isOverlayName(u.default.CLONE_BOTTOM)&&this.wot.cloneSource.wtOverlays.adjustElementsSize();else{this.wot.wtViewport.createVisibleCalculators(),this.wot.wtOverlays.refresh(!1),this.wot.wtOverlays.applyToDOM();var a=(0,l.outerWidth)(this.wtTable.hider),c=(0,l.outerWidth)(this.wtTable.TABLE);if(0!==a&&c!==a&&this.adjustColumnWidths(t),i!==this.wot.wtViewport.getWorkspaceWidth()){this.wot.wtViewport.containerWidth=null;var h=this.wtTable.getFirstRenderedColumn(),d=this.wtTable.getLastRenderedColumn(),f=this.wot.getSetting("defaultColumnWidth"),p=this.wot.getSetting("rowHeaderWidth");if(null!=(p=this.instance.getSetting("onModifyRowHeaderWidth",p)))for(var g=0;this.rowHeaderCount>g;g++){var v=Array.isArray(p)?p[g]:p;v=null==v?f:v,this.COLGROUP.childNodes[g].style.width=v+"px"}for(var m=h;d>m;m++){var y=this.wtTable.getStretchedColumnWidth(m);this.COLGROUP.childNodes[this.columnFilter.sourceToRendered(m)+this.rowHeaderCount].style.width=y+"px"}}this.wot.getSetting("onDraw",!0)}}},{key:"removeRedundantRows",value:function(e){for(;this.wtTable.tbodyChildrenLength>e;)this.TBODY.removeChild(this.TBODY.lastChild),this.wtTable.tbodyChildrenLength--}},{key:"renderRows",value:function(e,t,o){for(var n=void 0,r=0,i=this.rowFilter.renderedToSource(r),s=this.wtTable.isWorkingOnClone();e>i&&i>=0&&(!c&&r>1e3&&(c=!0,console.warn('Performance tip: Handsontable rendered more than 1000 visible rows. Consider limiting the number of rendered rows by specifying the table height and/or turning off the "renderAllRows" option.')),void 0===t||r!==t);){if(n=this.getOrCreateTrForRow(r,n),this.renderRowHeaders(i,n),this.adjustColumns(n,o+this.rowHeaderCount),this.renderCells(i,n,o),s&&!this.wot.isOverlayName(u.default.CLONE_BOTTOM)||this.resetOversizedRow(i),n.firstChild){var l=this.wot.wtTable.getRowHeight(i);l?(l--,n.firstChild.style.height=l+"px"):n.firstChild.style.height=""}r++,i=this.rowFilter.renderedToSource(r)}}},{key:"resetOversizedRow",value:function(e){this.wot.getSetting("externalRowCalculator")||this.wot.wtViewport.oversizedRows&&this.wot.wtViewport.oversizedRows[e]&&(this.wot.wtViewport.oversizedRows[e]=void 0)}},{key:"markOversizedRows",value:function(){if(!this.wot.getSetting("externalRowCalculator")){var e=this.instance.wtTable.TBODY.childNodes.length,t=e*this.instance.wtSettings.settings.defaultRowHeight,o=(0,l.innerHeight)(this.instance.wtTable.TBODY)-1,n=void 0,r=void 0,i=void 0,s=void 0,a=void 0;this.instance.getSetting("totalRows");if(t!==o||this.instance.getSetting("fixedRowsBottom"))for(;e;)e--,i=this.instance.wtTable.rowFilter.renderedToSource(e),n=this.instance.wtTable.getRowHeight(i),s=this.instance.wtTable.getTrForRow(i),a=s.querySelector("th"),r=a?(0,l.innerHeight)(a):(0,l.innerHeight)(s)-1,(!n&&r>this.instance.wtSettings.settings.defaultRowHeight||r>n)&&(this.instance.wtViewport.oversizedRows[i]=++r)}}},{key:"markOversizedColumnHeaders",value:function(){var e=this.wot.getOverlayName();if(this.columnHeaderCount&&!this.wot.wtViewport.hasOversizedColumnHeadersMarked[e]&&!this.wtTable.isWorkingOnClone()){for(var t=this.wtTable.getRenderedColumnsCount(),o=0;this.columnHeaderCount>o;o++)for(var n=-1*this.rowHeaderCount;t>n;n++)this.markIfOversizedColumnHeader(n);this.wot.wtViewport.hasOversizedColumnHeadersMarked[e]=!0}}},{key:"adjustColumnHeaderHeights",value:function(){for(var e=this.wot.getSetting("columnHeaders"),t=this.wot.wtTable.THEAD.childNodes,o=this.wot.wtViewport.oversizedColumnHeaders,n=0,r=e.length;r>n;n++)if(o[n]){if(!t[n]||0===t[n].childNodes.length)return;t[n].childNodes[0].style.height=o[n]+"px"}}},{key:"markIfOversizedColumnHeader",value:function(e){for(var t=this.wot.wtTable.columnFilter.renderedToSource(e),o=this.columnHeaderCount,n=this.wot.wtSettings.settings.defaultRowHeight,r=void 0,i=void 0,s=void 0,a=this.wot.getSetting("columnHeaderHeight")||[];o;)o--,r=this.wot.wtTable.getColumnHeaderHeight(o),(i=this.wot.wtTable.getColumnHeader(t,o))&&(s=(0,l.innerHeight)(i),(!r&&s>n||s>r)&&(this.wot.wtViewport.oversizedColumnHeaders[o]=s),Array.isArray(a)?null!=a[o]&&(this.wot.wtViewport.oversizedColumnHeaders[o]=a[o]):isNaN(a)||(this.wot.wtViewport.oversizedColumnHeaders[o]=a),(a[o]||a)>this.wot.wtViewport.oversizedColumnHeaders[o]&&(this.wot.wtViewport.oversizedColumnHeaders[o]=a[o]||a))}},{key:"renderCells",value:function(e,t,o){for(var n=void 0,r=void 0,s=0;o>s;s++)r=this.columnFilter.renderedToSource(s),n=0===s?t.childNodes[this.columnFilter.sourceColumnToVisibleRowHeadedColumn(r)]:n.nextSibling,"TH"==n.nodeName&&(n=i(n,t)),(0,l.hasClass)(n,"hide")||(n.className=""),n.removeAttribute("style"),this.wot.wtSettings.settings.cellRenderer(e,r,n);return n}},{key:"adjustColumnWidths",value:function(e){var t=0,o=this.wot.cloneSource?this.wot.cloneSource:this.wot,n=o.wtTable.holder,r=this.wot.getSetting("defaultColumnWidth"),i=this.wot.getSetting("rowHeaderWidth");if(n.scrollHeight>n.offsetHeight&&(t=(0,l.getScrollbarWidth)()),this.wot.wtViewport.columnsRenderCalculator.refreshStretching(this.wot.wtViewport.getViewportWidth()-t),null!=(i=this.instance.getSetting("onModifyRowHeaderWidth",i)))for(var s=0;this.rowHeaderCount>s;s++){var a=Array.isArray(i)?i[s]:i;a=null==a?r:a,this.COLGROUP.childNodes[s].style.width=a+"px"}for(var u=0;e>u;u++){this.COLGROUP.childNodes[u+this.rowHeaderCount].style.width=this.wtTable.getStretchedColumnWidth(this.columnFilter.renderedToSource(u))+"px"}}},{key:"appendToTbody",value:function(e){this.TBODY.appendChild(e),this.wtTable.tbodyChildrenLength++}},{key:"getOrCreateTrForRow",value:function(e,t){var o=void 0;return this.wtTable.tbodyChildrenLength>e?o=0===e?this.TBODY.firstChild:t.nextSibling:(o=this.createRow(),this.appendToTbody(o)),o.className&&o.removeAttribute("class"),o}},{key:"createRow",value:function(){for(var e=document.createElement("TR"),t=0;this.rowHeaderCount>t;t++)e.appendChild(document.createElement("TH"));return e}},{key:"renderRowHeader",value:function(e,t,o){o.className="",o.removeAttribute("style"),this.rowHeaders[t](e,o,t)}},{key:"renderRowHeaders",value:function(e,t){for(var o=t.firstChild,n=0;this.rowHeaderCount>n;n++)o?"TD"==o.nodeName&&(o=r(o,t)):(o=document.createElement("TH"),t.appendChild(o)),this.renderRowHeader(e,n,o),o=o.nextSibling}},{key:"adjustAvailableNodes",value:function(){this.adjustColGroups(),this.adjustThead()}},{key:"renderColumnHeaders",value:function(){if(this.columnHeaderCount)for(var e=this.wtTable.getRenderedColumnsCount(),t=0;this.columnHeaderCount>t;t++)for(var o=this.getTrForColumnHeaders(t),n=-1*this.rowHeaderCount;e>n;n++){var r=this.columnFilter.renderedToSource(n);this.renderColumnHeader(t,r,o.childNodes[n+this.rowHeaderCount])}}},{key:"adjustColGroups",value:function(){for(var e=this.wtTable.getRenderedColumnsCount();e+this.rowHeaderCount>this.wtTable.colgroupChildrenLength;)this.COLGROUP.appendChild(document.createElement("COL")),this.wtTable.colgroupChildrenLength++;for(;this.wtTable.colgroupChildrenLength>e+this.rowHeaderCount;)this.COLGROUP.removeChild(this.COLGROUP.lastChild),this.wtTable.colgroupChildrenLength--;this.rowHeaderCount&&(0,l.addClass)(this.COLGROUP.childNodes[0],"rowHeader")}},{key:"adjustThead",value:function(){var e=this.wtTable.getRenderedColumnsCount(),t=this.THEAD.firstChild;if(this.columnHeaders.length){for(var o=0,n=this.columnHeaders.length;n>o;o++){for(t=this.THEAD.childNodes[o],t||(t=document.createElement("TR"),this.THEAD.appendChild(t)),this.theadChildrenLength=t.childNodes.length;e+this.rowHeaderCount>this.theadChildrenLength;)t.appendChild(document.createElement("TH")),this.theadChildrenLength++;for(;this.theadChildrenLength>e+this.rowHeaderCount;)t.removeChild(t.lastChild),this.theadChildrenLength--}var r=this.THEAD.childNodes.length;if(r>this.columnHeaders.length)for(var i=this.columnHeaders.length;r>i;i++)this.THEAD.removeChild(this.THEAD.lastChild)}else t&&(0,l.empty)(t)}},{key:"getTrForColumnHeaders",value:function(e){return this.THEAD.childNodes[e]}},{key:"renderColumnHeader",value:function(e,t,o){return o.className="",o.removeAttribute("style"),this.columnHeaders[e](t,o,e)}},{key:"adjustColumns",value:function(e,t){for(var o=e.childNodes.length;t>o;){e.appendChild(document.createElement("TD")),o++}for(;o>t;)e.removeChild(e.lastChild),o--}},{key:"removeRedundantColumns",value:function(e){for(;this.wtTable.tbodyChildrenLength>e;)this.TBODY.removeChild(this.TBODY.lastChild),this.wtTable.tbodyChildrenLength--}}]),e}()},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var i=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),s=o(0),l=o(1),a=o(4),u=n(a),c=o(137),h=n(c),d=o(138),f=n(d);t.default=function(){function e(t){var o=this;r(this,e),this.wot=t,this.instance=this.wot,this.oversizedRows=[],this.oversizedColumnHeaders=[],this.hasOversizedColumnHeadersMarked={},this.clientHeight=0,this.containerWidth=NaN,this.rowHeaderWidth=NaN,this.rowsVisibleCalculator=null,this.columnsVisibleCalculator=null,this.eventManager=new u.default(this.wot),this.eventManager.addEventListener(window,"resize",function(){o.clientHeight=o.getWorkspaceHeight()})}return i(e,[{key:"getWorkspaceHeight",value:function(){var e=this.instance.wtOverlays.topOverlay.trimmingContainer,t=void 0,o=0;return e===window?o=document.documentElement.clientHeight:(t=(0,s.outerHeight)(e),o=t>0&&e.clientHeight>0?e.clientHeight:1/0),o}},{key:"getWorkspaceWidth",value:function(){var e=void 0,t=this.wot.getSetting("totalColumns"),o=this.instance.wtOverlays.leftOverlay.trimmingContainer,n=void 0,r=this.wot.getSetting("stretchH"),i=document.documentElement.offsetWidth;return this.wot.getSetting("preventOverflow")?(0,s.outerWidth)(this.instance.wtTable.wtRootElement):(e=this.wot.getSetting("freezeOverlays")?Math.min(i-this.getWorkspaceOffset().left,i):Math.min(this.getContainerFillWidth(),i-this.getWorkspaceOffset().left,i),o===window&&t>0&&this.sumColumnWidths(0,t-1)>e?document.documentElement.clientWidth:o===window||"scroll"!=(n=(0,s.getStyle)(this.instance.wtOverlays.leftOverlay.trimmingContainer,"overflow"))&&"hidden"!=n&&"auto"!=n?"none"!==r&&r?e:Math.max(e,(0,s.outerWidth)(this.instance.wtTable.TABLE)):Math.max(e,o.clientWidth))}},{key:"hasVerticalScroll",value:function(){return this.getWorkspaceActualHeight()>this.getWorkspaceHeight()}},{key:"hasHorizontalScroll",value:function(){return this.getWorkspaceActualWidth()>this.getWorkspaceWidth()}},{key:"sumColumnWidths",value:function(e,t){for(var o=0;t>e;)o+=this.wot.wtTable.getColumnWidth(e),e++;return o}},{key:"getContainerFillWidth",value:function(){if(this.containerWidth)return this.containerWidth;var e=this.instance.wtTable.holder,t=void 0,o=void 0;return o=document.createElement("div"),o.style.width="100%",o.style.height="1px",e.appendChild(o),t=o.offsetWidth,this.containerWidth=t,e.removeChild(o),t}},{key:"getWorkspaceOffset",value:function(){return(0,s.offset)(this.wot.wtTable.TABLE)}},{key:"getWorkspaceActualHeight",value:function(){return(0,s.outerHeight)(this.wot.wtTable.TABLE)}},{key:"getWorkspaceActualWidth",value:function(){return(0,s.outerWidth)(this.wot.wtTable.TABLE)||(0,s.outerWidth)(this.wot.wtTable.TBODY)||(0,s.outerWidth)(this.wot.wtTable.THEAD)}},{key:"getColumnHeaderHeight",value:function(){return isNaN(this.columnHeaderHeight)&&(this.columnHeaderHeight=(0,s.outerHeight)(this.wot.wtTable.THEAD)),this.columnHeaderHeight}},{key:"getViewportHeight",value:function(){var e=this.getWorkspaceHeight(),t=void 0;return e===1/0?e:(t=this.getColumnHeaderHeight(),t>0&&(e-=t),e)}},{key:"getRowHeaderWidth",value:function(){var e=this.instance.getSetting("rowHeaderWidth"),t=this.instance.getSetting("rowHeaders");if(e){this.rowHeaderWidth=0;for(var o=0,n=t.length;n>o;o++)this.rowHeaderWidth+=e[o]||e}if(this.wot.cloneSource)return this.wot.cloneSource.wtViewport.getRowHeaderWidth();if(isNaN(this.rowHeaderWidth))if(t.length){var r=this.instance.wtTable.TABLE.querySelector("TH");this.rowHeaderWidth=0;for(var i=0,l=t.length;l>i;i++)r?(this.rowHeaderWidth+=(0,s.outerWidth)(r),r=r.nextSibling):this.rowHeaderWidth+=50}else this.rowHeaderWidth=0;return this.rowHeaderWidth=this.instance.getSetting("onModifyRowHeaderWidth",this.rowHeaderWidth)||this.rowHeaderWidth}},{key:"getViewportWidth",value:function(){var e=this.getWorkspaceWidth(),t=void 0;return e===1/0?e:(t=this.getRowHeaderWidth(),t>0?e-t:e)}},{key:"createRowsCalculator",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]&&arguments[0],o=void 0,n=void 0,r=void 0,i=void 0,l=void 0,a=void 0,u=void 0;return this.rowHeaderWidth=NaN,o=this.wot.wtSettings.settings.renderAllRows?1/0:this.getViewportHeight(),n=this.wot.wtOverlays.topOverlay.getScrollPosition()-this.wot.wtOverlays.topOverlay.getTableParentOffset(),0>n&&(n=0),r=this.wot.getSetting("fixedRowsTop"),l=this.wot.getSetting("fixedRowsBottom"),u=this.wot.getSetting("totalRows"),r&&(a=this.wot.wtOverlays.topOverlay.sumCellSizes(0,r),n+=a,o-=a),l&&this.wot.wtOverlays.bottomOverlay.clone&&(a=this.wot.wtOverlays.bottomOverlay.sumCellSizes(u-l,u),o-=a),i=this.wot.wtTable.holder.clientHeight===this.wot.wtTable.holder.offsetHeight?0:(0,s.getScrollbarWidth)(),new f.default(o,n,this.wot.getSetting("totalRows"),function(t){return e.wot.wtTable.getRowHeight(t)},t?null:this.wot.wtSettings.settings.viewportRowCalculatorOverride,t,i)}},{key:"createColumnsCalculator",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]&&arguments[0],o=this.getViewportWidth(),n=void 0,r=void 0;if(this.columnHeaderHeight=NaN,n=this.wot.wtOverlays.leftOverlay.getScrollPosition()-this.wot.wtOverlays.leftOverlay.getTableParentOffset(),0>n&&(n=0),r=this.wot.getSetting("fixedColumnsLeft")){var i=this.wot.wtOverlays.leftOverlay.sumCellSizes(0,r);n+=i,o-=i}return this.wot.wtTable.holder.clientWidth!==this.wot.wtTable.holder.offsetWidth&&(o-=(0,s.getScrollbarWidth)()),new h.default(o,n,this.wot.getSetting("totalColumns"),function(t){return e.wot.wtTable.getColumnWidth(t)},t?null:this.wot.wtSettings.settings.viewportColumnCalculatorOverride,t,this.wot.getSetting("stretchH"),function(t,o){return e.wot.getSetting("onBeforeStretchingColumnWidth",t,o)})}},{key:"createRenderCalculators",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(e){var t=this.createRowsCalculator(!0),o=this.createColumnsCalculator(!0);this.areAllProposedVisibleRowsAlreadyRendered(t)&&this.areAllProposedVisibleColumnsAlreadyRendered(o)||(e=!1)}return e||(this.rowsRenderCalculator=this.createRowsCalculator(),this.columnsRenderCalculator=this.createColumnsCalculator()),this.rowsVisibleCalculator=null,this.columnsVisibleCalculator=null,e}},{key:"createVisibleCalculators",value:function(){this.rowsVisibleCalculator=this.createRowsCalculator(!0),this.columnsVisibleCalculator=this.createColumnsCalculator(!0)}},{key:"areAllProposedVisibleRowsAlreadyRendered",value:function(e){return!!this.rowsVisibleCalculator&&(!(this.rowsRenderCalculator.startRow>e.startRow||e.startRow===this.rowsRenderCalculator.startRow&&e.startRow>0)&&!(e.endRow>this.rowsRenderCalculator.endRow||e.endRow===this.rowsRenderCalculator.endRow&&e.endRow<this.wot.getSetting("totalRows")-1))}},{key:"areAllProposedVisibleColumnsAlreadyRendered",value:function(e){return!!this.columnsVisibleCalculator&&(!(this.columnsRenderCalculator.startColumn>e.startColumn||e.startColumn===this.columnsRenderCalculator.startColumn&&e.startColumn>0)&&!(e.endColumn>this.columnsRenderCalculator.endColumn||e.endColumn===this.columnsRenderCalculator.endColumn&&e.endColumn<this.wot.getSetting("totalColumns")-1))}},{key:"resetHasOversizedColumnHeadersMarked",value:function(){(0,l.objectEach)(this.hasOversizedColumnHeadersMarked,function(e,t,o){o[t]=void 0})}}]),e}()},function(e,t,o){"use strict";function n(e){d=!1;var t=this.getActiveEditor();if((0,r.isPrintableChar)(e.keyCode)||e.keyCode===r.KEY_CODES.BACKSPACE||e.keyCode===r.KEY_CODES.DELETE||e.keyCode===r.KEY_CODES.INSERT){var o=0;if(e.keyCode===r.KEY_CODES.C&&(e.ctrlKey||e.metaKey))return;t.isOpened()||(o+=10),t.htEditor&&t.instance._registerTimeout(setTimeout(function(){t.queryChoices(t.TEXTAREA.value),d=!0},o))}}t.__esModule=!0;var r=o(16),i=o(20),s=o(27),l=o(2),a=o(0),u=o(150),c=function(e){return e&&e.__esModule?e:{default:e}}(u),h=c.default.prototype.extend();h.prototype.init=function(){c.default.prototype.init.apply(this,arguments),this.query=null,this.strippedChoices=[],this.rawChoices=[]},h.prototype.getValue=function(){var e=this,t=this.rawChoices.find(function(t){return e.stripValueIfNeeded(t)===e.TEXTAREA.value});return(0,i.isDefined)(t)?t:this.TEXTAREA.value},h.prototype.createElements=function(){c.default.prototype.createElements.apply(this,arguments),(0,a.addClass)(this.htContainer,"autocompleteEditor"),(0,a.addClass)(this.htContainer,-1===window.navigator.platform.indexOf("Mac")?"":"htMacScroll")};var d=!1;h.prototype.prepare=function(){this.instance.addHook("beforeKeyDown",n),c.default.prototype.prepare.apply(this,arguments)},h.prototype.open=function(){this.TEXTAREA_PARENT.style.overflow="auto",c.default.prototype.open.apply(this,arguments),this.TEXTAREA_PARENT.style.overflow="";var e=this.htEditor.getInstance(),t=this,o=void 0===this.cellProperties.trimDropdown||this.cellProperties.trimDropdown;this.TEXTAREA.style.visibility="visible",this.focus(),e.updateSettings({colWidths:o?[(0,a.outerWidth)(this.TEXTAREA)-2]:void 0,width:o?(0,a.outerWidth)(this.TEXTAREA)+(0,a.getScrollbarWidth)()+2:void 0,afterRenderer:function(e,o,n,r,s,l){var a=t.cellProperties,u=a.filteringCaseSensitive,c=a.allowHtml,h=void 0,d=void 0;s=(0,i.stringify)(s),s&&!c&&-1!==(h=!0===u?s.indexOf(this.query):s.toLowerCase().indexOf(t.query.toLowerCase()))&&(d=s.substr(h,t.query.length),s=s.replace(d,"<strong>"+d+"</strong>")),e.innerHTML=s},autoColumnSize:!0,modifyColWidth:function(e,t){var n=this.getPlugin("autoColumnSize").widths;return n[t]&&(e=n[t]),o?e:e+15}}),this.htEditor.view.wt.wtTable.holder.parentNode.style["padding-right"]=(0,a.getScrollbarWidth)()+2+"px",d&&(d=!1),t.instance._registerTimeout(setTimeout(function(){t.queryChoices(t.TEXTAREA.value)},0))},h.prototype.close=function(){c.default.prototype.close.apply(this,arguments)},h.prototype.queryChoices=function(e){var t=this;this.query=e;var o=this.cellProperties.source;"function"==typeof o?o.call(this.cellProperties,e,function(e){t.rawChoices=e,t.updateChoicesList(t.stripValuesIfNeeded(e))}):Array.isArray(o)?(this.rawChoices=o,this.updateChoicesList(this.stripValuesIfNeeded(o))):this.updateChoicesList([])},h.prototype.updateChoicesList=function(e){var t=(0,a.getCaretPosition)(this.TEXTAREA),o=(0,a.getSelectionEndPosition)(this.TEXTAREA),n=this.cellProperties.sortByRelevance,r=this.cellProperties.filter,i=null,s=null;n&&(i=h.sortByRelevance(this.stripValueIfNeeded(this.getValue()),e,this.cellProperties.filteringCaseSensitive));var u=Array.isArray(i)?i.length:0;if(!1===r)u&&(s=i[0]);else{for(var c=[],d=0,f=e.length;f>d&&(!n||d<u);d++)c.push(u?e[i[d]]:e[d]);s=0,e=c}this.strippedChoices=e,this.htEditor.loadData((0,l.pivot)([e])),this.updateDropdownHeight(),this.flipDropdownIfNeeded(),!0===this.cellProperties.strict&&this.highlightBestMatchingChoice(s),this.instance.listen(),this.TEXTAREA.focus(),(0,a.setCaretPosition)(this.TEXTAREA,t,t===o?void 0:o)},h.prototype.flipDropdownIfNeeded=function(){var e=(0,a.offset)(this.TEXTAREA),t=(0,a.outerHeight)(this.TEXTAREA),o=this.getDropdownHeight(),n=(0,a.getTrimmingContainer)(this.instance.view.wt.wtTable.TABLE),r=n.scrollTop,i=(0,a.outerHeight)(this.instance.view.wt.wtTable.THEAD),s={row:0,col:0};n!==window&&(s=(0,a.offset)(n));var l=e.top-s.top-i+r,u=n.scrollHeight-l-i-t,c=o>u&&l>u;return c?this.flipDropdown(o):this.unflipDropdown(),this.limitDropdownIfNeeded(c?l:u,o),c},h.prototype.limitDropdownIfNeeded=function(e,t){if(t>e){var o=0,n=0,r=0,i=null;do{r=this.htEditor.getRowHeight(n)||this.htEditor.view.wt.wtSettings.settings.defaultRowHeight,o+=r,n++}while(e>o);i=o-r,this.htEditor.flipped&&(this.htEditor.rootElement.style.top=parseInt(this.htEditor.rootElement.style.top,10)+t-i+"px"),this.setDropdownHeight(o-r)}},h.prototype.flipDropdown=function(e){var t=this.htEditor.rootElement.style;t.position="absolute",t.top=-e+"px",this.htEditor.flipped=!0},h.prototype.unflipDropdown=function(){var e=this.htEditor.rootElement.style;"absolute"===e.position&&(e.position="",e.top=""),this.htEditor.flipped=void 0},h.prototype.updateDropdownHeight=function(){var e=this.htEditor.getColWidth(0)+(0,a.getScrollbarWidth)()+2,t=this.cellProperties.trimDropdown;this.htEditor.updateSettings({height:this.getDropdownHeight(),width:t?void 0:e}),this.htEditor.view.wt.wtTable.alignOverlaysWithTrimmingContainer()},h.prototype.setDropdownHeight=function(e){this.htEditor.updateSettings({height:e})},h.prototype.finishEditing=function(e){e||this.instance.removeHook("beforeKeyDown",n),c.default.prototype.finishEditing.apply(this,arguments)},h.prototype.highlightBestMatchingChoice=function(e){"number"==typeof e?this.htEditor.selectCell(e,0):this.htEditor.deselectCell()},h.sortByRelevance=function(e,t,o){var n=[],r=void 0,l=e.length,a=void 0,u=void 0,c=[],h=void 0,d=t.length;if(0===l){for(h=0;d>h;h++)c.push(h);return c}for(h=0;d>h;h++)r=(0,s.stripTags)((0,i.stringify)(t[h])),-1!==(a=o?r.indexOf(e):r.toLowerCase().indexOf(e.toLowerCase()))&&(u=r.length-a-l,n.push({baseIndex:h,index:a,charsLeft:u,value:r}));for(n.sort(function(e,t){if(-1===t.index)return-1;if(-1===e.index)return 1;if(t.index>e.index)return-1;if(e.index>t.index)return 1;if(e.index===t.index){if(t.charsLeft>e.charsLeft)return-1;if(e.charsLeft>t.charsLeft)return 1}return 0}),h=0,d=n.length;d>h;h++)c.push(n[h].baseIndex);return c},h.prototype.getDropdownHeight=function(){var e=this.htEditor.getInstance().getRowHeight(0)||23,t=this.cellProperties.visibleRows;return t>this.strippedChoices.length?this.strippedChoices.length*e+8:t*e},h.prototype.stripValueIfNeeded=function(e){return this.stripValuesIfNeeded([e])[0]},h.prototype.stripValuesIfNeeded=function(e){var t=this.cellProperties.allowHtml,o=(0,l.arrayMap)(e,function(e){return(0,i.stringify)(e)});return(0,l.arrayMap)(o,function(e){return t?e:(0,s.stripTags)(e)})},h.prototype.allowKeyEventPropagation=function(e){var t={row:this.htEditor.getSelectedRange()?this.htEditor.getSelectedRange().from.row:-1},o=!1;return e===r.KEY_CODES.ARROW_DOWN&&t.row>0&&t.row<this.htEditor.countRows()-1&&(o=!0),e===r.KEY_CODES.ARROW_UP&&t.row>-1&&(o=!0),o},h.prototype.discardEditor=function(e){c.default.prototype.discardEditor.apply(this,arguments),this.instance.view.render()},t.default=h},function(e,t,o){"use strict";t.__esModule=!0;var n=o(16),r=o(1),i=o(0),s=o(7),l=o(43),a=function(e){return e&&e.__esModule?e:{default:e}}(l),u=a.default.prototype.extend();u.prototype.createElements=function(){a.default.prototype.createElements.apply(this,arguments);var e=document.createElement("DIV");e.className="handsontableEditor",this.TEXTAREA_PARENT.appendChild(e),this.htContainer=e,this.assignHooks()},u.prototype.prepare=function(e,t,o,n,i,s){a.default.prototype.prepare.apply(this,arguments);var l=this,u={startRows:0,startCols:0,minRows:0,minCols:0,className:"listbox",copyPaste:!1,autoColumnSize:!1,autoRowSize:!1,readOnly:!0,fillHandle:!1,afterOnCellMouseDown:function(e,t){var o=this.getSourceData(t.row,t.col);void 0!==o&&l.setValue(o),l.instance.destroyEditor()}};this.cellProperties.handsontable&&(0,r.extend)(u,s.handsontable),this.htOptions=u};var c=function(e){if(!(0,s.isImmediatePropagationStopped)(e)){var t,o,r=this.getActiveEditor(),i=r.htEditor.getInstance();if(e.keyCode==n.KEY_CODES.ARROW_DOWN)if(i.getSelected()||i.flipped){if(i.getSelected())if(i.flipped)t=i.getSelected()[0]+1;else if(!i.flipped){o=i.getSelected()[0];var l=i.countRows()-1;t=Math.min(l,o+1)}}else t=0;else e.keyCode==n.KEY_CODES.ARROW_UP&&(!i.getSelected()&&i.flipped?t=i.countRows()-1:i.getSelected()&&(i.flipped?(o=i.getSelected()[0],t=Math.max(0,o-1)):(o=i.getSelected()[0],t=o-1)));void 0!==t&&(0>t||i.flipped&&t>i.countRows()-1?i.deselectCell():i.selectCell(t,0),i.getData().length&&(e.preventDefault(),(0,s.stopImmediatePropagation)(e),r.instance.listen(),r.TEXTAREA.focus()))}};u.prototype.open=function(){this.instance.addHook("beforeKeyDown",c),a.default.prototype.open.apply(this,arguments),this.htEditor&&this.htEditor.destroy(),this.htEditor=new this.instance.constructor(this.htContainer,this.htOptions),this.htEditor.init(),this.cellProperties.strict?(this.htEditor.selectCell(0,0),this.TEXTAREA.style.visibility="hidden"):(this.htEditor.deselectCell(),this.TEXTAREA.style.visibility="visible"),(0,i.setCaretPosition)(this.TEXTAREA,0,this.TEXTAREA.value.length)},u.prototype.close=function(){this.instance.removeHook("beforeKeyDown",c),this.instance.listen(),a.default.prototype.close.apply(this,arguments)},u.prototype.focus=function(){this.instance.listen(),a.default.prototype.focus.apply(this,arguments)},u.prototype.beginEditing=function(e){var t=this.instance.getSettings().onBeginEditing;t&&!1===t()||a.default.prototype.beginEditing.apply(this,arguments)},u.prototype.finishEditing=function(e,t){if(this.htEditor&&this.htEditor.isListening()&&this.instance.listen(),this.htEditor&&this.htEditor.getSelected()){var o=this.htEditor.getInstance().getValue();void 0!==o&&this.setValue(o)}return a.default.prototype.finishEditing.apply(this,arguments)},u.prototype.assignHooks=function(){var e=this;this.instance.addHook("afterDestroy",function(){e.htEditor&&e.htEditor.destroy()})},t.default=u},function(e,t,o){"use strict";t.__esModule=!0;var n=o(2),r=o(1),i=o(6),s={_arrayMap:[],getValueByIndex:function(e){var t=void 0;return void 0===(t=this._arrayMap[e])?null:t},getIndexByValue:function(e){var t=void 0;return-1===(t=this._arrayMap.indexOf(e))?null:t},insertItems:function(e){var t=this,o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,r=(0,n.arrayMax)(this._arrayMap)+1,s=[];return(0,i.rangeEach)(o-1,function(o){s.push(t._arrayMap.splice(e+o,0,r+o))}),s},removeItems:function(e){var t=this,o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,r=[];if(Array.isArray(e)){var i=[].concat(this._arrayMap);e.sort(function(e,t){return t-e}),r=(0,n.arrayReduce)(e,function(e,o){return t._arrayMap.splice(o,1),e.concat(i.slice(o,o+1))},[])}else r=this._arrayMap.splice(e,o);return r},unshiftItems:function(e){function t(e){return(0,n.arrayReduce)(r,function(t,o){return e>o&&t++,t},0)}var o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,r=this.removeItems(e,o);this._arrayMap=(0,n.arrayMap)(this._arrayMap,function(e,o){var n=t(e);return n&&(e-=n),e})},shiftItems:function(e){var t=this,o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1;this._arrayMap=(0,n.arrayMap)(this._arrayMap,function(t){return e>t||(t+=o),t}),(0,i.rangeEach)(o-1,function(o){t._arrayMap.splice(e+o,0,e+o)})},clearMap:function(){this._arrayMap.length=0}};(0,r.defineGetter)(s,"MIXIN_NAME","arrayMapper",{writable:!1,enumerable:!1}),t.default=s},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=o(6),s=0;t.default=function(){function e(t){n(this,e),this.hot=t,this._element=null,this.state=s}return r(e,[{key:"appendTo",value:function(e){e.appendChild(this._element),this.state=2}},{key:"build",value:function(){this._element=document.createElement("div"),this.state=1}},{key:"destroy",value:function(){this.isAppended()&&this._element.parentElement.removeChild(this._element),this._element=null,this.state=s}},{key:"isAppended",value:function(){return 2===this.state}},{key:"isBuilt",value:function(){return this.state>=1}},{key:"setPosition",value:function(e,t){(0,i.isNumeric)(e)&&(this._element.style.top=e+"px"),(0,i.isNumeric)(t)&&(this._element.style.left=t+"px")}},{key:"getPosition",value:function(){return{top:this._element.style.top?parseInt(this._element.style.top,10):0,left:this._element.style.left?parseInt(this._element.style.left,10):0}}},{key:"setSize",value:function(e,t){(0,i.isNumeric)(e)&&(this._element.style.width=e+"px"),(0,i.isNumeric)(t)&&(this._element.style.height=t+"px")}},{key:"getSize",value:function(){return{width:this._element.style.width?parseInt(this._element.style.width,10):0,height:this._element.style.height?parseInt(this._element.style.height,10):0}}},{key:"setOffset",value:function(e,t){(0,i.isNumeric)(e)&&(this._element.style.marginTop=e+"px"),(0,i.isNumeric)(t)&&(this._element.style.marginLeft=t+"px")}},{key:"getOffset",value:function(){return{top:this._element.style.marginTop?parseInt(this._element.style.marginTop,10):0,left:this._element.style.marginLeft?parseInt(this._element.style.marginLeft,10):0}}}]),e}()},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=0;t.default=function(){function e(t){n(this,e),this.hot=t,this._element=null,this.state=i}return r(e,[{key:"appendTo",value:function(e){e.appendChild(this._element),this.state=2}},{key:"build",value:function(){this._element=document.createElement("div"),this.state=1}},{key:"destroy",value:function(){this.isAppended()&&this._element.parentElement.removeChild(this._element),this._element=null,this.state=i}},{key:"isAppended",value:function(){return 2===this.state}},{key:"isBuilt",value:function(){return this.state>=1}},{key:"setPosition",value:function(e,t){e&&(this._element.style.top=e+"px"),t&&(this._element.style.left=t+"px")}},{key:"getPosition",value:function(){return{top:this._element.style.top?parseInt(this._element.style.top,10):0,left:this._element.style.left?parseInt(this._element.style.left,10):0}}},{key:"setSize",value:function(e,t){e&&(this._element.style.width=e+"px"),t&&(this._element.style.height=t+"px")}},{key:"getSize",value:function(){return{width:this._element.style.width?parseInt(this._element.style.width,10):0,height:this._element.style.height?parseInt(this._element.style.height,10):0}}},{key:"setOffset",value:function(e,t){e&&(this._element.style.marginTop=e+"px"),t&&(this._element.style.marginLeft=t+"px")}},{key:"getOffset",value:function(){return{top:this._element.style.marginTop?parseInt(this._element.style.marginTop,10):0,left:this._element.style.marginLeft?parseInt(this._element.style.marginLeft,10):0}}}]),e}()},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){h.set(e,t)}function i(e){var t=void 0;if(!(e instanceof a.default)){if(!h.has(e))throw Error("Record translator was not registered for this object identity");e=h.get(e)}return d.has(e)?t=d.get(e):(t=new c(e),d.set(e,t)),t}t.__esModule=!0,t.RecordTranslator=void 0;var s=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}();t.registerIdentity=r,t.getTranslator=i;var l=o(63),a=function(e){return e&&e.__esModule?e:{default:e}}(l),u=o(1),c=function(){function e(t){n(this,e),this.hot=t}return s(e,[{key:"toVisualRow",value:function(e){return this.hot.runHooks("unmodifyRow",e)}},{key:"toVisualColumn",value:function(e){return this.hot.runHooks("unmodifyCol",e)}},{key:"toVisual",value:function(e,t){return(0,u.isObject)(e)?{row:this.toVisualRow(e.row),column:this.toVisualColumn(e.column)}:[this.toVisualRow(e),this.toVisualColumn(t)]}},{key:"toPhysicalRow",value:function(e){return this.hot.runHooks("modifyRow",e)}},{key:"toPhysicalColumn",value:function(e){return this.hot.runHooks("modifyCol",e)}},{key:"toPhysical",value:function(e,t){return(0,u.isObject)(e)?{row:this.toPhysicalRow(e.row),column:this.toPhysicalColumn(e.column)}:[this.toPhysicalRow(e),this.toPhysicalColumn(t)]}}]),e}();t.RecordTranslator=c;var h=new WeakMap,d=new WeakMap},function(e,t,o){"use strict";function n(e,t,o){return t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o,e}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var i=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),s=o(1),l=o(6),a=o(20);t.default=function(){function e(t){r(this,e),this.samples=null,this.dataFactory=t,this.customSampleCount=null,this.allowDuplicates=!1}return i(e,null,[{key:"SAMPLE_COUNT",get:function(){return 3}}]),i(e,[{key:"getSampleCount",value:function(){return this.customSampleCount?this.customSampleCount:e.SAMPLE_COUNT}},{key:"setSampleCount",value:function(e){this.customSampleCount=e}},{key:"setAllowDuplicates",value:function(e){this.allowDuplicates=e}},{key:"generateRowSamples",value:function(e,t){return this.generateSamples("row",t,e)}},{key:"generateColumnSamples",value:function(e,t){return this.generateSamples("col",t,e)}},{key:"generateSamples",value:function(e,t,o){var n=this,r=new Map;return"number"==typeof o&&(o={from:o,to:o}),(0,l.rangeEach)(o.from,o.to,function(o){var i=n.generateSample(e,t,o);r.set(o,i)}),r}},{key:"generateSample",value:function(e,t,o){var r=this,i=new Map,u=[],c=void 0;return(0,l.rangeEach)(t.from,t.to,function(t){var l=void 0;if("row"===e)l=r.dataFactory(o,t);else{if("col"!==e)throw Error("Unsupported sample type");l=r.dataFactory(t,o)}c=(0,s.isObject)(l)?Object.keys(l).length:Array.isArray(l)?l.length:(0,a.stringify)(l).length,i.has(c)||i.set(c,{needed:r.getSampleCount(),strings:[]});var h=i.get(c);if(h.needed){if(!(u.indexOf(l)>-1)||r.allowDuplicates){h.strings.push(n({value:l},"row"===e?"col":"row",t)),u.push(l),h.needed--}}}),i}}]),e}()},function(e,t,o){var n=o(23),r=o(24),i=o(59);e.exports=function(e){return function(t,o,s){var l,a=n(t),u=r(a.length),c=i(s,u);if(e&&o!=o){for(;u>c;)if((l=a[c++])!=l)return!0}else for(;u>c;c++)if((e||c in a)&&a[c]===o)return e||c||0;return!e&&-1}}},function(e,t,o){var n=o(38),r=o(10)("toStringTag"),i="Arguments"==n(function(){return arguments}()),s=function(e,t){try{return e[t]}catch(e){}};e.exports=function(e){var t,o,l;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(o=s(t=Object(e),r))?o:i?n(t):"Object"==(l=n(t))&&"function"==typeof t.callee?"Arguments":l}},function(e,t,o){"use strict";var n=o(19).f,r=o(79),i=o(58),s=o(29),l=o(51),a=o(30),u=o(55),c=o(167),h=o(168),d=o(173),f=o(21),p=o(46).fastKey,g=f?"_s":"size",v=function(e,t){var o,n=p(t);if("F"!==n)return e._i[n];for(o=e._f;o;o=o.n)if(o.k==t)return o};e.exports={getConstructor:function(e,t,o,c){var h=e(function(e,n){l(e,h,t,"_i"),e._i=r(null),e._f=void 0,e._l=void 0,e[g]=0,void 0!=n&&u(n,o,e[c],e)});return i(h.prototype,{clear:function(){for(var e=this,t=e._i,o=e._f;o;o=o.n)o.r=!0,o.p&&(o.p=o.p.n=void 0),delete t[o.i];e._f=e._l=void 0,e[g]=0},delete:function(e){var t=this,o=v(t,e);if(o){var n=o.n,r=o.p;delete t._i[o.i],o.r=!0,r&&(r.n=n),n&&(n.p=r),t._f==o&&(t._f=n),t._l==o&&(t._l=r),t[g]--}return!!o},forEach:function(e){l(this,h,"forEach");for(var t,o=s(e,arguments.length>1?arguments[1]:void 0,3);t=t?t.n:this._f;)for(o(t.v,t.k,this);t&&t.r;)t=t.p},has:function(e){return!!v(this,e)}}),f&&n(h.prototype,"size",{get:function(){return a(this[g])}}),h},def:function(e,t,o){var n,r,i=v(e,t);return i?i.v=o:(e._l=i={i:r=p(t,!0),k:t,v:o,p:n=e._l,n:void 0,r:!1},e._f||(e._f=i),n&&(n.n=i),e[g]++,"F"!==r&&(e._i[r]=i)),e},getEntry:v,setStrong:function(e,t,o){c(e,t,function(e,t){this._t=e,this._k=t,this._l=void 0},function(){for(var e=this,t=e._k,o=e._l;o&&o.r;)o=o.p;return e._t&&(e._l=o=o?o.n:e._t._f)?"keys"==t?h(0,o.k):"values"==t?h(0,o.v):h(0,[o.k,o.v]):(e._t=void 0,h(1))},o?"entries":"values",!o,!0),d(t)}}},function(e,t,o){"use strict";var n=o(58),r=o(46).getWeak,i=o(18),s=o(15),l=o(51),a=o(55),u=o(52),c=o(22),h=u(5),d=u(6),f=0,p=function(e){return e._l||(e._l=new g)},g=function(){this.a=[]},v=function(e,t){return h(e.a,function(e){return e[0]===t})};g.prototype={get:function(e){var t=v(this,e);if(t)return t[1]},has:function(e){return!!v(this,e)},set:function(e,t){var o=v(this,e);o?o[1]=t:this.a.push([e,t])},delete:function(e){var t=d(this.a,function(t){return t[0]===e});return~t&&this.a.splice(t,1),!!~t}},e.exports={getConstructor:function(e,t,o,i){var u=e(function(e,n){l(e,u,t,"_i"),e._i=f++,e._l=void 0,void 0!=n&&a(n,o,e[i],e)});return n(u.prototype,{delete:function(e){if(!s(e))return!1;var t=r(e);return!0===t?p(this).delete(e):t&&c(t,this._i)&&delete t[this._i]},has:function(e){if(!s(e))return!1;var t=r(e);return!0===t?p(this).has(e):t&&c(t,this._i)}}),u},def:function(e,t,o){var n=r(i(t),!0);return!0===n?p(e).set(t,o):n[e._i]=o,e},ufstore:p}},function(e,t,o){e.exports=o(13).document&&document.documentElement},function(e,t,o){e.exports=!o(21)&&!o(31)(function(){return 7!=Object.defineProperty(o(74)("div"),"a",{get:function(){return 7}}).a})},function(e,t,o){var n=o(45),r=o(10)("iterator"),i=Array.prototype;e.exports=function(e){return void 0!==e&&(n.Array===e||i[r]===e)}},function(e,t,o){var n=o(38);e.exports=Array.isArray||function(e){return"Array"==n(e)}},function(e,t,o){var n=o(15),r=Math.floor;e.exports=function(e){return!n(e)&&isFinite(e)&&r(e)===e}},function(e,t,o){var n=o(15),r=o(38),i=o(10)("match");e.exports=function(e){var t;return n(e)&&(void 0!==(t=e[i])?!!t:"RegExp"==r(e))}},function(e,t,o){var n=o(18);e.exports=function(e,t,o,r){try{return r?t(n(o)[0],o[1]):t(o)}catch(t){var i=e.return;throw void 0!==i&&n(i.call(e)),t}}},function(e,t,o){"use strict";var n=o(56),r=o(3),i=o(33),s=o(32),l=o(22),a=o(45),u=o(287),c=o(48),h=o(292),d=o(10)("iterator"),f=!([].keys&&"next"in[].keys()),p=function(){return this};e.exports=function(e,t,o,g,v,m,y){u(o,t,g);var w,C,b,S=function(e){if(!f&&e in k)return k[e];switch(e){case"keys":case"values":return function(){return new o(this,e)}}return function(){return new o(this,e)}},E=t+" Iterator",R="values"==v,O=!1,k=e.prototype,T=k[d]||k["@@iterator"]||v&&k[v],_=T||S(v),M=v?R?S("entries"):_:void 0,H="Array"==t?k.entries||T:T;if(H&&(b=h(H.call(new e)))!==Object.prototype&&(c(b,E,!0),n||l(b,d)||s(b,d,p)),R&&T&&"values"!==T.name&&(O=!0,_=function(){return T.call(this)}),n&&!y||!f&&!O&&k[d]||s(k,d,_),a[t]=_,a[E]=p,v)if(w={values:R?_:S("values"),keys:m?_:S("keys"),entries:M},y)for(C in w)C in k||i(k,C,w[C]);else r(r.P+r.F*(f||O),t,w);return w}},function(e,t){e.exports=function(e,t){return{value:t,done:!!e}}},function(e,t,o){"use strict";var n=o(39),r=o(57),i=o(47),s=o(41),l=o(77),a=Object.assign;e.exports=!a||o(31)(function(){var e={},t={},o=Symbol(),n="abcdefghijklmnopqrst";return e[o]=7,n.split("").forEach(function(e){t[e]=e}),7!=a({},e)[o]||Object.keys(a({},t)).join("")!=n})?function(e,t){for(var o=s(e),a=arguments.length,u=1,c=r.f,h=i.f;a>u;)for(var d,f=l(arguments[u++]),p=c?n(f).concat(c(f)):n(f),g=p.length,v=0;g>v;)h.call(f,d=p[v++])&&(o[d]=f[d]);return o}:a},function(e,t,o){var n=o(22),r=o(23),i=o(156)(!1),s=o(82)("IE_PROTO");e.exports=function(e,t){var o,l=r(e),a=0,u=[];for(o in l)o!=s&&n(l,o)&&u.push(o);for(;t.length>a;)n(l,o=t[a++])&&(~i(u,o)||u.push(o));return u}},function(e,t,o){var n=o(39),r=o(23),i=o(47).f;e.exports=function(e){return function(t){for(var o,s=r(t),l=n(s),a=l.length,u=0,c=[];a>u;)i.call(s,o=l[u++])&&c.push(e?[o,s[o]]:s[o]);return c}}},function(e,t,o){var n=o(15),r=o(18),i=function(e,t){if(r(e),!n(t)&&null!==t)throw TypeError(t+": can't set as prototype!")};e.exports={set:Object.setPrototypeOf||("__proto__"in{}?function(e,t,n){try{n=o(29)(Function.call,o(80).f(Object.prototype,"__proto__").set,2),n(e,[]),t=!(e instanceof Array)}catch(e){t=!0}return function(e,o){return i(e,o),t?e.__proto__=o:n(e,o),e}}({},!1):void 0),check:i}},function(e,t,o){"use strict";var n=o(13),r=o(19),i=o(21),s=o(10)("species");e.exports=function(e){var t=n[e];i&&t&&!t[s]&&r.f(t,s,{configurable:!0,get:function(){return this}})}},function(e,t,o){var n=o(24),r=o(175),i=o(30);e.exports=function(e,t,o,s){var l=i(e)+"",a=l.length,u=void 0===o?" ":o+"",c=n(t);if(a>=c||""==u)return l;var h=c-a,d=r.call(u,Math.ceil(h/u.length));return d.length>h&&(d=d.slice(0,h)),s?d+l:l+d}},function(e,t,o){"use strict";var n=o(60),r=o(30);e.exports=function(e){var t=r(this)+"",o="",i=n(e);if(0>i||i==1/0)throw RangeError("Count can't be negative");for(;i>0;(i>>>=1)&&(t+=t))1&i&&(o+=t);return o}},function(e,t,o){t.f=o(10)},function(e,t,o){var n=o(157),r=o(10)("iterator"),i=o(45);e.exports=o(44).getIteratorMethod=function(e){if(void 0!=e)return e[r]||e["@@iterator"]||i[n(e)]}},function(e,t,o){"use strict";function n(e){var t="undefined"!=typeof window&&window.jQuery;t&&(t.fn.handsontable=function(t){var o=this.first(),n=o.data("handsontable");if("string"!=typeof t){var r=t||{};return n?n.updateSettings(r):(n=new e.Core(o[0],r),o.data("handsontable",n),n.init()),o}var i=[],s=void 0;if(arguments.length>1)for(var l=1,a=arguments.length;a>l;l++)i.push(arguments[l]);if(n){if(void 0===n[t])throw Error("Handsontable do not provide action: "+t);s=n[t].apply(n,i),"destroy"===t&&o.removeData()}return s})}t.__esModule=!0,t.default=n},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}t.__esModule=!0,t.Base=t.UndoRedo=t.TouchScroll=t.Search=t.PersistentState=t.ObserveChanges=t.MultipleSelectionHandles=t.MergeCells=t.ManualRowResize=t.ManualRowMove=t.ManualColumnResize=t.ManualColumnMove=t.ManualColumnFreeze=t.DragToScroll=t.CustomBorders=t.CopyPaste=t.ContextMenu=t.Comments=t.ColumnSorting=t.AutoRowSize=t.AutoFill=t.AutoColumnSize=void 0;var r=o(212),i=n(r),s=o(214),l=n(s),a=o(213),u=n(a),c=o(216),h=n(c),d=o(218),f=n(d),p=o(221),g=n(p),v=o(238),m=n(v),y=o(240),w=n(y),C=o(241),b=n(C),S=o(244),E=n(S),R=o(246),O=n(R),k=o(249),T=n(k),_=o(250),M=n(_),H=o(254),A=n(H),P=o(255),x=n(P),D=o(256),L=n(D),N=o(258),I=n(N),j=o(260),W=n(j),B=o(261),F=n(B),V=o(262),z=n(V),U=o(263),K=n(U),Y=o(12),G=n(Y);t.AutoColumnSize=i.default,t.AutoFill=l.default,t.AutoRowSize=u.default,t.ColumnSorting=h.default,t.Comments=f.default,t.ContextMenu=g.default,t.CopyPaste=m.default,t.CustomBorders=w.default,t.DragToScroll=b.default,t.ManualColumnFreeze=E.default,t.ManualColumnMove=O.default,t.ManualColumnResize=T.default,t.ManualRowMove=M.default,t.ManualRowResize=A.default,t.MergeCells=x.default,t.MultipleSelectionHandles=L.default,t.ObserveChanges=I.default,t.PersistentState=W.default,t.Search=F.default,t.TouchScroll=z.default,t.UndoRedo=K.default,t.Base=G.default},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t,o){"use strict";function n(){function e(e){return e.currentStyle||document.defaultView.getComputedStyle(e)}var t,o={minHeight:200,maxHeight:300,minWidth:100,maxWidth:300},n=document.body,r=document.createTextNode(""),i=document.createElement("SPAN"),s=function(e,t,o){e.attachEvent?e.attachEvent("on"+t,o):e.addEventListener(t,o,!1)},l=function(e,t,o){e.removeEventListener?e.removeEventListener(t,o,!1):e.detachEvent("on"+t,o)},a=function(s){var l,a;s?/^[a-zA-Z \.,\\\/\|0-9]$/.test(s)||(s="."):s="",void 0!==r.textContent?r.textContent=t.value+s:r.data=t.value+s,i.style.fontSize=e(t).fontSize,i.style.fontFamily=e(t).fontFamily,i.style.whiteSpace="pre",n.appendChild(i),l=i.clientWidth+2,n.removeChild(i),t.style.height=o.minHeight+"px",t.style.width=o.minWidth>l?o.minWidth+"px":l>o.maxWidth?o.maxWidth+"px":l+"px",a=t.scrollHeight?t.scrollHeight-1:0,o.minHeight>a?t.style.height=o.minHeight+"px":a>o.maxHeight?(t.style.height=o.maxHeight+"px",t.style.overflowY="visible"):t.style.height=a+"px"},u=function(){window.setTimeout(a,0)},c=function(e){if(e&&e.minHeight)if("inherit"==e.minHeight)o.minHeight=t.clientHeight;else{var n=parseInt(e.minHeight);isNaN(n)||(o.minHeight=n)}if(e&&e.maxHeight)if("inherit"==e.maxHeight)o.maxHeight=t.clientHeight;else{var s=parseInt(e.maxHeight);isNaN(s)||(o.maxHeight=s)}if(e&&e.minWidth)if("inherit"==e.minWidth)o.minWidth=t.clientWidth;else{var l=parseInt(e.minWidth);isNaN(l)||(o.minWidth=l)}if(e&&e.maxWidth)if("inherit"==e.maxWidth)o.maxWidth=t.clientWidth;else{var a=parseInt(e.maxWidth);isNaN(a)||(o.maxWidth=a)}i.firstChild||(i.className="autoResize",i.style.display="inline-block",i.appendChild(r))},h=function(e,n,r){t=e,c(n),"TEXTAREA"==t.nodeName&&(t.style.resize="none",t.style.overflowY="",t.style.height=o.minHeight+"px",t.style.minWidth=o.minWidth+"px",t.style.maxWidth=o.maxWidth+"px",t.style.overflowY="hidden"),r&&(s(t,"change",a),s(t,"cut",u),s(t,"paste",u),s(t,"drop",u),s(t,"keydown",u),s(t,"focus",a)),a()};return{init:function(e,t,o){h(e,t,o)},unObserve:function(){l(t,"change",a),l(t,"cut",u),l(t,"paste",u),l(t,"drop",u),l(t,"keydown",u),l(t,"focus",a)},resize:a}}e.exports=n},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var s=o(0),l=o(28),a=function(e){return e&&e.__esModule?e:{default:e}}(l),u=function(e){function t(e){n(this,t);var o=r(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.clone=o.makeClone(a.default.CLONE_DEBUG),o.clone.wtTable.holder.style.opacity=.4,o.clone.wtTable.holder.style.textShadow="0 0 2px #ff0000",(0,s.addClass)(o.clone.wtTable.holder.parentNode,"wtDebugVisible"),o}return i(t,e),t}(a.default);a.default.registerOverlay(a.default.CLONE_DEBUG,u),t.default=u},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var s=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),l=o(0),a=o(28),u=function(e){return e&&e.__esModule?e:{default:e}}(a),c=function(e){function t(e){n(this,t);var o=r(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.clone=o.makeClone(u.default.CLONE_LEFT),o}return i(t,e),s(t,[{key:"shouldBeRendered",value:function(){return!(!this.wot.getSetting("fixedColumnsLeft")&&!this.wot.getSetting("rowHeaders").length)}},{key:"resetFixedPosition",value:function(){if(this.needFullRender&&this.wot.wtTable.holder.parentNode){var e=this.clone.wtTable.holder.parentNode,t=0,o=this.wot.getSetting("preventOverflow");if(this.trimmingContainer!==window||o&&"horizontal"===o)t=this.getScrollPosition(),(0,l.resetCssTransform)(e);else{var n=this.wot.wtTable.hider.getBoundingClientRect(),r=Math.ceil(n.left),i=Math.ceil(n.right),s=void 0,a=void 0;a=this.wot.wtTable.hider.style.top,a=""===a?0:a,s=0>r&&i-e.offsetWidth>0?-r:0,t=s,s+="px",(0,l.setOverlayPosition)(e,s,a)}this.adjustHeaderBordersPosition(t),this.adjustElementsSize()}}},{key:"setScrollPosition",value:function(e){this.mainTableScrollableElement===window?window.scrollTo(e,(0,l.getWindowScrollTop)()):this.mainTableScrollableElement.scrollLeft=e}},{key:"onScroll",value:function(){this.wot.getSetting("onScrollVertically")}},{key:"sumCellSizes",value:function(e,t){for(var o=0,n=this.wot.wtSettings.defaultColumnWidth;t>e;)o+=this.wot.wtTable.getStretchedColumnWidth(e)||n,e++;return o}},{key:"adjustElementsSize",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this.updateTrimmingContainer(),(this.needFullRender||e)&&(this.adjustRootElementSize(),this.adjustRootChildrenSize(),e||(this.areElementSizesAdjusted=!0))}},{key:"adjustRootElementSize",value:function(){var e=this.wot.wtTable.holder,t=e.clientHeight===e.offsetHeight?0:(0,l.getScrollbarWidth)(),o=this.clone.wtTable.holder.parentNode,n=o.style,r=this.wot.getSetting("preventOverflow"),i=void 0;if(this.trimmingContainer!==window||"vertical"===r){var s=this.wot.wtViewport.getWorkspaceHeight()-t;s=Math.min(s,(0,l.innerHeight)(this.wot.wtTable.wtRootElement)),n.height=s+"px"}else n.height="";this.clone.wtTable.holder.style.height=n.height,i=(0,l.outerWidth)(this.clone.wtTable.TABLE),n.width=(0===i?i:i+4)+"px"}},{key:"adjustRootChildrenSize",value:function(){var e=(0,l.getScrollbarWidth)();this.clone.wtTable.hider.style.height=this.hider.style.height,this.clone.wtTable.holder.style.height=this.clone.wtTable.holder.parentNode.style.height,0===e&&(e=30),this.clone.wtTable.holder.style.width=parseInt(this.clone.wtTable.holder.parentNode.style.width,10)+e+"px"}},{key:"applyToDOM",value:function(){var e=this.wot.getSetting("totalColumns");if(this.areElementSizesAdjusted||this.adjustElementsSize(),"number"==typeof this.wot.wtViewport.columnsRenderCalculator.startPosition)this.spreader.style.left=this.wot.wtViewport.columnsRenderCalculator.startPosition+"px";else{if(0!==e)throw Error("Incorrect value of the columnsRenderCalculator");this.spreader.style.left="0"}this.spreader.style.right="",this.needFullRender&&this.syncOverlayOffset()}},{key:"syncOverlayOffset",value:function(){this.clone.wtTable.spreader.style.top="number"==typeof this.wot.wtViewport.rowsRenderCalculator.startPosition?this.wot.wtViewport.rowsRenderCalculator.startPosition+"px":""}},{key:"scrollTo",value:function(e,t){var o=this.getTableParentOffset(),n=this.wot.cloneSource?this.wot.cloneSource:this.wot,r=n.wtTable.holder,i=0;t&&r.offsetWidth!==r.clientWidth&&(i=(0,l.getScrollbarWidth)()),t?(o+=this.sumCellSizes(0,e+1),o-=this.wot.wtViewport.getViewportWidth()):o+=this.sumCellSizes(this.wot.getSetting("fixedColumnsLeft"),e),o+=i,this.setScrollPosition(o)}},{key:"getTableParentOffset",value:function(){var e=this.wot.getSetting("preventOverflow"),t=0;return e||this.trimmingContainer!==window||(t=this.wot.wtTable.holderOffset.left),t}},{key:"getScrollPosition",value:function(){return(0,l.getScrollLeft)(this.mainTableScrollableElement)}},{key:"adjustHeaderBordersPosition",value:function(e){var t=this.wot.wtTable.holder.parentNode,o=this.wot.getSetting("rowHeaders"),n=this.wot.getSetting("fixedColumnsLeft");if(this.wot.getSetting("totalRows")?(0,l.removeClass)(t,"emptyRows"):(0,l.addClass)(t,"emptyRows"),n&&!o.length)(0,l.addClass)(t,"innerBorderLeft");else if(!n&&o.length){var r=(0,l.hasClass)(t,"innerBorderLeft");e?(0,l.addClass)(t,"innerBorderLeft"):(0,l.removeClass)(t,"innerBorderLeft"),(!r&&e||r&&!e)&&this.wot.wtOverlays.adjustElementsSize()}}}]),t}(u.default);u.default.registerOverlay(u.default.CLONE_LEFT,c),t.default=c},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var s=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),l=o(0),a=o(28),u=function(e){return e&&e.__esModule?e:{default:e}}(a),c=function(e){function t(e){n(this,t);var o=r(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.clone=o.makeClone(u.default.CLONE_TOP),o}return i(t,e),s(t,[{key:"shouldBeRendered",value:function(){return!(!this.wot.getSetting("fixedRowsTop")&&!this.wot.getSetting("columnHeaders").length)}},{key:"resetFixedPosition",value:function(){if(this.needFullRender&&this.wot.wtTable.holder.parentNode){var e=this.clone.wtTable.holder.parentNode,t=0,o=this.wot.getSetting("preventOverflow");if(this.trimmingContainer!==window||o&&"vertical"===o)t=this.getScrollPosition(),(0,l.resetCssTransform)(e);else{var n=this.wot.wtTable.hider.getBoundingClientRect(),r=Math.ceil(n.top),i=Math.ceil(n.bottom),s=void 0,a=void 0;s=this.wot.wtTable.hider.style.left,s=""===s?0:s,a=0>r&&i-e.offsetHeight>0?-r:0,t=a,a+="px",(0,l.setOverlayPosition)(e,s,a)}this.adjustHeaderBordersPosition(t),this.adjustElementsSize()}}},{key:"setScrollPosition",value:function(e){this.mainTableScrollableElement===window?window.scrollTo((0,l.getWindowScrollLeft)(),e):this.mainTableScrollableElement.scrollTop=e}},{key:"onScroll",value:function(){this.wot.getSetting("onScrollHorizontally")}},{key:"sumCellSizes",value:function(e,t){for(var o=0,n=this.wot.wtSettings.settings.defaultRowHeight;t>e;){var r=this.wot.wtTable.getRowHeight(e);o+=void 0===r?n:r,e++}return o}},{key:"adjustElementsSize",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this.updateTrimmingContainer(),(this.needFullRender||e)&&(this.adjustRootElementSize(),this.adjustRootChildrenSize(),e||(this.areElementSizesAdjusted=!0))}},{key:"adjustRootElementSize",value:function(){var e=this.wot.wtTable.holder,t=e.clientWidth===e.offsetWidth?0:(0,l.getScrollbarWidth)(),o=this.clone.wtTable.holder.parentNode,n=o.style,r=this.wot.getSetting("preventOverflow"),i=void 0;if(this.trimmingContainer!==window||"horizontal"===r){var s=this.wot.wtViewport.getWorkspaceWidth()-t;s=Math.min(s,(0,l.innerWidth)(this.wot.wtTable.wtRootElement)),n.width=s+"px"}else n.width="";this.clone.wtTable.holder.style.width=n.width,i=(0,l.outerHeight)(this.clone.wtTable.TABLE),n.height=(0===i?i:i+4)+"px"}},{key:"adjustRootChildrenSize",value:function(){var e=(0,l.getScrollbarWidth)();this.clone.wtTable.hider.style.width=this.hider.style.width,this.clone.wtTable.holder.style.width=this.clone.wtTable.holder.parentNode.style.width,0===e&&(e=30),this.clone.wtTable.holder.style.height=parseInt(this.clone.wtTable.holder.parentNode.style.height,10)+e+"px"}},{key:"applyToDOM",value:function(){var e=this.wot.getSetting("totalRows");if(this.areElementSizesAdjusted||this.adjustElementsSize(),"number"==typeof this.wot.wtViewport.rowsRenderCalculator.startPosition)this.spreader.style.top=this.wot.wtViewport.rowsRenderCalculator.startPosition+"px";else{if(0!==e)throw Error("Incorrect value of the rowsRenderCalculator");this.spreader.style.top="0"}this.spreader.style.bottom="",this.needFullRender&&this.syncOverlayOffset()}},{key:"syncOverlayOffset",value:function(){this.clone.wtTable.spreader.style.left="number"==typeof this.wot.wtViewport.columnsRenderCalculator.startPosition?this.wot.wtViewport.columnsRenderCalculator.startPosition+"px":""}},{key:"scrollTo",value:function(e,t){var o=this.getTableParentOffset(),n=this.wot.cloneSource?this.wot.cloneSource:this.wot,r=n.wtTable.holder,i=0;if(t&&r.offsetHeight!==r.clientHeight&&(i=(0,l.getScrollbarWidth)()),t){var s=this.wot.getSetting("fixedRowsBottom"),a=(this.wot.getSetting("fixedRowsTop"),this.wot.getSetting("totalRows"));o+=this.sumCellSizes(0,e+1),o-=this.wot.wtViewport.getViewportHeight()-this.sumCellSizes(a-s,a),o+=1}else o+=this.sumCellSizes(this.wot.getSetting("fixedRowsTop"),e);o+=i,this.setScrollPosition(o)}},{key:"getTableParentOffset",value:function(){return this.mainTableScrollableElement===window?this.wot.wtTable.holderOffset.top:0}},{key:"getScrollPosition",value:function(){return(0,l.getScrollTop)(this.mainTableScrollableElement)}},{key:"redrawSelectionBorders",value:function(e){if(e&&e.cellRange){var t=e.getBorder(this.wot);if(t){var o=e.getCorners();t.disappear(),t.appear(o)}}}},{key:"redrawAllSelectionsBorders",value:function(){var e=this.wot.selections;this.redrawSelectionBorders(e.current),this.redrawSelectionBorders(e.area),this.redrawSelectionBorders(e.fill),this.wot.wtTable.wot.wtOverlays.leftOverlay.refresh()}},{key:"adjustHeaderBordersPosition",value:function(e){var t=this.wot.wtTable.holder.parentNode;if(this.wot.getSetting("totalColumns")?(0,l.removeClass)(t,"emptyColumns"):(0,l.addClass)(t,"emptyColumns"),0===this.wot.getSetting("fixedRowsTop")&&this.wot.getSetting("columnHeaders").length>0){var o=(0,l.hasClass)(t,"innerBorderTop");e||0===this.wot.getSetting("totalRows")?(0,l.addClass)(t,"innerBorderTop"):(0,l.removeClass)(t,"innerBorderTop"),(!o&&e||o&&!e)&&(this.wot.wtOverlays.adjustElementsSize(),this.redrawAllSelectionsBorders())}if(0===this.wot.getSetting("rowHeaders").length){var n=this.clone.wtTable.THEAD.querySelectorAll("th:nth-of-type(2)");if(n)for(var r=0;n.length>r;r++)n[r].style["border-left-width"]=0}}}]),t}(u.default);u.default.registerOverlay(u.default.CLONE_TOP,c),t.default=c},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var s=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),l=o(0),a=o(28),u=function(e){return e&&e.__esModule?e:{default:e}}(a),c=function(e){function t(e){n(this,t);var o=r(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.clone=o.makeClone(u.default.CLONE_TOP_LEFT_CORNER),o}return i(t,e),s(t,[{key:"shouldBeRendered",value:function(){return!(!this.wot.getSetting("fixedRowsTop")&&!this.wot.getSetting("columnHeaders").length||!this.wot.getSetting("fixedColumnsLeft")&&!this.wot.getSetting("rowHeaders").length)}},{key:"resetFixedPosition",value:function(){if(this.updateTrimmingContainer(),this.wot.wtTable.holder.parentNode){var e=this.clone.wtTable.holder.parentNode,t=(0,l.outerHeight)(this.clone.wtTable.TABLE),o=(0,l.outerWidth)(this.clone.wtTable.TABLE),n=this.wot.getSetting("preventOverflow");if(this.trimmingContainer===window){var r=this.wot.wtTable.hider.getBoundingClientRect(),i=Math.ceil(r.top),s=Math.ceil(r.left),a=Math.ceil(r.bottom),u=Math.ceil(r.right),c="0",h="0";n&&"vertical"!==n||0>s&&u-e.offsetWidth>0&&(c=-s+"px"),n&&"horizontal"!==n||0>i&&a-e.offsetHeight>0&&(h=-i+"px"),(0,l.setOverlayPosition)(e,c,h)}else(0,l.resetCssTransform)(e);e.style.height=(0===t?t:t+4)+"px",e.style.width=(0===o?o:o+4)+"px"}}}]),t}(u.default);u.default.registerOverlay(u.default.CLONE_TOP_LEFT_CORNER,c),t.default=c},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},s=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),l=o(0),a=o(136),u=n(a),c=o(42),h=n(c),d=o(68),f=n(d);t.default=function(){function e(t,o){r(this,e),this.settings=t,this.cellRange=o||null,this.instanceBorders={}}return s(e,[{key:"getBorder",value:function(e){if(this.instanceBorders[e.guid])return this.instanceBorders[e.guid];this.instanceBorders[e.guid]=new u.default(e,this.settings)}},{key:"isEmpty",value:function(){return null===this.cellRange}},{key:"add",value:function(e){this.isEmpty()?this.cellRange=new f.default(e,e,e):this.cellRange.expand(e)}},{key:"replace",value:function(e,t){if(!this.isEmpty()){if(this.cellRange.from.isEqual(e))return this.cellRange.from=t,!0;if(this.cellRange.to.isEqual(e))return this.cellRange.to=t,!0}return!1}},{key:"clear",value:function(){this.cellRange=null}},{key:"getCorners",value:function(){var e=this.cellRange.getTopLeftCorner(),t=this.cellRange.getBottomRightCorner();return[e.row,e.col,t.row,t.col]}},{key:"addClassAtCoords",value:function(e,t,o,n){var r=e.wtTable.getCell(new h.default(t,o));"object"===(void 0===r?"undefined":i(r))&&(0,l.addClass)(r,n)}},{key:"draw",value:function(e){if(this.isEmpty()){if(this.settings.border){var t=this.getBorder(e);t&&t.disappear()}}else{for(var o=e.wtTable.getRenderedRowsCount(),n=e.wtTable.getRenderedColumnsCount(),r=this.getCorners(),i=void 0,s=void 0,a=void 0,u=0;n>u;u++)if((s=e.wtTable.columnFilter.renderedToSource(u))>=r[1]&&r[3]>=s&&(a=e.wtTable.getColumnHeader(s))){var c=[];this.settings.highlightHeaderClassName&&c.push(this.settings.highlightHeaderClassName),this.settings.highlightColumnClassName&&c.push(this.settings.highlightColumnClassName),(0,l.addClass)(a,c)}for(var h=0;o>h;h++){if((i=e.wtTable.rowFilter.renderedToSource(h))>=r[0]&&r[2]>=i&&(a=e.wtTable.getRowHeader(i))){var d=[];this.settings.highlightHeaderClassName&&d.push(this.settings.highlightHeaderClassName),this.settings.highlightRowClassName&&d.push(this.settings.highlightRowClassName),(0,l.addClass)(a,d)}for(var f=0;n>f;f++)s=e.wtTable.columnFilter.renderedToSource(f),r[0]>i||i>r[2]||r[1]>s||s>r[3]?r[0]>i||i>r[2]?r[1]>s||s>r[3]||this.settings.highlightColumnClassName&&this.addClassAtCoords(e,i,s,this.settings.highlightColumnClassName):this.settings.highlightRowClassName&&this.addClassAtCoords(e,i,s,this.settings.highlightRowClassName):this.settings.className&&this.addClassAtCoords(e,i,s,this.settings.className)}if(e.getSetting("onBeforeDrawBorders",r,this.settings.className),this.settings.border){var p=this.getBorder(e);p&&p.appear(r)}}}}]),e}()},function(e,t,o){"use strict";t.__esModule=!0;var n=o(14),r=o(9),i=o(26);t.default={editor:(0,n.getEditor)("autocomplete"),renderer:(0,r.getRenderer)("autocomplete"),validator:(0,i.getValidator)("autocomplete")}},function(e,t,o){"use strict";t.__esModule=!0;var n=o(14),r=o(9);t.default={editor:(0,n.getEditor)("checkbox"),renderer:(0,r.getRenderer)("checkbox")}},function(e,t,o){"use strict";t.__esModule=!0;var n=o(14),r=o(9),i=o(26);t.default={editor:(0,n.getEditor)("date"),renderer:(0,r.getRenderer)("autocomplete"),validator:(0,i.getValidator)("date")}},function(e,t,o){"use strict";t.__esModule=!0;var n=o(14),r=o(9),i=o(26);t.default={editor:(0,n.getEditor)("dropdown"),renderer:(0,r.getRenderer)("autocomplete"),validator:(0,i.getValidator)("autocomplete")}},function(e,t,o){"use strict";t.__esModule=!0;var n=o(14),r=o(9);t.default={editor:(0,n.getEditor)("handsontable"),renderer:(0,r.getRenderer)("autocomplete")}},function(e,t,o){"use strict";t.__esModule=!0;var n=o(14),r=o(9),i=o(26);t.default={editor:(0,n.getEditor)("numeric"),renderer:(0,r.getRenderer)("numeric"),validator:(0,i.getValidator)("numeric"),dataType:"number"}},function(e,t,o){"use strict";t.__esModule=!0;var n=o(14),r=o(9);o(26);t.default={editor:(0,n.getEditor)("password"),renderer:(0,r.getRenderer)("password"),copyable:!1}},function(e,t,o){"use strict";t.__esModule=!0;var n=o(25),r=o(14),i=o(9);t.default={editor:(0,r.getEditor)((0,n.isMobileBrowser)()?"mobile":"text"),renderer:(0,i.getRenderer)("text")}},function(e,t,o){"use strict";t.__esModule=!0;var n=o(14),r=o(9),i=o(26);t.default={editor:(0,n.getEditor)("text"),renderer:(0,r.getRenderer)("text"),validator:(0,i.getValidator)("time")}},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t,o){var n=this;this.instance=e,this.priv=t,this.GridSettings=o,this.dataSource=this.instance.getSettings().data,this.cachedLength=null,this.skipCache=!1,this.latestSourceRowsCount=0,this.duckSchema=this.dataSource&&this.dataSource[0]?this.recursiveDuckSchema(this.dataSource[0]):{},this.createMap(),this.interval=f.default.create(function(){return n.clearLengthCache()},"15fps"),this.instance.addHook("skipLengthCache",function(e){return n.onSkipLengthCache(e)}),this.onSkipLengthCache(500)}t.__esModule=!0;var i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},s=o(134),l=n(s),a=o(64),u=o(65),c=o(1),h=o(2),d=o(273),f=n(d),p=o(6),g=o(211),v=n(g),m=o(8);n(m);r.prototype.DESTINATION_RENDERER=1,r.prototype.DESTINATION_CLIPBOARD_GENERATOR=2,r.prototype.recursiveDuckSchema=function(e){return(0,c.duckSchema)(e)},r.prototype.recursiveDuckColumns=function(e,t,o){var n,r;if(void 0===t&&(t=0,o=""),"object"===(void 0===e?"undefined":i(e))&&!Array.isArray(e))for(r in e)(0,c.hasOwnProperty)(e,r)&&(null===e[r]?(n=o+r,this.colToPropCache.push(n),this.propToColCache.set(n,t),t++):t=this.recursiveDuckColumns(e[r],t,r+"."));return t},r.prototype.createMap=function(){var e=void 0,t=this.getSchema();if(void 0===t)throw Error("trying to create `columns` definition but you didn't provide `schema` nor `data`");this.colToPropCache=[],this.propToColCache=new v.default;var o=this.instance.getSettings().columns;if(o){var n=this.instance.getSettings().maxCols,r=Math.min(n,o.length),i=0,s=!1,l=(0,c.deepObjectSize)(t);for("function"==typeof o&&(r=l>0?l:this.instance.countSourceCols(),s=!0),e=0;r>e;e++){var a=s?o(e):o[e];if((0,c.isObject)(a)){if(void 0!==a.data){var u=s?i:e;this.colToPropCache[u]=a.data,this.propToColCache.set(a.data,u)}i++}}}else this.recursiveDuckColumns(t)},r.prototype.colToProp=function(e){return e=this.instance.runHooks("modifyCol",e),!isNaN(e)&&this.colToPropCache&&void 0!==this.colToPropCache[e]?this.colToPropCache[e]:e},r.prototype.propToCol=function(e){var t;return t=void 0===this.propToColCache.get(e)?e:this.propToColCache.get(e),t=this.instance.runHooks("unmodifyCol",t)},r.prototype.getSchema=function(){var e=this.instance.getSettings().dataSchema;return e?"function"==typeof e?e():e:this.duckSchema},r.prototype.createRow=function(e,t,o){var n,r,i=this.instance.countCols(),s=0;t||(t=1),"number"==typeof e&&e<this.instance.countSourceRows()||(e=this.instance.countSourceRows()),this.instance.runHooks("beforeCreateRow",e,t,o),r=e;for(var l=this.instance.getSettings().maxRows;t>s&&this.instance.countSourceRows()<l;)"array"===this.instance.dataType?this.instance.getSettings().dataSchema?n=(0,c.deepClone)(this.getSchema()):(n=[],(0,p.rangeEach)(i-1,function(){return n.push(null)})):"function"===this.instance.dataType?n=this.instance.getSettings().dataSchema(e):(n={},(0,c.deepExtend)(n,this.getSchema())),e===this.instance.countSourceRows()?this.dataSource.push(n):this.spliceData(e,0,n),s++,r++;return this.instance.runHooks("afterCreateRow",e,s,o),this.instance.forceFullRender=!0,s},r.prototype.createCol=function(e,t,o){if(!this.instance.isColumnModificationAllowed())throw Error("Cannot create new column. When data source in an object, you can only have as much columns as defined in first data row, data schema or in the 'columns' setting.If you want to be able to add new columns, you have to use array datasource.");var n,r,i=this.instance.countSourceRows(),s=this.dataSource,l=0;t||(t=1),"number"==typeof e&&e<this.instance.countCols()||(e=this.instance.countCols()),this.instance.runHooks("beforeCreateCol",e,t,o),r=e;for(var a=this.instance.getSettings().maxCols;t>l&&this.instance.countCols()<a;){if(n=(0,u.columnFactory)(this.GridSettings,this.priv.columnsSettingConflicts),"number"==typeof e&&e<this.instance.countCols()){for(var c=0;i>c;c++)s[c].splice(r,0,null);this.priv.columnSettings.splice(r,0,n)}else{if(i>0)for(var h=0;i>h;h++)void 0===s[h]&&(s[h]=[]),s[h].push(null);else s.push([null]);this.priv.columnSettings.push(n)}l++,r++}return this.instance.runHooks("afterCreateCol",e,l,o),this.instance.forceFullRender=!0,l},r.prototype.removeRow=function(e,t,o){t||(t=1),"number"!=typeof e&&(e=-t),t=this.instance.runHooks("modifyRemovedAmount",t,e),e=(this.instance.countSourceRows()+e)%this.instance.countSourceRows();var n=this.visualRowsToPhysical(e,t);if(!1!==this.instance.runHooks("beforeRemoveRow",e,t,n,o)){var r=this.dataSource,i=void 0;i=this.filterData(e,t),i&&(r.length=0,Array.prototype.push.apply(r,i)),this.instance.runHooks("afterRemoveRow",e,t,n,o),this.instance.forceFullRender=!0}},r.prototype.removeCol=function(e,t,o){if("object"===this.instance.dataType||this.instance.getSettings().columns)throw Error("cannot remove column with object data source or columns option specified");t||(t=1),"number"!=typeof e&&(e=-t),e=(this.instance.countCols()+e)%this.instance.countCols();var n=this.visualColumnsToPhysical(e,t),r=n.slice(0).sort(function(e,t){return t-e});if(!1!==this.instance.runHooks("beforeRemoveCol",e,t,n,o)){for(var i=!0,s=r.length,l=this.dataSource,a=0;s>a;a++)i&&n[0]!==n[a]-a&&(i=!1);if(i)for(var u=0,c=this.instance.countSourceRows();c>u;u++)l[u].splice(n[0],t);else{for(var h=0,d=this.instance.countSourceRows();d>h;h++)for(var f=0;s>f;f++)l[h].splice(r[f],1);for(var p=0;s>p;p++)this.priv.columnSettings.splice(n[p],1)}this.instance.runHooks("afterRemoveCol",e,t,n,o),this.instance.forceFullRender=!0}},r.prototype.spliceCol=function(e,t,o){var n=4>arguments.length?[]:[].slice.call(arguments,3),r=this.instance.getDataAtCol(e),i=r.slice(t,t+o),s=r.slice(t+o);(0,h.extendArray)(n,s);for(var l=0;o>l;)n.push(null),l++;return(0,h.to2dArray)(n),this.instance.populateFromArray(t,e,n,null,null,"spliceCol"),i},r.prototype.spliceRow=function(e,t,o){var n=4>arguments.length?[]:[].slice.call(arguments,3),r=this.instance.getSourceDataAtRow(e),i=r.slice(t,t+o),s=r.slice(t+o);(0,h.extendArray)(n,s);for(var l=0;o>l;)n.push(null),l++;return this.instance.populateFromArray(e,t,[n],null,null,"spliceRow"),i},r.prototype.spliceData=function(e,t,o){!1!==this.instance.runHooks("beforeDataSplice",e,t,o)&&this.dataSource.splice(e,t,o)},r.prototype.filterData=function(e,t){var o=this.visualRowsToPhysical(e,t);if(!1!==this.instance.runHooks("beforeDataFilter",e,t,o))return this.dataSource.filter(function(e,t){return-1==o.indexOf(t)})},r.prototype.get=function(e,t){e=this.instance.runHooks("modifyRow",e);var o=this.dataSource[e],n=this.instance.runHooks("modifyRowData",e);o=isNaN(n)?n:o;var r=null;if(o&&o.hasOwnProperty&&(0,c.hasOwnProperty)(o,t))r=o[t];else if("string"==typeof t&&t.indexOf(".")>-1){var i=t.split("."),s=o;if(!s)return null;for(var l=0,a=i.length;a>l;l++)if(void 0===(s=s[i[l]]))return null;r=s}else"function"==typeof t&&(r=t(this.dataSource.slice(e,e+1)[0]));if(this.instance.hasHook("modifyData")){var u=(0,c.createObjectPropListener)(r);this.instance.runHooks("modifyData",e,this.propToCol(t),u,"get"),u.isTouched()&&(r=u.value)}return r};var y=(0,a.cellMethodLookupFactory)("copyable",!1);r.prototype.getCopyable=function(e,t){return y.call(this.instance,e,this.propToCol(t))?this.get(e,t):""},r.prototype.set=function(e,t,o,n){e=this.instance.runHooks("modifyRow",e,n||"datamapGet");var r=this.dataSource[e],i=this.instance.runHooks("modifyRowData",e);if(r=isNaN(i)?i:r,this.instance.hasHook("modifyData")){var s=(0,c.createObjectPropListener)(o);this.instance.runHooks("modifyData",e,this.propToCol(t),s,"set"),s.isTouched()&&(o=s.value)}if(r&&r.hasOwnProperty&&(0,c.hasOwnProperty)(r,t))r[t]=o;else if("string"==typeof t&&t.indexOf(".")>-1){var l=t.split("."),a=r,u=0,h=void 0;for(u=0,h=l.length-1;h>u;u++)void 0===a[l[u]]&&(a[l[u]]={}),a=a[l[u]];a[l[u]]=o}else"function"==typeof t?t(this.dataSource.slice(e,e+1)[0],o):r[t]=o},r.prototype.visualRowsToPhysical=function(e,t){for(var o,n=this.instance.countSourceRows(),r=(n+e)%n,i=[],s=t;n>r&&s;)o=this.instance.runHooks("modifyRow",r),i.push(o),s--,r++;return i},r.prototype.visualColumnsToPhysical=function(e,t){for(var o=this.instance.countCols(),n=(o+e)%o,r=[],i=t;o>n&&i;){r.push(this.instance.runHooks("modifyCol",n)),i--,n++}return r},r.prototype.clear=function(){for(var e=0;e<this.instance.countSourceRows();e++)for(var t=0;t<this.instance.countCols();t++)this.set(e,this.colToProp(t),"")},r.prototype.clearLengthCache=function(){this.cachedLength=null},r.prototype.getLength=function(){var e=this,t=void 0,o=this.instance.getSettings().maxRows;t=0>o||0===o?0:o||1/0;var n=this.instance.countSourceRows();if(this.instance.hasHook("modifyRow")){var r=this.skipCache;this.interval.start(),n!==this.latestSourceRowsCount&&(r=!0),this.latestSourceRowsCount=n,null===this.cachedLength||r?((0,p.rangeEach)(n-1,function(t){null===(t=e.instance.runHooks("modifyRow",t))&&--n}),this.cachedLength=n):n=this.cachedLength}else this.interval.stop();return Math.min(n,t)},r.prototype.getAll=function(){var e={row:0,col:0},t={row:Math.max(this.instance.countSourceRows()-1,0),col:Math.max(this.instance.countCols()-1,0)};return e.row-t.row!=0||this.instance.countSourceRows()?this.getRange(e,t,r.prototype.DESTINATION_RENDERER):[]},r.prototype.getRange=function(e,t,o){var n,r,i,s,l,a=[],u=this.instance.getSettings().maxRows,c=this.instance.getSettings().maxCols;if(0===u||0===c)return[];var h=o===this.DESTINATION_CLIPBOARD_GENERATOR?this.getCopyable:this.get;for(r=Math.min(Math.max(u-1,0),Math.max(e.row,t.row)),s=Math.min(Math.max(c-1,0),Math.max(e.col,t.col)),n=Math.min(e.row,t.row);r>=n;n++){l=[];var d=this.instance.runHooks("modifyRow",n);for(i=Math.min(e.col,t.col);s>=i&&null!==d;i++)l.push(h.call(this,n,this.colToProp(i)));null!==d&&a.push(l)}return a},r.prototype.getText=function(e,t){return l.default.stringify(this.getRange(e,t,this.DESTINATION_RENDERER))},r.prototype.getCopyableText=function(e,t){return l.default.stringify(this.getRange(e,t,this.DESTINATION_CLIPBOARD_GENERATOR))},r.prototype.onSkipLengthCache=function(e){var t=this;this.skipCache=!0,setTimeout(function(){t.skipCache=!1},e)},r.prototype.destroy=function(){this.interval.stop(),this.interval=null,this.instance=null,this.priv=null,this.GridSettings=null,this.dataSource=null,this.cachedLength=null,this.duckSchema=null},t.default=r},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=o(1),s=o(2),l=o(6);t.default=function(){function e(t){var o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];n(this,e),this.hot=t,this.data=o,this.dataType="array",this.colToProp=function(){},this.propToCol=function(){}}return r(e,[{key:"getData",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=this.data;return e&&(t=this.getByRange({row:0,col:0},{row:Math.max(this.countRows()-1,0),col:Math.max(this.countColumns()-1,0)},!0)),t}},{key:"setData",value:function(e){this.data=e}},{key:"getAtColumn",value:function(e){var t=this,o=[];return(0,s.arrayEach)(this.data,function(n){var r=t.colToProp(e);n="string"==typeof r?(0,i.getProperty)(n,r):n[r],o.push(n)}),o}},{key:"getAtRow",value:function(e){return this.data[e]}},{key:"getAtCell",value:function(e,t){var o=null,n=this.hot.runHooks("modifyRowData",e),r=isNaN(n)?n:this.data[e];if(r){var s=this.colToProp(t);o="string"==typeof s?(0,i.getProperty)(r,s):"function"==typeof s?s(this.data.slice(e,e+1)[0]):r[s]}return o}},{key:"getByRange",value:function(e,t){var o=this,n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=Math.min(e.row,t.row),i=Math.min(e.col,t.col),s=Math.max(e.row,t.row),a=Math.max(e.col,t.col),u=[];return(0,l.rangeEach)(r,s,function(e){var t=o.getAtRow(e),r=void 0;"array"===o.dataType?r=t.slice(i,a+1):"object"===o.dataType&&(r=n?[]:{},(0,l.rangeEach)(i,a,function(e){var i=o.colToProp(e);n?r.push(t[i]):r[i]=t[i]})),u.push(r)}),u}},{key:"countRows",value:function(){return Array.isArray(this.data)?this.data.length:0}},{key:"countColumns",value:function(){var e=0;return Array.isArray(this.data)&&("array"===this.dataType?e=this.data[0].length:"object"===this.dataType&&(e=Object.keys(this.data[0]).length)),e}},{key:"destroy",value:function(){this.data=null,this.hot=null}}]),e}()},function(e,t,o){"use strict";function n(e,t,o){function n(e){o.setSelectedHeaders(!1,!1,!1);var n="function"==typeof t.settings.enterMoves?t.settings.enterMoves(event):t.settings.enterMoves;e?o.transformStart(-n.row,-n.col):o.transformStart(n.row,n.col,!0)}function a(e){e?(o.selectedHeader.cols&&o.setSelectedHeaders(o.selectedHeader.rows,!1,!1),o.transformEnd(-1,0)):(o.setSelectedHeaders(!1,!1,!1),o.transformStart(-1,0))}function h(e){e?o.transformEnd(1,0):(o.setSelectedHeaders(!1,!1,!1),o.transformStart(1,0))}function d(e){e?o.transformEnd(0,1):(o.setSelectedHeaders(!1,!1,!1),o.transformStart(0,1))}function f(e){e?(o.selectedHeader.rows&&o.setSelectedHeaders(!1,o.selectedHeader.cols,!1),o.transformEnd(0,-1)):(o.setSelectedHeaders(!1,!1,!1),o.transformStart(0,-1))}function p(l){var u,p;if(e.isListening()&&(e.runHooks("beforeKeyDown",l),!y&&!(0,s.isImmediatePropagationStopped)(l)&&(t.lastKeyCode=l.keyCode,o.isSelected()))){if(u=(l.ctrlKey||l.metaKey)&&!l.altKey,v&&!v.isWaiting()&&!((0,i.isMetaKey)(l.keyCode)||(0,i.isCtrlKey)(l.keyCode)||u||m.isEditorOpened()))return void m.openEditor("",l);switch(p=l.shiftKey?o.setRangeEnd:o.setRangeStart,l.keyCode){case i.KEY_CODES.A:!m.isEditorOpened()&&u&&(o.selectAll(),l.preventDefault(),(0,s.stopPropagation)(l));break;case i.KEY_CODES.ARROW_UP:m.isEditorOpened()&&!v.isWaiting()&&m.closeEditorAndSaveChanges(u),a(l.shiftKey),l.preventDefault(),(0,s.stopPropagation)(l);break;case i.KEY_CODES.ARROW_DOWN:m.isEditorOpened()&&!v.isWaiting()&&m.closeEditorAndSaveChanges(u),h(l.shiftKey),l.preventDefault(),(0,s.stopPropagation)(l);break;case i.KEY_CODES.ARROW_RIGHT:m.isEditorOpened()&&!v.isWaiting()&&m.closeEditorAndSaveChanges(u),d(l.shiftKey),l.preventDefault(),(0,s.stopPropagation)(l);break;case i.KEY_CODES.ARROW_LEFT:m.isEditorOpened()&&!v.isWaiting()&&m.closeEditorAndSaveChanges(u),f(l.shiftKey),l.preventDefault(),(0,s.stopPropagation)(l);break;case i.KEY_CODES.TAB:o.setSelectedHeaders(!1,!1,!1);var g="function"==typeof t.settings.tabMoves?t.settings.tabMoves(l):t.settings.tabMoves;l.shiftKey?o.transformStart(-g.row,-g.col):o.transformStart(g.row,g.col,!0),l.preventDefault(),(0,s.stopPropagation)(l);break;case i.KEY_CODES.BACKSPACE:case i.KEY_CODES.DELETE:o.empty(l),m.prepareEditor(),l.preventDefault();break;case i.KEY_CODES.F2:m.openEditor(null,l),v&&v.enableFullEditMode(),l.preventDefault();break;case i.KEY_CODES.ENTER:m.isEditorOpened()?(v&&v.state!==c.EditorState.WAITING&&m.closeEditorAndSaveChanges(u),n(l.shiftKey)):e.getSettings().enterBeginsEditing?(m.openEditor(null,l),v&&v.enableFullEditMode()):n(l.shiftKey),l.preventDefault(),(0,s.stopImmediatePropagation)(l);break;case i.KEY_CODES.ESCAPE:m.isEditorOpened()&&m.closeEditorAndRestoreOriginalValue(u),l.preventDefault();break;case i.KEY_CODES.HOME:o.setSelectedHeaders(!1,!1,!1),p(l.ctrlKey||l.metaKey?new r.CellCoords(0,t.selRange.from.col):new r.CellCoords(t.selRange.from.row,0)),l.preventDefault(),(0,s.stopPropagation)(l);break;case i.KEY_CODES.END:o.setSelectedHeaders(!1,!1,!1),p(l.ctrlKey||l.metaKey?new r.CellCoords(e.countRows()-1,t.selRange.from.col):new r.CellCoords(t.selRange.from.row,e.countCols()-1)),l.preventDefault(),(0,s.stopPropagation)(l);break;case i.KEY_CODES.PAGE_UP:o.setSelectedHeaders(!1,!1,!1),o.transformStart(-e.countVisibleRows(),0),l.preventDefault(),(0,s.stopPropagation)(l);break;case i.KEY_CODES.PAGE_DOWN:o.setSelectedHeaders(!1,!1,!1),o.transformStart(e.countVisibleRows(),0),l.preventDefault(),(0,s.stopPropagation)(l)}}}var g,v,m=this,y=!1;g=new u.default(e),this.destroyEditor=function(e){this.closeEditor(e)},this.getActiveEditor=function(){return v},this.prepareEditor=function(){var o,n,r,i,s,a,u;if(v&&v.isWaiting())return void this.closeEditor(!1,!1,function(e){e&&m.prepareEditor()});o=t.selRange.highlight.row,n=t.selRange.highlight.col,r=e.colToProp(n),i=e.getCell(o,n),s=e.getSourceDataAtCell(e.runHooks("modifyRow",o),n),a=e.getCellMeta(o,n),u=e.getCellEditor(a),u?(v=(0,l.getEditorInstance)(u,e),v.prepare(o,n,r,i,s,a)):v=void 0},this.isEditorOpened=function(){return v&&v.isOpened()},this.openEditor=function(e,t){v&&!v.cellProperties.readOnly?v.beginEditing(e,t):v&&v.cellProperties.readOnly&&t&&t.keyCode===i.KEY_CODES.ENTER&&n()},this.closeEditor=function(e,t,o){v?v.finishEditing(e,t,o):o&&o(!1)},this.closeEditorAndSaveChanges=function(e){return this.closeEditor(!1,e)},this.closeEditorAndRestoreOriginalValue=function(e){return this.closeEditor(!0,e)},function(){function t(e,t,o){"TD"==o.nodeName&&(m.openEditor(),v&&v.enableFullEditMode())}e.addHook("afterDocumentKeyDown",p),g.addEventListener(document.documentElement,"keydown",function(t){y||e.runHooks("afterDocumentKeyDown",t)}),e.view.wt.update("onCellDblClick",t),e.addHook("afterDestroy",function(){y=!0})}()}t.__esModule=!0;var r=o(11),i=o(16),s=o(7),l=o(14),a=o(4),u=function(e){return e&&e.__esModule?e:{default:e}}(a),c=o(36);t.default=n},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var s=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),l=o(36),a=function(e){return e&&e.__esModule?e:{default:e}}(l),u=o(0);t.default=function(e){function t(){return n(this,t),r(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return i(t,e),s(t,[{key:"beginEditing",value:function(e,t){if(void 0===t){var o=this.TD.querySelector('input[type="checkbox"]');(0,u.hasClass)(o,"htBadValue")||o.click()}}},{key:"finishEditing",value:function(){}},{key:"init",value:function(){}},{key:"open",value:function(){}},{key:"close",value:function(){}},{key:"getValue",value:function(){}},{key:"setValue",value:function(){}},{key:"focus",value:function(){}}]),t}(a.default)},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var l=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),a=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},u=o(61),c=n(u),h=o(304),d=n(h);o(183);var f=o(0),p=o(1),g=o(4),v=n(g),m=o(16),y=o(7),w=o(43),C=n(w);t.default=function(e){function t(e){r(this,t);var o=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.defaultDateFormat="DD/MM/YYYY",o.isCellEdited=!1,o.parentDestroyed=!1,o}return s(t,e),l(t,[{key:"init",value:function(){var e=this;if("function"!=typeof c.default)throw Error("You need to include moment.js to your project.");if("function"!=typeof d.default)throw Error("You need to include Pikaday to your project.");a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"init",this).call(this),this.instance.addHook("afterDestroy",function(){e.parentDestroyed=!0,e.destroyElements()})}},{key:"createElements",value:function(){a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"createElements",this).call(this),this.datePicker=document.createElement("DIV"),this.datePickerStyle=this.datePicker.style,this.datePickerStyle.position="absolute",this.datePickerStyle.top=0,this.datePickerStyle.left=0,this.datePickerStyle.zIndex=9999,(0,f.addClass)(this.datePicker,"htDatepickerHolder"),document.body.appendChild(this.datePicker),this.$datePicker=new d.default(this.getDatePickerConfig()),new v.default(this).addEventListener(this.datePicker,"mousedown",function(e){return(0,y.stopPropagation)(e)}),this.hideDatepicker()}},{key:"destroyElements",value:function(){this.$datePicker.destroy()}},{key:"prepare",value:function(e,o,n,r,i,s){this._opened=!1,a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"prepare",this).call(this,e,o,n,r,i,s)}},{key:"open",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"open",this).call(this),this.showDatepicker(e)}},{key:"close",value:function(){var e=this;this._opened=!1,this.instance._registerTimeout(setTimeout(function(){e.instance.selection.refreshBorders()},0)),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"close",this).call(this)}},{key:"finishEditing",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],o=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(e){var n=this.originalValue;void 0!==n&&this.setValue(n)}this.hideDatepicker(),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"finishEditing",this).call(this,e,o)}},{key:"showDatepicker",value:function(e){this.$datePicker.config(this.getDatePickerConfig());var t=this.TD.getBoundingClientRect(),o=this.cellProperties.dateFormat||this.defaultDateFormat,n=this.$datePicker.config(),r=void 0,i=this.instance.view.isMouseDown(),s=!!e&&(0,m.isMetaKey)(e.keyCode);this.datePickerStyle.top=window.pageYOffset+t.top+(0,f.outerHeight)(this.TD)+"px",this.datePickerStyle.left=window.pageXOffset+t.left+"px",this.$datePicker._onInputFocus=function(){},n.format=o,this.originalValue?(r=this.originalValue,(0,c.default)(r,o,!0).isValid()&&this.$datePicker.setMoment((0,c.default)(r,o),!0),this.getValue()!==this.originalValue&&this.setValue(this.originalValue),s||i||this.setValue("")):this.cellProperties.defaultDate?(r=this.cellProperties.defaultDate,n.defaultDate=r,(0,c.default)(r,o,!0).isValid()&&this.$datePicker.setMoment((0,c.default)(r,o),!0),s||i||this.setValue("")):this.$datePicker.gotoToday(),this.datePickerStyle.display="block",this.$datePicker.show()}},{key:"hideDatepicker",value:function(){this.datePickerStyle.display="none",this.$datePicker.hide()}},{key:"getDatePickerConfig",value:function(){var e=this,t=this.TEXTAREA,o={};this.cellProperties&&this.cellProperties.datePickerConfig&&(0,p.deepExtend)(o,this.cellProperties.datePickerConfig);var n=o.onSelect,r=o.onClose;return o.field=t,o.trigger=t,o.container=this.datePicker,o.bound=!1,o.format=o.format||this.defaultDateFormat,o.reposition=o.reposition||!1,o.onSelect=function(t){isNaN(t.getTime())||(t=(0,c.default)(t).format(e.cellProperties.dateFormat||e.defaultDateFormat)),e.setValue(t),e.hideDatepicker(),n&&n()},o.onClose=function(){e.parentDestroyed||e.finishEditing(!1),r&&r()},o}}]),t}(C.default)},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var l=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),a=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},u=o(149),c=n(u),h=o(8),d=n(h),f=function(e){function t(){return r(this,t),i(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return s(t,e),l(t,[{key:"prepare",value:function(e,o,n,r,i,s){a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"prepare",this).call(this,e,o,n,r,i,s),this.cellProperties.filter=!1,this.cellProperties.strict=!0}}]),t}(c.default);d.default.getSingleton().add("beforeValidate",function(e,t,o,n){var r=this.getCellMeta(t,this.propToCol(o));r.editor===f&&void 0===r.strict&&(r.filter=!1,r.strict=!0)}),t.default=f},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}t.__esModule=!0;var r=o(16),i=o(7),s=o(0),l=o(36),a=n(l),u=o(4),c=n(u),h=a.default.prototype.extend(),d={},f=function(){this.controls={},this.controls.leftButton=document.createElement("DIV"),this.controls.leftButton.className="leftButton",this.controls.rightButton=document.createElement("DIV"),this.controls.rightButton.className="rightButton",this.controls.upButton=document.createElement("DIV"),this.controls.upButton.className="upButton",this.controls.downButton=document.createElement("DIV"),this.controls.downButton.className="downButton";for(var e in this.controls)Object.prototype.hasOwnProperty.call(this.controls,e)&&this.positionControls.appendChild(this.controls[e])};h.prototype.valueChanged=function(){return this.initValue!=this.getValue()},h.prototype.init=function(){var e=this;this.eventManager=new c.default(this.instance),this.createElements(),this.bindEvents(),this.instance.addHook("afterDestroy",function(){e.destroy()})},h.prototype.getValue=function(){return this.TEXTAREA.value},h.prototype.setValue=function(e){this.initValue=e,this.TEXTAREA.value=e},h.prototype.createElements=function(){this.editorContainer=document.createElement("DIV"),this.editorContainer.className="htMobileEditorContainer",this.cellPointer=document.createElement("DIV"),this.cellPointer.className="cellPointer",this.moveHandle=document.createElement("DIV"),this.moveHandle.className="moveHandle",this.inputPane=document.createElement("DIV"),this.inputPane.className="inputs",this.positionControls=document.createElement("DIV"),this.positionControls.className="positionControls",this.TEXTAREA=document.createElement("TEXTAREA"),(0,s.addClass)(this.TEXTAREA,"handsontableInput"),this.inputPane.appendChild(this.TEXTAREA),this.editorContainer.appendChild(this.cellPointer),this.editorContainer.appendChild(this.moveHandle),this.editorContainer.appendChild(this.inputPane),this.editorContainer.appendChild(this.positionControls),f.call(this),document.body.appendChild(this.editorContainer)},h.prototype.onBeforeKeyDown=function(e){var t=this,o=t.getActiveEditor();if(e.target===o.TEXTAREA&&!(0,i.isImmediatePropagationStopped)(e))switch(e.keyCode){case r.KEY_CODES.ENTER:o.close(),e.preventDefault();break;case r.KEY_CODES.BACKSPACE:(0,i.stopImmediatePropagation)(e)}},h.prototype.open=function(){this.instance.addHook("beforeKeyDown",this.onBeforeKeyDown),(0,s.addClass)(this.editorContainer,"active"),(0,s.removeClass)(this.cellPointer,"hidden"),this.updateEditorPosition()},h.prototype.focus=function(){this.TEXTAREA.focus(),(0,s.setCaretPosition)(this.TEXTAREA,this.TEXTAREA.value.length)},h.prototype.close=function(){this.TEXTAREA.blur(),this.instance.removeHook("beforeKeyDown",this.onBeforeKeyDown),(0,s.removeClass)(this.editorContainer,"active")},h.prototype.scrollToView=function(){this.instance.view.scrollViewport(this.instance.getSelectedRange().highlight)},h.prototype.hideCellPointer=function(){(0,s.hasClass)(this.cellPointer,"hidden")||(0,s.addClass)(this.cellPointer,"hidden")},h.prototype.updateEditorPosition=function(e,t){if(e&&t)e=parseInt(e,10),t=parseInt(t,10),this.editorContainer.style.top=t+"px",this.editorContainer.style.left=e+"px";else{var o=this.instance.getSelected(),n=this.instance.getCell(o[0],o[1]);if(d.cellPointer||(d.cellPointer={height:(0,s.outerHeight)(this.cellPointer),width:(0,s.outerWidth)(this.cellPointer)}),d.editorContainer||(d.editorContainer={width:(0,s.outerWidth)(this.editorContainer)}),void 0!==n){var r=this.instance.view.wt.wtOverlays.leftOverlay.trimmingContainer==window?0:(0,s.getScrollLeft)(this.instance.view.wt.wtOverlays.leftOverlay.holder),i=this.instance.view.wt.wtOverlays.topOverlay.trimmingContainer==window?0:(0,s.getScrollTop)(this.instance.view.wt.wtOverlays.topOverlay.holder),l=(0,s.offset)(n),a=(0,s.outerWidth)(n),u={x:r,y:i};this.editorContainer.style.top=parseInt(l.top+(0,s.outerHeight)(n)-u.y+d.cellPointer.height,10)+"px",this.editorContainer.style.left=parseInt(window.innerWidth/2-d.editorContainer.width/2,10)+"px",l.left+a/2>parseInt(this.editorContainer.style.left,10)+d.editorContainer.width?this.editorContainer.style.left=window.innerWidth-d.editorContainer.width+"px":l.left+a/2<parseInt(this.editorContainer.style.left,10)+20&&(this.editorContainer.style.left="0px"),this.cellPointer.style.left=parseInt(l.left-d.cellPointer.width/2-(0,s.offset)(this.editorContainer).left+a/2-u.x,10)+"px"}}},h.prototype.updateEditorData=function(){var e=this.instance.getSelected(),t=this.instance.getDataAtCell(e[0],e[1]);this.row=e[0],this.col=e[1],this.setValue(t),this.updateEditorPosition()},h.prototype.prepareAndSave=function(){var e;this.valueChanged()&&(e=this.instance.getSettings().trimWhitespace?[[String.prototype.trim.call(this.getValue())]]:[[this.getValue()]],this.saveValue(e))},h.prototype.bindEvents=function(){var e=this;this.eventManager.addEventListener(this.controls.leftButton,"touchend",function(t){e.prepareAndSave(),e.instance.selection.transformStart(0,-1,null,!0),e.updateEditorData(),t.preventDefault()}),this.eventManager.addEventListener(this.controls.rightButton,"touchend",function(t){e.prepareAndSave(),e.instance.selection.transformStart(0,1,null,!0),e.updateEditorData(),t.preventDefault()}),this.eventManager.addEventListener(this.controls.upButton,"touchend",function(t){e.prepareAndSave(),e.instance.selection.transformStart(-1,0,null,!0),e.updateEditorData(),t.preventDefault()}),this.eventManager.addEventListener(this.controls.downButton,"touchend",function(t){e.prepareAndSave(),e.instance.selection.transformStart(1,0,null,!0),e.updateEditorData(),t.preventDefault()}),this.eventManager.addEventListener(this.moveHandle,"touchstart",function(t){if(1==t.touches.length){var o=t.touches[0],n={x:e.editorContainer.offsetLeft,y:e.editorContainer.offsetTop},r={x:o.pageX-n.x,y:o.pageY-n.y};e.eventManager.addEventListener(this,"touchmove",function(t){var o=t.touches[0];e.updateEditorPosition(o.pageX-r.x,o.pageY-r.y),e.hideCellPointer(),t.preventDefault()})}}),this.eventManager.addEventListener(document.body,"touchend",function(t){(0,s.isChildOf)(t.target,e.editorContainer)||(0,s.isChildOf)(t.target,e.instance.rootElement)||e.close()}),this.eventManager.addEventListener(this.instance.view.wt.wtOverlays.leftOverlay.holder,"scroll",function(t){e.instance.view.wt.wtOverlays.leftOverlay.trimmingContainer!=window&&e.hideCellPointer()}),this.eventManager.addEventListener(this.instance.view.wt.wtOverlays.topOverlay.holder,"scroll",function(t){e.instance.view.wt.wtOverlays.topOverlay.trimmingContainer!=window&&e.hideCellPointer()})},h.prototype.destroy=function(){this.eventManager.clear(),this.editorContainer.parentNode.removeChild(this.editorContainer)},t.default=h},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var l=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),a=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},u=o(87),c=n(u),h=o(43),d=n(h);t.default=function(e){function t(){return r(this,t),i(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return s(t,e),l(t,[{key:"beginEditing",value:function(e){if(void 0===e&&this.originalValue){void 0!==this.cellProperties.language&&c.default.culture(this.cellProperties.language);e=(""+this.originalValue).replace(".",c.default.cultureData().delimiters.decimal)}a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"beginEditing",this).call(this,e)}}]),t}(d.default)},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var s=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),l=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},a=o(0),u=o(43),c=function(e){return e&&e.__esModule?e:{default:e}}(u);t.default=function(e){function t(){return n(this,t),r(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return i(t,e),s(t,[{key:"createElements",value:function(){l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"createElements",this).call(this),this.TEXTAREA=document.createElement("input"),this.TEXTAREA.setAttribute("type","password"),this.TEXTAREA.className="handsontableInput",this.textareaStyle=this.TEXTAREA.style,this.textareaStyle.width=0,this.textareaStyle.height=0,(0,a.empty)(this.TEXTAREA_PARENT),this.TEXTAREA_PARENT.appendChild(this.TEXTAREA)}}]),t}(c.default)},function(e,t,o){"use strict";t.__esModule=!0;var n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r=o(0),i=o(7),s=o(16),l=o(36),a=function(e){return e&&e.__esModule?e:{default:e}}(l),u=a.default.prototype.extend();u.prototype.init=function(){this.select=document.createElement("SELECT"),(0,r.addClass)(this.select,"htSelectEditor"),this.select.style.display="none",this.instance.rootElement.appendChild(this.select),this.registerHooks()},u.prototype.registerHooks=function(){var e=this;this.instance.addHook("afterScrollHorizontally",function(){return e.refreshDimensions()}),this.instance.addHook("afterScrollVertically",function(){return e.refreshDimensions()}),this.instance.addHook("afterColumnResize",function(){return e.refreshDimensions()}),this.instance.addHook("afterRowResize",function(){return e.refreshDimensions()})},u.prototype.prepare=function(){a.default.prototype.prepare.apply(this,arguments);var e,t=this.cellProperties.selectOptions;e=this.prepareOptions("function"==typeof t?t(this.row,this.col,this.prop):t),(0,r.empty)(this.select);for(var o in e)if(Object.prototype.hasOwnProperty.call(e,o)){var n=document.createElement("OPTION");n.value=o,(0,r.fastInnerHTML)(n,e[o]),this.select.appendChild(n)}},u.prototype.prepareOptions=function(e){var t={};if(Array.isArray(e))for(var o=0,r=e.length;r>o;o++)t[e[o]]=e[o];else"object"==(void 0===e?"undefined":n(e))&&(t=e);return t},u.prototype.getValue=function(){return this.select.value},u.prototype.setValue=function(e){this.select.value=e};var c=function(e){var t=this,o=t.getActiveEditor();switch(e.keyCode){case s.KEY_CODES.ARROW_UP:var n=o.select.selectedIndex-1;0>n||(o.select[n].selected=!0),(0,i.stopImmediatePropagation)(e),e.preventDefault();break;case s.KEY_CODES.ARROW_DOWN:var r=o.select.selectedIndex+1;r>o.select.length-1||(o.select[r].selected=!0),(0,i.stopImmediatePropagation)(e),e.preventDefault()}};u.prototype.open=function(){this._opened=!0,this.refreshDimensions(),this.select.style.display="",this.instance.addHook("beforeKeyDown",c)},u.prototype.close=function(){this._opened=!1,this.select.style.display="none",this.instance.removeHook("beforeKeyDown",c)},u.prototype.focus=function(){this.select.focus()},u.prototype.refreshValue=function(){var e=this.instance.getSourceDataAtCell(this.row,this.prop);this.originalValue=e,this.setValue(e),this.refreshDimensions()},u.prototype.refreshDimensions=function(){if(this.state===l.EditorState.EDITING){if(!(this.TD=this.getEditedCell()))return void this.close();var e,t=(0,r.outerWidth)(this.TD)+1,o=(0,r.outerHeight)(this.TD)+1,n=(0,r.offset)(this.TD),i=(0,r.offset)(this.instance.rootElement),s=(0,r.getScrollableElement)(this.TD),a=n.top-i.top-1-(s.scrollTop||0),u=n.left-i.left-1-(s.scrollLeft||0),c=this.checkEditorSection();this.instance.getSettings();switch(c){case"top":e=(0,r.getCssTransform)(this.instance.view.wt.wtOverlays.topOverlay.clone.wtTable.holder.parentNode);break;case"left":e=(0,r.getCssTransform)(this.instance.view.wt.wtOverlays.leftOverlay.clone.wtTable.holder.parentNode);break;case"top-left-corner":e=(0,r.getCssTransform)(this.instance.view.wt.wtOverlays.topLeftCornerOverlay.clone.wtTable.holder.parentNode);break;case"bottom-left-corner":e=(0,r.getCssTransform)(this.instance.view.wt.wtOverlays.bottomLeftCornerOverlay.clone.wtTable.holder.parentNode);break;case"bottom":e=(0,r.getCssTransform)(this.instance.view.wt.wtOverlays.bottomOverlay.clone.wtTable.holder.parentNode)}0===this.instance.getSelected()[0]&&(a+=1),0===this.instance.getSelected()[1]&&(u+=1);var h=this.select.style;e&&-1!=e?h[e[0]]=e[1]:(0,r.resetCssTransform)(this.select);var d=(0,r.getComputedStyle)(this.TD);parseInt(d.borderTopWidth,10)>0&&(o-=1),parseInt(d.borderLeftWidth,10)>0&&(t-=1),h.height=o+"px",h.minWidth=t+"px",h.top=a+"px",h.left=u+"px",h.margin="0px"}},u.prototype.getEditedCell=function(){var e,t=this.checkEditorSection();switch(t){case"top":e=this.instance.view.wt.wtOverlays.topOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.select.style.zIndex=101;break;case"corner":e=this.instance.view.wt.wtOverlays.topLeftCornerOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.select.style.zIndex=103;break;case"left":e=this.instance.view.wt.wtOverlays.leftOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.select.style.zIndex=102;break;default:e=this.instance.getCell(this.row,this.col),this.select.style.zIndex=""}return-1!=e&&-2!=e?e:void 0},t.default=u},function(e,t,o){"use strict";function n(e){for(var t=arguments.length,o=Array(t>1?t-1:0),n=1;t>n;n++)o[n-1]=arguments[n];return(0,r.arrayReduce)(e,function(e,t,n){return e+t.replace(/(?:\r?\n\s+)/g,"")+(o[n]?o[n]:"")},"").trim()}t.__esModule=!0,t.toSingleLine=n;var r=o(2)},function(e,t,o){"use strict";function n(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t.default=e,t}function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){var o=new h.default(e,t||{},Z.rootInstanceSymbol);return o.init(),o}o(98),o(115),o(124),o(125),o(109),o(123),o(106),o(107),o(108),o(97),o(120),o(118),o(116),o(121),o(122),o(117),o(119),o(110),o(111),o(112),o(114),o(113),o(95),o(96),o(91),o(94),o(93),o(92),o(67),o(100),o(101),o(103),o(102),o(99),o(105),o(104),o(126),o(129),o(127),o(128),o(131),o(130),o(133),o(132),o(180),o(181),o(182);var s=o(14),l=o(9),a=o(26),u=o(62),c=o(63),h=r(c),d=o(178),f=r(d),p=o(4),g=r(p),v=o(8),m=r(v),y=o(66),w=r(y),C=o(2),b=n(C),S=o(25),E=n(S),R=o(64),O=n(R),k=o(89),T=n(k),_=o(34),M=n(_),H=o(35),A=n(H),P=o(20),x=n(P),D=o(6),L=n(D),N=o(1),I=n(N),j=o(65),W=n(j),B=o(27),F=n(B),V=o(16),z=n(V),U=o(0),K=n(U),Y=o(7),G=n(Y),X=o(179),q=n(X),Q=o(5),J=o(88),$=r(J),Z=o(90);(0,f.default)(i),i.Core=h.default,i.DefaultSettings=$.default,i.EventManager=g.default,i._getListenersCounter=p.getListenersCounter,i.buildDate="05/09/2017 13:02:49",i.packageName="handsontable",i.version="0.34.1";i.hooks=m.default.getSingleton(),i.__GhostTable=w.default;var ee=[b,E,O,T,M,A,x,L,I,W,F,z],te=[K,G];i.helper={},i.dom={},b.arrayEach(ee,function(e){b.arrayEach(Object.getOwnPropertyNames(e),function(t){"_"!==t.charAt(0)&&(i.helper[t]=e[t])})}),b.arrayEach(te,function(e){b.arrayEach(Object.getOwnPropertyNames(e),function(t){"_"!==t.charAt(0)&&(i.dom[t]=e[t])})}),i.cellTypes={},b.arrayEach((0,u.getRegisteredCellTypeNames)(),function(e){i.cellTypes[e]=(0,u.getCellType)(e)}),i.cellTypes.registerCellType=u.registerCellType,i.cellTypes.getCellType=u.getCellType,i.editors={},b.arrayEach((0,s.getRegisteredEditorNames)(),function(e){i.editors[F.toUpperCaseFirst(e)+"Editor"]=(0,s.getEditor)(e)}),i.editors.registerEditor=s.registerEditor,i.editors.getEditor=s.getEditor,i.renderers={},b.arrayEach((0,l.getRegisteredRendererNames)(),function(e){var t=(0,l.getRenderer)(e);"base"===e&&(i.renderers.cellDecorator=t),i.renderers[F.toUpperCaseFirst(e)+"Renderer"]=t}),i.renderers.registerRenderer=l.registerRenderer,i.renderers.getRenderer=l.getRenderer,i.validators={},b.arrayEach((0,a.getRegisteredValidatorNames)(),function(e){i.validators[F.toUpperCaseFirst(e)+"Validator"]=(0,a.getValidator)(e)}),i.validators.registerValidator=a.registerValidator,i.validators.getValidator=a.getValidator,i.plugins={},b.arrayEach(Object.getOwnPropertyNames(q),function(e){var t=q[e];"Base"===e?i.plugins[e+"Plugin"]=t:i.plugins[e]=t}),i.plugins.registerPlugin=Q.registerPlugin,e.exports=i},function(e,t,o){"use strict";function n(){function e(e){return null!==e&&!o(e)&&("string"==typeof e||"number"==typeof e)}function t(e){return null!==e&&("object"==(void 0===e?"undefined":r(e))||"function"==typeof e)}function o(e){return e!==e}var n={arrayMap:[],weakMap:new WeakMap};return{get:function(o){return e(o)?n.arrayMap[o]:t(o)?n.weakMap.get(o):void 0},set:function(o,r){if(e(o))n.arrayMap[o]=r;else{if(!t(o))throw Error("Invalid key type");n.weakMap.set(o,r)}},delete:function(o){e(o)?delete n.arrayMap[o]:t(o)&&n.weakMap.delete(o)}}}t.__esModule=!0;var r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.default=n},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var l=function(){function e(e,t){var o=[],n=!0,r=!1,i=void 0;try{for(var s,l=e[Symbol.iterator]();!(n=(s=l.next()).done)&&(o.push(s.value),!t||o.length!==t);n=!0);}catch(e){r=!0,i=e}finally{try{!n&&l.return&&l.return()}finally{if(r)throw i}}return o}return function(t,o){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,o);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),a=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},u=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),c=o(12),h=n(c),d=o(2),f=o(34),p=o(0),g=o(66),v=n(g),m=o(1),y=o(6),w=o(5),C=o(155),b=n(C),S=o(27),E=o(11),R=new WeakMap,O=function(e){function t(e){r(this,t);var o=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return R.set(o,{cachedColumnHeaders:[]}),o.widths=[],o.ghostTable=new v.default(o.hot),o.samplesGenerator=new b.default(function(e,t){return o.hot.getDataAtCell(e,t)}),o.firstCalculation=!0,o.inProgress=!1,o.addHook("beforeColumnResize",function(e,t,n){return o.onBeforeColumnResize(e,t,n)}),o}return s(t,e),u(t,null,[{key:"CALCULATION_STEP",get:function(){return 50}},{key:"SYNC_CALCULATION_LIMIT",get:function(){return 50}}]),u(t,[{key:"isEnabled",value:function(){return!1!==this.hot.getSettings().autoColumnSize&&!this.hot.getSettings().colWidths}},{key:"enablePlugin",value:function(){var e=this;if(!this.enabled){var o=this.hot.getSettings().autoColumnSize;o&&null!=o.useHeaders&&this.ghostTable.setSetting("useHeaders",o.useHeaders),this.addHook("afterLoadData",function(){return e.onAfterLoadData()}),this.addHook("beforeChange",function(t){return e.onBeforeChange(t)}),this.addHook("beforeRender",function(t){return e.onBeforeRender(t)}),this.addHook("modifyColWidth",function(t,o){return e.getColumnWidth(o,t)}),this.addHook("afterInit",function(){return e.onAfterInit()}),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this)}}},{key:"updatePlugin",value:function(){var e=this.findColumnsWhereHeaderWasChanged();e.length&&this.clearCache(e),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"updatePlugin",this).call(this)}},{key:"disablePlugin",value:function(){a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"calculateColumnsWidth",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{from:0,to:this.hot.countCols()-1},t=this,o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{from:0,to:this.hot.countRows()-1},n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];"number"==typeof e&&(e={from:e,to:e}),"number"==typeof o&&(o={from:o,to:o}),(0,y.rangeEach)(e.from,e.to,function(e){if(n||void 0===t.widths[e]&&!t.hot._getColWidthFromSettings(e)){t.samplesGenerator.generateColumnSamples(e,o).forEach(function(e,o){return t.ghostTable.addColumn(o,e)})}}),this.ghostTable.columns.length&&(this.ghostTable.getWidths(function(e,o){t.widths[e]=o}),this.ghostTable.clean())}},{key:"calculateAllColumnsWidth",value:function(){var e=this,o=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{from:0,to:this.hot.countRows()-1},n=0,r=this.hot.countCols()-1,i=null;this.inProgress=!0;this.firstCalculation&&this.getSyncCalculationLimit()&&(this.calculateColumnsWidth({from:0,to:this.getSyncCalculationLimit()},o),this.firstCalculation=!1,n=this.getSyncCalculationLimit()+1),r>n?function s(){if(!e.hot)return(0,f.cancelAnimationFrame)(i),void(e.inProgress=!1);e.calculateColumnsWidth({from:n,to:Math.min(n+t.CALCULATION_STEP,r)},o),n=n+t.CALCULATION_STEP+1,r>n?i=(0,f.requestAnimationFrame)(s):((0,f.cancelAnimationFrame)(i),e.inProgress=!1,e.hot.view.wt.wtOverlays.adjustElementsSize(!0),e.hot.view.wt.wtOverlays.leftOverlay.needFullRender&&e.hot.view.wt.wtOverlays.leftOverlay.clone.draw())}():this.inProgress=!1}},{key:"setSamplingOptions",value:function(){var e=this.hot.getSettings().autoColumnSize,t=e&&(0,m.hasOwnProperty)(e,"samplingRatio")?this.hot.getSettings().autoColumnSize.samplingRatio:void 0,o=e&&(0,m.hasOwnProperty)(e,"allowSampleDuplicates")?this.hot.getSettings().autoColumnSize.allowSampleDuplicates:void 0;t&&!isNaN(t)&&this.samplesGenerator.setSampleCount(parseInt(t,10)),o&&this.samplesGenerator.setAllowDuplicates(o)}},{key:"recalculateAllColumnsWidth",value:function(){this.hot.view&&(0,p.isVisible)(this.hot.view.wt.wtTable.TABLE)&&(this.clearCache(),this.calculateAllColumnsWidth())}},{key:"getSyncCalculationLimit",value:function(){var e=t.SYNC_CALCULATION_LIMIT,o=this.hot.countCols()-1;return(0,m.isObject)(this.hot.getSettings().autoColumnSize)&&(e=this.hot.getSettings().autoColumnSize.syncLimit,(0,S.isPercentValue)(e)?e=(0,y.valueAccordingPercent)(o,e):e>>=0),Math.min(e,o)}},{key:"getColumnWidth",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:void 0,o=2>=arguments.length||void 0===arguments[2]||arguments[2],n=t;return void 0===n&&(n=this.widths[e],o&&"number"==typeof n&&(n=Math.max(n,E.ViewportColumnsCalculator.DEFAULT_WIDTH))),n}},{key:"getFirstVisibleColumn",value:function(){var e=this.hot.view.wt;return e.wtViewport.columnsVisibleCalculator?e.wtTable.getFirstVisibleColumn():e.wtViewport.columnsRenderCalculator?e.wtTable.getFirstRenderedColumn():-1}},{key:"getLastVisibleColumn",value:function(){var e=this.hot.view.wt;return e.wtViewport.columnsVisibleCalculator?e.wtTable.getLastVisibleColumn():e.wtViewport.columnsRenderCalculator?e.wtTable.getLastRenderedColumn():-1}},{key:"findColumnsWhereHeaderWasChanged",value:function(){var e=this.hot.getColHeader(),t=R.get(this),o=t.cachedColumnHeaders;return(0,d.arrayReduce)(e,function(e,t,n){var r=o.length;return(n>r-1||o[n]!==t)&&e.push(n),n>r-1?o.push(t):o[n]=t,e},[])}},{key:"clearCache",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];t.length?(0,d.arrayEach)(t,function(t){e.widths[t]=void 0}):this.widths.length=0}},{key:"isNeedRecalculate",value:function(){return!!(0,d.arrayFilter)(this.widths,function(e){return void 0===e}).length}},{key:"onBeforeRender",value:function(){var e=this.hot.renderCall;this.hot.countRows()&&(this.calculateColumnsWidth({from:this.getFirstVisibleColumn(),to:this.getLastVisibleColumn()},void 0,e),this.isNeedRecalculate()&&!this.inProgress&&this.calculateAllColumnsWidth())}},{key:"onAfterLoadData",value:function(){var e=this;this.hot.view?this.recalculateAllColumnsWidth():setTimeout(function(){e.hot&&e.recalculateAllColumnsWidth()},0)}},{key:"onBeforeChange",value:function(e){var t=this;this.clearCache((0,d.arrayMap)(e,function(e){var o=l(e,2);return t.hot.propToCol(o[1])}))}},{key:"onBeforeColumnResize",value:function(e,t,o){return o&&(this.calculateColumnsWidth(e,void 0,!0),t=this.getColumnWidth(e,void 0,!1)),t}},{key:"onAfterInit",value:function(){R.get(this).cachedColumnHeaders=this.hot.getColHeader()}},{key:"destroy",value:function(){this.ghostTable.clean(),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}}]),t}(h.default);(0,w.registerPlugin)("autoColumnSize",O),t.default=O},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var l=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},a=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),u=o(12),c=n(u),h=o(2),d=o(34),f=o(0),p=o(66),g=n(p),v=o(1),m=o(6),y=o(5),w=o(155),C=n(w),b=o(27),S=function(e){function t(e){r(this,t);var o=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.heights=[],o.ghostTable=new g.default(o.hot),o.samplesGenerator=new C.default(function(e,t){return 0>e?-1===e?o.hot.getColHeader(t):null:o.hot.getDataAtCell(e,t)}),o.firstCalculation=!0,o.inProgress=!1,o.addHook("beforeRowResize",function(e,t,n){return o.onBeforeRowResize(e,t,n)}),o}return s(t,e),a(t,null,[{key:"CALCULATION_STEP",get:function(){return 50}},{key:"SYNC_CALCULATION_LIMIT",get:function(){return 500}}]),a(t,[{key:"isEnabled",value:function(){return!0===this.hot.getSettings().autoRowSize||(0,v.isObject)(this.hot.getSettings().autoRowSize)}},{key:"enablePlugin",value:function(){var e=this;this.enabled||(this.setSamplingOptions(),this.addHook("afterLoadData",function(){return e.onAfterLoadData()}),this.addHook("beforeChange",function(t){return e.onBeforeChange(t)}),this.addHook("beforeColumnMove",function(){return e.recalculateAllRowsHeight()}),this.addHook("beforeColumnResize",function(){return e.recalculateAllRowsHeight()}),this.addHook("beforeColumnSort",function(){return e.clearCache()}),this.addHook("beforeRender",function(t){return e.onBeforeRender(t)}),this.addHook("beforeRowMove",function(t,o){return e.onBeforeRowMove(t,o)}),this.addHook("modifyRowHeight",function(t,o){return e.getRowHeight(o,t)}),this.addHook("modifyColumnHeaderHeight",function(){return e.getColumnHeaderHeight()}),l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{key:"disablePlugin",value:function(){l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"calculateRowsHeight",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{from:0,to:this.hot.countRows()-1},t=this,o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{from:0,to:this.hot.countCols()-1},n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if("number"==typeof e&&(e={from:e,to:e}),"number"==typeof o&&(o={from:o,to:o}),null!==this.hot.getColHeader(0)){this.ghostTable.addColumnHeadersRow(this.samplesGenerator.generateRowSamples(-1,o).get(-1))}(0,m.rangeEach)(e.from,e.to,function(e){if(n||void 0===t.heights[e]){t.samplesGenerator.generateRowSamples(e,o).forEach(function(e,o){t.ghostTable.addRow(o,e)})}}),this.ghostTable.rows.length&&(this.ghostTable.getHeights(function(e,o){t.heights[e]=o}),this.ghostTable.clean())}},{key:"calculateAllRowsHeight",value:function(){var e=this,o=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{from:0,to:this.hot.countCols()-1},n=0,r=this.hot.countRows()-1,i=null;this.inProgress=!0;this.firstCalculation&&this.getSyncCalculationLimit()&&(this.calculateRowsHeight({from:0,to:this.getSyncCalculationLimit()},o),this.firstCalculation=!1,n=this.getSyncCalculationLimit()+1),r>n?function s(){if(!e.hot)return(0,d.cancelAnimationFrame)(i),void(e.inProgress=!1);e.calculateRowsHeight({from:n,to:Math.min(n+t.CALCULATION_STEP,r)},o),n=n+t.CALCULATION_STEP+1,r>n?i=(0,d.requestAnimationFrame)(s):((0,d.cancelAnimationFrame)(i),e.inProgress=!1,e.hot.view.wt.wtOverlays.adjustElementsSize(!0),e.hot.view.wt.wtOverlays.leftOverlay.needFullRender&&e.hot.view.wt.wtOverlays.leftOverlay.clone.draw())}():(this.inProgress=!1,this.hot.view.wt.wtOverlays.adjustElementsSize(!1))}},{key:"setSamplingOptions",value:function(){var e=this.hot.getSettings().autoRowSize,t=e&&(0,v.hasOwnProperty)(e,"samplingRatio")?this.hot.getSettings().autoRowSize.samplingRatio:void 0,o=e&&(0,v.hasOwnProperty)(e,"allowSampleDuplicates")?this.hot.getSettings().autoRowSize.allowSampleDuplicates:void 0;t&&!isNaN(t)&&this.samplesGenerator.setSampleCount(parseInt(t,10)),o&&this.samplesGenerator.setAllowDuplicates(o)}},{key:"recalculateAllRowsHeight",value:function(){(0,f.isVisible)(this.hot.view.wt.wtTable.TABLE)&&(this.clearCache(),this.calculateAllRowsHeight())}},{key:"getSyncCalculationLimit",value:function(){var e=t.SYNC_CALCULATION_LIMIT,o=this.hot.countRows()-1;return(0,v.isObject)(this.hot.getSettings().autoRowSize)&&(e=this.hot.getSettings().autoRowSize.syncLimit,(0,b.isPercentValue)(e)?e=(0,m.valueAccordingPercent)(o,e):e>>=0),Math.min(e,o)}},{key:"getRowHeight",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:void 0,o=t;return void 0!==this.heights[e]&&this.heights[e]>(t||0)&&(o=this.heights[e]),o}},{key:"getColumnHeaderHeight",value:function(){return this.heights[-1]}},{key:"getFirstVisibleRow",value:function(){var e=this.hot.view.wt;return e.wtViewport.rowsVisibleCalculator?e.wtTable.getFirstVisibleRow():e.wtViewport.rowsRenderCalculator?e.wtTable.getFirstRenderedRow():-1}},{key:"getLastVisibleRow",value:function(){var e=this.hot.view.wt;return e.wtViewport.rowsVisibleCalculator?e.wtTable.getLastVisibleRow():e.wtViewport.rowsRenderCalculator?e.wtTable.getLastRenderedRow():-1}},{key:"clearCache",value:function(){this.heights.length=0,this.heights[-1]=void 0}},{key:"clearCacheByRange",value:function(e){var t=this;"number"==typeof e&&(e={from:e,to:e}),(0,m.rangeEach)(Math.min(e.from,e.to),Math.max(e.from,e.to),function(e){t.heights[e]=void 0})}},{key:"isNeedRecalculate",value:function(){return!!(0,h.arrayFilter)(this.heights,function(e){return void 0===e}).length}},{key:"onBeforeRender",value:function(){var e=this.hot.renderCall;this.calculateRowsHeight({from:this.getFirstVisibleRow(),to:this.getLastVisibleRow()},void 0,e);var t=this.hot.getSettings().fixedRowsBottom;if(t){var o=this.hot.countRows()-1;this.calculateRowsHeight({from:o-t,to:o})}this.isNeedRecalculate()&&!this.inProgress&&this.calculateAllRowsHeight()}},{key:"onBeforeRowMove",value:function(e,t){this.clearCacheByRange({from:e,to:t}),this.calculateAllRowsHeight()}},{key:"onBeforeRowResize",value:function(e,t,o){return o&&(this.calculateRowsHeight(e,void 0,!0),t=this.getRowHeight(e)),t}},{key:"onAfterLoadData",value:function(){var e=this;this.hot.view?this.recalculateAllRowsHeight():setTimeout(function(){e.hot&&e.recalculateAllRowsHeight()},0)}},{key:"onBeforeChange",value:function(e){var t=null;1===e.length?t=e[0][0]:e.length>1&&(t={from:e[0][0],to:e[e.length-1][0]}),null!==t&&this.clearCacheByRange(t)}},{key:"destroy",value:function(){this.ghostTable.clean(),l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}}]),t}(c.default);(0,y.registerPlugin)("autoRowSize",S),t.default=S},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var l=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),a=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},u=o(12),c=n(u),h=o(8),d=n(h),f=o(0),p=o(4),g=n(p),v=o(5),m=o(11),y=o(215);d.default.getSingleton().register("modifyAutofillRange"),d.default.getSingleton().register("beforeAutofill");var w=function(e){function t(e){r(this,t);var o=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.eventManager=new g.default(o),o.addingStarted=!1,o.mouseDownOnCellCorner=!1,o.mouseDragOutside=!1,o.handleDraggedCells=0,o.directions=[],o.autoInsertRow=!1,o}return s(t,e),l(t,[{key:"isEnabled",value:function(){return this.hot.getSettings().fillHandle}},{key:"enablePlugin",value:function(){var e=this;this.enabled||(this.mapSettings(),this.registerEvents(),this.addHook("afterOnCellCornerMouseDown",function(t){return e.onAfterCellCornerMouseDown(t)}),this.addHook("afterOnCellCornerDblClick",function(t){return e.onCellCornerDblClick(t)}),this.addHook("beforeOnCellMouseOver",function(t,o,n){return e.onBeforeCellMouseOver(o)}),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{key:"updatePlugin",value:function(){this.disablePlugin(),this.enablePlugin(),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"updatePlugin",this).call(this)}},{key:"disablePlugin",value:function(){this.clearMappedSettings(),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"getSelectionData",value:function(){var e={from:this.hot.getSelectedRange().from,to:this.hot.getSelectedRange().to};return this.hot.getData(e.from.row,e.from.col,e.to.row,e.to.col)}},{key:"fillIn",value:function(){if(this.hot.view.wt.selections.fill.isEmpty())return!1;var e=this.hot.view.wt.selections.fill.getCorners();this.resetSelectionOfDraggedArea();var t=this.getCornersOfSelectedCells(),o=(0,y.getDragDirectionAndRange)(t,e),n=o.directionOfDrag,r=o.startOfDragCoords,i=o.endOfDragCoords;if(this.hot.runHooks("modifyAutofillRange",t,e),r&&r.row>-1&&r.col>-1){var s=this.getSelectionData(),l=(0,y.getDeltas)(r,i,s,n),a=s;if(this.hot.runHooks("beforeAutofill",r,i,s),["up","left"].indexOf(n)>-1){a=[];var u=null,c=null;if("up"===n){u=i.row-r.row+1,c=u%s.length;for(var h=0;u>h;h++)a.push(s[(h+(s.length-c))%s.length])}else{u=i.col-r.col+1,c=u%s[0].length;for(var d=0;s.length>d;d++){a.push([]);for(var f=0;u>f;f++)a[d].push(s[d][(f+(s[d].length-c))%s[d].length])}}}this.hot.populateFromArray(r.row,r.col,a,i.row,i.col,this.pluginName+".fill",null,n,l),this.setSelection(e)}else this.hot.selection.refreshBorders();return!0}},{key:"reduceSelectionAreaIfNeeded",value:function(e){return 0>e.row&&(e.row=0),0>e.col&&(e.col=0),e}},{key:"getCoordsOfDragAndDropBorders",value:function(e){var t=this.hot.getSelectedRange().getTopLeftCorner(),o=this.hot.getSelectedRange().getBottomRightCorner(),n=void 0;if(this.directions.includes(y.DIRECTIONS.vertical)&&(e.row>o.row||t.row>e.row))n=new m.CellCoords(e.row,o.col);else{if(!this.directions.includes(y.DIRECTIONS.horizontal))return;n=new m.CellCoords(o.row,e.col)}return this.reduceSelectionAreaIfNeeded(n)}},{key:"showBorder",value:function(e){var t=this.getCoordsOfDragAndDropBorders(e);t&&this.redrawBorders(t)}},{key:"addRow",value:function(){var e=this;this.hot._registerTimeout(setTimeout(function(){e.hot.alter("insert_row",void 0,1,e.pluginName+".fill"),e.addingStarted=!1},200))}},{key:"addNewRowIfNeeded",value:function(){if(this.hot.view.wt.selections.fill.cellRange&&!1===this.addingStarted&&this.autoInsertRow){var e=this.hot.getSelected(),t=this.hot.view.wt.selections.fill.getCorners(),o=this.hot.countRows();o-1>e[2]&&t[2]===o-1&&(this.addingStarted=!0,this.addRow())}}},{key:"getCornersOfSelectedCells",value:function(){return this.hot.selection.isMultiple()?this.hot.view.wt.selections.area.getCorners():this.hot.view.wt.selections.current.getCorners()}},{key:"getIndexOfLastAdjacentFilledInRow",value:function(e){for(var t=this.hot.getData(),o=this.hot.countRows(),n=void 0,r=e[2]+1;o>r;r++){for(var i=e[1];e[3]>=i;i++){if(t[r][i])return-1}var s=t[r][e[1]-1],l=t[r][e[3]+1];(s||l)&&(n=r)}return n}},{key:"addSelectionFromStartAreaToSpecificRowIndex",value:function(e,t){this.hot.view.wt.selections.fill.clear(),this.hot.view.wt.selections.fill.add(new m.CellCoords(e[0],e[1])),this.hot.view.wt.selections.fill.add(new m.CellCoords(t,e[3]))}},{key:"setSelection",value:function(e){this.hot.selection.setRangeStart(new m.CellCoords(e[0],e[1])),this.hot.selection.setRangeEnd(new m.CellCoords(e[2],e[3]))}},{key:"selectAdjacent",value:function(){var e=this.getCornersOfSelectedCells(),t=this.getIndexOfLastAdjacentFilledInRow(e);return-1!==t&&(this.addSelectionFromStartAreaToSpecificRowIndex(e,t),!0)}},{key:"resetSelectionOfDraggedArea",value:function(){this.handleDraggedCells=0,this.hot.view.wt.selections.fill.clear()}},{key:"redrawBorders",value:function(e){this.hot.view.wt.selections.fill.clear(),this.hot.view.wt.selections.fill.add(this.hot.getSelectedRange().from),this.hot.view.wt.selections.fill.add(this.hot.getSelectedRange().to),this.hot.view.wt.selections.fill.add(e),this.hot.view.render()}},{key:"getIfMouseWasDraggedOutside",value:function(e){var t=(0,f.offset)(this.hot.table).top-(window.pageYOffset||document.documentElement.scrollTop)+(0,f.outerHeight)(this.hot.table),o=(0,f.offset)(this.hot.table).left-(window.pageXOffset||document.documentElement.scrollLeft)+(0,f.outerWidth)(this.hot.table);return e.clientY>t&&o>=e.clientX}},{key:"registerEvents",value:function(){var e=this;this.eventManager.addEventListener(document.documentElement,"mouseup",function(){return e.onMouseUp()}),this.eventManager.addEventListener(document.documentElement,"mousemove",function(t){return e.onMouseMove(t)})}},{key:"onCellCornerDblClick",value:function(){this.selectAdjacent()&&this.fillIn()}},{key:"onAfterCellCornerMouseDown",value:function(){this.handleDraggedCells=1,this.mouseDownOnCellCorner=!0}},{key:"onBeforeCellMouseOver",value:function(e){this.mouseDownOnCellCorner&&!this.hot.view.isMouseDown()&&this.handleDraggedCells&&(this.handleDraggedCells++,this.showBorder(e),this.addNewRowIfNeeded())}},{key:"onMouseUp",value:function(){this.handleDraggedCells&&(this.handleDraggedCells>1&&this.fillIn(),this.handleDraggedCells=0,this.mouseDownOnCellCorner=!1)}},{key:"onMouseMove",value:function(e){var t=this.getIfMouseWasDraggedOutside(e);!1===this.addingStarted&&this.handleDraggedCells>0&&t?(this.mouseDragOutside=!0,this.addingStarted=!0):this.mouseDragOutside=!1,this.mouseDragOutside&&this.autoInsertRow&&this.addRow()}},{key:"clearMappedSettings",value:function(){this.directions.length=0,this.autoInsertRow=!1}},{key:"mapSettings",value:function(){var e=(0,y.getMappedFillHandleSetting)(this.hot.getSettings().fillHandle);this.directions=e.directions,this.autoInsertRow=e.autoInsertRow}},{key:"destroy",value:function(){a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}}]),t}(c.default);(0,v.registerPlugin)("autofill",w),t.default=w},function(e,t,o){"use strict";function n(e,t,o,n){var r=o.length,i=o?o[0].length:0,s=[],l=t.row-e.row,a=t.col-e.col;if(-1!==["down","up"].indexOf(n)){for(var u=[],c=0;a>=c;c++){var h=parseInt(o[0][c],10),d=parseInt(o[r-1][c],10);u.push(("down"===n?d-h:h-d)/(r-1)||0)}s.push(u)}if(-1!==["right","left"].indexOf(n))for(var f=0;l>=f;f++){var p=parseInt(o[f][0],10),g=parseInt(o[f][i-1],10),v=("right"===n?g-p:p-g)/(i-1)||0;s.push([v])}return s}function r(e,t){var o=void 0,n=void 0,r=void 0;return t[0]===e[0]&&e[1]>t[1]?(r="left",o=new a.CellCoords(t[0],t[1]),n=new a.CellCoords(t[2],e[1]-1)):t[0]===e[0]&&t[3]>e[3]?(r="right",o=new a.CellCoords(t[0],e[3]+1),n=new a.CellCoords(t[2],t[3])):e[0]>t[0]&&t[1]===e[1]?(r="up",o=new a.CellCoords(t[0],t[1]),n=new a.CellCoords(e[0]-1,t[3])):t[2]>e[2]&&t[1]===e[1]&&(r="down",o=new a.CellCoords(e[2]+1,t[1]),n=new a.CellCoords(t[2],t[3])),{directionOfDrag:r,startOfDragCoords:o,endOfDragCoords:n}}function i(e){var t={};return!0===e?(t.directions=Object.keys(u),t.autoInsertRow=!0):(0,s.isObject)(e)?(t.autoInsertRow=!!(0,l.isDefined)(e.autoInsertRow)&&(e.direction!==u.horizontal&&e.autoInsertRow),t.directions=(0,l.isDefined)(e.direction)?[e.direction]:Object.keys(u)):"string"==typeof e?(t.directions=[e],t.autoInsertRow=!0):(t.directions=[],t.autoInsertRow=!1),t}t.__esModule=!0,t.DIRECTIONS=void 0,t.getDeltas=n,t.getDragDirectionAndRange=r,t.getMappedFillHandleSetting=i;var s=o(1),l=o(20),a=o(11),u=t.DIRECTIONS={horizontal:"horizontal",vertical:"vertical"}},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e){if(Array.isArray(e)){for(var t=0,o=Array(e.length);e.length>t;t++)o[t]=e[t];return o}return Array.from(e)}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function s(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function l(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},u=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),c=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},h=o(61),d=n(h),f=o(0),p=o(2),g=o(20),v=o(1),m=o(12),y=n(m),w=o(5),C=o(274),b=n(C),S=o(8),E=n(S);E.default.getSingleton().register("beforeColumnSort"),E.default.getSingleton().register("afterColumnSort");var R=function(e){function t(e){i(this,t);var o=s(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.sortIndicators=[],o.lastSortedColumn=null,o.sortEmptyCells=!1,o}return l(t,e),u(t,[{key:"isEnabled",value:function(){return!!this.hot.getSettings().columnSorting}},{key:"enablePlugin",value:function(){var e=this;if(!this.enabled){this.setPluginOptions();var o=this;this.hot.sortIndex=[],this.hot.sort=function(){var e=Array.prototype.slice.call(arguments);return o.sortByColumn.apply(o,r(e))},void 0===this.hot.getSettings().observeChanges&&this.enableObserveChangesPlugin(),this.addHook("afterTrimRow",function(t){return e.sort()}),this.addHook("afterUntrimRow",function(t){return e.sort()}),this.addHook("modifyRow",function(t){return e.translateRow(t)}),this.addHook("unmodifyRow",function(t){return e.untranslateRow(t)}),this.addHook("afterUpdateSettings",function(){return e.onAfterUpdateSettings()}),this.addHook("afterGetColHeader",function(t,o){return e.getColHeader(t,o)}),this.addHook("afterOnCellMouseDown",function(t,o){return e.onAfterOnCellMouseDown(t,o)}),this.addHook("afterCreateRow",function(){o.afterCreateRow.apply(o,arguments)}),this.addHook("afterRemoveRow",function(){o.afterRemoveRow.apply(o,arguments)}),this.addHook("afterInit",function(){return e.sortBySettings()}),this.addHook("afterLoadData",function(){e.hot.sortIndex=[],e.hot.view&&e.sortBySettings()}),this.hot.view&&this.sortBySettings(),c(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this)}}},{key:"disablePlugin",value:function(){this.hot.sort=void 0,c(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"onAfterUpdateSettings",value:function(){this.sortBySettings()}},{key:"sortBySettings",value:function(){var e=this.hot.getSettings().columnSorting,t=this.loadSortingState(),o=void 0,n=void 0;void 0===t?(o=e.column,n=e.sortOrder):(o=t.sortColumn,n=t.sortOrder),"number"==typeof o&&(this.lastSortedColumn=o,this.sortByColumn(o,n))}},{key:"setSortingColumn",value:function(e,t){if(void 0===e)return this.hot.sortColumn=void 0,void(this.hot.sortOrder=void 0);this.hot.sortOrder=this.hot.sortColumn===e&&void 0===t?!1===this.hot.sortOrder?void 0:!this.hot.sortOrder:void 0===t||t,this.hot.sortColumn=e}},{key:"sortByColumn",value:function(e,t){if(this.setSortingColumn(e,t),void 0!==this.hot.sortColumn){!1!==this.hot.runHooks("beforeColumnSort",this.hot.sortColumn,this.hot.sortOrder)&&this.sort(),this.updateOrderClass(),this.updateSortIndicator(),this.hot.runHooks("afterColumnSort",this.hot.sortColumn,this.hot.sortOrder),this.hot.render(),this.saveSortingState()}}},{key:"saveSortingState",value:function(){var e={};void 0!==this.hot.sortColumn&&(e.sortColumn=this.hot.sortColumn),void 0!==this.hot.sortOrder&&(e.sortOrder=this.hot.sortOrder),((0,v.hasOwnProperty)(e,"sortColumn")||(0,v.hasOwnProperty)(e,"sortOrder"))&&this.hot.runHooks("persistentStateSave","columnSorting",e)}},{key:"loadSortingState",value:function(){var e={};return this.hot.runHooks("persistentStateLoad","columnSorting",e),e.value}},{key:"updateOrderClass",value:function(){var e=void 0;!0===this.hot.sortOrder?e="ascending":!1===this.hot.sortOrder&&(e="descending"),this.sortOrderClass=e}},{key:"enableObserveChangesPlugin",value:function(){var e=this;this.hot._registerTimeout(setTimeout(function(){e.hot.updateSettings({observeChanges:!0})},0))}},{key:"defaultSort",value:function(e,t){return function(o,n){return"string"==typeof o[1]&&(o[1]=o[1].toLowerCase()),"string"==typeof n[1]&&(n[1]=n[1].toLowerCase()),o[1]===n[1]?0:(0,g.isEmpty)(o[1])?(0,g.isEmpty)(n[1])?0:t.columnSorting.sortEmptyCells&&e?-1:1:(0,g.isEmpty)(n[1])?(0,g.isEmpty)(o[1])?0:t.columnSorting.sortEmptyCells&&e?1:-1:isNaN(o[1])&&!isNaN(n[1])?e?1:-1:!isNaN(o[1])&&isNaN(n[1])?e?-1:1:(isNaN(o[1])||isNaN(n[1])||(o[1]=parseFloat(o[1]),n[1]=parseFloat(n[1])),n[1]>o[1]?e?-1:1:o[1]>n[1]?e?1:-1:0)}}},{key:"dateSort",value:function(e,t){return function(o,n){if(o[1]===n[1])return 0;if((0,g.isEmpty)(o[1]))return(0,g.isEmpty)(n[1])?0:t.columnSorting.sortEmptyCells&&e?-1:1;if((0,g.isEmpty)(n[1]))return(0,g.isEmpty)(o[1])?0:t.columnSorting.sortEmptyCells&&e?1:-1;var r=(0,d.default)(o[1],t.dateFormat),i=(0,d.default)(n[1],t.dateFormat);return r.isValid()?i.isValid()?i.isAfter(r)?e?-1:1:i.isBefore(r)?e?1:-1:0:-1:1}}},{key:"numericSort",value:function(e,t){return function(o,n){var r=parseFloat(o[1]),i=parseFloat(n[1]);if(r===i||isNaN(r)&&isNaN(i))return 0;if(t.columnSorting.sortEmptyCells){if((0,g.isEmpty)(o[1]))return e?-1:1;if((0,g.isEmpty)(n[1]))return e?1:-1}return isNaN(r)?1:isNaN(i)?-1:i>r?e?-1:1:r>i?e?1:-1:0}}},{key:"sort",value:function(){if(void 0===this.hot.sortOrder)return void(this.hot.sortIndex.length=0);var e=this.hot.getCellMeta(0,this.hot.sortColumn),t=this.hot.countEmptyRows(),o=void 0,n=void 0;this.hot.sortingEnabled=!1,this.hot.sortIndex.length=0,void 0===e.columnSorting.sortEmptyCells&&(e.columnSorting={sortEmptyCells:this.sortEmptyCells}),n=this.hot.getSettings().maxRows===Number.POSITIVE_INFINITY?this.hot.countRows()-this.hot.getSettings().minSpareRows:this.hot.countRows()-t;for(var r=0,i=n;i>r;r++)this.hot.sortIndex.push([r,this.hot.getDataAtCell(r,this.hot.sortColumn)]);if(e.sortFunction)o=e.sortFunction;else switch(e.type){case"date":o=this.dateSort;break;case"numeric":o=this.numericSort;break;default:o=this.defaultSort}(0,b.default)(this.hot.sortIndex,o(this.hot.sortOrder,e));for(var s=this.hot.sortIndex.length;s<this.hot.countRows();s++)this.hot.sortIndex.push([s,this.hot.getDataAtCell(s,this.hot.sortColumn)]);this.hot.sortingEnabled=!0}},{key:"updateSortIndicator",value:function(){if(void 0!==this.hot.sortOrder){this.sortIndicators[this.hot.sortColumn]=this.hot.getCellMeta(0,this.hot.sortColumn).sortIndicator}}},{key:"translateRow",value:function(e){return this.hot.sortingEnabled&&void 0!==this.hot.sortOrder&&this.hot.sortIndex&&this.hot.sortIndex.length&&this.hot.sortIndex[e]?this.hot.sortIndex[e][0]:e}},{key:"untranslateRow",value:function(e){if(this.hot.sortingEnabled&&this.hot.sortIndex&&this.hot.sortIndex.length)for(var t=0;this.hot.sortIndex.length>t;t++)if(this.hot.sortIndex[t][0]==e)return t}},{key:"getColHeader",value:function(e,t){if(0>e||!t.parentNode)return!1;var o=t.querySelector(".colHeader"),n=(t.getAttribute("colspan"),t.parentNode.parentNode.childNodes),r=Array.prototype.indexOf.call(n,t.parentNode);r-=n.length,o&&(this.hot.getSettings().columnSorting&&e>=0&&-1===r&&(0,f.addClass)(o,"columnSorting"),(0,f.removeClass)(o,"descending"),(0,f.removeClass)(o,"ascending"),this.sortIndicators[e]&&e===this.hot.sortColumn&&("ascending"===this.sortOrderClass?(0,f.addClass)(o,"ascending"):"descending"===this.sortOrderClass&&(0,f.addClass)(o,"descending")))}},{key:"isSorted",value:function(){return void 0!==this.hot.sortColumn}},{key:"afterCreateRow",value:function(e,t){if(this.isSorted()){for(var o=0;this.hot.sortIndex.length>o;o++)e>this.hot.sortIndex[o][0]||(this.hot.sortIndex[o][0]+=t);for(var n=0;t>n;n++)this.hot.sortIndex.splice(e+n,0,[e+n,this.hot.getSourceData()[e+n][this.hot.sortColumn+this.hot.colOffset()]]);this.saveSortingState()}}},{key:"afterRemoveRow",value:function(e,t){function o(e){return(0,p.arrayReduce)(n,function(t,o){return e>o&&t++,t},0)}if(this.isSorted()){var n=this.hot.sortIndex.splice(e,t);n=(0,p.arrayMap)(n,function(e){return e[0]}),this.hot.sortIndex=(0,p.arrayMap)(this.hot.sortIndex,function(e,t){var n=o(e[0]);return n&&(e[0]-=n),e}),this.saveSortingState()}}},{key:"setPluginOptions",value:function(){var e=this.hot.getSettings().columnSorting;this.sortEmptyCells="object"===(void 0===e?"undefined":a(e))&&(e.sortEmptyCells||!1)}},{key:"onAfterOnCellMouseDown",value:function(e,t){t.row>-1||(0,f.hasClass)(e.realTarget,"columnSorting")&&(t.col!==this.lastSortedColumn&&(this.hot.sortOrder=!0),this.lastSortedColumn=t.col,this.sortByColumn(t.col))}}]),t}(y.default);(0,w.registerPlugin)("columnSorting",R),t.default=R},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=o(0);t.default=function(){function e(){n(this,e),this.editor=this.createEditor(),this.editorStyle=this.editor.style,this.hidden=!0,this.hide()}return r(e,null,[{key:"CLASS_EDITOR_CONTAINER",get:function(){return"htCommentsContainer"}},{key:"CLASS_EDITOR",get:function(){return"htComments"}},{key:"CLASS_INPUT",get:function(){return"htCommentTextArea"}},{key:"CLASS_CELL",get:function(){return"htCommentCell"}}]),r(e,[{key:"setPosition",value:function(e,t){this.editorStyle.left=e+"px",this.editorStyle.top=t+"px"}},{key:"setSize",value:function(e,t){if(e&&t){var o=this.getInputElement();o.style.width=e+"px",o.style.height=t+"px"}}},{key:"resetSize",value:function(){var e=this.getInputElement();e.style.width="",e.style.height=""}},{key:"setReadOnlyState",value:function(e){this.getInputElement().readOnly=e}},{key:"show",value:function(){this.editorStyle.display="block",this.hidden=!1}},{key:"hide",value:function(){this.editorStyle.display="none",this.hidden=!0}},{key:"isVisible",value:function(){return"block"===this.editorStyle.display}},{key:"setValue",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";e=e||"",this.getInputElement().value=e}},{key:"getValue",value:function(){return this.getInputElement().value}},{key:"isFocused",value:function(){return document.activeElement===this.getInputElement()}},{key:"focus",value:function(){this.getInputElement().focus()}},{key:"createEditor",value:function(){var t=document.querySelector("."+e.CLASS_EDITOR_CONTAINER),o=void 0,n=void 0;return t||(t=document.createElement("div"),(0,i.addClass)(t,e.CLASS_EDITOR_CONTAINER),document.body.appendChild(t)),o=document.createElement("div"),(0,i.addClass)(o,e.CLASS_EDITOR),n=document.createElement("textarea"),(0,i.addClass)(n,e.CLASS_INPUT),o.appendChild(n),t.appendChild(o),o}},{key:"getInputElement",value:function(){return this.editor.querySelector("."+e.CLASS_INPUT)}},{key:"destroy",value:function(){this.editor.parentNode.removeChild(this.editor),this.editor=null,this.editorStyle=null}}]),e}()},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t,o){return t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o,e}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function s(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function l(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var a=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),u=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},c=o(0),h=o(1),d=o(4),f=n(d),p=o(11),g=o(5),v=o(12),m=n(v),y=o(217),w=n(y),C=o(17),b=o(219),S=n(b);o(298);var E=new WeakMap,R=function(e){function t(e){i(this,t);var o=s(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.editor=null,o.displaySwitch=null,o.eventManager=null,o.range={},o.mouseDown=!1,o.contextMenuEvent=!1,o.timer=null,E.set(o,{tempEditorDimensions:{},cellBelowCursor:null}),o}return l(t,e),a(t,[{key:"isEnabled",value:function(){return!!this.hot.getSettings().comments}},{key:"enablePlugin",value:function(){var e=this;this.enabled||(this.editor||(this.editor=new w.default),this.eventManager||(this.eventManager=new f.default(this)),this.displaySwitch||(this.displaySwitch=new S.default(this.getDisplayDelaySetting())),this.addHook("afterContextMenuDefaultOptions",function(t){return e.addToContextMenu(t)}),this.addHook("afterRenderer",function(t,o,n,r,i,s){return e.onAfterRenderer(t,s)}),this.addHook("afterScrollHorizontally",function(){return e.hide()}),this.addHook("afterScrollVertically",function(){return e.hide()}),this.addHook("afterBeginEditing",function(t){return e.onAfterBeginEditing(t)}),this.displaySwitch.addLocalHook("hide",function(){return e.hide()}),this.displaySwitch.addLocalHook("show",function(t,o){return e.showAtCell(t,o)}),this.registerListeners(),u(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{key:"updatePlugin",value:function(){this.disablePlugin(),this.enablePlugin(),u(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"updatePlugin",this).call(this),this.displaySwitch.updateDelay(this.getDisplayDelaySetting())}},{key:"disablePlugin",value:function(){u(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"registerListeners",value:function(){var e=this;this.eventManager.addEventListener(document,"mouseover",function(t){return e.onMouseOver(t)}),this.eventManager.addEventListener(document,"mousedown",function(t){return e.onMouseDown(t)}),this.eventManager.addEventListener(document,"mouseup",function(t){return e.onMouseUp(t)}),this.eventManager.addEventListener(this.editor.getInputElement(),"blur",function(t){return e.onEditorBlur(t)}),this.eventManager.addEventListener(this.editor.getInputElement(),"mousedown",function(t){return e.onEditorMouseDown(t)}),this.eventManager.addEventListener(this.editor.getInputElement(),"mouseup",function(t){return e.onEditorMouseUp(t)})}},{key:"setRange",value:function(e){this.range=e}},{key:"clearRange",value:function(){this.range={}}},{key:"targetIsCellWithComment",value:function(e){var t=(0,c.closest)(e.target,"TD","TBODY");return!!(t&&(0,c.hasClass)(t,"htCommentCell")&&(0,c.closest)(t,[this.hot.rootElement]))}},{key:"targetIsCommentTextArea",value:function(e){return this.editor.getInputElement()===e.target}},{key:"setComment",value:function(e){if(!this.range.from)throw Error('Before using this method, first set cell range (hot.getPlugin("comment").setRange())');var t=this.editor.getValue(),o="";null!=e?o=e:null!=t&&(o=t),this.updateCommentMeta(this.range.from.row,this.range.from.col,r({},"value",o)),this.hot.render()}},{key:"setCommentAtCell",value:function(e,t,o){this.setRange({from:new p.CellCoords(e,t)}),this.setComment(o)}},{key:"removeComment",value:function(){var e=0>=arguments.length||void 0===arguments[0]||arguments[0];if(!this.range.from)throw Error('Before using this method, first set cell range (hot.getPlugin("comment").setRange())');this.hot.setCellMeta(this.range.from.row,this.range.from.col,"comment",void 0),e&&this.hot.render(),this.hide()}},{key:"removeCommentAtCell",value:function(e,t){var o=2>=arguments.length||void 0===arguments[2]||arguments[2];this.setRange({from:new p.CellCoords(e,t)}),this.removeComment(o)}},{key:"getComment",value:function(){return this.getCommentMeta(this.range.from.row,this.range.from.col,"value")}},{key:"getCommentAtCell",value:function(e,t){return this.getCommentMeta(e,t,"value")}},{key:"show",value:function(){if(!this.range.from)throw Error('Before using this method, first set cell range (hot.getPlugin("comment").setRange())');var e=this.hot.getCellMeta(this.range.from.row,this.range.from.col);return this.refreshEditor(!0),this.editor.setValue(e.comment?e.comment.value:""),this.editor.hidden&&this.editor.show(),!0}},{key:"showAtCell",value:function(e,t){return this.setRange({from:new p.CellCoords(e,t)}),this.show()}},{key:"hide",value:function(){this.editor.hidden||this.editor.hide()}},{key:"refreshEditor",value:function(){if(arguments.length>0&&void 0!==arguments[0]&&arguments[0]||this.range.from&&this.editor.isVisible()){var e=(0,c.getScrollableElement)(this.hot.view.wt.wtTable.TABLE),t=this.hot.view.wt.wtTable.getCell(this.range.from),o=this.range.from.row,n=this.range.from.col,r=(0,c.offset)(t),i=this.hot.view.wt.wtTable.getStretchedColumnWidth(n),s=0>r.top?0:r.top,l=r.left;this.hot.view.wt.wtViewport.hasVerticalScroll()&&e!==window&&(s-=this.hot.view.wt.wtOverlays.topOverlay.getScrollPosition()),this.hot.view.wt.wtViewport.hasHorizontalScroll()&&e!==window&&(l-=this.hot.view.wt.wtOverlays.leftOverlay.getScrollPosition());var a=l+i,u=s,h=this.getCommentMeta(o,n,"style"),d=this.getCommentMeta(o,n,"readOnly");h?this.editor.setSize(h.width,h.height):this.editor.resetSize(),this.editor.setReadOnlyState(d),this.editor.setPosition(a,u)}}},{key:"checkSelectionCommentsConsistency",value:function(){var e=this.hot.getSelectedRange();if(!e)return!1;var t=!1,o=e.from;return this.getCommentMeta(o.row,o.col,"value")&&(t=!0),t}},{key:"updateCommentMeta",value:function(e,t,o){var n=this.hot.getCellMeta(e,t).comment,r=void 0;n?(r=(0,h.deepClone)(n),(0,h.deepExtend)(r,o)):r=o,this.hot.setCellMeta(e,t,"comment",r)}},{key:"getCommentMeta",value:function(e,t,o){var n=this.hot.getCellMeta(e,t);if(n.comment)return n.comment[o]}},{key:"onMouseDown",value:function(e){if(this.mouseDown=!0,this.hot.view&&this.hot.view.wt){if(!this.contextMenuEvent&&!this.targetIsCommentTextArea(e)){var t=(0,c.closest)(e.target,"TD","TBODY"),o=null;t&&(o=this.hot.view.wt.wtTable.getCoords(t)),(!t||this.range.from&&o&&(this.range.from.row!==o.row||this.range.from.col!==o.col))&&this.hide()}this.contextMenuEvent=!1}}},{key:"onMouseOver",value:function(e){var t=E.get(this);if(t.cellBelowCursor=document.elementFromPoint(e.clientX,e.clientY),!(this.mouseDown||this.editor.isFocused()||(0,c.hasClass)(e.target,"wtBorder")||t.cellBelowCursor!==e.target)&&this.editor)if(this.targetIsCellWithComment(e)){var o=this.hot.view.wt.wtTable.getCoords(e.target),n={from:new p.CellCoords(o.row,o.col)};this.displaySwitch.show(n)}else(0,c.isChildOf)(e.target,document)&&!this.targetIsCommentTextArea(e)&&this.displaySwitch.hide()}},{key:"onMouseUp",value:function(e){this.mouseDown=!1}},{key:"onAfterRenderer",value:function(e,t){t.comment&&t.comment.value&&(0,c.addClass)(e,t.commentedCellClassName)}},{key:"onEditorBlur",value:function(e){this.setComment()}},{key:"onEditorMouseDown",value:function(e){E.get(this).tempEditorDimensions={width:(0,c.outerWidth)(e.target),height:(0,c.outerHeight)(e.target)}}},{key:"onEditorMouseUp",value:function(e){var t=E.get(this),o=(0,c.outerWidth)(e.target),n=(0,c.outerHeight)(e.target);o===t.tempEditorDimensions.width+1&&n===t.tempEditorDimensions.height+2||this.updateCommentMeta(this.range.from.row,this.range.from.col,r({},"style",{width:o,height:n}))}},{key:"onContextMenuAddComment",value:function(){var e=this;this.displaySwitch.cancelHiding();var t=this.hot.getSelectedRange();this.contextMenuEvent=!0,this.setRange({from:t.from}),this.show(),setTimeout(function(){e.hot&&(e.hot.deselectCell(),e.editor.focus())},10)}},{key:"onContextMenuRemoveComment",value:function(e){this.contextMenuEvent=!0;for(var t=e.start.row;e.end.row>=t;t++)for(var o=e.start.col;e.end.col>=o;o++)this.removeCommentAtCell(t,o,!1);this.hot.render()}},{key:"onContextMenuMakeReadOnly",value:function(e){this.contextMenuEvent=!0;for(var t=e.start.row;e.end.row>=t;t++)for(var o=e.start.col;e.end.col>=o;o++){var n=!!this.getCommentMeta(t,o,"readOnly");this.updateCommentMeta(t,o,r({},"readOnly",!n))}}},{key:"addToContextMenu",value:function(e){var t=this;e.items.push({name:"---------"},{key:"commentsAddEdit",name:function(){return t.checkSelectionCommentsConsistency()?"Edit comment":"Add comment"},callback:function(){return t.onContextMenuAddComment()},disabled:function(){return!(this.getSelected()&&!this.selection.selectedHeader.corner)}},{key:"commentsRemove",name:function(){return"Delete comment"},callback:function(e,o){return t.onContextMenuRemoveComment(o)},disabled:function(){return t.hot.selection.selectedHeader.corner}},{key:"commentsReadOnly",name:function(){var e=this,t="Read only comment";return(0,C.checkSelectionConsistency)(this.getSelectedRange(),function(t,o){var n=e.getCellMeta(t,o).comment;if(n&&(n=n.readOnly),n)return!0})&&(t=(0,C.markLabelAsSelected)(t)),t},callback:function(e,o){return t.onContextMenuMakeReadOnly(o)},disabled:function(){return t.hot.selection.selectedHeader.corner||!t.checkSelectionCommentsConsistency()}})}},{key:"getDisplayDelaySetting",value:function(){var e=this.hot.getSettings().comments;if((0,h.isObject)(e))return e.displayDelay}},{key:"onAfterBeginEditing",value:function(e,t){this.hide()}},{key:"destroy",value:function(){this.editor&&this.editor.destroy(),this.displaySwitch&&this.displaySwitch.destroy(),u(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}}]),t}(m.default);(0,g.registerPlugin)("comments",R),t.default=R},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=o(35),s=o(1),l=o(69),a=function(e){return e&&e.__esModule?e:{default:e}}(l),u=function(){function e(t){n(this,e),this.wasLastActionShow=!0,this.showDebounced=null,this.hidingTimer=null,this.updateDelay(t)}return r(e,[{key:"hide",value:function(){var e=this;this.wasLastActionShow=!1,this.hidingTimer=setTimeout(function(){!1===e.wasLastActionShow&&e.runLocalHooks("hide")},250)}},{key:"show",value:function(e){this.wasLastActionShow=!0,this.showDebounced(e)}},{key:"cancelHiding",value:function(){this.wasLastActionShow=!0,clearTimeout(this.hidingTimer),this.hidingTimer=null}},{key:"updateDelay",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:250;this.showDebounced=(0,i.debounce)(function(t){e.wasLastActionShow&&e.runLocalHooks("show",t.from.row,t.from.col)},t)}},{key:"destroy",value:function(){this.clearLocalHooks()}}]),e}();(0,s.mixin)(u,a.default),t.default=u},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){var o=void 0;return(0,s.arrayEach)(t,function(t){var n=t.key?t.key.split(":"):null;if(Array.isArray(n)&&n[1]===e)return o=t,!1}),o}t.__esModule=!0;var i=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),s=o(2),l=o(1);t.default=function(){function e(t){n(this,e),this.hot=t,this.commands={},this.commonCallback=null}return i(e,[{key:"registerCommand",value:function(e,t){this.commands[e]=t}},{key:"setCommonCallback",value:function(e){this.commonCallback=e}},{key:"execute",value:function(e){for(var t=this,o=arguments.length,n=Array(o>1?o-1:0),i=1;o>i;i++)n[i-1]=arguments[i];var a=e.split(":");e=a[0];var u=2===a.length?a[1]:null,c=this.commands[e];if(!c)throw Error("Menu command '"+e+"' not exists.");if(u&&c.submenu&&(c=r(u,c.submenu.items)),!0!==c.disabled&&("function"!=typeof c.disabled||!0!==c.disabled.call(this.hot))&&!(0,l.hasOwnProperty)(c,"submenu")){var h=[];"function"==typeof c.callback&&h.push(c.callback),"function"==typeof this.commonCallback&&h.push(this.commonCallback),n.unshift(a.join(":")),(0,s.arrayEach)(h,function(e){return e.apply(t.hot,n)})}}}]),e}()},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var l=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},a=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),u=o(12),c=n(u),h=o(8),d=n(h),f=o(2),p=o(220),g=n(p),v=o(4),m=n(v),y=o(223),w=n(y),C=o(224),b=n(C),S=o(5),E=o(7),R=o(0),O=o(70);o(299),d.default.getSingleton().register("afterContextMenuDefaultOptions"),d.default.getSingleton().register("afterContextMenuShow"),d.default.getSingleton().register("afterContextMenuHide"),d.default.getSingleton().register("afterContextMenuExecute");var k=function(e){function t(e){r(this,t);var o=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.eventManager=new m.default(o),o.commandExecutor=new g.default(o.hot),o.itemsFactory=null,o.menu=null,o}return s(t,e),a(t,null,[{key:"DEFAULT_ITEMS",get:function(){return[O.ROW_ABOVE,O.ROW_BELOW,O.SEPARATOR,O.COLUMN_LEFT,O.COLUMN_RIGHT,O.SEPARATOR,O.REMOVE_ROW,O.REMOVE_COLUMN,O.SEPARATOR,O.UNDO,O.REDO,O.SEPARATOR,O.READ_ONLY,O.SEPARATOR,O.ALIGNMENT]}}]),a(t,[{key:"isEnabled",value:function(){return this.hot.getSettings().contextMenu}},{key:"enablePlugin",value:function(){var e=this;if(!this.enabled){this.itemsFactory=new w.default(this.hot,t.DEFAULT_ITEMS);var o=this.hot.getSettings().contextMenu,n={items:this.itemsFactory.getItems(o)};this.registerEvents(),"function"==typeof o.callback&&this.commandExecutor.setCommonCallback(o.callback),l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this),this.callOnPluginsReady(function(){e.hot.runHooks("afterContextMenuDefaultOptions",n),e.itemsFactory.setPredefinedItems(n.items);var t=e.itemsFactory.getItems(o);e.menu=new b.default(e.hot,{className:"htContextMenu",keepInViewport:!0}),e.hot.runHooks("beforeContextMenuSetItems",t),e.menu.setMenuItems(t),e.menu.addLocalHook("afterOpen",function(){return e.onMenuAfterOpen()}),e.menu.addLocalHook("afterClose",function(){return e.onMenuAfterClose()}),e.menu.addLocalHook("executeCommand",function(){for(var t=arguments.length,o=Array(t),n=0;t>n;n++)o[n]=arguments[n];return e.executeCommand.apply(e,o)}),(0,f.arrayEach)(t,function(t){return e.commandExecutor.registerCommand(t.key,t)})})}}},{key:"updatePlugin",value:function(){this.disablePlugin(),this.enablePlugin(),l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"updatePlugin",this).call(this)}},{key:"disablePlugin",value:function(){this.close(),this.menu&&(this.menu.destroy(),this.menu=null),l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"registerEvents",value:function(){var e=this;this.eventManager.addEventListener(this.hot.rootElement,"contextmenu",function(t){return e.onContextMenu(t)})}},{key:"open",value:function(e){this.menu&&(this.menu.open(),this.menu.setPosition({top:parseInt((0,E.pageY)(e),10)-(0,R.getWindowScrollTop)(),left:parseInt((0,E.pageX)(e),10)-(0,R.getWindowScrollLeft)()}),this.menu.hotMenu.isHotTableEnv=this.hot.isHotTableEnv)}},{key:"close",value:function(){this.menu&&this.menu.close()}},{key:"executeCommand",value:function(){for(var e=arguments.length,t=Array(e),o=0;e>o;o++)t[o]=arguments[o];this.commandExecutor.execute.apply(this.commandExecutor,t)}},{key:"onContextMenu",value:function(e){var t=this.hot.getSettings(),o=t.rowHeaders,n=t.colHeaders,r=e.realTarget;this.close(),(0,R.hasClass)(r,"handsontableInput")||(e.preventDefault(),(0,E.stopPropagation)(e),(o||n||function(e){return"TD"===e.nodeName||"TD"===e.parentNode.nodeName}(r)||(0,R.hasClass)(r,"current")&&(0,R.hasClass)(r,"wtBorder"))&&this.open(e))}},{key:"onMenuAfterOpen",value:function(){this.hot.runHooks("afterContextMenuShow",this)}},{key:"onMenuAfterClose",value:function(){this.hot.listen(),this.hot.runHooks("afterContextMenuHide",this)}},{key:"destroy",value:function(){this.close(),this.menu&&this.menu.destroy(),l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}}]),t}(c.default);k.SEPARATOR={name:O.SEPARATOR},(0,S.registerPlugin)("contextMenu",k),t.default=k},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=o(0),s=o(7);t.default=function(){function e(t){n(this,e);var o=(0,i.getWindowScrollTop)(),r=(0,i.getWindowScrollLeft)(),l=void 0,a=void 0,u=void 0,c=void 0,h=void 0,d=void 0;this.type=this.getSourceType(t),"literal"===this.type?(l=parseInt(t.top,10),u=parseInt(t.left,10),h=t.height||0,d=t.width||0,a=l,c=u,l+=o,u+=r):"event"===this.type&&(l=parseInt((0,s.pageY)(t),10),u=parseInt((0,s.pageX)(t),10),h=t.target.clientHeight,d=t.target.clientWidth,a=l-o,c=u-r),this.top=l,this.topRelative=a,this.left=u,this.leftRelative=c,this.scrollTop=o,this.scrollLeft=r,this.cellHeight=h,this.cellWidth=d}return r(e,[{key:"getSourceType",value:function(e){var t="literal";return e instanceof Event&&(t="event"),t}},{key:"fitsAbove",value:function(e){return this.topRelative>=e.offsetHeight}},{key:"fitsBelow",value:function(e){return(arguments.length>1&&void 0!==arguments[1]?arguments[1]:window.innerHeight)>=this.topRelative+e.offsetHeight}},{key:"fitsOnRight",value:function(e){return(arguments.length>1&&void 0!==arguments[1]?arguments[1]:window.innerWidth)>=this.leftRelative+this.cellWidth+e.offsetWidth}},{key:"fitsOnLeft",value:function(e){return this.leftRelative>=e.offsetWidth}}]),e}()},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},n=[];return e&&e.items?e=e.items:Array.isArray(e)||(e=t),(0,s.isObject)(e)?(0,s.objectEach)(e,function(e,t){var r=o["string"==typeof e?e:t];r||(r=e),(0,s.isObject)(e)?(0,s.extend)(r,e):"string"==typeof r&&(r={name:r}),void 0===r.key&&(r.key=t),n.push(r)}):(0,l.arrayEach)(e,function(e,t){var r=o[e];(r||0>a.ITEMS.indexOf(e))&&(r||(r={name:e,key:""+t}),(0,s.isObject)(e)&&(0,s.extend)(r,e),void 0===r.key&&(r.key=t),n.push(r))}),n}t.__esModule=!0;var i=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),s=o(1),l=o(2),a=o(70);t.default=function(){function e(t){var o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;n(this,e),this.hot=t,this.predefinedItems=(0,a.predefinedItems)(),this.defaultOrderPattern=o}return i(e,[{key:"setPredefinedItems",value:function(e){var t=this,o={};this.defaultOrderPattern.length=0,(0,s.objectEach)(e,function(e,n){var r="";e.name===a.SEPARATOR?(o[a.SEPARATOR]=e,r=a.SEPARATOR):isNaN(parseInt(n,10))?(e.key=void 0===e.key?n:e.key,o[n]=e,r=e.key):(o[e.key]=e,r=e.key),t.defaultOrderPattern.push(r)}),this.predefinedItems=o}},{key:"getItems",value:function(){return r(arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,this.defaultOrderPattern,this.predefinedItems)}}]),e}()},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var i=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),s=o(63),l=n(s),a=o(0),u=o(2),c=o(222),h=n(c),d=o(4),f=n(d),p=o(1),g=o(35),v=o(17),m=o(16),y=o(69),w=n(y),C=o(70),b=o(7),S=function(){function e(t,o){r(this,e),this.hot=t,this.options=o||{parent:null,name:null,className:"",keepInViewport:!0,standalone:!1},this.eventManager=new f.default(this),this.container=this.createContainer(this.options.name),this.hotMenu=null,this.hotSubMenus={},this.parentMenu=this.options.parent||null,this.menuItems=null,this.origOutsideClickDeselects=null,this.keyEvent=!1,this.offset={above:0,below:0,left:0,right:0},this._afterScrollCallback=null,this.registerEvents()}return i(e,[{key:"registerEvents",value:function(){var e=this;this.eventManager.addEventListener(document.documentElement,"mousedown",function(t){return e.onDocumentMouseDown(t)})}},{key:"setMenuItems",value:function(e){this.menuItems=e}},{key:"setOffset",value:function(e){this.offset[e]=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0}},{key:"isSubMenu",value:function(){return null!==this.parentMenu}},{key:"open",value:function(){var e=this;this.container.removeAttribute("style"),this.container.style.display="block";var t=(0,g.debounce)(function(t){return e.openSubMenu(t)},300),o=(0,u.arrayFilter)(this.menuItems,function(t){return(0,v.isItemHidden)(t,e.hot)});o=(0,v.filterSeparators)(o,C.SEPARATOR);var n={data:o,colHeaders:!1,colWidths:[200],autoRowSize:!1,readOnly:!0,copyPaste:!1,columns:[{data:"name",renderer:function(t,o,n,r,i,s){return e.menuItemRenderer(t,o,n,r,i,s)}}],renderAllRows:!0,fragmentSelection:"cell",disableVisualSelection:"area",beforeKeyDown:function(t){return e.onBeforeKeyDown(t)},afterOnCellMouseOver:function(o,n,r){e.isAllSubMenusClosed()?t(n.row):e.openSubMenu(n.row)},rowHeights:function(e){return o[e].name===C.SEPARATOR?1:23}};this.origOutsideClickDeselects=this.hot.getSettings().outsideClickDeselects,this.hot.getSettings().outsideClickDeselects=!1,this.hotMenu=new l.default(this.container,n),this.hotMenu.addHook("afterInit",function(){return e.onAfterInit()}),this.hotMenu.addHook("afterSelection",function(t,o,n,r,i){return e.onAfterSelection(t,o,n,r,i)}),this.hotMenu.init(),this.hotMenu.listen(),this.blockMainTableCallbacks(),this.runLocalHooks("afterOpen")}},{key:"close",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this.isOpened()&&(e&&this.parentMenu?this.parentMenu.close():(this.closeAllSubMenus(),this.container.style.display="none",this.releaseMainTableCallbacks(),this.hotMenu.destroy(),this.hotMenu=null,this.hot.getSettings().outsideClickDeselects=this.origOutsideClickDeselects,this.runLocalHooks("afterClose"),this.parentMenu&&this.parentMenu.hotMenu.listen()))}},{key:"openSubMenu",value:function(t){if(!this.hotMenu)return!1;var o=this.hotMenu.getCell(t,0);if(this.closeAllSubMenus(),!o||!(0,v.hasSubMenu)(o))return!1;var n=this.hotMenu.getSourceDataAtRow(t),r=new e(this.hot,{parent:this,name:n.name,className:this.options.className,keepInViewport:!0});return r.setMenuItems(n.submenu.items),r.open(),r.setPosition(o.getBoundingClientRect()),this.hotSubMenus[n.key]=r,r}},{key:"closeSubMenu",value:function(e){var t=this.hotMenu.getSourceDataAtRow(e),o=this.hotSubMenus[t.key];o&&(o.destroy(),delete this.hotSubMenus[t.key])}},{key:"closeAllSubMenus",value:function(){var e=this;(0,u.arrayEach)(this.hotMenu.getData(),function(t,o){return e.closeSubMenu(o)})}},{key:"isAllSubMenusClosed",value:function(){return 0===Object.keys(this.hotSubMenus).length}},{key:"destroy",value:function(){this.clearLocalHooks(),this.close(),this.parentMenu=null,this.eventManager.destroy()}},{key:"isOpened",value:function(){return null!==this.hotMenu}},{key:"executeCommand",value:function(e){if(this.isOpened()&&this.hotMenu.getSelected()){var t=this.hotMenu.getSourceDataAtRow(this.hotMenu.getSelected()[0]);if(this.runLocalHooks("select",t,e),!1!==t.isCommand&&t.name!==C.SEPARATOR){var o=this.hot.getSelectedRange(),n=o?(0,v.normalizeSelection)(o):{},r=!0;(!0===t.disabled||"function"==typeof t.disabled&&!0===t.disabled.call(this.hot)||t.submenu)&&(r=!1),this.runLocalHooks("executeCommand",t.key,n,e),this.isSubMenu()&&this.parentMenu.runLocalHooks("executeCommand",t.key,n,e),r&&this.close(!0)}}}},{key:"setPosition",value:function(e){var t=new h.default(e);this.options.keepInViewport?(t.fitsBelow(this.container)?this.setPositionBelowCursor(t):t.fitsAbove(this.container)?this.setPositionAboveCursor(t):this.setPositionBelowCursor(t),t.fitsOnRight(this.container)?this.setPositionOnRightOfCursor(t):this.setPositionOnLeftOfCursor(t)):(this.setPositionBelowCursor(t),this.setPositionOnRightOfCursor(t))}},{key:"setPositionAboveCursor",value:function(e){var t=this.offset.above+e.top-this.container.offsetHeight;this.isSubMenu()&&(t=e.top+e.cellHeight-this.container.offsetHeight+3),this.container.style.top=t+"px"}},{key:"setPositionBelowCursor",value:function(e){var t=this.offset.below+e.top;this.isSubMenu()&&(t=e.top-1),this.container.style.top=t+"px"}},{key:"setPositionOnRightOfCursor",value:function(e){var t=void 0;t=this.isSubMenu()?1+e.left+e.cellWidth:this.offset.right+1+e.left,this.container.style.left=t+"px"}},{key:"setPositionOnLeftOfCursor",value:function(e){this.container.style.left=this.offset.left+e.left-this.container.offsetWidth+(0,a.getScrollbarWidth)()+4+"px"}},{key:"selectFirstCell",value:function(){var e=this.hotMenu.getCell(0,0);(0,v.isSeparator)(e)||(0,v.isDisabled)(e)||(0,v.isSelectionDisabled)(e)?this.selectNextCell(0,0):this.hotMenu.selectCell(0,0)}},{key:"selectLastCell",value:function(){var e=this.hotMenu.countRows()-1,t=this.hotMenu.getCell(e,0);(0,v.isSeparator)(t)||(0,v.isDisabled)(t)||(0,v.isSelectionDisabled)(t)?this.selectPrevCell(e,0):this.hotMenu.selectCell(e,0)}},{key:"selectNextCell",value:function(e,t){var o=e+1,n=o<this.hotMenu.countRows()?this.hotMenu.getCell(o,t):null;n&&((0,v.isSeparator)(n)||(0,v.isDisabled)(n)||(0,v.isSelectionDisabled)(n)?this.selectNextCell(o,t):this.hotMenu.selectCell(o,t))}},{key:"selectPrevCell",value:function(e,t){var o=e-1,n=0>o?null:this.hotMenu.getCell(o,t);n&&((0,v.isSeparator)(n)||(0,v.isDisabled)(n)||(0,v.isSelectionDisabled)(n)?this.selectPrevCell(o,t):this.hotMenu.selectCell(o,t))}},{key:"menuItemRenderer",value:function(e,t,o,n,r,i){var s=this,l=e.getSourceDataAtRow(o),u=document.createElement("div"),c=function(e){return e.disableSelection};"function"==typeof i&&(i=i.call(this.hot)),(0,a.empty)(t),(0,a.addClass)(u,"htItemWrapper"),t.appendChild(u),!function(e){return RegExp(C.SEPARATOR,"i").test(e.name)}(l)?"function"==typeof l.renderer?((0,a.addClass)(t,"htCustomMenuRenderer"),t.appendChild(l.renderer(e,u,o,n,r,i))):(0,a.fastInnerHTML)(u,i):(0,a.addClass)(t,"htSeparator"),!function(e){return!0===e.disabled||"function"==typeof e.disabled&&!0===e.disabled.call(s.hot)}(l)?c(l)?((0,a.addClass)(t,"htSelectionDisabled"),this.eventManager.addEventListener(t,"mouseenter",function(){return e.deselectCell()})):!function(e){return(0,p.hasOwnProperty)(e,"submenu")}(l)?((0,a.removeClass)(t,"htSubmenu"),(0,a.removeClass)(t,"htDisabled"),c(l)?this.eventManager.addEventListener(t,"mouseenter",function(){return e.deselectCell()}):this.eventManager.addEventListener(t,"mouseenter",function(){return e.selectCell(o,n,void 0,void 0,!1,!1)})):((0,a.addClass)(t,"htSubmenu"),c(l)?this.eventManager.addEventListener(t,"mouseenter",function(){return e.deselectCell()}):this.eventManager.addEventListener(t,"mouseenter",function(){return e.selectCell(o,n,void 0,void 0,!1,!1)})):((0,a.addClass)(t,"htDisabled"),this.eventManager.addEventListener(t,"mouseenter",function(){return e.deselectCell()}))}},{key:"createContainer",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;e&&(e=e.replace(/[^A-z0-9]/g,"_"),e=this.options.className+"Sub_"+e);var t=void 0;return t=e?document.querySelector("."+this.options.className+"."+e):document.querySelector("."+this.options.className),t||(t=document.createElement("div"),(0,a.addClass)(t,"htMenu "+this.options.className),e&&(0,a.addClass)(t,e),document.getElementsByTagName("body")[0].appendChild(t)),t}},{key:"blockMainTableCallbacks",value:function(){this._afterScrollCallback=function(){},this.hot.addHook("afterScrollVertically",this._afterScrollCallback),this.hot.addHook("afterScrollHorizontally",this._afterScrollCallback)}},{key:"releaseMainTableCallbacks",value:function(){this._afterScrollCallback&&(this.hot.removeHook("afterScrollVertically",this._afterScrollCallback),this.hot.removeHook("afterScrollHorizontally",this._afterScrollCallback),this._afterScrollCallback=null)}},{key:"onBeforeKeyDown",value:function(e){var t=this.hotMenu.getSelected(),o=!1;switch(this.keyEvent=!0,e.keyCode){case m.KEY_CODES.ESCAPE:this.close(),o=!0;break;case m.KEY_CODES.ENTER:t&&(this.hotMenu.getSourceDataAtRow(t[0]).submenu?o=!0:(this.executeCommand(e),this.close(!0)));break;case m.KEY_CODES.ARROW_DOWN:t?this.selectNextCell(t[0],t[1]):this.selectFirstCell(),o=!0;break;case m.KEY_CODES.ARROW_UP:t?this.selectPrevCell(t[0],t[1]):this.selectLastCell(),o=!0;break;case m.KEY_CODES.ARROW_RIGHT:if(t){var n=this.openSubMenu(t[0]);n&&n.selectFirstCell()}o=!0;break;case m.KEY_CODES.ARROW_LEFT:t&&this.isSubMenu()&&(this.close(),this.parentMenu&&this.parentMenu.hotMenu.listen(),o=!0)}o&&(e.preventDefault(),(0,b.stopImmediatePropagation)(e)),this.keyEvent=!1}},{key:"onAfterInit",value:function(){var e=this.hotMenu.getSettings().data,t=this.hotMenu.view.wt.wtTable.hider.style,o=this.hotMenu.view.wt.wtTable.holder.style,n=parseInt(t.width,10),r=(0,u.arrayReduce)(e,function(e,t){return e+(t.name===C.SEPARATOR?1:26)},0);o.width=n+22+"px",o.height=r+4+"px",t.height=o.height}},{key:"onAfterSelection",value:function(e,t,o,n,r){!1===this.keyEvent&&(r.value=!0)}},{key:"onDocumentMouseDown",value:function(e){this.isOpened()&&(this.container&&(0,a.isChildOf)(e.target,this.container)&&this.executeCommand(e),this.options.standalone&&this.hotMenu&&!(0,a.isChildOf)(e.target,this.hotMenu.rootElement)?this.close(!0):(this.isAllSubMenusClosed()||this.isSubMenu())&&!(0,a.isChildOf)(e.target,".htMenu")&&(0,a.isChildOf)(e.target,document)&&this.close(!0))}}]),e}();(0,p.mixin)(S,w.default),t.default=S},function(e,t,o){"use strict";function n(){return{key:s,name:"Alignment",disabled:function(){return!(this.getSelectedRange()&&!this.selection.selectedHeader.corner)},submenu:{items:[{key:s+":left",name:function(){var e=this,t="Left";return(0,r.checkSelectionConsistency)(this.getSelectedRange(),function(t,o){var n=e.getCellMeta(t,o).className;if(n&&-1!==n.indexOf("htLeft"))return!0})&&(t=(0,r.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),o=(0,r.getAlignmentClasses)(t,function(t,o){return e.getCellMeta(t,o).className});this.runHooks("beforeCellAlignment",o,t,"horizontal","htLeft"),(0,r.align)(t,"horizontal","htLeft",function(t,o){return e.getCellMeta(t,o)},function(t,o,n,r){return e.setCellMeta(t,o,n,r)}),this.render()},disabled:!1},{key:s+":center",name:function(){var e=this,t="Center";return(0,r.checkSelectionConsistency)(this.getSelectedRange(),function(t,o){var n=e.getCellMeta(t,o).className;if(n&&-1!==n.indexOf("htCenter"))return!0})&&(t=(0,r.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),o=(0,r.getAlignmentClasses)(t,function(t,o){return e.getCellMeta(t,o).className});this.runHooks("beforeCellAlignment",o,t,"horizontal","htCenter"),(0,r.align)(t,"horizontal","htCenter",function(t,o){return e.getCellMeta(t,o)},function(t,o,n,r){return e.setCellMeta(t,o,n,r)}),this.render()},disabled:!1},{key:s+":right",name:function(){var e=this,t="Right";return(0,r.checkSelectionConsistency)(this.getSelectedRange(),function(t,o){var n=e.getCellMeta(t,o).className;if(n&&-1!==n.indexOf("htRight"))return!0})&&(t=(0,r.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),o=(0,r.getAlignmentClasses)(t,function(t,o){return e.getCellMeta(t,o).className});this.runHooks("beforeCellAlignment",o,t,"horizontal","htRight"),(0,r.align)(t,"horizontal","htRight",function(t,o){return e.getCellMeta(t,o)},function(t,o,n,r){return e.setCellMeta(t,o,n,r)}),this.render()},disabled:!1},{key:s+":justify",name:function(){var e=this,t="Justify";return(0,r.checkSelectionConsistency)(this.getSelectedRange(),function(t,o){var n=e.getCellMeta(t,o).className;if(n&&-1!==n.indexOf("htJustify"))return!0})&&(t=(0,r.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),o=(0,r.getAlignmentClasses)(t,function(t,o){return e.getCellMeta(t,o).className});this.runHooks("beforeCellAlignment",o,t,"horizontal","htJustify"),(0,r.align)(t,"horizontal","htJustify",function(t,o){return e.getCellMeta(t,o)},function(t,o,n,r){return e.setCellMeta(t,o,n,r)}),this.render()},disabled:!1},{name:i.KEY},{key:s+":top",name:function(){var e=this,t="Top";return(0,r.checkSelectionConsistency)(this.getSelectedRange(),function(t,o){var n=e.getCellMeta(t,o).className;if(n&&-1!==n.indexOf("htTop"))return!0})&&(t=(0,r.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),o=(0,r.getAlignmentClasses)(t,function(t,o){return e.getCellMeta(t,o).className});this.runHooks("beforeCellAlignment",o,t,"vertical","htTop"),(0,r.align)(t,"vertical","htTop",function(t,o){return e.getCellMeta(t,o)},function(t,o,n,r){return e.setCellMeta(t,o,n,r)}),this.render()},disabled:!1},{key:s+":middle",name:function(){var e=this,t="Middle";return(0,r.checkSelectionConsistency)(this.getSelectedRange(),function(t,o){var n=e.getCellMeta(t,o).className;if(n&&-1!==n.indexOf("htMiddle"))return!0})&&(t=(0,r.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),o=(0,r.getAlignmentClasses)(t,function(t,o){return e.getCellMeta(t,o).className});this.runHooks("beforeCellAlignment",o,t,"vertical","htMiddle"),(0,r.align)(t,"vertical","htMiddle",function(t,o){return e.getCellMeta(t,o)},function(t,o,n,r){return e.setCellMeta(t,o,n,r)}),this.render()},disabled:!1},{key:s+":bottom",name:function(){var e=this,t="Bottom";return(0,r.checkSelectionConsistency)(this.getSelectedRange(),function(t,o){var n=e.getCellMeta(t,o).className;if(n&&-1!==n.indexOf("htBottom"))return!0})&&(t=(0,r.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),o=(0,r.getAlignmentClasses)(t,function(t,o){return e.getCellMeta(t,o).className});this.runHooks("beforeCellAlignment",o,t,"vertical","htBottom"),(0,r.align)(t,"vertical","htBottom",function(t,o){return e.getCellMeta(t,o)},function(t,o,n,r){return e.setCellMeta(t,o,n,r)}),this.render()},disabled:!1}]}}}t.__esModule=!0,t.KEY=void 0,t.default=n;var r=o(17),i=o(71),s=t.KEY="alignment"},function(e,t,o){"use strict";function n(){return{key:i,name:"Clear column",callback:function(e,t){var o=t.start.col;this.countRows()&&this.populateFromArray(0,o,[[null]],Math.max(t.start.row,t.end.row),o,"ContextMenu.clearColumn")},disabled:function(){var e=(0,r.getValidSelection)(this);if(!e)return!0;var t=[e[0],0,e[0],this.countCols()-1],o=t.join(",")==e.join(",");return 0>e[1]||this.countCols()>=this.getSettings().maxCols||o}}}t.__esModule=!0,t.KEY=void 0,t.default=n;var r=o(17),i=t.KEY="clear_column"},function(e,t,o){"use strict";function n(){return{key:i,name:"Insert column on the left",callback:function(e,t){this.alter("insert_col",t.start.col,1,"ContextMenu.columnLeft")},disabled:function(){var e=(0,r.getValidSelection)(this);if(!e)return!0;if(!this.isColumnModificationAllowed())return!0;var t=[e[0],0,e[0],this.countCols()-1],o=t.join(",")==e.join(","),n=1===this.countCols();return 0>e[1]||this.countCols()>=this.getSettings().maxCols||!n&&o},hidden:function(){return!this.getSettings().allowInsertColumn}}}t.__esModule=!0,t.KEY=void 0,t.default=n;var r=o(17),i=t.KEY="col_left"},function(e,t,o){"use strict";function n(){return{key:i,name:"Insert column on the right",callback:function(e,t){this.alter("insert_col",t.end.col+1,1,"ContextMenu.columnRight")},disabled:function(){var e=(0,r.getValidSelection)(this);if(!e)return!0;if(!this.isColumnModificationAllowed())return!0;var t=[e[0],0,e[0],this.countCols()-1],o=t.join(",")==e.join(","),n=1===this.countCols();return 0>e[1]||this.countCols()>=this.getSettings().maxCols||!n&&o},hidden:function(){return!this.getSettings().allowInsertColumn}}}t.__esModule=!0,t.KEY=void 0,t.default=n;var r=o(17),i=t.KEY="col_right"},function(e,t,o){"use strict";function n(){return{key:i,name:function(){var e=this,t="Read only";return(0,r.checkSelectionConsistency)(this.getSelectedRange(),function(t,o){return e.getCellMeta(t,o).readOnly})&&(t=(0,r.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),o=(0,r.checkSelectionConsistency)(t,function(t,o){return e.getCellMeta(t,o).readOnly});t.forAll(function(t,n){e.setCellMeta(t,n,"readOnly",!o)}),this.render()},disabled:function(){return!(this.getSelectedRange()&&!this.selection.selectedHeader.corner)}}}t.__esModule=!0,t.KEY=void 0,t.default=n;var r=o(17),i=t.KEY="make_read_only"},function(e,t,o){"use strict";function n(){return{key:r,name:"Redo",callback:function(){this.redo()},disabled:function(){return this.undoRedo&&!this.undoRedo.isRedoAvailable()}}}t.__esModule=!0,t.default=n;var r=t.KEY="redo"},function(e,t,o){"use strict";function n(){return{key:i,name:"Remove column",callback:function(e,t){this.alter("remove_col",t.start.col,t.end.col-t.start.col+1,"ContextMenu.removeColumn")},disabled:function(){var e=(0,r.getValidSelection)(this),t=this.countCols();return!e||this.selection.selectedHeader.rows||this.selection.selectedHeader.corner||!this.isColumnModificationAllowed()||!t},hidden:function(){return!this.getSettings().allowRemoveColumn}}}t.__esModule=!0,t.KEY=void 0,t.default=n;var r=o(17),i=t.KEY="remove_col"},function(e,t,o){"use strict";function n(){return{key:i,name:"Remove row",callback:function(e,t){this.alter("remove_row",t.start.row,t.end.row-t.start.row+1,"ContextMenu.removeRow")},disabled:function(){var e=(0,r.getValidSelection)(this),t=this.countRows();return!e||this.selection.selectedHeader.cols||this.selection.selectedHeader.corner||!t},hidden:function(){return!this.getSettings().allowRemoveRow}}}t.__esModule=!0,t.KEY=void 0,t.default=n;var r=o(17),i=t.KEY="remove_row"},function(e,t,o){"use strict";function n(){return{key:i,name:"Insert row above",callback:function(e,t){this.alter("insert_row",t.start.row,1,"ContextMenu.rowAbove")},disabled:function(){return!(0,r.getValidSelection)(this)||this.selection.selectedHeader.cols||this.countRows()>=this.getSettings().maxRows},hidden:function(){return!this.getSettings().allowInsertRow}}}t.__esModule=!0,t.KEY=void 0,t.default=n;var r=o(17),i=t.KEY="row_above"},function(e,t,o){"use strict";function n(){return{key:i,name:"Insert row below",callback:function(e,t){this.alter("insert_row",t.end.row+1,1,"ContextMenu.rowBelow")},disabled:function(){return!(0,r.getValidSelection)(this)||this.selection.selectedHeader.cols||this.countRows()>=this.getSettings().maxRows},hidden:function(){return!this.getSettings().allowInsertRow}}}t.__esModule=!0,t.KEY=void 0,t.default=n;var r=o(17),i=t.KEY="row_below"},function(e,t,o){"use strict";function n(){return{key:r,name:"Undo",callback:function(){this.undo()},disabled:function(){return this.undoRedo&&!this.undoRedo.isUndoAvailable()}}}t.__esModule=!0,t.default=n;var r=t.KEY="undo"},function(e,t,o){"use strict";function n(e){return{key:"copy",name:"Copy",callback:function(){e.setCopyableText(),e.copy(!0)},disabled:function(){return!e.hot.getSelected()},hidden:!1}}t.__esModule=!0,t.default=n},function(e,t,o){"use strict";function n(e){return{key:"cut",name:"Cut",callback:function(){e.setCopyableText(),e.cut(!0)},disabled:function(){return!e.hot.getSelected()},hidden:!1}}t.__esModule=!0,t.default=n},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var l="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},a=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),u=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},c=o(12),h=n(c),d=o(8),f=n(d),p=o(134),g=n(p),v=o(11),m=o(16),y=o(0),w=o(2),C=o(6),b=o(7),S=o(5),E=o(239),R=n(E),O=o(236),k=n(O),T=o(237),_=n(T),M=o(4),H=n(M);o(300),f.default.getSingleton().register("afterCopyLimit"),f.default.getSingleton().register("modifyCopyableRange"),f.default.getSingleton().register("beforeCut"),f.default.getSingleton().register("afterCut"),f.default.getSingleton().register("beforePaste"),f.default.getSingleton().register("afterPaste"),f.default.getSingleton().register("beforeCopy"),f.default.getSingleton().register("afterCopy");var A=1e3,P=1e3,x=new WeakMap,D=function(e){function t(e){r(this,t);var o=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.eventManager=new H.default(o),o.columnsLimit=P,o.copyableRanges=[],o.pasteMode="overwrite",o.rowsLimit=A,o.textarea=void 0,x.set(o,{isTriggeredByPaste:!1}),o}return s(t,e),a(t,[{key:"isEnabled",value:function(){return!!this.hot.getSettings().copyPaste}},{key:"enablePlugin",value:function(){var e=this;if(!this.enabled){var o=this.hot.getSettings();this.textarea=R.default.getSingleton(),"object"===l(o.copyPaste)&&(this.pasteMode=o.copyPaste.pasteMode||this.pasteMode,this.rowsLimit=o.copyPaste.rowsLimit||this.rowsLimit,this.columnsLimit=o.copyPaste.columnsLimit||this.columnsLimit),this.addHook("afterContextMenuDefaultOptions",function(t){return e.onAfterContextMenuDefaultOptions(t)}),this.addHook("beforeKeyDown",function(t){return e.onBeforeKeyDown(t)}),this.registerEvents(),u(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this)}}},{key:"updatePlugin",value:function(){this.disablePlugin(),this.enablePlugin(),u(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"updatePlugin",this).call(this)}},{key:"disablePlugin",value:function(){this.textarea&&this.textarea.destroy(),u(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"setCopyableText",value:function(){var e=this.hot.getSelectedRange();if(e){var t=e.getTopLeftCorner(),o=e.getBottomRightCorner(),n=t.row,r=t.col,i=o.row,s=o.col,l=Math.min(i,n+this.rowsLimit-1),a=Math.min(s,r+this.columnsLimit-1);this.copyableRanges.length=0,this.copyableRanges.push({startRow:n,startCol:r,endRow:l,endCol:a}),this.copyableRanges=this.hot.runHooks("modifyCopyableRange",this.copyableRanges);this.textarea.setValue(this.getRangedCopyableData(this.copyableRanges)),i===l&&s===a||this.hot.runHooks("afterCopyLimit",i-n+1,s-r+1,this.rowsLimit,this.columnsLimit)}}},{key:"getRangedCopyableData",value:function(e){var t=this,o=[],n=[],r=[];return(0,w.arrayEach)(e,function(e){(0,C.rangeEach)(e.startRow,e.endRow,function(e){-1===n.indexOf(e)&&n.push(e)}),(0,C.rangeEach)(e.startCol,e.endCol,function(e){-1===r.indexOf(e)&&r.push(e)})}),(0,w.arrayEach)(n,function(e){var n=[];(0,w.arrayEach)(r,function(o){n.push(t.hot.getCopyableData(e,o))}),o.push(n)}),g.default.stringify(o)}},{key:"getRangedData",value:function(e){var t=this,o=[],n=[],r=[];return(0,w.arrayEach)(e,function(e){(0,C.rangeEach)(e.startRow,e.endRow,function(e){-1===n.indexOf(e)&&n.push(e)}),(0,C.rangeEach)(e.startCol,e.endCol,function(e){-1===r.indexOf(e)&&r.push(e)})}),(0,w.arrayEach)(n,function(e){var n=[];(0,w.arrayEach)(r,function(o){n.push(t.hot.getCopyableData(e,o))}),o.push(n)}),o}},{key:"copy",value:function(e){var t=this.getRangedData(this.copyableRanges);!this.hot.runHooks("beforeCopy",t,this.copyableRanges)?this.textarea.setValue(""):(this.textarea.setValue(g.default.stringify(t)),this.textarea.select(),e&&document.execCommand("copy"),this.hot.runHooks("afterCopy",t,this.copyableRanges))}},{key:"cut",value:function(e){var t=this.getRangedData(this.copyableRanges);!this.hot.runHooks("beforeCut",t,this.copyableRanges)?this.textarea.setValue(""):(this.textarea.setValue(g.default.stringify(t)),this.hot.selection.empty(),this.textarea.select(),e&&document.execCommand("cut"),this.hot.runHooks("afterCut",t,this.copyableRanges))}},{key:"paste",value:function(){this.textarea.setValue(arguments.length>0&&void 0!==arguments[0]?arguments[0]:""),this.onPaste(),this.onInput()}},{key:"registerEvents",value:function(){var e=this;this.eventManager.addEventListener(this.textarea.element,"paste",function(t){return e.onPaste(t)}),this.eventManager.addEventListener(this.textarea.element,"input",function(t){return e.onInput(t)})}},{key:"triggerPaste",value:function(){this.textarea.select(),this.onPaste()}},{key:"onPaste",value:function(){x.get(this).isTriggeredByPaste=!0}},{key:"onInput",value:function(){var e=this,t=x.get(this);if(this.hot.isListening()&&t.isTriggeredByPaste){t.isTriggeredByPaste=!1;var o=void 0,n=void 0,r=void 0,i=void 0,s=void 0,l=void 0,a=void 0,u=void 0,c=void 0,h=void 0;o=this.textarea.getValue(),n=g.default.parse(o);if(!!this.hot.runHooks("beforePaste",n,this.copyableRanges)){r=this.hot.getSelected(),i=new v.CellCoords(r[0],r[1]),s=new v.CellCoords(r[2],r[3]),l=new v.CellRange(i,i,s),a=l.getTopLeftCorner(),u=l.getBottomRightCorner(),c=a,h=new v.CellCoords(Math.max(u.row,n.length-1+a.row),Math.max(u.col,n[0].length-1+a.col));var d=s.row-i.row>=n.length-1,f=s.col-i.col>=n[0].length-1;this.hot.addHookOnce("afterChange",function(t,o){var n=t?t.length:0;if(n){var r={row:0,col:0},i=-1;(0,w.arrayEach)(t,function(e,o){var s=n>o+1?t[o+1]:null;s&&(d||(r.row+=Math.max(s[0]-e[0]-1,0)),!f&&e[1]>i&&(i=e[1],r.col+=Math.max(s[1]-e[1]-1,0)))}),e.hot.selectCell(c.row,c.col,h.row+r.row,h.col+r.col)}}),this.hot.populateFromArray(c.row,c.col,n,h.row,h.col,"CopyPaste.paste",this.pasteMode),this.hot.runHooks("afterPaste",n,this.copyableRanges)}}}},{key:"onAfterContextMenuDefaultOptions",value:function(e){e.items.push({name:"---------"},(0,k.default)(this),(0,_.default)(this))}},{key:"onBeforeKeyDown",value:function(e){var t=this;if(this.hot.getSelected()&&(!this.hot.getActiveEditor()||!this.hot.getActiveEditor().isOpened())&&!(0,b.isImmediatePropagationStopped)(e)&&(this.textarea.isActive()||!(0,y.getSelectionText)())){if((0,m.isCtrlKey)(e.keyCode)){if(this.hot.getSettings().fragmentSelection&&(0,y.getSelectionText)())return;return this.setCopyableText(),void(0,b.stopImmediatePropagation)(e)}(e.ctrlKey||e.metaKey)&&!e.altKey&&(e.keyCode==m.KEY_CODES.A&&setTimeout(function(){t.setCopyableText()},0),e.keyCode==m.KEY_CODES.X&&this.cut(),e.keyCode==m.KEY_CODES.C&&this.copy(),e.keyCode==m.KEY_CODES.V&&this.triggerPaste())}}},{key:"destroy",value:function(){this.textarea&&this.textarea.destroy(),u(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}}]),t}(h.default);(0,S.registerPlugin)("CopyPaste",D),t.default=D},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=function(){function e(){n(this,e),this.element=void 0,this.isAppended=!1,this.refCounter=0}return r(e,null,[{key:"getSingleton",value:function(){return s.append(),s}}]),r(e,[{key:"append",value:function(){this.hasBeenDestroyed()&&this.create(),this.refCounter++,!this.isAppended&&document.body&&document.body&&(this.isAppended=!0,document.body.appendChild(this.element))}},{key:"create",value:function(){this.element=document.createElement("textarea"),this.element.id="HandsontableCopyPaste",this.element.className="copyPaste",this.element.tabIndex=-1,this.element.autocomplete="off",this.element.wrap="off"}},{key:"deselect",value:function(){this.element===document.activeElement&&document.activeElement.blur()}},{key:"destroy",value:function(){this.refCounter--,this.refCounter=0>this.refCounter?0:this.refCounter,this.hasBeenDestroyed()&&this.element&&this.element.parentNode&&(this.element.parentNode.removeChild(this.element),this.element=null,this.isAppended=!1)}},{key:"getValue",value:function(){return this.element.value}},{key:"hasBeenDestroyed",value:function(){return 1>this.refCounter}},{key:"isActive",value:function(){return this.element===document.activeElement}},{key:"select",value:function(){this.element.focus(),this.element.select()}},{key:"setValue",value:function(e){this.element.value=e}}]),e}(),s=new i;t.default=i},function(e,t,o){"use strict";function n(){}var r,i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},s=o(8),l=function(e){return e&&e.__esModule?e:{default:e}}(s),a=(o(5),o(1)),u=o(11),c=function(e){return"boolean"==typeof e&&!0===e||"object"===(void 0===e?"undefined":i(e))&&e.length>0},h=function(){c(this.getSettings().customBorders)&&(this.customBorders||(r=this,this.customBorders=new n))},d=function(e){for(var t=0;r.view.wt.selections.length>t;t++)if(r.view.wt.selections[t].settings.className==e)return t;return-1},f=function(e){var t={row:e.row,col:e.col},o=new u.Selection(e,new u.CellRange(t,t,t)),n=d(e.className);0>n?r.view.wt.selections.push(o):r.view.wt.selections[n]=o},p=function(e,t,o){var n=C(e,t);n=b(n,o),this.setCellMeta(e,t,"borders",n),f(n)},g=function(e){for(var t=e.range,o=t.from.row;t.to.row>=o;o++)for(var n=t.from.col;t.to.col>=n;n++){var r=C(o,n),i=0;o==t.from.row&&(i++,(0,a.hasOwnProperty)(e,"top")&&(r.top=e.top)),o==t.to.row&&(i++,(0,a.hasOwnProperty)(e,"bottom")&&(r.bottom=e.bottom)),n==t.from.col&&(i++,(0,a.hasOwnProperty)(e,"left")&&(r.left=e.left)),n==t.to.col&&(i++,(0,a.hasOwnProperty)(e,"right")&&(r.right=e.right)),i>0&&(this.setCellMeta(o,n,"borders",r),f(r))}},v=function(e,t){return"border_row"+e+"col"+t},m=function(){return{width:1,color:"#000"}},y=function(){return{hide:!0}},w=function(){return{width:1,color:"#000",cornerVisible:!1}},C=function(e,t){return{className:v(e,t),border:w(),row:e,col:t,top:y(),right:y(),bottom:y(),left:y()}},b=function(e,t){return(0,a.hasOwnProperty)(t,"border")&&(e.border=t.border),(0,a.hasOwnProperty)(t,"top")&&(e.top=t.top),(0,a.hasOwnProperty)(t,"right")&&(e.right=t.right),(0,a.hasOwnProperty)(t,"bottom")&&(e.bottom=t.bottom),(0,a.hasOwnProperty)(t,"left")&&(e.left=t.left),e},S=function(e){for(var t=document.querySelectorAll("."+e),o=0;t.length>o;o++)if(t[o]&&"TD"!=t[o].nodeName){var n=t[o].parentNode;n.parentNode&&n.parentNode.removeChild(n)}},E=function(e,t){var o=v(e,t);S(o),this.removeCellMeta(e,t,"borders")},R=function(e,t,o,n){var r=this.getCellMeta(e,t).borders;r&&void 0!=r.border||(r=C(e,t)),r[o]=n?y():m(),this.setCellMeta(e,t,"borders",r);var i=v(e,t);S(i),f(r),this.render()},O=function(e,t,o){if(e.from.row==e.to.row&&e.from.col==e.to.col)"noBorders"==t?E.call(this,e.from.row,e.from.col):R.call(this,e.from.row,e.from.col,t,o);else switch(t){case"noBorders":for(var n=e.from.col;e.to.col>=n;n++)for(var r=e.from.row;e.to.row>=r;r++)E.call(this,r,n);break;case"top":for(var i=e.from.col;e.to.col>=i;i++)R.call(this,e.from.row,i,t,o);break;case"right":for(var s=e.from.row;e.to.row>=s;s++)R.call(this,s,e.to.col,t);break;case"bottom":for(var l=e.from.col;e.to.col>=l;l++)R.call(this,e.to.row,l,t);break;case"left":for(var a=e.from.row;e.to.row>=a;a++)R.call(this,a,e.from.col,t)}},k=function(e,t){var o=!1;return e.getSelectedRange().forAll(function(n,r){var i=e.getCellMeta(n,r).borders;if(i){if(!t)return o=!0,!1;if(!(0,a.hasOwnProperty)(i[t],"hide"))return o=!0,!1}}),o},T=function(e){return'<span class="selected">'+String.fromCharCode(10003)+"</span>"+e},_=function(e){this.getSettings().customBorders&&(e.items.push({name:"---------"}),e.items.push({key:"borders",name:"Borders",disabled:function(){return this.selection.selectedHeader.corner},submenu:{items:[{key:"borders:top",name:function(){var e="Top";return k(this,"top")&&(e=T(e)),e},callback:function(){var e=k(this,"top");O.call(this,this.getSelectedRange(),"top",e)}},{key:"borders:right",name:function(){var e="Right";return k(this,"right")&&(e=T(e)),e},callback:function(){var e=k(this,"right");O.call(this,this.getSelectedRange(),"right",e)}},{key:"borders:bottom",name:function(){var e="Bottom";return k(this,"bottom")&&(e=T(e)),e},callback:function(){var e=k(this,"bottom");O.call(this,this.getSelectedRange(),"bottom",e)}},{key:"borders:left",name:function(){var e="Left";return k(this,"left")&&(e=T(e)),e},callback:function(){var e=k(this,"left");O.call(this,this.getSelectedRange(),"left",e)}},{key:"borders:no_borders",name:"Remove border(s)",callback:function(){O.call(this,this.getSelectedRange(),"noBorders")},disabled:function(){return!k(this)}}]}}))};l.default.getSingleton().add("beforeInit",h),l.default.getSingleton().add("afterContextMenuDefaultOptions",_),l.default.getSingleton().add("afterInit",function(){var e=this.getSettings().customBorders;if(e){for(var t=0;e.length>t;t++)e[t].range?g.call(this,e[t]):p.call(this,e[t].row,e[t].col,e[t]);this.render(),this.view.wt.draw(!0)}})},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(){this.boundaries=null,this.callback=null}t.__esModule=!0;var i=o(8),s=n(i),l=o(4),a=n(l);o(5);r.prototype.setBoundaries=function(e){this.boundaries=e},r.prototype.setCallback=function(e){this.callback=e},r.prototype.check=function(e,t){var o=0,n=0;this.boundaries.top>t?n=t-this.boundaries.top:t>this.boundaries.bottom&&(n=t-this.boundaries.bottom),this.boundaries.left>e?o=e-this.boundaries.left:e>this.boundaries.right&&(o=e-this.boundaries.right),this.callback(o,n)};var u,c=function(e){e.dragToScrollListening=!1;var t=e.view.wt.wtTable.holder;u=new r,t!==window&&(u.setBoundaries(t.getBoundingClientRect()),u.setCallback(function(e,o){0>e?t.scrollLeft-=50:e>0&&(t.scrollLeft+=50),0>o?t.scrollTop-=20:o>0&&(t.scrollTop+=20)}),e.dragToScrollListening=!0)};s.default.getSingleton().add("afterInit",function(){var e=this,t=new a.default(this);t.addEventListener(document,"mouseup",function(){e.dragToScrollListening=!1}),t.addEventListener(document,"mousemove",function(t){e.dragToScrollListening&&u.check(t.clientX,t.clientY)})}),s.default.getSingleton().add("afterDestroy",function(){new a.default(this).clear()}),s.default.getSingleton().add("afterOnCellMouseDown",function(){c(this)}),s.default.getSingleton().add("afterOnCellCornerMouseDown",function(){c(this)}),t.default=r},function(e,t,o){"use strict";function n(e){return{key:"freeze_column",name:"Freeze this column",callback:function(){var t=this.getSelectedRange().from.col;e.freezeColumn(t),this.render(),this.view.wt.wtOverlays.adjustElementsSize(!0)},hidden:function(){var e=this.getSelectedRange(),t=!1;return void 0===e?t=!0:e.from.col===e.to.col&&e.from.col>this.getSettings().fixedColumnsLeft-1||(t=!0),t}}}t.__esModule=!0,t.default=n},function(e,t,o){"use strict";function n(e){return{key:"unfreeze_column",name:"Unfreeze this column",callback:function(){var t=this.getSelectedRange().from.col;e.unfreezeColumn(t),this.render(),this.view.wt.wtOverlays.adjustElementsSize(!0)},hidden:function(){var e=this.getSelectedRange(),t=!1;return void 0===e?t=!0:e.from.col===e.to.col&&e.from.col<this.getSettings().fixedColumnsLeft||(t=!0),t}}}t.__esModule=!0,t.default=n},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var l=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),a=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},u=o(12),c=n(u),h=o(5),d=o(2),f=o(242),p=n(f),g=o(243),v=n(g);o(301);var m=new WeakMap,y=function(e){function t(e){r(this,t);var o=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return m.set(o,{moveByFreeze:!1,afterFirstUse:!1}),o.frozenColumnsBasePositions=[],o.manualColumnMovePlugin=void 0,o}return s(t,e),l(t,[{key:"isEnabled",value:function(){return!!this.hot.getSettings().manualColumnFreeze}},{key:"enablePlugin",value:function(){var e=this;this.enabled||(this.addHook("afterContextMenuDefaultOptions",function(t){return e.addContextMenuEntry(t)}),this.addHook("afterInit",function(){return e.onAfterInit()}),this.addHook("beforeColumnMove",function(t,o){return e.onBeforeColumnMove(t,o)}),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{key:"disablePlugin",value:function(){var e=m.get(this);e.afterFirstUse=!1,e.moveByFreeze=!1,a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"updatePlugin",value:function(){this.disablePlugin(),this.enablePlugin(),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"updatePlugin",this).call(this)}},{key:"freezeColumn",value:function(e){var t=m.get(this),o=this.hot.getSettings();t.afterFirstUse||(t.afterFirstUse=!0),o.fixedColumnsLeft!==this.hot.countCols()&&e>o.fixedColumnsLeft-1&&(t.moveByFreeze=!0,e!==this.getMovePlugin().columnsMapper.getValueByIndex(e)&&(this.frozenColumnsBasePositions[o.fixedColumnsLeft]=e),this.getMovePlugin().moveColumn(e,o.fixedColumnsLeft++))}},{key:"unfreezeColumn",value:function(e){var t=m.get(this),o=this.hot.getSettings();if(t.afterFirstUse||(t.afterFirstUse=!0),o.fixedColumnsLeft>0&&o.fixedColumnsLeft-1>=e){var n=this.getBestColumnReturnPosition(e);t.moveByFreeze=!0,o.fixedColumnsLeft--,this.getMovePlugin().moveColumn(e,n+1)}}},{key:"getMovePlugin",value:function(){return this.manualColumnMovePlugin||(this.manualColumnMovePlugin=this.hot.getPlugin("manualColumnMove")),this.manualColumnMovePlugin}},{key:"getBestColumnReturnPosition",value:function(e){var t=this.getMovePlugin(),o=this.hot.getSettings(),n=o.fixedColumnsLeft,r=t.columnsMapper.getValueByIndex(n),i=void 0;if(null==this.frozenColumnsBasePositions[e])for(i=t.columnsMapper.getValueByIndex(e);i>r;)n++,r=t.columnsMapper.getValueByIndex(n);else{for(i=this.frozenColumnsBasePositions[e],this.frozenColumnsBasePositions[e]=void 0;i>=r;)n++,r=t.columnsMapper.getValueByIndex(n);n=r}return n-1}},{key:"addContextMenuEntry",value:function(e){e.items.push({name:"---------"},(0,p.default)(this),(0,v.default)(this))}},{key:"onAfterInit",value:function(){this.getMovePlugin().isEnabled()||this.getMovePlugin().enablePlugin()}},{key:"onBeforeColumnMove",value:function(e,t){var o=m.get(this);if(o.afterFirstUse&&!o.moveByFreeze){var n=this.hot.getSettings().fixedColumnsLeft,r=n>t;if(r||(0,d.arrayEach)(e,function(e,t,o){if(n>e)return r=!0,!1}),r)return!1}o.moveByFreeze&&(o.moveByFreeze=!1)}},{key:"destroy",value:function(){a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}}]),t}(c.default);(0,h.registerPlugin)("manualColumnFreeze",y),t.default=y},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=o(151),s=function(e){return e&&e.__esModule?e:{default:e}}(i),l=o(2),a=o(1),u=o(6),c=function(){function e(t){n(this,e),this.manualColumnMove=t}return r(e,[{key:"createMap",value:function(e){var t=this,o=void 0===e?this._arrayMap.length:e;this._arrayMap.length=0,(0,u.rangeEach)(o-1,function(e){t._arrayMap[e]=e})}},{key:"destroy",value:function(){this._arrayMap=null}},{key:"moveColumn",value:function(e,t){var o=this._arrayMap[e];this._arrayMap[e]=null,this._arrayMap.splice(t,0,o)}},{key:"clearNull",value:function(){this._arrayMap=(0,l.arrayFilter)(this._arrayMap,function(e){return null!==e})}}]),e}();(0,a.mixin)(c,s.default),t.default=c},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var l=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),a=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},u=o(12),c=n(u),h=o(8),d=n(h),f=o(2),p=o(0),g=o(6),v=o(4),m=n(v),y=o(5),w=o(245),C=n(w),b=o(247),S=n(b),E=o(248),R=n(E),O=o(11);o(302),d.default.getSingleton().register("beforeColumnMove"),d.default.getSingleton().register("afterColumnMove"),d.default.getSingleton().register("unmodifyCol");var k=new WeakMap,T=function(e){function t(e){r(this,t);var o=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return k.set(o,{columnsToMove:[],countCols:0,fixedColumns:0,pressed:void 0,disallowMoving:void 0,target:{eventPageX:void 0,coords:void 0,TD:void 0,col:void 0}}),o.removedColumns=[],o.columnsMapper=new C.default(o),o.eventManager=new m.default(o),o.backlight=new S.default(e),o.guideline=new R.default(e),o}return s(t,e),l(t,[{key:"isEnabled",value:function(){return!!this.hot.getSettings().manualColumnMove}},{key:"enablePlugin",value:function(){var e=this;this.enabled||(this.addHook("beforeOnCellMouseDown",function(t,o,n,r){return e.onBeforeOnCellMouseDown(t,o,n,r)}),this.addHook("beforeOnCellMouseOver",function(t,o,n,r){return e.onBeforeOnCellMouseOver(t,o,n,r)}),this.addHook("afterScrollVertically",function(){return e.onAfterScrollVertically()}),this.addHook("modifyCol",function(t,o){return e.onModifyCol(t,o)}),this.addHook("beforeRemoveCol",function(t,o){return e.onBeforeRemoveCol(t,o)}),this.addHook("afterRemoveCol",function(t,o){return e.onAfterRemoveCol(t,o)}),this.addHook("afterCreateCol",function(t,o){return e.onAfterCreateCol(t,o)}),this.addHook("afterLoadData",function(t){return e.onAfterLoadData(t)}),this.addHook("unmodifyCol",function(t){return e.onUnmodifyCol(t)}),this.registerEvents(),(0,p.addClass)(this.hot.rootElement,"ht__manualColumnMove"),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{key:"updatePlugin",value:function(){this.disablePlugin(),this.enablePlugin(),this.onAfterPluginsInitialized(),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"updatePlugin",this).call(this)}},{key:"disablePlugin",value:function(){var e=this.hot.getSettings().manualColumnMove;Array.isArray(e)&&this.columnsMapper.clearMap(),(0,p.removeClass)(this.hot.rootElement,"ht__manualColumnMove"),this.unregisterEvents(),this.backlight.destroy(),this.guideline.destroy(),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"moveColumn",value:function(e,t){this.moveColumns([e],t)}},{key:"moveColumns",value:function(e,t){var o=this,n=k.get(this),r=this.hot.runHooks("beforeColumnMove",e,t);n.disallowMoving=!r,!1!==r&&((0,f.arrayEach)(e,function(e,t,n){n[t]=o.columnsMapper.getValueByIndex(e)}),(0,f.arrayEach)(e,function(e,n){var r=o.columnsMapper.getIndexByValue(e);r!==t&&o.columnsMapper.moveColumn(r,t+n)}),this.columnsMapper.clearNull()),this.hot.runHooks("afterColumnMove",e,t)}},{key:"changeSelection",value:function(e,t){var o=this.hot.selection,n=this.hot.countRows()-1;o.setRangeStartOnly(new O.CellCoords(0,e)),o.setRangeEnd(new O.CellCoords(n,t),!1)}},{key:"getColumnsWidth",value:function(e,t){for(var o=0,n=e;t>n;n++){var r=0;r=0>n?this.hot.view.wt.wtTable.getColumnWidth(n)||0:this.hot.view.wt.wtTable.getStretchedColumnWidth(n)||0,o+=r}return o}},{key:"initialSettings",value:function(){var e=this.hot.getSettings().manualColumnMove;Array.isArray(e)?this.moveColumns(e,0):void 0!==e&&this.persistentStateLoad()}},{key:"isFixedColumnsLeft",value:function(e){return e<this.hot.getSettings().fixedColumnsLeft}},{key:"persistentStateSave",value:function(){this.hot.runHooks("persistentStateSave","manualColumnMove",this.columnsMapper._arrayMap)}},{key:"persistentStateLoad",value:function(){var e={};this.hot.runHooks("persistentStateLoad","manualColumnMove",e),e.value&&(this.columnsMapper._arrayMap=e.value)}},{key:"prepareColumnsToMoving",value:function(e,t){var o=[];return(0,g.rangeEach)(e,t,function(e){o.push(e)}),o}},{key:"refreshPositions",value:function(){var e=k.get(this),t=this.hot.view.wt.wtTable.getFirstVisibleColumn(),o=this.hot.view.wt.wtTable.getLastVisibleColumn(),n=this.hot.view.wt.wtTable,r=this.hot.view.wt.wtOverlays.scrollableElement,i="number"==typeof r.scrollX?r.scrollX:r.scrollLeft,s=this.hot.view.THEAD.offsetLeft+this.getColumnsWidth(0,e.coordsColumn),l=e.target.eventPageX-(e.rootElementOffset-(void 0===r.scrollX?i:0)),a=n.hider.offsetWidth,u=n.TBODY.offsetLeft,c=this.backlight.getOffset().left,h=this.backlight.getSize().width,d=0;if(e.target.eventPageX>e.rootElementOffset+n.holder.offsetWidth+i&&e.countCols>e.coordsColumn&&e.coordsColumn++,e.hasRowHeaders&&(d=this.hot.view.wt.wtOverlays.leftOverlay.clone.wtTable.getColumnHeader(-1).offsetWidth),this.isFixedColumnsLeft(e.coordsColumn)&&(s+=i),s+=d,0>e.coordsColumn)e.target.col=e.fixedColumns>0?0:t>0?t-1:t;else if(l<e.target.TD.offsetWidth/2+s)(e.target.col=e.coordsColumn)>t||e.fixedColumns>e.target.col||this.hot.scrollViewportTo(void 0,t-1);else{var f=e.countCols>e.coordsColumn?e.coordsColumn:e.countCols-1;e.target.col=f+1,s+=e.target.TD.offsetWidth,e.target.col>o&&this.hot.scrollViewportTo(void 0,o+1,void 0,!0)}e.target.col>t||e.fixedColumns>e.target.col||this.hot.scrollViewportTo(void 0,t-1);var p=l,g=s;a>l+h+c?u+d>l+c&&(p=u+d+Math.abs(c)):p=a-h-c,a-1>s?0===g?g=1:void 0!==r.scrollX&&e.fixedColumns>e.coordsColumn&&(g-=e.rootElementOffset>r.scrollX?0:e.rootElementOffset):g=a-1,this.backlight.setPosition(null,p),this.guideline.setPosition(null,g)}},{key:"updateColumnsMapper",value:function(){var e=this.hot.countSourceCols(),t=this.columnsMapper._arrayMap.length;if(0===t)this.columnsMapper.createMap(e||this.hot.getSettings().startCols);else if(e>t){var o=e-t;this.columnsMapper.insertItems(t,o)}else if(t>e){var n=e-1,r=[];(0,f.arrayEach)(this.columnsMapper._arrayMap,function(e,t,o){e>n&&r.push(t)}),this.columnsMapper.removeItems(r)}}},{key:"registerEvents",value:function(){var e=this;this.eventManager.addEventListener(document.documentElement,"mousemove",function(t){return e.onMouseMove(t)}),this.eventManager.addEventListener(document.documentElement,"mouseup",function(){return e.onMouseUp()})}},{key:"unregisterEvents",value:function(){this.eventManager.clear()}},{key:"onBeforeOnCellMouseDown",value:function(e,t,o,n){var r=this.hot.view.wt.wtTable,i=this.hot.selection.selectedHeader.cols,s=this.hot.getSelectedRange(),l=k.get(this),a=e.realTarget.className.indexOf("columnSorting")>-1;if(!s||!i||l.pressed||0!==e.button||a)return l.pressed=!1,l.columnsToMove.length=0,void(0,p.removeClass)(this.hot.rootElement,["on-moving--columns","show-ui"]);var u=this.guideline.isBuilt()&&!this.guideline.isAppended(),c=this.backlight.isBuilt()&&!this.backlight.isAppended();u&&c&&(this.guideline.appendTo(r.hider),this.backlight.appendTo(r.hider));var h=s.from,d=s.to,f=Math.min(h.col,d.col),g=Math.max(h.col,d.col);if(0<=t.row||t.col<f||g<t.col)(0,p.removeClass)(this.hot.rootElement,"after-selection--columns"),l.pressed=!1,l.columnsToMove.length=0;else{n.column=!0,l.pressed=!0,l.target.eventPageX=e.pageX,l.coordsColumn=t.col,l.target.TD=o,l.target.col=t.col,l.columnsToMove=this.prepareColumnsToMoving(f,g),l.hasRowHeaders=!!this.hot.getSettings().rowHeaders,l.countCols=this.hot.countCols(),l.fixedColumns=this.hot.getSettings().fixedColumnsLeft,l.rootElementOffset=(0,p.offset)(this.hot.rootElement).left;var v=l.hasRowHeaders?-1:0,m=r.holder.scrollTop+r.getColumnHeaderHeight(0)+1,y=l.fixedColumns>t.col,w=this.hot.view.wt.wtOverlays.scrollableElement,C=w.scrollX?w.scrollX-l.rootElementOffset:0,b=e.layerX-(y?C:0),S=Math.abs(this.getColumnsWidth(f,t.col)+b);this.backlight.setPosition(m,this.getColumnsWidth(v,f)+S),this.backlight.setSize(this.getColumnsWidth(f,g+1),r.hider.offsetHeight-m),this.backlight.setOffset(null,-1*S),(0,p.addClass)(this.hot.rootElement,"on-moving--columns")}}},{key:"onMouseMove",value:function(e){var t=k.get(this);if(t.pressed){if(e.realTarget===this.backlight.element){var o=this.backlight.getSize().width;this.backlight.setSize(0),setTimeout(function(){this.backlight.setPosition(o)})}t.target.eventPageX=e.pageX,this.refreshPositions()}}},{key:"onBeforeOnCellMouseOver",value:function(e,t,o,n){var r=this.hot.getSelectedRange(),i=k.get(this);r&&i.pressed&&(i.columnsToMove.indexOf(t.col)>-1?(0,p.removeClass)(this.hot.rootElement,"show-ui"):(0,p.addClass)(this.hot.rootElement,"show-ui"),n.row=!0,n.column=!0,n.cell=!0,i.coordsColumn=t.col,i.target.TD=o)}},{key:"onMouseUp",value:function(){var e=k.get(this);if(e.coordsColumn=void 0,e.pressed=!1,e.backlightWidth=0,(0,p.removeClass)(this.hot.rootElement,["on-moving--columns","show-ui","after-selection--columns"]),this.hot.selection.selectedHeader.cols&&(0,p.addClass)(this.hot.rootElement,"after-selection--columns"),e.columnsToMove.length>=1&&void 0!==e.target.col&&-1>=e.columnsToMove.indexOf(e.target.col)){if(this.moveColumns(e.columnsToMove,e.target.col),this.persistentStateSave(),this.hot.render(),this.hot.view.wt.wtOverlays.adjustElementsSize(!0),!e.disallowMoving){this.changeSelection(this.columnsMapper.getIndexByValue(e.columnsToMove[0]),this.columnsMapper.getIndexByValue(e.columnsToMove[e.columnsToMove.length-1]))}e.columnsToMove.length=0}}},{key:"onAfterScrollVertically",value:function(){var e=this.hot.view.wt.wtTable,t=e.getColumnHeaderHeight(0)+1,o=e.holder.scrollTop,n=t+o;this.backlight.setPosition(n),this.backlight.setSize(null,e.hider.offsetHeight-n)}},{key:"onAfterCreateCol",value:function(e,t){this.columnsMapper.shiftItems(e,t)}},{key:"onBeforeRemoveCol",value:function(e,t){var o=this;this.removedColumns.length=0,!1!==e&&(0,g.rangeEach)(e,e+t-1,function(e){o.removedColumns.push(o.hot.runHooks("modifyCol",e,o.pluginName))})}},{key:"onAfterRemoveCol",value:function(e,t){this.columnsMapper.unshiftItems(this.removedColumns)}},{key:"onAfterLoadData",value:function(e){this.updateColumnsMapper()}},{key:"onModifyCol",value:function(e,t){if(t!==this.pluginName){var o=this.columnsMapper.getValueByIndex(e);e=null===o?e:o}return e}},{key:"onUnmodifyCol",value:function(e){var t=this.columnsMapper.getIndexByValue(e);return null===t?e:t}},{key:"onAfterPluginsInitialized",value:function(){this.updateColumnsMapper(),this.initialSettings(),this.backlight.build(),this.guideline.build()}},{key:"destroy",value:function(){this.backlight.destroy(),this.guideline.destroy(),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}}]),t}(c.default);(0,y.registerPlugin)("ManualColumnMove",T),t.default=T},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var s=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),l=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},a=o(152),u=function(e){return e&&e.__esModule?e:{default:e}}(a),c=o(0);t.default=function(e){function t(){return n(this,t),r(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return i(t,e),s(t,[{key:"build",value:function(){l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"build",this).call(this),(0,c.addClass)(this._element,"ht__manualColumnMove--backlight")}}]),t}(u.default)},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var s=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),l=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},a=o(152),u=function(e){return e&&e.__esModule?e:{default:e}}(a),c=o(0);t.default=function(e){function t(){return n(this,t),r(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return i(t,e),s(t,[{key:"build",value:function(){l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"build",this).call(this),(0,c.addClass)(this._element,"ht__manualColumnMove--guideline")}}]),t}(u.default)},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var l=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),a=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},u=o(12),c=n(u),h=o(0),d=o(4),f=n(d),p=o(7),g=o(2),v=o(6),m=o(5),y=function(e){function t(e){r(this,t);var o=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.currentTH=null,o.currentCol=null,o.selectedCols=[],o.currentWidth=null,o.newSize=null,o.startY=null,o.startWidth=null,o.startOffset=null,o.handle=document.createElement("DIV"),o.guide=document.createElement("DIV"),o.eventManager=new f.default(o),o.pressed=null,o.dblclick=0,o.autoresizeTimeout=null,o.manualColumnWidths=[],(0,h.addClass)(o.handle,"manualColumnResizer"),(0,h.addClass)(o.guide,"manualColumnResizerGuide"),o}return s(t,e),l(t,[{key:"isEnabled",value:function(){return this.hot.getSettings().manualColumnResize}},{key:"enablePlugin",value:function(){var e=this;if(!this.enabled){this.manualColumnWidths=[];var o=this.hot.getSettings().manualColumnResize,n=this.loadManualColumnWidths();this.addHook("modifyColWidth",function(t,o){return e.onModifyColWidth(t,o)}),this.addHook("beforeStretchingColumnWidth",function(t,o){return e.onBeforeStretchingColumnWidth(t,o)}),this.addHook("beforeColumnResize",function(t,o,n){return e.onBeforeColumnResize(t,o,n)}),this.manualColumnWidths=void 0!==n?n:Array.isArray(o)?o:[],this.bindEvents(),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this)}}},{key:"updatePlugin",value:function(){var e=this.hot.getSettings().manualColumnResize;Array.isArray(e)?this.manualColumnWidths=e:e||(this.manualColumnWidths=[])}},{key:"disablePlugin",value:function(){a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"saveManualColumnWidths",value:function(){this.hot.runHooks("persistentStateSave","manualColumnWidths",this.manualColumnWidths)}},{key:"loadManualColumnWidths",value:function(){var e={};return this.hot.runHooks("persistentStateLoad","manualColumnWidths",e),e.value}},{key:"setupHandlePosition",value:function(e){var t=this;if(!e.parentNode)return!1;this.currentTH=e;var o=this.hot.view.wt.wtTable.getCoords(e).col,n=(0,h.outerHeight)(this.currentTH);if(o>=0){var r=this.currentTH.getBoundingClientRect();if(this.currentCol=o,this.selectedCols=[],this.hot.selection.isSelected()&&this.hot.selection.selectedHeader.cols){var i=this.hot.getSelectedRange(),s=i.from,l=i.to,a=s.col,u=l.col;u>a||(a=l.col,u=s.col),a>this.currentCol||this.currentCol>u?this.selectedCols.push(this.currentCol):(0,v.rangeEach)(a,u,function(e){return t.selectedCols.push(e)})}else this.selectedCols.push(this.currentCol);this.startOffset=r.left-6,this.startWidth=parseInt(r.width,10),this.handle.style.top=r.top+"px",this.handle.style.left=this.startOffset+this.startWidth+"px",this.handle.style.height=n+"px",this.hot.rootElement.appendChild(this.handle)}}},{key:"refreshHandlePosition",value:function(){this.handle.style.left=this.startOffset+this.currentWidth+"px"}},{key:"setupGuidePosition",value:function(){var e=parseInt((0,h.outerHeight)(this.handle),10),t=parseInt(this.handle.style.top,10)+e,o=parseInt(this.hot.view.maximumVisibleElementHeight(0),10);(0,h.addClass)(this.handle,"active"),(0,h.addClass)(this.guide,"active"),this.guide.style.top=t+"px",this.guide.style.left=this.handle.style.left,this.guide.style.height=o-e+"px",this.hot.rootElement.appendChild(this.guide)}},{key:"refreshGuidePosition",value:function(){this.guide.style.left=this.handle.style.left}},{key:"hideHandleAndGuide",value:function(){(0,h.removeClass)(this.handle,"active"),(0,h.removeClass)(this.guide,"active")}},{key:"checkIfColumnHeader",value:function(e){if(e!=this.hot.rootElement){var t=e.parentNode;return"THEAD"===t.tagName||this.checkIfColumnHeader(t)}return!1}},{key:"getTHFromTargetElement",value:function(e){return"TABLE"!=e.tagName?"TH"==e.tagName?e:this.getTHFromTargetElement(e.parentNode):null}},{key:"onMouseOver",value:function(e){if(this.checkIfColumnHeader(e.target)){var t=this.getTHFromTargetElement(e.target);if(!t)return;var o=t.getAttribute("colspan");!t||null!==o&&1!==o||this.pressed||this.setupHandlePosition(t)}}},{key:"afterMouseDownTimeout",value:function(){var e=this,t=function(){e.hot.forceFullRender=!0,e.hot.view.render(),e.hot.view.wt.wtOverlays.adjustElementsSize(!0)},o=function(o,n){var r=e.hot.runHooks("beforeColumnResize",o,e.newSize,!0);void 0!==r&&(e.newSize=r),"all"===e.hot.getSettings().stretchH?e.clearManualSize(o):e.setManualSize(o,e.newSize),n&&t(),e.saveManualColumnWidths(),e.hot.runHooks("afterColumnResize",o,e.newSize,!0)};if(this.dblclick>=2){this.selectedCols.length>1?((0,g.arrayEach)(this.selectedCols,function(e){o(e)}),t()):(0,g.arrayEach)(this.selectedCols,function(e){o(e,!0)})}this.dblclick=0,this.autoresizeTimeout=null}},{key:"onMouseDown",value:function(e){var t=this;(0,h.hasClass)(e.target,"manualColumnResizer")&&(this.setupGuidePosition(),this.pressed=this.hot,null===this.autoresizeTimeout&&(this.autoresizeTimeout=setTimeout(function(){return t.afterMouseDownTimeout()},500),this.hot._registerTimeout(this.autoresizeTimeout)),this.dblclick++,this.startX=(0,p.pageX)(e),this.newSize=this.startWidth)}},{key:"onMouseMove",value:function(e){var t=this;this.pressed&&(this.currentWidth=this.startWidth+((0,p.pageX)(e)-this.startX),(0,g.arrayEach)(this.selectedCols,function(e){t.newSize=t.setManualSize(e,t.currentWidth)}),this.refreshHandlePosition(),this.refreshGuidePosition())}},{key:"onMouseUp",value:function(e){var t=this,o=function(){t.hot.forceFullRender=!0,t.hot.view.render(),t.hot.view.wt.wtOverlays.adjustElementsSize(!0)},n=function(e,n){t.hot.runHooks("beforeColumnResize",e,t.newSize),n&&o(),t.saveManualColumnWidths(),t.hot.runHooks("afterColumnResize",e,t.newSize)};if(this.pressed){if(this.hideHandleAndGuide(),this.pressed=!1,this.newSize!=this.startWidth){this.selectedCols.length>1?((0,g.arrayEach)(this.selectedCols,function(e){n(e)}),o()):(0,g.arrayEach)(this.selectedCols,function(e){n(e,!0)})}this.setupHandlePosition(this.currentTH)}}},{key:"bindEvents",value:function(){var e=this;this.eventManager.addEventListener(this.hot.rootElement,"mouseover",function(t){return e.onMouseOver(t)}),this.eventManager.addEventListener(this.hot.rootElement,"mousedown",function(t){return e.onMouseDown(t)}),this.eventManager.addEventListener(window,"mousemove",function(t){return e.onMouseMove(t)}),this.eventManager.addEventListener(window,"mouseup",function(t){return e.onMouseUp(t)})}},{key:"setManualSize",value:function(e,t){return t=Math.max(t,20),e=this.hot.runHooks("modifyCol",e),this.manualColumnWidths[e]=t,t}},{key:"clearManualSize",value:function(e){e=this.hot.runHooks("modifyCol",e),this.manualColumnWidths[e]=void 0}},{key:"onModifyColWidth",value:function(e,t){return this.enabled&&(t=this.hot.runHooks("modifyCol",t),this.hot.getSettings().manualColumnResize&&this.manualColumnWidths[t])?this.manualColumnWidths[t]:e}},{key:"onBeforeStretchingColumnWidth",value:function(e,t){var o=this.manualColumnWidths[t];return void 0===o&&(o=e),o}},{key:"onBeforeColumnResize",value:function(){this.hot.view.wt.wtViewport.hasOversizedColumnHeadersMarked={}}}]),t}(c.default);(0,m.registerPlugin)("manualColumnResize",y),t.default=y},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var l=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),a=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},u=o(12),c=n(u),h=o(8),d=n(h),f=o(2),p=o(0),g=o(6),v=o(4),m=n(v),y=o(5),w=o(251),C=n(w),b=o(252),S=n(b),E=o(253),R=n(E),O=o(11);o(303),d.default.getSingleton().register("beforeRowMove"),d.default.getSingleton().register("afterRowMove"),d.default.getSingleton().register("unmodifyRow");var k=new WeakMap,T=function(e){function t(e){r(this,t);var o=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return k.set(o,{rowsToMove:[],pressed:void 0,disallowMoving:void 0,target:{eventPageY:void 0,coords:void 0,TD:void 0,row:void 0}}),o.removedRows=[],o.rowsMapper=new C.default(o),o.eventManager=new m.default(o),o.backlight=new S.default(e),o.guideline=new R.default(e),o}return s(t,e),l(t,[{key:"isEnabled",value:function(){return!!this.hot.getSettings().manualRowMove}},{key:"enablePlugin",value:function(){var e=this;this.enabled||(this.addHook("beforeOnCellMouseDown",function(t,o,n,r){return e.onBeforeOnCellMouseDown(t,o,n,r)}),this.addHook("beforeOnCellMouseOver",function(t,o,n,r){return e.onBeforeOnCellMouseOver(t,o,n,r)}),this.addHook("afterScrollHorizontally",function(){return e.onAfterScrollHorizontally()}),this.addHook("modifyRow",function(t,o){return e.onModifyRow(t,o)}),this.addHook("beforeRemoveRow",function(t,o){return e.onBeforeRemoveRow(t,o)}),this.addHook("afterRemoveRow",function(t,o){return e.onAfterRemoveRow(t,o)}),this.addHook("afterCreateRow",function(t,o){return e.onAfterCreateRow(t,o)}),this.addHook("afterLoadData",function(t){return e.onAfterLoadData(t)}),this.addHook("beforeColumnSort",function(t,o){return e.onBeforeColumnSort(t,o)}),this.addHook("unmodifyRow",function(t){return e.onUnmodifyRow(t)}),this.registerEvents(),(0,p.addClass)(this.hot.rootElement,"ht__manualRowMove"),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{key:"updatePlugin",value:function(){this.disablePlugin(),this.enablePlugin(),this.onAfterPluginsInitialized(),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"updatePlugin",this).call(this)}},{key:"disablePlugin",value:function(){var e=this.hot.getSettings().manualRowMove;Array.isArray(e)&&this.rowsMapper.clearMap(),(0,p.removeClass)(this.hot.rootElement,"ht__manualRowMove"),this.unregisterEvents(),this.backlight.destroy(),this.guideline.destroy(),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"moveRow",value:function(e,t){this.moveRows([e],t)}},{key:"moveRows",value:function(e,t){var o=this,n=k.get(this);n.disallowMoving=!1===this.hot.runHooks("beforeRowMove",e,t),n.disallowMoving||((0,f.arrayEach)(e,function(e,t,n){n[t]=o.rowsMapper.getValueByIndex(e)}),(0,f.arrayEach)(e,function(e,n){var r=o.rowsMapper.getIndexByValue(e);r!==t&&o.rowsMapper.moveRow(r,t+n)}),this.rowsMapper.clearNull()),this.hot.runHooks("afterRowMove",e,t)}},{key:"changeSelection",value:function(e,t){var o=this.hot.selection,n=this.hot.countCols()-1;o.setRangeStartOnly(new O.CellCoords(e,0)),o.setRangeEnd(new O.CellCoords(t,n),!1)}},{key:"getRowsHeight",value:function(e,t){for(var o=0,n=e;t>n;n++){o+=this.hot.view.wt.wtTable.getRowHeight(n)||23}return o}},{key:"initialSettings",value:function(){var e=this.hot.getSettings().manualRowMove;if(Array.isArray(e))this.moveRows(e,0);else if(void 0!==e){var t=this.persistentStateLoad();t.length&&this.moveRows(t,0)}}},{key:"isFixedRowTop",value:function(e){return e<this.hot.getSettings().fixedRowsTop}},{key:"isFixedRowBottom",value:function(e){return e>this.hot.getSettings().fixedRowsBottom}},{key:"persistentStateSave",value:function(){this.hot.runHooks("persistentStateSave","manualRowMove",this.rowsMapper._arrayMap)}},{key:"persistentStateLoad",value:function(){var e={};return this.hot.runHooks("persistentStateLoad","manualRowMove",e),e.value?e.value:[]}},{key:"prepareRowsToMoving",value:function(){var e=this.hot.getSelectedRange(),t=[];if(!e)return t;var o=e.from,n=e.to,r=Math.min(o.row,n.row),i=Math.max(o.row,n.row);return(0,g.rangeEach)(r,i,function(e){t.push(e)}),t}},{key:"refreshPositions",value:function(){var e=k.get(this),t=e.target.coords,o=this.hot.view.wt.wtTable.getFirstVisibleRow(),n=this.hot.view.wt.wtTable.getLastVisibleRow(),r=this.hot.getSettings().fixedRowsTop,i=this.hot.countRows();r>t.row&&o>0&&this.hot.scrollViewportTo(o-1),t.row>=n&&i>n&&this.hot.scrollViewportTo(n+1,void 0,!0);var s=this.hot.view.wt.wtTable,l=e.target.TD,a=(0,p.offset)(this.hot.rootElement),u=this.hot.view.THEAD.offsetHeight+this.getRowsHeight(0,t.row),c=e.target.eventPageY-a.top+s.holder.scrollTop,h=s.hider.offsetHeight,d=s.TBODY.offsetTop,f=this.backlight.getOffset().top,g=this.backlight.getSize().height;this.isFixedRowTop(t.row)&&(u+=s.holder.scrollTop),0>t.row?e.target.row=o>0?o-1:o:l.offsetHeight/2+u>c?e.target.row=t.row:(e.target.row=t.row+1,u+=0===t.row?l.offsetHeight-1:l.offsetHeight);var v=c,m=u;h>c+g+f?d>c+f&&(v=d+Math.abs(f)):v=h-g-f,h-1>u||(m=h-1);var y=0;this.hot.view.wt.wtOverlays.topOverlay&&(y=this.hot.view.wt.wtOverlays.topOverlay.clone.wtTable.TABLE.offsetHeight),t.row>=r&&y>m-s.holder.scrollTop&&this.hot.scrollViewportTo(t.row),this.backlight.setPosition(v),this.guideline.setPosition(m)}},{key:"updateRowsMapper",value:function(){var e=this.hot.countSourceRows(),t=this.rowsMapper._arrayMap.length;if(0===t)this.rowsMapper.createMap(e||this.hot.getSettings().startRows);else if(e>t){var o=e-t;this.rowsMapper.insertItems(t,o)}else if(t>e){var n=e-1,r=[];(0,f.arrayEach)(this.rowsMapper._arrayMap,function(e,t,o){e>n&&r.push(t)}),this.rowsMapper.removeItems(r)}}},{key:"registerEvents",value:function(){var e=this;this.eventManager.addEventListener(document.documentElement,"mousemove",function(t){return e.onMouseMove(t)}),this.eventManager.addEventListener(document.documentElement,"mouseup",function(){return e.onMouseUp()})}},{key:"unregisterEvents",value:function(){this.eventManager.clear()}},{key:"onBeforeColumnSort",value:function(e,t){k.get(this).disallowMoving=void 0!==t}},{key:"onBeforeOnCellMouseDown",value:function(e,t,o,n){var r=this.hot.view.wt.wtTable,i=this.hot.selection.selectedHeader.rows,s=this.hot.getSelectedRange(),l=k.get(this);if(!s||!i||l.pressed||0!==e.button)return l.pressed=!1,l.rowsToMove.length=0,void(0,p.removeClass)(this.hot.rootElement,["on-moving--rows","show-ui"]);var a=this.guideline.isBuilt()&&!this.guideline.isAppended(),u=this.backlight.isBuilt()&&!this.backlight.isAppended();a&&u&&(this.guideline.appendTo(r.hider),this.backlight.appendTo(r.hider));var c=s.from,h=s.to,d=Math.min(c.row,h.row),f=Math.max(c.row,h.row);if(0<=t.col||t.row<d||f<t.row)(0,p.removeClass)(this.hot.rootElement,"after-selection--rows"),l.pressed=!1,l.rowsToMove.length=0;else{n.row=!0,l.pressed=!0,l.target.eventPageY=e.pageY,l.target.coords=t,l.target.TD=o,l.rowsToMove=this.prepareRowsToMoving();var g=r.holder.scrollLeft+r.getColumnWidth(-1);this.backlight.setPosition(null,g),this.backlight.setSize(r.hider.offsetWidth-g,this.getRowsHeight(d,f+1)),this.backlight.setOffset(-1*(this.getRowsHeight(d,t.row)+e.layerY),null),(0,p.addClass)(this.hot.rootElement,"on-moving--rows"),this.refreshPositions()}}},{key:"onMouseMove",value:function(e){var t=k.get(this);if(t.pressed){if(e.realTarget===this.backlight.element){var o=this.backlight.getSize().height;this.backlight.setSize(null,0),setTimeout(function(){this.backlight.setPosition(null,o)})}t.target.eventPageY=e.pageY,this.refreshPositions()}}},{key:"onBeforeOnCellMouseOver",value:function(e,t,o,n){var r=this.hot.getSelectedRange(),i=k.get(this);r&&i.pressed&&(i.rowsToMove.indexOf(t.row)>-1?(0,p.removeClass)(this.hot.rootElement,"show-ui"):(0,p.addClass)(this.hot.rootElement,"show-ui"),n.row=!0,n.column=!0,n.cell=!0,i.target.coords=t,i.target.TD=o)}},{key:"onMouseUp",value:function(){var e=k.get(this),t=e.target.row,o=e.rowsToMove.length;if(e.pressed=!1,e.backlightHeight=0,(0,p.removeClass)(this.hot.rootElement,["on-moving--rows","show-ui","after-selection--rows"]),this.hot.selection.selectedHeader.rows&&(0,p.addClass)(this.hot.rootElement,"after-selection--rows"),o>=1&&void 0!==t&&-1>=e.rowsToMove.indexOf(t)&&e.rowsToMove[o-1]!==t-1){if(this.moveRows(e.rowsToMove,t),this.persistentStateSave(),this.hot.render(),!e.disallowMoving){this.changeSelection(this.rowsMapper.getIndexByValue(e.rowsToMove[0]),this.rowsMapper.getIndexByValue(e.rowsToMove[o-1]))}e.rowsToMove.length=0}}},{key:"onAfterScrollHorizontally",value:function(){var e=this.hot.view.wt.wtTable,t=e.getColumnWidth(-1),o=e.holder.scrollLeft,n=t+o;this.backlight.setPosition(null,n),this.backlight.setSize(e.hider.offsetWidth-n)}},{key:"onAfterCreateRow",value:function(e,t){this.rowsMapper.shiftItems(e,t)}},{key:"onBeforeRemoveRow",value:function(e,t){var o=this;this.removedRows.length=0,!1!==e&&(0,g.rangeEach)(e,e+t-1,function(e){o.removedRows.push(o.hot.runHooks("modifyRow",e,o.pluginName))})}},{key:"onAfterRemoveRow",value:function(e,t){this.rowsMapper.unshiftItems(this.removedRows)}},{key:"onAfterLoadData",value:function(e){this.updateRowsMapper()}},{key:"onModifyRow",value:function(e,t){if(t!==this.pluginName){var o=this.rowsMapper.getValueByIndex(e);e=null===o?e:o}return e}},{key:"onUnmodifyRow",value:function(e){var t=this.rowsMapper.getIndexByValue(e);return null===t?e:t}},{key:"onAfterPluginsInitialized",value:function(){this.updateRowsMapper(),this.initialSettings(),this.backlight.build(),this.guideline.build()}},{key:"destroy",value:function(){this.backlight.destroy(),this.guideline.destroy(),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}}]),t}(c.default);(0,y.registerPlugin)("ManualRowMove",T),t.default=T},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=o(151),s=function(e){return e&&e.__esModule?e:{default:e}}(i),l=o(2),a=o(1),u=o(6),c=function(){function e(t){n(this,e),this.manualRowMove=t}return r(e,[{key:"createMap",value:function(e){var t=this,o=void 0===e?this._arrayMap.length:e;this._arrayMap.length=0,(0,u.rangeEach)(o-1,function(e){t._arrayMap[e]=e})}},{key:"destroy",value:function(){this._arrayMap=null}},{key:"moveRow",value:function(e,t){var o=this._arrayMap[e];this._arrayMap[e]=null,this._arrayMap.splice(t,0,o)}},{key:"clearNull",value:function(){this._arrayMap=(0,l.arrayFilter)(this._arrayMap,function(e){return null!==e})}}]),e}();(0,a.mixin)(c,s.default),t.default=c},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var s=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),l=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},a=o(153),u=function(e){return e&&e.__esModule?e:{default:e}}(a),c=o(0);t.default=function(e){function t(){return n(this,t),r(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return i(t,e),s(t,[{key:"build",value:function(){l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"build",this).call(this),(0,c.addClass)(this._element,"ht__manualRowMove--backlight")}}]),t}(u.default)},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var s=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),l=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},a=o(153),u=function(e){return e&&e.__esModule?e:{default:e}}(a),c=o(0);t.default=function(e){function t(){return n(this,t),r(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return i(t,e),s(t,[{key:"build",value:function(){l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"build",this).call(this),(0,c.addClass)(this._element,"ht__manualRowMove--guideline")}}]),t}(u.default)},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var l=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),a=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},u=o(12),c=n(u),h=o(0),d=o(4),f=n(d),p=o(7),g=o(2),v=o(6),m=o(5),y=function(e){function t(e){r(this,t);var o=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.currentTH=null,o.currentRow=null,o.selectedRows=[],o.currentHeight=null,o.newSize=null,o.startY=null,o.startHeight=null,o.startOffset=null,o.handle=document.createElement("DIV"),o.guide=document.createElement("DIV"),o.eventManager=new f.default(o),o.pressed=null,o.dblclick=0,o.autoresizeTimeout=null,o.manualRowHeights=[],(0,h.addClass)(o.handle,"manualRowResizer"),(0,h.addClass)(o.guide,"manualRowResizerGuide"),o}return s(t,e),l(t,[{key:"isEnabled",value:function(){return this.hot.getSettings().manualRowResize}},{key:"enablePlugin",value:function(){var e=this;if(!this.enabled){this.manualRowHeights=[];var o=this.hot.getSettings().manualRowResize,n=this.loadManualRowHeights();this.manualRowHeights=void 0!==n?n:Array.isArray(o)?o:[],this.addHook("modifyRowHeight",function(t,o){return e.onModifyRowHeight(t,o)}),this.bindEvents(),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this)}}},{key:"updatePlugin",value:function(){var e=this.hot.getSettings().manualRowResize;Array.isArray(e)?this.manualRowHeights=e:e||(this.manualRowHeights=[])}},{key:"disablePlugin",value:function(){a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"saveManualRowHeights",value:function(){this.hot.runHooks("persistentStateSave","manualRowHeights",this.manualRowHeights)}},{key:"loadManualRowHeights",value:function(){var e={};return this.hot.runHooks("persistentStateLoad","manualRowHeights",e),e.value}},{key:"setupHandlePosition",value:function(e){var t=this;this.currentTH=e;var o=this.hot.view.wt.wtTable.getCoords(e).row,n=(0,h.outerWidth)(this.currentTH);if(o>=0){var r=this.currentTH.getBoundingClientRect();if(this.currentRow=o,this.selectedRows=[],this.hot.selection.isSelected()&&this.hot.selection.selectedHeader.rows){var i=this.hot.getSelectedRange(),s=i.from,l=i.to,a=s.row,u=l.row;u>a||(a=l.row,u=s.row),a>this.currentRow||this.currentRow>u?this.selectedRows.push(this.currentRow):(0,v.rangeEach)(a,u,function(e){return t.selectedRows.push(e)})}else this.selectedRows.push(this.currentRow);this.startOffset=r.top-6,this.startHeight=parseInt(r.height,10),this.handle.style.left=r.left+"px",this.handle.style.top=this.startOffset+this.startHeight+"px",this.handle.style.width=n+"px",this.hot.rootElement.appendChild(this.handle)}}},{key:"refreshHandlePosition",value:function(){this.handle.style.top=this.startOffset+this.currentHeight+"px"}},{key:"setupGuidePosition",value:function(){var e=parseInt((0,h.outerWidth)(this.handle),10),t=parseInt(this.handle.style.left,10)+e,o=parseInt(this.hot.view.maximumVisibleElementWidth(0),10);(0,h.addClass)(this.handle,"active"),(0,h.addClass)(this.guide,"active"),this.guide.style.top=this.handle.style.top,this.guide.style.left=t+"px",this.guide.style.width=o-e+"px",this.hot.rootElement.appendChild(this.guide)}},{key:"refreshGuidePosition",value:function(){this.guide.style.top=this.handle.style.top}},{key:"hideHandleAndGuide",value:function(){(0,h.removeClass)(this.handle,"active"),(0,h.removeClass)(this.guide,"active")}},{key:"checkIfRowHeader",value:function(e){if(e!=this.hot.rootElement){var t=e.parentNode;return"TBODY"===t.tagName||this.checkIfRowHeader(t)}return!1}},{key:"getTHFromTargetElement",value:function(e){return"TABLE"!=e.tagName?"TH"==e.tagName?e:this.getTHFromTargetElement(e.parentNode):null}},{key:"onMouseOver",value:function(e){if(this.checkIfRowHeader(e.target)){var t=this.getTHFromTargetElement(e.target);t&&(this.pressed||this.setupHandlePosition(t))}}},{key:"afterMouseDownTimeout",value:function(){var e=this,t=function(){e.hot.forceFullRender=!0,e.hot.view.render(),e.hot.view.wt.wtOverlays.adjustElementsSize(!0)},o=function(o,n){var r=e.hot.runHooks("beforeRowResize",o,e.newSize,!0);void 0!==r&&(e.newSize=r),e.setManualSize(o,e.newSize),n&&t(),e.hot.runHooks("afterRowResize",o,e.newSize,!0)};if(this.dblclick>=2){this.selectedRows.length>1?((0,g.arrayEach)(this.selectedRows,function(e){o(e)}),t()):(0,g.arrayEach)(this.selectedRows,function(e){o(e,!0)})}this.dblclick=0,this.autoresizeTimeout=null}},{key:"onMouseDown",value:function(e){var t=this;(0,h.hasClass)(e.target,"manualRowResizer")&&(this.setupGuidePosition(),this.pressed=this.hot,null==this.autoresizeTimeout&&(this.autoresizeTimeout=setTimeout(function(){return t.afterMouseDownTimeout()},500),this.hot._registerTimeout(this.autoresizeTimeout)),this.dblclick++,this.startY=(0,p.pageY)(e),this.newSize=this.startHeight)}},{key:"onMouseMove",value:function(e){var t=this;this.pressed&&(this.currentHeight=this.startHeight+((0,p.pageY)(e)-this.startY),(0,g.arrayEach)(this.selectedRows,function(e){t.newSize=t.setManualSize(e,t.currentHeight)}),this.refreshHandlePosition(),this.refreshGuidePosition())}},{key:"onMouseUp",value:function(e){var t=this,o=function(){t.hot.forceFullRender=!0,t.hot.view.render(),t.hot.view.wt.wtOverlays.adjustElementsSize(!0)},n=function(e,n){t.hot.runHooks("beforeRowResize",e,t.newSize),n&&o(),t.saveManualRowHeights(),t.hot.runHooks("afterRowResize",e,t.newSize)};if(this.pressed){if(this.hideHandleAndGuide(),this.pressed=!1,this.newSize!=this.startHeight){this.selectedRows.length>1?((0,g.arrayEach)(this.selectedRows,function(e){n(e)}),o()):(0,g.arrayEach)(this.selectedRows,function(e){n(e,!0)})}this.setupHandlePosition(this.currentTH)}}},{key:"bindEvents",value:function(){var e=this;this.eventManager.addEventListener(this.hot.rootElement,"mouseover",function(t){return e.onMouseOver(t)}),this.eventManager.addEventListener(this.hot.rootElement,"mousedown",function(t){return e.onMouseDown(t)}),this.eventManager.addEventListener(window,"mousemove",function(t){return e.onMouseMove(t)}),this.eventManager.addEventListener(window,"mouseup",function(t){return e.onMouseUp(t)})}},{key:"setManualSize",value:function(e,t){return e=this.hot.runHooks("modifyRow",e),this.manualRowHeights[e]=t,t}},{key:"onModifyRowHeight",value:function(e,t){if(this.enabled){var o=this.hot.getPlugin("autoRowSize"),n=o?o.heights[t]:null;t=this.hot.runHooks("modifyRow",t);var r=this.manualRowHeights[t];if(void 0!==r&&(r===n||r>(e||0)))return r}return e}}]),t}(c.default);(0,m.registerPlugin)("manualRowResize",y),t.default=y},function(e,t,o){"use strict";function n(){var e=[];return e.getInfo=function(e,t){for(var o=0,n=this.length;n>o;o++)if(!(this[o].row>e||e>this[o].row+this[o].rowspan-1||this[o].col>t||t>this[o].col+this[o].colspan-1))return this[o]},e.setInfo=function(e){for(var t=0,o=this.length;o>t;t++)if(this[t].row===e.row&&this[t].col===e.col)return void(this[t]=e);this.push(e)},e.removeInfo=function(e,t){for(var o=0,n=this.length;n>o;o++)if(this[o].row===e&&this[o].col===t){this.splice(o,1);break}},e}function r(e){if(this.mergedCellInfoCollection=new n,Array.isArray(e))for(var t=0,o=e.length;o>t;t++)this.mergedCellInfoCollection.setInfo(e[t])}function i(e,t){if(this.getSettings().mergeCells&&!this.selection.isMultiple()){var o=this.mergeCells.mergedCellInfoCollection.getInfo(e[0],e[1]);o&&(e[0]=o.row,e[1]=o.col,e[2]=o.row+o.rowspan-1,e[3]=o.col+o.colspan-1)}}function s(e,t){this.mergeCells&&this.mergeCells.shiftCollection("right",e,t)}function l(e,t){this.mergeCells&&this.mergeCells.shiftCollection("left",e,t)}function a(e,t){this.mergeCells&&this.mergeCells.shiftCollection("down",e,t)}function u(e,t){this.mergeCells&&this.mergeCells.shiftCollection("up",e,t)}t.__esModule=!0;var c=o(8),h=function(e){return e&&e.__esModule?e:{default:e}}(c),d=(o(5),o(7)),f=o(11);r.prototype.canMergeRange=function(e){return!e.isSingle()},r.prototype.mergeRange=function(e){if(this.canMergeRange(e)){var t=e.getTopLeftCorner(),o=e.getBottomRightCorner(),n={};n.row=t.row,n.col=t.col,n.rowspan=o.row-t.row+1,n.colspan=o.col-t.col+1,this.mergedCellInfoCollection.setInfo(n)}},r.prototype.mergeOrUnmergeSelection=function(e){this.mergedCellInfoCollection.getInfo(e.from.row,e.from.col)?this.unmergeSelection(e.from):this.mergeSelection(e)},r.prototype.mergeSelection=function(e){this.mergeRange(e)},r.prototype.unmergeSelection=function(e){var t=this.mergedCellInfoCollection.getInfo(e.row,e.col);this.mergedCellInfoCollection.removeInfo(t.row,t.col)},r.prototype.applySpanProperties=function(e,t,o){var n=this.mergedCellInfoCollection.getInfo(t,o);n?n.row===t&&n.col===o?(e.setAttribute("rowspan",n.rowspan),e.setAttribute("colspan",n.colspan)):(e.removeAttribute("rowspan"),e.removeAttribute("colspan"),e.style.display="none"):(e.removeAttribute("rowspan"),e.removeAttribute("colspan"))},r.prototype.modifyTransform=function(e,t,o){var n={row:o.row,col:o.col};if("modifyTransformStart"==e){var r;this.lastDesiredCoords||(this.lastDesiredCoords=new f.CellCoords(null,null));for(var i=new f.CellCoords(t.highlight.row,t.highlight.col),s=this.mergedCellInfoCollection.getInfo(i.row,i.col),l=0,a=this.mergedCellInfoCollection.length;a>l;l++){var u=this.mergedCellInfoCollection[l];if(u=new f.CellCoords(u.row+u.rowspan-1,u.col+u.colspan-1),t.includes(u)){!0;break}}if(s){var c=new f.CellCoords(s.row,s.col),h=new f.CellCoords(s.row+s.rowspan-1,s.col+s.colspan-1);new f.CellRange(c,c,h).includes(this.lastDesiredCoords)||(this.lastDesiredCoords=new f.CellCoords(null,null)),n.row=this.lastDesiredCoords.row?this.lastDesiredCoords.row-i.row:n.row,n.col=this.lastDesiredCoords.col?this.lastDesiredCoords.col-i.col:n.col,o.row>0?n.row=s.row+s.rowspan-1-i.row+o.row:0>o.row&&(n.row=i.row-s.row+o.row),o.col>0?n.col=s.col+s.colspan-1-i.col+o.col:0>o.col&&(n.col=i.col-s.col+o.col)}r=new f.CellCoords(t.highlight.row+n.row,t.highlight.col+n.col);var d=this.mergedCellInfoCollection.getInfo(r.row,r.col);d&&(this.lastDesiredCoords=r,n={row:d.row-i.row,col:d.col-i.col})}else if("modifyTransformEnd"==e)for(var p=0,g=this.mergedCellInfoCollection.length;g>p;p++){var v=this.mergedCellInfoCollection[p],m=new f.CellCoords(v.row,v.col),y=new f.CellCoords(v.row+v.rowspan-1,v.col+v.colspan-1),w=new f.CellRange(m,m,y),C=t.getBordersSharedWith(w);if(w.isEqual(t))t.setDirection("NW-SE");else if(C.length>0){var b=t.highlight.isEqual(w.from);C.indexOf("top")>-1?t.to.isSouthEastOf(w.from)&&b?t.setDirection("NW-SE"):t.to.isSouthWestOf(w.from)&&b&&t.setDirection("NE-SW"):C.indexOf("bottom")>-1&&(t.to.isNorthEastOf(w.from)&&b?t.setDirection("SW-NE"):t.to.isNorthWestOf(w.from)&&b&&t.setDirection("SE-NW"))}r=function(e){return new f.CellCoords(t.to.row+e.row,t.to.col+e.col)}(n);var S=function(e,t){return t.row>=e.row&&e.row+e.rowspan-1>=t.row}(v,r),E=function(e,t){return t.col>=e.col&&e.col+e.colspan-1>=t.col}(v,r);t.includesRange(w)&&(w.includes(r)||S||E)&&(S&&(0>n.row?n.row-=v.rowspan-1:n.row>0&&(n.row+=v.rowspan-1)),E&&(0>n.col?n.col-=v.colspan-1:n.col>0&&(n.col+=v.colspan-1)))}0!==n.row&&(o.row=n.row),0!==n.col&&(o.col=n.col)},r.prototype.shiftCollection=function(e,t,o){var n=[0,0];switch(e){case"right":n[0]+=1;break;case"left":n[0]-=1;break;case"down":n[1]+=1;break;case"up":n[1]-=1}for(var r=0;this.mergedCellInfoCollection.length>r;r++){var i=this.mergedCellInfoCollection[r];"right"===e||"left"===e?t>i.col||(i.col+=n[0]):t>i.row||(i.row+=n[1])}};var p=function(){var e=this,t=e.getSettings().mergeCells;t&&(e.mergeCells||(e.mergeCells=new r(t)))},g=function(){var e=this;e.mergeCells&&(e.view.wt.wtTable.getCell=function(t){if(e.getSettings().mergeCells){var o=e.mergeCells.mergedCellInfoCollection.getInfo(t.row,t.col);o&&(t=o)}return f.Table.prototype.getCell.call(this,t)})},v=function(){var e=this,t=e.getSettings().mergeCells;if(t)if(e.mergeCells){if(e.mergeCells.mergedCellInfoCollection=new n,Array.isArray(t))for(var o=0,i=t.length;i>o;o++)e.mergeCells.mergedCellInfoCollection.setInfo(t[o])}else e.mergeCells=new r(t);else e.mergeCells&&(e.mergeCells.mergedCellInfoCollection=new n)},m=function(e){if(this.mergeCells){(e.ctrlKey||e.metaKey)&&!e.altKey&&77===e.keyCode&&(this.mergeCells.mergeOrUnmergeSelection(this.getSelectedRange()),this.render(),(0,d.stopImmediatePropagation)(e))}},y=function(e){this.getSettings().mergeCells&&(e.items.push({name:"---------"}),e.items.push({key:"mergeCells",name:function(){var e=this.getSelected();return this.mergeCells.mergedCellInfoCollection.getInfo(e[0],e[1])?"Unmerge cells":"Merge cells"},callback:function(){this.mergeCells.mergeOrUnmergeSelection(this.getSelectedRange()),this.render()},disabled:function(){return this.selection.selectedHeader.corner}}))},w=function(e,t,o,n,r,i){this.mergeCells&&this.mergeCells.applySpanProperties(e,t,o)},C=function(e){return function(t){if(this.getSettings().mergeCells){var o=this.getSelectedRange();if(this.mergeCells.modifyTransform(e,o,t),"modifyTransformEnd"===e){var n=this.countRows(),r=this.countCols();0>o.from.row?o.from.row=0:o.from.row>0&&o.from.row>=n&&(o.from.row=o.from-1),0>o.from.col?o.from.col=0:o.from.col>0&&o.from.col>=r&&(o.from.col=r-1)}}}},b=function(e){if(this.lastDesiredCoords=null,this.getSettings().mergeCells){var t=this.getSelectedRange();t.highlight=new f.CellCoords(t.highlight.row,t.highlight.col),t.to=e;var o=!1;do{o=!1;for(var n=0,r=this.mergeCells.mergedCellInfoCollection.length;r>n;n++){var i=this.mergeCells.mergedCellInfoCollection[n],s=new f.CellCoords(i.row,i.col),l=new f.CellCoords(i.row+i.rowspan-1,i.col+i.colspan-1);t.expandByRange(new f.CellRange(s,s,l))&&(e.row=t.to.row,e.col=t.to.col,o=!0)}}while(o)}},S=function(e,t){if(t&&"area"==t){if(this.getSettings().mergeCells)for(var o=this.getSelectedRange(),n=new f.CellRange(o.from,o.from,o.from),r=new f.CellRange(o.to,o.to,o.to),i=0,s=this.mergeCells.mergedCellInfoCollection.length;s>i;i++){var l=this.mergeCells.mergedCellInfoCollection[i],a=new f.CellCoords(l.row,l.col),u=new f.CellCoords(l.row+l.rowspan-1,l.col+l.colspan-1),c=new f.CellRange(a,a,u);n.expandByRange(c)&&(e[0]=n.from.row,e[1]=n.from.col),r.expandByRange(c)&&(e[2]=r.from.row,e[3]=r.from.col)}}},E=function(e,t,o){if(this.getSettings().mergeCells){var n=this.mergeCells.mergedCellInfoCollection.getInfo(e,t);!n||n.row==e&&n.col==t||(o.copyable=!1)}},R=function e(t){if(this.getSettings().mergeCells)for(var o,n=this.countCols(),r=0;n>r;r++){if((o=this.mergeCells.mergedCellInfoCollection.getInfo(t.startRow,r))&&t.startRow>o.row)return t.startRow=o.row,e.call(this,t);if(o=this.mergeCells.mergedCellInfoCollection.getInfo(t.endRow,r)){var i=o.row+o.rowspan-1;if(i>t.endRow)return t.endRow=i,e.call(this,t)}}},O=function e(t){if(this.getSettings().mergeCells)for(var o,n=this.countRows(),r=0;n>r;r++){if((o=this.mergeCells.mergedCellInfoCollection.getInfo(r,t.startColumn))&&t.startColumn>o.col)return t.startColumn=o.col,e.call(this,t);if(o=this.mergeCells.mergedCellInfoCollection.getInfo(r,t.endColumn)){var i=o.col+o.colspan-1;if(i>t.endColumn)return t.endColumn=i,e.call(this,t)}}},k=function(e){if(e&&this.mergeCells){var t=this.mergeCells.mergedCellInfoCollection,o=this.getSelectedRange();for(var n in t)if(o.highlight.row==t[n].row&&o.highlight.col==t[n].col&&o.to.row==t[n].row+t[n].rowspan-1&&o.to.col==t[n].col+t[n].colspan-1)return!1}return e},T=h.default.getSingleton();T.add("beforeInit",p),T.add("afterInit",g),T.add("afterUpdateSettings",v),T.add("beforeKeyDown",m),T.add("modifyTransformStart",C("modifyTransformStart")),T.add("modifyTransformEnd",C("modifyTransformEnd")),T.add("beforeSetRangeEnd",b),T.add("beforeDrawBorders",S),T.add("afterIsMultipleSelection",k),T.add("afterRenderer",w),T.add("afterContextMenuDefaultOptions",y),T.add("afterGetCellMeta",E),T.add("afterViewportRowCalculatorOverride",R),T.add("afterViewportColumnCalculatorOverride",O),T.add("modifyAutofillRange",i),T.add("afterCreateCol",s),T.add("afterRemoveCol",l),T.add("afterCreateRow",a),T.add("afterRemoveRow",u),t.default=r},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var l=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),a=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},u=o(8),c=(n(u),o(0)),h=o(25),d=o(12),f=n(d),p=o(4),g=n(p),v=o(5),m=o(11),y=function(e){function t(e){r(this,t);var o=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.dragged=[],o.eventManager=null,o.lastSetCell=null,o}return s(t,e),l(t,[{key:"isEnabled",value:function(){return(0,h.isMobileBrowser)()}},{key:"enablePlugin",value:function(){this.enabled||(this.eventManager||(this.eventManager=new g.default(this)),this.registerListeners(),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{key:"registerListeners",value:function(){function e(e){if(1===t.dragged.length)return t.dragged.splice(0,t.dragged.length),!0;var o=t.dragged.indexOf(e);if(-1==o)return!1;0===o?t.dragged=t.dragged.slice(0,1):1==o&&(t.dragged=t.dragged.slice(-1))}var t=this;this.eventManager.addEventListener(this.hot.rootElement,"touchstart",function(e){var o=void 0;return(0,c.hasClass)(e.target,"topLeftSelectionHandle-HitArea")?(o=t.hot.getSelectedRange(),t.dragged.push("topLeft"),t.touchStartRange={width:o.getWidth(),height:o.getHeight(),direction:o.getDirection()},e.preventDefault(),!1):(0,c.hasClass)(e.target,"bottomRightSelectionHandle-HitArea")?(o=t.hot.getSelectedRange(),t.dragged.push("bottomRight"),t.touchStartRange={width:o.getWidth(),height:o.getHeight(),direction:o.getDirection()},e.preventDefault(),!1):void 0}),this.eventManager.addEventListener(this.hot.rootElement,"touchend",function(o){return(0,c.hasClass)(o.target,"topLeftSelectionHandle-HitArea")?(e.call(t,"topLeft"),t.touchStartRange=void 0,o.preventDefault(),!1):(0,c.hasClass)(o.target,"bottomRightSelectionHandle-HitArea")?(e.call(t,"bottomRight"),t.touchStartRange=void 0,o.preventDefault(),!1):void 0}),this.eventManager.addEventListener(this.hot.rootElement,"touchmove",function(e){var o=(0,c.getWindowScrollTop)(),n=(0,c.getWindowScrollLeft)(),r=void 0,i=void 0,s=void 0,l=void 0,a=void 0,u=void 0,h=void 0;0!==t.dragged.length&&(r=document.elementFromPoint(e.touches[0].screenX-n,e.touches[0].screenY-o))&&r!==t.lastSetCell&&("TD"!=r.nodeName&&"TH"!=r.nodeName||(i=t.hot.getCoords(r),-1==i.col&&(i.col=0),s=t.hot.getSelectedRange(),l=s.getWidth(),a=s.getHeight(),u=s.getDirection(),1==l&&1==a&&t.hot.selection.setRangeEnd(i),h=t.getCurrentRangeCoords(s,i,t.touchStartRange.direction,u,t.dragged[0]),null!==h.start&&t.hot.selection.setRangeStart(h.start),t.hot.selection.setRangeEnd(h.end),t.lastSetCell=r),e.preventDefault())})}},{key:"getCurrentRangeCoords",value:function(e,t,o,n,r){var i=e.getTopLeftCorner(),s=e.getBottomRightCorner(),l=e.getBottomLeftCorner(),a=e.getTopRightCorner(),u={start:null,end:null};switch(o){case"NE-SW":switch(n){case"NE-SW":case"NW-SE":u="topLeft"==r?{start:new m.CellCoords(t.row,e.highlight.col),end:new m.CellCoords(l.row,t.col)}:{start:new m.CellCoords(e.highlight.row,t.col),end:new m.CellCoords(t.row,i.col)};break;case"SE-NW":"bottomRight"==r&&(u={start:new m.CellCoords(s.row,t.col),end:new m.CellCoords(t.row,i.col)})}break;case"NW-SE":switch(n){case"NE-SW":"topLeft"==r?u={start:t,end:l}:u.end=t;break;case"NW-SE":"topLeft"==r?u={start:t,end:s}:u.end=t;break;case"SE-NW":"topLeft"==r?u={start:t,end:i}:u.end=t;break;case"SW-NE":"topLeft"==r?u={start:t,end:a}:u.end=t}break;case"SW-NE":switch(n){case"NW-SE":u="bottomRight"==r?{start:new m.CellCoords(t.row,i.col),end:new m.CellCoords(l.row,t.col)}:{start:new m.CellCoords(i.row,t.col),end:new m.CellCoords(t.row,s.col)};break;case"SW-NE":u="topLeft"==r?{start:new m.CellCoords(e.highlight.row,t.col),end:new m.CellCoords(t.row,s.col)}:{start:new m.CellCoords(t.row,i.col),end:new m.CellCoords(i.row,t.col)};break;case"SE-NW":"bottomRight"==r?u={start:new m.CellCoords(t.row,a.col),end:new m.CellCoords(i.row,t.col)}:"topLeft"==r&&(u={start:l,end:t})}break;case"SE-NW":switch(n){case"NW-SE":case"NE-SW":case"SW-NE":"topLeft"==r&&(u.end=t);break;case"SE-NW":"topLeft"==r?u.end=t:u={start:t,end:i}}}return u}},{key:"isDragged",value:function(){return this.dragged.length>0}}]),t}(f.default);(0,v.registerPlugin)("multipleSelectionHandles",y),t.default=y},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var i=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),s=o(135),l=n(s),a=o(69),u=n(a),c=o(1),h=o(259),d=function(){function e(t){r(this,e),this.observedData=null,this.observer=null,this.paused=!1,this.setObservedData(t)}return i(e,[{key:"setObservedData",value:function(e){var t=this;this.observer&&l.default.unobserve(this.observedData,this.observer),this.observedData=e,this.observer=l.default.observe(this.observedData,function(e){return t.onChange(e)})}},{key:"isPaused",value:function(){return this.paused}},{key:"pause",value:function(){this.paused=!0}},{key:"resume",value:function(){this.paused=!1}},{key:"onChange",value:function(e){this.runLocalHooks("change",(0,h.cleanPatches)(e))}},{key:"destroy",value:function(){l.default.unobserve(this.observedData,this.observer),this.observedData=null,this.observer=null}}]),e}();(0,c.mixin)(d,u.default),t.default=d},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var l=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),a=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},u=o(12),c=n(u),h=o(135),d=(n(h),o(257)),f=n(d),p=o(2),g=o(5),v=function(e){function t(e){r(this,t);var o=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.observer=null,o}return s(t,e),l(t,[{key:"isEnabled",value:function(){return this.hot.getSettings().observeChanges}},{key:"enablePlugin",value:function(){var e=this;this.enabled||(this.observer||(this.observer=new f.default(this.hot.getSourceData()),this._exposePublicApi()),this.observer.addLocalHook("change",function(t){return e.onDataChange(t)}),this.addHook("afterCreateRow",function(){return e.onAfterTableAlter()}),this.addHook("afterRemoveRow",function(){return e.onAfterTableAlter()}),this.addHook("afterCreateCol",function(){return e.onAfterTableAlter()}),this.addHook("afterRemoveCol",function(){return e.onAfterTableAlter()}),this.addHook("afterChange",function(t,o){return e.onAfterTableAlter(o)}),this.addHook("afterLoadData",function(t){return e.onAfterLoadData(t)}),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{key:"disablePlugin",value:function(){this.observer&&(this.observer.destroy(),this.observer=null,this._deletePublicApi()),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"onDataChange",value:function(e){var t=this;if(!this.observer.isPaused()){var o=this.pluginName+".change",n={add:function(e){isNaN(e.col)?t.hot.runHooks("afterCreateRow",e.row,1,o):t.hot.runHooks("afterCreateCol",e.col,1,o)},remove:function(e){isNaN(e.col)?t.hot.runHooks("afterRemoveRow",e.row,1,o):t.hot.runHooks("afterRemoveCol",e.col,1,o)},replace:function(e){t.hot.runHooks("afterChange",[e.row,e.col,null,e.value],o)}};(0,p.arrayEach)(e,function(e){n[e.op]&&n[e.op](e)}),this.hot.render()}this.hot.runHooks("afterChangesObserved")}},{key:"onAfterTableAlter",value:function(e){var t=this;"loadData"!==e&&(this.observer.pause(),this.hot.addHookOnce("afterChangesObserved",function(){return t.observer.resume()}))}},{key:"onAfterLoadData",value:function(e){e||this.observer.setObservedData(this.hot.getSourceData())}},{key:"destroy",value:function(){this.observer&&(this.observer.destroy(),this._deletePublicApi()),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}},{key:"_exposePublicApi",value:function(){var e=this,t=this.hot;t.pauseObservingChanges=function(){return e.observer.pause()},t.resumeObservingChanges=function(){return e.observer.resume()},t.isPausedObservingChanges=function(){return e.observer.isPaused()}}},{key:"_deletePublicApi",value:function(){var e=this.hot;delete e.pauseObservingChanges,delete e.resumeObservingChanges,delete e.isPausedObservingChanges}}]),t}(c.default);t.default=v,(0,g.registerPlugin)("observeChanges",v)},function(e,t,o){"use strict";function n(e){var t=[];return e=(0,s.arrayFilter)(e,function(e){return!/[\/]length/gi.test(e.path)&&!!r(e.path)}),e=(0,s.arrayMap)(e,function(e){var t=r(e.path);return e.row=t.row,e.col=t.col,e}),e=(0,s.arrayFilter)(e,function(e){if(-1!==["add","remove"].indexOf(e.op)&&!isNaN(e.col)){if(-1!==t.indexOf(e.col))return!1;t.push(e.col)}return!0}),t.length=0,e}function r(e){var t=e.match(/^\/(\d+)\/?(.*)?$/);if(!t)return null;var o=i(t,3),n=o[1],r=o[2];return{row:parseInt(n,10),col:/^\d*$/.test(r)?parseInt(r,10):r}}t.__esModule=!0;var i=function(){function e(e,t){var o=[],n=!0,r=!1,i=void 0;try{for(var s,l=e[Symbol.iterator]();!(n=(s=l.next()).done)&&(o.push(s.value),!t||o.length!==t);n=!0);}catch(e){r=!0,i=e}finally{try{!n&&l.return&&l.return()}finally{if(r)throw i}}return o}return function(t,o){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,o);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}();t.cleanPatches=n,t.parsePath=r;var s=o(2)},function(e,t,o){"use strict";function n(e){var t,o=function(){window.localStorage[e+"__persistentStateKeys"]=JSON.stringify(t)},n=function(){t=[],o()};!function(){var o=window.localStorage[e+"__persistentStateKeys"],n="string"==typeof o?JSON.parse(o):void 0;t=n||[]}(),this.saveValue=function(n,r){window.localStorage[e+"_"+n]=JSON.stringify(r),-1==t.indexOf(n)&&(t.push(n),o())},this.loadValue=function(t,o){t=void 0===t?o:t;var n=window.localStorage[e+"_"+t];return void 0===n?void 0:JSON.parse(n)},this.reset=function(t){window.localStorage.removeItem(e+"_"+t)},this.resetAll=function(){for(var o=0;t.length>o;o++)window.localStorage.removeItem(e+"_"+t[o]);n()}}function r(){function e(){var e=this;for(var t in r)(0,l.hasOwnProperty)(r,t)&&e.addHook(t,r[t])}function t(){var e=this;for(var t in r)(0,l.hasOwnProperty)(r,t)&&e.removeHook(t,r[t])}var o=this;this.init=function(){var r=this,i=r.getSettings().persistentState;if(!(o.enabled=!!i))return void t.call(r);r.storage||(r.storage=new n(r.rootElement.id)),r.resetState=o.resetValue,e.call(r)},this.saveValue=function(e,t){this.storage.saveValue(e,t)},this.loadValue=function(e,t){t.value=this.storage.loadValue(e)},this.resetValue=function(e){var t=this;void 0===e?t.storage.resetAll():t.storage.reset(e)};var r={persistentStateSave:o.saveValue,persistentStateLoad:o.loadValue,persistentStateReset:o.resetValue};for(var i in r)(0,l.hasOwnProperty)(r,i)&&s.default.getSingleton().register(i)}t.__esModule=!0;var i=o(8),s=function(e){return e&&e.__esModule?e:{default:e}}(i),l=(o(5),o(1)),a=new r;s.default.getSingleton().add("beforeInit",a.init),s.default.getSingleton().add("afterUpdateSettings",a.init),t.default=r},function(e,t,o){"use strict";function n(e){this.query=function(t,o,r){var i=e.countRows(),s=e.countCols(),l=[];o||(o=n.global.getDefaultCallback()),r||(r=n.global.getDefaultQueryMethod());for(var a=0;i>a;a++)for(var u=0;s>u;u++){var c=e.getDataAtCell(a,u),h=e.getCellMeta(a,u),d=h.search.callback||o,f=h.search.queryMethod||r,p=f(t,c);if(p){var g={row:a,col:u,data:c};l.push(g)}d&&d(e,a,u,c,p)}return l}}function r(e,t,o,r,i,l,a){var c=null!==a.search&&"object"==s(a.search)&&a.search.searchResultClass||n.global.getDefaultSearchResultClass();a.isSearchResult?(0,u.addClass)(t,c):(0,u.removeClass)(t,c)}function i(){var e=this;!e.getSettings().search?delete e.search:e.search=new n(e)}t.__esModule=!0;var s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},l=o(8),a=function(e){return e&&e.__esModule?e:{default:e}}(l),u=o(0),c=o(9);n.DEFAULT_CALLBACK=function(e,t,o,n,r){e.getCellMeta(t,o).isSearchResult=r},n.DEFAULT_QUERY_METHOD=function(e,t){return!(void 0===e||null==e||!e.toLowerCase||0===e.length)&&(void 0!==t&&null!=t&&-1!=(""+t).toLowerCase().indexOf(e.toLowerCase()))},n.DEFAULT_SEARCH_RESULT_CLASS="htSearchResult",n.global=function(){var e=n.DEFAULT_CALLBACK,t=n.DEFAULT_QUERY_METHOD,o=n.DEFAULT_SEARCH_RESULT_CLASS;return{getDefaultCallback:function(){return e},setDefaultCallback:function(t){e=t},getDefaultQueryMethod:function(){return t},setDefaultQueryMethod:function(e){t=e},getDefaultSearchResultClass:function(){return o},setDefaultSearchResultClass:function(e){o=e}}}();var h=(0,c.getRenderer)("base");(0,c.registerRenderer)("base",function(e,t,o,n,i,s,l){h.apply(this,arguments),r.apply(this,arguments)}),a.default.getSingleton().add("afterInit",i),a.default.getSingleton().add("afterUpdateSettings",i),t.default=n},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var s=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),l=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},a=o(0),u=o(2),c=o(12),h=function(e){return e&&e.__esModule?e:{default:e}}(c),d=o(5),f=o(34),p=function(e){function t(e){n(this,t);var o=r(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.scrollbars=[],o.clones=[],o.lockedCollection=!1,o.freezeOverlays=!1,o}return i(t,e),s(t,[{key:"isEnabled",value:function(){return(0,f.isTouchSupported)()}},{key:"enablePlugin",value:function(){var e=this;this.enabled||(this.addHook("afterRender",function(){return e.onAfterRender()}),this.registerEvents(),l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{key:"updatePlugin",value:function(){this.lockedCollection=!1,l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"updatePlugin",this).call(this)}},{key:"disablePlugin",value:function(){l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"registerEvents",value:function(){var e=this;this.addHook("beforeTouchScroll",function(){return e.onBeforeTouchScroll()}),this.addHook("afterMomentumScroll",function(){return e.onAfterMomentumScroll()})}},{key:"onAfterRender",value:function(){if(!this.lockedCollection){var e=this.hot.view.wt.wtOverlays,t=e.topOverlay,o=e.bottomOverlay,n=e.leftOverlay,r=e.topLeftCornerOverlay,i=e.bottomLeftCornerOverlay;this.lockedCollection=!0,this.scrollbars.length=0,this.scrollbars.push(t),o.clone&&this.scrollbars.push(o),this.scrollbars.push(n),r&&this.scrollbars.push(r),i&&i.clone&&this.scrollbars.push(i),this.clones.length=0,t.needFullRender&&this.clones.push(t.clone.wtTable.holder.parentNode),o.needFullRender&&this.clones.push(o.clone.wtTable.holder.parentNode),n.needFullRender&&this.clones.push(n.clone.wtTable.holder.parentNode),r&&this.clones.push(r.clone.wtTable.holder.parentNode),i&&i.clone&&this.clones.push(i.clone.wtTable.holder.parentNode)}}},{key:"onBeforeTouchScroll",value:function(){this.freezeOverlays=!0,(0,u.arrayEach)(this.clones,function(e){(0,a.addClass)(e,"hide-tween")})}},{key:"onAfterMomentumScroll",value:function(){var e=this;this.freezeOverlays=!1,(0,u.arrayEach)(this.clones,function(e){(0,a.removeClass)(e,"hide-tween"),(0,a.addClass)(e,"show-tween")}),setTimeout(function(){(0,u.arrayEach)(e.clones,function(e){(0,a.removeClass)(e,"show-tween")})},400),(0,u.arrayEach)(this.scrollbars,function(e){e.refresh(),e.resetFixedPosition()}),this.hot.view.wt.wtOverlays.syncScrollWithMaster()}}]),t}(h.default);(0,d.registerPlugin)("touchScroll",p),t.default=p},function(e,t,o){"use strict";function n(e){var t=this;this.instance=e,this.doneActions=[],this.undoneActions=[],this.ignoreNewActions=!1,e.addHook("afterChange",function(e,o){e&&"UndoRedo.undo"!==o&&"UndoRedo.redo"!==o&&t.done(new n.ChangeAction(e))}),e.addHook("afterCreateRow",function(e,o,r){if("UndoRedo.undo"!==r&&"UndoRedo.undo"!==r&&"auto"!==r){var i=new n.CreateRowAction(e,o);t.done(i)}}),e.addHook("beforeRemoveRow",function(e,o,r,i){if("UndoRedo.undo"!==i&&"UndoRedo.redo"!==i&&"auto"!==i){var s=t.instance.getSourceDataArray();e=(s.length+e)%s.length;var l=(0,f.deepClone)(s.slice(e,e+o));t.done(new n.RemoveRowAction(e,l))}}),e.addHook("afterCreateCol",function(e,o,r){"UndoRedo.undo"!==r&&"UndoRedo.redo"!==r&&"auto"!==r&&t.done(new n.CreateColumnAction(e,o))}),e.addHook("beforeRemoveCol",function(o,r,i,s){if("UndoRedo.undo"!==s&&"UndoRedo.redo"!==s&&"auto"!==s){var l=t.instance.getSourceDataArray();o=(t.instance.countCols()+o)%t.instance.countCols();var a=[],u=[],c=[];(0,d.rangeEach)(l.length-1,function(t){var n=[],i=l[t];(0,d.rangeEach)(o,o+(r-1),function(t){n.push(i[e.runHooks("modifyCol",t)])}),a.push(n)}),(0,d.rangeEach)(r-1,function(t){c.push(e.runHooks("modifyCol",o+t))}),Array.isArray(e.getSettings().colHeaders)&&(0,d.rangeEach)(r-1,function(t){u.push(e.getSettings().colHeaders[e.runHooks("modifyCol",o+t)]||null)});var h=t.instance.getPlugin("manualColumnMove"),f=h.isEnabled()?h.columnsMapper.__arrayMap:[],p=new n.RemoveColumnAction(o,c,a,u,f);t.done(p)}}),e.addHook("beforeCellAlignment",function(e,o,r,i){var s=new n.CellAlignmentAction(e,o,r,i);t.done(s)}),e.addHook("beforeFilter",function(e){t.done(new n.FiltersAction(e))}),e.addHook("beforeRowMove",function(e,o){!1!==e&&t.done(new n.RowMoveAction(e,o))})}function r(){var e=this;void 0===e.getSettings().undo||e.getSettings().undo?e.undoRedo||(e.undoRedo=new n(e),l(e),e.addHook("beforeKeyDown",i),e.addHook("afterChange",s)):e.undoRedo&&(delete e.undoRedo,a(e),e.removeHook("beforeKeyDown",i),e.removeHook("afterChange",s))}function i(e){var t=this;(e.ctrlKey||e.metaKey)&&!e.altKey&&(89===e.keyCode||e.shiftKey&&90===e.keyCode?(t.undoRedo.redo(),(0,p.stopImmediatePropagation)(e)):90===e.keyCode&&(t.undoRedo.undo(),(0,p.stopImmediatePropagation)(e)))}function s(e,t){var o=this;if("loadData"===t)return o.undoRedo.clear()}function l(e){e.undo=function(){return e.undoRedo.undo()},e.redo=function(){return e.undoRedo.redo()},e.isUndoAvailable=function(){return e.undoRedo.isUndoAvailable()},e.isRedoAvailable=function(){return e.undoRedo.isRedoAvailable()},e.clearUndo=function(){return e.undoRedo.clear()}}function a(e){delete e.undo,delete e.redo,delete e.isUndoAvailable,delete e.isRedoAvailable,delete e.clearUndo}var u=o(8),c=function(e){return e&&e.__esModule?e:{default:e}}(u),h=o(2),d=o(6),f=o(1),p=o(7),g=o(11);n.prototype.done=function(e){this.ignoreNewActions||(this.doneActions.push(e),this.undoneActions.length=0)},n.prototype.undo=function(){if(this.isUndoAvailable()){var e=this.doneActions.pop(),t=(0,f.deepClone)(e),o=this.instance;if(!1===o.runHooks("beforeUndo",t))return;this.ignoreNewActions=!0;var n=this;e.undo(this.instance,function(){n.ignoreNewActions=!1,n.undoneActions.push(e)}),o.runHooks("afterUndo",t)}},n.prototype.redo=function(){if(this.isRedoAvailable()){var e=this.undoneActions.pop(),t=(0,f.deepClone)(e),o=this.instance;if(!1===o.runHooks("beforeRedo",t))return;this.ignoreNewActions=!0;var n=this;e.redo(this.instance,function(){n.ignoreNewActions=!1,n.doneActions.push(e)}),o.runHooks("afterRedo",t)}},n.prototype.isUndoAvailable=function(){return this.doneActions.length>0},n.prototype.isRedoAvailable=function(){return this.undoneActions.length>0},n.prototype.clear=function(){this.doneActions.length=0,this.undoneActions.length=0},n.Action=function(){},n.Action.prototype.undo=function(){},n.Action.prototype.redo=function(){},n.ChangeAction=function(e){this.changes=e,this.actionType="change"},(0,f.inherit)(n.ChangeAction,n.Action),n.ChangeAction.prototype.undo=function(e,t){for(var o=(0,f.deepClone)(this.changes),n=e.countEmptyRows(!0),r=e.countEmptyCols(!0),i=0,s=o.length;s>i;i++)o[i].splice(3,1);e.addHookOnce("afterChange",t),e.setDataAtRowProp(o,null,null,"UndoRedo.undo");for(var l=0,a=o.length;a>l;l++)e.getSettings().minSpareRows&&o[l][0]+1+e.getSettings().minSpareRows===e.countRows()&&n==e.getSettings().minSpareRows&&(e.alter("remove_row",parseInt(o[l][0]+1,10),e.getSettings().minSpareRows),e.undoRedo.doneActions.pop()),e.getSettings().minSpareCols&&o[l][1]+1+e.getSettings().minSpareCols===e.countCols()&&r==e.getSettings().minSpareCols&&(e.alter("remove_col",parseInt(o[l][1]+1,10),e.getSettings().minSpareCols),e.undoRedo.doneActions.pop())},n.ChangeAction.prototype.redo=function(e,t){for(var o=(0,f.deepClone)(this.changes),n=0,r=o.length;r>n;n++)o[n].splice(2,1);e.addHookOnce("afterChange",t),e.setDataAtRowProp(o,null,null,"UndoRedo.redo")},n.CreateRowAction=function(e,t){this.index=e,this.amount=t,this.actionType="insert_row"},(0,f.inherit)(n.CreateRowAction,n.Action),n.CreateRowAction.prototype.undo=function(e,t){var o=e.countRows(),n=e.getSettings().minSpareRows;this.index>=o&&o>this.index-n&&(this.index-=n),e.addHookOnce("afterRemoveRow",t),e.alter("remove_row",this.index,this.amount,"UndoRedo.undo")},n.CreateRowAction.prototype.redo=function(e,t){e.addHookOnce("afterCreateRow",t),e.alter("insert_row",this.index,this.amount,"UndoRedo.redo")},n.RemoveRowAction=function(e,t){this.index=e,this.data=t,this.actionType="remove_row"},(0,f.inherit)(n.RemoveRowAction,n.Action),n.RemoveRowAction.prototype.undo=function(e,t){e.alter("insert_row",this.index,this.data.length,"UndoRedo.undo"),e.addHookOnce("afterRender",t),e.populateFromArray(this.index,0,this.data,void 0,void 0,"UndoRedo.undo")},n.RemoveRowAction.prototype.redo=function(e,t){e.addHookOnce("afterRemoveRow",t),e.alter("remove_row",this.index,this.data.length,"UndoRedo.redo")},n.CreateColumnAction=function(e,t){this.index=e,this.amount=t,this.actionType="insert_col"},(0,f.inherit)(n.CreateColumnAction,n.Action),n.CreateColumnAction.prototype.undo=function(e,t){e.addHookOnce("afterRemoveCol",t),e.alter("remove_col",this.index,this.amount,"UndoRedo.undo")},n.CreateColumnAction.prototype.redo=function(e,t){e.addHookOnce("afterCreateCol",t),e.alter("insert_col",this.index,this.amount,"UndoRedo.redo")},n.RemoveColumnAction=function(e,t,o,n,r){this.index=e,this.indexes=t,this.data=o,this.amount=this.data[0].length,this.headers=n,this.columnPositions=r.slice(0),this.actionType="remove_col"},(0,f.inherit)(n.RemoveColumnAction,n.Action),n.RemoveColumnAction.prototype.undo=function(e,t){var o=this,n=void 0,r=this.indexes.slice(0).sort(),i=function(e,t,n){return n[o.indexes.indexOf(r[t])]},s=[];(0,d.rangeEach)(this.data.length-1,function(e){s[e]=(0,h.arrayMap)(o.data[e],i)});var l=[];l=(0,h.arrayMap)(this.headers,i);var a=[];e.runHooks("beforeCreateCol",this.indexes[0],this.indexes[this.indexes.length-1],"UndoRedo.undo"),(0,d.rangeEach)(this.data.length-1,function(t){n=e.getSourceDataAtRow(t),(0,d.rangeEach)(r.length-1,function(e){n.splice(r[e],0,s[t][e]),a.push([t,r[e],null,s[t][e]])})}),e.getPlugin("formulas")&&e.getPlugin("formulas").onAfterSetDataAtCell(a),void 0!==this.headers&&(0,d.rangeEach)(l.length-1,function(t){e.getSettings().colHeaders.splice(r[t],0,l[t])}),e.getPlugin("manualColumnMove")&&(e.getPlugin("manualColumnMove").columnsMapper.__arrayMap=this.columnPositions),e.addHookOnce("afterRender",t),e.runHooks("afterCreateCol",this.indexes[0],this.indexes[this.indexes.length-1],"UndoRedo.undo"),e.getPlugin("formulas")&&e.getPlugin("formulas").recalculateFull(),e.render()},n.RemoveColumnAction.prototype.redo=function(e,t){e.addHookOnce("afterRemoveCol",t),e.alter("remove_col",this.index,this.amount,"UndoRedo.redo")},n.CellAlignmentAction=function(e,t,o,n){this.stateBefore=e,this.range=t,this.type=o,this.alignment=n},n.CellAlignmentAction.prototype.undo=function(e,t){if(e.getPlugin("contextMenu").isEnabled()){for(var o=this.range.from.row;this.range.to.row>=o;o++)for(var n=this.range.from.col;this.range.to.col>=n;n++)e.setCellMeta(o,n,"className",this.stateBefore[o][n]||" htLeft");e.addHookOnce("afterRender",t),e.render()}},n.CellAlignmentAction.prototype.redo=function(e,t){e.getPlugin("contextMenu").isEnabled()&&(e.selectCell(this.range.from.row,this.range.from.col,this.range.to.row,this.range.to.col),e.getPlugin("contextMenu").executeCommand("alignment:"+this.alignment.replace("ht","").toLowerCase()),e.addHookOnce("afterRender",t),e.render())},n.FiltersAction=function(e){this.conditionsStack=e,this.actionType="filter"},(0,f.inherit)(n.FiltersAction,n.Action),n.FiltersAction.prototype.undo=function(e,t){var o=e.getPlugin("filters");e.addHookOnce("afterRender",t),o.conditionCollection.importAllConditions(this.conditionsStack.slice(0,this.conditionsStack.length-1)),o.filter()},n.FiltersAction.prototype.redo=function(e,t){var o=e.getPlugin("filters");e.addHookOnce("afterRender",t),o.conditionCollection.importAllConditions(this.conditionsStack),o.filter()},n.RowMoveAction=function(e,t){this.rows=e.slice(),this.target=t},(0,f.inherit)(n.RowMoveAction,n.Action),n.RowMoveAction.prototype.undo=function(e,t){var o=e.getPlugin("manualRowMove");e.addHookOnce("afterRender",t);for(var n=this.target>this.rows[0]?-1*this.rows.length:0,r=this.rows[0]>this.target?this.rows[0]+this.rows.length:this.rows[0],i=[],s=this.rows.length+n,l=n;s>l;l++)i.push(this.target+l);o.moveRows(i.slice(),r),e.render(),e.selection.setRangeStartOnly(new g.CellCoords(this.rows[0],0)),e.selection.setRangeEnd(new g.CellCoords(this.rows[this.rows.length-1],e.countCols()-1))},n.RowMoveAction.prototype.redo=function(e,t){var o=e.getPlugin("manualRowMove");e.addHookOnce("afterRender",t),o.moveRows(this.rows.slice(),this.target),e.render();var n=this.target>this.rows[0]?this.target-this.rows.length:this.target;e.selection.setRangeStartOnly(new g.CellCoords(n,0)),e.selection.setRangeEnd(new g.CellCoords(n+this.rows.length-1,e.countCols()-1))};var v=c.default.getSingleton();v.add("afterInit",r),v.add("afterUpdateSettings",r),v.register("beforeUndo"),v.register("afterUndo"),v.register("beforeRedo"),v.register("afterRedo")},function(e,t,o){"use strict";function n(e,t,o,n,i,s,l){l.className&&(t.className=t.className?t.className+" "+l.className:l.className),l.readOnly&&(0,r.addClass)(t,l.readOnlyCellClassName),!1===l.valid&&l.invalidCellClassName?(0,r.addClass)(t,l.invalidCellClassName):(0,r.removeClass)(t,l.invalidCellClassName),!1===l.wordWrap&&l.noWordWrapClassName&&(0,r.addClass)(t,l.noWordWrapClassName),!s&&l.placeholder&&(0,r.addClass)(t,l.placeholderCellClassName)}t.__esModule=!0;var r=o(0);t.default=n},function(e,t,o){"use strict";function n(e,t,o,n,i,h,d){var f=(u.cloneNode(!0),c.cloneNode(!0));if(d.allowHtml?(0,a.getRenderer)("html").apply(this,arguments):(0,a.getRenderer)("text").apply(this,arguments),t.appendChild(f),(0,r.addClass)(t,"htAutocomplete"),t.firstChild||t.appendChild(document.createTextNode(String.fromCharCode(160))),!e.acArrowListener){var p=new s.default(e);e.acArrowListener=function(i){(0,r.hasClass)(i.target,"htAutocompleteArrow")&&e.view.wt.getSetting("onCellDblClick",null,new l.CellCoords(o,n),t)},p.addEventListener(e.rootElement,"mousedown",e.acArrowListener),e.addHookOnce("afterDestroy",function(){p.destroy()})}}t.__esModule=!0;var r=o(0),i=o(4),s=function(e){return e&&e.__esModule?e:{default:e}}(i),l=o(11),a=o(9),u=document.createElement("DIV");u.className="htAutocompleteWrapper";var c=document.createElement("DIV");c.className="htAutocompleteArrow",c.appendChild(document.createTextNode(String.fromCharCode(9660)));t.default=n},function(e,t,o){"use strict";function n(e,t,o,n,l,a,u){function c(e){var t=(0,v.partial)(g.isKey,e.keyCode);t("SPACE|ENTER|DELETE|BACKSPACE")&&!(0,m.isImmediatePropagationStopped)(e)&&p(function(){(0,m.stopImmediatePropagation)(e),e.preventDefault()}),t("SPACE|ENTER")&&f(),t("DELETE|BACKSPACE")&&f(!0)}function f(){var t=arguments.length>0&&void 0!==arguments[0]&&arguments[0],o=e.getSelectedRange();if(o){for(var n=o.getTopLeftCorner(),r=o.getBottomRightCorner(),i=[],s=n.row;r.row>=s;s+=1)for(var l=n.col;r.col>=l;l+=1){var a=e.getCellMeta(s,l);if("checkbox"!==a.type)return;if(!0!==a.readOnly){void 0===a.checkedTemplate&&(a.checkedTemplate=!0),void 0===a.uncheckedTemplate&&(a.uncheckedTemplate=!1);var u=e.getDataAtCell(s,l);!1===t?u===a.checkedTemplate?i.push([s,l,a.uncheckedTemplate]):-1!==[a.uncheckedTemplate,null,void 0].indexOf(u)&&i.push([s,l,a.checkedTemplate]):i.push([s,l,a.uncheckedTemplate])}}i.length>0&&e.setDataAtCell(i)}}function p(t){var o=e.getSelectedRange();if(o)for(var n=o.getTopLeftCorner(),r=o.getBottomRightCorner(),i=n.row;r.row>=i;i++)for(var s=n.col;r.col>=s;s++){var l=e.getCellMeta(i,s);if("checkbox"!==l.type)return;var a=e.getCell(i,s);if(null==a)t(i,s,l);else{var u=a.querySelectorAll("input[type=checkbox]");u.length>0&&!l.readOnly&&t(u)}}}(0,y.getRenderer)("base").apply(this,arguments);var C=(r(e),i()),S=u.label,E=!1;if(void 0===u.checkedTemplate&&(u.checkedTemplate=!0),void 0===u.uncheckedTemplate&&(u.uncheckedTemplate=!1),(0,h.empty)(t),a===u.checkedTemplate||(0,d.equalsIgnoreCase)(a,u.checkedTemplate)?C.checked=!0:a===u.uncheckedTemplate||(0,d.equalsIgnoreCase)(a,u.uncheckedTemplate)?C.checked=!1:null===a?(0,h.addClass)(C,"noValue"):(C.style.display="none",(0,h.addClass)(C,b),E=!0),C.setAttribute("data-row",o),C.setAttribute("data-col",n),!E&&S){var R="";S.value?R="function"==typeof S.value?S.value.call(this,o,n,l,a):S.value:S.property&&(R=e.getDataAtRowProp(o,S.property));var O=s(R);"before"===S.position?O.appendChild(C):O.insertBefore(C,O.firstChild),C=O}t.appendChild(C),E&&t.appendChild(document.createTextNode("#bad-value#")),w.has(e)||(w.set(e,!0),e.addHook("beforeKeyDown",c))}function r(e){var t=C.get(e);return t||(t=new p.default(e),t.addEventListener(e.rootElement,"click",function(t){return a(t,e)}),t.addEventListener(e.rootElement,"mouseup",function(t){return l(t,e)}),t.addEventListener(e.rootElement,"change",function(t){return u(t,e)}),C.set(e,t)),t}function i(){var e=document.createElement("input");return e.className="htCheckboxRendererInput",e.type="checkbox",e.setAttribute("autocomplete","off"),e.setAttribute("tabindex","-1"),e.cloneNode(!1)}function s(e){var t=document.createElement("label");return t.className="htCheckboxRendererLabel",t.appendChild(document.createTextNode(e)),t.cloneNode(!0)}function l(e,t){c(e.target)&&setTimeout(t.listen,10)}function a(e,t){if(!c(e.target))return!1;t.getCellMeta(parseInt(e.target.getAttribute("data-row"),10),parseInt(e.target.getAttribute("data-col"),10)).readOnly&&e.preventDefault()}function u(e,t){if(!c(e.target))return!1;var o=parseInt(e.target.getAttribute("data-row"),10),n=parseInt(e.target.getAttribute("data-col"),10),r=t.getCellMeta(o,n);if(!r.readOnly){var i=null;i=e.target.checked?void 0===r.uncheckedTemplate||r.checkedTemplate:void 0!==r.uncheckedTemplate&&r.uncheckedTemplate,t.setDataAtCell(o,n,i)}}function c(e){return"INPUT"===e.tagName&&"checkbox"===e.getAttribute("type")}t.__esModule=!0;var h=o(0),d=o(27),f=o(4),p=function(e){return e&&e.__esModule?e:{default:e}}(f),g=o(16),v=o(35),m=o(7),y=o(9),w=new WeakMap,C=new WeakMap,b="htBadValue";t.default=n},function(e,t,o){"use strict";function n(e,t,o,n,s,l,a){(0,i.getRenderer)("base").apply(this,arguments),null!==l&&void 0!==l||(l=""),(0,r.fastInnerHTML)(t,l)}t.__esModule=!0;var r=o(0),i=o(9);t.default=n},function(e,t,o){"use strict";function n(e,t,o,n,r,a,u){if((0,l.isNumeric)(a)){void 0!==u.language&&i.default.culture(u.language),a=(0,i.default)(a).format(u.format||"0");var c=u.className||"",h=c.length?c.split(" "):[];0>h.indexOf("htLeft")&&0>h.indexOf("htCenter")&&0>h.indexOf("htRight")&&0>h.indexOf("htJustify")&&h.push("htRight"),0>h.indexOf("htNumeric")&&h.push("htNumeric"),u.className=h.join(" ")}(0,s.getRenderer)("text")(e,t,o,n,r,a,u)}t.__esModule=!0;var r=o(87),i=function(e){return e&&e.__esModule?e:{default:e}}(r),s=o(9),l=o(6);t.default=n},function(e,t,o){"use strict";function n(e,t,o,n,l,a,u){(0,i.getRenderer)("text").apply(this,arguments),a=t.innerHTML;var c=u.hashLength||a.length,h=u.hashSymbol||"*",d="";(0,s.rangeEach)(c-1,function(){d+=h}),(0,r.fastInnerHTML)(t,d)}t.__esModule=!0;var r=o(0),i=o(9),s=o(6);t.default=n},function(e,t,o){"use strict";function n(e,t,o,n,l,a,u){(0,s.getRenderer)("base").apply(this,arguments),!a&&u.placeholder&&(a=u.placeholder);var c=(0,i.stringify)(a);if(e.getSettings().trimWhitespace||(c=c.replace(/ /g,String.fromCharCode(160))),u.rendererTemplate){(0,r.empty)(t);var h=document.createElement("TEMPLATE");h.setAttribute("bind","{{}}"),h.innerHTML=u.rendererTemplate,HTMLTemplateElement.decorate(h),h.model=e.getSourceDataAtRow(o),t.appendChild(h)}else(0,r.fastInnerText)(t,c)}t.__esModule=!0;var r=o(0),i=o(20),s=o(9);t.default=n},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e){var t=this,o=this;this.eventManager=new u.default(e),this.instance=e,this.settings=e.getSettings(),this.selectionMouseDown=!1;var n=e.rootElement.getAttribute("style");n&&e.rootElement.setAttribute("data-originalstyle",n),(0,s.addClass)(e.rootElement,"handsontable");var r=document.createElement("TABLE");(0,s.addClass)(r,"htCore"),e.getSettings().tableClassName&&(0,s.addClass)(r,e.getSettings().tableClassName),this.THEAD=document.createElement("THEAD"),r.appendChild(this.THEAD),this.TBODY=document.createElement("TBODY"),r.appendChild(this.TBODY),e.table=r,e.container.insertBefore(r,e.container.firstChild),this.eventManager.addEventListener(e.rootElement,"mousedown",function(e){this.selectionMouseDown=!0,o.isTextSelectionAllowed(e.target)||(a(),e.preventDefault(),window.focus())}),this.eventManager.addEventListener(e.rootElement,"mouseup",function(e){this.selectionMouseDown=!1}),this.eventManager.addEventListener(e.rootElement,"mousemove",function(e){this.selectionMouseDown&&!o.isTextSelectionAllowed(e.target)&&(a(),e.preventDefault())}),this.eventManager.addEventListener(document.documentElement,"keyup",function(t){e.selection.isInProgress()&&!t.shiftKey&&e.selection.finish()});var i;this.isMouseDown=function(){return i},this.eventManager.addEventListener(document.documentElement,"mouseup",function(t){e.selection.isInProgress()&&1===t.which&&e.selection.finish(),i=!1,!(0,s.isOutsideInput)(document.activeElement)&&e.selection.isSelected()||e.unlisten()}),this.eventManager.addEventListener(document.documentElement,"mousedown",function(t){var n=t.target,r=t.target,l=t.x||t.clientX,a=t.y||t.clientY;if(!i&&e.rootElement){if(r===e.view.wt.wtTable.holder){var u=(0,s.getScrollbarWidth)();if(document.elementFromPoint(l+u,a)!==e.view.wt.wtTable.holder||document.elementFromPoint(l,a+u)!==e.view.wt.wtTable.holder)return}else for(;r!==document.documentElement;){if(null===r){if(t.isTargetWebComponent)break;return}if(r===e.rootElement)return;r=r.parentNode}("function"==typeof o.settings.outsideClickDeselects?o.settings.outsideClickDeselects(n):o.settings.outsideClickDeselects)?e.deselectCell():e.destroyEditor()}}),this.eventManager.addEventListener(r,"selectstart",function(e){o.settings.fragmentSelection||(0,s.isInput)(e.target)||e.preventDefault()});var a=function(){window.getSelection?window.getSelection().empty?window.getSelection().empty():window.getSelection().removeAllRanges&&window.getSelection().removeAllRanges():document.selection&&document.selection.empty()},f=[new h.Selection({className:"current",border:{width:2,color:"#5292F7",cornerVisible:function(){return o.settings.fillHandle&&!o.isCellEdited()&&!e.selection.isMultiple()},multipleSelectionHandlesVisible:function(){return!o.isCellEdited()&&!e.selection.isMultiple()}}}),new h.Selection({className:"area",border:{width:1,color:"#89AFF9",cornerVisible:function(){return o.settings.fillHandle&&!o.isCellEdited()&&e.selection.isMultiple()},multipleSelectionHandlesVisible:function(){return!o.isCellEdited()&&e.selection.isMultiple()}}}),new h.Selection({className:"highlight",highlightHeaderClassName:o.settings.currentHeaderClassName,highlightRowClassName:o.settings.currentRowClassName,highlightColumnClassName:o.settings.currentColClassName}),new h.Selection({className:"fill",border:{width:1,color:"red"}})];f.current=f[0],f.area=f[1],f.highlight=f[2],f.fill=f[3];var p={debug:function(){return o.settings.debug},externalRowCalculator:this.instance.getPlugin("autoRowSize")&&this.instance.getPlugin("autoRowSize").isEnabled(),table:r,preventOverflow:function(){return t.settings.preventOverflow},stretchH:function(){return o.settings.stretchH},data:e.getDataAtCell,totalRows:function(){return e.countRows()},totalColumns:function(){return e.countCols()},fixedColumnsLeft:function(){return o.settings.fixedColumnsLeft},fixedRowsTop:function(){return o.settings.fixedRowsTop},fixedRowsBottom:function(){return o.settings.fixedRowsBottom},minSpareRows:function(){return o.settings.minSpareRows},renderAllRows:o.settings.renderAllRows,rowHeaders:function(){var t=[];return e.hasRowHeaders()&&t.push(function(e,t){o.appendRowHeader(e,t)}),e.runHooks("afterGetRowHeaderRenderers",t),t},columnHeaders:function(){var t=[];return e.hasColHeaders()&&t.push(function(e,t){o.appendColHeader(e,t)}),e.runHooks("afterGetColumnHeaderRenderers",t),t},columnWidth:e.getColWidth,rowHeight:e.getRowHeight,cellRenderer:function(e,t,n){var r=o.instance.getCellMeta(e,t),i=o.instance.colToProp(t),s=o.instance.getDataAtRowProp(e,i);o.instance.hasHook("beforeValueRender")&&(s=o.instance.runHooks("beforeValueRender",s)),o.instance.runHooks("beforeRenderer",n,e,t,i,s,r),o.instance.getCellRenderer(r)(o.instance,n,e,t,i,s,r),o.instance.runHooks("afterRenderer",n,e,t,i,s,r)},selections:f,hideBorderOnMouseDownOver:function(){return o.settings.fragmentSelection},onCellMouseDown:function(t,n,r,s){var l={row:!1,column:!1,cells:!1};if(e.listen(),o.activeWt=s,i=!0,e.runHooks("beforeOnCellMouseDown",t,n,r,l),!(0,c.isImmediatePropagationStopped)(t)){var a=e.getSelectedRange(),u=e.selection,d=u.selectedHeader;if(t.shiftKey&&a)0>n.row||0>n.col||l.cells?!d.cols&&!d.rows||0>n.row||0>n.col||l.cells?d.cols&&0>n.row&&!l.column?u.setRangeEnd(new h.CellCoords(a.to.row,n.col)):d.rows&&0>n.col&&!l.row?u.setRangeEnd(new h.CellCoords(n.row,a.to.col)):(!d.cols&&!d.rows&&0>n.col||d.cols&&0>n.col)&&!l.row?(u.setSelectedHeaders(!0,!1),u.setRangeStartOnly(new h.CellCoords(a.from.row,0)),u.setRangeEnd(new h.CellCoords(n.row,e.countCols()-1))):(!d.cols&&!d.rows&&0>n.row||d.rows&&0>n.row)&&!l.column&&(u.setSelectedHeaders(!1,!0),u.setRangeStartOnly(new h.CellCoords(0,a.from.col)),u.setRangeEnd(new h.CellCoords(e.countRows()-1,n.col))):(u.setSelectedHeaders(!1,!1),u.setRangeEnd(new h.CellCoords(n.row,n.col))):(u.setSelectedHeaders(!1,!1),u.setRangeEnd(n));else{var f=!0;if(a){var p=a.from,g=a.to,v=!u.inInSelection(n);if(0>n.row&&d.cols){var m=Math.min(p.col,g.col),y=Math.max(p.col,g.col);f=m>n.col||n.col>y}else if(0>n.col&&d.rows){var w=Math.min(p.row,g.row),C=Math.max(p.row,g.row);f=w>n.row||n.row>C}else f=v}var b=(0,c.isRightClick)(t),S=(0,c.isLeftClick)(t)||"touchstart"===t.type;n.row>=0||0>n.col||l.column?n.col>=0||0>n.row||l.row?0>n.col||0>n.row||l.cells?0>n.col&&0>n.row&&(n.row=0,n.col=0,u.setSelectedHeaders(!1,!1,!0),u.setRangeStart(n)):(S||b&&f)&&(u.setSelectedHeaders(!1,!1),u.setRangeStart(n)):(u.setSelectedHeaders(!0,!1),(S||b&&f)&&(u.setRangeStartOnly(new h.CellCoords(n.row,0)),u.setRangeEnd(new h.CellCoords(n.row,Math.max(e.countCols()-1,0)),!1))):(u.setSelectedHeaders(!1,!0),(S||b&&f)&&(u.setRangeStartOnly(new h.CellCoords(0,n.col)),u.setRangeEnd(new h.CellCoords(Math.max(e.countRows()-1,0),n.col),!1)))}e.runHooks("afterOnCellMouseDown",t,n,r),o.activeWt=o.wt}},onCellMouseOut:function(t,n,r,i){o.activeWt=i,e.runHooks("beforeOnCellMouseOut",t,n,r),(0,c.isImmediatePropagationStopped)(t)||(e.runHooks("afterOnCellMouseOut",t,n,r),o.activeWt=o.wt)},onCellMouseOver:function(t,n,r,s){var l={row:!1,column:!1,cell:!1};o.activeWt=s,e.runHooks("beforeOnCellMouseOver",t,n,r,l),(0,c.isImmediatePropagationStopped)(t)||(0===t.button&&i&&(e.selection.selectedHeader.cols&&!l.column?e.selection.setRangeEnd(new h.CellCoords(e.countRows()-1,n.col),!1):e.selection.selectedHeader.rows&&!l.row?e.selection.setRangeEnd(new h.CellCoords(n.row,e.countCols()-1),!1):l.cell||e.selection.setRangeEnd(n)),e.runHooks("afterOnCellMouseOver",t,n,r),o.activeWt=o.wt)},onCellMouseUp:function(t,n,r,i){o.activeWt=i,e.runHooks("beforeOnCellMouseUp",t,n,r),e.runHooks("afterOnCellMouseUp",t,n,r),o.activeWt=o.wt},onCellCornerMouseDown:function(t){t.preventDefault(),e.runHooks("afterOnCellCornerMouseDown",t)},onCellCornerDblClick:function(t){t.preventDefault(),e.runHooks("afterOnCellCornerDblClick",t)},beforeDraw:function(e,t){o.beforeRender(e,t)},onDraw:function(e){o.onDraw(e)},onScrollVertically:function(){e.runHooks("afterScrollVertically")},onScrollHorizontally:function(){e.runHooks("afterScrollHorizontally")},onBeforeDrawBorders:function(t,o){e.runHooks("beforeDrawBorders",t,o)},onBeforeTouchScroll:function(){e.runHooks("beforeTouchScroll")},onAfterMomentumScroll:function(){e.runHooks("afterMomentumScroll")},onBeforeStretchingColumnWidth:function(t,o){return e.runHooks("beforeStretchingColumnWidth",t,o)},onModifyRowHeaderWidth:function(t){return e.runHooks("modifyRowHeaderWidth",t)},viewportRowCalculatorOverride:function(t){var n=e.countRows(),r=o.settings.viewportRowRenderingOffset;if("auto"===r&&o.settings.fixedRowsTop&&(r=10),"number"==typeof r&&(t.startRow=Math.max(t.startRow-r,0),t.endRow=Math.min(t.endRow+r,n-1)),"auto"===r){var i=t.startRow+t.endRow-t.startRow,s=Math.ceil(i/n*12);t.startRow=Math.max(t.startRow-s,0),t.endRow=Math.min(t.endRow+s,n-1)}e.runHooks("afterViewportRowCalculatorOverride",t)},viewportColumnCalculatorOverride:function(t){var n=e.countCols(),r=o.settings.viewportColumnRenderingOffset;if("auto"===r&&o.settings.fixedColumnsLeft&&(r=10),"number"==typeof r&&(t.startColumn=Math.max(t.startColumn-r,0),t.endColumn=Math.min(t.endColumn+r,n-1)),"auto"===r){var i=t.startColumn+t.endColumn-t.startColumn,s=Math.ceil(i/n*12);t.startRow=Math.max(t.startColumn-s,0),t.endColumn=Math.min(t.endColumn+s,n-1)}e.runHooks("afterViewportColumnCalculatorOverride",t)},rowHeaderWidth:function(){return o.settings.rowHeaderWidth},columnHeaderHeight:function(){var t=e.runHooks("modifyColumnHeaderHeight");return o.settings.columnHeaderHeight||t}};e.runHooks("beforeInitWalkontable",p),this.wt=new d.default(p),this.activeWt=this.wt,(0,l.isChrome)()||(0,l.isSafari)()||this.eventManager.addEventListener(e.rootElement,"wheel",function(e){e.preventDefault();var t=parseInt((0,s.getComputedStyle)(document.body)["font-size"],10),n=o.wt.wtOverlays.scrollableElement,r=e.wheelDeltaY||e.deltaY,i=e.wheelDeltaX||e.deltaX;switch(e.deltaMode){case 0:n.scrollLeft+=i,n.scrollTop+=r;break;case 1:n.scrollLeft+=i*t,n.scrollTop+=r*t}}),this.eventManager.addEventListener(o.wt.wtTable.spreader,"mousedown",function(e){e.target===o.wt.wtTable.spreader&&3===e.which&&(0,c.stopPropagation)(e)}),this.eventManager.addEventListener(o.wt.wtTable.spreader,"contextmenu",function(e){e.target===o.wt.wtTable.spreader&&3===e.which&&(0,c.stopPropagation)(e)}),this.eventManager.addEventListener(document.documentElement,"click",function(){o.settings.observeDOMVisibility&&o.wt.drawInterrupted&&(o.instance.forceFullRender=!0,o.render())})}t.__esModule=!0;var i=function(){function e(e,t){var o=[],n=!0,r=!1,i=void 0;try{for(var s,l=e[Symbol.iterator]();!(n=(s=l.next()).done)&&(o.push(s.value),!t||o.length!==t);n=!0);}catch(e){r=!0,i=e}finally{try{!n&&l.return&&l.return()}finally{if(r)throw i}}return o}return function(t,o){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,o);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),s=o(0),l=o(25),a=o(4),u=n(a),c=o(7),h=o(11),d=n(h);r.prototype.isTextSelectionAllowed=function(e){if((0,s.isInput)(e))return!0;var t=(0,s.isChildOf)(e,this.instance.view.wt.wtTable.spreader);return!(!0!==this.settings.fragmentSelection||!t)||(!("cell"!==this.settings.fragmentSelection||!this.isSelectedOnlyCell()||!t)||!(this.settings.fragmentSelection||!this.isCellEdited()||!this.isSelectedOnlyCell()))},r.prototype.isSelectedOnlyCell=function(){var e=this.instance.getSelected()||[],t=i(e,4),o=t[0],n=t[1],r=t[2],s=t[3];return void 0!==o&&o===r&&n===s},r.prototype.isCellEdited=function(){var e=this.instance.getActiveEditor();return e&&e.isOpened()},r.prototype.beforeRender=function(e,t){e&&this.instance.runHooks("beforeRender",this.instance.forceFullRender,t)},r.prototype.onDraw=function(e){e&&this.instance.runHooks("afterRender",this.instance.forceFullRender)},r.prototype.render=function(){this.wt.draw(!this.instance.forceFullRender),this.instance.forceFullRender=!1,this.instance.renderCall=!1},r.prototype.getCellAtCoords=function(e,t){var o=this.wt.getCell(e,t);return 0>o?null:o},r.prototype.scrollViewport=function(e){this.wt.scrollViewport(e)},r.prototype.appendRowHeader=function(e,t){if(t.firstChild){var o=t.firstChild;if(!(0,s.hasClass)(o,"relative"))return(0,s.empty)(t),void this.appendRowHeader(e,t);this.updateCellHeader(o.querySelector(".rowHeader"),e,this.instance.getRowHeader)}else{var n=document.createElement("div"),r=document.createElement("span");n.className="relative",r.className="rowHeader",this.updateCellHeader(r,e,this.instance.getRowHeader),n.appendChild(r),t.appendChild(n)}this.instance.runHooks("afterGetRowHeader",e,t)},r.prototype.appendColHeader=function(e,t){if(t.firstChild){var o=t.firstChild;(0,s.hasClass)(o,"relative")?this.updateCellHeader(o.querySelector(".colHeader"),e,this.instance.getColHeader):((0,s.empty)(t),this.appendColHeader(e,t))}else{var n=document.createElement("div"),r=document.createElement("span");n.className="relative",r.className="colHeader",this.updateCellHeader(r,e,this.instance.getColHeader),n.appendChild(r),t.appendChild(n)}this.instance.runHooks("afterGetColHeader",e,t)},r.prototype.updateCellHeader=function(e,t,o){var n=t,r=this.wt.wtOverlays.getParentOverlay(e)||this.wt;e.parentNode&&((0,s.hasClass)(e,"colHeader")?n=r.wtTable.columnFilter.sourceToRendered(t):(0,s.hasClass)(e,"rowHeader")&&(n=r.wtTable.rowFilter.sourceToRendered(t))),n>-1?(0,s.fastInnerHTML)(e,o(t)):((0,s.fastInnerText)(e,String.fromCharCode(160)),(0,s.addClass)(e,"cornerHeader"))},r.prototype.maximumVisibleElementWidth=function(e){var t=this.wt.wtViewport.getWorkspaceWidth(),o=t-e;return o>0?o:0},r.prototype.maximumVisibleElementHeight=function(e){var t=this.wt.wtViewport.getWorkspaceHeight(),o=t-e;return o>0?o:0},r.prototype.mainViewIsActive=function(){return this.wt===this.activeWt},r.prototype.destroy=function(){this.wt.destroy(),this.eventManager.destroy()},t.default=r},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=function e(t){n(this,e),this.data=t,this.next=null,this.prev=null},s=function(){function e(){n(this,e),this.first=null,this.last=null}return r(e,[{key:"push",value:function(e){var t=new i(e);if(null===this.first)this.first=t,this.last=t;else{var o=this.last;this.last=t,t.prev=o,o.next=t}}},{key:"unshift",value:function(e){var t=new i(e);if(null===this.first)this.first=t,this.last=t;else{var o=this.first;this.first=t,t.next=o,o.prev=t}}},{key:"inorder",value:function(e){for(var t=this.first;t;)e(t),t=t.next}},{key:"remove",value:function(e){if(null===this.first)return!1;for(var t=this.first,o=void 0,n=void 0;t;){if(t.data===e)return o=t.next,n=t.prev,o&&(o.prev=n),n&&(n.next=o),t===this.first&&(this.first=o),t===this.last&&(this.last=n),!0;t=t.next}return!1}},{key:"hasCycle",value:function(){for(var e=this.first,t=this.first;;){if(null===e)return!1;if(null===(e=e.next))return!1;if(e=e.next,t=t.next,e===t)return!0}}},{key:"pop",value:function(){if(null===this.last)return null;var e=this.last;return this.last=this.last.prev,e}},{key:"shift",value:function(){if(null===this.first)return null;var e=this.first;return this.first=this.first.next,e}},{key:"recursiveReverse",value:function(){function e(t,o){o&&(e(o,o.next),o.next=t)}if(this.first){e(this.first,this.first.next),this.first.next=null;var t=this.first;this.first=this.last,this.last=t}}},{key:"reverse",value:function(){if(this.first&&this.first.next){for(var e=this.first.next,t=this.first,o=void 0;e;)o=e.next,e.next=t,t.prev=e,t=e,e=o;this.first.next=null,this.last.prev=null,o=this.first,this.first=t,this.last=o}}}]),e}();t.NodeStructure=i,t.default=s},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e){return"string"==typeof e&&/fps$/.test(e)&&(e=1e3/parseInt(e.replace("fps","")||0,10)),e}t.__esModule=!0;var i=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}();t.parseDelay=r;var s=o(34);t.default=function(){function e(t,o){var i=this;n(this,e),this.timer=null,this.func=t,this.delay=r(o),this.stopped=!0,this._then=null,this._callback=function(){return i.__callback()}}return i(e,null,[{key:"create",value:function(t,o){return new e(t,o)}}]),i(e,[{key:"start",value:function(){return this.stopped&&(this._then=Date.now(),this.stopped=!1,this.timer=(0,s.requestAnimationFrame)(this._callback)),this}},{key:"stop",value:function(){return this.stopped||(this.stopped=!0,(0,s.cancelAnimationFrame)(this.timer),this.timer=null),this}},{key:"__callback",value:function(){if(this.timer=(0,s.requestAnimationFrame)(this._callback),this.delay){var e=Date.now(),t=e-this._then;t>this.delay&&(this._then=e-t%this.delay,this.func())}else this.func()}}]),e}()},function(e,t,o){"use strict";function n(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:l,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:e.length;if(1>=Math.abs(i-o))return[];var s=Math.ceil((o+i)/2);return n(e,t,o,s),n(e,t,s,i),r(e,t,o,s,i)}function r(e,t,o,n,r){for(var i=new s.default,l=new s.default,a=n-o,u=r-n,c=Math.max(a,u),h=r-o,d=0;c>d;d+=1)a>d&&i.push(e[o+d]),u>d&&l.push(e[n+d]);for(var f=0;h>f;)e[o+f]=i.first&&l.first?t(i.first.data,l.first.data)>0?l.shift().data:i.shift().data:i.first?i.shift().data:l.shift().data,f+=1;return e}t.__esModule=!0,t.default=n,t.merge=r;var i=o(272),s=function(e){return e&&e.__esModule?e:{default:e}}(i),l=function(e,t){var o=""+e,n=""+t;return o===n?0:n>o?-1:1}},function(e,t,o){"use strict";function n(e,t){if(null==e&&(e=""),this.allowEmpty&&""===e)return void t(!0);this.strict&&this.source?"function"==typeof this.source?this.source(e,r(e,t)):r(e,t)(this.source):t(!0)}function r(e,t){var o=e;return function(e){for(var n=!1,r=0,i=e.length;i>r;r++)if(o===e[r]){n=!0;break}t(n)}}t.__esModule=!0,t.default=n},function(e,t,o){"use strict";function n(e,t){var o=!0,n=(0,a.getEditorInstance)("date",this.instance);null==e&&(e="");var i=(0,s.default)(new Date(e)).isValid()||(0,s.default)(e,n.defaultDateFormat).isValid(),l=(0,s.default)(e,this.dateFormat||n.defaultDateFormat,!0).isValid();if(this.allowEmpty&&""===e&&(i=!0,l=!0),i||(o=!1),!i&&l&&(o=!0),i&&!l)if(!0===this.correctFormat){var u=r(e,this.dateFormat),c=this.instance.runHooks("unmodifyRow",this.row),h=this.instance.runHooks("unmodifyCol",this.col);this.instance.setDataAtCell(c,h,u,"dateValidator"),o=!0}else o=!1;t(o)}function r(e,t){var o=(0,s.default)((0,l.getNormalizedDate)(e)),n=(0,s.default)(e,t),r=e.search(/[A-z]/g)>-1,i=void 0;return i=o.isValid()&&o.format("x")===n.format("x")||!n.isValid()||r?o:n,i.format(t)}t.__esModule=!0,t.default=n,t.correctFormat=r;var i=o(61),s=function(e){return e&&e.__esModule?e:{default:e}}(i),l=o(89),a=o(14)},function(e,t,o){"use strict";function n(e,t){null==e&&(e=""),t(this.allowEmpty&&""===e?!0:""===e?!1:/^-?\d*(\.|,)?\d*$/.test(e))}t.__esModule=!0,t.default=n},function(e,t,o){"use strict";function n(e,t){var o=!0,n=this.timeFormat||"h:mm:ss a";null===e&&(e=""),e=/^\d{3,}$/.test(e)?parseInt(e,10):e;var r=/^\d{1,2}$/.test(e);r&&(e+=":00");var l=(0,i.default)(e,s,!0).isValid()?(0,i.default)(e):(0,i.default)(e,n),a=l.isValid(),u=(0,i.default)(e,n,!0).isValid()&&!r;if(this.allowEmpty&&""===e&&(a=!0,u=!0),a||(o=!1),!a&&u&&(o=!0),a&&!u)if(!0===this.correctFormat){var c=l.format(n),h=this.instance.runHooks("unmodifyRow",this.row),d=this.instance.runHooks("unmodifyCol",this.col);this.instance.setDataAtCell(h,d,c,"timeValidator"),o=!0}else o=!1;t(o)}t.__esModule=!0,t.default=n;var r=o(61),i=function(e){return e&&e.__esModule?e:{default:e}}(r),s=["YYYY-MM-DDTHH:mm:ss.SSSZ","X","x"]},function(e,t,o){"use strict";var n=o(41),r=o(59),i=o(24);e.exports=[].copyWithin||function(e,t){var o=n(this),s=i(o.length),l=r(e,s),a=r(t,s),u=arguments.length>2?arguments[2]:void 0,c=Math.min((void 0===u?s:r(u,s))-a,s-l),h=1;for(l>a&&a+c>l&&(h=-1,a+=c-1,l+=c-1);c-- >0;)a in o?o[l]=o[a]:delete o[l],l+=h,a+=h;return o}},function(e,t,o){"use strict";var n=o(41),r=o(59),i=o(24);e.exports=function(e){for(var t=n(this),o=i(t.length),s=arguments.length,l=r(s>1?arguments[1]:void 0,o),a=s>2?arguments[2]:void 0,u=void 0===a?o:r(a,o);u>l;)t[l++]=e;return t}},function(e,t,o){var n=o(15),r=o(163),i=o(10)("species");e.exports=function(e){var t;return r(e)&&(t=e.constructor,"function"!=typeof t||t!==Array&&!r(t.prototype)||(t=void 0),n(t)&&null===(t=t[i])&&(t=void 0)),void 0===t?Array:t}},function(e,t,o){var n=o(281);e.exports=function(e,t){return new(n(e))(t)}},function(e,t,o){var n=o(39),r=o(57),i=o(47);e.exports=function(e){var t=n(e),o=r.f;if(o)for(var s,l=o(e),a=i.f,u=0;l.length>u;)a.call(e,s=l[u++])&&t.push(s);return t}},function(e,t,o){"use strict";var n=o(18);e.exports=function(){var e=n(this),t="";return e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),e.unicode&&(t+="u"),e.sticky&&(t+="y"),t}},function(e,t,o){var n=o(15),r=o(172).set;e.exports=function(e,t,o){var i,s=t.constructor;return s!==o&&"function"==typeof s&&(i=s.prototype)!==o.prototype&&n(i)&&r&&r(e,i),e}},function(e,t){e.exports=function(e,t,o){var n=void 0===o;switch(t.length){case 0:return n?e():e.call(o);case 1:return n?e(t[0]):e.call(o,t[0]);case 2:return n?e(t[0],t[1]):e.call(o,t[0],t[1]);case 3:return n?e(t[0],t[1],t[2]):e.call(o,t[0],t[1],t[2]);case 4:return n?e(t[0],t[1],t[2],t[3]):e.call(o,t[0],t[1],t[2],t[3])}return e.apply(o,t)}},function(e,t,o){"use strict";var n=o(79),r=o(40),i=o(48),s={};o(32)(s,o(10)("iterator"),function(){return this}),e.exports=function(e,t,o){e.prototype=n(s,{next:r(1,o)}),i(e,t+" Iterator")}},function(e,t,o){var n=o(39),r=o(23);e.exports=function(e,t){for(var o,i=r(e),s=n(i),l=s.length,a=0;l>a;)if(i[o=s[a++]]===t)return o}},function(e,t,o){var n=o(13),r=o(85).set,i=n.MutationObserver||n.WebKitMutationObserver,s=n.process,l=n.Promise,a="process"==o(38)(s);e.exports=function(){var e,t,o,u=function(){var n,r;for(a&&(n=s.domain)&&n.exit();e;){r=e.fn,e=e.next;try{r()}catch(n){throw e?o():t=void 0,n}}t=void 0,n&&n.enter()};if(a)o=function(){s.nextTick(u)};else if(i){var c=!0,h=document.createTextNode("");new i(u).observe(h,{characterData:!0}),o=function(){h.data=c=!c}}else if(l&&l.resolve){var d=l.resolve();o=function(){d.then(u)}}else o=function(){r.call(n,u)};return function(n){var r={fn:n,next:void 0};t&&(t.next=r),e||(e=r,o()),t=r}}},function(e,t,o){var n=o(19),r=o(18),i=o(39);e.exports=o(21)?Object.defineProperties:function(e,t){r(e);for(var o,s=i(t),l=s.length,a=0;l>a;)n.f(e,o=s[a++],t[o]);return e}},function(e,t,o){var n=o(23),r=o(81).f,i={}.toString,s="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],l=function(e){try{return r(e)}catch(e){return s.slice()}};e.exports.f=function(e){return s&&"[object Window]"==i.call(e)?l(e):r(n(e))}},function(e,t,o){var n=o(22),r=o(41),i=o(82)("IE_PROTO"),s=Object.prototype;e.exports=Object.getPrototypeOf||function(e){return e=r(e),n(e,i)?e[i]:"function"==typeof e.constructor&&e instanceof e.constructor?e.constructor.prototype:e instanceof Object?s:null}},function(e,t,o){var n=o(81),r=o(57),i=o(18),s=o(13).Reflect;e.exports=s&&s.ownKeys||function(e){var t=n.f(i(e)),o=r.f;return o?t.concat(o(e)):t}},function(e,t){e.exports=Object.is||function(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}},function(e,t,o){var n=o(18),r=o(72),i=o(10)("species");e.exports=function(e,t){var o,s=n(e).constructor;return void 0===s||void 0==(o=n(s)[i])?t:r(o)}},function(e,t,o){var n=o(60),r=o(30);e.exports=function(e){return function(t,o){var i,s,l=r(t)+"",a=n(o),u=l.length;return 0>a||a>=u?e?"":void 0:(i=l.charCodeAt(a),55296>i||i>56319||a+1===u||56320>(s=l.charCodeAt(a+1))||s>57343?e?l.charAt(a):i:e?l.slice(a,a+2):s-56320+(i-55296<<10)+65536)}}},function(e,t,o){var n=o(13),r=o(44),i=o(56),s=o(176),l=o(19).f;e.exports=function(e){var t=r.Symbol||(r.Symbol=i?{}:n.Symbol||{});"_"==e.charAt(0)||e in t||l(t,e,{value:s.f(e)})}},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){e.exports=o}])});
|
29
|
+
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("moment"),require("numbro"),require("pikaday")):"function"==typeof define&&define.amd?define("Handsontable",["moment","numbro","pikaday"],t):"object"==typeof exports?exports.Handsontable=t(require("moment"),require("numbro"),require("pikaday")):e.Handsontable=t(e.moment,e.numbro,e.Pikaday)}(this,function(e,t,o){return function(e){function t(n){if(o[n])return o[n].exports;var r=o[n]={i:n,l:!1,exports:{}};return e[n].call(r.exports,r,r.exports,t),r.l=!0,r.exports}var o={};return t.m=e,t.c=o,t.d=function(e,o,n){t.o(e,o)||Object.defineProperty(e,o,{configurable:!1,enumerable:!0,get:n})},t.n=function(e){var o=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(o,"a",o),o},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=180)}([function(e,t,o){"use strict";function n(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,o=-1,n=null;null!=e;){if(o===t){n=e;break}e.host&&e.nodeType===Node.DOCUMENT_FRAGMENT_NODE?e=e.host:(o++,e=e.parentNode)}return n}function r(e,t,o){for(;null!=e&&e!==o;){if(e.nodeType===Node.ELEMENT_NODE&&(t.indexOf(e.nodeName)>-1||t.indexOf(e)>-1))return e;e=e.host&&e.nodeType===Node.DOCUMENT_FRAGMENT_NODE?e.host:e.parentNode}return null}function i(e,t,o){for(var n=[];e&&(e=r(e,t,o))&&(!o||o.contains(e));)n.push(e),e=e.host&&e.nodeType===Node.DOCUMENT_FRAGMENT_NODE?e.host:e.parentNode;var i=n.length;return i?n[i-1]:null}function s(e,t){var o=e.parentNode,n=[];for("string"==typeof t?n=Array.prototype.slice.call(document.querySelectorAll(t),0):n.push(t);null!=o;){if(n.indexOf(o)>-1)return!0;o=o.parentNode}return!1}function l(e){function t(e){return e.nodeType===Node.ELEMENT_NODE&&e.nodeName===n.toUpperCase()}var o,n="hot-table",r=!1;for(o=a(e);null!=o;){if(t(o)){r=!0;break}if(o.host&&o.nodeType===Node.DOCUMENT_FRAGMENT_NODE){if(r=t(o.host))break;o=o.host}o=o.parentNode}return r}function a(e){return"undefined"!=typeof Polymer&&"function"==typeof wrap?wrap(e):e}function u(e){return"undefined"!=typeof Polymer&&"function"==typeof unwrap?unwrap(e):e}function c(e){var t=0;if(e.previousSibling)for(;e=e.previousSibling;)++t;return t}function h(e,t){var o=document.querySelector(".ht_clone_"+e);return o?o.contains(t):null}function d(e){var t=0,o=[];if(!e||!e.length)return o;for(;e[t];)o.push(e[t]),t++;return o}function f(e,t){return q(e,t)}function p(e,t){return Q(e,t)}function g(e,t){return J(e,t)}function v(e,t){if(3===e.nodeType)t.removeChild(e);else if(["TABLE","THEAD","TBODY","TFOOT","TR"].indexOf(e.nodeName)>-1)for(var o=e.childNodes,n=o.length-1;n>=0;n--)v(o[n],e)}function m(e){for(var t;t=e.lastChild;)e.removeChild(t)}function y(e,t){re.test(t)?e.innerHTML=t:w(e,t)}function w(e,t){var o=e.firstChild;o&&3===o.nodeType&&null===o.nextSibling?ie?o.textContent=t:o.data=t:(m(e),e.appendChild(document.createTextNode(t)))}function C(e){for(var t=e;u(t)!==document.documentElement;){if(null===t)return!1;if(t.nodeType===Node.DOCUMENT_FRAGMENT_NODE){if(t.host){if(t.host.impl)return C(t.host.impl);if(t.host)return C(t.host);throw Error("Lost in Web Components world")}return!1}if("none"===t.style.display)return!1;t=t.parentNode}return!0}function b(e){var t,o,n,r,i;if(r=document.documentElement,(0,Z.hasCaptionProblem)()&&e.firstChild&&"CAPTION"===e.firstChild.nodeName)return i=e.getBoundingClientRect(),{top:i.top+(window.pageYOffset||r.scrollTop)-(r.clientTop||0),left:i.left+(window.pageXOffset||r.scrollLeft)-(r.clientLeft||0)};for(t=e.offsetLeft,o=e.offsetTop,n=e;(e=e.offsetParent)&&e!==document.body;)t+=e.offsetLeft,o+=e.offsetTop,n=e;return n&&"fixed"===n.style.position&&(t+=window.pageXOffset||r.scrollLeft,o+=window.pageYOffset||r.scrollTop),{left:t,top:o}}function S(){var e=window.scrollY;return void 0===e&&(e=document.documentElement.scrollTop),e}function E(){var e=window.scrollX;return void 0===e&&(e=document.documentElement.scrollLeft),e}function R(e){return e===window?S():e.scrollTop}function O(e){return e===window?E():e.scrollLeft}function k(e){for(var t,o,n,r=e.parentNode,i=["auto","scroll"],s="",l="",a="",u="";r&&r.style&&document.body!==r;){if(t=r.style.overflow,o=r.style.overflowX,n=r.style.overflowY,"scroll"==t||"scroll"==o||"scroll"==n)return r;if(window.getComputedStyle&&(s=window.getComputedStyle(r),l=s.getPropertyValue("overflow"),a=s.getPropertyValue("overflow-y"),u=s.getPropertyValue("overflow-x"),"scroll"===l||"scroll"===u||"scroll"===a))return r;if(r.scrollHeight+1>=r.clientHeight&&(-1!==i.indexOf(n)||-1!==i.indexOf(t)||-1!==i.indexOf(l)||-1!==i.indexOf(a)))return r;if(r.scrollWidth+1>=r.clientWidth&&(-1!==i.indexOf(o)||-1!==i.indexOf(t)||-1!==i.indexOf(l)||-1!==i.indexOf(u)))return r;r=r.parentNode}return window}function T(e){for(var t=e.parentNode;t&&t.style&&document.body!==t;){if("visible"!==t.style.overflow&&""!==t.style.overflow)return t;if(window.getComputedStyle){var o=window.getComputedStyle(t);if("visible"!==o.getPropertyValue("overflow")&&""!==o.getPropertyValue("overflow"))return t}t=t.parentNode}return window}function _(e,t){if(e){if(e!==window){var o,n=e.style[t];return""!==n&&void 0!==n?n:(o=M(e),""!==o[t]&&void 0!==o[t]?o[t]:void 0)}if("width"===t)return window.innerWidth+"px";if("height"===t)return window.innerHeight+"px"}}function M(e){return e.currentStyle||document.defaultView.getComputedStyle(e)}function H(e){return e.offsetWidth}function A(e){return(0,Z.hasCaptionProblem)()&&e.firstChild&&"CAPTION"===e.firstChild.nodeName?e.offsetHeight+e.firstChild.offsetHeight:e.offsetHeight}function P(e){return e.clientHeight||e.innerHeight}function x(e){return e.clientWidth||e.innerWidth}function D(e,t,o){window.addEventListener?e.addEventListener(t,o,!1):e.attachEvent("on"+t,o)}function L(e,t,o){window.removeEventListener?e.removeEventListener(t,o,!1):e.detachEvent("on"+t,o)}function N(e){if(e.selectionStart)return e.selectionStart;if(document.selection){e.focus();var t=document.selection.createRange();if(null==t)return 0;var o=e.createTextRange(),n=o.duplicate();return o.moveToBookmark(t.getBookmark()),n.setEndPoint("EndToStart",o),n.text.length}return 0}function I(e){if(e.selectionEnd)return e.selectionEnd;if(document.selection){var t=document.selection.createRange();if(null==t)return 0;return e.createTextRange().text.indexOf(t.text)+t.text.length}return 0}function j(){var e="";return window.getSelection?e=""+window.getSelection():document.selection&&"Control"!==document.selection.type&&(e=document.selection.createRange().text),e}function W(e,t,o){if(void 0===o&&(o=t),e.setSelectionRange){e.focus();try{e.setSelectionRange(t,o)}catch(i){var n=e.parentNode,r=n.style.display;n.style.display="block",e.setSelectionRange(t,o),n.style.display=r}}else if(e.createTextRange){var i=e.createTextRange();i.collapse(!0),i.moveEnd("character",o),i.moveStart("character",t),i.select()}}function B(){var e=document.createElement("div");e.style.height="200px",e.style.width="100%";var t=document.createElement("div");t.style.boxSizing="content-box",t.style.height="150px",t.style.left="0px",t.style.overflow="hidden",t.style.position="absolute",t.style.top="0px",t.style.width="200px",t.style.visibility="hidden",t.appendChild(e),(document.body||document.documentElement).appendChild(t);var o=e.offsetWidth;t.style.overflow="scroll";var n=e.offsetWidth;return o==n&&(n=t.clientWidth),(document.body||document.documentElement).removeChild(t),o-n}function F(){return void 0===ne&&(ne=B()),ne}function V(e){return e.offsetWidth!==e.clientWidth}function z(e){return e.offsetHeight!==e.clientHeight}function U(e,t,o){(0,$.isIE8)()||(0,$.isIE9)()?(e.style.top=o,e.style.left=t):(0,$.isSafari)()?e.style["-webkit-transform"]="translate3d("+t+","+o+",0)":e.style.transform="translate3d("+t+","+o+",0)"}function Y(e){var t;return e.style.transform&&""!==(t=e.style.transform)?["transform",t]:e.style["-webkit-transform"]&&""!==(t=e.style["-webkit-transform"])?["-webkit-transform",t]:-1}function K(e){e.style.transform&&""!==e.style.transform?e.style.transform="":e.style["-webkit-transform"]&&""!==e.style["-webkit-transform"]&&(e.style["-webkit-transform"]="")}function G(e){var t=["INPUT","SELECT","TEXTAREA"];return e&&(t.indexOf(e.nodeName)>-1||"true"===e.contentEditable)}function X(e){return G(e)&&-1==e.className.indexOf("handsontableInput")&&-1==e.className.indexOf("copyPaste")}t.__esModule=!0,t.HTML_CHARACTERS=void 0,t.getParent=n,t.closest=r,t.closestDown=i,t.isChildOf=s,t.isChildOfWebComponentTable=l,t.polymerWrap=a,t.polymerUnwrap=u,t.index=c,t.overlayContainsElement=h,t.hasClass=f,t.addClass=p,t.removeClass=g,t.removeTextNodes=v,t.empty=m,t.fastInnerHTML=y,t.fastInnerText=w,t.isVisible=C,t.offset=b,t.getWindowScrollTop=S,t.getWindowScrollLeft=E,t.getScrollTop=R,t.getScrollLeft=O,t.getScrollableElement=k,t.getTrimmingContainer=T,t.getStyle=_,t.getComputedStyle=M,t.outerWidth=H,t.outerHeight=A,t.innerHeight=P,t.innerWidth=x,t.addEvent=D,t.removeEvent=L,t.getCaretPosition=N,t.getSelectionEndPosition=I,t.getSelectionText=j,t.setCaretPosition=W,t.getScrollbarWidth=F,t.hasVerticalScrollbar=V,t.hasHorizontalScrollbar=z,t.setOverlayPosition=U,t.getCssTransform=Y,t.resetCssTransform=K,t.isInput=G,t.isOutsideInput=X;var q,Q,J,$=o(26),Z=o(34),ee=!!document.documentElement.classList;if(ee){var te=function(){var e=document.createElement("div");return e.classList.add("test","test2"),e.classList.contains("test2")}();q=function(e,t){return void 0!==e.classList&&""!==t&&e.classList.contains(t)},Q=function(e,t){var o=0;if("string"==typeof t&&(t=t.split(" ")),t=d(t),te)e.classList.add.apply(e.classList,t);else for(;t&&t[o];)e.classList.add(t[o]),o++},J=function(e,t){var o=0;if("string"==typeof t&&(t=t.split(" ")),t=d(t),te)e.classList.remove.apply(e.classList,t);else for(;t&&t[o];)e.classList.remove(t[o]),o++}}else{var oe=function(e){return RegExp("(\\s|^)"+e+"(\\s|$)")};q=function(e,t){return void 0!==e.className&&oe(t).test(e.className)},Q=function(e,t){var o=0,n=e.className;if("string"==typeof t&&(t=t.split(" ")),""===n)n=t.join(" ");else for(;t&&t[o];)oe(t[o]).test(n)||(n+=" "+t[o]),o++;e.className=n},J=function(e,t){var o=0,n=e.className;for("string"==typeof t&&(t=t.split(" "));t&&t[o];)n=n.replace(oe(t[o])," ").trim(),o++;e.className!==n&&(e.className=n)}}var ne,re=t.HTML_CHARACTERS=/(<(.*)>|&(.*);)/,ie=!!document.createTextNode("test").textContent},function(e,t,o){"use strict";function n(e,t,o){return t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o,e}function r(e){var t;return Array.isArray(e)?t=[]:(t={},p(e,function(e,o){"__children"!==o&&(t[o]=e&&"object"===(void 0===e?"undefined":w(e))&&!Array.isArray(e)?r(e):Array.isArray(e)?e.length&&"object"===w(e[0])&&!Array.isArray(e[0])?[r(e[0])]:[]:null)})),t}function i(e,t){return t.prototype.constructor=t,e.prototype=new t,e.prototype.constructor=e,e}function s(e,t){return p(t,function(t,o){e[o]=t}),e}function l(e,t){p(t,function(o,n){t[n]&&"object"===w(t[n])?(e[n]||(e[n]=Array.isArray(t[n])?[]:"[object Date]"===Object.prototype.toString.call(t[n])?t[n]:{}),l(e[n],t[n])):e[n]=t[n]})}function a(e){return"object"===(void 0===e?"undefined":w(e))?JSON.parse(JSON.stringify(e)):e}function u(e){var t={};return p(e,function(e,o){t[o]=e}),t}function c(e){e.MIXINS||(e.MIXINS=[]);for(var t=arguments.length,o=Array(t>1?t-1:0),n=1;t>n;n++)o[n-1]=arguments[n];return(0,C.arrayEach)(o,function(t){e.MIXINS.push(t.MIXIN_NAME),p(t,function(t,o){if(void 0!==e.prototype[o])throw Error("Mixin conflict. Property '"+o+"' already exist and cannot be overwritten.");if("function"==typeof t)e.prototype[o]=t;else{Object.defineProperty(e.prototype,o,{get:function(e,t){e="_"+e;var o=function(e){return(Array.isArray(e)||d(e))&&(e=a(e)),e};return function(){return void 0===this[e]&&(this[e]=o(t)),this[e]}}(o,t),set:function(e){return e="_"+e,function(t){this[e]=t}}(o),configurable:!0})}})}),e}function h(e,t){return JSON.stringify(e)===JSON.stringify(t)}function d(e){return"[object Object]"==Object.prototype.toString.call(e)}function f(e,t,o,n){n.value=o,n.writable=!1!==n.writable,n.enumerable=!1!==n.enumerable,n.configurable=!1!==n.configurable,Object.defineProperty(e,t,n)}function p(e,t){for(var o in e)if((!e.hasOwnProperty||e.hasOwnProperty&&Object.prototype.hasOwnProperty.call(e,o))&&!1===t(e[o],o,e))break;return e}function g(e,t){var o=t.split("."),n=e;return p(o,function(e){if(void 0===(n=n[e]))return n=void 0,!1}),n}function v(e){if(!d(e))return 0;return function e(t){var o=0;return d(t)?p(t,function(t){o+=e(t)}):o++,o}(e)}function m(e){var t,o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"value",r="_"+o,i=(t={_touched:!1},n(t,r,e),n(t,"isTouched",function(){return this._touched}),t);return Object.defineProperty(i,o,{get:function(){return this[r]},set:function(e){this._touched=!0,this[r]=e},enumerable:!0,configurable:!0}),i}function y(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.__esModule=!0;var w="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.duckSchema=r,t.inherit=i,t.extend=s,t.deepExtend=l,t.deepClone=a,t.clone=u,t.mixin=c,t.isObjectEquals=h,t.isObject=d,t.defineGetter=f,t.objectEach=p,t.getProperty=g,t.deepObjectSize=v,t.createObjectPropListener=m,t.hasOwnProperty=y;var C=o(2)},function(e,t,o){"use strict";function n(e){for(var t=0,o=e.length;o>t;)e[t]=[e[t]],t++}function r(e,t){for(var o=0,n=t.length;n>o;)e.push(t[o]),o++}function i(e){var t=[];if(!e||0===e.length||!e[0]||0===e[0].length)return t;for(var o=e.length,n=e[0].length,r=0;o>r;r++)for(var i=0;n>i;i++)t[i]||(t[i]=[]),t[i][r]=e[r][i];return t}function s(e,t,o,n){var r=-1,i=e.length;for(n&&i&&(o=e[++r]);++r<i;)o=t(o,e[r],r,e);return o}function l(e,t){for(var o=-1,n=e.length,r=-1,i=[];++o<n;){var s=e[o];t(s,o,e)&&(i[++r]=s)}return i}function a(e,t){for(var o=-1,n=e.length,r=-1,i=[];++o<n;){var s=e[o];i[++r]=t(s,o,e)}return i}function u(e,t){for(var o=-1,n=e.length;++o<n&&!1!==t(e[o],o,e););return e}function c(e){return s(e,function(e,t){return e+t},0)}function h(e){return s(e,function(e,t){return e>t?e:t},Array.isArray(e)?e[0]:void 0)}function d(e){return s(e,function(e,t){return t>e?e:t},Array.isArray(e)?e[0]:void 0)}function f(e){return e.length?c(e)/e.length:0}function p(e){return s(e,function(e,t){return e.concat(Array.isArray(t)?p(t):t)},[])}function g(e){var t=[];return u(e,function(e){-1===t.indexOf(e)&&t.push(e)}),t}t.__esModule=!0,t.to2dArray=n,t.extendArray=r,t.pivot=i,t.arrayReduce=s,t.arrayFilter=l,t.arrayMap=a,t.arrayEach=u,t.arraySum=c,t.arrayMax=h,t.arrayMin=d,t.arrayAvg=f,t.arrayFlatten=p,t.arrayUnique=g},function(e,t,o){var n=o(11),r=o(44),i=o(29),s=o(28),l=o(30),a=function(e,t,o){var u,c,h,d,f=e&a.F,p=e&a.G,g=e&a.S,v=e&a.P,m=e&a.B,y=p?n:g?n[t]||(n[t]={}):(n[t]||{}).prototype,w=p?r:r[t]||(r[t]={}),C=w.prototype||(w.prototype={});p&&(o=t);for(u in o)c=!f&&y&&void 0!==y[u],h=(c?y:o)[u],d=m&&c?l(h,n):v&&"function"==typeof h?l(Function.call,h):h,y&&s(y,u,h,e&a.U),w[u]!=h&&i(w,u,d),v&&C[u]!=h&&(C[u]=h)};n.core=r,a.F=1,a.G=2,a.S=4,a.P=8,a.B=16,a.W=32,a.U=64,a.R=128,e.exports=a},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){var o=void 0,n=void 0,r=void 0,i=void 0,s=void 0,h=void 0;if(t.isTargetWebComponent=!1,t.realTarget=t.target,h=t.stopImmediatePropagation,t.stopImmediatePropagation=function(){h.apply(this),(0,c.stopImmediatePropagation)(this)},!d.isHotTableEnv)return t;for(t=(0,l.polymerWrap)(t),s=t.path?t.path.length:0;s--;){if("HOT-TABLE"===t.path[s].nodeName)o=!0;else if(o&&t.path[s].shadowRoot){i=t.path[s];break}0!==s||i||(i=t.path[s])}return i||(i=t.target),t.isTargetWebComponent=!0,(0,u.isWebComponentSupportedNatively)()?t.realTarget=t.srcElement||t.toElement:((0,a.hasOwnProperty)(e,"hot")||e.isHotTableEnv||e.wtTable)&&((0,a.hasOwnProperty)(e,"hot")?n=e.hot?e.hot.view.wt.wtTable.TABLE:null:e.isHotTableEnv?n=e.view.activeWt.wtTable.TABLE.parentNode.parentNode:e.wtTable&&(n=e.wtTable.TABLE.parentNode.parentNode),r=(0,l.closest)(t.target,["HOT-TABLE"],n),t.realTarget=r?n.querySelector("HOT-TABLE")||t.target:t.target),Object.defineProperty(t,"target",{get:function(){return(0,l.polymerWrap)(i)},enumerable:!0,configurable:!0}),t}function i(){return h}t.__esModule=!0;var s=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}();t.getListenersCounter=i;var l=o(0),a=o(1),u=o(34),c=o(10),h=0,d=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;n(this,e),this.context=t||this,this.context.eventListeners||(this.context.eventListeners=[])}return s(e,[{key:"addEventListener",value:function(e,t,o){function n(e){e=r(s,e),o.call(this,e)}var i=this,s=this.context;return this.context.eventListeners.push({element:e,event:t,callback:o,callbackProxy:n}),window.addEventListener?e.addEventListener(t,n,!1):e.attachEvent("on"+t,n),h++,function(){i.removeEventListener(e,t,o)}}},{key:"removeEventListener",value:function(e,t,o){for(var n=this.context.eventListeners.length,r=void 0;n--;)if(r=this.context.eventListeners[n],r.event==t&&r.element==e){if(o&&o!=r.callback)continue;this.context.eventListeners.splice(n,1),r.element.removeEventListener?r.element.removeEventListener(r.event,r.callbackProxy,!1):r.element.detachEvent("on"+r.event,r.callbackProxy),h--}}},{key:"clearEvents",value:function(){if(this.context)for(var e=this.context.eventListeners.length;e--;){var t=this.context.eventListeners[e];t&&this.removeEventListener(t.element,t.event,t.callback)}}},{key:"clear",value:function(){this.clearEvents()}},{key:"destroy",value:function(){this.clearEvents(),this.context=null}},{key:"fireEvent",value:function(e,t){var o,n={bubbles:!0,cancelable:"mousemove"!==t,view:window,detail:0,screenX:0,screenY:0,clientX:1,clientY:1,ctrlKey:!1,altKey:!1,shiftKey:!1,metaKey:!1,button:0,relatedTarget:void 0};document.createEvent?(o=document.createEvent("MouseEvents"),o.initMouseEvent(t,n.bubbles,n.cancelable,n.view,n.detail,n.screenX,n.screenY,n.clientX,n.clientY,n.ctrlKey,n.altKey,n.shiftKey,n.metaKey,n.button,n.relatedTarget||document.body.parentNode)):o=document.createEventObject(),e.dispatchEvent?e.dispatchEvent(o):e.fireEvent("on"+t,o)}}]),e}();t.default=d},function(e,t,o){"use strict";function n(e,t){e=(0,c.toUpperCaseFirst)(e),a.default.getSingleton().add("construct",function(){var o=void 0;h.has(this)||h.set(this,{}),o=h.get(this),o[e]||(o[e]=new t(this))}),a.default.getSingleton().add("afterDestroy",function(){if(h.has(this)){var e=h.get(this);(0,u.objectEach)(e,function(e){return e.destroy()}),h.delete(this)}})}function r(e,t){if("string"!=typeof t)throw Error('Only strings can be passed as "plugin" parameter');var o=(0,c.toUpperCaseFirst)(t);if(h.has(e)&&h.get(e)[o])return h.get(e)[o]}function i(e){return h.has(e)?Object.keys(h.get(e)):[]}function s(e,t){var o=null;return h.has(e)&&(0,u.objectEach)(h.get(e),function(e,n){e===t&&(o=n)}),o}t.__esModule=!0,t.getPluginName=t.getRegistredPluginNames=t.getPlugin=t.registerPlugin=void 0;var l=o(7),a=function(e){return e&&e.__esModule?e:{default:e}}(l),u=o(1),c=o(32),h=new WeakMap;t.registerPlugin=n,t.getPlugin=r,t.getRegistredPluginNames=i,t.getPluginName=s},function(e,t,o){"use strict";function n(e){var t=void 0===e?"undefined":l(e);return"number"==t?!isNaN(e)&&isFinite(e):"string"==t?!!e.length&&(1==e.length?/\d/.test(e):/^\s*[+-]?\s*(?:(?:\d+(?:\.\d+)?(?:e[+-]?\d+)?)|(?:0x[a-f\d]+))\s*$/i.test(e)):"object"==t&&!(!e||"number"!=typeof e.valueOf()||e instanceof Date)}function r(e,t,o){var n=-1;for("function"==typeof t?(o=t,t=e):n=e-1;++n<=t&&!1!==o(n););}function i(e,t,o){var n=e+1;for("function"==typeof t&&(o=t,t=0);--n>=t&&!1!==o(n););}function s(e,t){return t=parseInt((""+t).replace("%",""),10),t=parseInt(e*t/100,10)}t.__esModule=!0;var l="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.isNumeric=n,t.rangeEach=r,t.rangeEachReverse=i,t.valueAccordingPercent=s},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=o(2),s=o(1),l=["afterCellMetaReset","afterChange","afterChangesObserved","afterContextMenuDefaultOptions","beforeContextMenuSetItems","afterDropdownMenuDefaultOptions","beforeDropdownMenuSetItems","afterContextMenuHide","afterContextMenuShow","afterCopyLimit","beforeCreateCol","afterCreateCol","beforeCreateRow","afterCreateRow","afterDeselect","afterDestroy","afterDocumentKeyDown","afterGetCellMeta","afterGetColHeader","afterGetRowHeader","afterInit","afterLoadData","afterMomentumScroll","afterOnCellCornerMouseDown","afterOnCellCornerDblClick","afterOnCellMouseDown","afterOnCellMouseOver","afterOnCellMouseOut","afterRemoveCol","afterRemoveRow","afterRender","beforeRenderer","afterRenderer","afterScrollHorizontally","afterScrollVertically","afterSelection","afterSelectionByProp","afterSelectionEnd","afterSelectionEndByProp","afterSetCellMeta","afterRemoveCellMeta","afterSetDataAtCell","afterSetDataAtRowProp","afterUpdateSettings","afterValidate","beforeAutofill","beforeCellAlignment","beforeChange","beforeChangeRender","beforeDrawBorders","beforeGetCellMeta","beforeRemoveCellMeta","beforeInit","beforeInitWalkontable","beforeKeyDown","beforeOnCellMouseDown","beforeOnCellMouseOver","beforeOnCellMouseOut","beforeRemoveCol","beforeRemoveRow","beforeRender","beforeSetRangeStart","beforeSetRangeEnd","beforeTouchScroll","beforeValidate","beforeValueRender","construct","init","modifyCol","unmodifyCol","unmodifyRow","modifyColHeader","modifyColWidth","modifyRow","modifyRowHeader","modifyRowHeight","modifyData","modifyRowData","persistentStateLoad","persistentStateReset","persistentStateSave","beforeColumnSort","afterColumnSort","modifyAutofillRange","modifyCopyableRange","beforeCut","afterCut","beforeCopy","afterCopy","beforePaste","afterPaste","beforeColumnMove","afterColumnMove","beforeRowMove","afterRowMove","beforeColumnResize","afterColumnResize","beforeRowResize","afterRowResize","afterGetColumnHeaderRenderers","afterGetRowHeaderRenderers","beforeStretchingColumnWidth","beforeFilter","afterFilter","modifyColumnHeaderHeight","beforeUndo","afterUndo","beforeRedo","afterRedo","modifyRowHeaderWidth","beforeAutofillInsidePopulate","modifyTransformStart","modifyTransformEnd","afterModifyTransformStart","afterModifyTransformEnd","afterViewportRowCalculatorOverride","afterViewportColumnCalculatorOverride","afterPluginsInitialized","manualRowHeights","skipLengthCache","afterTrimRow","afterUntrimRow","afterDropdownMenuShow","afterDropdownMenuHide","hiddenRow","hiddenColumn","beforeAddChild","afterAddChild","beforeDetachChild","afterDetachChild","afterBeginEditing","afterListen","afterUnlisten"],a=function(){function e(){n(this,e),this.globalBucket=this.createEmptyBucket()}return r(e,null,[{key:"getSingleton",value:function(){return u}}]),r(e,[{key:"createEmptyBucket",value:function(){var e=Object.create(null);return(0,i.arrayEach)(l,function(t){return e[t]=[]}),e}},{key:"getBucket",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;return e?(e.pluginHookBucket||(e.pluginHookBucket=this.createEmptyBucket()),e.pluginHookBucket):this.globalBucket}},{key:"add",value:function(e,t){var o=this,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;if(Array.isArray(t))(0,i.arrayEach)(t,function(t){return o.add(e,t,n)});else{var r=this.getBucket(n);if(void 0===r[e]&&(this.register(e),r[e]=[]),t.skip=!1,-1===r[e].indexOf(t)){var s=!1;t.initialHook&&(0,i.arrayEach)(r[e],function(o,n){if(o.initialHook)return r[e][n]=t,s=!0,!1}),s||r[e].push(t)}}return this}},{key:"once",value:function(e,t){var o=this,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;Array.isArray(t)?(0,i.arrayEach)(t,function(t){return o.once(e,t,n)}):(t.runOnce=!0,this.add(e,t,n))}},{key:"remove",value:function(e,t){var o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,n=this.getBucket(o);return void 0!==n[e]&&n[e].indexOf(t)>=0&&(t.skip=!0,!0)}},{key:"has",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,o=this.getBucket(t);return!(void 0===o[e]||!o[e].length)}},{key:"run",value:function(e,t,o,n,r,i,s,l){var a=this.globalBucket[t],u=-1,c=a?a.length:0;if(c)for(;++u<c;)if(a[u]&&!a[u].skip){var h=a[u].call(e,o,n,r,i,s,l);void 0!==h&&(o=h),a[u]&&a[u].runOnce&&this.remove(t,a[u])}var d=this.getBucket(e)[t],f=-1,p=d?d.length:0;if(p)for(;++f<p;)if(d[f]&&!d[f].skip){var g=d[f].call(e,o,n,r,i,s,l);void 0!==g&&(o=g),d[f]&&d[f].runOnce&&this.remove(t,d[f],e)}return o}},{key:"destroy",value:function(){(0,s.objectEach)(this.getBucket(arguments.length>0&&void 0!==arguments[0]?arguments[0]:null),function(e,t,o){return o[t].length=0})}},{key:"register",value:function(e){this.isRegistered(e)||l.push(e)}},{key:"deregister",value:function(e){this.isRegistered(e)&&l.splice(l.indexOf(e),1)}},{key:"isRegistered",value:function(e){return l.indexOf(e)>=0}},{key:"getRegistered",value:function(){return l}}]),e}(),u=new a;t.default=a},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e){if("function"==typeof e)return e;if(!R(e))throw Error('No registered renderer found under "'+e+'" name');return E(e)}t.__esModule=!0,t.getRegisteredRenderers=t.getRegisteredRendererNames=t.hasRenderer=t.getRenderer=t.registerRenderer=void 0;var i=o(63),s=n(i),l=o(220),a=n(l),u=o(221),c=n(u),h=o(222),d=n(h),f=o(223),p=n(f),g=o(224),v=n(g),m=o(225),y=n(m),w=o(226),C=n(w),b=(0,s.default)("renderers"),S=b.register,E=b.getItem,R=b.hasItem,O=b.getNames,k=b.getValues;S("base",a.default),S("autocomplete",c.default),S("checkbox",d.default),S("html",p.default),S("numeric",v.default),S("password",y.default),S("text",C.default),t.registerRenderer=S,t.getRenderer=r,t.hasRenderer=R,t.getRegisteredRendererNames=O,t.getRegisteredRenderers=k},function(e,t,o){var n=o(69)("wks"),r=o(42),i=o(11).Symbol,s="function"==typeof i;(e.exports=function(e){return n[e]||(n[e]=s&&i[e]||(s?i:r)("Symbol."+e))}).store=n},function(e,t,o){"use strict";function n(e){e.isImmediatePropagationEnabled=!1,e.cancelBubble=!0}function r(e){return!1===e.isImmediatePropagationEnabled}function i(e){"function"==typeof e.stopPropagation?e.stopPropagation():e.cancelBubble=!0}function s(e){return e.pageX?e.pageX:e.clientX+(0,c.getWindowScrollLeft)()}function l(e){return e.pageY?e.pageY:e.clientY+(0,c.getWindowScrollTop)()}function a(e){return 2===e.button}function u(e){return 0===e.button}t.__esModule=!0,t.stopImmediatePropagation=n,t.isImmediatePropagationStopped=r,t.stopPropagation=i,t.pageX=s,t.pageY=l,t.isRightClick=a,t.isLeftClick=u;var c=o(0)},function(e,t){var o=e.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=o)},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}t.__esModule=!0,t.Viewport=t.TableRenderer=t.Table=t.Settings=t.Selection=t.Scroll=t.Overlays=t.Event=t.Core=t.default=t.Border=t.TopLeftCornerOverlay=t.TopOverlay=t.LeftOverlay=t.DebugOverlay=t.RowFilter=t.ColumnFilter=t.CellRange=t.CellCoords=t.ViewportRowsCalculator=t.ViewportColumnsCalculator=void 0,o(89),o(103),o(104),o(108),o(109),o(111),o(113),o(114),o(115),o(116),o(117),o(118),o(119),o(120),o(122),o(124),o(125),o(126),o(127),o(128),o(129),o(130),o(131),o(132),o(133),o(134),o(135),o(136),o(78),o(137),o(138),o(140),o(141),o(142),o(143),o(144),o(145),o(146),o(148),o(149),o(150),o(152),o(153),o(154);var r=o(155),i=n(r),s=o(156),l=n(s),a=o(49),u=n(a),c=o(79),h=n(c),d=o(157),f=n(d),p=o(158),g=n(p),v=o(204),m=n(v),y=o(206),w=n(y),C=o(207),b=n(C),S=o(208),E=n(S),R=o(167),O=n(R),k=o(159),T=n(k),_=o(160),M=n(_),H=o(161),A=n(H),P=o(162),x=n(P),D=o(209),L=n(D),N=o(163),I=n(N),j=o(164),W=n(j),B=o(165),F=n(B),V=o(166),z=n(V);t.ViewportColumnsCalculator=i.default,t.ViewportRowsCalculator=l.default,t.CellCoords=u.default,t.CellRange=h.default,t.ColumnFilter=f.default,t.RowFilter=g.default,t.DebugOverlay=m.default,t.LeftOverlay=w.default,t.TopOverlay=b.default,t.TopLeftCornerOverlay=E.default,t.Border=O.default,t.default=T.default,t.Core=T.default,t.Event=M.default,t.Overlays=A.default,t.Scroll=x.default,t.Selection=L.default,t.Settings=I.default,t.Table=W.default,t.TableRenderer=F.default,t.Viewport=z.default},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=o(1),s=o(2),l=o(172),a=o(5),u=new WeakMap,c=null;t.default=function(){function e(t){var o=this;n(this,e),(0,i.defineGetter)(this,"hot",t,{writable:!1}),(0,i.defineGetter)(this,"t",(0,l.getTranslator)(t),{writable:!1}),u.set(this,{hooks:{}}),c=null,this.pluginName=null,this.pluginsInitializedCallbacks=[],this.isPluginsReady=!1,this.enabled=!1,this.initialized=!1,this.hot.addHook("afterPluginsInitialized",function(){return o.onAfterPluginsInitialized()}),this.hot.addHook("afterUpdateSettings",function(){return o.onUpdateSettings()}),this.hot.addHook("beforeInit",function(){return o.init()})}return r(e,[{key:"init",value:function(){this.pluginName=(0,a.getPluginName)(this.hot,this),this.isEnabled&&this.isEnabled()&&this.enablePlugin(),c||(c=(0,a.getRegistredPluginNames)(this.hot)),0>c.indexOf(this.pluginName)||c.splice(c.indexOf(this.pluginName),1),c.length||this.hot.runHooks("afterPluginsInitialized"),this.initialized=!0}},{key:"enablePlugin",value:function(){this.enabled=!0}},{key:"disablePlugin",value:function(){this.eventManager&&this.eventManager.clear(),this.clearHooks(),this.enabled=!1}},{key:"addHook",value:function(e,t){u.get(this).hooks[e]=u.get(this).hooks[e]||[];var o=u.get(this).hooks[e];this.hot.addHook(e,t),o.push(t),u.get(this).hooks[e]=o}},{key:"removeHooks",value:function(e){var t=this;(0,s.arrayEach)(u.get(this).hooks[e]||[],function(o){t.hot.removeHook(e,o)})}},{key:"clearHooks",value:function(){var e=this,t=u.get(this).hooks;(0,i.objectEach)(t,function(t,o){return e.removeHooks(o)}),t.length=0}},{key:"callOnPluginsReady",value:function(e){this.isPluginsReady?e():this.pluginsInitializedCallbacks.push(e)}},{key:"onAfterPluginsInitialized",value:function(){(0,s.arrayEach)(this.pluginsInitializedCallbacks,function(e){return e()}),this.pluginsInitializedCallbacks.length=0,this.isPluginsReady=!0}},{key:"onUpdateSettings",value:function(){this.isEnabled&&(this.enabled&&!this.isEnabled()&&this.disablePlugin(),!this.enabled&&this.isEnabled()&&this.enablePlugin(),this.enabled&&this.isEnabled()&&this.updatePlugin())}},{key:"updatePlugin",value:function(){}},{key:"destroy",value:function(){var e=this;this.eventManager&&this.eventManager.destroy(),this.clearHooks(),(0,i.objectEach)(this,function(t,o){"hot"!==o&&"t"!==o&&(e[o]=null)}),delete this.t,delete this.hot}}]),e}()},function(e,t){e.exports=function(e){return"object"==typeof e?null!==e:"function"==typeof e}},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e){var t={},o=e;this.getConstructor=function(){return e},this.getInstance=function(e){return e.guid in t||(t[e.guid]=new o(e)),t[e.guid]},h.default.getSingleton().add("afterDestroy",function(){t={}})}function i(e,t){var o=void 0;if("function"==typeof e)D.get(e)||l(null,e),o=D.get(e);else{if("string"!=typeof e)throw Error('Only strings and functions can be passed as "editor" parameter');o=I(e)}if(!o)throw Error('No editor registered under name "'+e+'"');return o.getInstance(t)}function s(e){if(!j(e))throw Error('No registered editor found under "'+e+'" name');return I(e).getConstructor()}function l(e,t){var o=new r(t);"string"==typeof e&&N(e,o),D.set(t,o)}t.__esModule=!0,t.getRegisteredEditors=t.getRegisteredEditorNames=t.hasEditor=t.getEditorInstance=t.getEditor=t.registerEditor=void 0,t.RegisteredEditor=r,t._getEditorInstance=i;var a=o(63),u=n(a),c=o(7),h=n(c),d=o(41),f=n(d),p=o(168),g=n(p),v=o(211),m=n(v),y=o(212),w=n(y),C=o(215),b=n(C),S=o(169),E=n(S),R=o(216),O=n(R),k=o(217),T=n(k),_=o(218),M=n(_),H=o(219),A=n(H),P=o(51),x=n(P),D=new WeakMap,L=(0,u.default)("editors"),N=L.register,I=L.getItem,j=L.hasItem,W=L.getNames,B=L.getValues;l("base",f.default),l("autocomplete",g.default),l("checkbox",m.default),l("date",w.default),l("dropdown",b.default),l("handsontable",E.default),l("mobile",O.default),l("numeric",T.default),l("password",M.default),l("select",A.default),l("text",x.default),t.registerEditor=l,t.getEditor=s,t.getEditorInstance=i,t.hasEditor=j,t.getRegisteredEditorNames=W,t.getRegisteredEditors=B},function(e,t,o){var n=o(14);e.exports=function(e){if(!n(e))throw TypeError(e+" is not an object!");return e}},function(e,t,o){var n=o(16),r=o(91),i=o(65),s=Object.defineProperty;t.f=o(20)?Object.defineProperty:function(e,t,o){if(n(e),t=i(t,!0),n(o),r)try{return s(e,t,o)}catch(e){}if("get"in o||"set"in o)throw TypeError("Accessors not supported!");return"value"in o&&(e[t]=o.value),e}},function(e,t,o){"use strict";function n(e){return 32==e||e>=48&&57>=e||e>=96&&111>=e||e>=186&&192>=e||e>=219&&222>=e||e>=226||e>=65&&90>=e}function r(e){return-1!==[a.ARROW_DOWN,a.ARROW_UP,a.ARROW_LEFT,a.ARROW_RIGHT,a.HOME,a.END,a.DELETE,a.BACKSPACE,a.F1,a.F2,a.F3,a.F4,a.F5,a.F6,a.F7,a.F8,a.F9,a.F10,a.F11,a.F12,a.TAB,a.PAGE_DOWN,a.PAGE_UP,a.ENTER,a.ESCAPE,a.SHIFT,a.CAPS_LOCK,a.ALT].indexOf(e)}function i(e){return-1!==[a.CONTROL_LEFT,224,a.COMMAND_LEFT,a.COMMAND_RIGHT].indexOf(e)}function s(e,t){var o=t.split("|"),n=!1;return(0,l.arrayEach)(o,function(t){if(e===a[t])return n=!0,!1}),n}t.__esModule=!0,t.KEY_CODES=void 0,t.isPrintableChar=n,t.isMetaKey=r,t.isCtrlKey=i,t.isKey=s;var l=o(2),a=t.KEY_CODES={MOUSE_LEFT:1,MOUSE_RIGHT:3,MOUSE_MIDDLE:2,BACKSPACE:8,COMMA:188,INSERT:45,DELETE:46,END:35,ENTER:13,ESCAPE:27,CONTROL_LEFT:91,COMMAND_LEFT:17,COMMAND_RIGHT:93,ALT:18,HOME:36,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,SPACE:32,SHIFT:16,CAPS_LOCK:20,TAB:9,ARROW_RIGHT:39,ARROW_LEFT:37,ARROW_UP:38,ARROW_DOWN:40,F1:112,F2:113,F3:114,F4:115,F5:116,F6:117,F7:118,F8:119,F9:120,F10:121,F11:122,F12:123,A:65,X:88,C:67,V:86}},function(e,t,o){"use strict";function n(e){return{start:e.getTopLeftCorner(),end:e.getBottomRightCorner()}}function r(e){return(0,S.hasClass)(e,"htSeparator")}function i(e){return(0,S.hasClass)(e,"htSubmenu")}function s(e){return(0,S.hasClass)(e,"htDisabled")}function l(e){return(0,S.hasClass)(e,"htSelectionDisabled")}function a(e){var t=e.getSelected();return t?0>t[0]?null:t:null}function u(e,t){return-1!=e.indexOf(t)?e:(e=e.replace("htTop","").replace("htMiddle","").replace("htBottom","").replace(" ",""),e+=" "+t)}function c(e,t){return-1!=e.indexOf(t)?e:(e=e.replace("htLeft","").replace("htCenter","").replace("htRight","").replace("htJustify","").replace(" ",""),e+=" "+t)}function h(e,t){for(var o={},n=e.from.row;e.to.row>=n;n++)for(var r=e.from.col;e.to.col>=r;r++)o[n]||(o[n]=[]),o[n][r]=t(n,r);return o}function d(e,t,o,n,r){if(e.from.row==e.to.row&&e.from.col==e.to.col)f(e.from.row,e.from.col,t,o,n,r);else for(var i=e.from.row;e.to.row>=i;i++)for(var s=e.from.col;e.to.col>=s;s++)f(i,s,t,o,n,r)}function f(e,t,o,n,r,i){var s=r(e,t),l=n;s.className&&(l="vertical"===o?u(s.className,n):c(s.className,n)),i(e,t,"className",l)}function p(e,t){var o=!1;return e&&e.forAll(function(e,n){if(t(e,n))return o=!0,!1}),o}function g(e){return'<span class="selected">'+String.fromCharCode(10003)+"</span>"+e}function v(e,t){return!e.hidden||!("function"==typeof e.hidden&&e.hidden.call(t))}function m(e,t){for(var o=e.slice(0);o.length>0&&o[0].name===t;)o.shift();return o}function y(e,t){var o=e.slice(0);return o.reverse(),o=m(o,t),o.reverse(),o}function w(e){var t=[];return(0,b.arrayEach)(e,function(e,o){o>0?t[t.length-1].name!==e.name&&t.push(e):t.push(e)}),t}function C(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:E.KEY,o=e.slice(0);return o=m(o,t),o=y(o,t),o=w(o)}t.__esModule=!0,t.normalizeSelection=n,t.isSeparator=r,t.hasSubMenu=i,t.isDisabled=s,t.isSelectionDisabled=l,t.getValidSelection=a,t.prepareVerticalAlignClass=u,t.prepareHorizontalAlignClass=c,t.getAlignmentClasses=h,t.align=d,t.checkSelectionConsistency=p,t.markLabelAsSelected=g,t.isItemHidden=v,t.filterSeparators=C;var b=o(2),S=o(0),E=o(86)},function(e,t,o){e.exports=!o(23)(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})},function(e,t,o){var n=o(52),r=Math.min;e.exports=function(e){return e>0?r(n(e),9007199254740991):0}},function(e,t,o){"use strict";function n(e){var t=void 0;switch(void 0===e?"undefined":c(e)){case"string":case"number":t=""+e;break;case"object":t=null===e?"":""+e;break;case"undefined":t="";break;default:t=""+e}return t}function r(e){return void 0!==e}function i(e){return void 0===e}function s(e){return null===e||""===e||i(e)}function l(e){return"[object RegExp]"===Object.prototype.toString.call(e)}function a(e,t){e=C(e||"");var o="",n=!0,r=u(e),i=S(),l=s(e)||"trial"===e;if(l||r)if(r){var a=Math.floor((0,f.default)("12/10/2017","DD/MM/YYYY").toDate().getTime()/864e5),c=b(e);(c>45e3||c!==parseInt(c,10))&&(o="The license key provided to Handsontable Pro is invalid. Make sure you pass it correctly."),o||(a>c+1&&(o=(0,p.toSingleLine)(h)),n=a>c+15)}else o="Evaluation version of Handsontable Pro. Not licensed for use in a production environment.";else o="The license key provided to Handsontable Pro is invalid. Make sure you pass it correctly.";if(i&&(o=!1,n=!1),o&&!E&&(console[l?"info":"warn"](o),E=!0),n&&t.parentNode){var d=document.createElement("div");d.id="hot-display-license-info",d.appendChild(document.createTextNode("Evaluation version of Handsontable Pro.")),d.appendChild(document.createElement("br")),d.appendChild(document.createTextNode("Not licensed for production use.")),t.parentNode.insertBefore(d,t.nextSibling)}}function u(e){var t=[][g],o=t;if(e[g]!==w("Z"))return!1;for(var n="",r="B<H4P+".split(""),i=w(r.shift());i;i=w(r.shift()||"A"))--i<""[g]?o|=(m(""+m(v(n)+(v(y(e,Math.abs(i),2))+[]).padStart(2,"0")))%w("¢")||2)>>1:n=y(e,i,i?1===r[g]?9:8:6);return o===t}t.__esModule=!0;var c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},h=function(e,t){return Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}(["\n Your license key of Handsontable Pro has expired. \n Renew your maintenance plan at https://handsontable.com or downgrade to the previous version of the software.\n "],["\n Your license key of Handsontable Pro has expired.\\x20\n Renew your maintenance plan at https://handsontable.com or downgrade to the previous version of the software.\n "]);t.stringify=n,t.isDefined=r,t.isUndefined=i,t.isEmpty=s,t.isRegExp=l,t._injectProductInfo=a;var d=o(50),f=function(e){return e&&e.__esModule?e:{default:e}}(d),p=o(205),g="length",v=function(e){return parseInt(e,16)},m=function(e){return parseInt(e,10)},y=function(e,t,o){return e.substr(t,o)},w=function(e){return e.codePointAt(0)-65},C=function(e){return(""+e).replace(/\-/g,"")},b=function(e){return v(y(C(e),v("12"),w("F")))/(v(y(C(e),w("B"),~~![][g]))||9)},S=function(){return"undefined"!=typeof location&&/^([a-z0-9\-]+\.)?\x68\x61\x6E\x64\x73\x6F\x6E\x74\x61\x62\x6C\x65\x2E\x63\x6F\x6D$/i.test(location.host)},E=!1},function(e,t){e.exports=function(e){try{return!!e()}catch(e){return!0}}},function(e,t){var o={}.hasOwnProperty;e.exports=function(e,t){return o.call(e,t)}},function(e,t,o){var n=o(67),r=o(33);e.exports=function(e){return n(r(e))}},function(e,t,o){"use strict";function n(){return a}function r(){return u}function i(){return c}function s(){return h}function l(e){return e||(e=navigator.userAgent),/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(e)}t.__esModule=!0,t.isIE8=n,t.isIE9=r,t.isSafari=i,t.isChrome=s,t.isMobileBrowser=l;var a=!document.createTextNode("test").textContent,u=!!document.documentMode,c=/Safari/.test(navigator.userAgent)&&/Apple Computer/.test(navigator.vendor),h=/Chrome/.test(navigator.userAgent)&&/Google/.test(navigator.vendor)},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e){if("function"==typeof e)return e;if(!y(e))throw Error('No registered validator found under "'+e+'" name');return m(e)}t.__esModule=!0,t.getRegisteredValidators=t.getRegisteredValidatorNames=t.hasValidator=t.getValidator=t.registerValidator=void 0;var i=o(63),s=n(i),l=o(227),a=n(l),u=o(228),c=n(u),h=o(229),d=n(h),f=o(230),p=n(f),g=(0,s.default)("validators"),v=g.register,m=g.getItem,y=g.hasItem,w=g.getNames,C=g.getValues;v("autocomplete",a.default),v("date",c.default),v("numeric",d.default),v("time",p.default),t.registerValidator=v,t.getValidator=r,t.hasValidator=y,t.getRegisteredValidatorNames=w,t.getRegisteredValidators=C},function(e,t,o){var n=o(11),r=o(29),i=o(24),s=o(42)("src"),l=Function.toString,a=(""+l).split("toString");o(44).inspectSource=function(e){return l.call(e)},(e.exports=function(e,t,o,l){var u="function"==typeof o;u&&(i(o,"name")||r(o,"name",t)),e[t]!==o&&(u&&(i(o,s)||r(o,s,e[t]?""+e[t]:a.join(t+""))),e===n?e[t]=o:l?e[t]?e[t]=o:r(e,t,o):(delete e[t],r(e,t,o)))})(Function.prototype,"toString",function(){return"function"==typeof this&&this[s]||l.call(this)})},function(e,t,o){var n=o(17),r=o(43);e.exports=o(20)?function(e,t,o){return n.f(e,t,r(1,o))}:function(e,t,o){return e[t]=o,e}},function(e,t,o){var n=o(55);e.exports=function(e,t,o){if(n(e),void 0===t)return e;switch(o){case 1:return function(o){return e.call(t,o)};case 2:return function(o,n){return e.call(t,o,n)};case 3:return function(o,n,r){return e.call(t,o,n,r)}}return function(){return e.apply(t,arguments)}}},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var i=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),s=o(0),l=o(1),a=o(2),u=o(4),c=n(u),h=o(159),d=n(h),f={};t.default=function(){function e(t){r(this,e),(0,l.defineGetter)(this,"wot",t,{writable:!1}),this.instance=this.wot,this.type="",this.mainTableScrollableElement=null,this.TABLE=this.wot.wtTable.TABLE,this.hider=this.wot.wtTable.hider,this.spreader=this.wot.wtTable.spreader,this.holder=this.wot.wtTable.holder,this.wtRootElement=this.wot.wtTable.wtRootElement,this.trimmingContainer=(0,s.getTrimmingContainer)(this.hider.parentNode.parentNode),this.areElementSizesAdjusted=!1,this.updateStateOfRendering()}return i(e,null,[{key:"registerOverlay",value:function(t,o){if(-1===e.CLONE_TYPES.indexOf(t))throw Error("Unsupported overlay ("+t+").");f[t]=o}},{key:"createOverlay",value:function(e,t){return new f[e](t)}},{key:"hasOverlay",value:function(e){return void 0!==f[e]}},{key:"isOverlayTypeOf",value:function(e,t){return!(!e||!f[t])&&e instanceof f[t]}},{key:"CLONE_TOP",get:function(){return"top"}},{key:"CLONE_BOTTOM",get:function(){return"bottom"}},{key:"CLONE_LEFT",get:function(){return"left"}},{key:"CLONE_TOP_LEFT_CORNER",get:function(){return"top_left_corner"}},{key:"CLONE_BOTTOM_LEFT_CORNER",get:function(){return"bottom_left_corner"}},{key:"CLONE_DEBUG",get:function(){return"debug"}},{key:"CLONE_TYPES",get:function(){return[e.CLONE_TOP,e.CLONE_BOTTOM,e.CLONE_LEFT,e.CLONE_TOP_LEFT_CORNER,e.CLONE_BOTTOM_LEFT_CORNER,e.CLONE_DEBUG]}}]),i(e,[{key:"updateStateOfRendering",value:function(){var e=this.needFullRender;this.needFullRender=this.shouldBeRendered();var t=e!==this.needFullRender;return t&&!this.needFullRender&&this.reset(),t}},{key:"shouldBeRendered",value:function(){return!0}},{key:"updateTrimmingContainer",value:function(){this.trimmingContainer=(0,s.getTrimmingContainer)(this.hider.parentNode.parentNode)}},{key:"updateMainScrollableElement",value:function(){this.mainTableScrollableElement=(0,s.getScrollableElement)(this.wot.wtTable.TABLE)}},{key:"makeClone",value:function(t){if(-1===e.CLONE_TYPES.indexOf(t))throw Error('Clone type "'+t+'" is not supported.');var o=document.createElement("DIV"),n=document.createElement("TABLE");o.className="ht_clone_"+t+" handsontable",o.style.position="absolute",o.style.top=0,o.style.left=0,o.style.overflow="hidden",n.className=this.wot.wtTable.TABLE.className,o.appendChild(n),this.type=t,this.wot.wtTable.wtRootElement.parentNode.appendChild(o);var r=this.wot.getSetting("preventOverflow");return this.mainTableScrollableElement=!0===r||"horizontal"===r&&this.type===e.CLONE_TOP||"vertical"===r&&this.type===e.CLONE_LEFT?window:(0,s.getScrollableElement)(this.wot.wtTable.TABLE),new d.default({cloneSource:this.wot,cloneOverlay:this,table:n})}},{key:"refresh",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=this.shouldBeRendered();this.clone&&(this.needFullRender||t)&&this.clone.draw(e),this.needFullRender=t}},{key:"reset",value:function(){if(this.clone){var e=this.clone.wtTable.holder;(0,a.arrayEach)([e.style,this.clone.wtTable.hider.style,e.parentNode.style],function(e){e.width="",e.height=""})}}},{key:"destroy",value:function(){new c.default(this.clone).destroy()}}]),e}()},function(e,t,o){"use strict";function n(e){return e[0].toUpperCase()+e.substr(1)}function r(){for(var e=[],t=arguments.length,o=Array(t),n=0;t>n;n++)o[n]=arguments[n];for(var r=o.length;r--;){var i=(0,u.stringify)(o[r]).toLowerCase();-1===e.indexOf(i)&&e.push(i)}return 1===e.length}function i(){function e(){return Math.floor(65536*(1+Math.random())).toString(16).substring(1)}return e()+e()+e()+e()}function s(e){return/^([0-9][0-9]?%$)|(^100%$)/.test(e)}function l(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return(""+e).replace(/(?:\\)?\[([^[\]]+)]/g,function(e,o){return"\\"===e.charAt(0)?e.substr(1,e.length-1):void 0===t[o]?"":t[o]})}function a(e){return e+="",e.replace(c,"")}t.__esModule=!0,t.toUpperCaseFirst=n,t.equalsIgnoreCase=r,t.randomString=i,t.isPercentValue=s,t.substitute=l,t.stripTags=a;var u=o(22),c=(o(6),/<\/?\w+\/?>|<\w+[\s|\/][^>]*>/gi)},function(e,t){e.exports=function(e){if(void 0==e)throw TypeError("Can't call method on "+e);return e}},function(e,t,o){"use strict";function n(e){return f.call(window,e)}function r(e){p.call(window,e)}function i(){return"ontouchstart"in window}function s(){var e=document.createElement("div");return!(!e.createShadowRoot||!(""+e.createShadowRoot).match(/\[native code\]/))}function l(){var e=document.createElement("TABLE");e.style.borderSpacing=0,e.style.borderWidth=0,e.style.padding=0;var t=document.createElement("TBODY");e.appendChild(t),t.appendChild(document.createElement("TR")),t.firstChild.appendChild(document.createElement("TD")),t.firstChild.firstChild.innerHTML="<tr><td>t<br>t</td></tr>";var o=document.createElement("CAPTION");o.innerHTML="c<br>c<br>c<br>c",o.style.padding=0,o.style.margin=0,e.insertBefore(o,t),document.body.appendChild(e),v=2*e.lastChild.offsetHeight>e.offsetHeight,document.body.removeChild(e)}function a(){return void 0===v&&l(),v}function u(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return m||(m="object"===("undefined"==typeof Intl?"undefined":c(Intl))?new Intl.Collator(e,t).compare:"function"==typeof String.prototype.localeCompare?function(e,t){return(""+e).localeCompare(t)}:function(e,t){return e===t?0:e>t?-1:1})}t.__esModule=!0;var c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.requestAnimationFrame=n,t.cancelAnimationFrame=r,t.isTouchSupported=i,t.isWebComponentSupportedNatively=s,t.hasCaptionProblem=a,t.getComparisonFunction=u;for(var h=0,d=["ms","moz","webkit","o"],f=window.requestAnimationFrame,p=window.cancelAnimationFrame,g=0;4>g&&!f;++g)f=window[d[g]+"RequestAnimationFrame"],p=window[d[g]+"CancelAnimationFrame"]||window[d[g]+"CancelRequestAnimationFrame"];f||(f=function(e){var t=(new Date).getTime(),o=Math.max(0,16-(t-h)),n=window.setTimeout(function(){e(t+o)},o);return h=t+o,n}),p||(p=function(e){clearTimeout(e)});var v,m=void 0},function(e,t,o){"use strict";function n(e){return"function"==typeof e}function r(e){function t(){var t=this,s=arguments,l=Date.now(),a=!1;r.lastCallThrottled=!0,n||(n=l,a=!0);var u=o-(l-n);return a?(r.lastCallThrottled=!1,e.apply(this,s)):(i&&clearTimeout(i),i=setTimeout(function(){r.lastCallThrottled=!1,e.apply(t,s),n=0,i=void 0},u)),r}var o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:200,n=0,r={lastCallThrottled:!0},i=null;return t}function i(e){function t(){l=i}function o(){return l?(l--,e.apply(this,arguments)):s.apply(this,arguments)}var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:200,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:10,s=r(e,n),l=i;return o.clearHits=t,o}function s(e){function t(){var t=this,i=arguments;return n&&clearTimeout(n),n=setTimeout(function(){r=e.apply(t,i)},o),r}var o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:200,n=null,r=void 0;return t}function l(){for(var e=arguments.length,t=Array(e),o=0;e>o;o++)t[o]=arguments[o];var n=t[0],r=t.slice(1);return function(){return(0,h.arrayReduce)(r,function(e,t){return t(e)},n.apply(this,arguments))}}function a(e){for(var t=arguments.length,o=Array(t>1?t-1:0),n=1;t>n;n++)o[n-1]=arguments[n];return function(){for(var t=arguments.length,n=Array(t),r=0;t>r;r++)n[r]=arguments[r];return e.apply(this,o.concat(n))}}function u(e){function t(n){return function(){for(var r=arguments.length,i=Array(r),s=0;r>s;s++)i[s]=arguments[s];var l=n.concat(i);return o>l.length?t(l):e.apply(this,l)}}var o=e.length;return t([])}function c(e){function t(n){return function(){for(var r=arguments.length,i=Array(r),s=0;r>s;s++)i[s]=arguments[s];var l=n.concat(i.reverse());return o>l.length?t(l):e.apply(this,l)}}var o=e.length;return t([])}t.__esModule=!0,t.isFunction=n,t.throttle=r,t.throttleAfterHits=i,t.debounce=s,t.pipe=l,t.partial=a,t.curry=u,t.curryRight=c;var h=o(2)},function(e,t,o){var n=o(92),r=o(70);e.exports=Object.keys||function(e){return n(e,r)}},function(e,t){var o={}.toString;e.exports=function(e){return o.call(e).slice(8,-1)}},function(e,t,o){var n=o(33);e.exports=function(e){return Object(n(e))}},function(e,t,o){var n=o(14);e.exports=function(e,t){if(!n(e)||e._t!==t)throw TypeError("Incompatible receiver, "+t+" required!");return e}},function(e,t,o){var n=o(9)("unscopables"),r=Array.prototype;void 0==r[n]&&o(29)(r,n,{}),e.exports=function(e){r[n][e]=!0}},function(e,t,o){"use strict";function n(e){this.instance=e,this.state=s.VIRGIN,this._opened=!1,this._fullEditMode=!1,this._closeCallback=null,this.init()}t.__esModule=!0,t.EditorState=void 0;var r=o(12),i=o(22),s=t.EditorState={VIRGIN:"STATE_VIRGIN",EDITING:"STATE_EDITING",WAITING:"STATE_WAITING",FINISHED:"STATE_FINISHED"};n.prototype._fireCallbacks=function(e){this._closeCallback&&(this._closeCallback(e),this._closeCallback=null)},n.prototype.init=function(){},n.prototype.getValue=function(){throw Error("Editor getValue() method unimplemented")},n.prototype.setValue=function(e){throw Error("Editor setValue() method unimplemented")},n.prototype.open=function(){throw Error("Editor open() method unimplemented")},n.prototype.close=function(){throw Error("Editor close() method unimplemented")},n.prototype.prepare=function(e,t,o,n,r,i){this.TD=n,this.row=e,this.col=t,this.prop=o,this.originalValue=r,this.cellProperties=i,this.state=s.VIRGIN},n.prototype.extend=function(){function e(){t.apply(this,arguments)}var t=this.constructor;return function(e,t){function o(){}return o.prototype=t.prototype,e.prototype=new o,e.prototype.constructor=e,e}(e,t)},n.prototype.saveValue=function(e,t){var o=void 0,n=void 0;t?(o=this.instance.getSelected(),o[0]>o[2]&&(n=o[0],o[0]=o[2],o[2]=n),o[1]>o[3]&&(n=o[1],o[1]=o[3],o[3]=n)):o=[this.row,this.col,null,null],this.instance.populateFromArray(o[0],o[1],e,o[2],o[3],"edit")},n.prototype.beginEditing=function(e,t){this.state==s.VIRGIN&&(this.instance.view.scrollViewport(new r.CellCoords(this.row,this.col)),this.instance.view.render(),this.state=s.EDITING,e="string"==typeof e?e:this.originalValue,this.setValue((0,i.stringify)(e)),this.open(t),this._opened=!0,this.focus(),this.instance.view.render(),this.instance.runHooks("afterBeginEditing",this.row,this.col))},n.prototype.finishEditing=function(e,t,o){var n,r=this;if(o){var i=this._closeCallback;this._closeCallback=function(e){i&&i(e),o(e),r.instance.view.render()}}if(!this.isWaiting()){if(this.state==s.VIRGIN)return void this.instance._registerTimeout(setTimeout(function(){r._fireCallbacks(!0)},0));if(this.state==s.EDITING){if(e)return this.cancelChanges(),void this.instance.view.render();var l=this.getValue();n=this.instance.getSettings().trimWhitespace?[["string"==typeof l?String.prototype.trim.call(l||""):l]]:[[l]],this.state=s.WAITING,this.saveValue(n,t),this.instance.getCellValidator(this.cellProperties)?this.instance.addHookOnce("postAfterValidate",function(e){r.state=s.FINISHED,r.discardEditor(e)}):(this.state=s.FINISHED,this.discardEditor(!0))}}},n.prototype.cancelChanges=function(){this.state=s.FINISHED,this.discardEditor()},n.prototype.discardEditor=function(e){this.state===s.FINISHED&&(!1===e&&!0!==this.cellProperties.allowInvalid?(this.instance.selectCell(this.row,this.col),this.focus(),this.state=s.EDITING,this._fireCallbacks(!1)):(this.close(),this._opened=!1,this._fullEditMode=!1,this.state=s.VIRGIN,this._fireCallbacks(!0)))},n.prototype.enableFullEditMode=function(){this._fullEditMode=!0},n.prototype.isInFullEditMode=function(){return this._fullEditMode},n.prototype.isOpened=function(){return this._opened},n.prototype.isWaiting=function(){return this.state===s.WAITING},n.prototype.checkEditorSection=function(){var e=this.instance.countRows(),t="";return this.row<this.instance.getSettings().fixedRowsTop?t=this.col<this.instance.getSettings().fixedColumnsLeft?"top-left-corner":"top":this.instance.getSettings().fixedRowsBottom&&this.row>=e-this.instance.getSettings().fixedRowsBottom?t=this.col<this.instance.getSettings().fixedColumnsLeft?"bottom-left-corner":"bottom":this.col<this.instance.getSettings().fixedColumnsLeft&&(t="left"),t},t.default=n},function(e,t){var o=0,n=Math.random();e.exports=function(e){return"Symbol(".concat(void 0===e?"":e,")_",(++o+n).toString(36))}},function(e,t){e.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},function(e,t){var o=e.exports={version:"2.5.1"};"number"==typeof __e&&(__e=o)},function(e,t){e.exports={}},function(e,t,o){var n=o(17).f,r=o(24),i=o(9)("toStringTag");e.exports=function(e,t,o){e&&!r(e=o?e:e.prototype,i)&&n(e,i,{configurable:!0,value:t})}},function(e,t,o){var n=o(42)("meta"),r=o(14),i=o(24),s=o(17).f,l=0,a=Object.isExtensible||function(){return!0},u=!o(23)(function(){return a(Object.preventExtensions({}))}),c=function(e){s(e,n,{value:{i:"O"+ ++l,w:{}}})},h=function(e,t){if(!r(e))return"symbol"==typeof e?e:("string"==typeof e?"S":"P")+e;if(!i(e,n)){if(!a(e))return"F";if(!t)return"E";c(e)}return e[n].i},d=function(e,t){if(!i(e,n)){if(!a(e))return!0;if(!t)return!1;c(e)}return e[n].w},f=function(e){return u&&p.NEED&&a(e)&&!i(e,n)&&c(e),e},p=e.exports={KEY:n,NEED:!1,fastKey:h,getWeak:d,onFreeze:f}},function(e,t){t.f={}.propertyIsEnumerable},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}();t.default=function(){function e(t,o){n(this,e),void 0!==t&&void 0!==o?(this.row=t,this.col=o):(this.row=null,this.col=null)}return r(e,[{key:"isValid",value:function(e){return this.row>=0&&this.col>=0&&(this.row<e.getSetting("totalRows")&&this.col<e.getSetting("totalColumns"))}},{key:"isEqual",value:function(e){return e===this||this.row===e.row&&this.col===e.col}},{key:"isSouthEastOf",value:function(e){return this.row>=e.row&&this.col>=e.col}},{key:"isNorthWestOf",value:function(e){return e.row>=this.row&&e.col>=this.col}},{key:"isSouthWestOf",value:function(e){return this.row>=e.row&&e.col>=this.col}},{key:"isNorthEastOf",value:function(e){return e.row>=this.row&&this.col>=e.col}}]),e}()},function(t,o){t.exports=e},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}t.__esModule=!0;var r=o(0),i=o(210),s=n(i),l=o(41),a=n(l),u=o(4),c=n(u),h=o(18),d=o(10),f=a.default.prototype.extend();f.prototype.init=function(){var e=this;this.createElements(),this.eventManager=new c.default(this),this.bindEvents(),this.autoResize=(0,s.default)(),this.instance.addHook("afterDestroy",function(){e.destroy()})},f.prototype.getValue=function(){return this.TEXTAREA.value},f.prototype.setValue=function(e){this.TEXTAREA.value=e};var p=function(e){var t,o=this,n=o.getActiveEditor();if(t=(e.ctrlKey||e.metaKey)&&!e.altKey,e.target===n.TEXTAREA&&!(0,d.isImmediatePropagationStopped)(e)){if(17===e.keyCode||224===e.keyCode||91===e.keyCode||93===e.keyCode)return void(0,d.stopImmediatePropagation)(e);switch(e.keyCode){case h.KEY_CODES.ARROW_RIGHT:case h.KEY_CODES.ARROW_LEFT:n.isInFullEditMode()&&(!n.isWaiting()&&!n.allowKeyEventPropagation||!n.isWaiting()&&n.allowKeyEventPropagation&&!n.allowKeyEventPropagation(e.keyCode))&&(0,d.stopImmediatePropagation)(e);break;case h.KEY_CODES.ARROW_UP:case h.KEY_CODES.ARROW_DOWN:n.isInFullEditMode()&&(!n.isWaiting()&&!n.allowKeyEventPropagation||!n.isWaiting()&&n.allowKeyEventPropagation&&!n.allowKeyEventPropagation(e.keyCode))&&(0,d.stopImmediatePropagation)(e);break;case h.KEY_CODES.ENTER:var i=n.instance.getSelected(),s=!(i[0]===i[2]&&i[1]===i[3]);if(t&&!s||e.altKey){if(n.isOpened()){var l=(0,r.getCaretPosition)(n.TEXTAREA),a=n.getValue();n.setValue(a.slice(0,l)+"\n"+a.slice(l)),(0,r.setCaretPosition)(n.TEXTAREA,l+1)}else n.beginEditing(n.originalValue+"\n");(0,d.stopImmediatePropagation)(e)}e.preventDefault();break;case h.KEY_CODES.A:case h.KEY_CODES.X:case h.KEY_CODES.C:case h.KEY_CODES.V:t&&(0,d.stopImmediatePropagation)(e);break;case h.KEY_CODES.BACKSPACE:case h.KEY_CODES.DELETE:case h.KEY_CODES.HOME:case h.KEY_CODES.END:(0,d.stopImmediatePropagation)(e)}-1===[h.KEY_CODES.ARROW_UP,h.KEY_CODES.ARROW_RIGHT,h.KEY_CODES.ARROW_DOWN,h.KEY_CODES.ARROW_LEFT].indexOf(e.keyCode)&&n.autoResize.resize(String.fromCharCode(e.keyCode))}};f.prototype.open=function(){this.refreshDimensions(),this.instance.addHook("beforeKeyDown",p)},f.prototype.close=function(e){this.textareaParentStyle.display="none",this.autoResize.unObserve(),document.activeElement===this.TEXTAREA&&this.instance.listen(),this.instance.removeHook("beforeKeyDown",p)},f.prototype.focus=function(){this.TEXTAREA.focus(),(0,r.setCaretPosition)(this.TEXTAREA,this.TEXTAREA.value.length)},f.prototype.createElements=function(){this.TEXTAREA=document.createElement("TEXTAREA"),(0,r.addClass)(this.TEXTAREA,"handsontableInput"),this.textareaStyle=this.TEXTAREA.style,this.textareaStyle.width=0,this.textareaStyle.height=0,this.TEXTAREA_PARENT=document.createElement("DIV"),(0,r.addClass)(this.TEXTAREA_PARENT,"handsontableInputHolder"),this.textareaParentStyle=this.TEXTAREA_PARENT.style,this.textareaParentStyle.top=0,this.textareaParentStyle.left=0,this.textareaParentStyle.display="none",this.TEXTAREA_PARENT.appendChild(this.TEXTAREA),this.instance.rootElement.appendChild(this.TEXTAREA_PARENT);var e=this;this.instance._registerTimeout(setTimeout(function(){e.refreshDimensions()},0))},f.prototype.getEditedCell=function(){var e,t=this.checkEditorSection();switch(t){case"top":e=this.instance.view.wt.wtOverlays.topOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.textareaParentStyle.zIndex=101;break;case"top-left-corner":e=this.instance.view.wt.wtOverlays.topLeftCornerOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.textareaParentStyle.zIndex=103;break;case"bottom-left-corner":e=this.instance.view.wt.wtOverlays.bottomLeftCornerOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.textareaParentStyle.zIndex=103;break;case"left":e=this.instance.view.wt.wtOverlays.leftOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.textareaParentStyle.zIndex=102;break;case"bottom":e=this.instance.view.wt.wtOverlays.bottomOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.textareaParentStyle.zIndex=102;break;default:e=this.instance.getCell(this.row,this.col),this.textareaParentStyle.zIndex=""}return-1!=e&&-2!=e?e:void 0},f.prototype.refreshValue=function(){var e=this.instance.getSourceDataAtCell(this.row,this.prop);this.originalValue=e,this.setValue(e),this.refreshDimensions()},f.prototype.refreshDimensions=function(){if(this.state===l.EditorState.EDITING){if(!(this.TD=this.getEditedCell()))return void this.close(!0);var e,t=(0,r.offset)(this.TD),o=(0,r.offset)(this.instance.rootElement),n=(0,r.getScrollableElement)(this.TD),i=this.instance.countRows(),s=t.top===o.top?0:1,a=t.top-o.top-s-(n.scrollTop||0),u=t.left-o.left-1-(n.scrollLeft||0),c=this.instance.getSettings(),h=(this.instance.hasRowHeaders(),this.instance.hasColHeaders()),d=this.checkEditorSection(),f=this.TD.style.backgroundColor;switch(d){case"top":e=(0,r.getCssTransform)(this.instance.view.wt.wtOverlays.topOverlay.clone.wtTable.holder.parentNode);break;case"left":e=(0,r.getCssTransform)(this.instance.view.wt.wtOverlays.leftOverlay.clone.wtTable.holder.parentNode);break;case"top-left-corner":e=(0,r.getCssTransform)(this.instance.view.wt.wtOverlays.topLeftCornerOverlay.clone.wtTable.holder.parentNode);break;case"bottom-left-corner":e=(0,r.getCssTransform)(this.instance.view.wt.wtOverlays.bottomLeftCornerOverlay.clone.wtTable.holder.parentNode);break;case"bottom":e=(0,r.getCssTransform)(this.instance.view.wt.wtOverlays.bottomOverlay.clone.wtTable.holder.parentNode)}(h&&0===this.instance.getSelected()[0]||c.fixedRowsBottom&&this.instance.getSelected()[0]===i-c.fixedRowsBottom)&&(a+=1),0===this.instance.getSelected()[1]&&(u+=1),e&&-1!=e?this.textareaParentStyle[e[0]]=e[1]:(0,r.resetCssTransform)(this.TEXTAREA_PARENT),this.textareaParentStyle.top=a+"px",this.textareaParentStyle.left=u+"px";var p=this.instance.view.wt.wtViewport.rowsRenderCalculator.startPosition,g=this.instance.view.wt.wtViewport.columnsRenderCalculator.startPosition,v=this.instance.view.wt.wtOverlays.leftOverlay.getScrollPosition(),m=this.instance.view.wt.wtOverlays.topOverlay.getScrollPosition(),y=(0,r.getScrollbarWidth)(),w=this.TD.offsetTop+p-m,C=this.TD.offsetLeft+g-v,b=(0,r.innerWidth)(this.TD)-8,S=(0,r.hasVerticalScrollbar)(n)?y:0,E=(0,r.hasHorizontalScrollbar)(n)?y:0,R=this.instance.view.maximumVisibleElementWidth(C)-9-S,O=this.TD.scrollHeight+1,k=Math.max(this.instance.view.maximumVisibleElementHeight(w)-E,23),T=(0,r.getComputedStyle)(this.TD);this.TEXTAREA.style.fontSize=T.fontSize,this.TEXTAREA.style.fontFamily=T.fontFamily,this.TEXTAREA.style.backgroundColor="",this.TEXTAREA.style.backgroundColor=f||(0,r.getComputedStyle)(this.TEXTAREA).backgroundColor,this.autoResize.init(this.TEXTAREA,{minHeight:Math.min(O,k),maxHeight:k,minWidth:Math.min(b,R),maxWidth:R},!0),this.textareaParentStyle.display="block"}},f.prototype.bindEvents=function(){var e=this;this.eventManager.addEventListener(this.TEXTAREA,"cut",function(e){(0,d.stopPropagation)(e)}),this.eventManager.addEventListener(this.TEXTAREA,"paste",function(e){(0,d.stopPropagation)(e)}),this.instance.addHook("afterScrollHorizontally",function(){e.refreshDimensions()}),this.instance.addHook("afterScrollVertically",function(){e.refreshDimensions()}),this.instance.addHook("afterColumnResize",function(){e.refreshDimensions(),e.focus()}),this.instance.addHook("afterRowResize",function(){e.refreshDimensions(),e.focus()}),this.instance.addHook("afterDestroy",function(){e.eventManager.destroy()})},f.prototype.destroy=function(){this.eventManager.destroy()},t.default=f},function(e,t){var o=Math.ceil,n=Math.floor;e.exports=function(e){return isNaN(e=+e)?0:(e>0?n:o)(e)}},function(e,t,o){var n=o(52),r=Math.max,i=Math.min;e.exports=function(e,t){return e=n(e),0>e?r(e+t,0):i(e,t)}},function(e,t,o){var n=o(28);e.exports=function(e,t,o){for(var r in t)n(e,r,t[r],o);return e}},function(e,t){e.exports=function(e){if("function"!=typeof e)throw TypeError(e+" is not a function!");return e}},function(e,t){e.exports=function(e,t,o,n){if(!(e instanceof t)||void 0!==n&&n in e)throw TypeError(o+": incorrect invocation!");return e}},function(e,t,o){var n=o(30),r=o(95),i=o(96),s=o(16),l=o(21),a=o(97),u={},c={},t=e.exports=function(e,t,o,h,d){var f,p,g,v,m=d?function(){return e}:a(e),y=n(o,h,t?2:1),w=0;if("function"!=typeof m)throw TypeError(e+" is not iterable!");if(i(m)){for(f=l(e.length);f>w;w++)if((v=t?y(s(p=e[w])[0],p[1]):y(e[w]))===u||v===c)return v}else for(g=m.call(e);!(p=g.next()).done;)if((v=r(g,y,p.value,t))===u||v===c)return v};t.BREAK=u,t.RETURN=c},function(e,t){e.exports=!1},function(e,t,o){"use strict";var n=o(11),r=o(3),i=o(28),s=o(54),l=o(47),a=o(57),u=o(56),c=o(14),h=o(23),d=o(71),f=o(46),p=o(184);e.exports=function(e,t,o,g,v,m){var y=n[e],w=y,C=v?"set":"add",b=w&&w.prototype,S={},E=function(e){var t=b[e];i(b,e,"delete"==e?function(e){return!(m&&!c(e))&&t.call(this,0===e?0:e)}:"has"==e?function(e){return!(m&&!c(e))&&t.call(this,0===e?0:e)}:"get"==e?function(e){return m&&!c(e)?void 0:t.call(this,0===e?0:e)}:"add"==e?function(e){return t.call(this,0===e?0:e),this}:function(e,o){return t.call(this,0===e?0:e,o),this})};if("function"==typeof w&&(m||b.forEach&&!h(function(){(new w).entries().next()}))){var R=new w,O=R[C](m?{}:-0,1)!=R,k=h(function(){R.has(1)}),T=d(function(e){new w(e)}),_=!m&&h(function(){for(var e=new w,t=5;t--;)e[C](t,t);return!e.has(-0)});T||(w=t(function(t,o){u(t,w,e);var n=p(new y,t,w);return void 0!=o&&a(o,v,n[C],n),n}),w.prototype=b,b.constructor=w),(k||_)&&(E("delete"),E("has"),v&&E("get")),(_||O)&&E(C),m&&b.clear&&delete b.clear}else w=g.getConstructor(t,e,v,C),s(w.prototype,o),l.NEED=!0;return f(w,e),S[e]=w,r(r.G+r.W+r.F*(w!=y),S),m||g.setStrong(w,e,v),w}},function(e,t,o){var n=o(30),r=o(67),i=o(38),s=o(21),l=o(185);e.exports=function(e,t){var o=1==e,a=2==e,u=3==e,c=4==e,h=6==e,d=5==e||h,f=t||l;return function(t,l,p){for(var g,v,m=i(t),y=r(m),w=n(l,p,3),C=s(y.length),b=0,S=o?f(t,C):a?f(t,0):void 0;C>b;b++)if((d||b in y)&&(g=y[b],v=w(g,b,m),e))if(o)S[b]=v;else if(v)switch(e){case 3:return!0;case 5:return g;case 6:return b;case 2:S.push(g)}else if(c)return!1;return h?-1:u||c?c:S}}},function(e,t){t.f=Object.getOwnPropertySymbols},function(e,t,o){"use strict";var n=o(29),r=o(28),i=o(23),s=o(33),l=o(9);e.exports=function(e,t,o){var a=l(e),u=o(s,a,""[e]),c=u[0],h=u[1];i(function(){var t={};return t[a]=function(){return 7},7!=""[e](t)})&&(r(String.prototype,e,c),n(RegExp.prototype,a,2==t?function(e,t){return h.call(e,this,t)}:function(e){return h.call(e,this)}))}},function(e,t,o){"use strict";function n(e){if(Array.isArray(e)){for(var t=0,o=Array(e.length);e.length>t;t++)o[t]=e[t];return o}return Array.from(e)}function r(){function e(e,t){a.set(e,t)}function t(e){return a.get(e)}function o(e){return a.has(e)}function r(){return[].concat(n(a.keys()))}function s(){return[].concat(n(a.values()))}var l=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"common";i.has(l)||i.set(l,new Map);var a=i.get(l);return{register:e,getItem:t,hasItem:o,getNames:r,getValues:s}}t.__esModule=!0,t.default=r;var i=t.collection=new Map},function(e,t,o){var n=o(14),r=o(11).document,i=n(r)&&n(r.createElement);e.exports=function(e){return i?r.createElement(e):{}}},function(e,t,o){var n=o(14);e.exports=function(e,t){if(!n(e))return e;var o,r;if(t&&"function"==typeof(o=e.toString)&&!n(r=o.call(e)))return r;if("function"==typeof(o=e.valueOf)&&!n(r=o.call(e)))return r;if(!t&&"function"==typeof(o=e.toString)&&!n(r=o.call(e)))return r;throw TypeError("Can't convert object to primitive value")}},function(e,t,o){var n=o(16),r=o(181),i=o(70),s=o(68)("IE_PROTO"),l=function(){},a=function(){var e,t=o(64)("iframe"),n=i.length;for(t.style.display="none",o(94).appendChild(t),t.src="javascript:",e=t.contentWindow.document,e.open(),e.write("<script>document.F=Object<\/script>"),e.close(),a=e.F;n--;)delete a.prototype[i[n]];return a()};e.exports=Object.create||function(e,t){var o;return null!==e?(l.prototype=n(e),o=new l,l.prototype=null,o[s]=e):o=a(),void 0===t?o:r(o,t)}},function(e,t,o){var n=o(37);e.exports=Object("z").propertyIsEnumerable(0)?Object:function(e){return"String"==n(e)?e.split(""):Object(e)}},function(e,t,o){var n=o(69)("keys"),r=o(42);e.exports=function(e){return n[e]||(n[e]=r(e))}},function(e,t,o){var n=o(11),r=n["__core-js_shared__"]||(n["__core-js_shared__"]={});e.exports=function(e){return r[e]||(r[e]={})}},function(e,t){e.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},function(e,t,o){var n=o(9)("iterator"),r=!1;try{var i=[7][n]();i.return=function(){r=!0},Array.from(i,function(){throw 2})}catch(e){}e.exports=function(e,t){if(!t&&!r)return!1;var o=!1;try{var i=[7],s=i[n]();s.next=function(){return{done:o=!0}},i[n]=function(){return s},e(i)}catch(e){}return o}},function(e,t,o){var n=o(48),r=o(43),i=o(25),s=o(65),l=o(24),a=o(91),u=Object.getOwnPropertyDescriptor;t.f=o(20)?u:function(e,t){if(e=i(e),t=s(t,!0),a)try{return u(e,t)}catch(e){}if(l(e,t))return r(!n.f.call(e,t),e[t])}},function(e,t,o){var n,r,i,s=o(30),l=o(188),a=o(94),u=o(64),c=o(11),h=c.process,d=c.setImmediate,f=c.clearImmediate,p=c.MessageChannel,g=c.Dispatch,v=0,m={},y=function(){var e=+this;if(m.hasOwnProperty(e)){var t=m[e];delete m[e],t()}},w=function(e){y.call(e.data)};d&&f||(d=function(e){for(var t=[],o=1;arguments.length>o;)t.push(arguments[o++]);return m[++v]=function(){l("function"==typeof e?e:Function(e),t)},n(v),v},f=function(e){delete m[e]},"process"==o(37)(h)?n=function(e){h.nextTick(s(y,e,1))}:g&&g.now?n=function(e){g.now(s(y,e,1))}:p?(r=new p,i=r.port2,r.port1.onmessage=w,n=s(i.postMessage,i,1)):c.addEventListener&&"function"==typeof postMessage&&!c.importScripts?(n=function(e){c.postMessage(e+"","*")},c.addEventListener("message",w,!1)):n="onreadystatechange"in u("script")?function(e){a.appendChild(u("script")).onreadystatechange=function(){a.removeChild(this),y.call(e)}}:function(e){setTimeout(s(y,e,1),0)}),e.exports={set:d,clear:f}},function(e,t,o){var n=o(92),r=o(70).concat("length","prototype");t.f=Object.getOwnPropertyNames||function(e){return n(e,r)}},function(e,t,o){var n=o(123),r=o(33);e.exports=function(e,t,o){if(n(t))throw TypeError("String#"+o+" doesn't accept regex!");return r(e)+""}},function(e,t,o){var n=o(9)("match");e.exports=function(e){var t=/./;try{"/./"[e](t)}catch(o){try{return t[n]=!1,!"/./"[e](t)}catch(e){}}return!0}},function(e,t,o){"use strict";var n=o(17),r=o(43);e.exports=function(e,t,o){t in e?n.f(e,t,r(0,o)):e[t]=o}},function(e,t,o){"use strict";var n=o(40),r=o(100),i=o(45),s=o(25);e.exports=o(99)(Array,"Array",function(e,t){this._t=s(e),this._i=0,this._k=t},function(){var e=this._t,t=this._k,o=this._i++;return e&&e.length>o?"keys"==t?r(0,o):"values"==t?r(0,e[o]):r(0,[o,e[o]]):(this._t=void 0,r(1))},"values"),i.Arguments=i.Array,n("keys"),n("values"),n("entries")},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=o(49),s=function(e){return e&&e.__esModule?e:{default:e}}(i);t.default=function(){function e(t,o,r){n(this,e),this.highlight=t,this.from=o,this.to=r}return r(e,[{key:"isValid",value:function(e){return this.from.isValid(e)&&this.to.isValid(e)}},{key:"isSingle",value:function(){return this.from.row===this.to.row&&this.from.col===this.to.col}},{key:"getHeight",value:function(){return Math.max(this.from.row,this.to.row)-Math.min(this.from.row,this.to.row)+1}},{key:"getWidth",value:function(){return Math.max(this.from.col,this.to.col)-Math.min(this.from.col,this.to.col)+1}},{key:"includes",value:function(e){var t=e.row,o=e.col,n=this.getTopLeftCorner(),r=this.getBottomRightCorner();return!(n.row>t||t>r.row||n.col>o||o>r.col)}},{key:"includesRange",value:function(e){return this.includes(e.getTopLeftCorner())&&this.includes(e.getBottomRightCorner())}},{key:"isEqual",value:function(e){return Math.min(this.from.row,this.to.row)==Math.min(e.from.row,e.to.row)&&Math.max(this.from.row,this.to.row)==Math.max(e.from.row,e.to.row)&&Math.min(this.from.col,this.to.col)==Math.min(e.from.col,e.to.col)&&Math.max(this.from.col,this.to.col)==Math.max(e.from.col,e.to.col)}},{key:"overlaps",value:function(e){return e.isSouthEastOf(this.getTopLeftCorner())&&e.isNorthWestOf(this.getBottomRightCorner())}},{key:"isSouthEastOf",value:function(e){return this.getTopLeftCorner().isSouthEastOf(e)||this.getBottomRightCorner().isSouthEastOf(e)}},{key:"isNorthWestOf",value:function(e){return this.getTopLeftCorner().isNorthWestOf(e)||this.getBottomRightCorner().isNorthWestOf(e)}},{key:"expand",value:function(e){var t=this.getTopLeftCorner(),o=this.getBottomRightCorner();return(t.row>e.row||t.col>e.col||e.row>o.row||e.col>o.col)&&(this.from=new s.default(Math.min(t.row,e.row),Math.min(t.col,e.col)),this.to=new s.default(Math.max(o.row,e.row),Math.max(o.col,e.col)),!0)}},{key:"expandByRange",value:function(t){if(this.includesRange(t)||!this.overlaps(t))return!1;var o=this.getTopLeftCorner(),n=this.getBottomRightCorner(),r=(this.getTopRightCorner(),this.getBottomLeftCorner(),t.getTopLeftCorner()),i=t.getBottomRightCorner(),l=Math.min(o.row,r.row),a=Math.min(o.col,r.col),u=Math.max(n.row,i.row),c=Math.max(n.col,i.col),h=new s.default(l,a),d=new s.default(u,c),f=new e(h,h,d).isCorner(this.from,t),p=t.isEqual(new e(h,h,d));return f&&!p&&(this.from.col>h.col&&(h.col=c,d.col=a),this.from.row>h.row&&(h.row=u,d.row=l)),this.from=h,this.to=d,!0}},{key:"getDirection",value:function(){return this.from.isNorthWestOf(this.to)?"NW-SE":this.from.isNorthEastOf(this.to)?"NE-SW":this.from.isSouthEastOf(this.to)?"SE-NW":this.from.isSouthWestOf(this.to)?"SW-NE":void 0}},{key:"setDirection",value:function(e){switch(e){case"NW-SE":var t=[this.getTopLeftCorner(),this.getBottomRightCorner()];this.from=t[0],this.to=t[1];break;case"NE-SW":var o=[this.getTopRightCorner(),this.getBottomLeftCorner()];this.from=o[0],this.to=o[1];break;case"SE-NW":var n=[this.getBottomRightCorner(),this.getTopLeftCorner()];this.from=n[0],this.to=n[1];break;case"SW-NE":var r=[this.getBottomLeftCorner(),this.getTopRightCorner()];this.from=r[0],this.to=r[1]}}},{key:"getTopLeftCorner",value:function(){return new s.default(Math.min(this.from.row,this.to.row),Math.min(this.from.col,this.to.col))}},{key:"getBottomRightCorner",value:function(){return new s.default(Math.max(this.from.row,this.to.row),Math.max(this.from.col,this.to.col))}},{key:"getTopRightCorner",value:function(){return new s.default(Math.min(this.from.row,this.to.row),Math.max(this.from.col,this.to.col))}},{key:"getBottomLeftCorner",value:function(){return new s.default(Math.max(this.from.row,this.to.row),Math.min(this.from.col,this.to.col))}},{key:"isCorner",value:function(e,t){return!!(t&&t.includes(e)&&(this.getTopLeftCorner().isEqual(new s.default(t.from.row,t.from.col))||this.getTopRightCorner().isEqual(new s.default(t.from.row,t.to.col))||this.getBottomLeftCorner().isEqual(new s.default(t.to.row,t.from.col))||this.getBottomRightCorner().isEqual(new s.default(t.to.row,t.to.col))))||(e.isEqual(this.getTopLeftCorner())||e.isEqual(this.getTopRightCorner())||e.isEqual(this.getBottomLeftCorner())||e.isEqual(this.getBottomRightCorner()))}},{key:"getOppositeCorner",value:function(e,t){if(!(e instanceof s.default))return!1;if(t&&t.includes(e)){if(this.getTopLeftCorner().isEqual(new s.default(t.from.row,t.from.col)))return this.getBottomRightCorner();if(this.getTopRightCorner().isEqual(new s.default(t.from.row,t.to.col)))return this.getBottomLeftCorner();if(this.getBottomLeftCorner().isEqual(new s.default(t.to.row,t.from.col)))return this.getTopRightCorner();if(this.getBottomRightCorner().isEqual(new s.default(t.to.row,t.to.col)))return this.getTopLeftCorner()}return e.isEqual(this.getBottomRightCorner())?this.getTopLeftCorner():e.isEqual(this.getTopLeftCorner())?this.getBottomRightCorner():e.isEqual(this.getTopRightCorner())?this.getBottomLeftCorner():e.isEqual(this.getBottomLeftCorner())?this.getTopRightCorner():void 0}},{key:"getBordersSharedWith",value:function(e){if(!this.includesRange(e))return[];var t={top:Math.min(this.from.row,this.to.row),bottom:Math.max(this.from.row,this.to.row),left:Math.min(this.from.col,this.to.col),right:Math.max(this.from.col,this.to.col)},o={top:Math.min(e.from.row,e.to.row),bottom:Math.max(e.from.row,e.to.row),left:Math.min(e.from.col,e.to.col),right:Math.max(e.from.col,e.to.col)},n=[];return t.top==o.top&&n.push("top"),t.right==o.right&&n.push("right"),t.bottom==o.bottom&&n.push("bottom"),t.left==o.left&&n.push("left"),n}},{key:"getInner",value:function(){for(var e=this.getTopLeftCorner(),t=this.getBottomRightCorner(),o=[],n=e.row;t.row>=n;n++)for(var r=e.col;t.col>=r;r++)this.from.row===n&&this.from.col===r||this.to.row===n&&this.to.col===r||o.push(new s.default(n,r));return o}},{key:"getAll",value:function(){for(var e=this.getTopLeftCorner(),t=this.getBottomRightCorner(),o=[],n=e.row;t.row>=n;n++)for(var r=e.col;t.col>=r;r++)o.push(e.row===n&&e.col===r?e:t.row===n&&t.col===r?t:new s.default(n,r));return o}},{key:"forAll",value:function(e){for(var t=this.getTopLeftCorner(),o=this.getBottomRightCorner(),n=t.row;o.row>=n;n++)for(var r=t.col;o.col>=r;r++){var i=e(n,r);if(!1===i)return}}}]),e}()},function(e,o){e.exports=t},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e){if(!P(e))throw Error('You declared cell type "'+e+'" as a string that is not mapped to a known object.\n Cell type must be an object or a string mapped to an object registered by "Handsontable.cellTypes.registerCellType" method');return A(e)}function i(e,t){var o=t.editor,n=t.renderer,r=t.validator;o&&(0,a.registerEditor)(e,o),n&&(0,u.registerRenderer)(e,n),r&&(0,c.registerValidator)(e,r),H(e,t)}t.__esModule=!0,t.getRegisteredCellTypes=t.getRegisteredCellTypeNames=t.hasCellType=t.getCellType=t.registerCellType=void 0;var s=o(63),l=n(s),a=o(15),u=o(8),c=o(27),h=o(231),d=n(h),f=o(232),p=n(f),g=o(233),v=n(g),m=o(234),y=n(m),w=o(235),C=n(w),b=o(236),S=n(b),E=o(237),R=n(E),O=o(238),k=n(O),T=o(239),_=n(T),M=(0,l.default)("cellTypes"),H=M.register,A=M.getItem,P=M.hasItem,x=M.getNames,D=M.getValues;i("autocomplete",d.default),i("checkbox",p.default),i("date",v.default),i("dropdown",y.default),i("handsontable",C.default),i("numeric",S.default),i("password",R.default),i("text",k.default),i("time",_.default),t.registerCellType=i,t.getCellType=r,t.hasCellType=P,t.getRegisteredCellTypeNames=x,t.getRegisteredCellTypes=D},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e){if(Array.isArray(e)){for(var t=0,o=Array(e.length);e.length>t;t++)o[t]=e[t];return o}return Array.from(e)}function i(e,t){function o(){var e=!1;return{validatorsInQueue:0,valid:!0,addValidatorToQueue:function(){this.validatorsInQueue++,e=!1},removeValidatorFormQueue:function(){this.validatorsInQueue=0>this.validatorsInQueue-1?0:this.validatorsInQueue-1,this.checkIfQueueIsEmpty()},onQueueEmpty:function(e){},checkIfQueueIsEmpty:function(){0==this.validatorsInQueue&&0==e&&(e=!0,this.onQueueEmpty(this.valid))}}}function n(e,t,n){function r(){var o;e.length&&(o=U.runHooks("beforeChange",e,t),(0,d.isFunction)(o)?console.warn("Your beforeChange callback returns a function. It's not supported since Handsontable 0.12.1 (and the returned function will not be executed)."):!1===o&&e.splice(0,e.length)),n()}var i=new o;i.onQueueEmpty=r;for(var s=e.length-1;s>=0;s--)if(null===e[s])e.splice(s,1);else{var l=e[s][0],a=_.propToCol(e[s][1]),h=U.getCellMeta(l,a);if("numeric"===h.type&&"string"==typeof e[s][3]&&e[s][3].length>0&&(/^-?[\d\s]*(\.|,)?\d*$/.test(e[s][3])||h.format)){var p=e[s][3].length;u.default.culture((0,f.isUndefined)(h.language)?"en-US":e[s][3].indexOf(".")===p-3&&-1===e[s][3].indexOf(",")?"en-US":h.language);u.default.cultureData(u.default.culture());e[s][3]=u.default.validate(e[s][3])&&!isNaN(e[s][3])?parseFloat(e[s][3]):(0,u.default)().unformat(e[s][3])||e[s][3]}U.getCellValidator(h)&&(i.addValidatorToQueue(),U.validateCell(e[s][3],h,function(t,o){return function(n){if("boolean"!=typeof n)throw Error("Validation error: result is not boolean");if(!1===n&&!1===o.allowInvalid){e.splice(t,1),o.valid=!0;var r=U.getCell(o.visualRow,o.visualCol);(0,c.removeClass)(r,U.getSettings().invalidCellClassName),--t}i.removeValidatorFormQueue()}}(s,h),t))}i.checkIfQueueIsEmpty()}function i(e,t){var o=e.length-1;if(o>=0){for(;o>=0;o--){var n=!1;if(null!==e[o]){if(null!=e[o][2]||null!=e[o][3]){if(w.settings.allowInsertRow)for(;e[o][0]>U.countRows()-1;){var r=_.createRow(void 0,void 0,t);if(0===r){n=!0;break}}if(!n){if("array"===U.dataType&&(!w.settings.columns||0===w.settings.columns.length)&&w.settings.allowInsertColumn)for(;_.propToCol(e[o][1])>U.countCols()-1;)_.createCol(void 0,void 0,t);_.set(e[o][0],e[o][1],e[o][3])}}}else e.splice(o,1)}U.forceFullRender=!0,N.adjustRowsAndCols(),U.runHooks("beforeChangeRender",e,t),j.refreshBorders(null,!0),U.view.wt.wtOverlays.adjustElementsSize(),U.runHooks("afterChange",e,t||"edit");var i=U.getActiveEditor();i&&(0,f.isDefined)(i.refreshValue)&&i.refreshValue()}}function a(e,t,o){return"object"===(void 0===e?"undefined":l(e))?e:[[e,t,o]]}function g(e){if((0,b.hasOwnProperty)(e,"type")){var t,o={};"object"===l(e.type)?t=e.type:"string"==typeof e.type&&(t=(0,B.getCellType)(e.type));for(var n in t)(0,b.hasOwnProperty)(t,n)&&!(0,b.hasOwnProperty)(e,n)&&(o[n]=t[n]);return o}}function m(){throw Error("This method cannot be called because this Handsontable instance has been destroyed")}var w,_,H,N,j,V,z=arguments.length>2&&void 0!==arguments[2]&&arguments[2],U=this,Y=function(){},K=new C.default(U);(0,b.extend)(Y.prototype,W.default.prototype),(0,b.extend)(Y.prototype,t),(0,b.extend)(Y.prototype,g(t)),(0,D.hasValidParameter)(z)&&(0,D.registerAsRootInstance)(this),this.rootElement=e,this.isHotTableEnv=(0,c.isChildOfWebComponentTable)(this.rootElement),C.default.isHotTableEnv=this.isHotTableEnv,this.container=document.createElement("div"),this.renderCall=!1,e.insertBefore(this.container,e.firstChild),this.guid="ht_"+(0,k.randomString)();var G=(0,x.getTranslator)(U);H=new A.default(U),this.rootElement.id&&"ht_"!==this.rootElement.id.substring(0,3)||(this.rootElement.id=this.guid),w={cellSettings:[],columnSettings:[],columnsSettingConflicts:["data","width"],settings:new Y,selRange:null,isPopulated:null,scrollable:null,firstRun:!0},N={alter:function(e,t,o,n,i){function s(e,t,o,n){var i=function(){var e=void 0;return"array"===n?e=[]:"object"===n&&(e={}),e},s=(0,S.arrayMap)(Array(o),function(){return i()});s.unshift(t,0),e.splice.apply(e,r(s))}var l;switch(o=o||1,e){case"insert_row":var a=U.countSourceRows();if(U.getSettings().maxRows===a)return;t=(0,f.isDefined)(t)?t:a,l=_.createRow(t,o,n),s(w.cellSettings,t,o,"array"),l&&(j.isSelected()&&w.selRange.from.row>=t?(w.selRange.from.row+=l,j.transformEnd(l,0)):j.refreshBorders());break;case"insert_col":l=_.createCol(t,o,n);for(var u=0,c=U.countSourceRows();c>u;u++)w.cellSettings[u]&&s(w.cellSettings[u],t,o);if(l){if(Array.isArray(U.getSettings().colHeaders)){var h=[t,0];h.length+=l,Array.prototype.splice.apply(U.getSettings().colHeaders,h)}j.isSelected()&&w.selRange.from.col>=t?(w.selRange.from.col+=l,j.transformEnd(0,l)):j.refreshBorders()}break;case"remove_row":_.removeRow(t,o,n),w.cellSettings.splice(t,o);var d=U.countRows(),p=U.getSettings().fixedRowsTop;t+1>p||(U.getSettings().fixedRowsTop-=Math.min(o,p-t));var g=U.getSettings().fixedRowsBottom;g&&t>=d-g&&(U.getSettings().fixedRowsBottom-=Math.min(o,g)),N.adjustRowsAndCols(),j.refreshBorders();break;case"remove_col":var v=G.toPhysicalColumn(t);_.removeCol(t,o,n);for(var m=0,y=U.countSourceRows();y>m;m++)w.cellSettings[m]&&w.cellSettings[m].splice(v,o);var C=U.getSettings().fixedColumnsLeft;t+1>C||(U.getSettings().fixedColumnsLeft-=Math.min(o,C-t)),Array.isArray(U.getSettings().colHeaders)&&(void 0===v&&(v=-1),U.getSettings().colHeaders.splice(v,o)),N.adjustRowsAndCols(),j.refreshBorders();break;default:throw Error('There is no such action "'+e+'"')}i||N.adjustRowsAndCols()},adjustRowsAndCols:function(){if(w.settings.minRows){var e=U.countRows();if(w.settings.minRows>e)for(var t=0,o=w.settings.minRows;o-e>t;t++)_.createRow(U.countRows(),1,"auto")}if(w.settings.minSpareRows){var n=U.countEmptyRows(!0);if(w.settings.minSpareRows>n)for(;w.settings.minSpareRows>n&&U.countSourceRows()<w.settings.maxRows;n++)_.createRow(U.countRows(),1,"auto")}var r=void 0;if((w.settings.minCols||w.settings.minSpareCols)&&(r=U.countEmptyCols(!0)),w.settings.minCols&&!w.settings.columns&&U.countCols()<w.settings.minCols)for(;U.countCols()<w.settings.minCols;r++)_.createCol(U.countCols(),1,"auto");if(w.settings.minSpareCols&&!w.settings.columns&&"array"===U.dataType&&w.settings.minSpareCols>r)for(;w.settings.minSpareCols>r&&U.countCols()<w.settings.maxCols;r++)_.createCol(U.countCols(),1,"auto");var i=U.countRows(),s=U.countCols();if(0!==i&&0!==s||j.deselect(),j.isSelected()){var l=!1,a=w.selRange.from.row,u=w.selRange.from.col,c=w.selRange.to.row,h=w.selRange.to.col;a>i-1?(a=i-1,l=!0,c>a&&(c=a)):c>i-1&&(c=i-1,l=!0,a>c&&(a=c)),u>s-1?(u=s-1,l=!0,h>u&&(h=u)):h>s-1&&(h=s-1,l=!0,u>h&&(u=h)),l&&U.selectCell(a,u,c,h)}U.view&&U.view.wt.wtOverlays.adjustElementsSize()},populateFromArray:function(e,t,o,n,i,s,a){var u,c,h,d,p=[],g={};if(0===(c=t.length))return!1;var v,m,y,C;switch(i){case"shift_down":for(v=o?o.col-e.col+1:0,m=o?o.row-e.row+1:0,t=(0,P.translateRowsToColumns)(t),h=0,d=t.length,y=Math.max(d,v);y>h;h++)if(d>h){var S;for(u=0,c=t[h].length;m-c>u;u++)t[h].push(t[h][u%c]);t[h].unshift(e.col+h,e.row,0),(S=U).spliceCol.apply(S,r(t[h]))}else{var E;t[h%d][0]=e.col+h,(E=U).spliceCol.apply(E,r(t[h%d]))}break;case"shift_right":for(v=o?o.col-e.col+1:0,m=o?o.row-e.row+1:0,u=0,c=t.length,C=Math.max(c,m);C>u;u++)if(c>u){var R;for(h=0,d=t[u].length;v-d>h;h++)t[u].push(t[u][h%d]);t[u].unshift(e.row+u,e.col,0),(R=U).spliceRow.apply(R,r(t[u]))}else{var O;t[u%c][0]=e.row+u,(O=U).spliceRow.apply(O,r(t[u%c]))}break;case"overwrite":default:g.row=e.row,g.col=e.col;var k={row:o&&e?o.row-e.row+1:1,col:o&&e?o.col-e.col+1:1},T=0,_=0,M=!0,H=void 0,A=function(e){var o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=t[e%t.length];return null!==o?n[o%n.length]:n},x=t.length,D=o?o.row-e.row+1:0;for(c=o?D:Math.max(x,D),u=0;c>u&&(!(o&&g.row>o.row&&D>x||!w.settings.allowInsertRow&&g.row>U.countRows()-1)&&g.row<w.settings.maxRows);u++){var L=u-T,N=A(L).length,I=o?o.col-e.col+1:0;if(d=o?I:Math.max(N,I),g.col=e.col,H=U.getCellMeta(g.row,g.col),"CopyPaste.paste"!==n&&"Autofill.autofill"!==n||!H.skipRowOnPaste){for(_=0,h=0;d>h&&(!(o&&g.col>o.col&&I>N||!w.settings.allowInsertColumn&&g.col>U.countCols()-1)&&g.col<w.settings.maxCols);h++)if(H=U.getCellMeta(g.row,g.col),"CopyPaste.paste"!==n&&"Autofill.fill"!==n||!H.skipColumnOnPaste)if(H.readOnly)g.col++;else{var j=h-_,W=A(L,j),B=U.getDataAtCell(g.row,g.col),F={row:L,col:j};if("Autofill.fill"===n){var V=U.runHooks("beforeAutofillInsidePopulate",F,s,t,a,{},k);V&&(W=(0,f.isUndefined)(V.value)?W:V.value)}if(null!==W&&"object"===(void 0===W?"undefined":l(W)))if(null===B||"object"!==(void 0===B?"undefined":l(B)))M=!1;else{var z=(0,b.duckSchema)(B[0]||B),Y=(0,b.duckSchema)(W[0]||W);(0,b.isObjectEquals)(z,Y)?W=(0,b.deepClone)(W):M=!1}else null!==B&&"object"===(void 0===B?"undefined":l(B))&&(M=!1);M&&p.push([g.row,g.col,W]),M=!0,g.col++}else _++,g.col++,d++;g.row++}else T++,g.row++,c++}U.setDataAtCell(p,null,null,n||"populateFromArray")}}},this.selection=j={inProgress:!1,selectedHeader:{cols:!1,rows:!1},setSelectedHeaders:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],o=arguments.length>2&&void 0!==arguments[2]&&arguments[2];U.selection.selectedHeader.rows=e,U.selection.selectedHeader.cols=t,U.selection.selectedHeader.corner=o},begin:function(){U.selection.inProgress=!0},finish:function(){var e=U.getSelected();U.runHooks("afterSelectionEnd",e[0],e[1],e[2],e[3]),U.runHooks("afterSelectionEndByProp",e[0],U.colToProp(e[1]),e[2],U.colToProp(e[3])),U.selection.inProgress=!1},isInProgress:function(){return U.selection.inProgress},setRangeStart:function(e,t){U.runHooks("beforeSetRangeStart",e),w.selRange=new L.CellRange(e,e,e),j.setRangeEnd(e,null,t)},setRangeStartOnly:function(e){U.runHooks("beforeSetRangeStartOnly",e),w.selRange=new L.CellRange(e,e,e)},setRangeEnd:function(e,t,o){if(null!==w.selRange){var n,r=!1,i=!0,s=U.view.wt.wtTable.getFirstVisibleRow(),l=U.view.wt.wtTable.getFirstVisibleColumn(),a={row:null,col:null};U.runHooks("beforeSetRangeEnd",e),U.selection.begin(),a.row=0>e.row?s:e.row,a.col=0>e.col?l:e.col,w.selRange.to=new L.CellCoords(a.row,a.col),w.settings.multiSelect||(w.selRange.from=e),U.view.wt.selections.current.clear(),n=U.getCellMeta(w.selRange.highlight.row,w.selRange.highlight.col).disableVisualSelection,"string"==typeof n&&(n=[n]),(!1===n||Array.isArray(n)&&-1===n.indexOf("current"))&&U.view.wt.selections.current.add(w.selRange.highlight),U.view.wt.selections.area.clear(),(!1===n||Array.isArray(n)&&-1===n.indexOf("area"))&&j.isMultiple()&&(U.view.wt.selections.area.add(w.selRange.from),U.view.wt.selections.area.add(w.selRange.to)),(w.settings.currentHeaderClassName||w.settings.currentRowClassName||w.settings.currentColClassName)&&(U.view.wt.selections.highlight.clear(),U.view.wt.selections.highlight.add(w.selRange.from),U.view.wt.selections.highlight.add(w.selRange.to));var u=(0,b.createObjectPropListener)("value");U.runHooks("afterSelection",w.selRange.from.row,w.selRange.from.col,w.selRange.to.row,w.selRange.to.col,u),U.runHooks("afterSelectionByProp",w.selRange.from.row,_.colToProp(w.selRange.from.col),w.selRange.to.row,_.colToProp(w.selRange.to.col),u),(0===w.selRange.from.row&&w.selRange.to.row===U.countRows()-1&&U.countRows()>1||0===w.selRange.from.col&&w.selRange.to.col===U.countCols()-1&&U.countCols()>1)&&(r=!0),(0>e.row||0>e.col)&&(i=!1),u.isTouched()&&(t=!u.value),!1!==t&&!r&&i&&U.view.scrollViewport(w.selRange.from&&!j.isMultiple()?w.selRange.from:e),j.selectedHeader.rows&&j.selectedHeader.cols?(0,c.addClass)(U.rootElement,["ht__selection--rows","ht__selection--columns"]):j.selectedHeader.rows?((0,c.removeClass)(U.rootElement,"ht__selection--columns"),(0,c.addClass)(U.rootElement,"ht__selection--rows")):j.selectedHeader.cols?((0,c.removeClass)(U.rootElement,"ht__selection--rows"),(0,c.addClass)(U.rootElement,"ht__selection--columns")):(0,c.removeClass)(U.rootElement,["ht__selection--rows","ht__selection--columns"]),j.refreshBorders(null,o)}},refreshBorders:function(e,t){t||V.destroyEditor(e),U.view.render(),j.isSelected()&&!t&&V.prepareEditor()},isMultiple:function(){var e=!(w.selRange.to.col===w.selRange.from.col&&w.selRange.to.row===w.selRange.from.row),t=U.runHooks("afterIsMultipleSelection",e);if(e)return t},transformStart:function(e,t,o,n){var r,i,s,l,a=new L.CellCoords(e,t),u=0,c=0;U.runHooks("modifyTransformStart",a),r=U.countRows(),i=U.countCols(),l=U.getSettings().fixedRowsBottom,w.selRange.highlight.row+e>r-1?o&&w.settings.minSpareRows>0&&(!l||r-l-1>w.selRange.highlight.row)?(U.alter("insert_row",r),r=U.countRows()):w.settings.autoWrapCol&&(a.row=1-r,a.col=w.selRange.highlight.col+a.col==i-1?1-i:1):w.settings.autoWrapCol&&0>w.selRange.highlight.row+a.row&&w.selRange.highlight.col+a.col>=0&&(a.row=r-1,a.col=w.selRange.highlight.col+a.col==0?i-1:-1),w.selRange.highlight.col+a.col>i-1?o&&w.settings.minSpareCols>0?(U.alter("insert_col",i),i=U.countCols()):w.settings.autoWrapRow&&(a.row=w.selRange.highlight.row+a.row==r-1?1-r:1,a.col=1-i):w.settings.autoWrapRow&&0>w.selRange.highlight.col+a.col&&w.selRange.highlight.row+a.row>=0&&(a.row=w.selRange.highlight.row+a.row==0?r-1:-1,a.col=i-1),s=new L.CellCoords(w.selRange.highlight.row+a.row,w.selRange.highlight.col+a.col),0>s.row?(u=-1,s.row=0):s.row>0&&s.row>=r&&(u=1,s.row=r-1),0>s.col?(c=-1,s.col=0):s.col>0&&s.col>=i&&(c=1,s.col=i-1),U.runHooks("afterModifyTransformStart",s,u,c),j.setRangeStart(s,n)},transformEnd:function(e,t){var o,n,r,i=new L.CellCoords(e,t),s=0,l=0;U.runHooks("modifyTransformEnd",i),o=U.countRows(),n=U.countCols(),r=new L.CellCoords(w.selRange.to.row+i.row,w.selRange.to.col+i.col),0>r.row?(s=-1,r.row=0):r.row>0&&r.row>=o&&(s=1,r.row=o-1),0>r.col?(l=-1,r.col=0):r.col>0&&r.col>=n&&(l=1,r.col=n-1),U.runHooks("afterModifyTransformEnd",r,s,l),j.setRangeEnd(r,!0)},isSelected:function(){return null!==w.selRange},inInSelection:function(e){return!!j.isSelected()&&w.selRange.includes(e)},deselect:function(){j.isSelected()&&(U.selection.inProgress=!1,w.selRange=null,U.view.wt.selections.current.clear(),U.view.wt.selections.area.clear(),(w.settings.currentHeaderClassName||w.settings.currentRowClassName||w.settings.currentColClassName)&&U.view.wt.selections.highlight.clear(),V.destroyEditor(),j.refreshBorders(),(0,c.removeClass)(U.rootElement,["ht__selection--rows","ht__selection--columns"]),U.runHooks("afterDeselect"))},selectAll:function(){w.settings.multiSelect&&(j.setSelectedHeaders(!0,!0,!0),j.setRangeStart(new L.CellCoords(0,0)),j.setRangeEnd(new L.CellCoords(U.countRows()-1,U.countCols()-1),!1))},empty:function(){if(j.isSelected()){var e,t,o=w.selRange.getTopLeftCorner(),n=w.selRange.getBottomRightCorner(),r=[];for(e=o.row;n.row>=e;e++)for(t=o.col;n.col>=t;t++)U.getCellMeta(e,t).readOnly||r.push([e,t,""]);U.setDataAtCell(r)}}},this.init=function(){H.setData(w.settings.data),U.runHooks("beforeInit"),(0,p.isMobileBrowser)()&&(0,c.addClass)(U.rootElement,"mobile"),this.updateSettings(w.settings,!0),this.view=new M.default(this),V=new y.default(U,w,j,_),this.forceFullRender=!0,U.runHooks("init"),this.view.render(),"object"===l(w.firstRun)&&(U.runHooks("afterChange",w.firstRun[0],w.firstRun[1]),w.firstRun=!1),U.runHooks("afterInit")},this.validateCell=function(e,t,o,n){function r(e){var n=t.visualCol,r=t.visualRow,i=U.getCell(r,n,!0);i&&"TH"!=i.nodeName&&U.view.wt.wtSettings.settings.cellRenderer(r,n,i),o(e)}var i=U.getCellValidator(t);(0,f.isRegExp)(i)&&(i=function(e){return function(t,o){o(e.test(t))}}(i)),(0,d.isFunction)(i)?(e=U.runHooks("beforeValidate",e,t.visualRow,t.prop,n),U._registerTimeout(setTimeout(function(){i.call(t,e,function(o){o=U.runHooks("afterValidate",o,e,t.visualRow,t.prop,n),t.valid=o,r(o),U.runHooks("postAfterValidate",o,e,t.visualRow,t.prop,n)})},0))):U._registerTimeout(setTimeout(function(){t.valid=!0,r(t.valid)},0))},this.setDataAtCell=function(e,t,o,r){var s,u,c,h=a(e,t,o),d=[];for(s=0,u=h.length;u>s;s++){if("object"!==l(h[s]))throw Error("Method `setDataAtCell` accepts row number or changes array of arrays as its first parameter");if("number"!=typeof h[s][1])throw Error("Method `setDataAtCell` accepts row and column number as its parameters. If you want to use object property name, use method `setDataAtRowProp`");c=_.colToProp(h[s][1]),d.push([h[s][0],c,H.getAtCell(G.toPhysicalRow(h[s][0]),h[s][1]),h[s][2]])}r||"object"!==(void 0===e?"undefined":l(e))||(r=t),U.runHooks("afterSetDataAtCell",d,r),n(d,r,function(){i(d,r)})},this.setDataAtRowProp=function(e,t,o,r){var s,u,c=a(e,t,o),h=[];for(s=0,u=c.length;u>s;s++)h.push([c[s][0],c[s][1],H.getAtCell(G.toPhysicalRow(c[s][0]),c[s][1]),c[s][2]]);r||"object"!==(void 0===e?"undefined":l(e))||(r=t),U.runHooks("afterSetDataAtRowProp",h,r),n(h,r,function(){i(h,r)})},this.listen=function(){var e=!document.activeElement||document.activeElement&&void 0===document.activeElement.nodeName;document.activeElement&&document.activeElement!==document.body&&!e?document.activeElement.blur():e&&document.body.focus(),U&&!U.isListening()&&(F=U.guid,U.runHooks("afterListen"))},this.unlisten=function(){this.isListening()&&(F=null,U.runHooks("afterUnlisten"))},this.isListening=function(){return F===U.guid},this.destroyEditor=function(e){j.refreshBorders(e)},this.populateFromArray=function(e,t,o,n,r,i,s,a,u){var c;if("object"!==(void 0===o?"undefined":l(o))||"object"!==l(o[0]))throw Error("populateFromArray parameter `input` must be an array of arrays");return c="number"==typeof n?new L.CellCoords(n,r):null,N.populateFromArray(new L.CellCoords(e,t),o,c,i,s,a,u)},this.spliceCol=function(e,t,o){var n;return(n=_).spliceCol.apply(n,arguments)},this.spliceRow=function(e,t,o){var n;return(n=_).spliceRow.apply(n,arguments)},this.getSelected=function(){if(j.isSelected())return[w.selRange.from.row,w.selRange.from.col,w.selRange.to.row,w.selRange.to.col]},this.getSelectedRange=function(){if(j.isSelected())return w.selRange},this.render=function(){U.view&&(U.renderCall=!0,U.forceFullRender=!0,j.refreshBorders(null,!0))},this.loadData=function(e){if(U.dataType=Array.isArray(w.settings.dataSchema)?"array":(0,d.isFunction)(w.settings.dataSchema)?"function":"object",_&&_.destroy(),_=new v.default(U,w,Y),"object"===(void 0===e?"undefined":l(e))&&null!==e)e.push&&e.splice||(e=[e]);else{if(null!==e)throw Error("loadData only accepts array of objects or array of arrays ("+(void 0===e?"undefined":l(e))+" given)");e=[];var t,o=0,n=0,r=_.getSchema();for(o=0,n=w.settings.startRows;n>o;o++)if("object"!==U.dataType&&"function"!==U.dataType||!w.settings.dataSchema)if("array"===U.dataType)t=(0,b.deepClone)(r[0]),e.push(t);else{t=[];for(var i=0,s=w.settings.startCols;s>i;i++)t.push(null);e.push(t)}else t=(0,b.deepClone)(r),e.push(t)}w.isPopulated=!1,Y.prototype.data=e,Array.isArray(e[0])&&(U.dataType="array"),_.dataSource=e,H.data=e,H.dataType=U.dataType,H.colToProp=_.colToProp.bind(_),H.propToCol=_.propToCol.bind(_),function(){w.cellSettings.length=0}(),N.adjustRowsAndCols(),U.runHooks("afterLoadData",w.firstRun),w.firstRun?w.firstRun=[null,"loadData"]:(U.runHooks("afterChange",null,"loadData"),U.render()),w.isPopulated=!0},this.getData=function(e,t,o,n){return(0,f.isUndefined)(e)?_.getAll():_.getRange(new L.CellCoords(e,t),new L.CellCoords(o,n),_.DESTINATION_RENDERER)},this.getCopyableText=function(e,t,o,n){return _.getCopyableText(new L.CellCoords(e,t),new L.CellCoords(o,n))},this.getCopyableData=function(e,t){return _.getCopyable(e,_.colToProp(t))},this.getSchema=function(){return _.getSchema()},this.updateSettings=function(e,t){var o=!1,n=void 0,r=void 0,i=void 0;if((0,f.isDefined)(e.rows))throw Error('"rows" setting is no longer supported. do you mean startRows, minRows or maxRows?');if((0,f.isDefined)(e.cols))throw Error('"cols" setting is no longer supported. do you mean startCols, minCols or maxCols?');for(n in e)"data"!==n&&(I.default.getSingleton().getRegistered().indexOf(n)>-1?((0,d.isFunction)(e[n])||Array.isArray(e[n]))&&(e[n].initialHook=!0,U.addHook(n,e[n])):!t&&(0,b.hasOwnProperty)(e,n)&&(Y.prototype[n]=e[n]));void 0===e.data&&void 0===w.settings.data?U.loadData(null):void 0!==e.data?U.loadData(e.data):void 0!==e.columns&&_.createMap(),i=U.countCols();var s=e.columns||Y.prototype.columns;if(s&&(0,d.isFunction)(s)&&(i=U.countSourceCols(),o=!0),void 0===e.cell&&void 0===e.cells&&void 0===e.columns||(w.cellSettings.length=0),i>0){var l=void 0,a=void 0;for(n=0,r=0;i>n;n++)o&&!s(n)||(w.columnSettings[r]=(0,h.columnFactory)(Y,w.columnsSettingConflicts),l=w.columnSettings[r].prototype,s&&(a=o?s(n):s[r])&&((0,b.extend)(l,a),(0,b.extend)(l,g(a))),r++)}if((0,f.isDefined)(e.cell))for(var u in e.cell)if((0,b.hasOwnProperty)(e.cell,u)){var p=e.cell[u];U.setCellMetaObject(p.row,p.col,p)}U.runHooks("afterCellMetaReset"),(0,f.isDefined)(e.className)&&(Y.prototype.className&&(0,c.removeClass)(U.rootElement,Y.prototype.className),e.className&&(0,c.addClass)(U.rootElement,e.className));var v=U.rootElement.style.height;""!==v&&(v=parseInt(U.rootElement.style.height,10));var m=e.height;if((0,d.isFunction)(m)&&(m=m()),t){U.rootElement.getAttribute("style")&&U.rootElement.setAttribute("data-initialstyle",U.rootElement.getAttribute("style"))}if(null===m){var y=U.rootElement.getAttribute("data-initialstyle");y&&(y.indexOf("height")>-1||y.indexOf("overflow")>-1)?U.rootElement.setAttribute("style",y):(U.rootElement.style.height="",U.rootElement.style.overflow="")}else void 0!==m&&(U.rootElement.style.height=m+"px",U.rootElement.style.overflow="hidden");if(void 0!==e.width){var C=e.width;(0,d.isFunction)(C)&&(C=C()),U.rootElement.style.width=C+"px"}t||(_.clearLengthCache(),U.view&&U.view.wt.wtViewport.resetHasOversizedColumnHeadersMarked(),U.runHooks("afterUpdateSettings",e)),N.adjustRowsAndCols(),U.view&&!w.firstRun&&(U.forceFullRender=!0,j.refreshBorders(null,!0)),t||!U.view||""!==v&&""!==m&&void 0!==m||v===m||U.view.wt.wtOverlays.updateMainScrollableElements()},this.getValue=function(){var e=U.getSelected();if(Y.prototype.getValue){if((0,d.isFunction)(Y.prototype.getValue))return Y.prototype.getValue.call(U);if(e)return U.getData()[e[0]][Y.prototype.getValue]}else if(e)return U.getDataAtCell(e[0],e[1])},this.getSettings=function(){return w.settings},this.clear=function(){j.selectAll(),j.empty()},this.alter=function(e,t,o,n,r){N.alter(e,t,o,n,r)},this.getCell=function(e,t,o){return U.view.getCellAtCoords(new L.CellCoords(e,t),o)},this.getCoords=function(e){return this.view.wt.wtTable.getCoords.call(this.view.wt.wtTable,e)},this.colToProp=function(e){return _.colToProp(e)},this.propToCol=function(e){return _.propToCol(e)},this.toVisualRow=function(e){return G.toVisualRow(e)},this.toVisualColumn=function(e){return G.toVisualColumn(e)},this.toPhysicalRow=function(e){return G.toPhysicalRow(e)},this.toPhysicalColumn=function(e){return G.toPhysicalColumn(e)},this.getDataAtCell=function(e,t){return _.get(e,_.colToProp(t))},this.getDataAtRowProp=function(e,t){return _.get(e,t)},this.getDataAtCol=function(e){var t=[];return t.concat.apply(t,r(_.getRange(new L.CellCoords(0,e),new L.CellCoords(w.settings.data.length-1,e),_.DESTINATION_RENDERER)))},this.getDataAtProp=function(e){var t,o=[];return t=_.getRange(new L.CellCoords(0,_.propToCol(e)),new L.CellCoords(w.settings.data.length-1,_.propToCol(e)),_.DESTINATION_RENDERER),o.concat.apply(o,r(t))},this.getSourceData=function(e,t,o,n){return void 0===e?H.getData():H.getByRange(new L.CellCoords(e,t),new L.CellCoords(o,n))},this.getSourceDataArray=function(e,t,o,n){return void 0===e?H.getData(!0):H.getByRange(new L.CellCoords(e,t),new L.CellCoords(o,n),!0)},this.getSourceDataAtCol=function(e){return H.getAtColumn(e)},this.getSourceDataAtRow=function(e){return H.getAtRow(e)},this.getSourceDataAtCell=function(e,t){return H.getAtCell(e,t)},this.getDataAtRow=function(e){return _.getRange(new L.CellCoords(e,0),new L.CellCoords(e,this.countCols()-1),_.DESTINATION_RENDERER)[0]||[]},this.getDataType=function(e,t,o,n){var r=this,i=null,s=null;void 0===e&&(e=0,o=this.countRows(),t=0,n=this.countCols()),void 0===o&&(o=e),void 0===n&&(n=t);var l="mixed";return(0,T.rangeEach)(Math.min(e,o),Math.max(e,o),function(e){var o=!0;return(0,T.rangeEach)(Math.min(t,n),Math.max(t,n),function(t){var n=r.getCellMeta(e,t);return s=n.type,i?o=i===s:i=s,o}),l=o?s:"mixed",o}),l},this.removeCellMeta=function(e,t,o){var n=G.toPhysical(e,t),r=s(n,2),i=r[0],l=r[1],a=w.cellSettings[i][l][o];!1!==U.runHooks("beforeRemoveCellMeta",e,t,o,a)&&(delete w.cellSettings[i][l][o],U.runHooks("afterRemoveCellMeta",e,t,o,a)),a=null},this.spliceCellsMeta=function(e,t){for(var o,n=arguments.length,r=Array(n>2?n-2:0),i=2;n>i;i++)r[i-2]=arguments[i];(o=w.cellSettings).splice.apply(o,[e,t].concat(r))},this.setCellMetaObject=function(e,t,o){if("object"===(void 0===o?"undefined":l(o)))for(var n in o)if((0,b.hasOwnProperty)(o,n)){var r=o[n];this.setCellMeta(e,t,n,r)}},this.setCellMeta=function(e,t,o,n){var r=G.toPhysical(e,t),i=s(r,2),l=i[0],a=i[1];w.columnSettings[a]||(w.columnSettings[a]=(0,h.columnFactory)(Y,w.columnsSettingConflicts)),w.cellSettings[l]||(w.cellSettings[l]=[]),w.cellSettings[l][a]||(w.cellSettings[l][a]=new w.columnSettings[a]),w.cellSettings[l][a][o]=n,U.runHooks("afterSetCellMeta",e,t,o,n)},this.getCellsMeta=function(){return(0,S.arrayFlatten)(w.cellSettings)},this.getCellMeta=function(e,t){var o=_.colToProp(t),n=void 0,r=G.toPhysical(e,t),i=s(r,2),l=i[0],a=i[1];if(w.columnSettings[a]||(w.columnSettings[a]=(0,h.columnFactory)(Y,w.columnsSettingConflicts)),w.cellSettings[l]||(w.cellSettings[l]=[]),w.cellSettings[l][a]||(w.cellSettings[l][a]=new w.columnSettings[a]),n=w.cellSettings[l][a],n.row=l,n.col=a,n.visualRow=e,n.visualCol=t,n.prop=o,n.instance=U,U.runHooks("beforeGetCellMeta",e,t,n),(0,b.extend)(n,g(n)),n.cells){var u=n.cells.call(n,l,a,o);u&&((0,b.extend)(n,u),(0,b.extend)(n,g(u)))}return U.runHooks("afterGetCellMeta",e,t,n),n},this.getCellMetaAtRow=function(e){return w.cellSettings[e]},this.isColumnModificationAllowed=function(){return!("object"===U.dataType||U.getSettings().columns)};var X=(0,P.cellMethodLookupFactory)("renderer");this.getCellRenderer=function(e,t){return(0,R.getRenderer)(X.call(this,e,t))},this.getCellEditor=(0,P.cellMethodLookupFactory)("editor");var q=(0,P.cellMethodLookupFactory)("validator");this.getCellValidator=function(e,t){var o=q.call(this,e,t);return"string"==typeof o&&(o=(0,O.getValidator)(o)),o},this.validateCells=function(e){var t=new o;e&&(t.onQueueEmpty=e);for(var n=U.countRows()-1;n>=0;){for(var r=U.countCols()-1;r>=0;)t.addValidatorToQueue(),U.validateCell(U.getDataAtCell(n,r),U.getCellMeta(n,r),function(e){if("boolean"!=typeof e)throw Error("Validation error: result is not boolean");!1===e&&(t.valid=!1),t.removeValidatorFormQueue()},"validateCells"),r--;n--}t.checkIfQueueIsEmpty()},this.getRowHeader=function(e){var t=w.settings.rowHeaders;return void 0!==e&&(e=U.runHooks("modifyRowHeader",e)),void 0===e?(t=[],(0,T.rangeEach)(U.countRows()-1,function(e){t.push(U.getRowHeader(e))})):Array.isArray(t)&&void 0!==t[e]?t=t[e]:(0,d.isFunction)(t)?t=t(e):t&&"string"!=typeof t&&"number"!=typeof t&&(t=e+1),t},this.hasRowHeaders=function(){return!!w.settings.rowHeaders},this.hasColHeaders=function(){if(void 0!==w.settings.colHeaders&&null!==w.settings.colHeaders)return!!w.settings.colHeaders;for(var e=0,t=U.countCols();t>e;e++)if(U.getColHeader(e))return!0;return!1},this.getColHeader=function(e){var t=w.settings.columns&&(0,d.isFunction)(w.settings.columns),o=w.settings.colHeaders;if(void 0===(e=U.runHooks("modifyColHeader",e))){for(var n=[],r=t?U.countSourceCols():U.countCols(),i=0;r>i;i++)n.push(U.getColHeader(i));o=n}else{var s=e;e=U.runHooks("modifyCol",e);var l=function(e){for(var t=[],o=U.countSourceCols(),n=0;o>n;n++)(0,d.isFunction)(U.getSettings().columns)&&U.getSettings().columns(n)&&t.push(n);return t[e]}(e);w.settings.columns&&(0,d.isFunction)(w.settings.columns)&&w.settings.columns(l)&&w.settings.columns(l).title?o=w.settings.columns(l).title:w.settings.columns&&w.settings.columns[e]&&w.settings.columns[e].title?o=w.settings.columns[e].title:Array.isArray(w.settings.colHeaders)&&void 0!==w.settings.colHeaders[e]?o=w.settings.colHeaders[e]:(0,d.isFunction)(w.settings.colHeaders)?o=w.settings.colHeaders(e):w.settings.colHeaders&&"string"!=typeof w.settings.colHeaders&&"number"!=typeof w.settings.colHeaders&&(o=(0,P.spreadsheetColumnLabel)(s))}return o},this._getColWidthFromSettings=function(e){var t=U.getCellMeta(0,e),o=t.width;if(void 0!==o&&o!==w.settings.width||(o=t.colWidths),void 0!==o&&null!==o){switch(void 0===o?"undefined":l(o)){case"object":o=o[e];break;case"function":o=o(e)}"string"==typeof o&&(o=parseInt(o,10))}return o},this.getColWidth=function(e){var t=U._getColWidthFromSettings(e);return t=U.runHooks("modifyColWidth",t,e),void 0===t&&(t=L.ViewportColumnsCalculator.DEFAULT_WIDTH),t},this._getRowHeightFromSettings=function(e){var t=w.settings.rowHeights;if(void 0!==t&&null!==t){switch(void 0===t?"undefined":l(t)){case"object":t=t[e];break;case"function":t=t(e)}"string"==typeof t&&(t=parseInt(t,10))}return t},this.getRowHeight=function(e){var t=U._getRowHeightFromSettings(e);return t=U.runHooks("modifyRowHeight",t,e)},this.countSourceRows=function(){return U.runHooks("modifySourceLength")||(U.getSourceData()?U.getSourceData().length:0)},this.countSourceCols=function(){var e=U.getSourceData()&&U.getSourceData()[0]?U.getSourceData()[0]:[];return(0,b.isObject)(e)?(0,b.deepObjectSize)(e):e.length||0},this.countRows=function(){return _.getLength()},this.countCols=function(){var e=this.getSettings().maxCols,t=!1,o=0;if("array"===U.dataType&&(t=w.settings.data&&w.settings.data[0]&&w.settings.data[0].length),t&&(o=w.settings.data[0].length),w.settings.columns){if((0,d.isFunction)(w.settings.columns))if("array"===U.dataType){for(var n=0,r=0;o>r;r++)w.settings.columns(r)&&n++;o=n}else"object"!==U.dataType&&"function"!==U.dataType||(o=_.colToPropCache.length);else o=w.settings.columns.length}else"object"!==U.dataType&&"function"!==U.dataType||(o=_.colToPropCache.length);return Math.min(e,o)},this.rowOffset=function(){return U.view.wt.wtTable.getFirstRenderedRow()},this.colOffset=function(){return U.view.wt.wtTable.getFirstRenderedColumn()},this.countRenderedRows=function(){return U.view.wt.drawn?U.view.wt.wtTable.getRenderedRowsCount():-1},this.countVisibleRows=function(){return U.view.wt.drawn?U.view.wt.wtTable.getVisibleRowsCount():-1},this.countRenderedCols=function(){return U.view.wt.drawn?U.view.wt.wtTable.getRenderedColumnsCount():-1},this.countVisibleCols=function(){return U.view.wt.drawn?U.view.wt.wtTable.getVisibleColumnsCount():-1},this.countEmptyRows=function(e){for(var t,o=U.countRows()-1,n=0;o>=0;){if(t=U.runHooks("modifyRow",o),U.isEmptyRow(t))n++;else if(e)break;o--}return n},this.countEmptyCols=function(e){if(1>U.countRows())return 0;for(var t=U.countCols()-1,o=0;t>=0;){if(U.isEmptyCol(t))o++;else if(e)break;t--}return o},this.isEmptyRow=function(e){return w.settings.isEmptyRow.call(U,e)},this.isEmptyCol=function(e){return w.settings.isEmptyCol.call(U,e)},this.selectCell=function(e,t,o,n,r,i){var s;if(i=(0,f.isUndefined)(i)||!0===i,"number"!=typeof e||0>e||e>=U.countRows())return!1;if("number"!=typeof t||0>t||t>=U.countCols())return!1;if((0,f.isDefined)(o)){if("number"!=typeof o||0>o||o>=U.countRows())return!1;if("number"!=typeof n||0>n||n>=U.countCols())return!1}return s=new L.CellCoords(e,t),w.selRange=new L.CellRange(s,s,s),i&&U.listen(),(0,f.isUndefined)(o)?j.setRangeEnd(w.selRange.from,r):j.setRangeEnd(new L.CellCoords(o,n),r),U.selection.finish(),!0},this.selectCellByProp=function(e,t,o,n,r){var i;return arguments[1]=_.propToCol(arguments[1]),(0,f.isDefined)(arguments[3])&&(arguments[3]=_.propToCol(arguments[3])),(i=U).selectCell.apply(i,arguments)},this.deselectCell=function(){j.deselect()},this.scrollViewportTo=function(e,t){var o=arguments.length>2&&void 0!==arguments[2]&&arguments[2],n=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(void 0!==e&&(0>e||e>=U.countRows()))return!1;if(void 0!==t&&(0>t||t>=U.countCols()))return!1;var r=!1;return void 0!==e&&void 0!==t&&(U.view.wt.wtOverlays.topOverlay.scrollTo(e,o),U.view.wt.wtOverlays.leftOverlay.scrollTo(t,n),r=!0),"number"==typeof e&&"number"!=typeof t&&(U.view.wt.wtOverlays.topOverlay.scrollTo(e,o),r=!0),"number"==typeof t&&"number"!=typeof e&&(U.view.wt.wtOverlays.leftOverlay.scrollTo(t,n),r=!0),r},this.destroy=function(){U._clearTimeouts(),U.view&&U.view.destroy(),H&&H.destroy(),H=null;(0,c.empty)(U.rootElement),K.destroy(),U.runHooks("afterDestroy"),I.default.getSingleton().destroy(U);for(var e in U)(0,b.hasOwnProperty)(U,e)&&((0,d.isFunction)(U[e])?U[e]=m:"guid"!==e&&(U[e]=null));_&&_.destroy(),_=null,w=null,N=null,j=null,V=null,U=null,Y=null},this.getActiveEditor=function(){return V.getActiveEditor()},this.getPlugin=function(e){return(0,E.getPlugin)(this,e)},this.getInstance=function(){return U},this.addHook=function(e,t){I.default.getSingleton().add(e,t,U)},this.hasHook=function(e){return I.default.getSingleton().has(e,U)},this.addHookOnce=function(e,t){I.default.getSingleton().once(e,t,U)},this.removeHook=function(e,t){I.default.getSingleton().remove(e,t,U)},this.runHooks=function(e,t,o,n,r,i,s){return I.default.getSingleton().run(U,e,t,o,n,r,i,s)},this.timeouts=[],this._registerTimeout=function(e){this.timeouts.push(e)},this._clearTimeouts=function(){for(var e=0,t=this.timeouts.length;t>e;e++)clearTimeout(this.timeouts[e])},I.default.getSingleton().run(U,"construct")}t.__esModule=!0;var s=function(){function e(e,t){var o=[],n=!0,r=!1,i=void 0;try{for(var s,l=e[Symbol.iterator]();!(n=(s=l.next()).done)&&(o.push(s.value),!t||o.length!==t);n=!0);}catch(e){r=!0,i=e}finally{try{!n&&l.return&&l.return()}finally{if(r)throw i}}return o}return function(t,o){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,o);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),l="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.default=i;var a=o(80),u=n(a),c=o(0),h=o(83),d=o(35),f=o(22),p=o(26),g=o(240),v=n(g),m=o(243),y=n(m),w=o(4),C=n(w),b=o(1),S=o(2),E=o(5),R=o(8),O=o(27),k=o(32),T=o(6),_=o(244),M=n(_),H=o(245),A=n(H),P=o(84),x=o(172),D=o(173),L=o(12),N=o(7),I=n(N),j=o(174),W=n(j),B=o(81),F=null},function(e,t,o){"use strict";function n(e,t){function o(){}(0,r.inherit)(o,e);for(var n=0,i=t.length;i>n;n++)o.prototype[t[n]]=void 0;return o}t.__esModule=!0,t.columnFactory=n;var r=o(1)},function(e,t,o){"use strict";function n(e){for(var t=e+1,o="",n=void 0;t>0;)n=(t-1)%f,o=String.fromCharCode(65+n)+o,t=parseInt((t-n)/f,10);return o}function r(e){var t=0;if(e)for(var o=0,n=e.length-1;e.length>o;o+=1,n-=1)t+=Math.pow(f,n)*(d.indexOf(e[o])+1);return--t}function i(){var e,t,o=arguments.length>0&&void 0!==arguments[0]?arguments[0]:100,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:4,i=[];for(e=0;o>e;e++){var s=[];for(t=0;r>t;t++)s.push(n(t)+(e+1));i.push(s)}return i}function s(){var e,t,o=arguments.length>0&&void 0!==arguments[0]?arguments[0]:100,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:4,i=[];for(e=0;o>e;e++){var s={};for(t=0;r>t;t++)s["prop"+t]=n(t)+(e+1);i.push(s)}return i}function l(e,t){for(var o=[],n=void 0,r=0;e>r;r++){n=[];for(var i=0;t>i;i++)n.push("");o.push(n)}return o}function a(e){var t,o,n,r,i=[],s=0;for(t=0,o=e.length;o>t;t++)for(n=0,r=e[t].length;r>n;n++)n==s&&(i.push([]),s++),i[n].push(e[t][n]);return i}function u(e,t){return t=void 0===t||t,function(o,n){return function o(n){if(n){if((0,h.hasOwnProperty)(n,e)&&void 0!==n[e])return n[e];if((0,h.hasOwnProperty)(n,"type")&&n.type){var r;if("string"!=typeof n.type)throw Error("Cell type must be a string ");if(r=(0,c.getCellType)(n.type),(0,h.hasOwnProperty)(r,e))return r[e];if(t)return}return o(Object.getPrototypeOf(n))}}("number"==typeof o?this.getCellMeta(o,n):o)}}t.__esModule=!0,t.spreadsheetColumnLabel=n,t.spreadsheetColumnIndex=r,t.createSpreadsheetData=i,t.createSpreadsheetObjectData=s,t.createEmptySpreadsheetData=l,t.translateRowsToColumns=a,t.cellMethodLookupFactory=u;var c=o(81),h=o(1),d="ABCDEFGHIJKLMNOPQRSTUVWXYZ",f=d.length},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=o(0),s=o(2);t.default=function(){function e(t){n(this,e),this.hot=t,this.container=null,this.injected=!1,this.rows=[],this.columns=[],this.samples=null,this.settings={useHeaders:!0}}return r(e,[{key:"addRow",value:function(e,t){if(this.columns.length)throw Error("Doesn't support multi-dimensional table");this.rows.length||(this.container=this.createContainer(this.hot.rootElement.className));var o={row:e};this.rows.push(o),this.samples=t,this.table=this.createTable(this.hot.table.className),this.table.colGroup.appendChild(this.createColGroupsCol()),this.table.tr.appendChild(this.createRow(e)),this.container.container.appendChild(this.table.fragment),o.table=this.table.table}},{key:"addColumnHeadersRow",value:function(e){if(null!=this.hot.getColHeader(0)){var t={row:-1};this.rows.push(t),this.container=this.createContainer(this.hot.rootElement.className),this.samples=e,this.table=this.createTable(this.hot.table.className),this.table.colGroup.appendChild(this.createColGroupsCol()),this.table.tHead.appendChild(this.createColumnHeadersRow()),this.container.container.appendChild(this.table.fragment),t.table=this.table.table}}},{key:"addColumn",value:function(e,t){if(this.rows.length)throw Error("Doesn't support multi-dimensional table");this.columns.length||(this.container=this.createContainer(this.hot.rootElement.className));var o={col:e};this.columns.push(o),this.samples=t,this.table=this.createTable(this.hot.table.className),this.getSetting("useHeaders")&&null!==this.hot.getColHeader(e)&&this.hot.view.appendColHeader(e,this.table.th),this.table.tBody.appendChild(this.createCol(e)),this.container.container.appendChild(this.table.fragment),o.table=this.table.table}},{key:"getHeights",value:function(e){this.injected||this.injectTable(),(0,s.arrayEach)(this.rows,function(t){e(t.row,(0,i.outerHeight)(t.table)-1)})}},{key:"getWidths",value:function(e){this.injected||this.injectTable(),(0,s.arrayEach)(this.columns,function(t){e(t.col,(0,i.outerWidth)(t.table))})}},{key:"setSettings",value:function(e){this.settings=e}},{key:"setSetting",value:function(e,t){this.settings||(this.settings={}),this.settings[e]=t}},{key:"getSettings",value:function(){return this.settings}},{key:"getSetting",value:function(e){return this.settings?this.settings[e]:null}},{key:"createColGroupsCol",value:function(){var e=this,t=document,o=t.createDocumentFragment();return this.hot.hasRowHeaders()&&o.appendChild(this.createColElement(-1)),this.samples.forEach(function(t){(0,s.arrayEach)(t.strings,function(t){o.appendChild(e.createColElement(t.col))})}),o}},{key:"createRow",value:function(e){var t=this,o=document,n=o.createDocumentFragment(),r=o.createElement("th");return this.hot.hasRowHeaders()&&(this.hot.view.appendRowHeader(e,r),n.appendChild(r)),this.samples.forEach(function(r){(0,s.arrayEach)(r.strings,function(r){var i=r.col,s=t.hot.getCellMeta(e,i);s.col=i,s.row=e;var l=t.hot.getCellRenderer(s),a=o.createElement("td");l(t.hot,a,e,i,t.hot.colToProp(i),r.value,s),n.appendChild(a)})}),n}},{key:"createColumnHeadersRow",value:function(){var e=this,t=document,o=t.createDocumentFragment();if(this.hot.hasRowHeaders()){var n=t.createElement("th");this.hot.view.appendColHeader(-1,n),o.appendChild(n)}return this.samples.forEach(function(n){(0,s.arrayEach)(n.strings,function(n){var r=n.col,i=t.createElement("th");e.hot.view.appendColHeader(r,i),o.appendChild(i)})}),o}},{key:"createCol",value:function(e){var t=this,o=document,n=o.createDocumentFragment();return this.samples.forEach(function(r){(0,s.arrayEach)(r.strings,function(r){var i=r.row,s=t.hot.getCellMeta(i,e);s.col=e,s.row=i;var l=t.hot.getCellRenderer(s),a=o.createElement("td"),u=o.createElement("tr");l(t.hot,a,i,e,t.hot.colToProp(e),r.value,s),u.appendChild(a),n.appendChild(u)})}),n}},{key:"clean",value:function(){this.rows.length=0,this.rows[-1]=void 0,this.columns.length=0,this.samples&&this.samples.clear(),this.samples=null,this.removeTable()}},{key:"injectTable",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;this.injected||((e||this.hot.rootElement).appendChild(this.container.fragment),this.injected=!0)}},{key:"removeTable",value:function(){this.injected&&this.container.container.parentNode&&(this.container.container.parentNode.removeChild(this.container.container),this.container=null,this.injected=!1)}},{key:"createColElement",value:function(e){var t=document,o=t.createElement("col");return o.style.width=this.hot.view.wt.wtTable.getStretchedColumnWidth(e)+"px",o}},{key:"createTable",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=document,o=t.createDocumentFragment(),n=t.createElement("table"),r=t.createElement("thead"),s=t.createElement("tbody"),l=t.createElement("colgroup"),a=t.createElement("tr"),u=t.createElement("th");return this.isVertical()&&n.appendChild(l),this.isHorizontal()&&(a.appendChild(u),r.appendChild(a),n.style.tableLayout="auto",n.style.width="auto"),n.appendChild(r),this.isVertical()&&s.appendChild(a),n.appendChild(s),(0,i.addClass)(n,e),o.appendChild(n),{fragment:o,table:n,tHead:r,tBody:s,colGroup:l,tr:a,th:u}}},{key:"createContainer",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=document,o=t.createDocumentFragment(),n=t.createElement("div");return e="htGhostTable htAutoSize "+e.trim(),(0,i.addClass)(n,e),o.appendChild(n),{fragment:o,container:n}}},{key:"isVertical",value:function(){return!(!this.rows.length||this.columns.length)}},{key:"isHorizontal",value:function(){return!(!this.columns.length||this.rows.length)}}]),e}()},function(e,t,o){"use strict";function n(){return{name:r}}t.__esModule=!0,t.default=n;var r=t.KEY="---------"},function(e,t,o){"use strict";t.__esModule=!0;var n=o(2),r=o(1),i={_localHooks:Object.create(null),addLocalHook:function(e,t){this._localHooks[e]||(this._localHooks[e]=[]),this._localHooks[e].push(t)},runLocalHooks:function(e){for(var t=this,o=arguments.length,r=Array(o>1?o-1:0),i=1;o>i;i++)r[i-1]=arguments[i];this._localHooks[e]&&(0,n.arrayEach)(this._localHooks[e],function(e){return e.apply(t,r)})},clearLocalHooks:function(){this._localHooks={}}};(0,r.defineGetter)(i,"MIXIN_NAME","localHooks",{writable:!1,enumerable:!1}),t.default=i},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t,o){return t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o,e}function i(){var e={};return(0,C.objectEach)(D,function(t,o){e[o]=t()}),e}function s(e,t){-1===x.indexOf(e)&&(D[e]=t)}t.__esModule=!0,t.ITEMS=t.UNDO=t.SEPARATOR=t.ROW_BELOW=t.ROW_ABOVE=t.REMOVE_ROW=t.REMOVE_COLUMN=t.REDO=t.READ_ONLY=t.COLUMN_RIGHT=t.COLUMN_LEFT=t.CLEAR_COLUMN=t.ALIGNMENT=void 0;var l,a=o(262);Object.defineProperty(t,"ALIGNMENT",{enumerable:!0,get:function(){return a.KEY}});var u=o(263);Object.defineProperty(t,"CLEAR_COLUMN",{enumerable:!0,get:function(){return u.KEY}});var c=o(264);Object.defineProperty(t,"COLUMN_LEFT",{enumerable:!0,get:function(){return c.KEY}});var h=o(265);Object.defineProperty(t,"COLUMN_RIGHT",{enumerable:!0,get:function(){return h.KEY}});var d=o(266);Object.defineProperty(t,"READ_ONLY",{enumerable:!0,get:function(){return d.KEY}});var f=o(267);Object.defineProperty(t,"REDO",{enumerable:!0,get:function(){return f.KEY}});var p=o(268);Object.defineProperty(t,"REMOVE_COLUMN",{enumerable:!0,get:function(){return p.KEY}});var g=o(269);Object.defineProperty(t,"REMOVE_ROW",{enumerable:!0,get:function(){return g.KEY}});var v=o(270);Object.defineProperty(t,"ROW_ABOVE",{enumerable:!0,get:function(){return v.KEY}});var m=o(271);Object.defineProperty(t,"ROW_BELOW",{enumerable:!0,get:function(){return m.KEY}});var y=o(86);Object.defineProperty(t,"SEPARATOR",{enumerable:!0,get:function(){return y.KEY}});var w=o(272);Object.defineProperty(t,"UNDO",{enumerable:!0,get:function(){return w.KEY}}),t.predefinedItems=i,t.addItem=s;var C=o(1),b=n(a),S=n(u),E=n(c),R=n(h),O=n(d),k=n(f),T=n(p),_=n(g),M=n(v),H=n(m),A=n(y),P=n(w),x=t.ITEMS=[v.KEY,m.KEY,c.KEY,h.KEY,u.KEY,g.KEY,p.KEY,w.KEY,f.KEY,d.KEY,a.KEY,y.KEY],D=(l={},r(l,y.KEY,A.default),r(l,v.KEY,M.default),r(l,m.KEY,H.default),r(l,c.KEY,E.default),r(l,h.KEY,R.default),r(l,u.KEY,S.default),r(l,g.KEY,_.default),r(l,p.KEY,T.default),r(l,w.KEY,P.default),r(l,f.KEY,k.default),r(l,d.KEY,O.default),r(l,a.KEY,b.default),l)},function(e,t,o){"use strict";var n=o(90),r=o(39);e.exports=o(59)("Map",function(e){return function(){return e(this,arguments.length>0?arguments[0]:void 0)}},{get:function(e){var t=n.getEntry(r(this,"Map"),e);return t&&t.v},set:function(e,t){return n.def(r(this,"Map"),0===e?0:e,t)}},n,!0)},function(e,t,o){"use strict";var n=o(17).f,r=o(66),i=o(54),s=o(30),l=o(56),a=o(57),u=o(99),c=o(100),h=o(101),d=o(20),f=o(47).fastKey,p=o(39),g=d?"_s":"size",v=function(e,t){var o,n=f(t);if("F"!==n)return e._i[n];for(o=e._f;o;o=o.n)if(o.k==t)return o};e.exports={getConstructor:function(e,t,o,u){var c=e(function(e,n){l(e,c,t,"_i"),e._t=t,e._i=r(null),e._f=void 0,e._l=void 0,e[g]=0,void 0!=n&&a(n,o,e[u],e)});return i(c.prototype,{clear:function(){for(var e=p(this,t),o=e._i,n=e._f;n;n=n.n)n.r=!0,n.p&&(n.p=n.p.n=void 0),delete o[n.i];e._f=e._l=void 0,e[g]=0},delete:function(e){var o=p(this,t),n=v(o,e);if(n){var r=n.n,i=n.p;delete o._i[n.i],n.r=!0,i&&(i.n=r),r&&(r.p=i),o._f==n&&(o._f=r),o._l==n&&(o._l=i),o[g]--}return!!n},forEach:function(e){p(this,t);for(var o,n=s(e,arguments.length>1?arguments[1]:void 0,3);o=o?o.n:this._f;)for(n(o.v,o.k,this);o&&o.r;)o=o.p},has:function(e){return!!v(p(this,t),e)}}),d&&n(c.prototype,"size",{get:function(){return p(this,t)[g]}}),c},def:function(e,t,o){var n,r,i=v(e,t);return i?i.v=o:(e._l=i={i:r=f(t,!0),k:t,v:o,p:n=e._l,n:void 0,r:!1},e._f||(e._f=i),n&&(n.n=i),e[g]++,"F"!==r&&(e._i[r]=i)),e},getEntry:v,setStrong:function(e,t,o){u(e,t,function(e,o){this._t=p(e,t),this._k=o,this._l=void 0},function(){for(var e=this,t=e._k,o=e._l;o&&o.r;)o=o.p;return e._t&&(e._l=o=o?o.n:e._t._f)?"keys"==t?c(0,o.k):"values"==t?c(0,o.v):c(0,[o.k,o.v]):(e._t=void 0,c(1))},o?"entries":"values",!o,!0),h(t)}}},function(e,t,o){e.exports=!o(20)&&!o(23)(function(){return 7!=Object.defineProperty(o(64)("div"),"a",{get:function(){return 7}}).a})},function(e,t,o){var n=o(24),r=o(25),i=o(93)(!1),s=o(68)("IE_PROTO");e.exports=function(e,t){var o,l=r(e),a=0,u=[];for(o in l)o!=s&&n(l,o)&&u.push(o);for(;t.length>a;)n(l,o=t[a++])&&(~i(u,o)||u.push(o));return u}},function(e,t,o){var n=o(25),r=o(21),i=o(53);e.exports=function(e){return function(t,o,s){var l,a=n(t),u=r(a.length),c=i(s,u);if(e&&o!=o){for(;u>c;)if((l=a[c++])!=l)return!0}else for(;u>c;c++)if((e||c in a)&&a[c]===o)return e||c||0;return!e&&-1}}},function(e,t,o){var n=o(11).document;e.exports=n&&n.documentElement},function(e,t,o){var n=o(16);e.exports=function(e,t,o,r){try{return r?t(n(o)[0],o[1]):t(o)}catch(t){var i=e.return;throw void 0!==i&&n(i.call(e)),t}}},function(e,t,o){var n=o(45),r=o(9)("iterator"),i=Array.prototype;e.exports=function(e){return void 0!==e&&(n.Array===e||i[r]===e)}},function(e,t,o){var n=o(98),r=o(9)("iterator"),i=o(45);e.exports=o(44).getIteratorMethod=function(e){if(void 0!=e)return e[r]||e["@@iterator"]||i[n(e)]}},function(e,t,o){var n=o(37),r=o(9)("toStringTag"),i="Arguments"==n(function(){return arguments}()),s=function(e,t){try{return e[t]}catch(e){}};e.exports=function(e){var t,o,l;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(o=s(t=Object(e),r))?o:i?n(t):"Object"==(l=n(t))&&"function"==typeof t.callee?"Arguments":l}},function(e,t,o){"use strict";var n=o(58),r=o(3),i=o(28),s=o(29),l=o(24),a=o(45),u=o(182),c=o(46),h=o(183),d=o(9)("iterator"),f=!([].keys&&"next"in[].keys()),p=function(){return this};e.exports=function(e,t,o,g,v,m,y){u(o,t,g);var w,C,b,S=function(e){if(!f&&e in k)return k[e];switch(e){case"keys":case"values":return function(){return new o(this,e)}}return function(){return new o(this,e)}},E=t+" Iterator",R="values"==v,O=!1,k=e.prototype,T=k[d]||k["@@iterator"]||v&&k[v],_=T||S(v),M=v?R?S("entries"):_:void 0,H="Array"==t?k.entries||T:T;if(H&&(b=h(H.call(new e)))!==Object.prototype&&b.next&&(c(b,E,!0),n||l(b,d)||s(b,d,p)),R&&T&&"values"!==T.name&&(O=!0,_=function(){return T.call(this)}),n&&!y||!f&&!O&&k[d]||s(k,d,_),a[t]=_,a[E]=p,v)if(w={values:R?_:S("values"),keys:m?_:S("keys"),entries:M},y)for(C in w)C in k||i(k,C,w[C]);else r(r.P+r.F*(f||O),t,w);return w}},function(e,t){e.exports=function(e,t){return{value:t,done:!!e}}},function(e,t,o){"use strict";var n=o(11),r=o(17),i=o(20),s=o(9)("species");e.exports=function(e){var t=n[e];i&&t&&!t[s]&&r.f(t,s,{configurable:!0,get:function(){return this}})}},function(e,t,o){var n=o(14),r=o(16),i=function(e,t){if(r(e),!n(t)&&null!==t)throw TypeError(t+": can't set as prototype!")};e.exports={set:Object.setPrototypeOf||("__proto__"in{}?function(e,t,n){try{n=o(30)(Function.call,o(72).f(Object.prototype,"__proto__").set,2),n(e,[]),t=!(e instanceof Array)}catch(e){t=!0}return function(e,o){return i(e,o),t?e.__proto__=o:n(e,o),e}}({},!1):void 0),check:i}},function(e,t,o){"use strict";var n=o(90),r=o(39);e.exports=o(59)("Set",function(e){return function(){return e(this,arguments.length>0?arguments[0]:void 0)}},{add:function(e){return n.def(r(this,"Set"),e=0===e?0:e,e)}},n)},function(e,t,o){"use strict";var n,r=o(60)(0),i=o(28),s=o(47),l=o(106),a=o(107),u=o(14),c=o(23),h=o(39),d=s.getWeak,f=Object.isExtensible,p=a.ufstore,g={},v=function(e){return function(){return e(this,arguments.length>0?arguments[0]:void 0)}},m={get:function(e){if(u(e)){var t=d(e);return!0===t?p(h(this,"WeakMap")).get(e):t?t[this._i]:void 0}},set:function(e,t){return a.def(h(this,"WeakMap"),e,t)}},y=e.exports=o(59)("WeakMap",v,m,a,!0,!0);c(function(){return 7!=(new y).set((Object.freeze||Object)(g),7).get(g)})&&(n=a.getConstructor(v,"WeakMap"),l(n.prototype,m),s.NEED=!0,r(["delete","has","get","set"],function(e){var t=y.prototype,o=t[e];i(t,e,function(t,r){if(u(t)&&!f(t)){this._f||(this._f=new n);var i=this._f[e](t,r);return"set"==e?this:i}return o.call(this,t,r)})}))},function(e,t,o){var n=o(37);e.exports=Array.isArray||function(e){return"Array"==n(e)}},function(e,t,o){"use strict";var n=o(36),r=o(61),i=o(48),s=o(38),l=o(67),a=Object.assign;e.exports=!a||o(23)(function(){var e={},t={},o=Symbol(),n="abcdefghijklmnopqrst";return e[o]=7,n.split("").forEach(function(e){t[e]=e}),7!=a({},e)[o]||Object.keys(a({},t)).join("")!=n})?function(e,t){for(var o=s(e),a=arguments.length,u=1,c=r.f,h=i.f;a>u;)for(var d,f=l(arguments[u++]),p=c?n(f).concat(c(f)):n(f),g=p.length,v=0;g>v;)h.call(f,d=p[v++])&&(o[d]=f[d]);return o}:a},function(e,t,o){"use strict";var n=o(54),r=o(47).getWeak,i=o(16),s=o(14),l=o(56),a=o(57),u=o(60),c=o(24),h=o(39),d=u(5),f=u(6),p=0,g=function(e){return e._l||(e._l=new v)},v=function(){this.a=[]},m=function(e,t){return d(e.a,function(e){return e[0]===t})};v.prototype={get:function(e){var t=m(this,e);if(t)return t[1]},has:function(e){return!!m(this,e)},set:function(e,t){var o=m(this,e);o?o[1]=t:this.a.push([e,t])},delete:function(e){var t=f(this.a,function(t){return t[0]===e});return~t&&this.a.splice(t,1),!!~t}},e.exports={getConstructor:function(e,t,o,i){var u=e(function(e,n){l(e,u,t,"_i"),e._t=t,e._i=p++,e._l=void 0,void 0!=n&&a(n,o,e[i],e)});return n(u.prototype,{delete:function(e){if(!s(e))return!1;var o=r(e);return!0===o?g(h(this,t)).delete(e):o&&c(o,this._i)&&delete o[this._i]},has:function(e){if(!s(e))return!1;var o=r(e);return!0===o?g(h(this,t)).has(e):o&&c(o,this._i)}}),u},def:function(e,t,o){var n=r(i(t),!0);return!0===n?g(e).set(t,o):n[e._i]=o,e},ufstore:g}},function(e,t,o){"use strict";var n=o(107),r=o(39);o(59)("WeakSet",function(e){return function(){return e(this,arguments.length>0?arguments[0]:void 0)}},{add:function(e){return n.def(r(this,"WeakSet"),e,!0)}},n,!1,!0)},function(e,t,o){"use strict";var n,r,i,s,l=o(58),a=o(11),u=o(30),c=o(98),h=o(3),d=o(14),f=o(55),p=o(56),g=o(57),v=o(187),m=o(73).set,y=o(189)(),w=o(110),C=o(190),b=o(191),S=a.TypeError,E=a.process,R=a.Promise,O="process"==c(E),k=function(){},T=r=w.f,_=!!function(){try{var e=R.resolve(1),t=(e.constructor={})[o(9)("species")]=function(e){e(k,k)};return(O||"function"==typeof PromiseRejectionEvent)&&e.then(k)instanceof t}catch(e){}}(),M=function(e){var t;return!(!d(e)||"function"!=typeof(t=e.then))&&t},H=function(e,t){if(!e._n){e._n=!0;var o=e._c;y(function(){for(var n=e._v,r=1==e._s,i=0;o.length>i;)!function(t){var o,i,s=r?t.ok:t.fail,l=t.resolve,a=t.reject,u=t.domain;try{s?(r||(2==e._h&&x(e),e._h=1),!0===s?o=n:(u&&u.enter(),o=s(n),u&&u.exit()),o===t.promise?a(S("Promise-chain cycle")):(i=M(o))?i.call(o,l,a):l(o)):a(n)}catch(e){a(e)}}(o[i++]);e._c=[],e._n=!1,t&&!e._h&&A(e)})}},A=function(e){m.call(a,function(){var t,o,n,r=e._v,i=P(e);if(i&&(t=C(function(){O?E.emit("unhandledRejection",r,e):(o=a.onunhandledrejection)?o({promise:e,reason:r}):(n=a.console)&&n.error&&n.error("Unhandled promise rejection",r)}),e._h=O||P(e)?2:1),e._a=void 0,i&&t.e)throw t.v})},P=function(e){if(1==e._h)return!1;for(var t,o=e._a||e._c,n=0;o.length>n;)if(t=o[n++],t.fail||!P(t.promise))return!1;return!0},x=function(e){m.call(a,function(){var t;O?E.emit("rejectionHandled",e):(t=a.onrejectionhandled)&&t({promise:e,reason:e._v})})},D=function(e){var t=this;t._d||(t._d=!0,t=t._w||t,t._v=e,t._s=2,t._a||(t._a=t._c.slice()),H(t,!0))},L=function(e){var t,o=this;if(!o._d){o._d=!0,o=o._w||o;try{if(o===e)throw S("Promise can't be resolved itself");(t=M(e))?y(function(){var n={_w:o,_d:!1};try{t.call(e,u(L,n,1),u(D,n,1))}catch(e){D.call(n,e)}}):(o._v=e,o._s=1,H(o,!1))}catch(e){D.call({_w:o,_d:!1},e)}}};_||(R=function(e){p(this,R,"Promise","_h"),f(e),n.call(this);try{e(u(L,this,1),u(D,this,1))}catch(e){D.call(this,e)}},n=function(e){this._c=[],this._a=void 0,this._s=0,this._d=!1,this._v=void 0,this._h=0,this._n=!1},n.prototype=o(54)(R.prototype,{then:function(e,t){var o=T(v(this,R));return o.ok="function"!=typeof e||e,o.fail="function"==typeof t&&t,o.domain=O?E.domain:void 0,this._c.push(o),this._a&&this._a.push(o),this._s&&H(this,!1),o.promise},catch:function(e){return this.then(void 0,e)}}),i=function(){var e=new n;this.promise=e,this.resolve=u(L,e,1),this.reject=u(D,e,1)},w.f=T=function(e){return e===R||e===s?new i(e):r(e)}),h(h.G+h.W+h.F*!_,{Promise:R}),o(46)(R,"Promise"),o(101)("Promise"),s=o(44).Promise,h(h.S+h.F*!_,"Promise",{reject:function(e){var t=T(this);return(0,t.reject)(e),t.promise}}),h(h.S+h.F*(l||!_),"Promise",{resolve:function(e){return b(l&&this===s?R:this,e)}}),h(h.S+h.F*!(_&&o(71)(function(e){R.all(e).catch(k)})),"Promise",{all:function(e){var t=this,o=T(t),n=o.resolve,r=o.reject,i=C(function(){var o=[],i=0,s=1;g(e,!1,function(e){var l=i++,a=!1;o.push(void 0),s++,t.resolve(e).then(function(e){a||(a=!0,o[l]=e,--s||n(o))},r)}),--s||n(o)});return i.e&&r(i.v),o.promise},race:function(e){var t=this,o=T(t),n=o.reject,r=C(function(){g(e,!1,function(e){t.resolve(e).then(o.resolve,n)})});return r.e&&n(r.v),o.promise}})},function(e,t,o){"use strict";function n(e){var t,o;this.promise=new e(function(e,n){if(void 0!==t||void 0!==o)throw TypeError("Bad Promise constructor");t=e,o=n}),this.resolve=r(t),this.reject=r(o)}var r=o(55);e.exports.f=function(e){return new n(e)}},function(e,t,o){"use strict";var n=o(11),r=o(24),i=o(20),s=o(3),l=o(28),a=o(47).KEY,u=o(23),c=o(69),h=o(46),d=o(42),f=o(9),p=o(112),g=o(192),v=o(193),m=o(105),y=o(16),w=o(25),C=o(65),b=o(43),S=o(66),E=o(194),R=o(72),O=o(17),k=o(36),T=R.f,_=O.f,M=E.f,H=n.Symbol,A=n.JSON,P=A&&A.stringify,x=f("_hidden"),D=f("toPrimitive"),L={}.propertyIsEnumerable,N=c("symbol-registry"),I=c("symbols"),j=c("op-symbols"),W=Object.prototype,B="function"==typeof H,F=n.QObject,V=!F||!F.prototype||!F.prototype.findChild,z=i&&u(function(){return 7!=S(_({},"a",{get:function(){return _(this,"a",{value:7}).a}})).a})?function(e,t,o){var n=T(W,t);n&&delete W[t],_(e,t,o),n&&e!==W&&_(W,t,n)}:_,U=function(e){var t=I[e]=S(H.prototype);return t._k=e,t},Y=B&&"symbol"==typeof H.iterator?function(e){return"symbol"==typeof e}:function(e){return e instanceof H},K=function(e,t,o){return e===W&&K(j,t,o),y(e),t=C(t,!0),y(o),r(I,t)?(o.enumerable?(r(e,x)&&e[x][t]&&(e[x][t]=!1),o=S(o,{enumerable:b(0,!1)})):(r(e,x)||_(e,x,b(1,{})),e[x][t]=!0),z(e,t,o)):_(e,t,o)},G=function(e,t){y(e);for(var o,n=v(t=w(t)),r=0,i=n.length;i>r;)K(e,o=n[r++],t[o]);return e},X=function(e,t){return void 0===t?S(e):G(S(e),t)},q=function(e){var t=L.call(this,e=C(e,!0));return!(this===W&&r(I,e)&&!r(j,e))&&(!(t||!r(this,e)||!r(I,e)||r(this,x)&&this[x][e])||t)},Q=function(e,t){if(e=w(e),t=C(t,!0),e!==W||!r(I,t)||r(j,t)){var o=T(e,t);return!o||!r(I,t)||r(e,x)&&e[x][t]||(o.enumerable=!0),o}},J=function(e){for(var t,o=M(w(e)),n=[],i=0;o.length>i;)r(I,t=o[i++])||t==x||t==a||n.push(t);return n},$=function(e){for(var t,o=e===W,n=M(o?j:w(e)),i=[],s=0;n.length>s;)!r(I,t=n[s++])||o&&!r(W,t)||i.push(I[t]);return i};B||(H=function(){if(this instanceof H)throw TypeError("Symbol is not a constructor!");var e=d(arguments.length>0?arguments[0]:void 0),t=function(o){this===W&&t.call(j,o),r(this,x)&&r(this[x],e)&&(this[x][e]=!1),z(this,e,b(1,o))};return i&&V&&z(W,e,{configurable:!0,set:t}),U(e)},l(H.prototype,"toString",function(){return this._k}),R.f=Q,O.f=K,o(74).f=E.f=J,o(48).f=q,o(61).f=$,i&&!o(58)&&l(W,"propertyIsEnumerable",q,!0),p.f=function(e){return U(f(e))}),s(s.G+s.W+s.F*!B,{Symbol:H});for(var Z="hasInstance,isConcatSpreadable,iterator,match,replace,search,species,split,toPrimitive,toStringTag,unscopables".split(","),ee=0;Z.length>ee;)f(Z[ee++]);for(var te=k(f.store),oe=0;te.length>oe;)g(te[oe++]);s(s.S+s.F*!B,"Symbol",{for:function(e){return r(N,e+="")?N[e]:N[e]=H(e)},keyFor:function(e){if(!Y(e))throw TypeError(e+" is not a symbol!");for(var t in N)if(N[t]===e)return t},useSetter:function(){V=!0},useSimple:function(){V=!1}}),s(s.S+s.F*!B,"Object",{create:X,defineProperty:K,defineProperties:G,getOwnPropertyDescriptor:Q,getOwnPropertyNames:J,getOwnPropertySymbols:$}),A&&s(s.S+s.F*(!B||u(function(){var e=H();return"[null]"!=P([e])||"{}"!=P({a:e})||"{}"!=P(Object(e))})),"JSON",{stringify:function(e){if(void 0!==e&&!Y(e)){for(var t,o,n=[e],r=1;arguments.length>r;)n.push(arguments[r++]);return t=n[1],"function"==typeof t&&(o=t),!o&&m(t)||(t=function(e,t){if(o&&(t=o.call(this,e,t)),!Y(t))return t}),n[1]=t,P.apply(A,n)}}}),H.prototype[D]||o(29)(H.prototype,D,H.prototype.valueOf),h(H,"Symbol"),h(Math,"Math",!0),h(n.JSON,"JSON",!0)},function(e,t,o){t.f=o(9)},function(e,t,o){var n=o(3);n(n.S+n.F,"Object",{assign:o(106)})},function(e,t,o){var n=o(3);n(n.S,"Object",{is:o(195)})},function(e,t,o){var n=o(3);n(n.S,"Object",{setPrototypeOf:o(102).set})},function(e,t,o){var n=o(17).f,r=Function.prototype,i=/^\s*function ([^ (]*)/;"name"in r||o(20)&&n(r,"name",{configurable:!0,get:function(){try{return(""+this).match(i)[1]}catch(e){return""}}})},function(e,t,o){var n=o(3),r=o(25),i=o(21);n(n.S,"String",{raw:function(e){for(var t=r(e.raw),o=i(t.length),n=arguments.length,s=[],l=0;o>l;)s.push(t[l++]+""),n>l&&s.push(arguments[l]+"");return s.join("")}})},function(e,t,o){var n=o(3),r=o(53),i=String.fromCharCode,s=String.fromCodePoint;n(n.S+n.F*(!!s&&1!=s.length),"String",{fromCodePoint:function(e){for(var t,o=[],n=arguments.length,s=0;n>s;){if(t=+arguments[s++],r(t,1114111)!==t)throw RangeError(t+" is not a valid code point");o.push(65536>t?i(t):i(55296+((t-=65536)>>10),t%1024+56320))}return o.join("")}})},function(e,t,o){"use strict";var n=o(3),r=o(196)(!1);n(n.P,"String",{codePointAt:function(e){return r(this,e)}})},function(e,t,o){var n=o(3);n(n.P,"String",{repeat:o(121)})},function(e,t,o){"use strict";var n=o(52),r=o(33);e.exports=function(e){var t=r(this)+"",o="",i=n(e);if(0>i||i==1/0)throw RangeError("Count can't be negative");for(;i>0;(i>>>=1)&&(t+=t))1&i&&(o+=t);return o}},function(e,t,o){"use strict";var n=o(3),r=o(21),i=o(75),s="".startsWith;n(n.P+n.F*o(76)("startsWith"),"String",{startsWith:function(e){var t=i(this,e,"startsWith"),o=r(Math.min(arguments.length>1?arguments[1]:void 0,t.length)),n=e+"";return s?s.call(t,n,o):t.slice(o,o+n.length)===n}})},function(e,t,o){var n=o(14),r=o(37),i=o(9)("match");e.exports=function(e){var t;return n(e)&&(void 0!==(t=e[i])?!!t:"RegExp"==r(e))}},function(e,t,o){"use strict";var n=o(3),r=o(21),i=o(75),s="".endsWith;n(n.P+n.F*o(76)("endsWith"),"String",{endsWith:function(e){var t=i(this,e,"endsWith"),o=arguments.length>1?arguments[1]:void 0,n=r(t.length),l=void 0===o?n:Math.min(r(o),n),a=e+"";return s?s.call(t,a,l):t.slice(l-a.length,l)===a}})},function(e,t,o){"use strict";var n=o(3),r=o(75);n(n.P+n.F*o(76)("includes"),"String",{includes:function(e){return!!~r(this,e,"includes").indexOf(e,arguments.length>1?arguments[1]:void 0)}})},function(e,t,o){o(20)&&"g"!=/./g.flags&&o(17).f(RegExp.prototype,"flags",{configurable:!0,get:o(197)})},function(e,t,o){o(62)("match",1,function(e,t,o){return[function(o){"use strict";var n=e(this),r=void 0==o?void 0:o[t];return void 0!==r?r.call(o,n):RegExp(o)[t](n+"")},o]})},function(e,t,o){o(62)("replace",2,function(e,t,o){return[function(n,r){"use strict";var i=e(this),s=void 0==n?void 0:n[t];return void 0!==s?s.call(n,i,r):o.call(i+"",n,r)},o]})},function(e,t,o){o(62)("split",2,function(e,t,n){"use strict";var r=o(123),i=n,s=[].push,l="length";if("c"=="abbc".split(/(b)*/)[1]||4!="test".split(/(?:)/,-1)[l]||2!="ab".split(/(?:ab)*/)[l]||4!=".".split(/(.?)(.?)/)[l]||".".split(/()()/)[l]>1||"".split(/.?/)[l]){var a=void 0===/()??/.exec("")[1];n=function(e,t){var o=this+"";if(void 0===e&&0===t)return[];if(!r(e))return i.call(o,e,t);var n,u,c,h,d,f=[],p=(e.ignoreCase?"i":"")+(e.multiline?"m":"")+(e.unicode?"u":"")+(e.sticky?"y":""),g=0,v=void 0===t?4294967295:t>>>0,m=RegExp(e.source,p+"g");for(a||(n=RegExp("^"+m.source+"$(?!\\s)",p));(u=m.exec(o))&&((c=u.index+u[0][l])<=g||(f.push(o.slice(g,u.index)),!a&&u[l]>1&&u[0].replace(n,function(){for(d=1;arguments[l]-2>d;d++)void 0===arguments[d]&&(u[d]=void 0)}),u[l]>1&&o[l]>u.index&&s.apply(f,u.slice(1)),h=u[0][l],g=c,v>f[l]));)m.lastIndex===u.index&&m.lastIndex++;return g===o[l]?!h&&m.test("")||f.push(""):f.push(o.slice(g)),f[l]>v?f.slice(0,v):f}}else"0".split(void 0,0)[l]&&(n=function(e,t){return void 0===e&&0===t?[]:i.call(this,e,t)});return[function(o,r){var i=e(this),s=void 0==o?void 0:o[t];return void 0!==s?s.call(o,i,r):n.call(i+"",o,r)},n]})},function(e,t,o){o(62)("search",1,function(e,t,o){return[function(o){"use strict";var n=e(this),r=void 0==o?void 0:o[t];return void 0!==r?r.call(o,n):RegExp(o)[t](n+"")},o]})},function(e,t,o){"use strict";var n=o(30),r=o(3),i=o(38),s=o(95),l=o(96),a=o(21),u=o(77),c=o(97);r(r.S+r.F*!o(71)(function(e){Array.from(e)}),"Array",{from:function(e){var t,o,r,h,d=i(e),f="function"==typeof this?this:Array,p=arguments.length,g=p>1?arguments[1]:void 0,v=void 0!==g,m=0,y=c(d);if(v&&(g=n(g,p>2?arguments[2]:void 0,2)),void 0==y||f==Array&&l(y))for(t=a(d.length),o=new f(t);t>m;m++)u(o,m,v?g(d[m],m):d[m]);else for(h=y.call(d),o=new f;!(r=h.next()).done;m++)u(o,m,v?s(h,g,[r.value,m],!0):r.value);return o.length=m,o}})},function(e,t,o){"use strict";var n=o(3),r=o(77);n(n.S+n.F*o(23)(function(){function e(){}return!(Array.of.call(e)instanceof e)}),"Array",{of:function(){for(var e=0,t=arguments.length,o=new("function"==typeof this?this:Array)(t);t>e;)r(o,e,arguments[e++]);return o.length=t,o}})},function(e,t,o){var n=o(3);n(n.P,"Array",{copyWithin:o(198)}),o(40)("copyWithin")},function(e,t,o){"use strict";var n=o(3),r=o(60)(5),i=!0;"find"in[]&&Array(1).find(function(){i=!1}),n(n.P+n.F*i,"Array",{find:function(e){return r(this,e,arguments.length>1?arguments[1]:void 0)}}),o(40)("find")},function(e,t,o){"use strict";var n=o(3),r=o(60)(6),i="findIndex",s=!0;i in[]&&Array(1)[i](function(){s=!1}),n(n.P+n.F*s,"Array",{findIndex:function(e){return r(this,e,arguments.length>1?arguments[1]:void 0)}}),o(40)(i)},function(e,t,o){var n=o(3);n(n.P,"Array",{fill:o(199)}),o(40)("fill")},function(e,t,o){var n=o(3),r=o(11).isFinite;n(n.S,"Number",{isFinite:function(e){return"number"==typeof e&&r(e)}})},function(e,t,o){var n=o(3);n(n.S,"Number",{isInteger:o(139)})},function(e,t,o){var n=o(14),r=Math.floor;e.exports=function(e){return!n(e)&&isFinite(e)&&r(e)===e}},function(e,t,o){var n=o(3),r=o(139),i=Math.abs;n(n.S,"Number",{isSafeInteger:function(e){return r(e)&&9007199254740991>=i(e)}})},function(e,t,o){var n=o(3);n(n.S,"Number",{isNaN:function(e){return e!=e}})},function(e,t,o){var n=o(3);n(n.S,"Number",{EPSILON:Math.pow(2,-52)})},function(e,t,o){var n=o(3);n(n.S,"Number",{MIN_SAFE_INTEGER:-9007199254740991})},function(e,t,o){var n=o(3);n(n.S,"Number",{MAX_SAFE_INTEGER:9007199254740991})},function(e,t,o){"use strict";var n=o(3),r=o(93)(!0);n(n.P,"Array",{includes:function(e){return r(this,e,arguments.length>1?arguments[1]:void 0)}}),o(40)("includes")},function(e,t,o){var n=o(3),r=o(147)(!1);n(n.S,"Object",{values:function(e){return r(e)}})},function(e,t,o){var n=o(36),r=o(25),i=o(48).f;e.exports=function(e){return function(t){for(var o,s=r(t),l=n(s),a=l.length,u=0,c=[];a>u;)i.call(s,o=l[u++])&&c.push(e?[o,s[o]]:s[o]);return c}}},function(e,t,o){var n=o(3),r=o(147)(!0);n(n.S,"Object",{entries:function(e){return r(e)}})},function(e,t,o){var n=o(3),r=o(200),i=o(25),s=o(72),l=o(77);n(n.S,"Object",{getOwnPropertyDescriptors:function(e){for(var t,o,n=i(e),a=s.f,u=r(n),c={},h=0;u.length>h;)void 0!==(o=a(n,t=u[h++]))&&l(c,t,o);return c}})},function(e,t,o){"use strict";var n=o(3),r=o(151);n(n.P,"String",{padStart:function(e){return r(this,e,arguments.length>1?arguments[1]:void 0,!0)}})},function(e,t,o){var n=o(21),r=o(121),i=o(33);e.exports=function(e,t,o,s){var l=i(e)+"",a=l.length,u=void 0===o?" ":o+"",c=n(t);if(a>=c||""==u)return l;var h=c-a,d=r.call(u,Math.ceil(h/u.length));return d.length>h&&(d=d.slice(0,h)),s?d+l:l+d}},function(e,t,o){"use strict";var n=o(3),r=o(151);n(n.P,"String",{padEnd:function(e){return r(this,e,arguments.length>1?arguments[1]:void 0,!1)}})},function(e,t,o){var n=o(3),r=o(73);n(n.G+n.B,{setImmediate:r.set,clearImmediate:r.clear})},function(e,t,o){for(var n=o(78),r=o(36),i=o(28),s=o(11),l=o(29),a=o(45),u=o(9),c=u("iterator"),h=u("toStringTag"),d=a.Array,f={CSSRuleList:!0,CSSStyleDeclaration:!1,CSSValueList:!1,ClientRectList:!1,DOMRectList:!1,DOMStringList:!1,DOMTokenList:!0,DataTransferItemList:!1,FileList:!1,HTMLAllCollection:!1,HTMLCollection:!1,HTMLFormElement:!1,HTMLSelectElement:!1,MediaList:!0,MimeTypeArray:!1,NamedNodeMap:!1,NodeList:!0,PaintRequestList:!1,Plugin:!1,PluginArray:!1,SVGLengthList:!1,SVGNumberList:!1,SVGPathSegList:!1,SVGPointList:!1,SVGStringList:!1,SVGTransformList:!1,SourceBufferList:!1,StyleSheetList:!0,TextTrackCueList:!1,TextTrackList:!1,TouchList:!1},p=r(f),g=0;p.length>g;g++){var v,m=p[g],y=f[m],w=s[m],C=w&&w.prototype;if(C&&(C[c]||l(C,c,d),C[h]||l(C,h,m),a[m]=d,y))for(v in n)C[v]||i(C,v,n[v],!0)}},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=new WeakMap;t.default=function(){function e(t,o,r,s,l,a,u){var c=arguments.length>7&&void 0!==arguments[7]?arguments[7]:function(e){return e};n(this,e),i.set(this,{viewportWidth:t,scrollOffset:o,totalColumns:r,columnWidthFn:s,overrideFn:l,onlyFullyVisible:a,stretchingColumnWidthFn:c}),this.count=0,this.startColumn=null,this.endColumn=null,this.startPosition=null,this.stretchAllRatio=0,this.stretchLastWidth=0,this.stretch=u,this.totalTargetWidth=0,this.needVerifyLastColumnWidth=!0,this.stretchAllColumnsWidth=[],this.calculate()}return r(e,null,[{key:"DEFAULT_WIDTH",get:function(){return 50}}]),r(e,[{key:"calculate",value:function(){for(var e=0,t=!0,o=[],n=void 0,r=i.get(this),s=r.onlyFullyVisible,l=r.overrideFn,a=r.scrollOffset,u=r.totalColumns,c=r.viewportWidth,h=0;u>h;h++){n=this._getColumnWidth(h),e>a||s||(this.startColumn=h);var d=a>0?c+1:c;if(a>e||e+n>a+d||(null==this.startColumn&&(this.startColumn=h),this.endColumn=h),o.push(e),e+=n,s||(this.endColumn=h),e>=a+c){t=!1;break}}if(this.endColumn===u-1&&t)for(this.startColumn=this.endColumn;this.startColumn>0;){var f=o[this.endColumn]+n-o[this.startColumn-1];if(f>c&&s||this.startColumn--,f>c)break}null!==this.startColumn&&l&&l(this),this.startPosition=o[this.startColumn],void 0==this.startPosition&&(this.startPosition=null),null!==this.startColumn&&(this.count=this.endColumn-this.startColumn+1)}},{key:"refreshStretching",value:function(e){if("none"!==this.stretch){this.totalTargetWidth=e;for(var t=i.get(this),o=t.totalColumns,n=0,r=0;o>r;r++){var s=this._getColumnWidth(r),l=t.stretchingColumnWidthFn(void 0,r);"number"==typeof l?e-=l:n+=s}var a=e-n;if("all"===this.stretch&&a>0)this.stretchAllRatio=e/n,this.stretchAllColumnsWidth=[],this.needVerifyLastColumnWidth=!0;else if("last"===this.stretch&&e!==1/0){var u=this._getColumnWidth(o-1),c=a+u;this.stretchLastWidth=0>c?u:c}}}},{key:"getStretchedColumnWidth",value:function(e,t){var o=null;return"all"===this.stretch&&0!==this.stretchAllRatio?o=this._getStretchedAllColumnWidth(e,t):"last"===this.stretch&&0!==this.stretchLastWidth&&(o=this._getStretchedLastColumnWidth(e)),o}},{key:"_getStretchedAllColumnWidth",value:function(e,t){var o=0,n=i.get(this),r=n.totalColumns;if(!this.stretchAllColumnsWidth[e]){var s=Math.round(t*this.stretchAllRatio),l=n.stretchingColumnWidthFn(s,e);this.stretchAllColumnsWidth[e]=void 0===l?s:isNaN(l)?this._getColumnWidth(e):l}if(this.stretchAllColumnsWidth.length===r&&this.needVerifyLastColumnWidth){this.needVerifyLastColumnWidth=!1;for(var a=0;this.stretchAllColumnsWidth.length>a;a++)o+=this.stretchAllColumnsWidth[a];o!==this.totalTargetWidth&&(this.stretchAllColumnsWidth[this.stretchAllColumnsWidth.length-1]+=this.totalTargetWidth-o)}return this.stretchAllColumnsWidth[e]}},{key:"_getStretchedLastColumnWidth",value:function(e){return e===i.get(this).totalColumns-1?this.stretchLastWidth:null}},{key:"_getColumnWidth",value:function(t){var o=i.get(this).columnWidthFn(t);return void 0===o&&(o=e.DEFAULT_WIDTH),o}}]),e}()},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=new WeakMap;t.default=function(){function e(t,o,r,s,l,a,u){n(this,e),i.set(this,{viewportHeight:t,scrollOffset:o,totalRows:r,rowHeightFn:s,overrideFn:l,onlyFullyVisible:a,horizontalScrollbarHeight:u}),this.count=0,this.startRow=null,this.endRow=null,this.startPosition=null,this.calculate()}return r(e,null,[{key:"DEFAULT_HEIGHT",get:function(){return 23}}]),r(e,[{key:"calculate",value:function(){for(var t=0,o=!0,n=[],r=i.get(this),s=r.onlyFullyVisible,l=r.overrideFn,a=r.rowHeightFn,u=r.scrollOffset,c=r.totalRows,h=r.viewportHeight,d=r.horizontalScrollbarHeight||0,f=void 0,p=0;c>p;p++)if(f=a(p),void 0===f&&(f=e.DEFAULT_HEIGHT),t>u||s||(this.startRow=p),u>t||t+f>u+h-d||(null===this.startRow&&(this.startRow=p),this.endRow=p),n.push(t),t+=f,s||(this.endRow=p),t>=u+h-d){o=!1;break}if(this.endRow===c-1&&o)for(this.startRow=this.endRow;this.startRow>0;){var g=n[this.endRow]+f-n[this.startRow-1];if(g>h-d&&s||this.startRow--,g>=h-d)break}null!==this.startRow&&l&&l(this),this.startPosition=n[this.startRow],void 0==this.startPosition&&(this.startPosition=null),null!==this.startRow&&(this.count=this.endRow-this.startRow+1)}}]),e}()},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}();t.default=function(){function e(t,o,r){n(this,e),this.offset=t,this.total=o,this.countTH=r}return r(e,[{key:"offsetted",value:function(e){return e+this.offset}},{key:"unOffsetted",value:function(e){return e-this.offset}},{key:"renderedToSource",value:function(e){return this.offsetted(e)}},{key:"sourceToRendered",value:function(e){return this.unOffsetted(e)}},{key:"offsettedTH",value:function(e){return e-this.countTH}},{key:"unOffsettedTH",value:function(e){return e+this.countTH}},{key:"visibleRowHeadedColumnToSourceColumn",value:function(e){return this.renderedToSource(this.offsettedTH(e))}},{key:"sourceColumnToVisibleRowHeadedColumn",value:function(e){return this.unOffsettedTH(this.sourceToRendered(e))}}]),e}()},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}();t.default=function(){function e(t,o,r){n(this,e),this.offset=t,this.total=o,this.countTH=r}return r(e,[{key:"offsetted",value:function(e){return e+this.offset}},{key:"unOffsetted",value:function(e){return e-this.offset}},{key:"renderedToSource",value:function(e){return this.offsetted(e)}},{key:"sourceToRendered",value:function(e){return this.unOffsetted(e)}},{key:"offsettedTH",value:function(e){return e-this.countTH}},{key:"unOffsettedTH",value:function(e){return e+this.countTH}},{key:"visibleColHeadedRowToSourceRow",value:function(e){return this.renderedToSource(this.offsettedTH(e))}},{key:"sourceRowToVisibleColHeadedRow",value:function(e){return this.unOffsettedTH(this.sourceToRendered(e))}}]),e}()},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var i=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),s=o(0),l=o(1),a=o(32),u=o(160),c=n(u),h=o(161),d=n(h),f=o(162),p=n(f),g=o(163),v=n(g),m=o(164),y=n(m),w=o(166),C=n(w);t.default=function(){function e(t){r(this,e);var o=[];if(this.guid="wt_"+(0,a.randomString)(),t.cloneSource?(this.cloneSource=t.cloneSource,this.cloneOverlay=t.cloneOverlay,this.wtSettings=t.cloneSource.wtSettings,this.wtTable=new y.default(this,t.table,t.wtRootElement),this.wtScroll=new p.default(this),this.wtViewport=t.cloneSource.wtViewport,this.wtEvent=new c.default(this),this.selections=this.cloneSource.selections):(this.wtSettings=new v.default(this,t),this.wtTable=new y.default(this,t.table),this.wtScroll=new p.default(this),this.wtViewport=new C.default(this),this.wtEvent=new c.default(this),this.selections=this.getSetting("selections"),this.wtOverlays=new d.default(this),this.exportSettingsAsClassNames()),this.wtTable.THEAD.childNodes.length&&this.wtTable.THEAD.childNodes[0].childNodes.length){for(var n=0,i=this.wtTable.THEAD.childNodes[0].childNodes.length;i>n;n++)o.push(this.wtTable.THEAD.childNodes[0].childNodes[n].innerHTML);this.getSetting("columnHeaders").length||this.update("columnHeaders",[function(e,t){(0,s.fastInnerText)(t,o[e])}])}this.drawn=!1,this.drawInterrupted=!1}return i(e,[{key:"draw",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return this.drawInterrupted=!1,e||(0,s.isVisible)(this.wtTable.TABLE)?this.wtTable.draw(e):this.drawInterrupted=!0,this}},{key:"getCell",value:function(e){if(1>=arguments.length||void 0===arguments[1]||!arguments[1])return this.wtTable.getCell(e);var t=this.wtSettings.getSetting("totalRows"),o=this.wtSettings.getSetting("fixedRowsTop"),n=this.wtSettings.getSetting("fixedRowsBottom"),r=this.wtSettings.getSetting("fixedColumnsLeft");if(o>e.row&&r>e.col)return this.wtOverlays.topLeftCornerOverlay.clone.wtTable.getCell(e);if(o>e.row)return this.wtOverlays.topOverlay.clone.wtTable.getCell(e);if(r>e.col&&e.row>=t-n){if(this.wtOverlays.bottomLeftCornerOverlay&&this.wtOverlays.bottomLeftCornerOverlay.clone)return this.wtOverlays.bottomLeftCornerOverlay.clone.wtTable.getCell(e)}else{if(r>e.col)return this.wtOverlays.leftOverlay.clone.wtTable.getCell(e);if(t>e.row&&e.row>t-n&&this.wtOverlays.bottomOverlay&&this.wtOverlays.bottomOverlay.clone)return this.wtOverlays.bottomOverlay.clone.wtTable.getCell(e)}return this.wtTable.getCell(e)}},{key:"update",value:function(e,t){return this.wtSettings.update(e,t)}},{key:"scrollVertical",value:function(e){return this.wtOverlays.topOverlay.scrollTo(e),this.getSetting("onScrollVertically"),this}},{key:"scrollHorizontal",value:function(e){return this.wtOverlays.leftOverlay.scrollTo(e),this.getSetting("onScrollHorizontally"),this}},{key:"scrollViewport",value:function(e){return this.wtScroll.scrollViewport(e),this}},{key:"getViewport",value:function(){return[this.wtTable.getFirstVisibleRow(),this.wtTable.getFirstVisibleColumn(),this.wtTable.getLastVisibleRow(),this.wtTable.getLastVisibleColumn()]}},{key:"getOverlayName",value:function(){return this.cloneOverlay?this.cloneOverlay.type:"master"}},{key:"isOverlayName",value:function(e){return!!this.cloneOverlay&&this.cloneOverlay.type===e}},{key:"exportSettingsAsClassNames",value:function(){var e=this,t={rowHeaders:["array"],columnHeaders:["array"]},o=[],n=[];(0,l.objectEach)(t,function(t,r){t.indexOf("array")>-1&&e.getSetting(r).length&&n.push("ht"+(0,a.toUpperCaseFirst)(r)),o.push("ht"+(0,a.toUpperCaseFirst)(r))}),(0,s.removeClass)(this.wtTable.wtRootElement.parentNode,o),(0,s.addClass)(this.wtTable.wtRootElement.parentNode,n)}},{key:"getSetting",value:function(e,t,o,n,r){return this.wtSettings.getSetting(e,t,o,n,r)}},{key:"hasSetting",value:function(e){return this.wtSettings.has(e)}},{key:"destroy",value:function(){this.wtOverlays.destroy(),this.wtEvent.destroy()}}]),e}()},function(e,t,o){"use strict";function n(e){var t=this,o=new a.default(e);this.instance=e;var n=[null,null];this.dblClickTimeout=[null,null];var l=function(e){var o=document.activeElement,s=(0,i.partial)(r.getParent,e.realTarget),l=e.realTarget;if(l!==o&&s(0)!==o&&s(1)!==o){var a=t.parentCell(l);(0,r.hasClass)(l,"corner")?t.instance.getSetting("onCellCornerMouseDown",e,l):a.TD&&t.instance.hasSetting("onCellMouseDown")&&t.instance.getSetting("onCellMouseDown",e,a.coords,a.TD,t.instance),2!==e.button&&a.TD&&(n[0]=a.TD,clearTimeout(t.dblClickTimeout[0]),t.dblClickTimeout[0]=setTimeout(function(){n[0]=null},1e3))}},u=function(e){t.instance.touchMoving=!0},c=function(e){o.addEventListener(this,"touchmove",u),t.checkIfTouchMove=setTimeout(function(){!0===t.instance.touchMoving&&(t.instance.touchMoving=void 0,o.removeEventListener("touchmove",u,!1)),l(e)},30)},h=function(e){var o,n,i;t.instance.hasSetting("onCellMouseOver")&&(o=t.instance.wtTable.TABLE,n=(0,r.closestDown)(e.realTarget,["TD","TH"],o),i=t.instance.cloneSource||t.instance,n&&n!==i.lastMouseOver&&(0,r.isChildOf)(n,o)&&(i.lastMouseOver=n,t.instance.getSetting("onCellMouseOver",e,t.instance.wtTable.getCoords(n),n,t.instance)))},d=function(e){var o=void 0,n=void 0,i=void 0;t.instance.hasSetting("onCellMouseOut")&&(o=t.instance.wtTable.TABLE,n=(0,r.closestDown)(e.realTarget,["TD","TH"],o),i=(0,r.closestDown)(e.relatedTarget,["TD","TH"],o),n&&n!==i&&(0,r.isChildOf)(n,o)&&t.instance.getSetting("onCellMouseOut",e,t.instance.wtTable.getCoords(n),n,t.instance))},f=function(e){if(2!==e.button){var o=t.parentCell(e.realTarget);o.TD===n[0]&&o.TD===n[1]?((0,r.hasClass)(e.realTarget,"corner")?t.instance.getSetting("onCellCornerDblClick",e,o.coords,o.TD,t.instance):t.instance.getSetting("onCellDblClick",e,o.coords,o.TD,t.instance),n[0]=null,n[1]=null):o.TD===n[0]?(t.instance.getSetting("onCellMouseUp",e,o.coords,o.TD,t.instance),n[1]=o.TD,clearTimeout(t.dblClickTimeout[1]),t.dblClickTimeout[1]=setTimeout(function(){n[1]=null},500)):o.TD&&t.instance.hasSetting("onCellMouseUp")&&t.instance.getSetting("onCellMouseUp",e,o.coords,o.TD,t.instance)}},p=function(e){clearTimeout(void 0),e.preventDefault(),f(e)};if(o.addEventListener(this.instance.wtTable.holder,"mousedown",l),o.addEventListener(this.instance.wtTable.TABLE,"mouseover",h),o.addEventListener(this.instance.wtTable.TABLE,"mouseout",d),o.addEventListener(this.instance.wtTable.holder,"mouseup",f),this.instance.wtTable.holder.parentNode.parentNode&&(0,s.isMobileBrowser)()&&!t.instance.wtTable.isWorkingOnClone()){var g="."+this.instance.wtTable.holder.parentNode.className.split(" ").join(".");o.addEventListener(this.instance.wtTable.holder,"touchstart",function(e){t.instance.touchApplied=!0,(0,r.isChildOf)(e.target,g)&&c.call(e.target,e)}),o.addEventListener(this.instance.wtTable.holder,"touchend",function(e){t.instance.touchApplied=!1,(0,r.isChildOf)(e.target,g)&&p.call(e.target,e)}),t.instance.momentumScrolling||(t.instance.momentumScrolling={}),o.addEventListener(this.instance.wtTable.holder,"scroll",function(e){clearTimeout(t.instance.momentumScrolling._timeout),t.instance.momentumScrolling.ongoing||t.instance.getSetting("onBeforeTouchScroll"),t.instance.momentumScrolling.ongoing=!0,t.instance.momentumScrolling._timeout=setTimeout(function(){t.instance.touchApplied||(t.instance.momentumScrolling.ongoing=!1,t.instance.getSetting("onAfterMomentumScroll"))},200)})}o.addEventListener(window,"resize",function(){"none"!==t.instance.getSetting("stretchH")&&t.instance.draw()}),this.destroy=function(){clearTimeout(this.dblClickTimeout[0]),clearTimeout(this.dblClickTimeout[1]),o.destroy()}}t.__esModule=!0;var r=o(0),i=o(35),s=o(26),l=o(4),a=function(e){return e&&e.__esModule?e:{default:e}}(l);n.prototype.parentCell=function(e){var t={},o=this.instance.wtTable.TABLE,n=(0,r.closestDown)(e,["TD","TH"],o);return n?(t.coords=this.instance.wtTable.getCoords(n),t.TD=n):(0,r.hasClass)(e,"wtBorder")&&(0,r.hasClass)(e,"current")?(t.coords=this.instance.selections.current.cellRange.highlight,t.TD=this.instance.wtTable.getCell(t.coords)):(0,r.hasClass)(e,"wtBorder")&&(0,r.hasClass)(e,"area")&&this.instance.selections.area.cellRange&&(t.coords=this.instance.selections.area.cellRange.to,t.TD=this.instance.wtTable.getCell(t.coords)),t},t.default=n},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var i=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),s=o(0),l=o(2),a=o(18),u=o(26),c=o(4),h=n(c),d=o(31),f=n(d);t.default=function(){function e(t){r(this,e),this.wot=t,this.instance=this.wot,this.eventManager=new h.default(this.wot),this.wot.update("scrollbarWidth",(0,s.getScrollbarWidth)()),this.wot.update("scrollbarHeight",(0,s.getScrollbarWidth)()),this.scrollableElement=(0,s.getScrollableElement)(this.wot.wtTable.TABLE),this.prepareOverlays(),this.destroyed=!1,this.keyPressed=!1,this.spreaderLastSize={width:null,height:null},this.overlayScrollPositions={master:{top:0,left:0},top:{top:null,left:0},bottom:{top:null,left:0},left:{top:0,left:null}},this.pendingScrollCallbacks={master:{top:0,left:0},top:{left:0},bottom:{left:0},left:{top:0}},this.verticalScrolling=!1,this.horizontalScrolling=!1,this.delegatedScrollCallback=!1,this.registeredListeners=[],this.registerListeners()}return i(e,[{key:"prepareOverlays",value:function(){var e=!1;return this.topOverlay?e=this.topOverlay.updateStateOfRendering()||e:this.topOverlay=f.default.createOverlay(f.default.CLONE_TOP,this.wot),f.default.hasOverlay(f.default.CLONE_BOTTOM)||(this.bottomOverlay={needFullRender:!1,updateStateOfRendering:function(){return!1}}),f.default.hasOverlay(f.default.CLONE_BOTTOM_LEFT_CORNER)||(this.bottomLeftCornerOverlay={needFullRender:!1,updateStateOfRendering:function(){return!1}}),this.bottomOverlay?e=this.bottomOverlay.updateStateOfRendering()||e:this.bottomOverlay=f.default.createOverlay(f.default.CLONE_BOTTOM,this.wot),this.leftOverlay?e=this.leftOverlay.updateStateOfRendering()||e:this.leftOverlay=f.default.createOverlay(f.default.CLONE_LEFT,this.wot),this.topOverlay.needFullRender&&this.leftOverlay.needFullRender&&(this.topLeftCornerOverlay?e=this.topLeftCornerOverlay.updateStateOfRendering()||e:this.topLeftCornerOverlay=f.default.createOverlay(f.default.CLONE_TOP_LEFT_CORNER,this.wot)),this.bottomOverlay.needFullRender&&this.leftOverlay.needFullRender&&(this.bottomLeftCornerOverlay?e=this.bottomLeftCornerOverlay.updateStateOfRendering()||e:this.bottomLeftCornerOverlay=f.default.createOverlay(f.default.CLONE_BOTTOM_LEFT_CORNER,this.wot)),this.wot.getSetting("debug")&&!this.debug&&(this.debug=f.default.createOverlay(f.default.CLONE_DEBUG,this.wot)),e}},{key:"refreshAll",value:function(){if(this.wot.drawn){if(!this.wot.wtTable.holder.parentNode)return void this.destroy();this.wot.draw(!0),this.verticalScrolling&&this.leftOverlay.onScroll(),this.horizontalScrolling&&this.topOverlay.onScroll(),this.verticalScrolling=!1,this.horizontalScrolling=!1}}},{key:"registerListeners",value:function(){var e=this,t=this.topOverlay.mainTableScrollableElement,o=this.leftOverlay.mainTableScrollableElement,n=[];for(n.push([document.documentElement,"keydown",function(t){return e.onKeyDown(t)}]),n.push([document.documentElement,"keyup",function(){return e.onKeyUp()}]),n.push([document,"visibilitychange",function(){return e.onKeyUp()}]),n.push([t,"scroll",function(t){return e.onTableScroll(t)}]),t!==o&&n.push([o,"scroll",function(t){return e.onTableScroll(t)}]),this.topOverlay.needFullRender&&(n.push([this.topOverlay.clone.wtTable.holder,"scroll",function(t){return e.onTableScroll(t)}]),n.push([this.topOverlay.clone.wtTable.holder,"wheel",function(t){return e.onTableScroll(t)}])),this.bottomOverlay.needFullRender&&(n.push([this.bottomOverlay.clone.wtTable.holder,"scroll",function(t){return e.onTableScroll(t)}]),n.push([this.bottomOverlay.clone.wtTable.holder,"wheel",function(t){return e.onTableScroll(t)}])),this.leftOverlay.needFullRender&&(n.push([this.leftOverlay.clone.wtTable.holder,"scroll",function(t){return e.onTableScroll(t)}]),n.push([this.leftOverlay.clone.wtTable.holder,"wheel",function(t){return e.onTableScroll(t)}])),this.topLeftCornerOverlay&&this.topLeftCornerOverlay.needFullRender&&n.push([this.topLeftCornerOverlay.clone.wtTable.holder,"wheel",function(t){return e.onTableScroll(t)}]),this.bottomLeftCornerOverlay&&this.bottomLeftCornerOverlay.needFullRender&&n.push([this.bottomLeftCornerOverlay.clone.wtTable.holder,"wheel",function(t){return e.onTableScroll(t)}]),this.topOverlay.trimmingContainer!==window&&this.leftOverlay.trimmingContainer!==window&&n.push([window,"wheel",function(t){var o=void 0,n=t.wheelDeltaY||t.deltaY,r=t.wheelDeltaX||t.deltaX;e.topOverlay.clone.wtTable.holder.contains(t.realTarget)?o="top":e.bottomOverlay.clone&&e.bottomOverlay.clone.wtTable.holder.contains(t.realTarget)?o="bottom":e.leftOverlay.clone.wtTable.holder.contains(t.realTarget)?o="left":e.topLeftCornerOverlay&&e.topLeftCornerOverlay.clone&&e.topLeftCornerOverlay.clone.wtTable.holder.contains(t.realTarget)?o="topLeft":e.bottomLeftCornerOverlay&&e.bottomLeftCornerOverlay.clone&&e.bottomLeftCornerOverlay.clone.wtTable.holder.contains(t.realTarget)&&(o="bottomLeft"),("top"==o&&0!==n||"left"==o&&0!==r||"bottom"==o&&0!==n||("topLeft"===o||"bottomLeft"===o)&&(0!==n||0!==r))&&t.preventDefault()}]);n.length;){var r=n.pop();this.eventManager.addEventListener(r[0],r[1],r[2]),this.registeredListeners.push(r)}}},{key:"deregisterListeners",value:function(){for(;this.registeredListeners.length;){var e=this.registeredListeners.pop();this.eventManager.removeEventListener(e[0],e[1],e[2])}}},{key:"onTableScroll",value:function(e){if(!(0,u.isMobileBrowser)()){var t=this.leftOverlay.mainTableScrollableElement,o=this.topOverlay.mainTableScrollableElement,n=e.target;this.keyPressed&&(o!==window&&n!==window&&!e.target.contains(o)||t!==window&&n!==window&&!e.target.contains(t))||("scroll"===e.type?this.syncScrollPositions(e):this.translateMouseWheelToScroll(e))}}},{key:"onKeyDown",value:function(e){this.keyPressed=(0,a.isKey)(e.keyCode,"ARROW_UP|ARROW_RIGHT|ARROW_DOWN|ARROW_LEFT")}},{key:"onKeyUp",value:function(){this.keyPressed=!1}},{key:"translateMouseWheelToScroll",value:function(e){var t=this.topOverlay.clone.wtTable.holder,o=this.bottomOverlay.clone?this.bottomOverlay.clone.wtTable.holder:null,n=this.leftOverlay.clone.wtTable.holder,r=this.topLeftCornerOverlay&&this.topLeftCornerOverlay.clone?this.topLeftCornerOverlay.clone.wtTable.holder:null,i=this.bottomLeftCornerOverlay&&this.bottomLeftCornerOverlay.clone?this.bottomLeftCornerOverlay.clone.wtTable.holder:null,s=e.wheelDeltaY||-1*e.deltaY,l=e.wheelDeltaX||-1*e.deltaX,a=null,u={type:"wheel"},c=e.target,h=null;for(1===e.deltaMode&&(s*=120,l*=120);c!=document&&null!=c;){if(c.className.indexOf("wtHolder")>-1){a=c;break}c=c.parentNode}return u.target=a,a===r||a===i?(this.syncScrollPositions(u,-.2*l,"x"),this.syncScrollPositions(u,-.2*s,"y")):(a===t||a===o?h=s:a===n&&(h=l),this.syncScrollPositions(u,-.2*h)),!1}},{key:"syncScrollPositions",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;if(!this.destroyed){if(0===arguments.length)return void this.syncScrollWithMaster();var n=this.leftOverlay.mainTableScrollableElement,r=this.topOverlay.mainTableScrollableElement,i=e.target,l=0,a=!1,u=void 0,c=void 0,h=void 0,d=void 0,f=void 0,p=!1,g=this.wot.getSetting("preventOverflow");this.topOverlay.needFullRender&&(u=this.topOverlay.clone.wtTable.holder),this.bottomOverlay.needFullRender&&(f=this.bottomOverlay.clone.wtTable.holder),this.leftOverlay.needFullRender&&(c=this.leftOverlay.clone.wtTable.holder),this.leftOverlay.needFullRender&&this.topOverlay.needFullRender&&(h=this.topLeftCornerOverlay.clone.wtTable.holder),this.leftOverlay.needFullRender&&this.bottomOverlay.needFullRender&&(d=this.bottomLeftCornerOverlay.clone.wtTable.holder),i===document&&(i=window),i===n||i===r?(l=(0,s.getScrollLeft)(g?this.scrollableElement:i),this.horizontalScrolling=!0,this.overlayScrollPositions.master.left=l,a=!0,this.pendingScrollCallbacks.master.left>0?this.pendingScrollCallbacks.master.left--:(u&&u.scrollLeft!==l&&(null==t&&this.pendingScrollCallbacks.top.left++,u.scrollLeft=l,p=n!==window),f&&f.scrollLeft!==l&&(null==t&&this.pendingScrollCallbacks.bottom.left++,f.scrollLeft=l,p=n!==window)),l=(0,s.getScrollTop)(i),this.verticalScrolling=!0,this.overlayScrollPositions.master.top=l,a=!0,this.pendingScrollCallbacks.master.top>0?this.pendingScrollCallbacks.master.top--:c&&c.scrollTop!==l&&(null==t&&this.pendingScrollCallbacks.left.top++,c.scrollTop=l,p=r!==window)):i===f?(l=(0,s.getScrollLeft)(i),this.horizontalScrolling=!0,this.overlayScrollPositions.bottom.left=l,a=!0,this.pendingScrollCallbacks.bottom.left>0?this.pendingScrollCallbacks.bottom.left--:(null==t&&this.pendingScrollCallbacks.master.left++,n.scrollLeft=l,u&&u.scrollLeft!==l&&(null==t&&this.pendingScrollCallbacks.top.left++,u.scrollLeft=l,p=r!==window)),null!==t&&(a=!0,r.scrollTop+=t)):i===u?(l=(0,s.getScrollLeft)(i),this.horizontalScrolling=!0,this.overlayScrollPositions.top.left=l,a=!0,this.pendingScrollCallbacks.top.left>0?this.pendingScrollCallbacks.top.left--:(null==t&&this.pendingScrollCallbacks.master.left++,n.scrollLeft=l),null!==t&&(a=!0,r.scrollTop+=t),f&&f.scrollLeft!==l&&(null==t&&this.pendingScrollCallbacks.bottom.left++,f.scrollLeft=l,p=r!==window)):i===c?(l=(0,s.getScrollTop)(i),this.overlayScrollPositions.left.top!==l&&(this.verticalScrolling=!0,this.overlayScrollPositions.left.top=l,a=!0,this.pendingScrollCallbacks.left.top>0?this.pendingScrollCallbacks.left.top--:(null==t&&this.pendingScrollCallbacks.master.top++,r.scrollTop=l)),null!==t&&(a=!0,r.scrollLeft+=t)):i!==h&&i!==d||null!==t&&(a=!0,"x"===o?r.scrollLeft+=t:"y"===o&&(r.scrollTop+=t)),!this.keyPressed&&a&&"scroll"===e.type&&(this.delegatedScrollCallback?this.delegatedScrollCallback=!1:this.refreshAll(),p&&(this.delegatedScrollCallback=!0))}}},{key:"syncScrollWithMaster",value:function(){var e=this.topOverlay.mainTableScrollableElement,t=e.scrollLeft,o=e.scrollTop;this.topOverlay.needFullRender&&(this.topOverlay.clone.wtTable.holder.scrollLeft=t),this.bottomOverlay.needFullRender&&(this.bottomOverlay.clone.wtTable.holder.scrollLeft=t),this.leftOverlay.needFullRender&&(this.leftOverlay.clone.wtTable.holder.scrollTop=o)}},{key:"updateMainScrollableElements",value:function(){this.deregisterListeners(),this.leftOverlay.updateMainScrollableElement(),this.topOverlay.updateMainScrollableElement(),this.bottomOverlay.needFullRender&&this.bottomOverlay.updateMainScrollableElement(),this.scrollableElement=(0,s.getScrollableElement)(this.wot.wtTable.TABLE),this.registerListeners()}},{key:"destroy",value:function(){this.eventManager.destroy(),this.topOverlay.destroy(),this.bottomOverlay.clone&&this.bottomOverlay.destroy(),this.leftOverlay.destroy(),this.topLeftCornerOverlay&&this.topLeftCornerOverlay.destroy(),this.bottomLeftCornerOverlay&&this.bottomLeftCornerOverlay.clone&&this.bottomLeftCornerOverlay.destroy(),this.debug&&this.debug.destroy(),this.destroyed=!0}},{key:"refresh",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(this.topOverlay.areElementSizesAdjusted&&this.leftOverlay.areElementSizesAdjusted){var t=this.wot.wtTable.wtRootElement.parentNode||this.wot.wtTable.wtRootElement,o=t.clientWidth,n=t.clientHeight;o===this.spreaderLastSize.width&&n===this.spreaderLastSize.height||(this.spreaderLastSize.width=o,this.spreaderLastSize.height=n,this.adjustElementsSize())}this.bottomOverlay.clone&&this.bottomOverlay.refresh(e),this.leftOverlay.refresh(e),this.topOverlay.refresh(e),this.topLeftCornerOverlay&&this.topLeftCornerOverlay.refresh(e),this.bottomLeftCornerOverlay&&this.bottomLeftCornerOverlay.clone&&this.bottomLeftCornerOverlay.refresh(e),this.debug&&this.debug.refresh(e)}},{key:"adjustElementsSize",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=this.wot.getSetting("totalColumns"),o=this.wot.getSetting("totalRows"),n=this.wot.wtViewport.getRowHeaderWidth(),r=this.wot.wtViewport.getColumnHeaderHeight(),i=this.wot.wtTable.hider.style;i.width=n+this.leftOverlay.sumCellSizes(0,t)+"px",i.height=r+this.topOverlay.sumCellSizes(0,o)+1+"px",this.topOverlay.adjustElementsSize(e),this.leftOverlay.adjustElementsSize(e),this.bottomOverlay.clone&&this.bottomOverlay.adjustElementsSize(e)}},{key:"applyToDOM",value:function(){this.topOverlay.areElementSizesAdjusted&&this.leftOverlay.areElementSizesAdjusted||this.adjustElementsSize(),this.topOverlay.applyToDOM(),this.bottomOverlay.clone&&this.bottomOverlay.applyToDOM(),this.leftOverlay.applyToDOM()}},{key:"getParentOverlay",value:function(e){if(!e)return null;var t=[this.topOverlay,this.leftOverlay,this.bottomOverlay,this.topLeftCornerOverlay,this.bottomLeftCornerOverlay],o=null;return(0,l.arrayEach)(t,function(t,n){t&&t.clone&&t.clone.wtTable.TABLE.contains(e)&&(o=t.clone)}),o}}]),e}()},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=o(0),s=o(6);t.default=function(){function e(t){n(this,e),this.wot=t,this.instance=t}return r(e,[{key:"scrollViewport",value:function(e){if(this.wot.drawn){var t=this._getVariables(),o=t.topOverlay,n=t.leftOverlay,r=t.totalRows,i=t.totalColumns,s=t.fixedRowsTop,l=t.fixedRowsBottom,a=t.fixedColumnsLeft;if(0>e.row||e.row>Math.max(r-1,0))throw Error("row "+e.row+" does not exist");if(0>e.col||e.col>Math.max(i-1,0))throw Error("column "+e.col+" does not exist");e.row>=s&&e.row<this.getFirstVisibleRow()?o.scrollTo(e.row):e.row>this.getLastVisibleRow()&&r-l>e.row&&o.scrollTo(e.row,!0),e.col>=a&&e.col<this.getFirstVisibleColumn()?n.scrollTo(e.col):e.col>this.getLastVisibleColumn()&&n.scrollTo(e.col,!0)}}},{key:"getFirstVisibleRow",value:function(){var e=this._getVariables(),t=e.topOverlay,o=e.wtTable,n=e.wtViewport,r=e.totalRows,l=e.fixedRowsTop,a=o.getFirstVisibleRow();if(t.mainTableScrollableElement===window){var u=(0,i.offset)(o.wtRootElement),c=(0,i.innerHeight)(o.hider),h=(0,i.innerHeight)(window),d=(0,i.getScrollTop)(window);if(d>=u.top+c-h){var f=n.getColumnHeaderHeight();f+=t.sumCellSizes(0,l),(0,s.rangeEachReverse)(r,1,function(e){if(f+=t.sumCellSizes(e-1,e),d>=u.top+c-f)return a=e,!1})}}return a}},{key:"getLastVisibleRow",value:function(){var e=this._getVariables(),t=e.topOverlay,o=e.wtTable,n=e.wtViewport,r=e.totalRows,l=o.getLastVisibleRow();if(t.mainTableScrollableElement===window){var a=(0,i.offset)(o.wtRootElement),u=(0,i.innerHeight)(window),c=(0,i.getScrollTop)(window);if(a.top>c){var h=n.getColumnHeaderHeight();(0,s.rangeEach)(1,r,function(e){if(h+=t.sumCellSizes(e-1,e),a.top+h-c>=u)return l=e-2,!1})}}return l}},{key:"getFirstVisibleColumn",value:function(){var e=this._getVariables(),t=e.leftOverlay,o=e.wtTable,n=e.wtViewport,r=e.totalColumns,l=o.getFirstVisibleColumn();if(t.mainTableScrollableElement===window){var a=(0,i.offset)(o.wtRootElement),u=(0,i.innerWidth)(o.hider),c=(0,i.innerWidth)(window),h=(0,i.getScrollLeft)(window);if(h>=a.left+u-c){var d=n.getRowHeaderWidth();(0,s.rangeEachReverse)(r,1,function(e){if(d+=t.sumCellSizes(e-1,e),h>=a.left+u-d)return l=e,!1})}}return l}},{key:"getLastVisibleColumn",value:function(){var e=this._getVariables(),t=e.leftOverlay,o=e.wtTable,n=e.wtViewport,r=e.totalColumns,l=o.getLastVisibleColumn();if(t.mainTableScrollableElement===window){var a=(0,i.offset)(o.wtRootElement),u=(0,i.innerWidth)(window),c=(0,i.getScrollLeft)(window);if(a.left>c){var h=n.getRowHeaderWidth();(0,s.rangeEach)(1,r,function(e){if(h+=t.sumCellSizes(e-1,e),a.left+h-c>=u)return l=e-2,!1})}}return l}},{key:"_getVariables",value:function(){var e=this.wot;return{topOverlay:e.wtOverlays.topOverlay,leftOverlay:e.wtOverlays.leftOverlay,wtTable:e.wtTable,wtViewport:e.wtViewport,totalRows:e.getSetting("totalRows"),totalColumns:e.getSetting("totalColumns"),fixedRowsTop:e.getSetting("fixedRowsTop"),fixedRowsBottom:e.getSetting("fixedRowsBottom"),fixedColumnsLeft:e.getSetting("fixedColumnsLeft")}}}]),e}()},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=o(0),s=o(1);t.default=function(){function e(t,o){var r=this;n(this,e),this.wot=t,this.instance=t,this.defaults={table:void 0,debug:!1,externalRowCalculator:!1,stretchH:"none",currentRowClassName:null,currentColumnClassName:null,preventOverflow:function(){return!1},data:void 0,freezeOverlays:!1,fixedColumnsLeft:0,fixedRowsTop:0,fixedRowsBottom:0,minSpareRows:0,rowHeaders:function(){return[]},columnHeaders:function(){return[]},totalRows:void 0,totalColumns:void 0,cellRenderer:function(e,t,o){var n=r.getSetting("data",e,t);(0,i.fastInnerText)(o,void 0===n||null===n?"":n)},columnWidth:function(e){},rowHeight:function(e){},defaultRowHeight:23,defaultColumnWidth:50,selections:null,hideBorderOnMouseDownOver:!1,viewportRowCalculatorOverride:null,viewportColumnCalculatorOverride:null,onCellMouseDown:null,onCellMouseOver:null,onCellMouseOut:null,onCellMouseUp:null,onCellDblClick:null,onCellCornerMouseDown:null,onCellCornerDblClick:null,beforeDraw:null,onDraw:null,onBeforeDrawBorders:null,onScrollVertically:null,onScrollHorizontally:null,onBeforeTouchScroll:null,onAfterMomentumScroll:null,onBeforeStretchingColumnWidth:function(e){return e},onModifyRowHeaderWidth:null,scrollbarWidth:10,scrollbarHeight:10,renderAllRows:!1,groups:!1,rowHeaderWidth:null,columnHeaderHeight:null,headerClassName:null},this.settings={};for(var l in this.defaults)if((0,s.hasOwnProperty)(this.defaults,l))if(void 0!==o[l])this.settings[l]=o[l];else{if(void 0===this.defaults[l])throw Error('A required setting "'+l+'" was not provided');this.settings[l]=this.defaults[l]}}return r(e,[{key:"update",value:function(e,t){if(void 0===t)for(var o in e)(0,s.hasOwnProperty)(e,o)&&(this.settings[o]=e[o]);else this.settings[e]=t;return this.wot}},{key:"getSetting",value:function(e,t,o,n,r){return"function"==typeof this.settings[e]?this.settings[e](t,o,n,r):void 0!==t&&Array.isArray(this.settings[e])?this.settings[e][t]:this.settings[e]}},{key:"has",value:function(e){return!!this.settings[e]}}]),e}()},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e){if(Array.isArray(e)){for(var t=0,o=Array(e.length);e.length>t;t++)o[t]=e[t];return o}return Array.from(e)}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},l=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),a=o(0),u=o(35),c=o(49),h=n(c),d=o(79),f=(n(d),o(157)),p=n(f),g=o(158),v=n(g),m=o(165),y=n(m),w=o(31),C=n(w);t.default=function(){function e(t,o){var n=this;i(this,e),this.wot=t,this.instance=this.wot,this.TABLE=o,this.TBODY=null,this.THEAD=null,this.COLGROUP=null,this.tableOffset=0,this.holderOffset=0,(0,a.removeTextNodes)(this.TABLE),this.spreader=this.createSpreader(this.TABLE),this.hider=this.createHider(this.spreader),this.holder=this.createHolder(this.hider),this.wtRootElement=this.holder.parentNode,this.alignOverlaysWithTrimmingContainer(),this.fixTableDomTree(),this.colgroupChildrenLength=this.COLGROUP.childNodes.length,this.theadChildrenLength=this.THEAD.firstChild?this.THEAD.firstChild.childNodes.length:0,this.tbodyChildrenLength=this.TBODY.childNodes.length,this.rowFilter=null,this.columnFilter=null,this.correctHeaderWidth=!1;var r=this.wot.wtSettings.settings.rowHeaderWidth;this.wot.wtSettings.settings.rowHeaderWidth=function(){return n._modifyRowHeaderWidth(r)}}return l(e,[{key:"fixTableDomTree",value:function(){this.TBODY=this.TABLE.querySelector("tbody"),this.TBODY||(this.TBODY=document.createElement("tbody"),this.TABLE.appendChild(this.TBODY)),this.THEAD=this.TABLE.querySelector("thead"),this.THEAD||(this.THEAD=document.createElement("thead"),this.TABLE.insertBefore(this.THEAD,this.TBODY)),this.COLGROUP=this.TABLE.querySelector("colgroup"),this.COLGROUP||(this.COLGROUP=document.createElement("colgroup"),this.TABLE.insertBefore(this.COLGROUP,this.THEAD)),this.wot.getSetting("columnHeaders").length&&!this.THEAD.childNodes.length&&this.THEAD.appendChild(document.createElement("TR"))}},{key:"createSpreader",value:function(e){var t=e.parentNode,o=void 0;return t&&1===t.nodeType&&(0,a.hasClass)(t,"wtHolder")||(o=document.createElement("div"),o.className="wtSpreader",t&&t.insertBefore(o,e),o.appendChild(e)),o.style.position="relative",o}},{key:"createHider",value:function(e){var t=e.parentNode,o=void 0;return t&&1===t.nodeType&&(0,a.hasClass)(t,"wtHolder")||(o=document.createElement("div"),o.className="wtHider",t&&t.insertBefore(o,e),o.appendChild(e)),o}},{key:"createHolder",value:function(e){var t=e.parentNode,o=void 0;return t&&1===t.nodeType&&(0,a.hasClass)(t,"wtHolder")||(o=document.createElement("div"),o.style.position="relative",o.className="wtHolder",t&&t.insertBefore(o,e),this.isWorkingOnClone()||(o.parentNode.className+="ht_master handsontable"),o.appendChild(e)),o}},{key:"alignOverlaysWithTrimmingContainer",value:function(){var e=(0,a.getTrimmingContainer)(this.wtRootElement);if(!this.isWorkingOnClone())if(this.holder.parentNode.style.position="relative",e===window){var t=this.wot.getSetting("preventOverflow");t||(this.holder.style.overflow="visible",this.wtRootElement.style.overflow="visible")}else this.holder.style.width=(0,a.getStyle)(e,"width"),this.holder.style.height=(0,a.getStyle)(e,"height"),this.holder.style.overflow=""}},{key:"isWorkingOnClone",value:function(){return!!this.wot.cloneSource}},{key:"draw",value:function(e){var t=this.wot,o=t.wtOverlays,n=t.wtViewport,r=this.instance.getSetting("totalRows"),i=this.wot.getSetting("rowHeaders").length,s=this.wot.getSetting("columnHeaders").length,l=!1;if(!this.isWorkingOnClone()&&(this.holderOffset=(0,a.offset)(this.holder),e=n.createRenderCalculators(e),i&&!this.wot.getSetting("fixedColumnsLeft"))){var u=o.leftOverlay.getScrollPosition(),c=this.correctHeaderWidth;this.correctHeaderWidth=u>0,c!==this.correctHeaderWidth&&(e=!1)}if(this.isWorkingOnClone()||(l=o.prepareOverlays()),e)this.isWorkingOnClone()||n.createVisibleCalculators(),o&&o.refresh(!0);else{this.tableOffset=this.isWorkingOnClone()?this.wot.cloneSource.wtTable.tableOffset:(0,a.offset)(this.TABLE);var h=void 0;h=C.default.isOverlayTypeOf(this.wot.cloneOverlay,C.default.CLONE_DEBUG)||C.default.isOverlayTypeOf(this.wot.cloneOverlay,C.default.CLONE_TOP)||C.default.isOverlayTypeOf(this.wot.cloneOverlay,C.default.CLONE_TOP_LEFT_CORNER)?0:C.default.isOverlayTypeOf(this.instance.cloneOverlay,C.default.CLONE_BOTTOM)||C.default.isOverlayTypeOf(this.instance.cloneOverlay,C.default.CLONE_BOTTOM_LEFT_CORNER)?Math.max(r-this.wot.getSetting("fixedRowsBottom"),0):n.rowsRenderCalculator.startRow;var d=void 0;d=C.default.isOverlayTypeOf(this.wot.cloneOverlay,C.default.CLONE_DEBUG)||C.default.isOverlayTypeOf(this.wot.cloneOverlay,C.default.CLONE_LEFT)||C.default.isOverlayTypeOf(this.wot.cloneOverlay,C.default.CLONE_TOP_LEFT_CORNER)||C.default.isOverlayTypeOf(this.wot.cloneOverlay,C.default.CLONE_BOTTOM_LEFT_CORNER)?0:n.columnsRenderCalculator.startColumn,this.rowFilter=new v.default(h,r,s),this.columnFilter=new p.default(d,this.wot.getSetting("totalColumns"),i),this.alignOverlaysWithTrimmingContainer(),this._doDraw()}return this.refreshSelections(e),this.isWorkingOnClone()||(o.topOverlay.resetFixedPosition(),o.bottomOverlay.clone&&o.bottomOverlay.resetFixedPosition(),o.leftOverlay.resetFixedPosition(),o.topLeftCornerOverlay&&o.topLeftCornerOverlay.resetFixedPosition(),o.bottomLeftCornerOverlay&&o.bottomLeftCornerOverlay.clone&&o.bottomLeftCornerOverlay.resetFixedPosition()),l&&o.syncScrollWithMaster(),this.wot.drawn=!0,this}},{key:"_doDraw",value:function(){new y.default(this).render()}},{key:"removeClassFromCells",value:function(e){for(var t=this.TABLE.querySelectorAll("."+e),o=0,n=t.length;n>o;o++)(0,a.removeClass)(t[o],e)}},{key:"refreshSelections",value:function(e){if(this.wot.selections){var t=this.wot.selections.length;if(e)for(var o=0;t>o;o++)this.wot.selections[o].settings.className&&this.removeClassFromCells(this.wot.selections[o].settings.className),this.wot.selections[o].settings.highlightHeaderClassName&&this.removeClassFromCells(this.wot.selections[o].settings.highlightHeaderClassName),this.wot.selections[o].settings.highlightRowClassName&&this.removeClassFromCells(this.wot.selections[o].settings.highlightRowClassName),this.wot.selections[o].settings.highlightColumnClassName&&this.removeClassFromCells(this.wot.selections[o].settings.highlightColumnClassName);for(var n=0;t>n;n++)this.wot.selections[n].draw(this.wot,e)}}},{key:"getCell",value:function(e){if(this.isRowBeforeRenderedRows(e.row))return-1;if(this.isRowAfterRenderedRows(e.row))return-2;var t=this.TBODY.childNodes[this.rowFilter.sourceToRendered(e.row)];return t?t.childNodes[this.columnFilter.sourceColumnToVisibleRowHeadedColumn(e.col)]:void 0}},{key:"getColumnHeader",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,o=this.THEAD.childNodes[t];if(o)return o.childNodes[this.columnFilter.sourceColumnToVisibleRowHeadedColumn(e)]}},{key:"getRowHeader",value:function(e){if(0===this.columnFilter.sourceColumnToVisibleRowHeadedColumn(0))return null;var t=this.TBODY.childNodes[this.rowFilter.sourceToRendered(e)];return t?t.childNodes[0]:void 0}},{key:"getCoords",value:function(e){if("TD"!==e.nodeName&&"TH"!==e.nodeName&&(e=(0,a.closest)(e,["TD","TH"])),null===e)return null;var t=e.parentNode,o=t.parentNode,n=(0,a.index)(t),r=e.cellIndex;return(0,a.overlayContainsElement)(C.default.CLONE_TOP_LEFT_CORNER,e)||(0,a.overlayContainsElement)(C.default.CLONE_TOP,e)?"THEAD"===o.nodeName&&(n-=o.childNodes.length):n=o===this.THEAD?this.rowFilter.visibleColHeadedRowToSourceRow(n):this.rowFilter.renderedToSource(n),r=(0,a.overlayContainsElement)(C.default.CLONE_TOP_LEFT_CORNER,e)||(0,a.overlayContainsElement)(C.default.CLONE_LEFT,e)?this.columnFilter.offsettedTH(r):this.columnFilter.visibleRowHeadedColumnToSourceColumn(r),new h.default(n,r)}},{key:"getTrForRow",value:function(e){return this.TBODY.childNodes[this.rowFilter.sourceToRendered(e)]}},{key:"getFirstRenderedRow",value:function(){return this.wot.wtViewport.rowsRenderCalculator.startRow}},{key:"getFirstVisibleRow",value:function(){return this.wot.wtViewport.rowsVisibleCalculator.startRow}},{key:"getFirstRenderedColumn",value:function(){return this.wot.wtViewport.columnsRenderCalculator.startColumn}},{key:"getFirstVisibleColumn",value:function(){return this.wot.wtViewport.columnsVisibleCalculator.startColumn}},{key:"getLastRenderedRow",value:function(){return this.wot.wtViewport.rowsRenderCalculator.endRow}},{key:"getLastVisibleRow",value:function(){return this.wot.wtViewport.rowsVisibleCalculator.endRow}},{key:"getLastRenderedColumn",value:function(){return this.wot.wtViewport.columnsRenderCalculator.endColumn}},{key:"getLastVisibleColumn",value:function(){return this.wot.wtViewport.columnsVisibleCalculator.endColumn}},{key:"isRowBeforeRenderedRows",value:function(e){return this.rowFilter&&0>this.rowFilter.sourceToRendered(e)&&e>=0}},{key:"isRowAfterViewport",value:function(e){return this.rowFilter&&this.rowFilter.sourceToRendered(e)>this.getLastVisibleRow()}},{key:"isRowAfterRenderedRows",value:function(e){return this.rowFilter&&this.rowFilter.sourceToRendered(e)>this.getLastRenderedRow()}},{key:"isColumnBeforeViewport",value:function(e){return this.columnFilter&&0>this.columnFilter.sourceToRendered(e)&&e>=0}},{key:"isColumnAfterViewport",value:function(e){return this.columnFilter&&this.columnFilter.sourceToRendered(e)>this.getLastVisibleColumn()}},{key:"isLastRowFullyVisible",value:function(){return this.getLastVisibleRow()===this.getLastRenderedRow()}},{key:"isLastColumnFullyVisible",value:function(){return this.getLastVisibleColumn()===this.getLastRenderedColumn()}},{key:"getRenderedColumnsCount",value:function(){var e=this.wot.wtViewport.columnsRenderCalculator.count,t=this.wot.getSetting("totalColumns");if(this.wot.isOverlayName(C.default.CLONE_DEBUG))e=t;else if(this.wot.isOverlayName(C.default.CLONE_LEFT)||this.wot.isOverlayName(C.default.CLONE_TOP_LEFT_CORNER)||this.wot.isOverlayName(C.default.CLONE_BOTTOM_LEFT_CORNER))return Math.min(this.wot.getSetting("fixedColumnsLeft"),t);return e}},{key:"getRenderedRowsCount",value:function(){var e=this.wot.wtViewport.rowsRenderCalculator.count,t=this.wot.getSetting("totalRows");return this.wot.isOverlayName(C.default.CLONE_DEBUG)?e=t:this.wot.isOverlayName(C.default.CLONE_TOP)||this.wot.isOverlayName(C.default.CLONE_TOP_LEFT_CORNER)?e=Math.min(this.wot.getSetting("fixedRowsTop"),t):(this.wot.isOverlayName(C.default.CLONE_BOTTOM)||this.wot.isOverlayName(C.default.CLONE_BOTTOM_LEFT_CORNER))&&(e=Math.min(this.wot.getSetting("fixedRowsBottom"),t)),e}},{key:"getVisibleRowsCount",value:function(){return this.wot.wtViewport.rowsVisibleCalculator.count}},{key:"allRowsInViewport",value:function(){return this.wot.getSetting("totalRows")==this.getVisibleRowsCount()}},{key:"getRowHeight",value:function(e){var t=this.wot.wtSettings.settings.rowHeight(e),o=this.wot.wtViewport.oversizedRows[e];return void 0!==o&&(t=void 0===t?o:Math.max(t,o)),t}},{key:"getColumnHeaderHeight",value:function(e){var t=this.wot.wtSettings.settings.defaultRowHeight,o=this.wot.wtViewport.oversizedColumnHeaders[e];return void 0!==o&&(t=t?Math.max(t,o):o),t}},{key:"getVisibleColumnsCount",value:function(){return this.wot.wtViewport.columnsVisibleCalculator.count}},{key:"allColumnsInViewport",value:function(){return this.wot.getSetting("totalColumns")==this.getVisibleColumnsCount()}},{key:"getColumnWidth",value:function(e){var t=this.wot.wtSettings.settings.columnWidth;return"function"==typeof t?t=t(e):"object"===(void 0===t?"undefined":s(t))&&(t=t[e]),t||this.wot.wtSettings.settings.defaultColumnWidth}},{key:"getStretchedColumnWidth",value:function(e){var t=this.getColumnWidth(e),o=null==t?this.instance.wtSettings.settings.defaultColumnWidth:t,n=this.wot.wtViewport.columnsRenderCalculator;if(n){var r=n.getStretchedColumnWidth(e,o);r&&(o=r)}return o}},{key:"_modifyRowHeaderWidth",value:function(e){var t=(0,u.isFunction)(e)?e():null;return Array.isArray(t)?(t=[].concat(r(t)),t[t.length-1]=this._correctRowHeaderWidth(t[t.length-1])):t=this._correctRowHeaderWidth(t),t}},{key:"_correctRowHeaderWidth",value:function(e){return"number"!=typeof e&&(e=this.wot.getSetting("defaultColumnWidth")),this.correctHeaderWidth&&e++,e}}]),e}()},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){var o=document.createElement("TH");return t.insertBefore(o,e),t.removeChild(e),o}function i(e,t){var o=document.createElement("TD");return t.insertBefore(o,e),t.removeChild(e),o}t.__esModule=!0;var s=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),l=o(0),a=o(31),u=function(e){return e&&e.__esModule?e:{default:e}}(a),c=!1;t.default=function(){function e(t){n(this,e),this.wtTable=t,this.wot=t.instance,this.instance=t.instance,this.rowFilter=t.rowFilter,this.columnFilter=t.columnFilter,this.TABLE=t.TABLE,this.THEAD=t.THEAD,this.TBODY=t.TBODY,this.COLGROUP=t.COLGROUP,this.rowHeaders=[],this.rowHeaderCount=0,this.columnHeaders=[],this.columnHeaderCount=0,this.fixedRowsTop=0,this.fixedRowsBottom=0}return s(e,[{key:"render",value:function(){if(!this.wtTable.isWorkingOnClone()){var e={};if(this.wot.getSetting("beforeDraw",!0,e),!0===e.skipRender)return}this.rowHeaders=this.wot.getSetting("rowHeaders"),this.rowHeaderCount=this.rowHeaders.length,this.fixedRowsTop=this.wot.getSetting("fixedRowsTop"),this.fixedRowsBottom=this.wot.getSetting("fixedRowsBottom"),this.columnHeaders=this.wot.getSetting("columnHeaders"),this.columnHeaderCount=this.columnHeaders.length;var t=this.wtTable.getRenderedColumnsCount(),o=this.wtTable.getRenderedRowsCount(),n=this.wot.getSetting("totalColumns"),r=this.wot.getSetting("totalRows"),i=void 0,s=!1;if((u.default.isOverlayTypeOf(this.wot.cloneOverlay,u.default.CLONE_BOTTOM)||u.default.isOverlayTypeOf(this.wot.cloneOverlay,u.default.CLONE_BOTTOM_LEFT_CORNER))&&(this.columnHeaders=[],this.columnHeaderCount=0),0>n||(this.adjustAvailableNodes(),s=!0,this.renderColumnHeaders(),this.renderRows(r,o,t),this.wtTable.isWorkingOnClone()||(i=this.wot.wtViewport.getWorkspaceWidth(),this.wot.wtViewport.containerWidth=null),this.adjustColumnWidths(t),this.markOversizedColumnHeaders(),this.adjustColumnHeaderHeights()),s||this.adjustAvailableNodes(),this.removeRedundantRows(o),this.wtTable.isWorkingOnClone()&&!this.wot.isOverlayName(u.default.CLONE_BOTTOM)||this.markOversizedRows(),this.wtTable.isWorkingOnClone())this.wot.isOverlayName(u.default.CLONE_BOTTOM)&&this.wot.cloneSource.wtOverlays.adjustElementsSize();else{this.wot.wtViewport.createVisibleCalculators(),this.wot.wtOverlays.refresh(!1),this.wot.wtOverlays.applyToDOM();var a=(0,l.outerWidth)(this.wtTable.hider),c=(0,l.outerWidth)(this.wtTable.TABLE);if(0!==a&&c!==a&&this.adjustColumnWidths(t),i!==this.wot.wtViewport.getWorkspaceWidth()){this.wot.wtViewport.containerWidth=null;var h=this.wtTable.getFirstRenderedColumn(),d=this.wtTable.getLastRenderedColumn(),f=this.wot.getSetting("defaultColumnWidth"),p=this.wot.getSetting("rowHeaderWidth");if(null!=(p=this.instance.getSetting("onModifyRowHeaderWidth",p)))for(var g=0;this.rowHeaderCount>g;g++){var v=Array.isArray(p)?p[g]:p;v=null==v?f:v,this.COLGROUP.childNodes[g].style.width=v+"px"}for(var m=h;d>m;m++){var y=this.wtTable.getStretchedColumnWidth(m);this.COLGROUP.childNodes[this.columnFilter.sourceToRendered(m)+this.rowHeaderCount].style.width=y+"px"}}this.wot.getSetting("onDraw",!0)}}},{key:"removeRedundantRows",value:function(e){for(;this.wtTable.tbodyChildrenLength>e;)this.TBODY.removeChild(this.TBODY.lastChild),this.wtTable.tbodyChildrenLength--}},{key:"renderRows",value:function(e,t,o){for(var n=void 0,r=0,i=this.rowFilter.renderedToSource(r),s=this.wtTable.isWorkingOnClone();e>i&&i>=0&&(!c&&r>1e3&&(c=!0,console.warn('Performance tip: Handsontable rendered more than 1000 visible rows. Consider limiting the number of rendered rows by specifying the table height and/or turning off the "renderAllRows" option.')),void 0===t||r!==t);){if(n=this.getOrCreateTrForRow(r,n),this.renderRowHeaders(i,n),this.adjustColumns(n,o+this.rowHeaderCount),this.renderCells(i,n,o),s&&!this.wot.isOverlayName(u.default.CLONE_BOTTOM)||this.resetOversizedRow(i),n.firstChild){var l=this.wot.wtTable.getRowHeight(i);l?(l--,n.firstChild.style.height=l+"px"):n.firstChild.style.height=""}r++,i=this.rowFilter.renderedToSource(r)}}},{key:"resetOversizedRow",value:function(e){this.wot.getSetting("externalRowCalculator")||this.wot.wtViewport.oversizedRows&&this.wot.wtViewport.oversizedRows[e]&&(this.wot.wtViewport.oversizedRows[e]=void 0)}},{key:"markOversizedRows",value:function(){if(!this.wot.getSetting("externalRowCalculator")){var e=this.instance.wtTable.TBODY.childNodes.length,t=e*this.instance.wtSettings.settings.defaultRowHeight,o=(0,l.innerHeight)(this.instance.wtTable.TBODY)-1,n=void 0,r=void 0,i=void 0,s=void 0,a=void 0;this.instance.getSetting("totalRows");if(t!==o||this.instance.getSetting("fixedRowsBottom"))for(;e;)e--,i=this.instance.wtTable.rowFilter.renderedToSource(e),n=this.instance.wtTable.getRowHeight(i),s=this.instance.wtTable.getTrForRow(i),a=s.querySelector("th"),r=a?(0,l.innerHeight)(a):(0,l.innerHeight)(s)-1,(!n&&r>this.instance.wtSettings.settings.defaultRowHeight||r>n)&&(this.instance.wtViewport.oversizedRows[i]=++r)}}},{key:"markOversizedColumnHeaders",value:function(){var e=this.wot.getOverlayName();if(this.columnHeaderCount&&!this.wot.wtViewport.hasOversizedColumnHeadersMarked[e]&&!this.wtTable.isWorkingOnClone()){for(var t=this.wtTable.getRenderedColumnsCount(),o=0;this.columnHeaderCount>o;o++)for(var n=-1*this.rowHeaderCount;t>n;n++)this.markIfOversizedColumnHeader(n);this.wot.wtViewport.hasOversizedColumnHeadersMarked[e]=!0}}},{key:"adjustColumnHeaderHeights",value:function(){for(var e=this.wot.getSetting("columnHeaders"),t=this.wot.wtTable.THEAD.childNodes,o=this.wot.wtViewport.oversizedColumnHeaders,n=0,r=e.length;r>n;n++)if(o[n]){if(!t[n]||0===t[n].childNodes.length)return;t[n].childNodes[0].style.height=o[n]+"px"}}},{key:"markIfOversizedColumnHeader",value:function(e){for(var t=this.wot.wtTable.columnFilter.renderedToSource(e),o=this.columnHeaderCount,n=this.wot.wtSettings.settings.defaultRowHeight,r=void 0,i=void 0,s=void 0,a=this.wot.getSetting("columnHeaderHeight")||[];o;)o--,r=this.wot.wtTable.getColumnHeaderHeight(o),(i=this.wot.wtTable.getColumnHeader(t,o))&&(s=(0,l.innerHeight)(i),(!r&&s>n||s>r)&&(this.wot.wtViewport.oversizedColumnHeaders[o]=s),Array.isArray(a)?null!=a[o]&&(this.wot.wtViewport.oversizedColumnHeaders[o]=a[o]):isNaN(a)||(this.wot.wtViewport.oversizedColumnHeaders[o]=a),(a[o]||a)>this.wot.wtViewport.oversizedColumnHeaders[o]&&(this.wot.wtViewport.oversizedColumnHeaders[o]=a[o]||a))}},{key:"renderCells",value:function(e,t,o){for(var n=void 0,r=void 0,s=0;o>s;s++)r=this.columnFilter.renderedToSource(s),n=0===s?t.childNodes[this.columnFilter.sourceColumnToVisibleRowHeadedColumn(r)]:n.nextSibling,"TH"==n.nodeName&&(n=i(n,t)),(0,l.hasClass)(n,"hide")||(n.className=""),n.removeAttribute("style"),this.wot.wtSettings.settings.cellRenderer(e,r,n);return n}},{key:"adjustColumnWidths",value:function(e){var t=0,o=this.wot.cloneSource?this.wot.cloneSource:this.wot,n=o.wtTable.holder,r=this.wot.getSetting("defaultColumnWidth"),i=this.wot.getSetting("rowHeaderWidth");if(n.scrollHeight>n.offsetHeight&&(t=(0,l.getScrollbarWidth)()),this.wot.wtViewport.columnsRenderCalculator.refreshStretching(this.wot.wtViewport.getViewportWidth()-t),null!=(i=this.instance.getSetting("onModifyRowHeaderWidth",i)))for(var s=0;this.rowHeaderCount>s;s++){var a=Array.isArray(i)?i[s]:i;a=null==a?r:a,this.COLGROUP.childNodes[s].style.width=a+"px"}for(var u=0;e>u;u++){this.COLGROUP.childNodes[u+this.rowHeaderCount].style.width=this.wtTable.getStretchedColumnWidth(this.columnFilter.renderedToSource(u))+"px"}}},{key:"appendToTbody",value:function(e){this.TBODY.appendChild(e),this.wtTable.tbodyChildrenLength++}},{key:"getOrCreateTrForRow",value:function(e,t){var o=void 0;return this.wtTable.tbodyChildrenLength>e?o=0===e?this.TBODY.firstChild:t.nextSibling:(o=this.createRow(),this.appendToTbody(o)),o.className&&o.removeAttribute("class"),o}},{key:"createRow",value:function(){for(var e=document.createElement("TR"),t=0;this.rowHeaderCount>t;t++)e.appendChild(document.createElement("TH"));return e}},{key:"renderRowHeader",value:function(e,t,o){o.className="",o.removeAttribute("style"),this.rowHeaders[t](e,o,t)}},{key:"renderRowHeaders",value:function(e,t){for(var o=t.firstChild,n=0;this.rowHeaderCount>n;n++)o?"TD"==o.nodeName&&(o=r(o,t)):(o=document.createElement("TH"),t.appendChild(o)),this.renderRowHeader(e,n,o),o=o.nextSibling}},{key:"adjustAvailableNodes",value:function(){this.adjustColGroups(),this.adjustThead()}},{key:"renderColumnHeaders",value:function(){if(this.columnHeaderCount)for(var e=this.wtTable.getRenderedColumnsCount(),t=0;this.columnHeaderCount>t;t++)for(var o=this.getTrForColumnHeaders(t),n=-1*this.rowHeaderCount;e>n;n++){var r=this.columnFilter.renderedToSource(n);this.renderColumnHeader(t,r,o.childNodes[n+this.rowHeaderCount])}}},{key:"adjustColGroups",value:function(){for(var e=this.wtTable.getRenderedColumnsCount();e+this.rowHeaderCount>this.wtTable.colgroupChildrenLength;)this.COLGROUP.appendChild(document.createElement("COL")),this.wtTable.colgroupChildrenLength++;for(;this.wtTable.colgroupChildrenLength>e+this.rowHeaderCount;)this.COLGROUP.removeChild(this.COLGROUP.lastChild),this.wtTable.colgroupChildrenLength--;this.rowHeaderCount&&(0,l.addClass)(this.COLGROUP.childNodes[0],"rowHeader")}},{key:"adjustThead",value:function(){var e=this.wtTable.getRenderedColumnsCount(),t=this.THEAD.firstChild;if(this.columnHeaders.length){for(var o=0,n=this.columnHeaders.length;n>o;o++){for(t=this.THEAD.childNodes[o],t||(t=document.createElement("TR"),this.THEAD.appendChild(t)),this.theadChildrenLength=t.childNodes.length;e+this.rowHeaderCount>this.theadChildrenLength;)t.appendChild(document.createElement("TH")),this.theadChildrenLength++;for(;this.theadChildrenLength>e+this.rowHeaderCount;)t.removeChild(t.lastChild),this.theadChildrenLength--}var r=this.THEAD.childNodes.length;if(r>this.columnHeaders.length)for(var i=this.columnHeaders.length;r>i;i++)this.THEAD.removeChild(this.THEAD.lastChild)}else t&&(0,l.empty)(t)}},{key:"getTrForColumnHeaders",value:function(e){return this.THEAD.childNodes[e]}},{key:"renderColumnHeader",value:function(e,t,o){return o.className="",o.removeAttribute("style"),this.columnHeaders[e](t,o,e)}},{key:"adjustColumns",value:function(e,t){for(var o=e.childNodes.length;t>o;){e.appendChild(document.createElement("TD")),o++}for(;o>t;)e.removeChild(e.lastChild),o--}},{key:"removeRedundantColumns",value:function(e){for(;this.wtTable.tbodyChildrenLength>e;)this.TBODY.removeChild(this.TBODY.lastChild),this.wtTable.tbodyChildrenLength--}}]),e}()},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var i=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),s=o(0),l=o(1),a=o(4),u=n(a),c=o(155),h=n(c),d=o(156),f=n(d);t.default=function(){function e(t){var o=this;r(this,e),this.wot=t,this.instance=this.wot,this.oversizedRows=[],this.oversizedColumnHeaders=[],this.hasOversizedColumnHeadersMarked={},this.clientHeight=0,this.containerWidth=NaN,this.rowHeaderWidth=NaN,this.rowsVisibleCalculator=null,this.columnsVisibleCalculator=null,this.eventManager=new u.default(this.wot),this.eventManager.addEventListener(window,"resize",function(){o.clientHeight=o.getWorkspaceHeight()})}return i(e,[{key:"getWorkspaceHeight",value:function(){var e=this.instance.wtOverlays.topOverlay.trimmingContainer,t=void 0,o=0;return e===window?o=document.documentElement.clientHeight:(t=(0,s.outerHeight)(e),o=t>0&&e.clientHeight>0?e.clientHeight:1/0),o}},{key:"getWorkspaceWidth",value:function(){var e=void 0,t=this.wot.getSetting("totalColumns"),o=this.instance.wtOverlays.leftOverlay.trimmingContainer,n=void 0,r=this.wot.getSetting("stretchH"),i=document.documentElement.offsetWidth;return this.wot.getSetting("preventOverflow")?(0,s.outerWidth)(this.instance.wtTable.wtRootElement):(e=this.wot.getSetting("freezeOverlays")?Math.min(i-this.getWorkspaceOffset().left,i):Math.min(this.getContainerFillWidth(),i-this.getWorkspaceOffset().left,i),o===window&&t>0&&this.sumColumnWidths(0,t-1)>e?document.documentElement.clientWidth:o===window||"scroll"!=(n=(0,s.getStyle)(this.instance.wtOverlays.leftOverlay.trimmingContainer,"overflow"))&&"hidden"!=n&&"auto"!=n?"none"!==r&&r?e:Math.max(e,(0,s.outerWidth)(this.instance.wtTable.TABLE)):Math.max(e,o.clientWidth))}},{key:"hasVerticalScroll",value:function(){return this.getWorkspaceActualHeight()>this.getWorkspaceHeight()}},{key:"hasHorizontalScroll",value:function(){return this.getWorkspaceActualWidth()>this.getWorkspaceWidth()}},{key:"sumColumnWidths",value:function(e,t){for(var o=0;t>e;)o+=this.wot.wtTable.getColumnWidth(e),e++;return o}},{key:"getContainerFillWidth",value:function(){if(this.containerWidth)return this.containerWidth;var e=this.instance.wtTable.holder,t=void 0,o=void 0;return o=document.createElement("div"),o.style.width="100%",o.style.height="1px",e.appendChild(o),t=o.offsetWidth,this.containerWidth=t,e.removeChild(o),t}},{key:"getWorkspaceOffset",value:function(){return(0,s.offset)(this.wot.wtTable.TABLE)}},{key:"getWorkspaceActualHeight",value:function(){return(0,s.outerHeight)(this.wot.wtTable.TABLE)}},{key:"getWorkspaceActualWidth",value:function(){return(0,s.outerWidth)(this.wot.wtTable.TABLE)||(0,s.outerWidth)(this.wot.wtTable.TBODY)||(0,s.outerWidth)(this.wot.wtTable.THEAD)}},{key:"getColumnHeaderHeight",value:function(){return isNaN(this.columnHeaderHeight)&&(this.columnHeaderHeight=(0,s.outerHeight)(this.wot.wtTable.THEAD)),this.columnHeaderHeight}},{key:"getViewportHeight",value:function(){var e=this.getWorkspaceHeight(),t=void 0;return e===1/0?e:(t=this.getColumnHeaderHeight(),t>0&&(e-=t),e)}},{key:"getRowHeaderWidth",value:function(){var e=this.instance.getSetting("rowHeaderWidth"),t=this.instance.getSetting("rowHeaders");if(e){this.rowHeaderWidth=0;for(var o=0,n=t.length;n>o;o++)this.rowHeaderWidth+=e[o]||e}if(this.wot.cloneSource)return this.wot.cloneSource.wtViewport.getRowHeaderWidth();if(isNaN(this.rowHeaderWidth))if(t.length){var r=this.instance.wtTable.TABLE.querySelector("TH");this.rowHeaderWidth=0;for(var i=0,l=t.length;l>i;i++)r?(this.rowHeaderWidth+=(0,s.outerWidth)(r),r=r.nextSibling):this.rowHeaderWidth+=50}else this.rowHeaderWidth=0;return this.rowHeaderWidth=this.instance.getSetting("onModifyRowHeaderWidth",this.rowHeaderWidth)||this.rowHeaderWidth}},{key:"getViewportWidth",value:function(){var e=this.getWorkspaceWidth(),t=void 0;return e===1/0?e:(t=this.getRowHeaderWidth(),t>0?e-t:e)}},{key:"createRowsCalculator",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]&&arguments[0],o=void 0,n=void 0,r=void 0,i=void 0,l=void 0,a=void 0,u=void 0;return this.rowHeaderWidth=NaN,o=this.wot.wtSettings.settings.renderAllRows?1/0:this.getViewportHeight(),n=this.wot.wtOverlays.topOverlay.getScrollPosition()-this.wot.wtOverlays.topOverlay.getTableParentOffset(),0>n&&(n=0),r=this.wot.getSetting("fixedRowsTop"),l=this.wot.getSetting("fixedRowsBottom"),u=this.wot.getSetting("totalRows"),r&&(a=this.wot.wtOverlays.topOverlay.sumCellSizes(0,r),n+=a,o-=a),l&&this.wot.wtOverlays.bottomOverlay.clone&&(a=this.wot.wtOverlays.bottomOverlay.sumCellSizes(u-l,u),o-=a),i=this.wot.wtTable.holder.clientHeight===this.wot.wtTable.holder.offsetHeight?0:(0,s.getScrollbarWidth)(),new f.default(o,n,this.wot.getSetting("totalRows"),function(t){return e.wot.wtTable.getRowHeight(t)},t?null:this.wot.wtSettings.settings.viewportRowCalculatorOverride,t,i)}},{key:"createColumnsCalculator",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]&&arguments[0],o=this.getViewportWidth(),n=void 0,r=void 0;if(this.columnHeaderHeight=NaN,n=this.wot.wtOverlays.leftOverlay.getScrollPosition()-this.wot.wtOverlays.leftOverlay.getTableParentOffset(),0>n&&(n=0),r=this.wot.getSetting("fixedColumnsLeft")){var i=this.wot.wtOverlays.leftOverlay.sumCellSizes(0,r);n+=i,o-=i}return this.wot.wtTable.holder.clientWidth!==this.wot.wtTable.holder.offsetWidth&&(o-=(0,s.getScrollbarWidth)()),new h.default(o,n,this.wot.getSetting("totalColumns"),function(t){return e.wot.wtTable.getColumnWidth(t)},t?null:this.wot.wtSettings.settings.viewportColumnCalculatorOverride,t,this.wot.getSetting("stretchH"),function(t,o){return e.wot.getSetting("onBeforeStretchingColumnWidth",t,o)})}},{key:"createRenderCalculators",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(e){var t=this.createRowsCalculator(!0),o=this.createColumnsCalculator(!0);this.areAllProposedVisibleRowsAlreadyRendered(t)&&this.areAllProposedVisibleColumnsAlreadyRendered(o)||(e=!1)}return e||(this.rowsRenderCalculator=this.createRowsCalculator(),this.columnsRenderCalculator=this.createColumnsCalculator()),this.rowsVisibleCalculator=null,this.columnsVisibleCalculator=null,e}},{key:"createVisibleCalculators",value:function(){this.rowsVisibleCalculator=this.createRowsCalculator(!0),this.columnsVisibleCalculator=this.createColumnsCalculator(!0)}},{key:"areAllProposedVisibleRowsAlreadyRendered",value:function(e){return!!this.rowsVisibleCalculator&&(!(this.rowsRenderCalculator.startRow>e.startRow||e.startRow===this.rowsRenderCalculator.startRow&&e.startRow>0)&&!(e.endRow>this.rowsRenderCalculator.endRow||e.endRow===this.rowsRenderCalculator.endRow&&e.endRow<this.wot.getSetting("totalRows")-1))}},{key:"areAllProposedVisibleColumnsAlreadyRendered",value:function(e){return!!this.columnsVisibleCalculator&&(!(this.columnsRenderCalculator.startColumn>e.startColumn||e.startColumn===this.columnsRenderCalculator.startColumn&&e.startColumn>0)&&!(e.endColumn>this.columnsRenderCalculator.endColumn||e.endColumn===this.columnsRenderCalculator.endColumn&&e.endColumn<this.wot.getSetting("totalColumns")-1))}},{key:"resetHasOversizedColumnHeadersMarked",value:function(){(0,l.objectEach)(this.hasOversizedColumnHeadersMarked,function(e,t,o){o[t]=void 0})}}]),e}()},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var i=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),s=o(0),l=o(10),a=o(1),u=o(26),c=o(4),h=n(c),d=o(49),f=n(d),p=o(31);n(p);t.default=function(){function e(t,o){r(this,e),o&&(this.eventManager=new h.default(t),this.instance=t,this.wot=t,this.settings=o,this.mouseDown=!1,this.main=null,this.top=null,this.left=null,this.bottom=null,this.right=null,this.topStyle=null,this.leftStyle=null,this.bottomStyle=null,this.rightStyle=null,this.cornerDefaultStyle={width:"5px",height:"5px",borderWidth:"2px",borderStyle:"solid",borderColor:"#FFF"},this.corner=null,this.cornerStyle=null,this.createBorders(o),this.registerListeners())}return i(e,[{key:"registerListeners",value:function(){var e=this;this.eventManager.addEventListener(document.body,"mousedown",function(){return e.onMouseDown()}),this.eventManager.addEventListener(document.body,"mouseup",function(){return e.onMouseUp()});for(var t=0,o=this.main.childNodes.length;o>t;t++)!function(t,o){e.eventManager.addEventListener(e.main.childNodes[t],"mouseenter",function(o){return e.onMouseEnter(o,e.main.childNodes[t])})}(t)}},{key:"onMouseDown",value:function(){this.mouseDown=!0}},{key:"onMouseUp",value:function(){this.mouseDown=!1}},{key:"onMouseEnter",value:function(e,t){function o(e){return e.clientY<Math.floor(i.top)||(e.clientY>Math.ceil(i.top+i.height)||(e.clientX<Math.floor(i.left)||(e.clientX>Math.ceil(i.left+i.width)||void 0)))}function n(e){o(e)&&(r.eventManager.removeEventListener(document.body,"mousemove",n),t.style.display="block")}if(this.mouseDown&&this.wot.getSetting("hideBorderOnMouseDownOver")){e.preventDefault(),(0,l.stopImmediatePropagation)(e);var r=this,i=t.getBoundingClientRect();t.style.display="none",this.eventManager.addEventListener(document.body,"mousemove",n)}}},{key:"createBorders",value:function(e){this.main=document.createElement("div");var t=["top","left","bottom","right","corner"],o=this.main.style;o.position="absolute",o.top=0,o.left=0;for(var n=0;5>n;n++){var r=t[n],i=document.createElement("div");i.className="wtBorder "+(this.settings.className||""),this.settings[r]&&this.settings[r].hide&&(i.className+=" hidden"),o=i.style,o.backgroundColor=this.settings[r]&&this.settings[r].color?this.settings[r].color:e.border.color,o.height=this.settings[r]&&this.settings[r].width?this.settings[r].width+"px":e.border.width+"px",o.width=this.settings[r]&&this.settings[r].width?this.settings[r].width+"px":e.border.width+"px",this.main.appendChild(i)}this.top=this.main.childNodes[0],this.left=this.main.childNodes[1],this.bottom=this.main.childNodes[2],this.right=this.main.childNodes[3],this.topStyle=this.top.style,this.leftStyle=this.left.style,this.bottomStyle=this.bottom.style,this.rightStyle=this.right.style,this.corner=this.main.childNodes[4],this.corner.className+=" corner",this.cornerStyle=this.corner.style,this.cornerStyle.width=this.cornerDefaultStyle.width,this.cornerStyle.height=this.cornerDefaultStyle.height,this.cornerStyle.border=[this.cornerDefaultStyle.borderWidth,this.cornerDefaultStyle.borderStyle,this.cornerDefaultStyle.borderColor].join(" "),(0,u.isMobileBrowser)()&&this.createMultipleSelectorHandles(),this.disappear(),this.wot.wtTable.bordersHolder||(this.wot.wtTable.bordersHolder=document.createElement("div"),this.wot.wtTable.bordersHolder.className="htBorders",this.wot.wtTable.spreader.appendChild(this.wot.wtTable.bordersHolder)),this.wot.wtTable.bordersHolder.insertBefore(this.main,this.wot.wtTable.bordersHolder.firstChild)}},{key:"createMultipleSelectorHandles",value:function(){this.selectionHandles={topLeft:document.createElement("DIV"),topLeftHitArea:document.createElement("DIV"),bottomRight:document.createElement("DIV"),bottomRightHitArea:document.createElement("DIV")};this.selectionHandles.topLeft.className="topLeftSelectionHandle",this.selectionHandles.topLeftHitArea.className="topLeftSelectionHandle-HitArea",this.selectionHandles.bottomRight.className="bottomRightSelectionHandle",this.selectionHandles.bottomRightHitArea.className="bottomRightSelectionHandle-HitArea",this.selectionHandles.styles={topLeft:this.selectionHandles.topLeft.style,topLeftHitArea:this.selectionHandles.topLeftHitArea.style,bottomRight:this.selectionHandles.bottomRight.style,bottomRightHitArea:this.selectionHandles.bottomRightHitArea.style};var e={position:"absolute",height:"40px",width:"40px","border-radius":parseInt(40/1.5,10)+"px"};for(var t in e)(0,a.hasOwnProperty)(e,t)&&(this.selectionHandles.styles.bottomRightHitArea[t]=e[t],this.selectionHandles.styles.topLeftHitArea[t]=e[t]);var o={position:"absolute",height:"10px",width:"10px","border-radius":parseInt(10/1.5,10)+"px",background:"#F5F5FF",border:"1px solid #4285c8"};for(var n in o)(0,a.hasOwnProperty)(o,n)&&(this.selectionHandles.styles.bottomRight[n]=o[n],this.selectionHandles.styles.topLeft[n]=o[n]);this.main.appendChild(this.selectionHandles.topLeft),this.main.appendChild(this.selectionHandles.bottomRight),this.main.appendChild(this.selectionHandles.topLeftHitArea),this.main.appendChild(this.selectionHandles.bottomRightHitArea)}},{key:"isPartRange",value:function(e,t){return!(!this.wot.selections.area.cellRange||e==this.wot.selections.area.cellRange.to.row&&t==this.wot.selections.area.cellRange.to.col)}},{key:"updateMultipleSelectionHandlesPosition",value:function(e,t,o,n,r,i){var s=parseInt(this.selectionHandles.styles.topLeft.width,10),l=parseInt(this.selectionHandles.styles.topLeftHitArea.width,10);this.selectionHandles.styles.topLeft.top=parseInt(o-s,10)+"px",this.selectionHandles.styles.topLeft.left=parseInt(n-s,10)+"px",this.selectionHandles.styles.topLeftHitArea.top=parseInt(o-l/4*3,10)+"px",this.selectionHandles.styles.topLeftHitArea.left=parseInt(n-l/4*3,10)+"px",this.selectionHandles.styles.bottomRight.top=parseInt(o+i,10)+"px",this.selectionHandles.styles.bottomRight.left=parseInt(n+r,10)+"px",this.selectionHandles.styles.bottomRightHitArea.top=parseInt(o+i-l/4,10)+"px",this.selectionHandles.styles.bottomRightHitArea.left=parseInt(n+r-l/4,10)+"px",this.settings.border.multipleSelectionHandlesVisible&&this.settings.border.multipleSelectionHandlesVisible()?(this.selectionHandles.styles.topLeft.display="block",this.selectionHandles.styles.topLeftHitArea.display="block",this.isPartRange(e,t)?(this.selectionHandles.styles.bottomRight.display="none",this.selectionHandles.styles.bottomRightHitArea.display="none"):(this.selectionHandles.styles.bottomRight.display="block",this.selectionHandles.styles.bottomRightHitArea.display="block")):(this.selectionHandles.styles.topLeft.display="none",this.selectionHandles.styles.bottomRight.display="none",this.selectionHandles.styles.topLeftHitArea.display="none",this.selectionHandles.styles.bottomRightHitArea.display="none"),e==this.wot.wtSettings.getSetting("fixedRowsTop")||t==this.wot.wtSettings.getSetting("fixedColumnsLeft")?(this.selectionHandles.styles.topLeft.zIndex="9999",this.selectionHandles.styles.topLeftHitArea.zIndex="9999"):(this.selectionHandles.styles.topLeft.zIndex="",this.selectionHandles.styles.topLeftHitArea.zIndex="")}},{key:"appear",value:function(e){if(!this.disabled){var t,o,n,r,i,l,a,c,h,d,p,g,v,m,y,w,C,b;b=this.wot.wtTable.getRenderedRowsCount();for(var S=0;b>S;S++){var E=this.wot.wtTable.rowFilter.renderedToSource(S);if(E>=e[0]&&e[2]>=E){v=E;break}}for(var R=b-1;R>=0;R--){var O=this.wot.wtTable.rowFilter.renderedToSource(R);if(O>=e[0]&&e[2]>=O){y=O;break}}b=this.wot.wtTable.getRenderedColumnsCount();for(var k=0;b>k;k++){var T=this.wot.wtTable.columnFilter.renderedToSource(k);if(T>=e[1]&&e[3]>=T){m=T;break}}for(var _=b-1;_>=0;_--){var M=this.wot.wtTable.columnFilter.renderedToSource(_);if(M>=e[1]&&e[3]>=M){w=M;break}}if(void 0===v||void 0===m)return void this.disappear();t=v!==y||m!==w,o=this.wot.wtTable.getCell(new f.default(v,m)),n=t?this.wot.wtTable.getCell(new f.default(y,w)):o,r=(0,s.offset)(o),i=t?(0,s.offset)(n):r,l=(0,s.offset)(this.wot.wtTable.TABLE),c=r.top,p=i.top+(0,s.outerHeight)(n)-c,d=r.left,g=i.left+(0,s.outerWidth)(n)-d,a=c-l.top-1,h=d-l.left-1;var H=(0,s.getComputedStyle)(o);parseInt(H.borderTopWidth,10)>0&&(a+=1,p=p>0?p-1:0),parseInt(H.borderLeftWidth,10)>0&&(h+=1,g=g>0?g-1:0),this.topStyle.top=a+"px",this.topStyle.left=h+"px",this.topStyle.width=g+"px",this.topStyle.display="block",this.leftStyle.top=a+"px",this.leftStyle.left=h+"px",this.leftStyle.height=p+"px",this.leftStyle.display="block";var A=Math.floor(this.settings.border.width/2);this.bottomStyle.top=a+p-A+"px",this.bottomStyle.left=h+"px",this.bottomStyle.width=g+"px",this.bottomStyle.display="block",this.rightStyle.top=a+"px",this.rightStyle.left=h+g-A+"px",this.rightStyle.height=p+1+"px",this.rightStyle.display="block",(0,u.isMobileBrowser)()||!this.hasSetting(this.settings.border.cornerVisible)||this.isPartRange(y,w)?this.cornerStyle.display="none":(this.cornerStyle.top=a+p-4+"px",this.cornerStyle.left=h+g-4+"px",this.cornerStyle.borderRightWidth=this.cornerDefaultStyle.borderWidth,this.cornerStyle.width=this.cornerDefaultStyle.width,this.cornerStyle.display="none",C=(0,s.getTrimmingContainer)(this.wot.wtTable.TABLE),w===this.wot.getSetting("totalColumns")-1&&n.offsetLeft+(0,s.outerWidth)(n)+parseInt(this.cornerDefaultStyle.width,10)/2>=(0,s.innerWidth)(C)&&(this.cornerStyle.left=Math.floor(h+g-3-parseInt(this.cornerDefaultStyle.width,10)/2)+"px",this.cornerStyle.borderRightWidth=0),y===this.wot.getSetting("totalRows")-1&&n.offsetTop+(0,s.outerHeight)(n)+parseInt(this.cornerDefaultStyle.height,10)/2>=(0,s.innerHeight)(C)&&(this.cornerStyle.top=Math.floor(a+p-3-parseInt(this.cornerDefaultStyle.height,10)/2)+"px",this.cornerStyle.borderBottomWidth=0),this.cornerStyle.display="block"),(0,u.isMobileBrowser)()&&this.updateMultipleSelectionHandlesPosition(v,m,a,h,g,p)}}},{key:"disappear",value:function(){this.topStyle.display="none",this.leftStyle.display="none",this.bottomStyle.display="none",this.rightStyle.display="none",this.cornerStyle.display="none",(0,u.isMobileBrowser)()&&(this.selectionHandles.styles.topLeft.display="none",this.selectionHandles.styles.bottomRight.display="none")}},{key:"hasSetting",value:function(e){return"function"==typeof e?e():!!e}}]),e}()},function(e,t,o){"use strict";function n(e){d=!1;var t=this.getActiveEditor();if((0,r.isPrintableChar)(e.keyCode)||e.keyCode===r.KEY_CODES.BACKSPACE||e.keyCode===r.KEY_CODES.DELETE||e.keyCode===r.KEY_CODES.INSERT){var o=0;if(e.keyCode===r.KEY_CODES.C&&(e.ctrlKey||e.metaKey))return;t.isOpened()||(o+=10),t.htEditor&&t.instance._registerTimeout(setTimeout(function(){t.queryChoices(t.TEXTAREA.value),d=!0},o))}}t.__esModule=!0;var r=o(18),i=o(22),s=o(32),l=o(2),a=o(0),u=o(169),c=function(e){return e&&e.__esModule?e:{default:e}}(u),h=c.default.prototype.extend();h.prototype.init=function(){c.default.prototype.init.apply(this,arguments),this.query=null,this.strippedChoices=[],this.rawChoices=[]},h.prototype.getValue=function(){var e=this,t=this.rawChoices.find(function(t){return e.stripValueIfNeeded(t)===e.TEXTAREA.value});return(0,i.isDefined)(t)?t:this.TEXTAREA.value},h.prototype.createElements=function(){c.default.prototype.createElements.apply(this,arguments),(0,a.addClass)(this.htContainer,"autocompleteEditor"),(0,a.addClass)(this.htContainer,-1===window.navigator.platform.indexOf("Mac")?"":"htMacScroll")};var d=!1;h.prototype.prepare=function(){this.instance.addHook("beforeKeyDown",n),c.default.prototype.prepare.apply(this,arguments)},h.prototype.open=function(){this.TEXTAREA_PARENT.style.overflow="auto",c.default.prototype.open.apply(this,arguments),this.TEXTAREA_PARENT.style.overflow="";var e=this.htEditor.getInstance(),t=this,o=void 0===this.cellProperties.trimDropdown||this.cellProperties.trimDropdown;this.TEXTAREA.style.visibility="visible",this.focus(),e.updateSettings({colWidths:o?[(0,a.outerWidth)(this.TEXTAREA)-2]:void 0,width:o?(0,a.outerWidth)(this.TEXTAREA)+(0,a.getScrollbarWidth)()+2:void 0,afterRenderer:function(e,o,n,r,s,l){var a=t.cellProperties,u=a.filteringCaseSensitive,c=a.allowHtml,h=void 0,d=void 0;s=(0,i.stringify)(s),s&&!c&&-1!==(h=!0===u?s.indexOf(this.query):s.toLowerCase().indexOf(t.query.toLowerCase()))&&(d=s.substr(h,t.query.length),s=s.replace(d,"<strong>"+d+"</strong>")),e.innerHTML=s},autoColumnSize:!0,modifyColWidth:function(e,t){var n=this.getPlugin("autoColumnSize").widths;return n[t]&&(e=n[t]),o?e:e+15}}),this.htEditor.view.wt.wtTable.holder.parentNode.style["padding-right"]=(0,a.getScrollbarWidth)()+2+"px",d&&(d=!1),t.instance._registerTimeout(setTimeout(function(){t.queryChoices(t.TEXTAREA.value)},0))},h.prototype.close=function(){c.default.prototype.close.apply(this,arguments)},h.prototype.queryChoices=function(e){var t=this;this.query=e;var o=this.cellProperties.source;"function"==typeof o?o.call(this.cellProperties,e,function(e){t.rawChoices=e,t.updateChoicesList(t.stripValuesIfNeeded(e))}):Array.isArray(o)?(this.rawChoices=o,this.updateChoicesList(this.stripValuesIfNeeded(o))):this.updateChoicesList([])},h.prototype.updateChoicesList=function(e){var t=(0,a.getCaretPosition)(this.TEXTAREA),o=(0,a.getSelectionEndPosition)(this.TEXTAREA),n=this.cellProperties.sortByRelevance,r=this.cellProperties.filter,i=null,s=null;n&&(i=h.sortByRelevance(this.stripValueIfNeeded(this.getValue()),e,this.cellProperties.filteringCaseSensitive));var u=Array.isArray(i)?i.length:0;if(!1===r)u&&(s=i[0]);else{for(var c=[],d=0,f=e.length;f>d&&(!n||d<u);d++)c.push(u?e[i[d]]:e[d]);s=0,e=c}this.strippedChoices=e,this.htEditor.loadData((0,l.pivot)([e])),this.updateDropdownHeight(),this.flipDropdownIfNeeded(),!0===this.cellProperties.strict&&this.highlightBestMatchingChoice(s),this.instance.listen(),this.TEXTAREA.focus(),(0,a.setCaretPosition)(this.TEXTAREA,t,t===o?void 0:o)},h.prototype.flipDropdownIfNeeded=function(){var e=(0,a.offset)(this.TEXTAREA),t=(0,a.outerHeight)(this.TEXTAREA),o=this.getDropdownHeight(),n=(0,a.getTrimmingContainer)(this.instance.view.wt.wtTable.TABLE),r=n.scrollTop,i=(0,a.outerHeight)(this.instance.view.wt.wtTable.THEAD),s={row:0,col:0};n!==window&&(s=(0,a.offset)(n));var l=e.top-s.top-i+r,u=n.scrollHeight-l-i-t,c=o>u&&l>u;return c?this.flipDropdown(o):this.unflipDropdown(),this.limitDropdownIfNeeded(c?l:u,o),c},h.prototype.limitDropdownIfNeeded=function(e,t){if(t>e){var o=0,n=0,r=0,i=null;do{r=this.htEditor.getRowHeight(n)||this.htEditor.view.wt.wtSettings.settings.defaultRowHeight,o+=r,n++}while(e>o);i=o-r,this.htEditor.flipped&&(this.htEditor.rootElement.style.top=parseInt(this.htEditor.rootElement.style.top,10)+t-i+"px"),this.setDropdownHeight(o-r)}},h.prototype.flipDropdown=function(e){var t=this.htEditor.rootElement.style;t.position="absolute",t.top=-e+"px",this.htEditor.flipped=!0},h.prototype.unflipDropdown=function(){var e=this.htEditor.rootElement.style;"absolute"===e.position&&(e.position="",e.top=""),this.htEditor.flipped=void 0},h.prototype.updateDropdownHeight=function(){var e=this.htEditor.getColWidth(0)+(0,a.getScrollbarWidth)()+2,t=this.cellProperties.trimDropdown;this.htEditor.updateSettings({height:this.getDropdownHeight(),width:t?void 0:e}),this.htEditor.view.wt.wtTable.alignOverlaysWithTrimmingContainer()},h.prototype.setDropdownHeight=function(e){this.htEditor.updateSettings({height:e})},h.prototype.finishEditing=function(e){e||this.instance.removeHook("beforeKeyDown",n),c.default.prototype.finishEditing.apply(this,arguments)},h.prototype.highlightBestMatchingChoice=function(e){"number"==typeof e?this.htEditor.selectCell(e,0):this.htEditor.deselectCell()},h.sortByRelevance=function(e,t,o){var n=[],r=void 0,l=e.length,a=void 0,u=void 0,c=[],h=void 0,d=t.length;if(0===l){for(h=0;d>h;h++)c.push(h);return c}for(h=0;d>h;h++)r=(0,s.stripTags)((0,i.stringify)(t[h])),-1!==(a=o?r.indexOf(e):r.toLowerCase().indexOf(e.toLowerCase()))&&(u=r.length-a-l,n.push({baseIndex:h,index:a,charsLeft:u,value:r}));for(n.sort(function(e,t){if(-1===t.index)return-1;if(-1===e.index)return 1;if(t.index>e.index)return-1;if(e.index>t.index)return 1;if(e.index===t.index){if(t.charsLeft>e.charsLeft)return-1;if(e.charsLeft>t.charsLeft)return 1}return 0}),h=0,d=n.length;d>h;h++)c.push(n[h].baseIndex);return c},h.prototype.getDropdownHeight=function(){var e=this.htEditor.getInstance().getRowHeight(0)||23,t=this.cellProperties.visibleRows;return t>this.strippedChoices.length?this.strippedChoices.length*e+8:t*e},h.prototype.stripValueIfNeeded=function(e){return this.stripValuesIfNeeded([e])[0]},h.prototype.stripValuesIfNeeded=function(e){var t=this.cellProperties.allowHtml,o=(0,l.arrayMap)(e,function(e){return(0,i.stringify)(e)});return(0,l.arrayMap)(o,function(e){return t?e:(0,s.stripTags)(e)})},h.prototype.allowKeyEventPropagation=function(e){var t={row:this.htEditor.getSelectedRange()?this.htEditor.getSelectedRange().from.row:-1},o=!1;return e===r.KEY_CODES.ARROW_DOWN&&t.row>0&&t.row<this.htEditor.countRows()-1&&(o=!0),e===r.KEY_CODES.ARROW_UP&&t.row>-1&&(o=!0),o},h.prototype.discardEditor=function(e){c.default.prototype.discardEditor.apply(this,arguments),this.instance.view.render()},t.default=h},function(e,t,o){"use strict";t.__esModule=!0;var n=o(18),r=o(1),i=o(0),s=o(10),l=o(51),a=function(e){return e&&e.__esModule?e:{default:e}}(l),u=a.default.prototype.extend();u.prototype.createElements=function(){a.default.prototype.createElements.apply(this,arguments);var e=document.createElement("DIV");e.className="handsontableEditor",this.TEXTAREA_PARENT.appendChild(e),this.htContainer=e,this.assignHooks()},u.prototype.prepare=function(e,t,o,n,i,s){a.default.prototype.prepare.apply(this,arguments);var l=this,u={startRows:0,startCols:0,minRows:0,minCols:0,className:"listbox",copyPaste:!1,autoColumnSize:!1,autoRowSize:!1,readOnly:!0,fillHandle:!1,afterOnCellMouseDown:function(e,t){var o=this.getSourceData(t.row,t.col);void 0!==o&&l.setValue(o),l.instance.destroyEditor()}};this.cellProperties.handsontable&&(0,r.extend)(u,s.handsontable),this.htOptions=u};var c=function(e){if(!(0,s.isImmediatePropagationStopped)(e)){var t,o,r=this.getActiveEditor(),i=r.htEditor.getInstance();if(e.keyCode==n.KEY_CODES.ARROW_DOWN)if(i.getSelected()||i.flipped){if(i.getSelected())if(i.flipped)t=i.getSelected()[0]+1;else if(!i.flipped){o=i.getSelected()[0];var l=i.countRows()-1;t=Math.min(l,o+1)}}else t=0;else e.keyCode==n.KEY_CODES.ARROW_UP&&(!i.getSelected()&&i.flipped?t=i.countRows()-1:i.getSelected()&&(i.flipped?(o=i.getSelected()[0],t=Math.max(0,o-1)):(o=i.getSelected()[0],t=o-1)));void 0!==t&&(0>t||i.flipped&&t>i.countRows()-1?i.deselectCell():i.selectCell(t,0),i.getData().length&&(e.preventDefault(),(0,s.stopImmediatePropagation)(e),r.instance.listen(),r.TEXTAREA.focus()))}};u.prototype.open=function(){this.instance.addHook("beforeKeyDown",c),a.default.prototype.open.apply(this,arguments),this.htEditor&&this.htEditor.destroy(),this.htEditor=new this.instance.constructor(this.htContainer,this.htOptions),this.htEditor.init(),this.cellProperties.strict?(this.htEditor.selectCell(0,0),this.TEXTAREA.style.visibility="hidden"):(this.htEditor.deselectCell(),this.TEXTAREA.style.visibility="visible"),(0,i.setCaretPosition)(this.TEXTAREA,0,this.TEXTAREA.value.length)},u.prototype.close=function(){this.instance.removeHook("beforeKeyDown",c),this.instance.listen(),a.default.prototype.close.apply(this,arguments)},u.prototype.focus=function(){this.instance.listen(),a.default.prototype.focus.apply(this,arguments)},u.prototype.beginEditing=function(e){var t=this.instance.getSettings().onBeginEditing;t&&!1===t()||a.default.prototype.beginEditing.apply(this,arguments)},u.prototype.finishEditing=function(e,t){if(this.htEditor&&this.htEditor.isListening()&&this.instance.listen(),this.htEditor&&this.htEditor.getSelected()){var o=this.htEditor.getInstance().getValue();void 0!==o&&this.setValue(o)}return a.default.prototype.finishEditing.apply(this,arguments)},u.prototype.assignHooks=function(){var e=this;this.instance.addHook("afterDestroy",function(){e.htEditor&&e.htEditor.destroy()})},t.default=u},function(e,t,o){"use strict";function n(e){var t=new Date(e);return isNaN(new Date(e+"T00:00").getDate())?t:new Date(t.getTime()+6e4*t.getTimezoneOffset())}t.__esModule=!0,t.getNormalizedDate=n},function(e,t,o){"use strict";!function(e){function o(e){return e.split('"').length-1}var n={parse:function(e){var t,n,r,i,s,l,a,u=[],c=0;for(r=e.split("\n"),r.length>1&&""===r[r.length-1]&&r.pop(),t=0,n=r.length;n>t;t+=1){for(r[t]=r[t].split("\t"),i=0,s=r[t].length;s>i;i+=1)u[c]||(u[c]=[]),l&&0===i?(a=u[c].length-1,u[c][a]=u[c][a]+"\n"+r[t][0],l&&1&o(r[t][0])&&(l=!1,u[c][a]=u[c][a].substring(0,u[c][a].length-1).replace(/""/g,'"'))):i===s-1&&0===r[t][i].indexOf('"')&&1&o(r[t][i])?(u[c].push(r[t][i].substring(1).replace(/""/g,'"')),l=!0):(u[c].push(r[t][i].replace(/""/g,'"')),l=!1);l||(c+=1)}return u},stringify:function(e){var t,o,n,r,i,s="";for(t=0,o=e.length;o>t;t+=1){for(r=e[t].length,n=0;r>n;n+=1)n>0&&(s+="\t"),i=e[t][n],"string"==typeof i?i.indexOf("\n")>-1?s+='"'+i.replace(/"/g,'""')+'"':s+=i:s+=null===i||void 0===i?"":i;t!==o-1&&(s+="\n")}return s}};t.parse=n.parse,t.stringify=n.stringify}(window)},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){h.set(e,t)}function i(e){var t=void 0;if(!(e instanceof a.default)){if(!h.has(e))throw Error("Record translator was not registered for this object identity");e=h.get(e)}return d.has(e)?t=d.get(e):(t=new c(e),d.set(e,t)),t}t.__esModule=!0,t.RecordTranslator=void 0;var s=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}();t.registerIdentity=r,t.getTranslator=i;var l=o(82),a=function(e){return e&&e.__esModule?e:{default:e}}(l),u=o(1),c=function(){function e(t){n(this,e),this.hot=t}return s(e,[{key:"toVisualRow",value:function(e){return this.hot.runHooks("unmodifyRow",e)}},{key:"toVisualColumn",value:function(e){return this.hot.runHooks("unmodifyCol",e)}},{key:"toVisual",value:function(e,t){return(0,u.isObject)(e)?{row:this.toVisualRow(e.row),column:this.toVisualColumn(e.column)}:[this.toVisualRow(e),this.toVisualColumn(t)]}},{key:"toPhysicalRow",value:function(e){return this.hot.runHooks("modifyRow",e)}},{key:"toPhysicalColumn",value:function(e){return this.hot.runHooks("modifyCol",e)}},{key:"toPhysical",value:function(e,t){return(0,u.isObject)(e)?{row:this.toPhysicalRow(e.row),column:this.toPhysicalColumn(e.column)}:[this.toPhysicalRow(e),this.toPhysicalColumn(t)]}}]),e}();t.RecordTranslator=c;var h=new WeakMap,d=new WeakMap},function(e,t,o){"use strict";function n(e){s.set(e,!0)}function r(e){return e===l}function i(e){return s.has(e)}t.__esModule=!0,t.registerAsRootInstance=n,t.hasValidParameter=r,t.isRootInstance=i;var s=t.holder=new WeakMap,l=t.rootInstanceSymbol=Symbol("rootInstance")},function(e,t,o){"use strict";function n(){}t.__esModule=!0;var r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i=o(22),s=o(1);n.prototype={licenseKey:"trial",data:void 0,dataSchema:void 0,width:void 0,height:void 0,startRows:5,startCols:5,rowHeaders:void 0,colHeaders:null,colWidths:void 0,rowHeights:void 0,columns:void 0,cells:void 0,cell:[],comments:!1,customBorders:!1,minRows:0,minCols:0,maxRows:1/0,maxCols:1/0,minSpareRows:0,minSpareCols:0,allowInsertRow:!0,allowInsertColumn:!0,allowRemoveRow:!0,allowRemoveColumn:!0,multiSelect:!0,fillHandle:!0,fixedRowsTop:0,fixedRowsBottom:0,fixedColumnsLeft:0,outsideClickDeselects:!0,enterBeginsEditing:!0,enterMoves:{row:1,col:0},tabMoves:{row:0,col:1},autoWrapRow:!1,autoWrapCol:!1,persistentState:void 0,currentRowClassName:void 0,currentColClassName:void 0,currentHeaderClassName:"ht__highlight",className:void 0,tableClassName:void 0,stretchH:"none",isEmptyRow:function(e){var t,o,n,l;for(t=0,o=this.countCols();o>t;t++)if(""!==(n=this.getDataAtCell(e,t))&&null!==n&&(0,i.isDefined)(n))return"object"===(void 0===n?"undefined":r(n))&&(l=this.getCellMeta(e,t),(0,s.isObjectEquals)(this.getSchema()[l.prop],n));return!0},isEmptyCol:function(e){var t,o,n;for(t=0,o=this.countRows();o>t;t++)if(""!==(n=this.getDataAtCell(t,e))&&null!==n&&(0,i.isDefined)(n))return!1;return!0},observeDOMVisibility:!0,allowInvalid:!0,allowEmpty:!0,invalidCellClassName:"htInvalid",placeholder:!1,placeholderCellClassName:"htPlaceholder",readOnlyCellClassName:"htDimmed",renderer:void 0,commentedCellClassName:"htCommentCell",fragmentSelection:!1,readOnly:!1,skipColumnOnPaste:!1,search:!1,type:"text",copyable:!0,editor:void 0,autoComplete:void 0,visibleRows:10,trimDropdown:!0,debug:!1,wordWrap:!0,noWordWrapClassName:"htNoWrap",contextMenu:void 0,copyPaste:!0,undo:void 0,columnSorting:void 0,manualColumnMove:void 0,manualColumnResize:void 0,manualRowMove:void 0,manualRowResize:void 0,mergeCells:!1,viewportRowRenderingOffset:"auto",viewportColumnRenderingOffset:"auto",validator:void 0,disableVisualSelection:!1,sortIndicator:void 0,manualColumnFreeze:void 0,trimWhitespace:!0,settings:void 0,source:void 0,title:void 0,checkedTemplate:void 0,uncheckedTemplate:void 0,label:void 0,format:void 0,language:void 0,selectOptions:void 0,autoColumnSize:void 0,autoRowSize:void 0,dateFormat:void 0,correctFormat:!1,defaultDate:void 0,strict:void 0,allowHtml:!1,renderAllRows:void 0,preventOverflow:!1,bindRowsWithHeaders:void 0,collapsibleColumns:void 0,columnSummary:void 0,dropdownMenu:void 0,filters:void 0,formulas:void 0,ganttChart:void 0,headerTooltips:void 0,hiddenColumns:void 0,hiddenRows:void 0,nestedHeaders:void 0,trimRows:void 0,rowHeaderWidth:void 0,columnHeaderHeight:void 0,observeChanges:void 0,sortFunction:void 0,sortByRelevance:!0,filter:!0,filteringCaseSensitive:!1},t.default=n},function(e,t,o){"use strict";function n(e,t,o){return t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o,e}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var i=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),s=o(1),l=o(6),a=o(22);t.default=function(){function e(t){r(this,e),this.samples=null,this.dataFactory=t,this.customSampleCount=null,this.allowDuplicates=!1}return i(e,null,[{key:"SAMPLE_COUNT",get:function(){return 3}}]),i(e,[{key:"getSampleCount",value:function(){return this.customSampleCount?this.customSampleCount:e.SAMPLE_COUNT}},{key:"setSampleCount",value:function(e){this.customSampleCount=e}},{key:"setAllowDuplicates",value:function(e){this.allowDuplicates=e}},{key:"generateRowSamples",value:function(e,t){return this.generateSamples("row",t,e)}},{key:"generateColumnSamples",value:function(e,t){return this.generateSamples("col",t,e)}},{key:"generateSamples",value:function(e,t,o){var n=this,r=new Map;return"number"==typeof o&&(o={from:o,to:o}),(0,l.rangeEach)(o.from,o.to,function(o){var i=n.generateSample(e,t,o);r.set(o,i)}),r}},{key:"generateSample",value:function(e,t,o){var r=this,i=new Map,u=[],c=void 0;return(0,l.rangeEach)(t.from,t.to,function(t){var l=void 0;if("row"===e)l=r.dataFactory(o,t);else{if("col"!==e)throw Error("Unsupported sample type");l=r.dataFactory(t,o)}c=(0,s.isObject)(l)?Object.keys(l).length:Array.isArray(l)?l.length:(0,a.stringify)(l).length,i.has(c)||i.set(c,{needed:r.getSampleCount(),strings:[]});var h=i.get(c);if(h.needed){if(!(u.indexOf(l)>-1)||r.allowDuplicates){h.strings.push(n({value:l},"row"===e?"col":"row",t)),u.push(l),h.needed--}}}),i}}]),e}()},function(e,t,o){"use strict";t.__esModule=!0;var n=o(2),r=o(1),i=o(6),s={_arrayMap:[],getValueByIndex:function(e){var t=void 0;return void 0===(t=this._arrayMap[e])?null:t},getIndexByValue:function(e){var t=void 0;return-1===(t=this._arrayMap.indexOf(e))?null:t},insertItems:function(e){var t=this,o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,r=(0,n.arrayMax)(this._arrayMap)+1,s=[];return(0,i.rangeEach)(o-1,function(o){s.push(t._arrayMap.splice(e+o,0,r+o))}),s},removeItems:function(e){var t=this,o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,r=[];if(Array.isArray(e)){var i=[].concat(this._arrayMap);e.sort(function(e,t){return t-e}),r=(0,n.arrayReduce)(e,function(e,o){return t._arrayMap.splice(o,1),e.concat(i.slice(o,o+1))},[])}else r=this._arrayMap.splice(e,o);return r},unshiftItems:function(e){function t(e){return(0,n.arrayReduce)(r,function(t,o){return e>o&&t++,t},0)}var o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,r=this.removeItems(e,o);this._arrayMap=(0,n.arrayMap)(this._arrayMap,function(e,o){var n=t(e);return n&&(e-=n),e})},shiftItems:function(e){var t=this,o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1;this._arrayMap=(0,n.arrayMap)(this._arrayMap,function(t){return e>t||(t+=o),t}),(0,i.rangeEach)(o-1,function(o){t._arrayMap.splice(e+o,0,e+o)})},clearMap:function(){this._arrayMap.length=0}};(0,r.defineGetter)(s,"MIXIN_NAME","arrayMapper",{writable:!1,enumerable:!1}),t.default=s},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=o(6),s=0;t.default=function(){function e(t){n(this,e),this.hot=t,this._element=null,this.state=s}return r(e,[{key:"appendTo",value:function(e){e.appendChild(this._element),this.state=2}},{key:"build",value:function(){this._element=document.createElement("div"),this.state=1}},{key:"destroy",value:function(){this.isAppended()&&this._element.parentElement.removeChild(this._element),this._element=null,this.state=s}},{key:"isAppended",value:function(){return 2===this.state}},{key:"isBuilt",value:function(){return this.state>=1}},{key:"setPosition",value:function(e,t){(0,i.isNumeric)(e)&&(this._element.style.top=e+"px"),(0,i.isNumeric)(t)&&(this._element.style.left=t+"px")}},{key:"getPosition",value:function(){return{top:this._element.style.top?parseInt(this._element.style.top,10):0,left:this._element.style.left?parseInt(this._element.style.left,10):0}}},{key:"setSize",value:function(e,t){(0,i.isNumeric)(e)&&(this._element.style.width=e+"px"),(0,i.isNumeric)(t)&&(this._element.style.height=t+"px")}},{key:"getSize",value:function(){return{width:this._element.style.width?parseInt(this._element.style.width,10):0,height:this._element.style.height?parseInt(this._element.style.height,10):0}}},{key:"setOffset",value:function(e,t){(0,i.isNumeric)(e)&&(this._element.style.marginTop=e+"px"),(0,i.isNumeric)(t)&&(this._element.style.marginLeft=t+"px")}},{key:"getOffset",value:function(){return{top:this._element.style.marginTop?parseInt(this._element.style.marginTop,10):0,left:this._element.style.marginLeft?parseInt(this._element.style.marginLeft,10):0}}}]),e}()},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=0;t.default=function(){function e(t){n(this,e),this.hot=t,this._element=null,this.state=i}return r(e,[{key:"appendTo",value:function(e){e.appendChild(this._element),this.state=2}},{key:"build",value:function(){this._element=document.createElement("div"),this.state=1}},{key:"destroy",value:function(){this.isAppended()&&this._element.parentElement.removeChild(this._element),this._element=null,this.state=i}},{key:"isAppended",value:function(){return 2===this.state}},{key:"isBuilt",value:function(){return this.state>=1}},{key:"setPosition",value:function(e,t){void 0!==e&&(this._element.style.top=e+"px"),void 0!==t&&(this._element.style.left=t+"px")}},{key:"getPosition",value:function(){return{top:this._element.style.top?parseInt(this._element.style.top,10):0,left:this._element.style.left?parseInt(this._element.style.left,10):0}}},{key:"setSize",value:function(e,t){e&&(this._element.style.width=e+"px"),t&&(this._element.style.height=t+"px")}},{key:"getSize",value:function(){return{width:this._element.style.width?parseInt(this._element.style.width,10):0,height:this._element.style.height?parseInt(this._element.style.height,10):0}}},{key:"setOffset",value:function(e,t){e&&(this._element.style.marginTop=e+"px"),t&&(this._element.style.marginLeft=t+"px")}},{key:"getOffset",value:function(){return{top:this._element.style.marginTop?parseInt(this._element.style.marginTop,10):0,left:this._element.style.marginLeft?parseInt(this._element.style.marginLeft,10):0}}}]),e}()},function(e,t,o){"use strict";var n,r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i=function(e,t){function o(){this.constructor=e}for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n]);e.prototype=null===t?Object.create(t):(o.prototype=t.prototype,new o)},s=Error;!function(e){function t(e,o){switch(void 0===e?"undefined":r(e)){case"undefined":case"boolean":case"string":case"number":return e===o;case"object":if(null===e)return null===o;if(T(e)){if(!T(o)||e.length!==o.length)return!1;for(var n=0,i=e.length;i>n;n++)if(!t(e[n],o[n]))return!1;return!0}var s=C(o),l=s.length;if(C(e).length!==l)return!1;for(var n=0;l>n;n++)if(!t(e[n],o[n]))return!1;return!0;default:return!1}}function o(e){return-1===e.indexOf("/")&&-1===e.indexOf("~")?e:e.replace(/~/g,"~0").replace(/\//g,"~1")}function n(e){for(var t=0,o=R.length;o>t;t++)if(R[t].obj===e)return R[t]}function l(e,t){for(var o=0,n=e.observers.length;n>o;o++)if(e.observers[o].callback===t)return e.observers[o].observer}function a(e,t){for(var o=0,n=e.observers.length;n>o;o++)if(e.observers[o].observer===t)return void e.observers.splice(o,1)}function u(e,t){t.unobserve()}function c(e){return"object"===(void 0===e?"undefined":r(e))?JSON.parse(JSON.stringify(e)):e}function h(e,t){var o,r=[],i=n(e);if(i?o=l(i,t):(i=new O(e),R.push(i)),o)return o;if(o={},i.value=c(e),t){o.callback=t,o.next=null;var u=this.intervals||[100,1e3,1e4,6e4];if(void 0===u.push)throw new s("jsonpatch.intervals must be an array");var h=0,f=function(){d(o)},p=function(){clearTimeout(o.next),o.next=setTimeout(function(){f(),h=0,o.next=setTimeout(g,u[h++])},0)},g=function e(){f(),h==u.length&&(h=u.length-1),o.next=setTimeout(e,u[h++])};"undefined"!=typeof window&&(window.addEventListener?(window.addEventListener("mousedown",p),window.addEventListener("mouseup",p),window.addEventListener("keydown",p)):(document.documentElement.attachEvent("onmousedown",p),document.documentElement.attachEvent("onmouseup",p),document.documentElement.attachEvent("onkeydown",p))),o.next=setTimeout(g,u[h++])}return o.patches=r,o.object=e,o.unobserve=function(){d(o),clearTimeout(o.next),a(i,o),"undefined"!=typeof window&&(window.removeEventListener?(window.removeEventListener("mousedown",p),window.removeEventListener("mouseup",p),window.removeEventListener("keydown",p)):(document.documentElement.detachEvent("onmousedown",p),document.documentElement.detachEvent("onmouseup",p),document.documentElement.detachEvent("onkeydown",p)))},i.observers.push(new k(t,o)),o}function d(e){for(var t,o=0,n=R.length;n>o;o++)if(R[o].obj===e.object){t=R[o];break}f(t.value,e.object,e.patches,""),e.patches.length&&g(t.value,e.patches);var r=e.patches;return r.length>0&&(e.patches=[],e.callback&&e.callback(r)),r}function f(e,t,n,i){for(var s=C(t),l=C(e),a=!1,u=l.length-1;u>=0;u--){var h=l[u],d=e[h];if(t.hasOwnProperty(h)){var p=t[h];"object"==(void 0===d?"undefined":r(d))&&null!=d&&"object"==(void 0===p?"undefined":r(p))&&null!=p?f(d,p,n,i+"/"+o(h)):d!=p&&(!0,n.push({op:"replace",path:i+"/"+o(h),value:c(p)}))}else n.push({op:"remove",path:i+"/"+o(h)}),a=!0}if(a||s.length!=l.length)for(var u=0;s.length>u;u++){var h=s[u];e.hasOwnProperty(h)||n.push({op:"add",path:i+"/"+o(h),value:c(t[h])})}}function p(e){for(var t,o=0,n=e.length;n>o;){t=e.charCodeAt(o);{if(48>t||t>57)return!1;o++}}return!0}function g(e,t,o){for(var n,r,i=!1,s=0,l=t.length;l>s;){n=t[s],s++;for(var a=n.path||"",u=a.split("/"),c=e,h=1,d=u.length,f=void 0;;){if(r=u[h],o&&void 0===f&&(void 0===c[r]?f=u.slice(0,h).join("/"):h==d-1&&(f=n.path),void 0!==f&&this.validator(n,s-1,e,f)),h++,void 0===r&&h>=d){i=E[n.op].call(n,c,r,e);break}if(T(c)){if("-"===r)r=c.length;else{if(o&&!p(r))throw new _("Expected an unsigned base-10 integer value, making the new referenced value the array element with the zero-based index","OPERATION_PATH_ILLEGAL_ARRAY_INDEX",s-1,n.path,n);r=parseInt(r,10)}if(h>=d){if(o&&"add"===n.op&&r>c.length)throw new _("The specified index MUST NOT be greater than the number of elements in the array","OPERATION_VALUE_OUT_OF_BOUNDS",s-1,n.path,n);i=S[n.op].call(n,c,r,e);break}}else if(r&&-1!=r.indexOf("~")&&(r=r.replace(/~1/g,"/").replace(/~0/g,"~")),h>=d){i=b[n.op].call(n,c,r,e);break}c=c[r]}}return i}function v(e,t){var o=[];return f(e,t,o,""),o}function m(e){if(void 0===e)return!0;if("array"==typeof e||"object"==(void 0===e?"undefined":r(e)))for(var t in e)if(m(e[t]))return!0;return!1}function y(t,o,n,i){if("object"!==(void 0===t?"undefined":r(t))||null===t||T(t))throw new _("Operation is not an object","OPERATION_NOT_AN_OBJECT",o,t,n);if(!b[t.op])throw new _("Operation `op` property is not one of operations defined in RFC-6902","OPERATION_OP_INVALID",o,t,n);if("string"!=typeof t.path)throw new _("Operation `path` property is not a string","OPERATION_PATH_INVALID",o,t,n);if(("move"===t.op||"copy"===t.op)&&"string"!=typeof t.from)throw new _("Operation `from` property is not present (applicable in `move` and `copy` operations)","OPERATION_FROM_REQUIRED",o,t,n);if(("add"===t.op||"replace"===t.op||"test"===t.op)&&void 0===t.value)throw new _("Operation `value` property is not present (applicable in `add`, `replace` and `test` operations)","OPERATION_VALUE_REQUIRED",o,t,n);if(("add"===t.op||"replace"===t.op||"test"===t.op)&&m(t.value))throw new _("Operation `value` property is not present (applicable in `add`, `replace` and `test` operations)","OPERATION_VALUE_CANNOT_CONTAIN_UNDEFINED",o,t,n);if(n)if("add"==t.op){var s=t.path.split("/").length,l=i.split("/").length;if(s!==l+1&&s!==l)throw new _("Cannot perform an `add` operation at the desired path","OPERATION_PATH_CANNOT_ADD",o,t,n)}else if("replace"===t.op||"remove"===t.op||"_get"===t.op){if(t.path!==i)throw new _("Cannot perform the operation at a path that does not exist","OPERATION_PATH_UNRESOLVABLE",o,t,n)}else if("move"===t.op||"copy"===t.op){var a={op:"_get",path:t.from,value:void 0},u=e.validate([a],n);if(u&&"OPERATION_PATH_UNRESOLVABLE"===u.name)throw new _("Cannot perform the operation from a path that does not exist","OPERATION_FROM_UNRESOLVABLE",o,t,n)}}function w(e,t){try{if(!T(e))throw new _("Patch sequence must be an array","SEQUENCE_NOT_AN_ARRAY");if(t)t=JSON.parse(JSON.stringify(t)),g.call(this,t,e,!0);else for(var o=0;e.length>o;o++)this.validator(e[o],o)}catch(e){if(e instanceof _)return e;throw e}}var C=function(e){if(T(e)){for(var t=Array(e.length),o=0;t.length>o;o++)t[o]=""+o;return t}if(Object.keys)return Object.keys(e);var t=[];for(var n in e)e.hasOwnProperty(n)&&t.push(n);return t},b={add:function(e,t){return e[t]=this.value,!0},remove:function(e,t){return delete e[t],!0},replace:function(e,t){return e[t]=this.value,!0},move:function(e,t,o){var n={op:"_get",path:this.from};return g(o,[n]),g(o,[{op:"remove",path:this.from}]),g(o,[{op:"add",path:this.path,value:n.value}]),!0},copy:function(e,t,o){var n={op:"_get",path:this.from};return g(o,[n]),g(o,[{op:"add",path:this.path,value:n.value}]),!0},test:function(e,o){return t(e[o],this.value)},_get:function(e,t){this.value=e[t]}},S={add:function(e,t){return e.splice(t,0,this.value),!0},remove:function(e,t){return e.splice(t,1),!0},replace:function(e,t){return e[t]=this.value,!0},move:b.move,copy:b.copy,test:b.test,_get:b._get},E={add:function(e){E.remove.call(this,e);for(var t in this.value)this.value.hasOwnProperty(t)&&(e[t]=this.value[t]);return!0},remove:function(e){for(var t in e)e.hasOwnProperty(t)&&b.remove.call(this,e,t);return!0},replace:function(e){return g(e,[{op:"remove",path:this.path}]),g(e,[{op:"add",path:this.path,value:this.value}]),!0},move:b.move,copy:b.copy,test:function(e){return JSON.stringify(e)===JSON.stringify(this.value)},_get:function(e){this.value=e}},R=[],O=function(){function e(e){this.observers=[],this.obj=e}return e}(),k=function(){function e(e,t){this.callback=e,this.observer=t}return e}();e.unobserve=u,e.observe=h,e.generate=d;var T;T=Array.isArray?Array.isArray:function(e){return e.push&&"number"==typeof e.length},e.apply=g,e.compare=v;var _=function(e){function t(t,o,n,r,i){e.call(this,t),this.message=t,this.name=o,this.index=n,this.operation=r,this.tree=i}return i(t,e),t}(s);e.JsonPatchError=_,e.Error=_,e.validator=y,e.validate=w}(n||(n={})),t.apply=n.apply,t.observe=n.observe,t.unobserve=n.unobserve,t.generate=n.generate,t.compare=n.compare,t.validate=n.validate,t.validator=n.validator,t.JsonPatchError=n.JsonPatchError,t.Error=n.Error},function(e,t,o){"use strict";function n(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t.default=e,t}function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){var o=new h.default(e,t||{},Z.rootInstanceSymbol);return o.init(),o}t.__esModule=!0,o(89),o(103),o(104),o(108),o(109),o(111),o(113),o(114),o(115),o(116),o(117),o(118),o(119),o(120),o(122),o(124),o(125),o(126),o(127),o(128),o(129),o(130),o(131),o(132),o(133),o(134),o(135),o(136),o(78),o(137),o(138),o(140),o(141),o(142),o(143),o(144),o(145),o(146),o(148),o(149),o(150),o(152),o(153),o(154),o(201),o(202),o(203);var s=o(15),l=o(8),a=o(27),u=o(81),c=o(82),h=r(c),d=o(246),f=r(d),p=o(4),g=r(p),v=o(7),m=r(v),y=o(85),w=r(y),C=o(2),b=n(C),S=o(26),E=n(S),R=o(84),O=n(R),k=o(170),T=n(k),_=o(34),M=n(_),H=o(35),A=n(H),P=o(22),x=n(P),D=o(6),L=n(D),N=o(1),I=n(N),j=o(83),W=n(j),B=o(32),F=n(B),V=o(18),z=n(V),U=o(0),Y=n(U),K=o(10),G=n(K),X=o(247),q=n(X),Q=o(5),J=o(174),$=r(J),Z=o(173);(0,f.default)(i),i.Core=h.default,i.DefaultSettings=$.default,i.EventManager=g.default,i._getListenersCounter=p.getListenersCounter,i.buildDate="12/10/2017 10:04:52",i.packageName="handsontable",i.version="0.34.5";i.hooks=m.default.getSingleton(),i.__GhostTable=w.default;var ee=[b,E,O,T,M,A,x,L,I,W,F,z],te=[Y,G];i.helper={},i.dom={},b.arrayEach(ee,function(e){b.arrayEach(Object.getOwnPropertyNames(e),function(t){"_"!==t.charAt(0)&&(i.helper[t]=e[t])})}),b.arrayEach(te,function(e){b.arrayEach(Object.getOwnPropertyNames(e),function(t){"_"!==t.charAt(0)&&(i.dom[t]=e[t])})}),i.cellTypes={},b.arrayEach((0,u.getRegisteredCellTypeNames)(),function(e){i.cellTypes[e]=(0,u.getCellType)(e)}),i.cellTypes.registerCellType=u.registerCellType,i.cellTypes.getCellType=u.getCellType,i.editors={},b.arrayEach((0,s.getRegisteredEditorNames)(),function(e){i.editors[F.toUpperCaseFirst(e)+"Editor"]=(0,s.getEditor)(e)}),i.editors.registerEditor=s.registerEditor,i.editors.getEditor=s.getEditor,i.renderers={},b.arrayEach((0,l.getRegisteredRendererNames)(),function(e){var t=(0,l.getRenderer)(e);"base"===e&&(i.renderers.cellDecorator=t),i.renderers[F.toUpperCaseFirst(e)+"Renderer"]=t}),i.renderers.registerRenderer=l.registerRenderer,i.renderers.getRenderer=l.getRenderer,i.validators={},b.arrayEach((0,a.getRegisteredValidatorNames)(),function(e){i.validators[F.toUpperCaseFirst(e)+"Validator"]=(0,a.getValidator)(e)}),i.validators.registerValidator=a.registerValidator,i.validators.getValidator=a.getValidator,i.plugins={},b.arrayEach(Object.getOwnPropertyNames(q),function(e){var t=q[e];"Base"===e?i.plugins[e+"Plugin"]=t:i.plugins[e]=t}),i.plugins.registerPlugin=Q.registerPlugin,t.default=i},function(e,t,o){var n=o(17),r=o(16),i=o(36);e.exports=o(20)?Object.defineProperties:function(e,t){r(e);for(var o,s=i(t),l=s.length,a=0;l>a;)n.f(e,o=s[a++],t[o]);return e}},function(e,t,o){"use strict";var n=o(66),r=o(43),i=o(46),s={};o(29)(s,o(9)("iterator"),function(){return this}),e.exports=function(e,t,o){e.prototype=n(s,{next:r(1,o)}),i(e,t+" Iterator")}},function(e,t,o){var n=o(24),r=o(38),i=o(68)("IE_PROTO"),s=Object.prototype;e.exports=Object.getPrototypeOf||function(e){return e=r(e),n(e,i)?e[i]:"function"==typeof e.constructor&&e instanceof e.constructor?e.constructor.prototype:e instanceof Object?s:null}},function(e,t,o){var n=o(14),r=o(102).set;e.exports=function(e,t,o){var i,s=t.constructor;return s!==o&&"function"==typeof s&&(i=s.prototype)!==o.prototype&&n(i)&&r&&r(e,i),e}},function(e,t,o){var n=o(186);e.exports=function(e,t){return new(n(e))(t)}},function(e,t,o){var n=o(14),r=o(105),i=o(9)("species");e.exports=function(e){var t;return r(e)&&(t=e.constructor,"function"!=typeof t||t!==Array&&!r(t.prototype)||(t=void 0),n(t)&&null===(t=t[i])&&(t=void 0)),void 0===t?Array:t}},function(e,t,o){var n=o(16),r=o(55),i=o(9)("species");e.exports=function(e,t){var o,s=n(e).constructor;return void 0===s||void 0==(o=n(s)[i])?t:r(o)}},function(e,t){e.exports=function(e,t,o){var n=void 0===o;switch(t.length){case 0:return n?e():e.call(o);case 1:return n?e(t[0]):e.call(o,t[0]);case 2:return n?e(t[0],t[1]):e.call(o,t[0],t[1]);case 3:return n?e(t[0],t[1],t[2]):e.call(o,t[0],t[1],t[2]);case 4:return n?e(t[0],t[1],t[2],t[3]):e.call(o,t[0],t[1],t[2],t[3])}return e.apply(o,t)}},function(e,t,o){var n=o(11),r=o(73).set,i=n.MutationObserver||n.WebKitMutationObserver,s=n.process,l=n.Promise,a="process"==o(37)(s);e.exports=function(){var e,t,o,u=function(){var n,r;for(a&&(n=s.domain)&&n.exit();e;){r=e.fn,e=e.next;try{r()}catch(n){throw e?o():t=void 0,n}}t=void 0,n&&n.enter()};if(a)o=function(){s.nextTick(u)};else if(i){var c=!0,h=document.createTextNode("");new i(u).observe(h,{characterData:!0}),o=function(){h.data=c=!c}}else if(l&&l.resolve){var d=l.resolve();o=function(){d.then(u)}}else o=function(){r.call(n,u)};return function(n){var r={fn:n,next:void 0};t&&(t.next=r),e||(e=r,o()),t=r}}},function(e,t){e.exports=function(e){try{return{e:!1,v:e()}}catch(e){return{e:!0,v:e}}}},function(e,t,o){var n=o(16),r=o(14),i=o(110);e.exports=function(e,t){if(n(e),r(t)&&t.constructor===e)return t;var o=i.f(e);return(0,o.resolve)(t),o.promise}},function(e,t,o){var n=o(11),r=o(44),i=o(58),s=o(112),l=o(17).f;e.exports=function(e){var t=r.Symbol||(r.Symbol=i?{}:n.Symbol||{});"_"==e.charAt(0)||e in t||l(t,e,{value:s.f(e)})}},function(e,t,o){var n=o(36),r=o(61),i=o(48);e.exports=function(e){var t=n(e),o=r.f;if(o)for(var s,l=o(e),a=i.f,u=0;l.length>u;)a.call(e,s=l[u++])&&t.push(s);return t}},function(e,t,o){var n=o(25),r=o(74).f,i={}.toString,s="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],l=function(e){try{return r(e)}catch(e){return s.slice()}};e.exports.f=function(e){return s&&"[object Window]"==i.call(e)?l(e):r(n(e))}},function(e,t){e.exports=Object.is||function(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}},function(e,t,o){var n=o(52),r=o(33);e.exports=function(e){return function(t,o){var i,s,l=r(t)+"",a=n(o),u=l.length;return 0>a||a>=u?e?"":void 0:(i=l.charCodeAt(a),55296>i||i>56319||a+1===u||56320>(s=l.charCodeAt(a+1))||s>57343?e?l.charAt(a):i:e?l.slice(a,a+2):s-56320+(i-55296<<10)+65536)}}},function(e,t,o){"use strict";var n=o(16);e.exports=function(){var e=n(this),t="";return e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),e.unicode&&(t+="u"),e.sticky&&(t+="y"),t}},function(e,t,o){"use strict";var n=o(38),r=o(53),i=o(21);e.exports=[].copyWithin||function(e,t){var o=n(this),s=i(o.length),l=r(e,s),a=r(t,s),u=arguments.length>2?arguments[2]:void 0,c=Math.min((void 0===u?s:r(u,s))-a,s-l),h=1;for(l>a&&a+c>l&&(h=-1,a+=c-1,l+=c-1);c-- >0;)a in o?o[l]=o[a]:delete o[l],l+=h,a+=h;return o}},function(e,t,o){"use strict";var n=o(38),r=o(53),i=o(21);e.exports=function(e){for(var t=n(this),o=i(t.length),s=arguments.length,l=r(s>1?arguments[1]:void 0,o),a=s>2?arguments[2]:void 0,u=void 0===a?o:r(a,o);u>l;)t[l++]=e;return t}},function(e,t,o){var n=o(74),r=o(61),i=o(16),s=o(11).Reflect;e.exports=s&&s.ownKeys||function(e){var t=n.f(i(e)),o=r.f;return o?t.concat(o(e)):t}},function(e,t){},function(e,t){},function(e,t){},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var s=o(0),l=o(31),a=function(e){return e&&e.__esModule?e:{default:e}}(l),u=function(e){function t(e){n(this,t);var o=r(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.clone=o.makeClone(a.default.CLONE_DEBUG),o.clone.wtTable.holder.style.opacity=.4,o.clone.wtTable.holder.style.textShadow="0 0 2px #ff0000",(0,s.addClass)(o.clone.wtTable.holder.parentNode,"wtDebugVisible"),o}return i(t,e),t}(a.default);a.default.registerOverlay(a.default.CLONE_DEBUG,u),t.default=u},function(e,t,o){"use strict";function n(e){for(var t=arguments.length,o=Array(t>1?t-1:0),n=1;t>n;n++)o[n-1]=arguments[n];return(0,r.arrayReduce)(e,function(e,t,n){return e+t.replace(/(?:\r?\n\s+)/g,"")+(o[n]?o[n]:"")},"").trim()}t.__esModule=!0,t.toSingleLine=n;var r=o(2)},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var s=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),l=o(0),a=o(31),u=function(e){return e&&e.__esModule?e:{default:e}}(a),c=function(e){function t(e){n(this,t);var o=r(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.clone=o.makeClone(u.default.CLONE_LEFT),o}return i(t,e),s(t,[{key:"shouldBeRendered",value:function(){return!(!this.wot.getSetting("fixedColumnsLeft")&&!this.wot.getSetting("rowHeaders").length)}},{key:"resetFixedPosition",value:function(){if(this.needFullRender&&this.wot.wtTable.holder.parentNode){var e=this.clone.wtTable.holder.parentNode,t=0,o=this.wot.getSetting("preventOverflow");if(this.trimmingContainer!==window||o&&"horizontal"===o)t=this.getScrollPosition(),(0,l.resetCssTransform)(e);else{var n=this.wot.wtTable.hider.getBoundingClientRect(),r=Math.ceil(n.left),i=Math.ceil(n.right),s=void 0,a=void 0;a=this.wot.wtTable.hider.style.top,a=""===a?0:a,s=0>r&&i-e.offsetWidth>0?-r:0,t=s,s+="px",(0,l.setOverlayPosition)(e,s,a)}this.adjustHeaderBordersPosition(t),this.adjustElementsSize()}}},{key:"setScrollPosition",value:function(e){this.mainTableScrollableElement===window?window.scrollTo(e,(0,l.getWindowScrollTop)()):this.mainTableScrollableElement.scrollLeft=e}},{key:"onScroll",value:function(){this.wot.getSetting("onScrollVertically")}},{key:"sumCellSizes",value:function(e,t){for(var o=0,n=this.wot.wtSettings.defaultColumnWidth;t>e;)o+=this.wot.wtTable.getStretchedColumnWidth(e)||n,e++;return o}},{key:"adjustElementsSize",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this.updateTrimmingContainer(),(this.needFullRender||e)&&(this.adjustRootElementSize(),this.adjustRootChildrenSize(),e||(this.areElementSizesAdjusted=!0))}},{key:"adjustRootElementSize",value:function(){var e=this.wot.wtTable.holder,t=e.clientHeight===e.offsetHeight?0:(0,l.getScrollbarWidth)(),o=this.clone.wtTable.holder.parentNode,n=o.style,r=this.wot.getSetting("preventOverflow"),i=void 0;if(this.trimmingContainer!==window||"vertical"===r){var s=this.wot.wtViewport.getWorkspaceHeight()-t;s=Math.min(s,(0,l.innerHeight)(this.wot.wtTable.wtRootElement)),n.height=s+"px"}else n.height="";this.clone.wtTable.holder.style.height=n.height,i=(0,l.outerWidth)(this.clone.wtTable.TABLE),n.width=(0===i?i:i+4)+"px"}},{key:"adjustRootChildrenSize",value:function(){var e=(0,l.getScrollbarWidth)();this.clone.wtTable.hider.style.height=this.hider.style.height,this.clone.wtTable.holder.style.height=this.clone.wtTable.holder.parentNode.style.height,0===e&&(e=30),this.clone.wtTable.holder.style.width=parseInt(this.clone.wtTable.holder.parentNode.style.width,10)+e+"px"}},{key:"applyToDOM",value:function(){var e=this.wot.getSetting("totalColumns");if(this.areElementSizesAdjusted||this.adjustElementsSize(),"number"==typeof this.wot.wtViewport.columnsRenderCalculator.startPosition)this.spreader.style.left=this.wot.wtViewport.columnsRenderCalculator.startPosition+"px";else{if(0!==e)throw Error("Incorrect value of the columnsRenderCalculator");this.spreader.style.left="0"}this.spreader.style.right="",this.needFullRender&&this.syncOverlayOffset()}},{key:"syncOverlayOffset",value:function(){this.clone.wtTable.spreader.style.top="number"==typeof this.wot.wtViewport.rowsRenderCalculator.startPosition?this.wot.wtViewport.rowsRenderCalculator.startPosition+"px":""}},{key:"scrollTo",value:function(e,t){var o=this.getTableParentOffset(),n=this.wot.cloneSource?this.wot.cloneSource:this.wot,r=n.wtTable.holder,i=0;t&&r.offsetWidth!==r.clientWidth&&(i=(0,l.getScrollbarWidth)()),t?(o+=this.sumCellSizes(0,e+1),o-=this.wot.wtViewport.getViewportWidth()):o+=this.sumCellSizes(this.wot.getSetting("fixedColumnsLeft"),e),o+=i,this.setScrollPosition(o)}},{key:"getTableParentOffset",value:function(){var e=this.wot.getSetting("preventOverflow"),t=0;return e||this.trimmingContainer!==window||(t=this.wot.wtTable.holderOffset.left),t}},{key:"getScrollPosition",value:function(){return(0,l.getScrollLeft)(this.mainTableScrollableElement)}},{key:"adjustHeaderBordersPosition",value:function(e){var t=this.wot.wtTable.holder.parentNode,o=this.wot.getSetting("rowHeaders"),n=this.wot.getSetting("fixedColumnsLeft");if(this.wot.getSetting("totalRows")?(0,l.removeClass)(t,"emptyRows"):(0,l.addClass)(t,"emptyRows"),n&&!o.length)(0,l.addClass)(t,"innerBorderLeft");else if(!n&&o.length){var r=(0,l.hasClass)(t,"innerBorderLeft");e?(0,l.addClass)(t,"innerBorderLeft"):(0,l.removeClass)(t,"innerBorderLeft"),(!r&&e||r&&!e)&&this.wot.wtOverlays.adjustElementsSize()}}}]),t}(u.default);u.default.registerOverlay(u.default.CLONE_LEFT,c),t.default=c},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var s=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),l=o(0),a=o(31),u=function(e){return e&&e.__esModule?e:{default:e}}(a),c=function(e){function t(e){n(this,t);var o=r(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.clone=o.makeClone(u.default.CLONE_TOP),o}return i(t,e),s(t,[{key:"shouldBeRendered",value:function(){return!(!this.wot.getSetting("fixedRowsTop")&&!this.wot.getSetting("columnHeaders").length)}},{key:"resetFixedPosition",value:function(){if(this.needFullRender&&this.wot.wtTable.holder.parentNode){var e=this.clone.wtTable.holder.parentNode,t=0,o=this.wot.getSetting("preventOverflow");if(this.trimmingContainer!==window||o&&"vertical"===o)t=this.getScrollPosition(),(0,l.resetCssTransform)(e);else{var n=this.wot.wtTable.hider.getBoundingClientRect(),r=Math.ceil(n.top),i=Math.ceil(n.bottom),s=void 0,a=void 0;s=this.wot.wtTable.hider.style.left,s=""===s?0:s,a=0>r&&i-e.offsetHeight>0?-r:0,t=a,a+="px",(0,l.setOverlayPosition)(e,s,a)}this.adjustHeaderBordersPosition(t),this.adjustElementsSize()}}},{key:"setScrollPosition",value:function(e){this.mainTableScrollableElement===window?window.scrollTo((0,l.getWindowScrollLeft)(),e):this.mainTableScrollableElement.scrollTop=e}},{key:"onScroll",value:function(){this.wot.getSetting("onScrollHorizontally")}},{key:"sumCellSizes",value:function(e,t){for(var o=0,n=this.wot.wtSettings.settings.defaultRowHeight;t>e;){var r=this.wot.wtTable.getRowHeight(e);o+=void 0===r?n:r,e++}return o}},{key:"adjustElementsSize",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this.updateTrimmingContainer(),(this.needFullRender||e)&&(this.adjustRootElementSize(),this.adjustRootChildrenSize(),e||(this.areElementSizesAdjusted=!0))}},{key:"adjustRootElementSize",value:function(){var e=this.wot.wtTable.holder,t=e.clientWidth===e.offsetWidth?0:(0,l.getScrollbarWidth)(),o=this.clone.wtTable.holder.parentNode,n=o.style,r=this.wot.getSetting("preventOverflow"),i=void 0;if(this.trimmingContainer!==window||"horizontal"===r){var s=this.wot.wtViewport.getWorkspaceWidth()-t;s=Math.min(s,(0,l.innerWidth)(this.wot.wtTable.wtRootElement)),n.width=s+"px"}else n.width="";this.clone.wtTable.holder.style.width=n.width,i=(0,l.outerHeight)(this.clone.wtTable.TABLE),n.height=(0===i?i:i+4)+"px"}},{key:"adjustRootChildrenSize",value:function(){var e=(0,l.getScrollbarWidth)();this.clone.wtTable.hider.style.width=this.hider.style.width,this.clone.wtTable.holder.style.width=this.clone.wtTable.holder.parentNode.style.width,0===e&&(e=30),this.clone.wtTable.holder.style.height=parseInt(this.clone.wtTable.holder.parentNode.style.height,10)+e+"px"}},{key:"applyToDOM",value:function(){var e=this.wot.getSetting("totalRows");if(this.areElementSizesAdjusted||this.adjustElementsSize(),"number"==typeof this.wot.wtViewport.rowsRenderCalculator.startPosition)this.spreader.style.top=this.wot.wtViewport.rowsRenderCalculator.startPosition+"px";else{if(0!==e)throw Error("Incorrect value of the rowsRenderCalculator");this.spreader.style.top="0"}this.spreader.style.bottom="",this.needFullRender&&this.syncOverlayOffset()}},{key:"syncOverlayOffset",value:function(){this.clone.wtTable.spreader.style.left="number"==typeof this.wot.wtViewport.columnsRenderCalculator.startPosition?this.wot.wtViewport.columnsRenderCalculator.startPosition+"px":""}},{key:"scrollTo",value:function(e,t){var o=this.getTableParentOffset(),n=this.wot.cloneSource?this.wot.cloneSource:this.wot,r=n.wtTable.holder,i=0;if(t&&r.offsetHeight!==r.clientHeight&&(i=(0,l.getScrollbarWidth)()),t){var s=this.wot.getSetting("fixedRowsBottom"),a=(this.wot.getSetting("fixedRowsTop"),this.wot.getSetting("totalRows"));o+=this.sumCellSizes(0,e+1),o-=this.wot.wtViewport.getViewportHeight()-this.sumCellSizes(a-s,a),o+=1}else o+=this.sumCellSizes(this.wot.getSetting("fixedRowsTop"),e);o+=i,this.setScrollPosition(o)}},{key:"getTableParentOffset",value:function(){return this.mainTableScrollableElement===window?this.wot.wtTable.holderOffset.top:0}},{key:"getScrollPosition",value:function(){return(0,l.getScrollTop)(this.mainTableScrollableElement)}},{key:"redrawSelectionBorders",value:function(e){if(e&&e.cellRange){var t=e.getBorder(this.wot);if(t){var o=e.getCorners();t.disappear(),t.appear(o)}}}},{key:"redrawAllSelectionsBorders",value:function(){var e=this.wot.selections;this.redrawSelectionBorders(e.current),this.redrawSelectionBorders(e.area),this.redrawSelectionBorders(e.fill),this.wot.wtTable.wot.wtOverlays.leftOverlay.refresh()}},{key:"adjustHeaderBordersPosition",value:function(e){var t=this.wot.wtTable.holder.parentNode;if(this.wot.getSetting("totalColumns")?(0,l.removeClass)(t,"emptyColumns"):(0,l.addClass)(t,"emptyColumns"),0===this.wot.getSetting("fixedRowsTop")&&this.wot.getSetting("columnHeaders").length>0){var o=(0,l.hasClass)(t,"innerBorderTop");e||0===this.wot.getSetting("totalRows")?(0,l.addClass)(t,"innerBorderTop"):(0,l.removeClass)(t,"innerBorderTop"),(!o&&e||o&&!e)&&(this.wot.wtOverlays.adjustElementsSize(),this.redrawAllSelectionsBorders())}if(0===this.wot.getSetting("rowHeaders").length){var n=this.clone.wtTable.THEAD.querySelectorAll("th:nth-of-type(2)");if(n)for(var r=0;n.length>r;r++)n[r].style["border-left-width"]=0}}}]),t}(u.default);u.default.registerOverlay(u.default.CLONE_TOP,c),t.default=c},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var s=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),l=o(0),a=o(31),u=function(e){return e&&e.__esModule?e:{default:e}}(a),c=function(e){function t(e){n(this,t);var o=r(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.clone=o.makeClone(u.default.CLONE_TOP_LEFT_CORNER),o}return i(t,e),s(t,[{key:"shouldBeRendered",value:function(){return!(!this.wot.getSetting("fixedRowsTop")&&!this.wot.getSetting("columnHeaders").length||!this.wot.getSetting("fixedColumnsLeft")&&!this.wot.getSetting("rowHeaders").length)}},{key:"resetFixedPosition",value:function(){if(this.updateTrimmingContainer(),this.wot.wtTable.holder.parentNode){var e=this.clone.wtTable.holder.parentNode,t=(0,l.outerHeight)(this.clone.wtTable.TABLE),o=(0,l.outerWidth)(this.clone.wtTable.TABLE),n=this.wot.getSetting("preventOverflow");if(this.trimmingContainer===window){var r=this.wot.wtTable.hider.getBoundingClientRect(),i=Math.ceil(r.top),s=Math.ceil(r.left),a=Math.ceil(r.bottom),u=Math.ceil(r.right),c="0",h="0";n&&"vertical"!==n||0>s&&u-e.offsetWidth>0&&(c=-s+"px"),n&&"horizontal"!==n||0>i&&a-e.offsetHeight>0&&(h=-i+"px"),(0,l.setOverlayPosition)(e,c,h)}else(0,l.resetCssTransform)(e);e.style.height=(0===t?t:t+4)+"px",e.style.width=(0===o?o:o+4)+"px"}}}]),t}(u.default);u.default.registerOverlay(u.default.CLONE_TOP_LEFT_CORNER,c),t.default=c},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},s=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),l=o(0),a=o(167),u=n(a),c=o(49),h=n(c),d=o(79),f=n(d);t.default=function(){function e(t,o){r(this,e),this.settings=t,this.cellRange=o||null,this.instanceBorders={}}return s(e,[{key:"getBorder",value:function(e){if(this.instanceBorders[e.guid])return this.instanceBorders[e.guid];this.instanceBorders[e.guid]=new u.default(e,this.settings)}},{key:"isEmpty",value:function(){return null===this.cellRange}},{key:"add",value:function(e){this.isEmpty()?this.cellRange=new f.default(e,e,e):this.cellRange.expand(e)}},{key:"replace",value:function(e,t){if(!this.isEmpty()){if(this.cellRange.from.isEqual(e))return this.cellRange.from=t,!0;if(this.cellRange.to.isEqual(e))return this.cellRange.to=t,!0}return!1}},{key:"clear",value:function(){this.cellRange=null}},{key:"getCorners",value:function(){var e=this.cellRange.getTopLeftCorner(),t=this.cellRange.getBottomRightCorner();return[e.row,e.col,t.row,t.col]}},{key:"addClassAtCoords",value:function(e,t,o,n){var r=e.wtTable.getCell(new h.default(t,o));"object"===(void 0===r?"undefined":i(r))&&(0,l.addClass)(r,n)}},{key:"draw",value:function(e){if(this.isEmpty()){if(this.settings.border){var t=this.getBorder(e);t&&t.disappear()}}else{for(var o=e.wtTable.getRenderedRowsCount(),n=e.wtTable.getRenderedColumnsCount(),r=this.getCorners(),i=void 0,s=void 0,a=void 0,u=0;n>u;u++)if((s=e.wtTable.columnFilter.renderedToSource(u))>=r[1]&&r[3]>=s&&(a=e.wtTable.getColumnHeader(s))){var c=[];this.settings.highlightHeaderClassName&&c.push(this.settings.highlightHeaderClassName),this.settings.highlightColumnClassName&&c.push(this.settings.highlightColumnClassName),(0,l.addClass)(a,c)}for(var h=0;o>h;h++){if((i=e.wtTable.rowFilter.renderedToSource(h))>=r[0]&&r[2]>=i&&(a=e.wtTable.getRowHeader(i))){var d=[];this.settings.highlightHeaderClassName&&d.push(this.settings.highlightHeaderClassName),this.settings.highlightRowClassName&&d.push(this.settings.highlightRowClassName),(0,l.addClass)(a,d)}for(var f=0;n>f;f++)s=e.wtTable.columnFilter.renderedToSource(f),r[0]>i||i>r[2]||r[1]>s||s>r[3]?r[0]>i||i>r[2]?r[1]>s||s>r[3]||this.settings.highlightColumnClassName&&this.addClassAtCoords(e,i,s,this.settings.highlightColumnClassName):this.settings.highlightRowClassName&&this.addClassAtCoords(e,i,s,this.settings.highlightRowClassName):this.settings.className&&this.addClassAtCoords(e,i,s,this.settings.className)}if(e.getSetting("onBeforeDrawBorders",r,this.settings.className),this.settings.border){var p=this.getBorder(e);p&&p.appear(r)}}}}]),e}()},function(e,t,o){"use strict";function n(){function e(e){return e.currentStyle||document.defaultView.getComputedStyle(e)}var t,o={minHeight:200,maxHeight:300,minWidth:100,maxWidth:300},n=document.body,r=document.createTextNode(""),i=document.createElement("SPAN"),s=function(e,t,o){e.attachEvent?e.attachEvent("on"+t,o):e.addEventListener(t,o,!1)},l=function(e,t,o){e.removeEventListener?e.removeEventListener(t,o,!1):e.detachEvent("on"+t,o)},a=function(s){var l,a;s?/^[a-zA-Z \.,\\\/\|0-9]$/.test(s)||(s="."):s="",void 0!==r.textContent?r.textContent=t.value+s:r.data=t.value+s,i.style.fontSize=e(t).fontSize,i.style.fontFamily=e(t).fontFamily,i.style.whiteSpace="pre",n.appendChild(i),l=i.clientWidth+2,n.removeChild(i),t.style.height=o.minHeight+"px",t.style.width=o.minWidth>l?o.minWidth+"px":l>o.maxWidth?o.maxWidth+"px":l+"px",a=t.scrollHeight?t.scrollHeight-1:0,o.minHeight>a?t.style.height=o.minHeight+"px":a>o.maxHeight?(t.style.height=o.maxHeight+"px",t.style.overflowY="visible"):t.style.height=a+"px"},u=function(){window.setTimeout(a,0)},c=function(e){if(e&&e.minHeight)if("inherit"==e.minHeight)o.minHeight=t.clientHeight;else{var n=parseInt(e.minHeight);isNaN(n)||(o.minHeight=n)}if(e&&e.maxHeight)if("inherit"==e.maxHeight)o.maxHeight=t.clientHeight;else{var s=parseInt(e.maxHeight);isNaN(s)||(o.maxHeight=s)}if(e&&e.minWidth)if("inherit"==e.minWidth)o.minWidth=t.clientWidth;else{var l=parseInt(e.minWidth);isNaN(l)||(o.minWidth=l)}if(e&&e.maxWidth)if("inherit"==e.maxWidth)o.maxWidth=t.clientWidth;else{var a=parseInt(e.maxWidth);isNaN(a)||(o.maxWidth=a)}i.firstChild||(i.className="autoResize",i.style.display="inline-block",i.appendChild(r))},h=function(e,n,r){t=e,c(n),"TEXTAREA"==t.nodeName&&(t.style.resize="none",t.style.overflowY="",t.style.height=o.minHeight+"px",t.style.minWidth=o.minWidth+"px",t.style.maxWidth=o.maxWidth+"px",t.style.overflowY="hidden"),r&&(s(t,"change",a),s(t,"cut",u),s(t,"paste",u),s(t,"drop",u),s(t,"keydown",u),s(t,"focus",a)),a()};return{init:function(e,t,o){h(e,t,o)},unObserve:function(){l(t,"change",a),l(t,"cut",u),l(t,"paste",u),l(t,"drop",u),l(t,"keydown",u),l(t,"focus",a)},resize:a}}e.exports=n},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var s=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),l=o(41),a=function(e){return e&&e.__esModule?e:{default:e}}(l),u=o(0);t.default=function(e){function t(){return n(this,t),r(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return i(t,e),s(t,[{key:"beginEditing",value:function(e,t){if(void 0===t){var o=this.TD.querySelector('input[type="checkbox"]');(0,u.hasClass)(o,"htBadValue")||o.click()}}},{key:"finishEditing",value:function(){}},{key:"init",value:function(){}},{key:"open",value:function(){}},{key:"close",value:function(){}},{key:"getValue",value:function(){}},{key:"setValue",value:function(){}},{key:"focus",value:function(){}}]),t}(a.default)},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var l=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),a=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},u=o(50),c=n(u),h=o(213),d=n(h);o(214);var f=o(0),p=o(1),g=o(4),v=n(g),m=o(18),y=o(10),w=o(51),C=n(w);t.default=function(e){function t(e){r(this,t);var o=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.defaultDateFormat="DD/MM/YYYY",o.isCellEdited=!1,o.parentDestroyed=!1,o}return s(t,e),l(t,[{key:"init",value:function(){var e=this;if("function"!=typeof c.default)throw Error("You need to include moment.js to your project.");if("function"!=typeof d.default)throw Error("You need to include Pikaday to your project.");a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"init",this).call(this),this.instance.addHook("afterDestroy",function(){e.parentDestroyed=!0,e.destroyElements()})}},{key:"createElements",value:function(){a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"createElements",this).call(this),this.datePicker=document.createElement("DIV"),this.datePickerStyle=this.datePicker.style,this.datePickerStyle.position="absolute",this.datePickerStyle.top=0,this.datePickerStyle.left=0,this.datePickerStyle.zIndex=9999,(0,f.addClass)(this.datePicker,"htDatepickerHolder"),document.body.appendChild(this.datePicker),this.$datePicker=new d.default(this.getDatePickerConfig()),new v.default(this).addEventListener(this.datePicker,"mousedown",function(e){return(0,y.stopPropagation)(e)}),this.hideDatepicker()}},{key:"destroyElements",value:function(){this.$datePicker.destroy()}},{key:"prepare",value:function(e,o,n,r,i,s){this._opened=!1,a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"prepare",this).call(this,e,o,n,r,i,s)}},{key:"open",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"open",this).call(this),this.showDatepicker(e)}},{key:"close",value:function(){var e=this;this._opened=!1,this.instance._registerTimeout(setTimeout(function(){e.instance.selection.refreshBorders()},0)),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"close",this).call(this)}},{key:"finishEditing",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],o=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(e){var n=this.originalValue;void 0!==n&&this.setValue(n)}this.hideDatepicker(),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"finishEditing",this).call(this,e,o)}},{key:"showDatepicker",value:function(e){this.$datePicker.config(this.getDatePickerConfig());var t=this.TD.getBoundingClientRect(),o=this.cellProperties.dateFormat||this.defaultDateFormat,n=this.$datePicker.config(),r=void 0,i=this.instance.view.isMouseDown(),s=!!e&&(0,m.isMetaKey)(e.keyCode);this.datePickerStyle.top=window.pageYOffset+t.top+(0,f.outerHeight)(this.TD)+"px",this.datePickerStyle.left=window.pageXOffset+t.left+"px",this.$datePicker._onInputFocus=function(){},n.format=o,this.originalValue?(r=this.originalValue,(0,c.default)(r,o,!0).isValid()&&this.$datePicker.setMoment((0,c.default)(r,o),!0),this.getValue()!==this.originalValue&&this.setValue(this.originalValue),s||i||this.setValue("")):this.cellProperties.defaultDate?(r=this.cellProperties.defaultDate,n.defaultDate=r,(0,c.default)(r,o,!0).isValid()&&this.$datePicker.setMoment((0,c.default)(r,o),!0),s||i||this.setValue("")):this.$datePicker.gotoToday(),this.datePickerStyle.display="block",this.$datePicker.show()}},{key:"hideDatepicker",value:function(){this.datePickerStyle.display="none",this.$datePicker.hide()}},{key:"getDatePickerConfig",value:function(){var e=this,t=this.TEXTAREA,o={};this.cellProperties&&this.cellProperties.datePickerConfig&&(0,p.deepExtend)(o,this.cellProperties.datePickerConfig);var n=o.onSelect,r=o.onClose;return o.field=t,o.trigger=t,o.container=this.datePicker,o.bound=!1,o.format=o.format||this.defaultDateFormat,o.reposition=o.reposition||!1,o.onSelect=function(t){isNaN(t.getTime())||(t=(0,c.default)(t).format(e.cellProperties.dateFormat||e.defaultDateFormat)),e.setValue(t),e.hideDatepicker(),n&&n()},o.onClose=function(){e.parentDestroyed||e.finishEditing(!1),r&&r()},o}}]),t}(C.default)},function(e,t){e.exports=o},function(e,t){},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var l=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),a=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},u=o(168),c=n(u),h=o(7),d=n(h),f=function(e){function t(){return r(this,t),i(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return s(t,e),l(t,[{key:"prepare",value:function(e,o,n,r,i,s){a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"prepare",this).call(this,e,o,n,r,i,s),this.cellProperties.filter=!1,this.cellProperties.strict=!0}}]),t}(c.default);d.default.getSingleton().add("beforeValidate",function(e,t,o,n){var r=this.getCellMeta(t,this.propToCol(o));r.editor===f&&void 0===r.strict&&(r.filter=!1,r.strict=!0)}),t.default=f},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}t.__esModule=!0;var r=o(18),i=o(10),s=o(0),l=o(41),a=n(l),u=o(4),c=n(u),h=a.default.prototype.extend(),d={},f=function(){this.controls={},this.controls.leftButton=document.createElement("DIV"),this.controls.leftButton.className="leftButton",this.controls.rightButton=document.createElement("DIV"),this.controls.rightButton.className="rightButton",this.controls.upButton=document.createElement("DIV"),this.controls.upButton.className="upButton",this.controls.downButton=document.createElement("DIV"),this.controls.downButton.className="downButton";for(var e in this.controls)Object.prototype.hasOwnProperty.call(this.controls,e)&&this.positionControls.appendChild(this.controls[e])};h.prototype.valueChanged=function(){return this.initValue!=this.getValue()},h.prototype.init=function(){var e=this;this.eventManager=new c.default(this.instance),this.createElements(),this.bindEvents(),this.instance.addHook("afterDestroy",function(){e.destroy()})},h.prototype.getValue=function(){return this.TEXTAREA.value},h.prototype.setValue=function(e){this.initValue=e,this.TEXTAREA.value=e},h.prototype.createElements=function(){this.editorContainer=document.createElement("DIV"),this.editorContainer.className="htMobileEditorContainer",this.cellPointer=document.createElement("DIV"),this.cellPointer.className="cellPointer",this.moveHandle=document.createElement("DIV"),this.moveHandle.className="moveHandle",this.inputPane=document.createElement("DIV"),this.inputPane.className="inputs",this.positionControls=document.createElement("DIV"),this.positionControls.className="positionControls",this.TEXTAREA=document.createElement("TEXTAREA"),(0,s.addClass)(this.TEXTAREA,"handsontableInput"),this.inputPane.appendChild(this.TEXTAREA),this.editorContainer.appendChild(this.cellPointer),this.editorContainer.appendChild(this.moveHandle),this.editorContainer.appendChild(this.inputPane),this.editorContainer.appendChild(this.positionControls),f.call(this),document.body.appendChild(this.editorContainer)},h.prototype.onBeforeKeyDown=function(e){var t=this,o=t.getActiveEditor();if(e.target===o.TEXTAREA&&!(0,i.isImmediatePropagationStopped)(e))switch(e.keyCode){case r.KEY_CODES.ENTER:o.close(),e.preventDefault();break;case r.KEY_CODES.BACKSPACE:(0,i.stopImmediatePropagation)(e)}},h.prototype.open=function(){this.instance.addHook("beforeKeyDown",this.onBeforeKeyDown),(0,s.addClass)(this.editorContainer,"active"),(0,s.removeClass)(this.cellPointer,"hidden"),this.updateEditorPosition()},h.prototype.focus=function(){this.TEXTAREA.focus(),(0,s.setCaretPosition)(this.TEXTAREA,this.TEXTAREA.value.length)},h.prototype.close=function(){this.TEXTAREA.blur(),this.instance.removeHook("beforeKeyDown",this.onBeforeKeyDown),(0,s.removeClass)(this.editorContainer,"active")},h.prototype.scrollToView=function(){this.instance.view.scrollViewport(this.instance.getSelectedRange().highlight)},h.prototype.hideCellPointer=function(){(0,s.hasClass)(this.cellPointer,"hidden")||(0,s.addClass)(this.cellPointer,"hidden")},h.prototype.updateEditorPosition=function(e,t){if(e&&t)e=parseInt(e,10),t=parseInt(t,10),this.editorContainer.style.top=t+"px",this.editorContainer.style.left=e+"px";else{var o=this.instance.getSelected(),n=this.instance.getCell(o[0],o[1]);if(d.cellPointer||(d.cellPointer={height:(0,s.outerHeight)(this.cellPointer),width:(0,s.outerWidth)(this.cellPointer)}),d.editorContainer||(d.editorContainer={width:(0,s.outerWidth)(this.editorContainer)}),void 0!==n){var r=this.instance.view.wt.wtOverlays.leftOverlay.trimmingContainer==window?0:(0,s.getScrollLeft)(this.instance.view.wt.wtOverlays.leftOverlay.holder),i=this.instance.view.wt.wtOverlays.topOverlay.trimmingContainer==window?0:(0,s.getScrollTop)(this.instance.view.wt.wtOverlays.topOverlay.holder),l=(0,s.offset)(n),a=(0,s.outerWidth)(n),u={x:r,y:i};this.editorContainer.style.top=parseInt(l.top+(0,s.outerHeight)(n)-u.y+d.cellPointer.height,10)+"px",this.editorContainer.style.left=parseInt(window.innerWidth/2-d.editorContainer.width/2,10)+"px",l.left+a/2>parseInt(this.editorContainer.style.left,10)+d.editorContainer.width?this.editorContainer.style.left=window.innerWidth-d.editorContainer.width+"px":l.left+a/2<parseInt(this.editorContainer.style.left,10)+20&&(this.editorContainer.style.left="0px"),this.cellPointer.style.left=parseInt(l.left-d.cellPointer.width/2-(0,s.offset)(this.editorContainer).left+a/2-u.x,10)+"px"}}},h.prototype.updateEditorData=function(){var e=this.instance.getSelected(),t=this.instance.getDataAtCell(e[0],e[1]);this.row=e[0],this.col=e[1],this.setValue(t),this.updateEditorPosition()},h.prototype.prepareAndSave=function(){var e;this.valueChanged()&&(e=this.instance.getSettings().trimWhitespace?[[String.prototype.trim.call(this.getValue())]]:[[this.getValue()]],this.saveValue(e))},h.prototype.bindEvents=function(){var e=this;this.eventManager.addEventListener(this.controls.leftButton,"touchend",function(t){e.prepareAndSave(),e.instance.selection.transformStart(0,-1,null,!0),e.updateEditorData(),t.preventDefault()}),this.eventManager.addEventListener(this.controls.rightButton,"touchend",function(t){e.prepareAndSave(),e.instance.selection.transformStart(0,1,null,!0),e.updateEditorData(),t.preventDefault()}),this.eventManager.addEventListener(this.controls.upButton,"touchend",function(t){e.prepareAndSave(),e.instance.selection.transformStart(-1,0,null,!0),e.updateEditorData(),t.preventDefault()}),this.eventManager.addEventListener(this.controls.downButton,"touchend",function(t){e.prepareAndSave(),e.instance.selection.transformStart(1,0,null,!0),e.updateEditorData(),t.preventDefault()}),this.eventManager.addEventListener(this.moveHandle,"touchstart",function(t){if(1==t.touches.length){var o=t.touches[0],n={x:e.editorContainer.offsetLeft,y:e.editorContainer.offsetTop},r={x:o.pageX-n.x,y:o.pageY-n.y};e.eventManager.addEventListener(this,"touchmove",function(t){var o=t.touches[0];e.updateEditorPosition(o.pageX-r.x,o.pageY-r.y),e.hideCellPointer(),t.preventDefault()})}}),this.eventManager.addEventListener(document.body,"touchend",function(t){(0,s.isChildOf)(t.target,e.editorContainer)||(0,s.isChildOf)(t.target,e.instance.rootElement)||e.close()}),this.eventManager.addEventListener(this.instance.view.wt.wtOverlays.leftOverlay.holder,"scroll",function(t){e.instance.view.wt.wtOverlays.leftOverlay.trimmingContainer!=window&&e.hideCellPointer()}),this.eventManager.addEventListener(this.instance.view.wt.wtOverlays.topOverlay.holder,"scroll",function(t){e.instance.view.wt.wtOverlays.topOverlay.trimmingContainer!=window&&e.hideCellPointer()})},h.prototype.destroy=function(){this.eventManager.clear(),this.editorContainer.parentNode.removeChild(this.editorContainer)},t.default=h},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var l=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),a=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},u=o(80),c=n(u),h=o(51),d=n(h);t.default=function(e){function t(){return r(this,t),i(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return s(t,e),l(t,[{key:"beginEditing",value:function(e){if(void 0===e&&this.originalValue){void 0!==this.cellProperties.language&&c.default.culture(this.cellProperties.language);e=(""+this.originalValue).replace(".",c.default.cultureData().delimiters.decimal)}a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"beginEditing",this).call(this,e)}}]),t}(d.default)},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var s=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),l=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},a=o(0),u=o(51),c=function(e){return e&&e.__esModule?e:{default:e}}(u);t.default=function(e){function t(){return n(this,t),r(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return i(t,e),s(t,[{key:"createElements",value:function(){l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"createElements",this).call(this),this.TEXTAREA=document.createElement("input"),this.TEXTAREA.setAttribute("type","password"),this.TEXTAREA.className="handsontableInput",this.textareaStyle=this.TEXTAREA.style,this.textareaStyle.width=0,this.textareaStyle.height=0,(0,a.empty)(this.TEXTAREA_PARENT),this.TEXTAREA_PARENT.appendChild(this.TEXTAREA)}}]),t}(c.default)},function(e,t,o){"use strict";t.__esModule=!0;var n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r=o(0),i=o(10),s=o(18),l=o(41),a=function(e){return e&&e.__esModule?e:{default:e}}(l),u=a.default.prototype.extend();u.prototype.init=function(){this.select=document.createElement("SELECT"),(0,r.addClass)(this.select,"htSelectEditor"),this.select.style.display="none",this.instance.rootElement.appendChild(this.select),this.registerHooks()},u.prototype.registerHooks=function(){var e=this;this.instance.addHook("afterScrollHorizontally",function(){return e.refreshDimensions()}),this.instance.addHook("afterScrollVertically",function(){return e.refreshDimensions()}),this.instance.addHook("afterColumnResize",function(){return e.refreshDimensions()}),this.instance.addHook("afterRowResize",function(){return e.refreshDimensions()})},u.prototype.prepare=function(){a.default.prototype.prepare.apply(this,arguments);var e,t=this.cellProperties.selectOptions;e=this.prepareOptions("function"==typeof t?t(this.row,this.col,this.prop):t),(0,r.empty)(this.select);for(var o in e)if(Object.prototype.hasOwnProperty.call(e,o)){var n=document.createElement("OPTION");n.value=o,(0,r.fastInnerHTML)(n,e[o]),this.select.appendChild(n)}},u.prototype.prepareOptions=function(e){var t={};if(Array.isArray(e))for(var o=0,r=e.length;r>o;o++)t[e[o]]=e[o];else"object"==(void 0===e?"undefined":n(e))&&(t=e);return t},u.prototype.getValue=function(){return this.select.value},u.prototype.setValue=function(e){this.select.value=e};var c=function(e){var t=this,o=t.getActiveEditor();switch(e.keyCode){case s.KEY_CODES.ARROW_UP:var n=o.select.selectedIndex-1;0>n||(o.select[n].selected=!0),(0,i.stopImmediatePropagation)(e),e.preventDefault();break;case s.KEY_CODES.ARROW_DOWN:var r=o.select.selectedIndex+1;r>o.select.length-1||(o.select[r].selected=!0),(0,i.stopImmediatePropagation)(e),e.preventDefault()}};u.prototype.open=function(){this._opened=!0,this.refreshDimensions(),this.select.style.display="",this.instance.addHook("beforeKeyDown",c)},u.prototype.close=function(){this._opened=!1,this.select.style.display="none",this.instance.removeHook("beforeKeyDown",c)},u.prototype.focus=function(){this.select.focus()},u.prototype.refreshValue=function(){var e=this.instance.getSourceDataAtCell(this.row,this.prop);this.originalValue=e,this.setValue(e),this.refreshDimensions()},u.prototype.refreshDimensions=function(){if(this.state===l.EditorState.EDITING){if(!(this.TD=this.getEditedCell()))return void this.close();var e,t=(0,r.outerWidth)(this.TD)+1,o=(0,r.outerHeight)(this.TD)+1,n=(0,r.offset)(this.TD),i=(0,r.offset)(this.instance.rootElement),s=(0,r.getScrollableElement)(this.TD),a=n.top-i.top-1-(s.scrollTop||0),u=n.left-i.left-1-(s.scrollLeft||0),c=this.checkEditorSection();this.instance.getSettings();switch(c){case"top":e=(0,r.getCssTransform)(this.instance.view.wt.wtOverlays.topOverlay.clone.wtTable.holder.parentNode);break;case"left":e=(0,r.getCssTransform)(this.instance.view.wt.wtOverlays.leftOverlay.clone.wtTable.holder.parentNode);break;case"top-left-corner":e=(0,r.getCssTransform)(this.instance.view.wt.wtOverlays.topLeftCornerOverlay.clone.wtTable.holder.parentNode);break;case"bottom-left-corner":e=(0,r.getCssTransform)(this.instance.view.wt.wtOverlays.bottomLeftCornerOverlay.clone.wtTable.holder.parentNode);break;case"bottom":e=(0,r.getCssTransform)(this.instance.view.wt.wtOverlays.bottomOverlay.clone.wtTable.holder.parentNode)}0===this.instance.getSelected()[0]&&(a+=1),0===this.instance.getSelected()[1]&&(u+=1);var h=this.select.style;e&&-1!=e?h[e[0]]=e[1]:(0,r.resetCssTransform)(this.select);var d=(0,r.getComputedStyle)(this.TD);parseInt(d.borderTopWidth,10)>0&&(o-=1),parseInt(d.borderLeftWidth,10)>0&&(t-=1),h.height=o+"px",h.minWidth=t+"px",h.top=a+"px",h.left=u+"px",h.margin="0px"}},u.prototype.getEditedCell=function(){var e,t=this.checkEditorSection();switch(t){case"top":e=this.instance.view.wt.wtOverlays.topOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.select.style.zIndex=101;break;case"corner":e=this.instance.view.wt.wtOverlays.topLeftCornerOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.select.style.zIndex=103;break;case"left":e=this.instance.view.wt.wtOverlays.leftOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.select.style.zIndex=102;break;default:e=this.instance.getCell(this.row,this.col),this.select.style.zIndex=""}return-1!=e&&-2!=e?e:void 0},t.default=u},function(e,t,o){"use strict";function n(e,t,o,n,i,s,l){l.className&&(t.className=t.className?t.className+" "+l.className:l.className),l.readOnly&&(0,r.addClass)(t,l.readOnlyCellClassName),!1===l.valid&&l.invalidCellClassName?(0,r.addClass)(t,l.invalidCellClassName):(0,r.removeClass)(t,l.invalidCellClassName),!1===l.wordWrap&&l.noWordWrapClassName&&(0,r.addClass)(t,l.noWordWrapClassName),!s&&l.placeholder&&(0,r.addClass)(t,l.placeholderCellClassName)}t.__esModule=!0;var r=o(0);t.default=n},function(e,t,o){"use strict";function n(e,t,o,n,i,h,d){var f=(u.cloneNode(!0),c.cloneNode(!0));if(d.allowHtml?(0,a.getRenderer)("html").apply(this,arguments):(0,a.getRenderer)("text").apply(this,arguments),t.appendChild(f),(0,r.addClass)(t,"htAutocomplete"),t.firstChild||t.appendChild(document.createTextNode(String.fromCharCode(160))),!e.acArrowListener){var p=new s.default(e);e.acArrowListener=function(i){(0,r.hasClass)(i.target,"htAutocompleteArrow")&&e.view.wt.getSetting("onCellDblClick",null,new l.CellCoords(o,n),t)},p.addEventListener(e.rootElement,"mousedown",e.acArrowListener),e.addHookOnce("afterDestroy",function(){p.destroy()})}}t.__esModule=!0;var r=o(0),i=o(4),s=function(e){return e&&e.__esModule?e:{default:e}}(i),l=o(12),a=o(8),u=document.createElement("DIV");u.className="htAutocompleteWrapper";var c=document.createElement("DIV");c.className="htAutocompleteArrow",c.appendChild(document.createTextNode(String.fromCharCode(9660)));t.default=n},function(e,t,o){"use strict";function n(e,t,o,n,l,a,u){function c(e){var t=(0,v.partial)(g.isKey,e.keyCode);t("SPACE|ENTER|DELETE|BACKSPACE")&&!(0,m.isImmediatePropagationStopped)(e)&&p(function(){(0,m.stopImmediatePropagation)(e),e.preventDefault()}),t("SPACE|ENTER")&&f(),t("DELETE|BACKSPACE")&&f(!0)}function f(){var t=arguments.length>0&&void 0!==arguments[0]&&arguments[0],o=e.getSelectedRange();if(o){for(var n=o.getTopLeftCorner(),r=o.getBottomRightCorner(),i=[],s=n.row;r.row>=s;s+=1)for(var l=n.col;r.col>=l;l+=1){var a=e.getCellMeta(s,l);if("checkbox"!==a.type)return;if(!0!==a.readOnly){void 0===a.checkedTemplate&&(a.checkedTemplate=!0),void 0===a.uncheckedTemplate&&(a.uncheckedTemplate=!1);var u=e.getDataAtCell(s,l);!1===t?u===a.checkedTemplate?i.push([s,l,a.uncheckedTemplate]):-1!==[a.uncheckedTemplate,null,void 0].indexOf(u)&&i.push([s,l,a.checkedTemplate]):i.push([s,l,a.uncheckedTemplate])}}i.length>0&&e.setDataAtCell(i)}}function p(t){var o=e.getSelectedRange();if(o)for(var n=o.getTopLeftCorner(),r=o.getBottomRightCorner(),i=n.row;r.row>=i;i++)for(var s=n.col;r.col>=s;s++){var l=e.getCellMeta(i,s);if("checkbox"!==l.type)return;var a=e.getCell(i,s);if(null==a)t(i,s,l);else{var u=a.querySelectorAll("input[type=checkbox]");u.length>0&&!l.readOnly&&t(u)}}}(0,y.getRenderer)("base").apply(this,arguments);var C=(r(e),i()),S=u.label,E=!1;if(void 0===u.checkedTemplate&&(u.checkedTemplate=!0),void 0===u.uncheckedTemplate&&(u.uncheckedTemplate=!1),(0,h.empty)(t),a===u.checkedTemplate||(0,d.equalsIgnoreCase)(a,u.checkedTemplate)?C.checked=!0:a===u.uncheckedTemplate||(0,d.equalsIgnoreCase)(a,u.uncheckedTemplate)?C.checked=!1:null===a?(0,h.addClass)(C,"noValue"):(C.style.display="none",(0,h.addClass)(C,b),E=!0),C.setAttribute("data-row",o),C.setAttribute("data-col",n),!E&&S){var R="";S.value?R="function"==typeof S.value?S.value.call(this,o,n,l,a):S.value:S.property&&(R=e.getDataAtRowProp(o,S.property));var O=s(R);"before"===S.position?O.appendChild(C):O.insertBefore(C,O.firstChild),C=O}t.appendChild(C),E&&t.appendChild(document.createTextNode("#bad-value#")),w.has(e)||(w.set(e,!0),e.addHook("beforeKeyDown",c))}function r(e){var t=C.get(e);return t||(t=new p.default(e),t.addEventListener(e.rootElement,"click",function(t){return a(t,e)}),t.addEventListener(e.rootElement,"mouseup",function(t){return l(t,e)}),t.addEventListener(e.rootElement,"change",function(t){return u(t,e)}),C.set(e,t)),t}function i(){var e=document.createElement("input");return e.className="htCheckboxRendererInput",e.type="checkbox",e.setAttribute("autocomplete","off"),e.setAttribute("tabindex","-1"),e.cloneNode(!1)}function s(e){var t=document.createElement("label");return t.className="htCheckboxRendererLabel",t.appendChild(document.createTextNode(e)),t.cloneNode(!0)}function l(e,t){c(e.target)&&setTimeout(t.listen,10)}function a(e,t){if(!c(e.target))return!1;t.getCellMeta(parseInt(e.target.getAttribute("data-row"),10),parseInt(e.target.getAttribute("data-col"),10)).readOnly&&e.preventDefault()}function u(e,t){if(!c(e.target))return!1;var o=parseInt(e.target.getAttribute("data-row"),10),n=parseInt(e.target.getAttribute("data-col"),10),r=t.getCellMeta(o,n);if(!r.readOnly){var i=null;i=e.target.checked?void 0===r.uncheckedTemplate||r.checkedTemplate:void 0!==r.uncheckedTemplate&&r.uncheckedTemplate,t.setDataAtCell(o,n,i)}}function c(e){return"INPUT"===e.tagName&&"checkbox"===e.getAttribute("type")}t.__esModule=!0;var h=o(0),d=o(32),f=o(4),p=function(e){return e&&e.__esModule?e:{default:e}}(f),g=o(18),v=o(35),m=o(10),y=o(8),w=new WeakMap,C=new WeakMap,b="htBadValue";t.default=n},function(e,t,o){"use strict";function n(e,t,o,n,s,l,a){(0,i.getRenderer)("base").apply(this,arguments),null!==l&&void 0!==l||(l=""),(0,r.fastInnerHTML)(t,l)}t.__esModule=!0;var r=o(0),i=o(8);t.default=n},function(e,t,o){"use strict";function n(e,t,o,n,r,a,u){if((0,l.isNumeric)(a)){void 0!==u.language&&i.default.culture(u.language),a=(0,i.default)(a).format(u.format||"0");var c=u.className||"",h=c.length?c.split(" "):[];0>h.indexOf("htLeft")&&0>h.indexOf("htCenter")&&0>h.indexOf("htRight")&&0>h.indexOf("htJustify")&&h.push("htRight"),0>h.indexOf("htNumeric")&&h.push("htNumeric"),u.className=h.join(" ")}(0,s.getRenderer)("text")(e,t,o,n,r,a,u)}t.__esModule=!0;var r=o(80),i=function(e){return e&&e.__esModule?e:{default:e}}(r),s=o(8),l=o(6);t.default=n},function(e,t,o){"use strict";function n(e,t,o,n,l,a,u){(0,i.getRenderer)("text").apply(this,arguments),a=t.innerHTML;var c=u.hashLength||a.length,h=u.hashSymbol||"*",d="";(0,s.rangeEach)(c-1,function(){d+=h}),(0,r.fastInnerHTML)(t,d)}t.__esModule=!0;var r=o(0),i=o(8),s=o(6);t.default=n},function(e,t,o){"use strict";function n(e,t,o,n,l,a,u){(0,s.getRenderer)("base").apply(this,arguments),!a&&u.placeholder&&(a=u.placeholder);var c=(0,i.stringify)(a);if(e.getSettings().trimWhitespace||(c=c.replace(/ /g,String.fromCharCode(160))),u.rendererTemplate){(0,r.empty)(t);var h=document.createElement("TEMPLATE");h.setAttribute("bind","{{}}"),h.innerHTML=u.rendererTemplate,HTMLTemplateElement.decorate(h),h.model=e.getSourceDataAtRow(o),t.appendChild(h)}else(0,r.fastInnerText)(t,c)}t.__esModule=!0;var r=o(0),i=o(22),s=o(8);t.default=n},function(e,t,o){"use strict";function n(e,t){if(null==e&&(e=""),this.allowEmpty&&""===e)return void t(!0);this.strict&&this.source?"function"==typeof this.source?this.source(e,r(e,t)):r(e,t)(this.source):t(!0)}function r(e,t){var o=e;return function(e){for(var n=!1,r=0,i=e.length;i>r;r++)if(o===e[r]){n=!0;break}t(n)}}t.__esModule=!0,t.default=n},function(e,t,o){"use strict";function n(e,t){var o=!0,n=(0,a.getEditorInstance)("date",this.instance);null==e&&(e="");var i=(0,s.default)(new Date(e)).isValid()||(0,s.default)(e,n.defaultDateFormat).isValid(),l=(0,s.default)(e,this.dateFormat||n.defaultDateFormat,!0).isValid();if(this.allowEmpty&&""===e&&(i=!0,l=!0),i||(o=!1),!i&&l&&(o=!0),i&&!l)if(!0===this.correctFormat){var u=r(e,this.dateFormat),c=this.instance.runHooks("unmodifyRow",this.row),h=this.instance.runHooks("unmodifyCol",this.col);this.instance.setDataAtCell(c,h,u,"dateValidator"),o=!0}else o=!1;t(o)}function r(e,t){var o=(0,s.default)((0,l.getNormalizedDate)(e)),n=(0,s.default)(e,t),r=e.search(/[A-z]/g)>-1,i=void 0;return i=o.isValid()&&o.format("x")===n.format("x")||!n.isValid()||r?o:n,i.format(t)}t.__esModule=!0,t.default=n,t.correctFormat=r;var i=o(50),s=function(e){return e&&e.__esModule?e:{default:e}}(i),l=o(170),a=o(15)},function(e,t,o){"use strict";function n(e,t){null==e&&(e=""),t(this.allowEmpty&&""===e?!0:""===e?!1:/^-?\d*(\.|,)?\d*$/.test(e))}t.__esModule=!0,t.default=n},function(e,t,o){"use strict";function n(e,t){var o=!0,n=this.timeFormat||"h:mm:ss a";null===e&&(e=""),e=/^\d{3,}$/.test(e)?parseInt(e,10):e;var r=/^\d{1,2}$/.test(e);r&&(e+=":00");var l=(0,i.default)(e,s,!0).isValid()?(0,i.default)(e):(0,i.default)(e,n),a=l.isValid(),u=(0,i.default)(e,n,!0).isValid()&&!r;if(this.allowEmpty&&""===e&&(a=!0,u=!0),a||(o=!1),!a&&u&&(o=!0),a&&!u)if(!0===this.correctFormat){var c=l.format(n),h=this.instance.runHooks("unmodifyRow",this.row),d=this.instance.runHooks("unmodifyCol",this.col);this.instance.setDataAtCell(h,d,c,"timeValidator"),o=!0}else o=!1;t(o)}t.__esModule=!0,t.default=n;var r=o(50),i=function(e){return e&&e.__esModule?e:{default:e}}(r),s=["YYYY-MM-DDTHH:mm:ss.SSSZ","X","x"]},function(e,t,o){"use strict";t.__esModule=!0;var n=o(15),r=o(8),i=o(27);t.default={editor:(0,n.getEditor)("autocomplete"),renderer:(0,r.getRenderer)("autocomplete"),validator:(0,i.getValidator)("autocomplete")}},function(e,t,o){"use strict";t.__esModule=!0;var n=o(15),r=o(8);t.default={editor:(0,n.getEditor)("checkbox"),renderer:(0,r.getRenderer)("checkbox")}},function(e,t,o){"use strict";t.__esModule=!0;var n=o(15),r=o(8),i=o(27);t.default={editor:(0,n.getEditor)("date"),renderer:(0,r.getRenderer)("autocomplete"),validator:(0,i.getValidator)("date")}},function(e,t,o){"use strict";t.__esModule=!0;var n=o(15),r=o(8),i=o(27);t.default={editor:(0,n.getEditor)("dropdown"),renderer:(0,r.getRenderer)("autocomplete"),validator:(0,i.getValidator)("autocomplete")}},function(e,t,o){"use strict";t.__esModule=!0;var n=o(15),r=o(8);t.default={editor:(0,n.getEditor)("handsontable"),renderer:(0,r.getRenderer)("autocomplete")}},function(e,t,o){"use strict";t.__esModule=!0;var n=o(15),r=o(8),i=o(27);t.default={editor:(0,n.getEditor)("numeric"),renderer:(0,r.getRenderer)("numeric"),validator:(0,i.getValidator)("numeric"),dataType:"number"}},function(e,t,o){"use strict";t.__esModule=!0;var n=o(15),r=o(8);o(27);t.default={editor:(0,n.getEditor)("password"),renderer:(0,r.getRenderer)("password"),copyable:!1}},function(e,t,o){"use strict";t.__esModule=!0;var n=o(26),r=o(15),i=o(8);t.default={editor:(0,r.getEditor)((0,n.isMobileBrowser)()?"mobile":"text"),renderer:(0,i.getRenderer)("text")}},function(e,t,o){"use strict";t.__esModule=!0;var n=o(15),r=o(8),i=o(27);t.default={editor:(0,n.getEditor)("text"),renderer:(0,r.getRenderer)("text"),validator:(0,i.getValidator)("time")}},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t,o){var n=this;this.instance=e,this.priv=t,this.GridSettings=o,this.dataSource=this.instance.getSettings().data,this.cachedLength=null,this.skipCache=!1,this.latestSourceRowsCount=0,this.duckSchema=this.dataSource&&this.dataSource[0]?this.recursiveDuckSchema(this.dataSource[0]):{},this.createMap(),this.interval=f.default.create(function(){return n.clearLengthCache()},"15fps"),this.instance.addHook("skipLengthCache",function(e){return n.onSkipLengthCache(e)}),this.onSkipLengthCache(500)}t.__esModule=!0;var i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},s=o(171),l=n(s),a=o(84),u=o(83),c=o(1),h=o(2),d=o(241),f=n(d),p=o(6),g=o(242),v=n(g),m=o(7);n(m);r.prototype.DESTINATION_RENDERER=1,r.prototype.DESTINATION_CLIPBOARD_GENERATOR=2,r.prototype.recursiveDuckSchema=function(e){return(0,c.duckSchema)(e)},r.prototype.recursiveDuckColumns=function(e,t,o){var n,r;if(void 0===t&&(t=0,o=""),"object"===(void 0===e?"undefined":i(e))&&!Array.isArray(e))for(r in e)(0,c.hasOwnProperty)(e,r)&&(null===e[r]?(n=o+r,this.colToPropCache.push(n),this.propToColCache.set(n,t),t++):t=this.recursiveDuckColumns(e[r],t,r+"."));return t},r.prototype.createMap=function(){var e=void 0,t=this.getSchema();if(void 0===t)throw Error("trying to create `columns` definition but you didn't provide `schema` nor `data`");this.colToPropCache=[],this.propToColCache=new v.default;var o=this.instance.getSettings().columns;if(o){var n=this.instance.getSettings().maxCols,r=Math.min(n,o.length),i=0,s=!1,l=(0,c.deepObjectSize)(t);for("function"==typeof o&&(r=l>0?l:this.instance.countSourceCols(),s=!0),e=0;r>e;e++){var a=s?o(e):o[e];if((0,c.isObject)(a)){if(void 0!==a.data){var u=s?i:e;this.colToPropCache[u]=a.data,this.propToColCache.set(a.data,u)}i++}}}else this.recursiveDuckColumns(t)},r.prototype.colToProp=function(e){return e=this.instance.runHooks("modifyCol",e),!isNaN(e)&&this.colToPropCache&&void 0!==this.colToPropCache[e]?this.colToPropCache[e]:e},r.prototype.propToCol=function(e){var t;return t=void 0===this.propToColCache.get(e)?e:this.propToColCache.get(e),t=this.instance.runHooks("unmodifyCol",t)},r.prototype.getSchema=function(){var e=this.instance.getSettings().dataSchema;return e?"function"==typeof e?e():e:this.duckSchema},r.prototype.createRow=function(e,t,o){var n,r,i=this.instance.countCols(),s=0;t||(t=1),"number"==typeof e&&e<this.instance.countSourceRows()||(e=this.instance.countSourceRows()),this.instance.runHooks("beforeCreateRow",e,t,o),r=e;for(var l=this.instance.getSettings().maxRows;t>s&&this.instance.countSourceRows()<l;)"array"===this.instance.dataType?this.instance.getSettings().dataSchema?n=(0,c.deepClone)(this.getSchema()):(n=[],(0,p.rangeEach)(i-1,function(){return n.push(null)})):"function"===this.instance.dataType?n=this.instance.getSettings().dataSchema(e):(n={},(0,c.deepExtend)(n,this.getSchema())),e===this.instance.countSourceRows()?this.dataSource.push(n):this.spliceData(e,0,n),s++,r++;return this.instance.runHooks("afterCreateRow",e,s,o),this.instance.forceFullRender=!0,s},r.prototype.createCol=function(e,t,o){if(!this.instance.isColumnModificationAllowed())throw Error("Cannot create new column. When data source in an object, you can only have as much columns as defined in first data row, data schema or in the 'columns' setting.If you want to be able to add new columns, you have to use array datasource.");var n,r,i=this.instance.countSourceRows(),s=this.dataSource,l=0;t||(t=1),"number"==typeof e&&e<this.instance.countCols()||(e=this.instance.countCols()),this.instance.runHooks("beforeCreateCol",e,t,o),r=e;for(var a=this.instance.getSettings().maxCols;t>l&&this.instance.countCols()<a;){if(n=(0,u.columnFactory)(this.GridSettings,this.priv.columnsSettingConflicts),"number"==typeof e&&e<this.instance.countCols()){for(var c=0;i>c;c++)s[c].splice(r,0,null);this.priv.columnSettings.splice(r,0,n)}else{if(i>0)for(var h=0;i>h;h++)void 0===s[h]&&(s[h]=[]),s[h].push(null);else s.push([null]);this.priv.columnSettings.push(n)}l++,r++}return this.instance.runHooks("afterCreateCol",e,l,o),this.instance.forceFullRender=!0,l},r.prototype.removeRow=function(e,t,o){t||(t=1),"number"!=typeof e&&(e=-t),t=this.instance.runHooks("modifyRemovedAmount",t,e),e=(this.instance.countSourceRows()+e)%this.instance.countSourceRows();var n=this.visualRowsToPhysical(e,t);if(!1!==this.instance.runHooks("beforeRemoveRow",e,t,n,o)){var r=this.dataSource,i=void 0;i=this.filterData(e,t),i&&(r.length=0,Array.prototype.push.apply(r,i)),this.instance.runHooks("afterRemoveRow",e,t,n,o),this.instance.forceFullRender=!0}},r.prototype.removeCol=function(e,t,o){if("object"===this.instance.dataType||this.instance.getSettings().columns)throw Error("cannot remove column with object data source or columns option specified");t||(t=1),"number"!=typeof e&&(e=-t),e=(this.instance.countCols()+e)%this.instance.countCols();var n=this.visualColumnsToPhysical(e,t),r=n.slice(0).sort(function(e,t){return t-e});if(!1!==this.instance.runHooks("beforeRemoveCol",e,t,n,o)){for(var i=!0,s=r.length,l=this.dataSource,a=0;s>a;a++)i&&n[0]!==n[a]-a&&(i=!1);if(i)for(var u=0,c=this.instance.countSourceRows();c>u;u++)l[u].splice(n[0],t);else{for(var h=0,d=this.instance.countSourceRows();d>h;h++)for(var f=0;s>f;f++)l[h].splice(r[f],1);for(var p=0;s>p;p++)this.priv.columnSettings.splice(n[p],1)}this.instance.runHooks("afterRemoveCol",e,t,n,o),this.instance.forceFullRender=!0}},r.prototype.spliceCol=function(e,t,o){var n=4>arguments.length?[]:[].slice.call(arguments,3),r=this.instance.getDataAtCol(e),i=r.slice(t,t+o),s=r.slice(t+o);(0,h.extendArray)(n,s);for(var l=0;o>l;)n.push(null),l++;return(0,h.to2dArray)(n),this.instance.populateFromArray(t,e,n,null,null,"spliceCol"),i},r.prototype.spliceRow=function(e,t,o){var n=4>arguments.length?[]:[].slice.call(arguments,3),r=this.instance.getSourceDataAtRow(e),i=r.slice(t,t+o),s=r.slice(t+o);(0,h.extendArray)(n,s);for(var l=0;o>l;)n.push(null),l++;return this.instance.populateFromArray(e,t,[n],null,null,"spliceRow"),i},r.prototype.spliceData=function(e,t,o){!1!==this.instance.runHooks("beforeDataSplice",e,t,o)&&this.dataSource.splice(e,t,o)},r.prototype.filterData=function(e,t){var o=this.visualRowsToPhysical(e,t);if(!1!==this.instance.runHooks("beforeDataFilter",e,t,o))return this.dataSource.filter(function(e,t){return-1==o.indexOf(t)})},r.prototype.get=function(e,t){e=this.instance.runHooks("modifyRow",e);var o=this.dataSource[e],n=this.instance.runHooks("modifyRowData",e);o=isNaN(n)?n:o;var r=null;if(o&&o.hasOwnProperty&&(0,c.hasOwnProperty)(o,t))r=o[t];else if("string"==typeof t&&t.indexOf(".")>-1){var i=t.split("."),s=o;if(!s)return null;for(var l=0,a=i.length;a>l;l++)if(void 0===(s=s[i[l]]))return null;r=s}else"function"==typeof t&&(r=t(this.dataSource.slice(e,e+1)[0]));if(this.instance.hasHook("modifyData")){var u=(0,c.createObjectPropListener)(r);this.instance.runHooks("modifyData",e,this.propToCol(t),u,"get"),u.isTouched()&&(r=u.value)}return r};var y=(0,a.cellMethodLookupFactory)("copyable",!1);r.prototype.getCopyable=function(e,t){return y.call(this.instance,e,this.propToCol(t))?this.get(e,t):""},r.prototype.set=function(e,t,o,n){e=this.instance.runHooks("modifyRow",e,n||"datamapGet");var r=this.dataSource[e],i=this.instance.runHooks("modifyRowData",e);if(r=isNaN(i)?i:r,this.instance.hasHook("modifyData")){var s=(0,c.createObjectPropListener)(o);this.instance.runHooks("modifyData",e,this.propToCol(t),s,"set"),s.isTouched()&&(o=s.value)}if(r&&r.hasOwnProperty&&(0,c.hasOwnProperty)(r,t))r[t]=o;else if("string"==typeof t&&t.indexOf(".")>-1){var l=t.split("."),a=r,u=0,h=void 0;for(u=0,h=l.length-1;h>u;u++)void 0===a[l[u]]&&(a[l[u]]={}),a=a[l[u]];a[l[u]]=o}else"function"==typeof t?t(this.dataSource.slice(e,e+1)[0],o):r[t]=o},r.prototype.visualRowsToPhysical=function(e,t){for(var o,n=this.instance.countSourceRows(),r=(n+e)%n,i=[],s=t;n>r&&s;)o=this.instance.runHooks("modifyRow",r),i.push(o),s--,r++;return i},r.prototype.visualColumnsToPhysical=function(e,t){for(var o=this.instance.countCols(),n=(o+e)%o,r=[],i=t;o>n&&i;){r.push(this.instance.runHooks("modifyCol",n)),i--,n++}return r},r.prototype.clear=function(){for(var e=0;e<this.instance.countSourceRows();e++)for(var t=0;t<this.instance.countCols();t++)this.set(e,this.colToProp(t),"")},r.prototype.clearLengthCache=function(){this.cachedLength=null},r.prototype.getLength=function(){var e=this,t=void 0,o=this.instance.getSettings().maxRows;t=0>o||0===o?0:o||1/0;var n=this.instance.countSourceRows();if(this.instance.hasHook("modifyRow")){var r=this.skipCache;this.interval.start(),n!==this.latestSourceRowsCount&&(r=!0),this.latestSourceRowsCount=n,null===this.cachedLength||r?((0,p.rangeEach)(n-1,function(t){null===(t=e.instance.runHooks("modifyRow",t))&&--n}),this.cachedLength=n):n=this.cachedLength}else this.interval.stop();return Math.min(n,t)},r.prototype.getAll=function(){var e={row:0,col:0},t={row:Math.max(this.instance.countSourceRows()-1,0),col:Math.max(this.instance.countCols()-1,0)};return e.row-t.row!=0||this.instance.countSourceRows()?this.getRange(e,t,r.prototype.DESTINATION_RENDERER):[]},r.prototype.getRange=function(e,t,o){var n,r,i,s,l,a=[],u=this.instance.getSettings().maxRows,c=this.instance.getSettings().maxCols;if(0===u||0===c)return[];var h=o===this.DESTINATION_CLIPBOARD_GENERATOR?this.getCopyable:this.get;for(r=Math.min(Math.max(u-1,0),Math.max(e.row,t.row)),s=Math.min(Math.max(c-1,0),Math.max(e.col,t.col)),n=Math.min(e.row,t.row);r>=n;n++){l=[];var d=this.instance.runHooks("modifyRow",n);for(i=Math.min(e.col,t.col);s>=i&&null!==d;i++)l.push(h.call(this,n,this.colToProp(i)));null!==d&&a.push(l)}return a},r.prototype.getText=function(e,t){return l.default.stringify(this.getRange(e,t,this.DESTINATION_RENDERER))},r.prototype.getCopyableText=function(e,t){return l.default.stringify(this.getRange(e,t,this.DESTINATION_CLIPBOARD_GENERATOR))},r.prototype.onSkipLengthCache=function(e){var t=this;this.skipCache=!0,setTimeout(function(){t.skipCache=!1},e)},r.prototype.destroy=function(){this.interval.stop(),this.interval=null,this.instance=null,this.priv=null,this.GridSettings=null,this.dataSource=null,this.cachedLength=null,this.duckSchema=null},t.default=r},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e){return"string"==typeof e&&/fps$/.test(e)&&(e=1e3/parseInt(e.replace("fps","")||0,10)),e}t.__esModule=!0;var i=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}();t.parseDelay=r;var s=o(34);t.default=function(){function e(t,o){var i=this;n(this,e),this.timer=null,this.func=t,this.delay=r(o),this.stopped=!0,this._then=null,this._callback=function(){return i.__callback()}}return i(e,null,[{key:"create",value:function(t,o){return new e(t,o)}}]),i(e,[{key:"start",value:function(){return this.stopped&&(this._then=Date.now(),this.stopped=!1,this.timer=(0,s.requestAnimationFrame)(this._callback)),this}},{key:"stop",value:function(){return this.stopped||(this.stopped=!0,(0,s.cancelAnimationFrame)(this.timer),this.timer=null),this}},{key:"__callback",value:function(){if(this.timer=(0,s.requestAnimationFrame)(this._callback),this.delay){var e=Date.now(),t=e-this._then;t>this.delay&&(this._then=e-t%this.delay,this.func())}else this.func()}}]),e}()},function(e,t,o){"use strict";function n(){function e(e){return null!==e&&!o(e)&&("string"==typeof e||"number"==typeof e)}function t(e){return null!==e&&("object"==(void 0===e?"undefined":r(e))||"function"==typeof e)}function o(e){return e!==e}var n={arrayMap:[],weakMap:new WeakMap};return{get:function(o){return e(o)?n.arrayMap[o]:t(o)?n.weakMap.get(o):void 0},set:function(o,r){if(e(o))n.arrayMap[o]=r;else{if(!t(o))throw Error("Invalid key type");n.weakMap.set(o,r)}},delete:function(o){e(o)?delete n.arrayMap[o]:t(o)&&n.weakMap.delete(o)}}}t.__esModule=!0;var r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.default=n},function(e,t,o){"use strict";function n(e,t,o){function n(e){o.setSelectedHeaders(!1,!1,!1);var n="function"==typeof t.settings.enterMoves?t.settings.enterMoves(event):t.settings.enterMoves;e?o.transformStart(-n.row,-n.col):o.transformStart(n.row,n.col,!0)}function a(e){e?(o.selectedHeader.cols&&o.setSelectedHeaders(o.selectedHeader.rows,!1,!1),o.transformEnd(-1,0)):(o.setSelectedHeaders(!1,!1,!1),o.transformStart(-1,0))}function h(e){e?o.transformEnd(1,0):(o.setSelectedHeaders(!1,!1,!1),o.transformStart(1,0))}function d(e){e?o.transformEnd(0,1):(o.setSelectedHeaders(!1,!1,!1),o.transformStart(0,1))}function f(e){e?(o.selectedHeader.rows&&o.setSelectedHeaders(!1,o.selectedHeader.cols,!1),o.transformEnd(0,-1)):(o.setSelectedHeaders(!1,!1,!1),o.transformStart(0,-1))}function p(l){var u,p;if(e.isListening()&&(e.runHooks("beforeKeyDown",l),!y&&!(0,s.isImmediatePropagationStopped)(l)&&(t.lastKeyCode=l.keyCode,o.isSelected()))){if(u=(l.ctrlKey||l.metaKey)&&!l.altKey,v&&!v.isWaiting()&&!((0,i.isMetaKey)(l.keyCode)||(0,i.isCtrlKey)(l.keyCode)||u||m.isEditorOpened()))return void m.openEditor("",l);switch(p=l.shiftKey?o.setRangeEnd:o.setRangeStart,l.keyCode){case i.KEY_CODES.A:!m.isEditorOpened()&&u&&(o.selectAll(),l.preventDefault(),(0,s.stopPropagation)(l));break;case i.KEY_CODES.ARROW_UP:m.isEditorOpened()&&!v.isWaiting()&&m.closeEditorAndSaveChanges(u),a(l.shiftKey),l.preventDefault(),(0,s.stopPropagation)(l);break;case i.KEY_CODES.ARROW_DOWN:m.isEditorOpened()&&!v.isWaiting()&&m.closeEditorAndSaveChanges(u),h(l.shiftKey),l.preventDefault(),(0,s.stopPropagation)(l);break;case i.KEY_CODES.ARROW_RIGHT:m.isEditorOpened()&&!v.isWaiting()&&m.closeEditorAndSaveChanges(u),d(l.shiftKey),l.preventDefault(),(0,s.stopPropagation)(l);break;case i.KEY_CODES.ARROW_LEFT:m.isEditorOpened()&&!v.isWaiting()&&m.closeEditorAndSaveChanges(u),f(l.shiftKey),l.preventDefault(),(0,s.stopPropagation)(l);break;case i.KEY_CODES.TAB:o.setSelectedHeaders(!1,!1,!1);var g="function"==typeof t.settings.tabMoves?t.settings.tabMoves(l):t.settings.tabMoves;l.shiftKey?o.transformStart(-g.row,-g.col):o.transformStart(g.row,g.col,!0),l.preventDefault(),(0,s.stopPropagation)(l);break;case i.KEY_CODES.BACKSPACE:case i.KEY_CODES.DELETE:o.empty(l),m.prepareEditor(),l.preventDefault();break;case i.KEY_CODES.F2:m.openEditor(null,l),v&&v.enableFullEditMode(),l.preventDefault();break;case i.KEY_CODES.ENTER:m.isEditorOpened()?(v&&v.state!==c.EditorState.WAITING&&m.closeEditorAndSaveChanges(u),n(l.shiftKey)):e.getSettings().enterBeginsEditing?(m.openEditor(null,l),v&&v.enableFullEditMode()):n(l.shiftKey),l.preventDefault(),(0,s.stopImmediatePropagation)(l);break;case i.KEY_CODES.ESCAPE:m.isEditorOpened()&&m.closeEditorAndRestoreOriginalValue(u),l.preventDefault();break;case i.KEY_CODES.HOME:o.setSelectedHeaders(!1,!1,!1),p(l.ctrlKey||l.metaKey?new r.CellCoords(0,t.selRange.from.col):new r.CellCoords(t.selRange.from.row,0)),l.preventDefault(),(0,s.stopPropagation)(l);break;case i.KEY_CODES.END:o.setSelectedHeaders(!1,!1,!1),p(l.ctrlKey||l.metaKey?new r.CellCoords(e.countRows()-1,t.selRange.from.col):new r.CellCoords(t.selRange.from.row,e.countCols()-1)),l.preventDefault(),(0,s.stopPropagation)(l);break;case i.KEY_CODES.PAGE_UP:o.setSelectedHeaders(!1,!1,!1),o.transformStart(-e.countVisibleRows(),0),l.preventDefault(),(0,s.stopPropagation)(l);break;case i.KEY_CODES.PAGE_DOWN:o.setSelectedHeaders(!1,!1,!1),o.transformStart(e.countVisibleRows(),0),l.preventDefault(),(0,s.stopPropagation)(l)}}}var g,v,m=this,y=!1;g=new u.default(e),this.destroyEditor=function(e){this.closeEditor(e)},this.getActiveEditor=function(){return v},this.prepareEditor=function(){var o,n,r,i,s,a,u;if(v&&v.isWaiting())return void this.closeEditor(!1,!1,function(e){e&&m.prepareEditor()});o=t.selRange.highlight.row,n=t.selRange.highlight.col,r=e.colToProp(n),i=e.getCell(o,n),s=e.getSourceDataAtCell(e.runHooks("modifyRow",o),n),a=e.getCellMeta(o,n),u=e.getCellEditor(a),u?(v=(0,l.getEditorInstance)(u,e),v.prepare(o,n,r,i,s,a)):v=void 0},this.isEditorOpened=function(){return v&&v.isOpened()},this.openEditor=function(e,t){v&&!v.cellProperties.readOnly?v.beginEditing(e,t):v&&v.cellProperties.readOnly&&t&&t.keyCode===i.KEY_CODES.ENTER&&n()},this.closeEditor=function(e,t,o){v?v.finishEditing(e,t,o):o&&o(!1)},this.closeEditorAndSaveChanges=function(e){return this.closeEditor(!1,e)},this.closeEditorAndRestoreOriginalValue=function(e){return this.closeEditor(!0,e)},function(){function t(e,t,o){"TD"==o.nodeName&&(m.openEditor(),v&&v.enableFullEditMode())}e.addHook("afterDocumentKeyDown",p),g.addEventListener(document.documentElement,"keydown",function(t){y||e.runHooks("afterDocumentKeyDown",t)}),e.view.wt.update("onCellDblClick",t),e.addHook("afterDestroy",function(){y=!0})}()}t.__esModule=!0;var r=o(12),i=o(18),s=o(10),l=o(15),a=o(4),u=function(e){return e&&e.__esModule?e:{default:e}}(a),c=o(41);t.default=n},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e){var t=this,o=this;this.eventManager=new u.default(e),this.instance=e,this.settings=e.getSettings(),this.selectionMouseDown=!1;var n=e.rootElement.getAttribute("style");n&&e.rootElement.setAttribute("data-originalstyle",n),(0,s.addClass)(e.rootElement,"handsontable");var r=document.createElement("TABLE");(0,s.addClass)(r,"htCore"),e.getSettings().tableClassName&&(0,s.addClass)(r,e.getSettings().tableClassName),this.THEAD=document.createElement("THEAD"),r.appendChild(this.THEAD),this.TBODY=document.createElement("TBODY"),r.appendChild(this.TBODY),e.table=r,e.container.insertBefore(r,e.container.firstChild),this.eventManager.addEventListener(e.rootElement,"mousedown",function(e){this.selectionMouseDown=!0,o.isTextSelectionAllowed(e.target)||(a(),e.preventDefault(),window.focus())}),this.eventManager.addEventListener(e.rootElement,"mouseup",function(e){this.selectionMouseDown=!1}),this.eventManager.addEventListener(e.rootElement,"mousemove",function(e){this.selectionMouseDown&&!o.isTextSelectionAllowed(e.target)&&(a(),e.preventDefault())}),this.eventManager.addEventListener(document.documentElement,"keyup",function(t){e.selection.isInProgress()&&!t.shiftKey&&e.selection.finish()});var i;this.isMouseDown=function(){return i},this.eventManager.addEventListener(document.documentElement,"mouseup",function(t){e.selection.isInProgress()&&1===t.which&&e.selection.finish(),i=!1,!(0,s.isOutsideInput)(document.activeElement)&&e.selection.isSelected()||e.unlisten()}),this.eventManager.addEventListener(document.documentElement,"mousedown",function(t){var n=t.target,r=t.target,l=t.x||t.clientX,a=t.y||t.clientY;if(!i&&e.rootElement){if(r===e.view.wt.wtTable.holder){var u=(0,s.getScrollbarWidth)();if(document.elementFromPoint(l+u,a)!==e.view.wt.wtTable.holder||document.elementFromPoint(l,a+u)!==e.view.wt.wtTable.holder)return}else for(;r!==document.documentElement;){if(null===r){if(t.isTargetWebComponent)break;return}if(r===e.rootElement)return;r=r.parentNode}("function"==typeof o.settings.outsideClickDeselects?o.settings.outsideClickDeselects(n):o.settings.outsideClickDeselects)?e.deselectCell():e.destroyEditor()}}),this.eventManager.addEventListener(r,"selectstart",function(e){o.settings.fragmentSelection||(0,s.isInput)(e.target)||e.preventDefault()});var a=function(){window.getSelection?window.getSelection().empty?window.getSelection().empty():window.getSelection().removeAllRanges&&window.getSelection().removeAllRanges():document.selection&&document.selection.empty()},f=[new h.Selection({className:"current",border:{width:2,color:"#5292F7",cornerVisible:function(){return o.settings.fillHandle&&!o.isCellEdited()&&!e.selection.isMultiple()},multipleSelectionHandlesVisible:function(){return!o.isCellEdited()&&!e.selection.isMultiple()}}}),new h.Selection({className:"area",border:{width:1,color:"#89AFF9",cornerVisible:function(){return o.settings.fillHandle&&!o.isCellEdited()&&e.selection.isMultiple()},multipleSelectionHandlesVisible:function(){return!o.isCellEdited()&&e.selection.isMultiple()}}}),new h.Selection({className:"highlight",highlightHeaderClassName:o.settings.currentHeaderClassName,highlightRowClassName:o.settings.currentRowClassName,highlightColumnClassName:o.settings.currentColClassName}),new h.Selection({className:"fill",border:{width:1,color:"red"}})];f.current=f[0],f.area=f[1],f.highlight=f[2],f.fill=f[3];var p={debug:function(){return o.settings.debug},externalRowCalculator:this.instance.getPlugin("autoRowSize")&&this.instance.getPlugin("autoRowSize").isEnabled(),table:r,preventOverflow:function(){return t.settings.preventOverflow},stretchH:function(){return o.settings.stretchH},data:e.getDataAtCell,totalRows:function(){return e.countRows()},totalColumns:function(){return e.countCols()},fixedColumnsLeft:function(){return o.settings.fixedColumnsLeft},fixedRowsTop:function(){return o.settings.fixedRowsTop},fixedRowsBottom:function(){return o.settings.fixedRowsBottom},minSpareRows:function(){return o.settings.minSpareRows},renderAllRows:o.settings.renderAllRows,rowHeaders:function(){var t=[];return e.hasRowHeaders()&&t.push(function(e,t){o.appendRowHeader(e,t)}),e.runHooks("afterGetRowHeaderRenderers",t),t},columnHeaders:function(){var t=[];return e.hasColHeaders()&&t.push(function(e,t){o.appendColHeader(e,t)}),e.runHooks("afterGetColumnHeaderRenderers",t),t},columnWidth:e.getColWidth,rowHeight:e.getRowHeight,cellRenderer:function(e,t,n){var r=o.instance.getCellMeta(e,t),i=o.instance.colToProp(t),s=o.instance.getDataAtRowProp(e,i);o.instance.hasHook("beforeValueRender")&&(s=o.instance.runHooks("beforeValueRender",s)),o.instance.runHooks("beforeRenderer",n,e,t,i,s,r),o.instance.getCellRenderer(r)(o.instance,n,e,t,i,s,r),o.instance.runHooks("afterRenderer",n,e,t,i,s,r)},selections:f,hideBorderOnMouseDownOver:function(){return o.settings.fragmentSelection},onCellMouseDown:function(t,n,r,s){var l={row:!1,column:!1,cells:!1};if(e.listen(),o.activeWt=s,i=!0,e.runHooks("beforeOnCellMouseDown",t,n,r,l),!(0,c.isImmediatePropagationStopped)(t)){var a=e.getSelectedRange(),u=e.selection,d=u.selectedHeader;if(t.shiftKey&&a)0>n.row||0>n.col||l.cells?!d.cols&&!d.rows||0>n.row||0>n.col||l.cells?d.cols&&0>n.row&&!l.column?u.setRangeEnd(new h.CellCoords(a.to.row,n.col)):d.rows&&0>n.col&&!l.row?u.setRangeEnd(new h.CellCoords(n.row,a.to.col)):(!d.cols&&!d.rows&&0>n.col||d.cols&&0>n.col)&&!l.row?(u.setSelectedHeaders(!0,!1),u.setRangeStartOnly(new h.CellCoords(a.from.row,0)),u.setRangeEnd(new h.CellCoords(n.row,e.countCols()-1))):(!d.cols&&!d.rows&&0>n.row||d.rows&&0>n.row)&&!l.column&&(u.setSelectedHeaders(!1,!0),u.setRangeStartOnly(new h.CellCoords(0,a.from.col)),u.setRangeEnd(new h.CellCoords(e.countRows()-1,n.col))):(u.setSelectedHeaders(!1,!1),u.setRangeEnd(new h.CellCoords(n.row,n.col))):(u.setSelectedHeaders(!1,!1),u.setRangeEnd(n));else{var f=!0;if(a){var p=a.from,g=a.to,v=!u.inInSelection(n);if(0>n.row&&d.cols){var m=Math.min(p.col,g.col),y=Math.max(p.col,g.col);f=m>n.col||n.col>y}else if(0>n.col&&d.rows){var w=Math.min(p.row,g.row),C=Math.max(p.row,g.row);f=w>n.row||n.row>C}else f=v}var b=(0,c.isRightClick)(t),S=(0,c.isLeftClick)(t)||"touchstart"===t.type;n.row>=0||0>n.col||l.column?n.col>=0||0>n.row||l.row?0>n.col||0>n.row||l.cells?0>n.col&&0>n.row&&(n.row=0,n.col=0,u.setSelectedHeaders(!1,!1,!0),u.setRangeStart(n)):(S||b&&f)&&(u.setSelectedHeaders(!1,!1),u.setRangeStart(n)):(u.setSelectedHeaders(!0,!1),(S||b&&f)&&(u.setRangeStartOnly(new h.CellCoords(n.row,0)),u.setRangeEnd(new h.CellCoords(n.row,Math.max(e.countCols()-1,0)),!1))):(u.setSelectedHeaders(!1,!0),(S||b&&f)&&(u.setRangeStartOnly(new h.CellCoords(0,n.col)),u.setRangeEnd(new h.CellCoords(Math.max(e.countRows()-1,0),n.col),!1)))}e.runHooks("afterOnCellMouseDown",t,n,r),o.activeWt=o.wt}},onCellMouseOut:function(t,n,r,i){o.activeWt=i,e.runHooks("beforeOnCellMouseOut",t,n,r),(0,c.isImmediatePropagationStopped)(t)||(e.runHooks("afterOnCellMouseOut",t,n,r),o.activeWt=o.wt)},onCellMouseOver:function(t,n,r,s){var l={row:!1,column:!1,cell:!1};o.activeWt=s,e.runHooks("beforeOnCellMouseOver",t,n,r,l),(0,c.isImmediatePropagationStopped)(t)||(0===t.button&&i&&(e.selection.selectedHeader.cols&&!l.column?e.selection.setRangeEnd(new h.CellCoords(e.countRows()-1,n.col),!1):e.selection.selectedHeader.rows&&!l.row?e.selection.setRangeEnd(new h.CellCoords(n.row,e.countCols()-1),!1):l.cell||e.selection.setRangeEnd(n)),e.runHooks("afterOnCellMouseOver",t,n,r),o.activeWt=o.wt)},onCellMouseUp:function(t,n,r,i){o.activeWt=i,e.runHooks("beforeOnCellMouseUp",t,n,r),e.runHooks("afterOnCellMouseUp",t,n,r),o.activeWt=o.wt},onCellCornerMouseDown:function(t){t.preventDefault(),e.runHooks("afterOnCellCornerMouseDown",t)},onCellCornerDblClick:function(t){t.preventDefault(),e.runHooks("afterOnCellCornerDblClick",t)},beforeDraw:function(e,t){o.beforeRender(e,t)},onDraw:function(e){o.onDraw(e)},onScrollVertically:function(){e.runHooks("afterScrollVertically")},onScrollHorizontally:function(){e.runHooks("afterScrollHorizontally")},onBeforeDrawBorders:function(t,o){e.runHooks("beforeDrawBorders",t,o)},onBeforeTouchScroll:function(){e.runHooks("beforeTouchScroll")},onAfterMomentumScroll:function(){e.runHooks("afterMomentumScroll")},onBeforeStretchingColumnWidth:function(t,o){return e.runHooks("beforeStretchingColumnWidth",t,o)},onModifyRowHeaderWidth:function(t){return e.runHooks("modifyRowHeaderWidth",t)},viewportRowCalculatorOverride:function(t){var n=e.countRows(),r=o.settings.viewportRowRenderingOffset;if("auto"===r&&o.settings.fixedRowsTop&&(r=10),"number"==typeof r&&(t.startRow=Math.max(t.startRow-r,0),t.endRow=Math.min(t.endRow+r,n-1)),"auto"===r){var i=t.startRow+t.endRow-t.startRow,s=Math.ceil(i/n*12);t.startRow=Math.max(t.startRow-s,0),t.endRow=Math.min(t.endRow+s,n-1)}e.runHooks("afterViewportRowCalculatorOverride",t)},viewportColumnCalculatorOverride:function(t){var n=e.countCols(),r=o.settings.viewportColumnRenderingOffset;if("auto"===r&&o.settings.fixedColumnsLeft&&(r=10),"number"==typeof r&&(t.startColumn=Math.max(t.startColumn-r,0),t.endColumn=Math.min(t.endColumn+r,n-1)),"auto"===r){var i=t.startColumn+t.endColumn-t.startColumn,s=Math.ceil(i/n*12);t.startRow=Math.max(t.startColumn-s,0),t.endColumn=Math.min(t.endColumn+s,n-1)}e.runHooks("afterViewportColumnCalculatorOverride",t)},rowHeaderWidth:function(){return o.settings.rowHeaderWidth},columnHeaderHeight:function(){var t=e.runHooks("modifyColumnHeaderHeight");return o.settings.columnHeaderHeight||t}};e.runHooks("beforeInitWalkontable",p),this.wt=new d.default(p),this.activeWt=this.wt,(0,l.isChrome)()||(0,l.isSafari)()||this.eventManager.addEventListener(e.rootElement,"wheel",function(e){e.preventDefault();var t=parseInt((0,s.getComputedStyle)(document.body)["font-size"],10),n=o.wt.wtOverlays.scrollableElement,r=e.wheelDeltaY||e.deltaY,i=e.wheelDeltaX||e.deltaX;switch(e.deltaMode){case 0:n.scrollLeft+=i,n.scrollTop+=r;break;case 1:n.scrollLeft+=i*t,n.scrollTop+=r*t}}),this.eventManager.addEventListener(o.wt.wtTable.spreader,"mousedown",function(e){e.target===o.wt.wtTable.spreader&&3===e.which&&(0,c.stopPropagation)(e)}),this.eventManager.addEventListener(o.wt.wtTable.spreader,"contextmenu",function(e){e.target===o.wt.wtTable.spreader&&3===e.which&&(0,c.stopPropagation)(e)}),this.eventManager.addEventListener(document.documentElement,"click",function(){o.settings.observeDOMVisibility&&o.wt.drawInterrupted&&(o.instance.forceFullRender=!0,o.render())})}t.__esModule=!0;var i=function(){function e(e,t){var o=[],n=!0,r=!1,i=void 0;try{for(var s,l=e[Symbol.iterator]();!(n=(s=l.next()).done)&&(o.push(s.value),!t||o.length!==t);n=!0);}catch(e){r=!0,i=e}finally{try{!n&&l.return&&l.return()}finally{if(r)throw i}}return o}return function(t,o){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,o);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),s=o(0),l=o(26),a=o(4),u=n(a),c=o(10),h=o(12),d=n(h);r.prototype.isTextSelectionAllowed=function(e){if((0,s.isInput)(e))return!0;var t=(0,s.isChildOf)(e,this.instance.view.wt.wtTable.spreader);return!(!0!==this.settings.fragmentSelection||!t)||(!("cell"!==this.settings.fragmentSelection||!this.isSelectedOnlyCell()||!t)||!(this.settings.fragmentSelection||!this.isCellEdited()||!this.isSelectedOnlyCell()))},r.prototype.isSelectedOnlyCell=function(){var e=this.instance.getSelected()||[],t=i(e,4),o=t[0],n=t[1],r=t[2],s=t[3];return void 0!==o&&o===r&&n===s},r.prototype.isCellEdited=function(){var e=this.instance.getActiveEditor();return e&&e.isOpened()},r.prototype.beforeRender=function(e,t){e&&this.instance.runHooks("beforeRender",this.instance.forceFullRender,t)},r.prototype.onDraw=function(e){e&&this.instance.runHooks("afterRender",this.instance.forceFullRender)},r.prototype.render=function(){this.wt.draw(!this.instance.forceFullRender),this.instance.forceFullRender=!1,this.instance.renderCall=!1},r.prototype.getCellAtCoords=function(e,t){var o=this.wt.getCell(e,t);return 0>o?null:o},r.prototype.scrollViewport=function(e){this.wt.scrollViewport(e)},r.prototype.appendRowHeader=function(e,t){if(t.firstChild){var o=t.firstChild;if(!(0,s.hasClass)(o,"relative"))return(0,s.empty)(t),void this.appendRowHeader(e,t);this.updateCellHeader(o.querySelector(".rowHeader"),e,this.instance.getRowHeader)}else{var n=document.createElement("div"),r=document.createElement("span");n.className="relative",r.className="rowHeader",this.updateCellHeader(r,e,this.instance.getRowHeader),n.appendChild(r),t.appendChild(n)}this.instance.runHooks("afterGetRowHeader",e,t)},r.prototype.appendColHeader=function(e,t){if(t.firstChild){var o=t.firstChild;(0,s.hasClass)(o,"relative")?this.updateCellHeader(o.querySelector(".colHeader"),e,this.instance.getColHeader):((0,s.empty)(t),this.appendColHeader(e,t))}else{var n=document.createElement("div"),r=document.createElement("span");n.className="relative",r.className="colHeader",this.updateCellHeader(r,e,this.instance.getColHeader),n.appendChild(r),t.appendChild(n)}this.instance.runHooks("afterGetColHeader",e,t)},r.prototype.updateCellHeader=function(e,t,o){var n=t,r=this.wt.wtOverlays.getParentOverlay(e)||this.wt;e.parentNode&&((0,s.hasClass)(e,"colHeader")?n=r.wtTable.columnFilter.sourceToRendered(t):(0,s.hasClass)(e,"rowHeader")&&(n=r.wtTable.rowFilter.sourceToRendered(t))),n>-1?(0,s.fastInnerHTML)(e,o(t)):((0,s.fastInnerText)(e,String.fromCharCode(160)),(0,s.addClass)(e,"cornerHeader"))},r.prototype.maximumVisibleElementWidth=function(e){var t=this.wt.wtViewport.getWorkspaceWidth(),o=t-e;return o>0?o:0},r.prototype.maximumVisibleElementHeight=function(e){var t=this.wt.wtViewport.getWorkspaceHeight(),o=t-e;return o>0?o:0},r.prototype.mainViewIsActive=function(){return this.wt===this.activeWt},r.prototype.destroy=function(){this.wt.destroy(),this.eventManager.destroy()},t.default=r},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=o(1),s=o(2),l=o(6);t.default=function(){function e(t){var o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];n(this,e),this.hot=t,this.data=o,this.dataType="array",this.colToProp=function(){},this.propToCol=function(){}}return r(e,[{key:"getData",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=this.data;return e&&(t=this.getByRange({row:0,col:0},{row:Math.max(this.countRows()-1,0),col:Math.max(this.countColumns()-1,0)},!0)),t}},{key:"setData",value:function(e){this.data=e}},{key:"getAtColumn",value:function(e){var t=this,o=[];return(0,s.arrayEach)(this.data,function(n){var r=t.colToProp(e);n="string"==typeof r?(0,i.getProperty)(n,r):n[r],o.push(n)}),o}},{key:"getAtRow",value:function(e){return this.data[e]}},{key:"getAtCell",value:function(e,t){var o=null,n=this.hot.runHooks("modifyRowData",e),r=isNaN(n)?n:this.data[e];if(r){var s=this.colToProp(t);o="string"==typeof s?(0,i.getProperty)(r,s):"function"==typeof s?s(this.data.slice(e,e+1)[0]):r[s]}return o}},{key:"getByRange",value:function(e,t){var o=this,n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=Math.min(e.row,t.row),i=Math.min(e.col,t.col),s=Math.max(e.row,t.row),a=Math.max(e.col,t.col),u=[];return(0,l.rangeEach)(r,s,function(e){var t=o.getAtRow(e),r=void 0;"array"===o.dataType?r=t.slice(i,a+1):"object"===o.dataType&&(r=n?[]:{},(0,l.rangeEach)(i,a,function(e){var i=o.colToProp(e);n?r.push(t[i]):r[i]=t[i]})),u.push(r)}),u}},{key:"countRows",value:function(){return Array.isArray(this.data)?this.data.length:0}},{key:"countColumns",value:function(){var e=0;return Array.isArray(this.data)&&("array"===this.dataType?e=this.data[0].length:"object"===this.dataType&&(e=Object.keys(this.data[0]).length)),e}},{key:"destroy",value:function(){this.data=null,this.hot=null}}]),e}()},function(e,t,o){"use strict";function n(e){var t="undefined"!=typeof window&&window.jQuery;t&&(t.fn.handsontable=function(t){var o=this.first(),n=o.data("handsontable");if("string"!=typeof t){var r=t||{};return n?n.updateSettings(r):(n=new e.Core(o[0],r),o.data("handsontable",n),n.init()),o}var i=[],s=void 0;if(arguments.length>1)for(var l=1,a=arguments.length;a>l;l++)i.push(arguments[l]);if(n){if(void 0===n[t])throw Error("Handsontable do not provide action: "+t);s=n[t].apply(n,i),"destroy"===t&&o.removeData()}return s})}t.__esModule=!0,t.default=n},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}t.__esModule=!0,t.Base=t.UndoRedo=t.TouchScroll=t.Search=t.PersistentState=t.ObserveChanges=t.MultipleSelectionHandles=t.MergeCells=t.ManualRowResize=t.ManualRowMove=t.ManualColumnResize=t.ManualColumnMove=t.ManualColumnFreeze=t.DragToScroll=t.CustomBorders=t.CopyPaste=t.ContextMenu=t.Comments=t.ColumnSorting=t.AutoRowSize=t.AutoFill=t.AutoColumnSize=void 0;var r=o(248),i=n(r),s=o(249),l=n(s),a=o(251),u=n(a),c=o(252),h=n(c),d=o(255),f=n(d),p=o(259),g=n(p),v=o(276),m=n(v),y=o(283),w=n(y),C=o(284),b=n(C),S=o(285),E=n(S),R=o(289),O=n(R),k=o(294),T=n(k),_=o(295),M=n(_),H=o(300),A=n(H),P=o(301),x=n(P),D=o(302),L=n(D),N=o(303),I=n(N),j=o(306),W=n(j),B=o(307),F=n(B),V=o(308),z=n(V),U=o(309),Y=n(U),K=o(13),G=n(K);t.AutoColumnSize=i.default,t.AutoFill=l.default,t.AutoRowSize=u.default,t.ColumnSorting=h.default,t.Comments=f.default,t.ContextMenu=g.default,t.CopyPaste=m.default,t.CustomBorders=w.default,t.DragToScroll=b.default,t.ManualColumnFreeze=E.default,t.ManualColumnMove=O.default,t.ManualColumnResize=T.default,t.ManualRowMove=M.default,t.ManualRowResize=A.default,t.MergeCells=x.default,t.MultipleSelectionHandles=L.default,t.ObserveChanges=I.default,t.PersistentState=W.default,t.Search=F.default,t.TouchScroll=z.default,t.UndoRedo=Y.default,t.Base=G.default},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var l=function(){function e(e,t){var o=[],n=!0,r=!1,i=void 0;try{for(var s,l=e[Symbol.iterator]();!(n=(s=l.next()).done)&&(o.push(s.value),!t||o.length!==t);n=!0);}catch(e){r=!0,i=e}finally{try{!n&&l.return&&l.return()}finally{if(r)throw i}}return o}return function(t,o){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,o);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),a=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},u=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),c=o(13),h=n(c),d=o(2),f=o(34),p=o(0),g=o(85),v=n(g),m=o(1),y=o(6),w=o(5),C=o(175),b=n(C),S=o(32),E=o(12),R=new WeakMap,O=function(e){function t(e){r(this,t);var o=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return R.set(o,{cachedColumnHeaders:[]}),o.widths=[],o.ghostTable=new v.default(o.hot),o.samplesGenerator=new b.default(function(e,t){return o.hot.getDataAtCell(e,t)}),o.firstCalculation=!0,o.inProgress=!1,o.addHook("beforeColumnResize",function(e,t,n){return o.onBeforeColumnResize(e,t,n)}),o}return s(t,e),u(t,null,[{key:"CALCULATION_STEP",get:function(){return 50}},{key:"SYNC_CALCULATION_LIMIT",get:function(){return 50}}]),u(t,[{key:"isEnabled",value:function(){return!1!==this.hot.getSettings().autoColumnSize&&!this.hot.getSettings().colWidths}},{key:"enablePlugin",value:function(){var e=this;if(!this.enabled){var o=this.hot.getSettings().autoColumnSize;o&&null!=o.useHeaders&&this.ghostTable.setSetting("useHeaders",o.useHeaders),this.addHook("afterLoadData",function(){return e.onAfterLoadData()}),this.addHook("beforeChange",function(t){return e.onBeforeChange(t)}),this.addHook("beforeRender",function(t){return e.onBeforeRender(t)}),this.addHook("modifyColWidth",function(t,o){return e.getColumnWidth(o,t)}),this.addHook("afterInit",function(){return e.onAfterInit()}),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this)}}},{key:"updatePlugin",value:function(){var e=this.findColumnsWhereHeaderWasChanged();e.length&&this.clearCache(e),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"updatePlugin",this).call(this)}},{key:"disablePlugin",value:function(){a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"calculateColumnsWidth",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{from:0,to:this.hot.countCols()-1},t=this,o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{from:0,to:this.hot.countRows()-1},n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];"number"==typeof e&&(e={from:e,to:e}),"number"==typeof o&&(o={from:o,to:o}),(0,y.rangeEach)(e.from,e.to,function(e){if(n||void 0===t.widths[e]&&!t.hot._getColWidthFromSettings(e)){t.samplesGenerator.generateColumnSamples(e,o).forEach(function(e,o){return t.ghostTable.addColumn(o,e)})}}),this.ghostTable.columns.length&&(this.ghostTable.getWidths(function(e,o){t.widths[e]=o}),this.ghostTable.clean())}},{key:"calculateAllColumnsWidth",value:function(){var e=this,o=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{from:0,to:this.hot.countRows()-1},n=0,r=this.hot.countCols()-1,i=null;this.inProgress=!0;this.firstCalculation&&this.getSyncCalculationLimit()&&(this.calculateColumnsWidth({from:0,to:this.getSyncCalculationLimit()},o),this.firstCalculation=!1,n=this.getSyncCalculationLimit()+1),r>n?function s(){if(!e.hot)return(0,f.cancelAnimationFrame)(i),void(e.inProgress=!1);e.calculateColumnsWidth({from:n,to:Math.min(n+t.CALCULATION_STEP,r)},o),n=n+t.CALCULATION_STEP+1,r>n?i=(0,f.requestAnimationFrame)(s):((0,f.cancelAnimationFrame)(i),e.inProgress=!1,e.hot.view.wt.wtOverlays.adjustElementsSize(!0),e.hot.view.wt.wtOverlays.leftOverlay.needFullRender&&e.hot.view.wt.wtOverlays.leftOverlay.clone.draw())}():this.inProgress=!1}},{key:"setSamplingOptions",value:function(){var e=this.hot.getSettings().autoColumnSize,t=e&&(0,m.hasOwnProperty)(e,"samplingRatio")?this.hot.getSettings().autoColumnSize.samplingRatio:void 0,o=e&&(0,m.hasOwnProperty)(e,"allowSampleDuplicates")?this.hot.getSettings().autoColumnSize.allowSampleDuplicates:void 0;t&&!isNaN(t)&&this.samplesGenerator.setSampleCount(parseInt(t,10)),o&&this.samplesGenerator.setAllowDuplicates(o)}},{key:"recalculateAllColumnsWidth",value:function(){this.hot.view&&(0,p.isVisible)(this.hot.view.wt.wtTable.TABLE)&&(this.clearCache(),this.calculateAllColumnsWidth())}},{key:"getSyncCalculationLimit",value:function(){var e=t.SYNC_CALCULATION_LIMIT,o=this.hot.countCols()-1;return(0,m.isObject)(this.hot.getSettings().autoColumnSize)&&(e=this.hot.getSettings().autoColumnSize.syncLimit,(0,S.isPercentValue)(e)?e=(0,y.valueAccordingPercent)(o,e):e>>=0),Math.min(e,o)}},{key:"getColumnWidth",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:void 0,o=2>=arguments.length||void 0===arguments[2]||arguments[2],n=t;return void 0===n&&(n=this.widths[e],o&&"number"==typeof n&&(n=Math.max(n,E.ViewportColumnsCalculator.DEFAULT_WIDTH))),n}},{key:"getFirstVisibleColumn",value:function(){var e=this.hot.view.wt;return e.wtViewport.columnsVisibleCalculator?e.wtTable.getFirstVisibleColumn():e.wtViewport.columnsRenderCalculator?e.wtTable.getFirstRenderedColumn():-1}},{key:"getLastVisibleColumn",value:function(){var e=this.hot.view.wt;return e.wtViewport.columnsVisibleCalculator?e.wtTable.getLastVisibleColumn():e.wtViewport.columnsRenderCalculator?e.wtTable.getLastRenderedColumn():-1}},{key:"findColumnsWhereHeaderWasChanged",value:function(){var e=this.hot.getColHeader(),t=R.get(this),o=t.cachedColumnHeaders;return(0,d.arrayReduce)(e,function(e,t,n){var r=o.length;return(n>r-1||o[n]!==t)&&e.push(n),n>r-1?o.push(t):o[n]=t,e},[])}},{key:"clearCache",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];t.length?(0,d.arrayEach)(t,function(t){e.widths[t]=void 0}):this.widths.length=0}},{key:"isNeedRecalculate",value:function(){return!!(0,d.arrayFilter)(this.widths,function(e){return void 0===e}).length}},{key:"onBeforeRender",value:function(){var e=this.hot.renderCall;this.hot.countRows()&&(this.calculateColumnsWidth({from:this.getFirstVisibleColumn(),to:this.getLastVisibleColumn()},void 0,e),this.isNeedRecalculate()&&!this.inProgress&&this.calculateAllColumnsWidth())}},{key:"onAfterLoadData",value:function(){var e=this;this.hot.view?this.recalculateAllColumnsWidth():setTimeout(function(){e.hot&&e.recalculateAllColumnsWidth()},0)}},{key:"onBeforeChange",value:function(e){var t=this;this.clearCache((0,d.arrayMap)(e,function(e){var o=l(e,2);return t.hot.propToCol(o[1])}))}},{key:"onBeforeColumnResize",value:function(e,t,o){return o&&(this.calculateColumnsWidth(e,void 0,!0),t=this.getColumnWidth(e,void 0,!1)),t}},{key:"onAfterInit",value:function(){R.get(this).cachedColumnHeaders=this.hot.getColHeader()}},{key:"destroy",value:function(){this.ghostTable.clean(),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}}]),t}(h.default);(0,w.registerPlugin)("autoColumnSize",O),t.default=O},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var l=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),a=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},u=o(13),c=n(u),h=o(7),d=n(h),f=o(0),p=o(4),g=n(p),v=o(5),m=o(12),y=o(250);d.default.getSingleton().register("modifyAutofillRange"),d.default.getSingleton().register("beforeAutofill");var w=function(e){function t(e){r(this,t);var o=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.eventManager=new g.default(o),o.addingStarted=!1,o.mouseDownOnCellCorner=!1,o.mouseDragOutside=!1,o.handleDraggedCells=0,o.directions=[],o.autoInsertRow=!1,o}return s(t,e),l(t,[{key:"isEnabled",value:function(){return this.hot.getSettings().fillHandle}},{key:"enablePlugin",value:function(){var e=this;this.enabled||(this.mapSettings(),this.registerEvents(),this.addHook("afterOnCellCornerMouseDown",function(t){return e.onAfterCellCornerMouseDown(t)}),this.addHook("afterOnCellCornerDblClick",function(t){return e.onCellCornerDblClick(t)}),this.addHook("beforeOnCellMouseOver",function(t,o,n){return e.onBeforeCellMouseOver(o)}),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{key:"updatePlugin",value:function(){this.disablePlugin(),this.enablePlugin(),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"updatePlugin",this).call(this)}},{key:"disablePlugin",value:function(){this.clearMappedSettings(),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"getSelectionData",value:function(){var e={from:this.hot.getSelectedRange().from,to:this.hot.getSelectedRange().to};return this.hot.getData(e.from.row,e.from.col,e.to.row,e.to.col)}},{key:"fillIn",value:function(){if(this.hot.view.wt.selections.fill.isEmpty())return!1;var e=this.hot.view.wt.selections.fill.getCorners();this.resetSelectionOfDraggedArea();var t=this.getCornersOfSelectedCells(),o=(0,y.getDragDirectionAndRange)(t,e),n=o.directionOfDrag,r=o.startOfDragCoords,i=o.endOfDragCoords;if(this.hot.runHooks("modifyAutofillRange",t,e),r&&r.row>-1&&r.col>-1){var s=this.getSelectionData(),l=(0,y.getDeltas)(r,i,s,n),a=s;if(this.hot.runHooks("beforeAutofill",r,i,s),["up","left"].indexOf(n)>-1){a=[];var u=null,c=null;if("up"===n){u=i.row-r.row+1,c=u%s.length;for(var h=0;u>h;h++)a.push(s[(h+(s.length-c))%s.length])}else{u=i.col-r.col+1,c=u%s[0].length;for(var d=0;s.length>d;d++){a.push([]);for(var f=0;u>f;f++)a[d].push(s[d][(f+(s[d].length-c))%s[d].length])}}}this.hot.populateFromArray(r.row,r.col,a,i.row,i.col,this.pluginName+".fill",null,n,l),this.setSelection(e)}else this.hot.selection.refreshBorders();return!0}},{key:"reduceSelectionAreaIfNeeded",value:function(e){return 0>e.row&&(e.row=0),0>e.col&&(e.col=0),e}},{key:"getCoordsOfDragAndDropBorders",value:function(e){var t=this.hot.getSelectedRange().getTopLeftCorner(),o=this.hot.getSelectedRange().getBottomRightCorner(),n=void 0;if(this.directions.includes(y.DIRECTIONS.vertical)&&(e.row>o.row||t.row>e.row))n=new m.CellCoords(e.row,o.col);else{if(!this.directions.includes(y.DIRECTIONS.horizontal))return;n=new m.CellCoords(o.row,e.col)}return this.reduceSelectionAreaIfNeeded(n)}},{key:"showBorder",value:function(e){var t=this.getCoordsOfDragAndDropBorders(e);t&&this.redrawBorders(t)}},{key:"addRow",value:function(){var e=this;this.hot._registerTimeout(setTimeout(function(){e.hot.alter("insert_row",void 0,1,e.pluginName+".fill"),e.addingStarted=!1},200))}},{key:"addNewRowIfNeeded",value:function(){if(this.hot.view.wt.selections.fill.cellRange&&!1===this.addingStarted&&this.autoInsertRow){var e=this.hot.getSelected(),t=this.hot.view.wt.selections.fill.getCorners(),o=this.hot.countRows();o-1>e[2]&&t[2]===o-1&&(this.addingStarted=!0,this.addRow())}}},{key:"getCornersOfSelectedCells",value:function(){return this.hot.selection.isMultiple()?this.hot.view.wt.selections.area.getCorners():this.hot.view.wt.selections.current.getCorners()}},{key:"getIndexOfLastAdjacentFilledInRow",value:function(e){for(var t=this.hot.getData(),o=this.hot.countRows(),n=void 0,r=e[2]+1;o>r;r++){for(var i=e[1];e[3]>=i;i++){if(t[r][i])return-1}var s=t[r][e[1]-1],l=t[r][e[3]+1];(s||l)&&(n=r)}return n}},{key:"addSelectionFromStartAreaToSpecificRowIndex",value:function(e,t){this.hot.view.wt.selections.fill.clear(),this.hot.view.wt.selections.fill.add(new m.CellCoords(e[0],e[1])),this.hot.view.wt.selections.fill.add(new m.CellCoords(t,e[3]))}},{key:"setSelection",value:function(e){this.hot.selection.setRangeStart(new m.CellCoords(e[0],e[1])),this.hot.selection.setRangeEnd(new m.CellCoords(e[2],e[3]))}},{key:"selectAdjacent",value:function(){var e=this.getCornersOfSelectedCells(),t=this.getIndexOfLastAdjacentFilledInRow(e);return-1!==t&&(this.addSelectionFromStartAreaToSpecificRowIndex(e,t),!0)}},{key:"resetSelectionOfDraggedArea",value:function(){this.handleDraggedCells=0,this.hot.view.wt.selections.fill.clear()}},{key:"redrawBorders",value:function(e){this.hot.view.wt.selections.fill.clear(),this.hot.view.wt.selections.fill.add(this.hot.getSelectedRange().from),this.hot.view.wt.selections.fill.add(this.hot.getSelectedRange().to),this.hot.view.wt.selections.fill.add(e),this.hot.view.render()}},{key:"getIfMouseWasDraggedOutside",value:function(e){var t=(0,f.offset)(this.hot.table).top-(window.pageYOffset||document.documentElement.scrollTop)+(0,f.outerHeight)(this.hot.table),o=(0,f.offset)(this.hot.table).left-(window.pageXOffset||document.documentElement.scrollLeft)+(0,f.outerWidth)(this.hot.table);return e.clientY>t&&o>=e.clientX}},{key:"registerEvents",value:function(){var e=this;this.eventManager.addEventListener(document.documentElement,"mouseup",function(){return e.onMouseUp()}),this.eventManager.addEventListener(document.documentElement,"mousemove",function(t){return e.onMouseMove(t)})}},{key:"onCellCornerDblClick",value:function(){this.selectAdjacent()&&this.fillIn()}},{key:"onAfterCellCornerMouseDown",value:function(){this.handleDraggedCells=1,this.mouseDownOnCellCorner=!0}},{key:"onBeforeCellMouseOver",value:function(e){this.mouseDownOnCellCorner&&!this.hot.view.isMouseDown()&&this.handleDraggedCells&&(this.handleDraggedCells++,this.showBorder(e),this.addNewRowIfNeeded())}},{key:"onMouseUp",value:function(){this.handleDraggedCells&&(this.handleDraggedCells>1&&this.fillIn(),this.handleDraggedCells=0,this.mouseDownOnCellCorner=!1)}},{key:"onMouseMove",value:function(e){var t=this.getIfMouseWasDraggedOutside(e);!1===this.addingStarted&&this.handleDraggedCells>0&&t?(this.mouseDragOutside=!0,this.addingStarted=!0):this.mouseDragOutside=!1,this.mouseDragOutside&&this.autoInsertRow&&this.addRow()}},{key:"clearMappedSettings",value:function(){this.directions.length=0,this.autoInsertRow=!1}},{key:"mapSettings",value:function(){var e=(0,y.getMappedFillHandleSetting)(this.hot.getSettings().fillHandle);this.directions=e.directions,this.autoInsertRow=e.autoInsertRow}},{key:"destroy",value:function(){a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}}]),t}(c.default);(0,v.registerPlugin)("autofill",w),t.default=w},function(e,t,o){"use strict";function n(e,t,o,n){var r=o.length,i=o?o[0].length:0,s=[],l=t.row-e.row,a=t.col-e.col;if(-1!==["down","up"].indexOf(n)){for(var u=[],c=0;a>=c;c++){var h=parseInt(o[0][c],10),d=parseInt(o[r-1][c],10);u.push(("down"===n?d-h:h-d)/(r-1)||0)}s.push(u)}if(-1!==["right","left"].indexOf(n))for(var f=0;l>=f;f++){var p=parseInt(o[f][0],10),g=parseInt(o[f][i-1],10),v=("right"===n?g-p:p-g)/(i-1)||0;s.push([v])}return s}function r(e,t){var o=void 0,n=void 0,r=void 0;return t[0]===e[0]&&e[1]>t[1]?(r="left",o=new a.CellCoords(t[0],t[1]),n=new a.CellCoords(t[2],e[1]-1)):t[0]===e[0]&&t[3]>e[3]?(r="right",o=new a.CellCoords(t[0],e[3]+1),n=new a.CellCoords(t[2],t[3])):e[0]>t[0]&&t[1]===e[1]?(r="up",o=new a.CellCoords(t[0],t[1]),n=new a.CellCoords(e[0]-1,t[3])):t[2]>e[2]&&t[1]===e[1]&&(r="down",o=new a.CellCoords(e[2]+1,t[1]),n=new a.CellCoords(t[2],t[3])),{directionOfDrag:r,startOfDragCoords:o,endOfDragCoords:n}}function i(e){var t={};return!0===e?(t.directions=Object.keys(u),t.autoInsertRow=!0):(0,s.isObject)(e)?(t.autoInsertRow=!!(0,l.isDefined)(e.autoInsertRow)&&(e.direction!==u.horizontal&&e.autoInsertRow),t.directions=(0,l.isDefined)(e.direction)?[e.direction]:Object.keys(u)):"string"==typeof e?(t.directions=[e],t.autoInsertRow=!0):(t.directions=[],t.autoInsertRow=!1),t}t.__esModule=!0,t.DIRECTIONS=void 0,t.getDeltas=n,t.getDragDirectionAndRange=r,t.getMappedFillHandleSetting=i;var s=o(1),l=o(22),a=o(12),u=t.DIRECTIONS={horizontal:"horizontal",vertical:"vertical"}},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var l=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},a=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),u=o(13),c=n(u),h=o(2),d=o(34),f=o(0),p=o(85),g=n(p),v=o(1),m=o(6),y=o(5),w=o(175),C=n(w),b=o(32),S=function(e){function t(e){r(this,t);var o=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.heights=[],o.ghostTable=new g.default(o.hot),o.samplesGenerator=new C.default(function(e,t){return 0>e?-1===e?o.hot.getColHeader(t):null:o.hot.getDataAtCell(e,t)}),o.firstCalculation=!0,o.inProgress=!1,o.addHook("beforeRowResize",function(e,t,n){return o.onBeforeRowResize(e,t,n)}),o}return s(t,e),a(t,null,[{key:"CALCULATION_STEP",get:function(){return 50}},{key:"SYNC_CALCULATION_LIMIT",get:function(){return 500}}]),a(t,[{key:"isEnabled",value:function(){return!0===this.hot.getSettings().autoRowSize||(0,v.isObject)(this.hot.getSettings().autoRowSize)}},{key:"enablePlugin",value:function(){var e=this;this.enabled||(this.setSamplingOptions(),this.addHook("afterLoadData",function(){return e.onAfterLoadData()}),this.addHook("beforeChange",function(t){return e.onBeforeChange(t)}),this.addHook("beforeColumnMove",function(){return e.recalculateAllRowsHeight()}),this.addHook("beforeColumnResize",function(){return e.recalculateAllRowsHeight()}),this.addHook("beforeColumnSort",function(){return e.clearCache()}),this.addHook("beforeRender",function(t){return e.onBeforeRender(t)}),this.addHook("beforeRowMove",function(t,o){return e.onBeforeRowMove(t,o)}),this.addHook("modifyRowHeight",function(t,o){return e.getRowHeight(o,t)}),this.addHook("modifyColumnHeaderHeight",function(){return e.getColumnHeaderHeight()}),l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{key:"disablePlugin",value:function(){l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"calculateRowsHeight",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{from:0,to:this.hot.countRows()-1},t=this,o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{from:0,to:this.hot.countCols()-1},n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if("number"==typeof e&&(e={from:e,to:e}),"number"==typeof o&&(o={from:o,to:o}),null!==this.hot.getColHeader(0)){this.ghostTable.addColumnHeadersRow(this.samplesGenerator.generateRowSamples(-1,o).get(-1))}(0,m.rangeEach)(e.from,e.to,function(e){if(n||void 0===t.heights[e]){t.samplesGenerator.generateRowSamples(e,o).forEach(function(e,o){t.ghostTable.addRow(o,e)})}}),this.ghostTable.rows.length&&(this.ghostTable.getHeights(function(e,o){t.heights[e]=o}),this.ghostTable.clean())}},{key:"calculateAllRowsHeight",value:function(){var e=this,o=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{from:0,to:this.hot.countCols()-1},n=0,r=this.hot.countRows()-1,i=null;this.inProgress=!0;this.firstCalculation&&this.getSyncCalculationLimit()&&(this.calculateRowsHeight({from:0,to:this.getSyncCalculationLimit()},o),this.firstCalculation=!1,n=this.getSyncCalculationLimit()+1),r>n?function s(){if(!e.hot)return(0,d.cancelAnimationFrame)(i),void(e.inProgress=!1);e.calculateRowsHeight({from:n,to:Math.min(n+t.CALCULATION_STEP,r)},o),n=n+t.CALCULATION_STEP+1,r>n?i=(0,d.requestAnimationFrame)(s):((0,d.cancelAnimationFrame)(i),e.inProgress=!1,e.hot.view.wt.wtOverlays.adjustElementsSize(!0),e.hot.view.wt.wtOverlays.leftOverlay.needFullRender&&e.hot.view.wt.wtOverlays.leftOverlay.clone.draw())}():(this.inProgress=!1,this.hot.view.wt.wtOverlays.adjustElementsSize(!1))}},{key:"setSamplingOptions",value:function(){var e=this.hot.getSettings().autoRowSize,t=e&&(0,v.hasOwnProperty)(e,"samplingRatio")?this.hot.getSettings().autoRowSize.samplingRatio:void 0,o=e&&(0,v.hasOwnProperty)(e,"allowSampleDuplicates")?this.hot.getSettings().autoRowSize.allowSampleDuplicates:void 0;t&&!isNaN(t)&&this.samplesGenerator.setSampleCount(parseInt(t,10)),o&&this.samplesGenerator.setAllowDuplicates(o)}},{key:"recalculateAllRowsHeight",value:function(){(0,f.isVisible)(this.hot.view.wt.wtTable.TABLE)&&(this.clearCache(),this.calculateAllRowsHeight())}},{key:"getSyncCalculationLimit",value:function(){var e=t.SYNC_CALCULATION_LIMIT,o=this.hot.countRows()-1;return(0,v.isObject)(this.hot.getSettings().autoRowSize)&&(e=this.hot.getSettings().autoRowSize.syncLimit,(0,b.isPercentValue)(e)?e=(0,m.valueAccordingPercent)(o,e):e>>=0),Math.min(e,o)}},{key:"getRowHeight",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:void 0,o=t;return void 0!==this.heights[e]&&this.heights[e]>(t||0)&&(o=this.heights[e]),o}},{key:"getColumnHeaderHeight",value:function(){return this.heights[-1]}},{key:"getFirstVisibleRow",value:function(){var e=this.hot.view.wt;return e.wtViewport.rowsVisibleCalculator?e.wtTable.getFirstVisibleRow():e.wtViewport.rowsRenderCalculator?e.wtTable.getFirstRenderedRow():-1}},{key:"getLastVisibleRow",value:function(){var e=this.hot.view.wt;return e.wtViewport.rowsVisibleCalculator?e.wtTable.getLastVisibleRow():e.wtViewport.rowsRenderCalculator?e.wtTable.getLastRenderedRow():-1}},{key:"clearCache",value:function(){this.heights.length=0,this.heights[-1]=void 0}},{key:"clearCacheByRange",value:function(e){var t=this;"number"==typeof e&&(e={from:e,to:e}),(0,m.rangeEach)(Math.min(e.from,e.to),Math.max(e.from,e.to),function(e){t.heights[e]=void 0})}},{key:"isNeedRecalculate",value:function(){return!!(0,h.arrayFilter)(this.heights,function(e){return void 0===e}).length}},{key:"onBeforeRender",value:function(){var e=this.hot.renderCall;this.calculateRowsHeight({from:this.getFirstVisibleRow(),to:this.getLastVisibleRow()},void 0,e);var t=this.hot.getSettings().fixedRowsBottom;if(t){var o=this.hot.countRows()-1;this.calculateRowsHeight({from:o-t,to:o})}this.isNeedRecalculate()&&!this.inProgress&&this.calculateAllRowsHeight()}},{key:"onBeforeRowMove",value:function(e,t){this.clearCacheByRange({from:e,to:t}),this.calculateAllRowsHeight()}},{key:"onBeforeRowResize",value:function(e,t,o){return o&&(this.calculateRowsHeight(e,void 0,!0),t=this.getRowHeight(e)),t}},{key:"onAfterLoadData",value:function(){var e=this;this.hot.view?this.recalculateAllRowsHeight():setTimeout(function(){e.hot&&e.recalculateAllRowsHeight()},0)}},{key:"onBeforeChange",value:function(e){var t=null;1===e.length?t=e[0][0]:e.length>1&&(t={from:e[0][0],to:e[e.length-1][0]}),null!==t&&this.clearCacheByRange(t)}},{key:"destroy",value:function(){this.ghostTable.clean(),l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}}]),t}(c.default);(0,y.registerPlugin)("autoRowSize",S),t.default=S},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e){if(Array.isArray(e)){for(var t=0,o=Array(e.length);e.length>t;t++)o[t]=e[t];return o}return Array.from(e)}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function s(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function l(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},u=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),c=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},h=o(50),d=n(h),f=o(0),p=o(2),g=o(22),v=o(1),m=o(13),y=n(m),w=o(5),C=o(253),b=n(C),S=o(7),E=n(S);E.default.getSingleton().register("beforeColumnSort"),E.default.getSingleton().register("afterColumnSort");var R=function(e){function t(e){i(this,t);var o=s(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.sortIndicators=[],o.lastSortedColumn=null,o.sortEmptyCells=!1,o}return l(t,e),u(t,[{key:"isEnabled",value:function(){return!!this.hot.getSettings().columnSorting}},{key:"enablePlugin",value:function(){var e=this;if(!this.enabled){this.setPluginOptions();var o=this;this.hot.sortIndex=[],this.hot.sort=function(){var e=Array.prototype.slice.call(arguments);return o.sortByColumn.apply(o,r(e))},void 0===this.hot.getSettings().observeChanges&&this.enableObserveChangesPlugin(),this.addHook("afterTrimRow",function(t){return e.sort()}),this.addHook("afterUntrimRow",function(t){return e.sort()}),this.addHook("modifyRow",function(t){return e.translateRow(t)}),this.addHook("unmodifyRow",function(t){return e.untranslateRow(t)}),this.addHook("afterUpdateSettings",function(){return e.onAfterUpdateSettings()}),this.addHook("afterGetColHeader",function(t,o){return e.getColHeader(t,o)}),this.addHook("afterOnCellMouseDown",function(t,o){return e.onAfterOnCellMouseDown(t,o)}),this.addHook("afterCreateRow",function(){o.afterCreateRow.apply(o,arguments)}),this.addHook("afterRemoveRow",function(){o.afterRemoveRow.apply(o,arguments)}),this.addHook("afterInit",function(){return e.sortBySettings()}),this.addHook("afterLoadData",function(){e.hot.sortIndex=[],e.hot.view&&e.sortBySettings()}),this.hot.view&&this.sortBySettings(),c(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this)}}},{key:"disablePlugin",value:function(){this.hot.sort=void 0,c(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"onAfterUpdateSettings",value:function(){this.sortBySettings()}},{key:"sortBySettings",value:function(){var e=this.hot.getSettings().columnSorting,t=this.loadSortingState(),o=void 0,n=void 0;void 0===t?(o=e.column,n=e.sortOrder):(o=t.sortColumn,n=t.sortOrder),"number"==typeof o&&(this.lastSortedColumn=o,this.sortByColumn(o,n))}},{key:"setSortingColumn",value:function(e,t){if(void 0===e)return this.hot.sortColumn=void 0,void(this.hot.sortOrder=void 0);this.hot.sortOrder=this.hot.sortColumn===e&&void 0===t?!1===this.hot.sortOrder?void 0:!this.hot.sortOrder:void 0===t||t,this.hot.sortColumn=e}},{key:"sortByColumn",value:function(e,t){if(this.setSortingColumn(e,t),void 0!==this.hot.sortColumn){!1!==this.hot.runHooks("beforeColumnSort",this.hot.sortColumn,this.hot.sortOrder)&&this.sort(),this.updateOrderClass(),this.updateSortIndicator(),this.hot.runHooks("afterColumnSort",this.hot.sortColumn,this.hot.sortOrder),this.hot.render(),this.saveSortingState()}}},{key:"saveSortingState",value:function(){var e={};void 0!==this.hot.sortColumn&&(e.sortColumn=this.hot.sortColumn),void 0!==this.hot.sortOrder&&(e.sortOrder=this.hot.sortOrder),((0,v.hasOwnProperty)(e,"sortColumn")||(0,v.hasOwnProperty)(e,"sortOrder"))&&this.hot.runHooks("persistentStateSave","columnSorting",e)}},{key:"loadSortingState",value:function(){var e={};return this.hot.runHooks("persistentStateLoad","columnSorting",e),e.value}},{key:"updateOrderClass",value:function(){var e=void 0;!0===this.hot.sortOrder?e="ascending":!1===this.hot.sortOrder&&(e="descending"),this.sortOrderClass=e}},{key:"enableObserveChangesPlugin",value:function(){var e=this;this.hot._registerTimeout(setTimeout(function(){e.hot.updateSettings({observeChanges:!0})},0))}},{key:"defaultSort",value:function(e,t){return function(o,n){return"string"==typeof o[1]&&(o[1]=o[1].toLowerCase()),"string"==typeof n[1]&&(n[1]=n[1].toLowerCase()),o[1]===n[1]?0:(0,g.isEmpty)(o[1])?(0,g.isEmpty)(n[1])?0:t.columnSorting.sortEmptyCells&&e?-1:1:(0,g.isEmpty)(n[1])?(0,g.isEmpty)(o[1])?0:t.columnSorting.sortEmptyCells&&e?1:-1:isNaN(o[1])&&!isNaN(n[1])?e?1:-1:!isNaN(o[1])&&isNaN(n[1])?e?-1:1:(isNaN(o[1])||isNaN(n[1])||(o[1]=parseFloat(o[1]),n[1]=parseFloat(n[1])),n[1]>o[1]?e?-1:1:o[1]>n[1]?e?1:-1:0)}}},{key:"dateSort",value:function(e,t){return function(o,n){if(o[1]===n[1])return 0;if((0,g.isEmpty)(o[1]))return(0,g.isEmpty)(n[1])?0:t.columnSorting.sortEmptyCells&&e?-1:1;if((0,g.isEmpty)(n[1]))return(0,g.isEmpty)(o[1])?0:t.columnSorting.sortEmptyCells&&e?1:-1;var r=(0,d.default)(o[1],t.dateFormat),i=(0,d.default)(n[1],t.dateFormat);return r.isValid()?i.isValid()?i.isAfter(r)?e?-1:1:i.isBefore(r)?e?1:-1:0:-1:1}}},{key:"numericSort",value:function(e,t){return function(o,n){var r=parseFloat(o[1]),i=parseFloat(n[1]);if(r===i||isNaN(r)&&isNaN(i))return 0;if(t.columnSorting.sortEmptyCells){if((0,g.isEmpty)(o[1]))return e?-1:1;if((0,g.isEmpty)(n[1]))return e?1:-1}return isNaN(r)?1:isNaN(i)?-1:i>r?e?-1:1:r>i?e?1:-1:0}}},{key:"sort",value:function(){if(void 0===this.hot.sortOrder)return void(this.hot.sortIndex.length=0);var e=this.hot.getCellMeta(0,this.hot.sortColumn),t=this.hot.countEmptyRows(),o=void 0,n=void 0;this.hot.sortingEnabled=!1,this.hot.sortIndex.length=0,void 0===e.columnSorting.sortEmptyCells&&(e.columnSorting={sortEmptyCells:this.sortEmptyCells}),n=this.hot.getSettings().maxRows===Number.POSITIVE_INFINITY?this.hot.countRows()-this.hot.getSettings().minSpareRows:this.hot.countRows()-t;for(var r=0,i=n;i>r;r++)this.hot.sortIndex.push([r,this.hot.getDataAtCell(r,this.hot.sortColumn)]);if(e.sortFunction)o=e.sortFunction;else switch(e.type){case"date":o=this.dateSort;break;case"numeric":o=this.numericSort;break;default:o=this.defaultSort}(0,b.default)(this.hot.sortIndex,o(this.hot.sortOrder,e));for(var s=this.hot.sortIndex.length;s<this.hot.countRows();s++)this.hot.sortIndex.push([s,this.hot.getDataAtCell(s,this.hot.sortColumn)]);this.hot.sortingEnabled=!0}},{key:"updateSortIndicator",value:function(){if(void 0!==this.hot.sortOrder){this.sortIndicators[this.hot.sortColumn]=this.hot.getCellMeta(0,this.hot.sortColumn).sortIndicator}}},{key:"translateRow",value:function(e){return this.hot.sortingEnabled&&void 0!==this.hot.sortOrder&&this.hot.sortIndex&&this.hot.sortIndex.length&&this.hot.sortIndex[e]?this.hot.sortIndex[e][0]:e}},{key:"untranslateRow",value:function(e){if(this.hot.sortingEnabled&&this.hot.sortIndex&&this.hot.sortIndex.length)for(var t=0;this.hot.sortIndex.length>t;t++)if(this.hot.sortIndex[t][0]==e)return t}},{key:"getColHeader",value:function(e,t){if(0>e||!t.parentNode)return!1;var o=t.querySelector(".colHeader"),n=(t.getAttribute("colspan"),t.parentNode.parentNode.childNodes),r=Array.prototype.indexOf.call(n,t.parentNode);r-=n.length,o&&(this.hot.getSettings().columnSorting&&e>=0&&-1===r&&(0,f.addClass)(o,"columnSorting"),(0,f.removeClass)(o,"descending"),(0,f.removeClass)(o,"ascending"),this.sortIndicators[e]&&e===this.hot.sortColumn&&("ascending"===this.sortOrderClass?(0,f.addClass)(o,"ascending"):"descending"===this.sortOrderClass&&(0,f.addClass)(o,"descending")))}},{key:"isSorted",value:function(){return void 0!==this.hot.sortColumn}},{key:"afterCreateRow",value:function(e,t){if(this.isSorted()){for(var o=0;this.hot.sortIndex.length>o;o++)e>this.hot.sortIndex[o][0]||(this.hot.sortIndex[o][0]+=t);for(var n=0;t>n;n++)this.hot.sortIndex.splice(e+n,0,[e+n,this.hot.getSourceData()[e+n][this.hot.sortColumn+this.hot.colOffset()]]);this.saveSortingState()}}},{key:"afterRemoveRow",value:function(e,t){function o(e){return(0,p.arrayReduce)(n,function(t,o){return e>o&&t++,t},0)}if(this.isSorted()){var n=this.hot.sortIndex.splice(e,t);n=(0,p.arrayMap)(n,function(e){return e[0]}),this.hot.sortIndex=(0,p.arrayMap)(this.hot.sortIndex,function(e,t){var n=o(e[0]);return n&&(e[0]-=n),e}),this.saveSortingState()}}},{key:"setPluginOptions",value:function(){var e=this.hot.getSettings().columnSorting;this.sortEmptyCells="object"===(void 0===e?"undefined":a(e))&&(e.sortEmptyCells||!1)}},{key:"onAfterOnCellMouseDown",value:function(e,t){t.row>-1||(0,f.hasClass)(e.realTarget,"columnSorting")&&(t.col!==this.lastSortedColumn&&(this.hot.sortOrder=!0),this.lastSortedColumn=t.col,this.sortByColumn(t.col))}}]),t}(y.default);(0,w.registerPlugin)("columnSorting",R),t.default=R},function(e,t,o){"use strict";function n(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:l,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:e.length;if(1>=Math.abs(i-o))return[];var s=Math.ceil((o+i)/2);return n(e,t,o,s),n(e,t,s,i),r(e,t,o,s,i)}function r(e,t,o,n,r){for(var i=new s.default,l=new s.default,a=n-o,u=r-n,c=Math.max(a,u),h=r-o,d=0;c>d;d+=1)a>d&&i.push(e[o+d]),u>d&&l.push(e[n+d]);for(var f=0;h>f;)e[o+f]=i.first&&l.first?t(i.first.data,l.first.data)>0?l.shift().data:i.shift().data:i.first?i.shift().data:l.shift().data,f+=1;return e}t.__esModule=!0,t.default=n,t.merge=r;var i=o(254),s=function(e){return e&&e.__esModule?e:{default:e}}(i),l=function(e,t){var o=""+e,n=""+t;return o===n?0:n>o?-1:1}},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=function e(t){n(this,e),this.data=t,this.next=null,this.prev=null},s=function(){function e(){n(this,e),this.first=null,this.last=null}return r(e,[{key:"push",value:function(e){var t=new i(e);if(null===this.first)this.first=t,this.last=t;else{var o=this.last;this.last=t,t.prev=o,o.next=t}}},{key:"unshift",value:function(e){var t=new i(e);if(null===this.first)this.first=t,this.last=t;else{var o=this.first;this.first=t,t.next=o,o.prev=t}}},{key:"inorder",value:function(e){for(var t=this.first;t;)e(t),t=t.next}},{key:"remove",value:function(e){if(null===this.first)return!1;for(var t=this.first,o=void 0,n=void 0;t;){if(t.data===e)return o=t.next,n=t.prev,o&&(o.prev=n),n&&(n.next=o),t===this.first&&(this.first=o),t===this.last&&(this.last=n),!0;t=t.next}return!1}},{key:"hasCycle",value:function(){for(var e=this.first,t=this.first;;){if(null===e)return!1;if(null===(e=e.next))return!1;if(e=e.next,t=t.next,e===t)return!0}}},{key:"pop",value:function(){if(null===this.last)return null;var e=this.last;return this.last=this.last.prev,e}},{key:"shift",value:function(){if(null===this.first)return null;var e=this.first;return this.first=this.first.next,e}},{key:"recursiveReverse",value:function(){function e(t,o){o&&(e(o,o.next),o.next=t)}if(this.first){e(this.first,this.first.next),this.first.next=null;var t=this.first;this.first=this.last,this.last=t}}},{key:"reverse",value:function(){if(this.first&&this.first.next){for(var e=this.first.next,t=this.first,o=void 0;e;)o=e.next,e.next=t,t.prev=e,t=e,e=o;this.first.next=null,this.last.prev=null,o=this.first,this.first=t,this.last=o}}}]),e}();t.NodeStructure=i,t.default=s},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t,o){return t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o,e}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function s(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function l(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var a=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),u=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},c=o(0),h=o(1),d=o(4),f=n(d),p=o(12),g=o(5),v=o(13),m=n(v),y=o(256),w=n(y),C=o(19),b=o(257),S=n(b);o(258);var E=new WeakMap,R=function(e){function t(e){i(this,t);var o=s(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.editor=null,o.displaySwitch=null,o.eventManager=null,o.range={},o.mouseDown=!1,o.contextMenuEvent=!1,o.timer=null,E.set(o,{tempEditorDimensions:{},cellBelowCursor:null}),o}return l(t,e),a(t,[{key:"isEnabled",value:function(){return!!this.hot.getSettings().comments}},{key:"enablePlugin",value:function(){var e=this;this.enabled||(this.editor||(this.editor=new w.default),this.eventManager||(this.eventManager=new f.default(this)),this.displaySwitch||(this.displaySwitch=new S.default(this.getDisplayDelaySetting())),this.addHook("afterContextMenuDefaultOptions",function(t){return e.addToContextMenu(t)}),this.addHook("afterRenderer",function(t,o,n,r,i,s){return e.onAfterRenderer(t,s)}),this.addHook("afterScrollHorizontally",function(){return e.hide()}),this.addHook("afterScrollVertically",function(){return e.hide()}),this.addHook("afterBeginEditing",function(t){return e.onAfterBeginEditing(t)}),this.displaySwitch.addLocalHook("hide",function(){return e.hide()}),this.displaySwitch.addLocalHook("show",function(t,o){return e.showAtCell(t,o)}),this.registerListeners(),u(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{key:"updatePlugin",value:function(){this.disablePlugin(),this.enablePlugin(),u(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"updatePlugin",this).call(this),this.displaySwitch.updateDelay(this.getDisplayDelaySetting())}},{key:"disablePlugin",value:function(){u(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"registerListeners",value:function(){var e=this;this.eventManager.addEventListener(document,"mouseover",function(t){return e.onMouseOver(t)}),this.eventManager.addEventListener(document,"mousedown",function(t){return e.onMouseDown(t)}),this.eventManager.addEventListener(document,"mouseup",function(t){return e.onMouseUp(t)}),this.eventManager.addEventListener(this.editor.getInputElement(),"blur",function(t){return e.onEditorBlur(t)}),this.eventManager.addEventListener(this.editor.getInputElement(),"mousedown",function(t){return e.onEditorMouseDown(t)}),this.eventManager.addEventListener(this.editor.getInputElement(),"mouseup",function(t){return e.onEditorMouseUp(t)})}},{key:"setRange",value:function(e){this.range=e}},{key:"clearRange",value:function(){this.range={}}},{key:"targetIsCellWithComment",value:function(e){var t=(0,c.closest)(e.target,"TD","TBODY");return!!(t&&(0,c.hasClass)(t,"htCommentCell")&&(0,c.closest)(t,[this.hot.rootElement]))}},{key:"targetIsCommentTextArea",value:function(e){return this.editor.getInputElement()===e.target}},{key:"setComment",value:function(e){if(!this.range.from)throw Error('Before using this method, first set cell range (hot.getPlugin("comment").setRange())');var t=this.editor.getValue(),o="";null!=e?o=e:null!=t&&(o=t),this.updateCommentMeta(this.range.from.row,this.range.from.col,r({},"value",o)),this.hot.render()}},{key:"setCommentAtCell",value:function(e,t,o){this.setRange({from:new p.CellCoords(e,t)}),this.setComment(o)}},{key:"removeComment",value:function(){var e=0>=arguments.length||void 0===arguments[0]||arguments[0];if(!this.range.from)throw Error('Before using this method, first set cell range (hot.getPlugin("comment").setRange())');this.hot.setCellMeta(this.range.from.row,this.range.from.col,"comment",void 0),e&&this.hot.render(),this.hide()}},{key:"removeCommentAtCell",value:function(e,t){var o=2>=arguments.length||void 0===arguments[2]||arguments[2];this.setRange({from:new p.CellCoords(e,t)}),this.removeComment(o)}},{key:"getComment",value:function(){return this.getCommentMeta(this.range.from.row,this.range.from.col,"value")}},{key:"getCommentAtCell",value:function(e,t){return this.getCommentMeta(e,t,"value")}},{key:"show",value:function(){if(!this.range.from)throw Error('Before using this method, first set cell range (hot.getPlugin("comment").setRange())');var e=this.hot.getCellMeta(this.range.from.row,this.range.from.col);return this.refreshEditor(!0),this.editor.setValue(e.comment?e.comment.value:""),this.editor.hidden&&this.editor.show(),!0}},{key:"showAtCell",value:function(e,t){return this.setRange({from:new p.CellCoords(e,t)}),this.show()}},{key:"hide",value:function(){this.editor.hidden||this.editor.hide()}},{key:"refreshEditor",value:function(){if(arguments.length>0&&void 0!==arguments[0]&&arguments[0]||this.range.from&&this.editor.isVisible()){var e=(0,c.getScrollableElement)(this.hot.view.wt.wtTable.TABLE),t=this.hot.view.wt.wtTable.getCell(this.range.from),o=this.range.from.row,n=this.range.from.col,r=(0,c.offset)(t),i=this.hot.view.wt.wtTable.getStretchedColumnWidth(n),s=0>r.top?0:r.top,l=r.left;this.hot.view.wt.wtViewport.hasVerticalScroll()&&e!==window&&(s-=this.hot.view.wt.wtOverlays.topOverlay.getScrollPosition()),this.hot.view.wt.wtViewport.hasHorizontalScroll()&&e!==window&&(l-=this.hot.view.wt.wtOverlays.leftOverlay.getScrollPosition());var a=l+i,u=s,h=this.getCommentMeta(o,n,"style"),d=this.getCommentMeta(o,n,"readOnly");h?this.editor.setSize(h.width,h.height):this.editor.resetSize(),this.editor.setReadOnlyState(d),this.editor.setPosition(a,u)}}},{key:"checkSelectionCommentsConsistency",value:function(){var e=this.hot.getSelectedRange();if(!e)return!1;var t=!1,o=e.from;return this.getCommentMeta(o.row,o.col,"value")&&(t=!0),t}},{key:"updateCommentMeta",value:function(e,t,o){var n=this.hot.getCellMeta(e,t).comment,r=void 0;n?(r=(0,h.deepClone)(n),(0,h.deepExtend)(r,o)):r=o,this.hot.setCellMeta(e,t,"comment",r)}},{key:"getCommentMeta",value:function(e,t,o){var n=this.hot.getCellMeta(e,t);if(n.comment)return n.comment[o]}},{key:"onMouseDown",value:function(e){if(this.mouseDown=!0,this.hot.view&&this.hot.view.wt){if(!this.contextMenuEvent&&!this.targetIsCommentTextArea(e)){var t=(0,c.closest)(e.target,"TD","TBODY"),o=null;t&&(o=this.hot.view.wt.wtTable.getCoords(t)),(!t||this.range.from&&o&&(this.range.from.row!==o.row||this.range.from.col!==o.col))&&this.hide()}this.contextMenuEvent=!1}}},{key:"onMouseOver",value:function(e){var t=E.get(this);if(t.cellBelowCursor=document.elementFromPoint(e.clientX,e.clientY),!(this.mouseDown||this.editor.isFocused()||(0,c.hasClass)(e.target,"wtBorder")||t.cellBelowCursor!==e.target)&&this.editor)if(this.targetIsCellWithComment(e)){var o=this.hot.view.wt.wtTable.getCoords(e.target),n={from:new p.CellCoords(o.row,o.col)};this.displaySwitch.show(n)}else(0,c.isChildOf)(e.target,document)&&!this.targetIsCommentTextArea(e)&&this.displaySwitch.hide()}},{key:"onMouseUp",value:function(e){this.mouseDown=!1}},{key:"onAfterRenderer",value:function(e,t){t.comment&&t.comment.value&&(0,c.addClass)(e,t.commentedCellClassName)}},{key:"onEditorBlur",value:function(e){this.setComment()}},{key:"onEditorMouseDown",value:function(e){E.get(this).tempEditorDimensions={width:(0,c.outerWidth)(e.target),height:(0,c.outerHeight)(e.target)}}},{key:"onEditorMouseUp",value:function(e){var t=E.get(this),o=(0,c.outerWidth)(e.target),n=(0,c.outerHeight)(e.target);o===t.tempEditorDimensions.width+1&&n===t.tempEditorDimensions.height+2||this.updateCommentMeta(this.range.from.row,this.range.from.col,r({},"style",{width:o,height:n}))}},{key:"onContextMenuAddComment",value:function(){var e=this;this.displaySwitch.cancelHiding();var t=this.hot.getSelectedRange();this.contextMenuEvent=!0,this.setRange({from:t.from}),this.show(),setTimeout(function(){e.hot&&(e.hot.deselectCell(),e.editor.focus())},10)}},{key:"onContextMenuRemoveComment",value:function(e){this.contextMenuEvent=!0;for(var t=e.start.row;e.end.row>=t;t++)for(var o=e.start.col;e.end.col>=o;o++)this.removeCommentAtCell(t,o,!1);this.hot.render()}},{key:"onContextMenuMakeReadOnly",value:function(e){this.contextMenuEvent=!0;for(var t=e.start.row;e.end.row>=t;t++)for(var o=e.start.col;e.end.col>=o;o++){var n=!!this.getCommentMeta(t,o,"readOnly");this.updateCommentMeta(t,o,r({},"readOnly",!n))}}},{key:"addToContextMenu",value:function(e){var t=this;e.items.push({name:"---------"},{key:"commentsAddEdit",name:function(){return t.checkSelectionCommentsConsistency()?"Edit comment":"Add comment"},callback:function(){return t.onContextMenuAddComment()},disabled:function(){return!(this.getSelected()&&!this.selection.selectedHeader.corner)}},{key:"commentsRemove",name:function(){return"Delete comment"},callback:function(e,o){return t.onContextMenuRemoveComment(o)},disabled:function(){return t.hot.selection.selectedHeader.corner}},{key:"commentsReadOnly",name:function(){var e=this,t="Read only comment";return(0,C.checkSelectionConsistency)(this.getSelectedRange(),function(t,o){var n=e.getCellMeta(t,o).comment;if(n&&(n=n.readOnly),n)return!0})&&(t=(0,C.markLabelAsSelected)(t)),t},callback:function(e,o){return t.onContextMenuMakeReadOnly(o)},disabled:function(){return t.hot.selection.selectedHeader.corner||!t.checkSelectionCommentsConsistency()}})}},{key:"getDisplayDelaySetting",value:function(){var e=this.hot.getSettings().comments;if((0,h.isObject)(e))return e.displayDelay}},{key:"onAfterBeginEditing",value:function(e,t){this.hide()}},{key:"destroy",value:function(){this.editor&&this.editor.destroy(),this.displaySwitch&&this.displaySwitch.destroy(),u(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}}]),t}(m.default);(0,g.registerPlugin)("comments",R),t.default=R},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=o(0);t.default=function(){function e(){n(this,e),this.editor=this.createEditor(),this.editorStyle=this.editor.style,this.hidden=!0,this.hide()}return r(e,null,[{key:"CLASS_EDITOR_CONTAINER",get:function(){return"htCommentsContainer"}},{key:"CLASS_EDITOR",get:function(){return"htComments"}},{key:"CLASS_INPUT",get:function(){return"htCommentTextArea"}},{key:"CLASS_CELL",get:function(){return"htCommentCell"}}]),r(e,[{key:"setPosition",value:function(e,t){this.editorStyle.left=e+"px",this.editorStyle.top=t+"px"}},{key:"setSize",value:function(e,t){if(e&&t){var o=this.getInputElement();o.style.width=e+"px",o.style.height=t+"px"}}},{key:"resetSize",value:function(){var e=this.getInputElement();e.style.width="",e.style.height=""}},{key:"setReadOnlyState",value:function(e){this.getInputElement().readOnly=e}},{key:"show",value:function(){this.editorStyle.display="block",this.hidden=!1}},{key:"hide",value:function(){this.editorStyle.display="none",this.hidden=!0}},{key:"isVisible",value:function(){return"block"===this.editorStyle.display}},{key:"setValue",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";e=e||"",this.getInputElement().value=e}},{key:"getValue",value:function(){return this.getInputElement().value}},{key:"isFocused",value:function(){return document.activeElement===this.getInputElement()}},{key:"focus",value:function(){this.getInputElement().focus()}},{key:"createEditor",value:function(){var t=document.querySelector("."+e.CLASS_EDITOR_CONTAINER),o=void 0,n=void 0;return t||(t=document.createElement("div"),(0,i.addClass)(t,e.CLASS_EDITOR_CONTAINER),document.body.appendChild(t)),o=document.createElement("div"),(0,i.addClass)(o,e.CLASS_EDITOR),n=document.createElement("textarea"),(0,i.addClass)(n,e.CLASS_INPUT),o.appendChild(n),t.appendChild(o),o}},{key:"getInputElement",value:function(){return this.editor.querySelector("."+e.CLASS_INPUT)}},{key:"destroy",value:function(){this.editor.parentNode.removeChild(this.editor),this.editor=null,this.editorStyle=null}}]),e}()},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=o(35),s=o(1),l=o(87),a=function(e){return e&&e.__esModule?e:{default:e}}(l),u=function(){function e(t){n(this,e),this.wasLastActionShow=!0,this.showDebounced=null,this.hidingTimer=null,this.updateDelay(t)}return r(e,[{key:"hide",value:function(){var e=this;this.wasLastActionShow=!1,this.hidingTimer=setTimeout(function(){!1===e.wasLastActionShow&&e.runLocalHooks("hide")},250)}},{key:"show",value:function(e){this.wasLastActionShow=!0,this.showDebounced(e)}},{key:"cancelHiding",value:function(){this.wasLastActionShow=!0,clearTimeout(this.hidingTimer),this.hidingTimer=null}},{key:"updateDelay",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:250;this.showDebounced=(0,i.debounce)(function(t){e.wasLastActionShow&&e.runLocalHooks("show",t.from.row,t.from.col)},t)}},{key:"destroy",value:function(){this.clearLocalHooks()}}]),e}();(0,s.mixin)(u,a.default),t.default=u},function(e,t){},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var l=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},a=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),u=o(13),c=n(u),h=o(7),d=n(h),f=o(2),p=o(260),g=n(p),v=o(4),m=n(v),y=o(261),w=n(y),C=o(273),b=n(C),S=o(5),E=o(10),R=o(0),O=o(88);o(275),d.default.getSingleton().register("afterContextMenuDefaultOptions"),d.default.getSingleton().register("afterContextMenuShow"),d.default.getSingleton().register("afterContextMenuHide"),d.default.getSingleton().register("afterContextMenuExecute");var k=function(e){function t(e){r(this,t);var o=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.eventManager=new m.default(o),o.commandExecutor=new g.default(o.hot),o.itemsFactory=null,o.menu=null,o}return s(t,e),a(t,null,[{key:"DEFAULT_ITEMS",get:function(){return[O.ROW_ABOVE,O.ROW_BELOW,O.SEPARATOR,O.COLUMN_LEFT,O.COLUMN_RIGHT,O.SEPARATOR,O.REMOVE_ROW,O.REMOVE_COLUMN,O.SEPARATOR,O.UNDO,O.REDO,O.SEPARATOR,O.READ_ONLY,O.SEPARATOR,O.ALIGNMENT]}}]),a(t,[{key:"isEnabled",value:function(){return this.hot.getSettings().contextMenu}},{key:"enablePlugin",value:function(){var e=this;if(!this.enabled){this.itemsFactory=new w.default(this.hot,t.DEFAULT_ITEMS);var o=this.hot.getSettings().contextMenu,n={items:this.itemsFactory.getItems(o)};this.registerEvents(),"function"==typeof o.callback&&this.commandExecutor.setCommonCallback(o.callback),l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this),this.callOnPluginsReady(function(){e.hot.runHooks("afterContextMenuDefaultOptions",n),e.itemsFactory.setPredefinedItems(n.items);var t=e.itemsFactory.getItems(o);e.menu=new b.default(e.hot,{className:"htContextMenu",keepInViewport:!0}),e.hot.runHooks("beforeContextMenuSetItems",t),e.menu.setMenuItems(t),e.menu.addLocalHook("afterOpen",function(){return e.onMenuAfterOpen()}),e.menu.addLocalHook("afterClose",function(){return e.onMenuAfterClose()}),e.menu.addLocalHook("executeCommand",function(){for(var t=arguments.length,o=Array(t),n=0;t>n;n++)o[n]=arguments[n];return e.executeCommand.apply(e,o)}),(0,f.arrayEach)(t,function(t){return e.commandExecutor.registerCommand(t.key,t)})})}}},{key:"updatePlugin",value:function(){this.disablePlugin(),this.enablePlugin(),l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"updatePlugin",this).call(this)}},{key:"disablePlugin",value:function(){this.close(),this.menu&&(this.menu.destroy(),this.menu=null),l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"registerEvents",value:function(){var e=this;this.eventManager.addEventListener(this.hot.rootElement,"contextmenu",function(t){return e.onContextMenu(t)})}},{key:"open",value:function(e){this.menu&&(this.menu.open(),this.menu.setPosition({top:parseInt((0,E.pageY)(e),10)-(0,R.getWindowScrollTop)(),left:parseInt((0,E.pageX)(e),10)-(0,R.getWindowScrollLeft)()}),this.menu.hotMenu.isHotTableEnv=this.hot.isHotTableEnv)}},{key:"close",value:function(){this.menu&&this.menu.close()}},{key:"executeCommand",value:function(){for(var e=arguments.length,t=Array(e),o=0;e>o;o++)t[o]=arguments[o];this.commandExecutor.execute.apply(this.commandExecutor,t)}},{key:"onContextMenu",value:function(e){var t=this.hot.getSettings(),o=t.rowHeaders,n=t.colHeaders,r=e.realTarget;this.close(),(0,R.hasClass)(r,"handsontableInput")||(e.preventDefault(),(0,E.stopPropagation)(e),(o||n||function(e){return"TD"===e.nodeName||"TD"===e.parentNode.nodeName}(r)||(0,R.hasClass)(r,"current")&&(0,R.hasClass)(r,"wtBorder"))&&this.open(e))}},{key:"onMenuAfterOpen",value:function(){this.hot.runHooks("afterContextMenuShow",this)}},{key:"onMenuAfterClose",value:function(){this.hot.listen(),this.hot.runHooks("afterContextMenuHide",this)}},{key:"destroy",value:function(){this.close(),this.menu&&this.menu.destroy(),l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}}]),t}(c.default);k.SEPARATOR={name:O.SEPARATOR},(0,S.registerPlugin)("contextMenu",k),t.default=k},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){var o=void 0;return(0,s.arrayEach)(t,function(t){var n=t.key?t.key.split(":"):null;if(Array.isArray(n)&&n[1]===e)return o=t,!1}),o}t.__esModule=!0;var i=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),s=o(2),l=o(1);t.default=function(){function e(t){n(this,e),this.hot=t,this.commands={},this.commonCallback=null}return i(e,[{key:"registerCommand",value:function(e,t){this.commands[e]=t}},{key:"setCommonCallback",value:function(e){this.commonCallback=e}},{key:"execute",value:function(e){for(var t=this,o=arguments.length,n=Array(o>1?o-1:0),i=1;o>i;i++)n[i-1]=arguments[i];var a=e.split(":");e=a[0];var u=2===a.length?a[1]:null,c=this.commands[e];if(!c)throw Error("Menu command '"+e+"' not exists.");if(u&&c.submenu&&(c=r(u,c.submenu.items)),!0!==c.disabled&&("function"!=typeof c.disabled||!0!==c.disabled.call(this.hot))&&!(0,l.hasOwnProperty)(c,"submenu")){var h=[];"function"==typeof c.callback&&h.push(c.callback),"function"==typeof this.commonCallback&&h.push(this.commonCallback),n.unshift(a.join(":")),(0,s.arrayEach)(h,function(e){return e.apply(t.hot,n)})}}}]),e}()},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},n=[];return e&&e.items?e=e.items:Array.isArray(e)||(e=t),(0,s.isObject)(e)?(0,s.objectEach)(e,function(e,t){var r=o["string"==typeof e?e:t];r||(r=e),(0,s.isObject)(e)?(0,s.extend)(r,e):"string"==typeof r&&(r={name:r}),void 0===r.key&&(r.key=t),n.push(r)}):(0,l.arrayEach)(e,function(e,t){var r=o[e];(r||0>a.ITEMS.indexOf(e))&&(r||(r={name:e,key:""+t}),(0,s.isObject)(e)&&(0,s.extend)(r,e),void 0===r.key&&(r.key=t),n.push(r))}),n}t.__esModule=!0;var i=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),s=o(1),l=o(2),a=o(88);t.default=function(){function e(t){var o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;n(this,e),this.hot=t,this.predefinedItems=(0,a.predefinedItems)(),this.defaultOrderPattern=o}return i(e,[{key:"setPredefinedItems",value:function(e){var t=this,o={};this.defaultOrderPattern.length=0,(0,s.objectEach)(e,function(e,n){var r="";e.name===a.SEPARATOR?(o[a.SEPARATOR]=e,r=a.SEPARATOR):isNaN(parseInt(n,10))?(e.key=void 0===e.key?n:e.key,o[n]=e,r=e.key):(o[e.key]=e,r=e.key),t.defaultOrderPattern.push(r)}),this.predefinedItems=o}},{key:"getItems",value:function(){return r(arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,this.defaultOrderPattern,this.predefinedItems)}}]),e}()},function(e,t,o){"use strict";function n(){return{key:s,name:"Alignment",disabled:function(){return!(this.getSelectedRange()&&!this.selection.selectedHeader.corner)},submenu:{items:[{key:s+":left",name:function(){var e=this,t="Left";return(0,r.checkSelectionConsistency)(this.getSelectedRange(),function(t,o){var n=e.getCellMeta(t,o).className;if(n&&-1!==n.indexOf("htLeft"))return!0})&&(t=(0,r.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),o=(0,r.getAlignmentClasses)(t,function(t,o){return e.getCellMeta(t,o).className});this.runHooks("beforeCellAlignment",o,t,"horizontal","htLeft"),(0,r.align)(t,"horizontal","htLeft",function(t,o){return e.getCellMeta(t,o)},function(t,o,n,r){return e.setCellMeta(t,o,n,r)}),this.render()},disabled:!1},{key:s+":center",name:function(){var e=this,t="Center";return(0,r.checkSelectionConsistency)(this.getSelectedRange(),function(t,o){var n=e.getCellMeta(t,o).className;if(n&&-1!==n.indexOf("htCenter"))return!0})&&(t=(0,r.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),o=(0,r.getAlignmentClasses)(t,function(t,o){return e.getCellMeta(t,o).className});this.runHooks("beforeCellAlignment",o,t,"horizontal","htCenter"),(0,r.align)(t,"horizontal","htCenter",function(t,o){return e.getCellMeta(t,o)},function(t,o,n,r){return e.setCellMeta(t,o,n,r)}),this.render()},disabled:!1},{key:s+":right",name:function(){var e=this,t="Right";return(0,r.checkSelectionConsistency)(this.getSelectedRange(),function(t,o){var n=e.getCellMeta(t,o).className;if(n&&-1!==n.indexOf("htRight"))return!0})&&(t=(0,r.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),o=(0,r.getAlignmentClasses)(t,function(t,o){return e.getCellMeta(t,o).className});this.runHooks("beforeCellAlignment",o,t,"horizontal","htRight"),(0,r.align)(t,"horizontal","htRight",function(t,o){return e.getCellMeta(t,o)},function(t,o,n,r){return e.setCellMeta(t,o,n,r)}),this.render()},disabled:!1},{key:s+":justify",name:function(){var e=this,t="Justify";return(0,r.checkSelectionConsistency)(this.getSelectedRange(),function(t,o){var n=e.getCellMeta(t,o).className;if(n&&-1!==n.indexOf("htJustify"))return!0})&&(t=(0,r.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),o=(0,r.getAlignmentClasses)(t,function(t,o){return e.getCellMeta(t,o).className});this.runHooks("beforeCellAlignment",o,t,"horizontal","htJustify"),(0,r.align)(t,"horizontal","htJustify",function(t,o){return e.getCellMeta(t,o)},function(t,o,n,r){return e.setCellMeta(t,o,n,r)}),this.render()},disabled:!1},{name:i.KEY},{key:s+":top",name:function(){var e=this,t="Top";return(0,r.checkSelectionConsistency)(this.getSelectedRange(),function(t,o){var n=e.getCellMeta(t,o).className;if(n&&-1!==n.indexOf("htTop"))return!0})&&(t=(0,r.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),o=(0,r.getAlignmentClasses)(t,function(t,o){return e.getCellMeta(t,o).className});this.runHooks("beforeCellAlignment",o,t,"vertical","htTop"),(0,r.align)(t,"vertical","htTop",function(t,o){return e.getCellMeta(t,o)},function(t,o,n,r){return e.setCellMeta(t,o,n,r)}),this.render()},disabled:!1},{key:s+":middle",name:function(){var e=this,t="Middle";return(0,r.checkSelectionConsistency)(this.getSelectedRange(),function(t,o){var n=e.getCellMeta(t,o).className;if(n&&-1!==n.indexOf("htMiddle"))return!0})&&(t=(0,r.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),o=(0,r.getAlignmentClasses)(t,function(t,o){return e.getCellMeta(t,o).className});this.runHooks("beforeCellAlignment",o,t,"vertical","htMiddle"),(0,r.align)(t,"vertical","htMiddle",function(t,o){return e.getCellMeta(t,o)},function(t,o,n,r){return e.setCellMeta(t,o,n,r)}),this.render()},disabled:!1},{key:s+":bottom",name:function(){var e=this,t="Bottom";return(0,r.checkSelectionConsistency)(this.getSelectedRange(),function(t,o){var n=e.getCellMeta(t,o).className;if(n&&-1!==n.indexOf("htBottom"))return!0})&&(t=(0,r.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),o=(0,r.getAlignmentClasses)(t,function(t,o){return e.getCellMeta(t,o).className});this.runHooks("beforeCellAlignment",o,t,"vertical","htBottom"),(0,r.align)(t,"vertical","htBottom",function(t,o){return e.getCellMeta(t,o)},function(t,o,n,r){return e.setCellMeta(t,o,n,r)}),this.render()},disabled:!1}]}}}t.__esModule=!0,t.KEY=void 0,t.default=n;var r=o(19),i=o(86),s=t.KEY="alignment"},function(e,t,o){"use strict";function n(){return{key:i,name:"Clear column",callback:function(e,t){var o=t.start.col;this.countRows()&&this.populateFromArray(0,o,[[null]],Math.max(t.start.row,t.end.row),o,"ContextMenu.clearColumn")},disabled:function(){var e=(0,r.getValidSelection)(this);if(!e)return!0;var t=[e[0],0,e[0],this.countCols()-1],o=t.join(",")==e.join(",");return 0>e[1]||this.countCols()>=this.getSettings().maxCols||o}}}t.__esModule=!0,t.KEY=void 0,t.default=n;var r=o(19),i=t.KEY="clear_column"},function(e,t,o){"use strict";function n(){return{key:i,name:"Insert column on the left",callback:function(e,t){this.alter("insert_col",t.start.col,1,"ContextMenu.columnLeft")},disabled:function(){var e=(0,r.getValidSelection)(this);if(!e)return!0;if(!this.isColumnModificationAllowed())return!0;var t=[e[0],0,e[0],this.countCols()-1],o=t.join(",")==e.join(","),n=1===this.countCols();return 0>e[1]||this.countCols()>=this.getSettings().maxCols||!n&&o},hidden:function(){return!this.getSettings().allowInsertColumn}}}t.__esModule=!0,t.KEY=void 0,t.default=n;var r=o(19),i=t.KEY="col_left"},function(e,t,o){"use strict";function n(){return{key:i,name:"Insert column on the right",callback:function(e,t){this.alter("insert_col",t.end.col+1,1,"ContextMenu.columnRight")},disabled:function(){var e=(0,r.getValidSelection)(this);if(!e)return!0;if(!this.isColumnModificationAllowed())return!0;var t=[e[0],0,e[0],this.countCols()-1],o=t.join(",")==e.join(","),n=1===this.countCols();return 0>e[1]||this.countCols()>=this.getSettings().maxCols||!n&&o},hidden:function(){return!this.getSettings().allowInsertColumn}}}t.__esModule=!0,t.KEY=void 0,t.default=n;var r=o(19),i=t.KEY="col_right"},function(e,t,o){"use strict";function n(){return{key:i,name:function(){var e=this,t="Read only";return(0,r.checkSelectionConsistency)(this.getSelectedRange(),function(t,o){return e.getCellMeta(t,o).readOnly})&&(t=(0,r.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),o=(0,r.checkSelectionConsistency)(t,function(t,o){return e.getCellMeta(t,o).readOnly});t.forAll(function(t,n){e.setCellMeta(t,n,"readOnly",!o)}),this.render()},disabled:function(){return!(this.getSelectedRange()&&!this.selection.selectedHeader.corner)}}}t.__esModule=!0,t.KEY=void 0,t.default=n;var r=o(19),i=t.KEY="make_read_only"},function(e,t,o){"use strict";function n(){return{key:r,name:"Redo",callback:function(){this.redo()},disabled:function(){return this.undoRedo&&!this.undoRedo.isRedoAvailable()}}}t.__esModule=!0,t.default=n;var r=t.KEY="redo"},function(e,t,o){"use strict";function n(){return{key:i,name:"Remove column",callback:function(e,t){this.alter("remove_col",t.start.col,t.end.col-t.start.col+1,"ContextMenu.removeColumn")},disabled:function(){var e=(0,r.getValidSelection)(this),t=this.countCols();return!e||this.selection.selectedHeader.rows||this.selection.selectedHeader.corner||!this.isColumnModificationAllowed()||!t},hidden:function(){return!this.getSettings().allowRemoveColumn}}}t.__esModule=!0,t.KEY=void 0,t.default=n;var r=o(19),i=t.KEY="remove_col"},function(e,t,o){"use strict";function n(){return{key:i,name:"Remove row",callback:function(e,t){this.alter("remove_row",t.start.row,t.end.row-t.start.row+1,"ContextMenu.removeRow")},disabled:function(){var e=(0,r.getValidSelection)(this),t=this.countRows();return!e||this.selection.selectedHeader.cols||this.selection.selectedHeader.corner||!t},hidden:function(){return!this.getSettings().allowRemoveRow}}}t.__esModule=!0,t.KEY=void 0,t.default=n;var r=o(19),i=t.KEY="remove_row"},function(e,t,o){"use strict";function n(){return{key:i,name:"Insert row above",callback:function(e,t){this.alter("insert_row",t.start.row,1,"ContextMenu.rowAbove")},disabled:function(){return!(0,r.getValidSelection)(this)||this.selection.selectedHeader.cols||this.countRows()>=this.getSettings().maxRows},hidden:function(){return!this.getSettings().allowInsertRow}}}t.__esModule=!0,t.KEY=void 0,t.default=n;var r=o(19),i=t.KEY="row_above"},function(e,t,o){"use strict";function n(){return{key:i,name:"Insert row below",callback:function(e,t){this.alter("insert_row",t.end.row+1,1,"ContextMenu.rowBelow")},disabled:function(){return!(0,r.getValidSelection)(this)||this.selection.selectedHeader.cols||this.countRows()>=this.getSettings().maxRows},hidden:function(){return!this.getSettings().allowInsertRow}}}t.__esModule=!0,t.KEY=void 0,t.default=n;var r=o(19),i=t.KEY="row_below"},function(e,t,o){"use strict";function n(){return{key:r,name:"Undo",callback:function(){this.undo()},disabled:function(){return this.undoRedo&&!this.undoRedo.isUndoAvailable()}}}t.__esModule=!0,t.default=n;var r=t.KEY="undo"},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var i=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),s=o(82),l=n(s),a=o(0),u=o(2),c=o(274),h=n(c),d=o(4),f=n(d),p=o(1),g=o(35),v=o(19),m=o(18),y=o(87),w=n(y),C=o(88),b=o(10),S=function(){function e(t,o){r(this,e),this.hot=t,this.options=o||{parent:null,name:null,className:"",keepInViewport:!0,standalone:!1},this.eventManager=new f.default(this),this.container=this.createContainer(this.options.name),this.hotMenu=null,this.hotSubMenus={},this.parentMenu=this.options.parent||null,this.menuItems=null,this.origOutsideClickDeselects=null,this.keyEvent=!1,this.offset={above:0,below:0,left:0,right:0},this._afterScrollCallback=null,this.registerEvents()}return i(e,[{key:"registerEvents",value:function(){var e=this;this.eventManager.addEventListener(document.documentElement,"mousedown",function(t){return e.onDocumentMouseDown(t)})}},{key:"setMenuItems",value:function(e){this.menuItems=e}},{key:"setOffset",value:function(e){this.offset[e]=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0}},{key:"isSubMenu",value:function(){return null!==this.parentMenu}},{key:"open",value:function(){var e=this;this.container.removeAttribute("style"),this.container.style.display="block";var t=(0,g.debounce)(function(t){return e.openSubMenu(t)},300),o=(0,u.arrayFilter)(this.menuItems,function(t){return(0,v.isItemHidden)(t,e.hot)});o=(0,v.filterSeparators)(o,C.SEPARATOR);var n={data:o,colHeaders:!1,colWidths:[200],autoRowSize:!1,readOnly:!0,copyPaste:!1,columns:[{data:"name",renderer:function(t,o,n,r,i,s){return e.menuItemRenderer(t,o,n,r,i,s)}}],renderAllRows:!0,fragmentSelection:"cell",disableVisualSelection:"area",beforeKeyDown:function(t){return e.onBeforeKeyDown(t)},afterOnCellMouseOver:function(o,n,r){e.isAllSubMenusClosed()?t(n.row):e.openSubMenu(n.row)},rowHeights:function(e){return o[e].name===C.SEPARATOR?1:23}};this.origOutsideClickDeselects=this.hot.getSettings().outsideClickDeselects,this.hot.getSettings().outsideClickDeselects=!1,this.hotMenu=new l.default(this.container,n),this.hotMenu.addHook("afterInit",function(){return e.onAfterInit()}),this.hotMenu.addHook("afterSelection",function(t,o,n,r,i){return e.onAfterSelection(t,o,n,r,i)}),this.hotMenu.init(),this.hotMenu.listen(),this.blockMainTableCallbacks(),this.runLocalHooks("afterOpen")}},{key:"close",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this.isOpened()&&(e&&this.parentMenu?this.parentMenu.close():(this.closeAllSubMenus(),this.container.style.display="none",this.releaseMainTableCallbacks(),this.hotMenu.destroy(),this.hotMenu=null,this.hot.getSettings().outsideClickDeselects=this.origOutsideClickDeselects,this.runLocalHooks("afterClose"),this.parentMenu&&this.parentMenu.hotMenu.listen()))}},{key:"openSubMenu",value:function(t){if(!this.hotMenu)return!1;var o=this.hotMenu.getCell(t,0);if(this.closeAllSubMenus(),!o||!(0,v.hasSubMenu)(o))return!1;var n=this.hotMenu.getSourceDataAtRow(t),r=new e(this.hot,{parent:this,name:n.name,className:this.options.className,keepInViewport:!0});return r.setMenuItems(n.submenu.items),r.open(),r.setPosition(o.getBoundingClientRect()),this.hotSubMenus[n.key]=r,r}},{key:"closeSubMenu",value:function(e){var t=this.hotMenu.getSourceDataAtRow(e),o=this.hotSubMenus[t.key];o&&(o.destroy(),delete this.hotSubMenus[t.key])}},{key:"closeAllSubMenus",value:function(){var e=this;(0,u.arrayEach)(this.hotMenu.getData(),function(t,o){return e.closeSubMenu(o)})}},{key:"isAllSubMenusClosed",value:function(){return 0===Object.keys(this.hotSubMenus).length}},{key:"destroy",value:function(){this.clearLocalHooks(),this.close(),this.parentMenu=null,this.eventManager.destroy()}},{key:"isOpened",value:function(){return null!==this.hotMenu}},{key:"executeCommand",value:function(e){if(this.isOpened()&&this.hotMenu.getSelected()){var t=this.hotMenu.getSourceDataAtRow(this.hotMenu.getSelected()[0]);if(this.runLocalHooks("select",t,e),!1!==t.isCommand&&t.name!==C.SEPARATOR){var o=this.hot.getSelectedRange(),n=o?(0,v.normalizeSelection)(o):{},r=!0;(!0===t.disabled||"function"==typeof t.disabled&&!0===t.disabled.call(this.hot)||t.submenu)&&(r=!1),this.runLocalHooks("executeCommand",t.key,n,e),this.isSubMenu()&&this.parentMenu.runLocalHooks("executeCommand",t.key,n,e),r&&this.close(!0)}}}},{key:"setPosition",value:function(e){var t=new h.default(e);this.options.keepInViewport?(t.fitsBelow(this.container)?this.setPositionBelowCursor(t):t.fitsAbove(this.container)?this.setPositionAboveCursor(t):this.setPositionBelowCursor(t),t.fitsOnRight(this.container)?this.setPositionOnRightOfCursor(t):this.setPositionOnLeftOfCursor(t)):(this.setPositionBelowCursor(t),this.setPositionOnRightOfCursor(t))}},{key:"setPositionAboveCursor",value:function(e){var t=this.offset.above+e.top-this.container.offsetHeight;this.isSubMenu()&&(t=e.top+e.cellHeight-this.container.offsetHeight+3),this.container.style.top=t+"px"}},{key:"setPositionBelowCursor",value:function(e){var t=this.offset.below+e.top;this.isSubMenu()&&(t=e.top-1),this.container.style.top=t+"px"}},{key:"setPositionOnRightOfCursor",value:function(e){var t=void 0;t=this.isSubMenu()?1+e.left+e.cellWidth:this.offset.right+1+e.left,this.container.style.left=t+"px"}},{key:"setPositionOnLeftOfCursor",value:function(e){this.container.style.left=this.offset.left+e.left-this.container.offsetWidth+(0,a.getScrollbarWidth)()+4+"px"}},{key:"selectFirstCell",value:function(){var e=this.hotMenu.getCell(0,0);(0,v.isSeparator)(e)||(0,v.isDisabled)(e)||(0,v.isSelectionDisabled)(e)?this.selectNextCell(0,0):this.hotMenu.selectCell(0,0)}},{key:"selectLastCell",value:function(){var e=this.hotMenu.countRows()-1,t=this.hotMenu.getCell(e,0);(0,v.isSeparator)(t)||(0,v.isDisabled)(t)||(0,v.isSelectionDisabled)(t)?this.selectPrevCell(e,0):this.hotMenu.selectCell(e,0)}},{key:"selectNextCell",value:function(e,t){var o=e+1,n=o<this.hotMenu.countRows()?this.hotMenu.getCell(o,t):null;n&&((0,v.isSeparator)(n)||(0,v.isDisabled)(n)||(0,v.isSelectionDisabled)(n)?this.selectNextCell(o,t):this.hotMenu.selectCell(o,t))}},{key:"selectPrevCell",value:function(e,t){var o=e-1,n=0>o?null:this.hotMenu.getCell(o,t);n&&((0,v.isSeparator)(n)||(0,v.isDisabled)(n)||(0,v.isSelectionDisabled)(n)?this.selectPrevCell(o,t):this.hotMenu.selectCell(o,t))}},{key:"menuItemRenderer",value:function(e,t,o,n,r,i){var s=this,l=e.getSourceDataAtRow(o),u=document.createElement("div"),c=function(e){return e.disableSelection};"function"==typeof i&&(i=i.call(this.hot)),(0,a.empty)(t),(0,a.addClass)(u,"htItemWrapper"),t.appendChild(u),!function(e){return RegExp(C.SEPARATOR,"i").test(e.name)}(l)?"function"==typeof l.renderer?((0,a.addClass)(t,"htCustomMenuRenderer"),t.appendChild(l.renderer(e,u,o,n,r,i))):(0,a.fastInnerHTML)(u,i):(0,a.addClass)(t,"htSeparator"),!function(e){return!0===e.disabled||"function"==typeof e.disabled&&!0===e.disabled.call(s.hot)}(l)?c(l)?((0,a.addClass)(t,"htSelectionDisabled"),this.eventManager.addEventListener(t,"mouseenter",function(){return e.deselectCell()})):!function(e){return(0,p.hasOwnProperty)(e,"submenu")}(l)?((0,a.removeClass)(t,"htSubmenu"),(0,a.removeClass)(t,"htDisabled"),c(l)?this.eventManager.addEventListener(t,"mouseenter",function(){return e.deselectCell()}):this.eventManager.addEventListener(t,"mouseenter",function(){return e.selectCell(o,n,void 0,void 0,!1,!1)})):((0,a.addClass)(t,"htSubmenu"),c(l)?this.eventManager.addEventListener(t,"mouseenter",function(){return e.deselectCell()}):this.eventManager.addEventListener(t,"mouseenter",function(){return e.selectCell(o,n,void 0,void 0,!1,!1)})):((0,a.addClass)(t,"htDisabled"),this.eventManager.addEventListener(t,"mouseenter",function(){return e.deselectCell()}))}},{key:"createContainer",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;e&&(e=e.replace(/[^A-z0-9]/g,"_"),e=this.options.className+"Sub_"+e);var t=void 0;return t=e?document.querySelector("."+this.options.className+"."+e):document.querySelector("."+this.options.className),t||(t=document.createElement("div"),(0,a.addClass)(t,"htMenu "+this.options.className),e&&(0,a.addClass)(t,e),document.getElementsByTagName("body")[0].appendChild(t)),t}},{key:"blockMainTableCallbacks",value:function(){this._afterScrollCallback=function(){},this.hot.addHook("afterScrollVertically",this._afterScrollCallback),this.hot.addHook("afterScrollHorizontally",this._afterScrollCallback)}},{key:"releaseMainTableCallbacks",value:function(){this._afterScrollCallback&&(this.hot.removeHook("afterScrollVertically",this._afterScrollCallback),this.hot.removeHook("afterScrollHorizontally",this._afterScrollCallback),this._afterScrollCallback=null)}},{key:"onBeforeKeyDown",value:function(e){var t=this.hotMenu.getSelected(),o=!1;switch(this.keyEvent=!0,e.keyCode){case m.KEY_CODES.ESCAPE:this.close(),o=!0;break;case m.KEY_CODES.ENTER:t&&(this.hotMenu.getSourceDataAtRow(t[0]).submenu?o=!0:(this.executeCommand(e),this.close(!0)));break;case m.KEY_CODES.ARROW_DOWN:t?this.selectNextCell(t[0],t[1]):this.selectFirstCell(),o=!0;break;case m.KEY_CODES.ARROW_UP:t?this.selectPrevCell(t[0],t[1]):this.selectLastCell(),o=!0;break;case m.KEY_CODES.ARROW_RIGHT:if(t){var n=this.openSubMenu(t[0]);n&&n.selectFirstCell()}o=!0;break;case m.KEY_CODES.ARROW_LEFT:t&&this.isSubMenu()&&(this.close(),this.parentMenu&&this.parentMenu.hotMenu.listen(),o=!0)}o&&(e.preventDefault(),(0,b.stopImmediatePropagation)(e)),this.keyEvent=!1}},{key:"onAfterInit",value:function(){var e=this.hotMenu.getSettings().data,t=this.hotMenu.view.wt.wtTable.hider.style,o=this.hotMenu.view.wt.wtTable.holder.style,n=parseInt(t.width,10),r=(0,u.arrayReduce)(e,function(e,t){return e+(t.name===C.SEPARATOR?1:26)},0);o.width=n+22+"px",o.height=r+4+"px",t.height=o.height}},{key:"onAfterSelection",value:function(e,t,o,n,r){!1===this.keyEvent&&(r.value=!0)}},{key:"onDocumentMouseDown",value:function(e){this.isOpened()&&(this.container&&(0,a.isChildOf)(e.target,this.container)&&this.executeCommand(e),this.options.standalone&&this.hotMenu&&!(0,a.isChildOf)(e.target,this.hotMenu.rootElement)?this.close(!0):(this.isAllSubMenusClosed()||this.isSubMenu())&&!(0,a.isChildOf)(e.target,".htMenu")&&(0,a.isChildOf)(e.target,document)&&this.close(!0))}}]),e}();(0,p.mixin)(S,w.default),t.default=S},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=o(0),s=o(10);t.default=function(){function e(t){n(this,e);var o=(0,i.getWindowScrollTop)(),r=(0,i.getWindowScrollLeft)(),l=void 0,a=void 0,u=void 0,c=void 0,h=void 0,d=void 0;this.type=this.getSourceType(t),"literal"===this.type?(l=parseInt(t.top,10),u=parseInt(t.left,10),h=t.height||0,d=t.width||0,a=l,c=u,l+=o,u+=r):"event"===this.type&&(l=parseInt((0,s.pageY)(t),10),u=parseInt((0,s.pageX)(t),10),h=t.target.clientHeight,d=t.target.clientWidth,a=l-o,c=u-r),this.top=l,this.topRelative=a,this.left=u,this.leftRelative=c,this.scrollTop=o,this.scrollLeft=r,this.cellHeight=h,this.cellWidth=d}return r(e,[{key:"getSourceType",value:function(e){var t="literal";return e instanceof Event&&(t="event"),t}},{key:"fitsAbove",value:function(e){return this.topRelative>=e.offsetHeight}},{key:"fitsBelow",value:function(e){return(arguments.length>1&&void 0!==arguments[1]?arguments[1]:window.innerHeight)>=this.topRelative+e.offsetHeight}},{key:"fitsOnRight",value:function(e){return(arguments.length>1&&void 0!==arguments[1]?arguments[1]:window.innerWidth)>=this.leftRelative+this.cellWidth+e.offsetWidth}},{key:"fitsOnLeft",value:function(e){return this.leftRelative>=e.offsetWidth}}]),e}()},function(e,t){},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var l="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},a=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),u=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},c=o(13),h=n(c),d=o(7),f=n(d),p=o(171),g=n(p),v=o(12),m=o(0),y=o(2),w=o(6),C=o(5),b=o(277),S=n(b),E=o(278),R=n(E),O=o(279),k=n(O),T=o(4),_=n(T),M=o(280),H=n(M);o(282),f.default.getSingleton().register("afterCopyLimit"),f.default.getSingleton().register("modifyCopyableRange"),f.default.getSingleton().register("beforeCut"),f.default.getSingleton().register("afterCut"),f.default.getSingleton().register("beforePaste"),f.default.getSingleton().register("afterPaste"),f.default.getSingleton().register("beforeCopy"),f.default.getSingleton().register("afterCopy");var A=1e3,P=1e3,x=new WeakMap,D=function(e){function t(e){r(this,t);var o=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.eventManager=new _.default(o),o.columnsLimit=P,o.copyableRanges=[],o.pasteMode="overwrite",o.rowsLimit=A,o.textarea=void 0,x.set(o,{isTriggeredByCopy:!1,isTriggeredByCut:!1,isBeginEditing:!1,isFragmentSelectionEnabled:!1}),o}return s(t,e),a(t,[{key:"isEnabled",value:function(){return!!this.hot.getSettings().copyPaste}},{key:"enablePlugin",value:function(){var e=this;if(!this.enabled){var o=this.hot.getSettings(),n=x.get(this);this.textarea=S.default.getSingleton(),n.isFragmentSelectionEnabled=o.fragmentSelection,"object"===l(o.copyPaste)&&(this.pasteMode=o.copyPaste.pasteMode||this.pasteMode,this.rowsLimit=o.copyPaste.rowsLimit||this.rowsLimit,this.columnsLimit=o.copyPaste.columnsLimit||this.columnsLimit),this.addHook("afterContextMenuDefaultOptions",function(t){return e.onAfterContextMenuDefaultOptions(t)}),this.addHook("afterSelectionEnd",function(){return e.onAfterSelectionEnd()}),this.registerEvents(),u(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this)}}},{key:"updatePlugin",value:function(){this.disablePlugin(),this.enablePlugin(),u(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"updatePlugin",this).call(this)}},{key:"disablePlugin",value:function(){this.textarea&&this.textarea.destroy(),u(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"setCopyableText",value:function(){var e=this.hot.getSelectedRange();if(e){var t=e.getTopLeftCorner(),o=e.getBottomRightCorner(),n=t.row,r=t.col,i=o.row,s=o.col,l=Math.min(i,n+this.rowsLimit-1),a=Math.min(s,r+this.columnsLimit-1);this.copyableRanges.length=0,this.copyableRanges.push({startRow:n,startCol:r,endRow:l,endCol:a}),this.copyableRanges=this.hot.runHooks("modifyCopyableRange",this.copyableRanges),i===l&&s===a||this.hot.runHooks("afterCopyLimit",i-n+1,s-r+1,this.rowsLimit,this.columnsLimit)}}},{key:"getRangedCopyableData",value:function(e){var t=this,o=[],n=[],r=[];return(0,y.arrayEach)(e,function(e){(0,w.rangeEach)(e.startRow,e.endRow,function(e){-1===n.indexOf(e)&&n.push(e)}),(0,w.rangeEach)(e.startCol,e.endCol,function(e){-1===r.indexOf(e)&&r.push(e)})}),(0,y.arrayEach)(n,function(e){var n=[];(0,y.arrayEach)(r,function(o){n.push(t.hot.getCopyableData(e,o))}),o.push(n)}),g.default.stringify(o)}},{key:"getRangedData",value:function(e){var t=this,o=[],n=[],r=[];return(0,y.arrayEach)(e,function(e){(0,w.rangeEach)(e.startRow,e.endRow,function(e){-1===n.indexOf(e)&&n.push(e)}),(0,w.rangeEach)(e.startCol,e.endCol,function(e){-1===r.indexOf(e)&&r.push(e)})}),(0,y.arrayEach)(n,function(e){var n=[];(0,y.arrayEach)(r,function(o){n.push(t.hot.getCopyableData(e,o))}),o.push(n)}),o}},{key:"copy",value:function(){x.get(this).isTriggeredByCopy=!0,this.textarea.select(),document.execCommand("copy")}},{key:"cut",value:function(){x.get(this).isTriggeredByCut=!0,this.textarea.select(),document.execCommand("cut")}},{key:"paste",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=new H.default;t.clipboardData.setData("text/plain",e),this.onPaste(t)}},{key:"registerEvents",value:function(){var e=this;this.eventManager.addEventListener(this.textarea.element,"paste",function(t){return e.onPaste(t)}),this.eventManager.addEventListener(this.textarea.element,"cut",function(t){return e.onCut(t)}),this.eventManager.addEventListener(this.textarea.element,"copy",function(t){return e.onCopy(t)})}},{key:"onCopy",value:function(e){var t=x.get(this);if(this.hot.isListening()||t.isTriggeredByCopy){this.setCopyableText(),t.isTriggeredByCopy=!1;var o=this.getRangedData(this.copyableRanges),n=!!this.hot.runHooks("beforeCopy",o,this.copyableRanges),r="";n&&(r=g.default.stringify(o),e&&e.clipboardData?e.clipboardData.setData("text/plain",r):"undefined"==typeof ClipboardEvent&&window.clipboardData.setData("Text",r),this.hot.runHooks("afterCopy",o,this.copyableRanges)),e.preventDefault()}}},{key:"onCut",value:function(e){var t=x.get(this);if(this.hot.isListening()||t.isTriggeredByCut){this.setCopyableText(),t.isTriggeredByCut=!1;var o=this.getRangedData(this.copyableRanges),n=!!this.hot.runHooks("beforeCut",o,this.copyableRanges),r=void 0;n&&(r=g.default.stringify(o),e&&e.clipboardData?e.clipboardData.setData("text/plain",r):"undefined"==typeof ClipboardEvent&&window.clipboardData.setData("Text",r),this.hot.selection.empty(),this.hot.runHooks("afterCut",o,this.copyableRanges)),e.preventDefault()}}},{key:"onPaste",value:function(e){var t=this;if(this.hot.isListening()){e&&e.preventDefault&&e.preventDefault();var o=void 0;if(e&&void 0!==e.clipboardData?this.textarea.setValue(e.clipboardData.getData("text/plain")):"undefined"==typeof ClipboardEvent&&void 0!==window.clipboardData&&this.textarea.setValue(window.clipboardData.getData("Text")),o=g.default.parse(this.textarea.getValue()),this.textarea.setValue(" "),0!==o.length){if(!!this.hot.runHooks("beforePaste",o,this.copyableRanges)){var n=this.hot.getSelected(),r=new v.CellCoords(n[0],n[1]),i=new v.CellCoords(n[2],n[3]),s=new v.CellRange(r,r,i),l=s.getTopLeftCorner(),a=s.getBottomRightCorner(),u=l,c=new v.CellCoords(Math.max(a.row,o.length-1+l.row),Math.max(a.col,o[0].length-1+l.col)),h=i.row-r.row>=o.length-1,d=i.col-r.col>=o[0].length-1;this.hot.addHookOnce("afterChange",function(e){var o=e?e.length:0;if(o){var n={row:0,col:0},r=-1;(0,y.arrayEach)(e,function(t,i){var s=o>i+1?e[i+1]:null;s&&(h||(n.row+=Math.max(s[0]-t[0]-1,0)),!d&&t[1]>r&&(r=t[1],n.col+=Math.max(s[1]-t[1]-1,0)))}),t.hot.selectCell(u.row,u.col,c.row+n.row,c.col+n.col)}}),this.hot.populateFromArray(u.row,u.col,o,c.row,c.col,"CopyPaste.paste",this.pasteMode),this.hot.runHooks("afterPaste",o,this.copyableRanges)}}}}},{key:"onAfterContextMenuDefaultOptions",value:function(e){e.items.push({name:"---------"},(0,R.default)(this),(0,k.default)(this))}},{key:"onAfterSelectionEnd",value:function(){var e=x.get(this),t=this.hot.getActiveEditor();t&&void 0!==t.isOpened&&t.isOpened()||e.isFragmentSelectionEnabled&&!this.textarea.isActive()&&(0,m.getSelectionText)()||(this.setCopyableText(),this.textarea.select())}},{key:"destroy",value:function(){this.textarea&&this.textarea.destroy(),u(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}}]),t}(h.default);(0,C.registerPlugin)("CopyPaste",D),t.default=D},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=function(){function e(){n(this,e),this.element=void 0,this.isAppended=!1,this.refCounter=0}return r(e,null,[{key:"getSingleton",value:function(){return s.append(),s}}]),r(e,[{key:"append",value:function(){this.hasBeenDestroyed()&&this.create(),this.refCounter++,!this.isAppended&&document.body&&document.body&&(this.isAppended=!0,document.body.appendChild(this.element))}},{key:"create",value:function(){this.element=document.createElement("textarea"),this.element.id="HandsontableCopyPaste",this.element.className="copyPaste",this.element.tabIndex=-1,this.element.autocomplete="off",this.element.wrap="hard",this.element.value=" "}},{key:"deselect",value:function(){this.element===document.activeElement&&document.activeElement.blur()}},{key:"destroy",value:function(){this.refCounter--,this.refCounter=0>this.refCounter?0:this.refCounter,this.hasBeenDestroyed()&&this.element&&this.element.parentNode&&(this.element.parentNode.removeChild(this.element),this.element=null,this.isAppended=!1)}},{key:"getValue",value:function(){return this.element.value}},{key:"hasBeenDestroyed",value:function(){return 1>this.refCounter}},{key:"isActive",value:function(){return this.element===document.activeElement}},{key:"select",value:function(){this.element.focus(),this.element.select()}},{key:"setValue",value:function(e){this.element.value=e}}]),e}(),s=new i;t.default=i},function(e,t,o){"use strict";function n(e){return{key:"copy",name:"Copy",callback:function(){e.copy()},disabled:function(){return!e.hot.getSelected()},hidden:!1}}t.__esModule=!0,t.default=n},function(e,t,o){"use strict";function n(e){return{key:"cut",name:"Cut",callback:function(){e.cut()},disabled:function(){return!e.hot.getSelected()},hidden:!1}}t.__esModule=!0,t.default=n},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=o(281),i=function(e){return e&&e.__esModule?e:{default:e}}(r);t.default=function e(){n(this,e),this.clipboardData=new i.default}},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}();t.default=function(){function e(){n(this,e),this.data={}}return r(e,[{key:"setData",value:function(e,t){this.data[e]=t}},{key:"getData",value:function(e){return this.data[e]||void 0}}]),e}()},function(e,t){},function(e,t,o){"use strict";function n(){}var r,i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},s=o(7),l=function(e){return e&&e.__esModule?e:{default:e}}(s),a=(o(5),o(1)),u=o(12),c=function(e){return"boolean"==typeof e&&!0===e||"object"===(void 0===e?"undefined":i(e))&&e.length>0},h=function(){c(this.getSettings().customBorders)&&(this.customBorders||(r=this,this.customBorders=new n))},d=function(e){for(var t=0;r.view.wt.selections.length>t;t++)if(r.view.wt.selections[t].settings.className==e)return t;return-1},f=function(e){var t={row:e.row,col:e.col},o=new u.Selection(e,new u.CellRange(t,t,t)),n=d(e.className);0>n?r.view.wt.selections.push(o):r.view.wt.selections[n]=o},p=function(e,t,o){var n=C(e,t);n=b(n,o),this.setCellMeta(e,t,"borders",n),f(n)},g=function(e){for(var t=e.range,o=t.from.row;t.to.row>=o;o++)for(var n=t.from.col;t.to.col>=n;n++){var r=C(o,n),i=0;o==t.from.row&&(i++,(0,a.hasOwnProperty)(e,"top")&&(r.top=e.top)),o==t.to.row&&(i++,(0,a.hasOwnProperty)(e,"bottom")&&(r.bottom=e.bottom)),n==t.from.col&&(i++,(0,a.hasOwnProperty)(e,"left")&&(r.left=e.left)),n==t.to.col&&(i++,(0,a.hasOwnProperty)(e,"right")&&(r.right=e.right)),i>0&&(this.setCellMeta(o,n,"borders",r),f(r))}},v=function(e,t){return"border_row"+e+"col"+t},m=function(){return{width:1,color:"#000"}},y=function(){return{hide:!0}},w=function(){return{width:1,color:"#000",cornerVisible:!1}},C=function(e,t){return{className:v(e,t),border:w(),row:e,col:t,top:y(),right:y(),bottom:y(),left:y()}},b=function(e,t){return(0,a.hasOwnProperty)(t,"border")&&(e.border=t.border),(0,a.hasOwnProperty)(t,"top")&&(e.top=t.top),(0,a.hasOwnProperty)(t,"right")&&(e.right=t.right),(0,a.hasOwnProperty)(t,"bottom")&&(e.bottom=t.bottom),(0,a.hasOwnProperty)(t,"left")&&(e.left=t.left),e},S=function(e){for(var t=document.querySelectorAll("."+e),o=0;t.length>o;o++)if(t[o]&&"TD"!=t[o].nodeName){var n=t[o].parentNode;n.parentNode&&n.parentNode.removeChild(n)}},E=function(e,t){var o=v(e,t);S(o),this.removeCellMeta(e,t,"borders")},R=function(e,t,o,n){var r=this.getCellMeta(e,t).borders;r&&void 0!=r.border||(r=C(e,t)),r[o]=n?y():m(),this.setCellMeta(e,t,"borders",r);var i=v(e,t);S(i),f(r),this.render()},O=function(e,t,o){if(e.from.row==e.to.row&&e.from.col==e.to.col)"noBorders"==t?E.call(this,e.from.row,e.from.col):R.call(this,e.from.row,e.from.col,t,o);else switch(t){case"noBorders":for(var n=e.from.col;e.to.col>=n;n++)for(var r=e.from.row;e.to.row>=r;r++)E.call(this,r,n);break;case"top":for(var i=e.from.col;e.to.col>=i;i++)R.call(this,e.from.row,i,t,o);break;case"right":for(var s=e.from.row;e.to.row>=s;s++)R.call(this,s,e.to.col,t);break;case"bottom":for(var l=e.from.col;e.to.col>=l;l++)R.call(this,e.to.row,l,t);break;case"left":for(var a=e.from.row;e.to.row>=a;a++)R.call(this,a,e.from.col,t)}},k=function(e,t){var o=!1;return e.getSelectedRange().forAll(function(n,r){var i=e.getCellMeta(n,r).borders;if(i){if(!t)return o=!0,!1;if(!(0,a.hasOwnProperty)(i[t],"hide"))return o=!0,!1}}),o},T=function(e){return'<span class="selected">'+String.fromCharCode(10003)+"</span>"+e},_=function(e){this.getSettings().customBorders&&(e.items.push({name:"---------"}),e.items.push({key:"borders",name:"Borders",disabled:function(){return this.selection.selectedHeader.corner},submenu:{items:[{key:"borders:top",name:function(){var e="Top";return k(this,"top")&&(e=T(e)),e},callback:function(){var e=k(this,"top");O.call(this,this.getSelectedRange(),"top",e)}},{key:"borders:right",name:function(){var e="Right";return k(this,"right")&&(e=T(e)),e},callback:function(){var e=k(this,"right");O.call(this,this.getSelectedRange(),"right",e)}},{key:"borders:bottom",name:function(){var e="Bottom";return k(this,"bottom")&&(e=T(e)),e},callback:function(){var e=k(this,"bottom");O.call(this,this.getSelectedRange(),"bottom",e)}},{key:"borders:left",name:function(){var e="Left";return k(this,"left")&&(e=T(e)),e},callback:function(){var e=k(this,"left");O.call(this,this.getSelectedRange(),"left",e)}},{key:"borders:no_borders",name:"Remove border(s)",callback:function(){O.call(this,this.getSelectedRange(),"noBorders")},disabled:function(){return!k(this)}}]}}))};l.default.getSingleton().add("beforeInit",h),l.default.getSingleton().add("afterContextMenuDefaultOptions",_),l.default.getSingleton().add("afterInit",function(){var e=this.getSettings().customBorders;if(e){for(var t=0;e.length>t;t++)e[t].range?g.call(this,e[t]):p.call(this,e[t].row,e[t].col,e[t]);this.render(),this.view.wt.draw(!0)}})},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(){this.boundaries=null,this.callback=null}t.__esModule=!0;var i=o(7),s=n(i),l=o(4),a=n(l);o(5);r.prototype.setBoundaries=function(e){this.boundaries=e},r.prototype.setCallback=function(e){this.callback=e},r.prototype.check=function(e,t){var o=0,n=0;this.boundaries.top>t?n=t-this.boundaries.top:t>this.boundaries.bottom&&(n=t-this.boundaries.bottom),this.boundaries.left>e?o=e-this.boundaries.left:e>this.boundaries.right&&(o=e-this.boundaries.right),this.callback(o,n)};var u,c=function(e){e.dragToScrollListening=!1;var t=e.view.wt.wtTable.holder;u=new r,t!==window&&(u.setBoundaries(t.getBoundingClientRect()),u.setCallback(function(e,o){0>e?t.scrollLeft-=50:e>0&&(t.scrollLeft+=50),0>o?t.scrollTop-=20:o>0&&(t.scrollTop+=20)}),e.dragToScrollListening=!0)};s.default.getSingleton().add("afterInit",function(){var e=this,t=new a.default(this);t.addEventListener(document,"mouseup",function(){e.dragToScrollListening=!1}),t.addEventListener(document,"mousemove",function(t){e.dragToScrollListening&&u.check(t.clientX,t.clientY)})}),s.default.getSingleton().add("afterDestroy",function(){new a.default(this).clear()}),s.default.getSingleton().add("afterOnCellMouseDown",function(){c(this)}),s.default.getSingleton().add("afterOnCellCornerMouseDown",function(){c(this)}),t.default=r},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var l=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),a=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},u=o(13),c=n(u),h=o(5),d=o(2),f=o(286),p=n(f),g=o(287),v=n(g);o(288);var m=new WeakMap,y=function(e){function t(e){r(this,t);var o=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return m.set(o,{moveByFreeze:!1,afterFirstUse:!1}),o.frozenColumnsBasePositions=[],o.manualColumnMovePlugin=void 0,o}return s(t,e),l(t,[{key:"isEnabled",value:function(){return!!this.hot.getSettings().manualColumnFreeze}},{key:"enablePlugin",value:function(){var e=this;this.enabled||(this.addHook("afterContextMenuDefaultOptions",function(t){return e.addContextMenuEntry(t)}),this.addHook("afterInit",function(){return e.onAfterInit()}),this.addHook("beforeColumnMove",function(t,o){return e.onBeforeColumnMove(t,o)}),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{key:"disablePlugin",value:function(){var e=m.get(this);e.afterFirstUse=!1,e.moveByFreeze=!1,a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"updatePlugin",value:function(){this.disablePlugin(),this.enablePlugin(),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"updatePlugin",this).call(this)}},{key:"freezeColumn",value:function(e){var t=m.get(this),o=this.hot.getSettings();t.afterFirstUse||(t.afterFirstUse=!0),o.fixedColumnsLeft!==this.hot.countCols()&&e>o.fixedColumnsLeft-1&&(t.moveByFreeze=!0,e!==this.getMovePlugin().columnsMapper.getValueByIndex(e)&&(this.frozenColumnsBasePositions[o.fixedColumnsLeft]=e),this.getMovePlugin().moveColumn(e,o.fixedColumnsLeft++))}},{key:"unfreezeColumn",value:function(e){var t=m.get(this),o=this.hot.getSettings();if(t.afterFirstUse||(t.afterFirstUse=!0),o.fixedColumnsLeft>0&&o.fixedColumnsLeft-1>=e){var n=this.getBestColumnReturnPosition(e);t.moveByFreeze=!0,o.fixedColumnsLeft--,this.getMovePlugin().moveColumn(e,n+1)}}},{key:"getMovePlugin",value:function(){return this.manualColumnMovePlugin||(this.manualColumnMovePlugin=this.hot.getPlugin("manualColumnMove")),this.manualColumnMovePlugin}},{key:"getBestColumnReturnPosition",value:function(e){var t=this.getMovePlugin(),o=this.hot.getSettings(),n=o.fixedColumnsLeft,r=t.columnsMapper.getValueByIndex(n),i=void 0;if(null==this.frozenColumnsBasePositions[e])for(i=t.columnsMapper.getValueByIndex(e);i>r;)n++,r=t.columnsMapper.getValueByIndex(n);else{for(i=this.frozenColumnsBasePositions[e],this.frozenColumnsBasePositions[e]=void 0;i>=r;)n++,r=t.columnsMapper.getValueByIndex(n);n=r}return n-1}},{key:"addContextMenuEntry",value:function(e){e.items.push({name:"---------"},(0,p.default)(this),(0,v.default)(this))}},{key:"onAfterInit",value:function(){this.getMovePlugin().isEnabled()||this.getMovePlugin().enablePlugin()}},{key:"onBeforeColumnMove",value:function(e,t){var o=m.get(this);if(o.afterFirstUse&&!o.moveByFreeze){var n=this.hot.getSettings().fixedColumnsLeft,r=n>t;if(r||(0,d.arrayEach)(e,function(e,t,o){if(n>e)return r=!0,!1}),r)return!1}o.moveByFreeze&&(o.moveByFreeze=!1)}},{key:"destroy",value:function(){a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}}]),t}(c.default);(0,h.registerPlugin)("manualColumnFreeze",y),t.default=y},function(e,t,o){"use strict";function n(e){return{key:"freeze_column",name:"Freeze this column",callback:function(){var t=this.getSelectedRange().from.col;e.freezeColumn(t),this.render(),this.view.wt.wtOverlays.adjustElementsSize(!0)},hidden:function(){var e=this.getSelectedRange(),t=!1;return void 0===e?t=!0:e.from.col===e.to.col&&e.from.col>this.getSettings().fixedColumnsLeft-1||(t=!0),t}}}t.__esModule=!0,t.default=n},function(e,t,o){"use strict";function n(e){return{key:"unfreeze_column",name:"Unfreeze this column",callback:function(){var t=this.getSelectedRange().from.col;e.unfreezeColumn(t),this.render(),this.view.wt.wtOverlays.adjustElementsSize(!0)},hidden:function(){var e=this.getSelectedRange(),t=!1;return void 0===e?t=!0:e.from.col===e.to.col&&e.from.col<this.getSettings().fixedColumnsLeft||(t=!0),t}}}t.__esModule=!0,t.default=n},function(e,t){},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var l=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),a=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},u=o(13),c=n(u),h=o(7),d=n(h),f=o(2),p=o(0),g=o(6),v=o(4),m=n(v),y=o(5),w=o(290),C=n(w),b=o(291),S=n(b),E=o(292),R=n(E),O=o(12);o(293),d.default.getSingleton().register("beforeColumnMove"),d.default.getSingleton().register("afterColumnMove"),d.default.getSingleton().register("unmodifyCol");var k=new WeakMap,T=function(e){function t(e){r(this,t);var o=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return k.set(o,{columnsToMove:[],countCols:0,fixedColumns:0,pressed:void 0,disallowMoving:void 0,target:{eventPageX:void 0,coords:void 0,TD:void 0,col:void 0}}),o.removedColumns=[],o.columnsMapper=new C.default(o),o.eventManager=new m.default(o),o.backlight=new S.default(e),o.guideline=new R.default(e),o}return s(t,e),l(t,[{key:"isEnabled",value:function(){return!!this.hot.getSettings().manualColumnMove}},{key:"enablePlugin",value:function(){var e=this;this.enabled||(this.addHook("beforeOnCellMouseDown",function(t,o,n,r){return e.onBeforeOnCellMouseDown(t,o,n,r)}),this.addHook("beforeOnCellMouseOver",function(t,o,n,r){return e.onBeforeOnCellMouseOver(t,o,n,r)}),this.addHook("afterScrollVertically",function(){return e.onAfterScrollVertically()}),this.addHook("modifyCol",function(t,o){return e.onModifyCol(t,o)}),this.addHook("beforeRemoveCol",function(t,o){return e.onBeforeRemoveCol(t,o)}),this.addHook("afterRemoveCol",function(){return e.onAfterRemoveCol()}),this.addHook("afterCreateCol",function(t,o){return e.onAfterCreateCol(t,o)}),this.addHook("afterLoadData",function(){return e.onAfterLoadData()}),this.addHook("unmodifyCol",function(t){return e.onUnmodifyCol(t)}),this.registerEvents(),(0,p.addClass)(this.hot.rootElement,"ht__manualColumnMove"),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{key:"updatePlugin",value:function(){this.disablePlugin(),this.enablePlugin(),this.onAfterPluginsInitialized(),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"updatePlugin",this).call(this)}},{key:"disablePlugin",value:function(){var e=this.hot.getSettings().manualColumnMove;Array.isArray(e)&&this.columnsMapper.clearMap(),(0,p.removeClass)(this.hot.rootElement,"ht__manualColumnMove"),this.unregisterEvents(),this.backlight.destroy(),this.guideline.destroy(),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"moveColumn",value:function(e,t){this.moveColumns([e],t)}},{key:"moveColumns",value:function(e,t){var o=this,n=k.get(this),r=this.hot.runHooks("beforeColumnMove",e,t);n.disallowMoving=!r,!1!==r&&((0,f.arrayEach)(e,function(e,t,n){n[t]=o.columnsMapper.getValueByIndex(e)}),(0,f.arrayEach)(e,function(e,n){var r=o.columnsMapper.getIndexByValue(e);r!==t&&o.columnsMapper.moveColumn(r,t+n)}),this.columnsMapper.clearNull()),this.hot.runHooks("afterColumnMove",e,t)}},{key:"changeSelection",value:function(e,t){var o=this.hot.selection,n=this.hot.countRows()-1;o.setRangeStartOnly(new O.CellCoords(0,e)),o.setRangeEnd(new O.CellCoords(n,t),!1)}},{key:"getColumnsWidth",value:function(e,t){for(var o=0,n=e;t>n;n++){var r=0;r=0>n?this.hot.view.wt.wtViewport.getRowHeaderWidth()||0:this.hot.view.wt.wtTable.getStretchedColumnWidth(n)||0,o+=r}return o}},{key:"initialSettings",value:function(){var e=this.hot.getSettings().manualColumnMove;Array.isArray(e)?this.moveColumns(e,0):void 0!==e&&this.persistentStateLoad()}},{key:"isFixedColumnsLeft",value:function(e){return e<this.hot.getSettings().fixedColumnsLeft}},{key:"persistentStateSave",value:function(){this.hot.runHooks("persistentStateSave","manualColumnMove",this.columnsMapper._arrayMap)}},{key:"persistentStateLoad",value:function(){var e={};this.hot.runHooks("persistentStateLoad","manualColumnMove",e),e.value&&(this.columnsMapper._arrayMap=e.value)}},{key:"prepareColumnsToMoving",value:function(e,t){var o=[];return(0,g.rangeEach)(e,t,function(e){o.push(e)}),o}},{key:"refreshPositions",value:function(){var e=k.get(this),t=this.hot.view.wt.wtTable.getFirstVisibleColumn(),o=this.hot.view.wt.wtTable.getLastVisibleColumn(),n=this.hot.view.wt.wtTable,r=this.hot.view.wt.wtOverlays.scrollableElement,i="number"==typeof r.scrollX?r.scrollX:r.scrollLeft,s=this.hot.view.THEAD.offsetLeft+this.getColumnsWidth(0,e.coordsColumn),l=e.target.eventPageX-(e.rootElementOffset-(void 0===r.scrollX?i:0)),a=n.hider.offsetWidth,u=n.TBODY.offsetLeft,c=this.backlight.getOffset().left,h=this.backlight.getSize().width,d=0;if(e.target.eventPageX>e.rootElementOffset+n.holder.offsetWidth+i&&e.countCols>e.coordsColumn&&e.coordsColumn++,e.hasRowHeaders&&(d=this.hot.view.wt.wtOverlays.leftOverlay.clone.wtTable.getColumnHeader(-1).offsetWidth),this.isFixedColumnsLeft(e.coordsColumn)&&(s+=i),s+=d,0>e.coordsColumn)e.target.col=e.fixedColumns>0?0:t>0?t-1:t;else if(l<e.target.TD.offsetWidth/2+s)(e.target.col=e.coordsColumn)>t||e.fixedColumns>e.target.col||this.hot.scrollViewportTo(void 0,t-1);else{var f=e.countCols>e.coordsColumn?e.coordsColumn:e.countCols-1;e.target.col=f+1,s+=e.target.TD.offsetWidth,e.target.col>o&&this.hot.scrollViewportTo(void 0,o+1,void 0,!0)}e.target.col>t||e.fixedColumns>e.target.col||this.hot.scrollViewportTo(void 0,t-1);var p=l,g=s;a>l+h+c?u+d>l+c&&(p=u+d+Math.abs(c)):p=a-h-c,a-1>s?0===g?g=1:void 0!==r.scrollX&&e.fixedColumns>e.coordsColumn&&(g-=e.rootElementOffset>r.scrollX?0:e.rootElementOffset):g=a-1,this.backlight.setPosition(null,p),this.guideline.setPosition(null,g)}},{key:"updateColumnsMapper",value:function(){var e=this.hot.countSourceCols(),t=this.columnsMapper._arrayMap.length;if(0===t)this.columnsMapper.createMap(e||this.hot.getSettings().startCols);else if(e>t){var o=e-t;this.columnsMapper.insertItems(t,o)}else if(t>e){var n=e-1,r=[];(0,f.arrayEach)(this.columnsMapper._arrayMap,function(e,t){e>n&&r.push(t)}),this.columnsMapper.removeItems(r)}}},{key:"registerEvents",value:function(){var e=this;this.eventManager.addEventListener(document.documentElement,"mousemove",function(t){return e.onMouseMove(t)}),this.eventManager.addEventListener(document.documentElement,"mouseup",function(){return e.onMouseUp()})}},{key:"unregisterEvents",value:function(){this.eventManager.clear()}},{key:"onBeforeOnCellMouseDown",value:function(e,t,o,n){var r=this.hot.view.wt.wtTable,i=this.hot.selection.selectedHeader.cols,s=this.hot.getSelectedRange(),l=k.get(this),a=e.realTarget.className.indexOf("columnSorting")>-1;if(!s||!i||l.pressed||0!==e.button||a)return l.pressed=!1,l.columnsToMove.length=0,void(0,p.removeClass)(this.hot.rootElement,["on-moving--columns","show-ui"]);var u=this.guideline.isBuilt()&&!this.guideline.isAppended(),c=this.backlight.isBuilt()&&!this.backlight.isAppended();u&&c&&(this.guideline.appendTo(r.hider),this.backlight.appendTo(r.hider));var h=s.from,d=s.to,f=Math.min(h.col,d.col),g=Math.max(h.col,d.col);if(0<=t.row||t.col<f||g<t.col)(0,p.removeClass)(this.hot.rootElement,"after-selection--columns"),l.pressed=!1,l.columnsToMove.length=0;else{n.column=!0,l.pressed=!0,l.target.eventPageX=e.pageX,l.coordsColumn=t.col,l.target.TD=o,l.target.col=t.col,l.columnsToMove=this.prepareColumnsToMoving(f,g),l.hasRowHeaders=!!this.hot.getSettings().rowHeaders,l.countCols=this.hot.countCols(),l.fixedColumns=this.hot.getSettings().fixedColumnsLeft,l.rootElementOffset=(0,p.offset)(this.hot.rootElement).left;var v=l.hasRowHeaders?-1:0,m=r.holder.scrollTop+r.getColumnHeaderHeight(0)+1,y=l.fixedColumns>t.col,w=this.hot.view.wt.wtOverlays.scrollableElement,C=w.scrollX?w.scrollX-l.rootElementOffset:0,b=e.layerX-(y?C:0),S=Math.abs(this.getColumnsWidth(f,t.col)+b);this.backlight.setPosition(m,this.getColumnsWidth(v,f)+S),this.backlight.setSize(this.getColumnsWidth(f,g+1),r.hider.offsetHeight-m),this.backlight.setOffset(null,-1*S),(0,p.addClass)(this.hot.rootElement,"on-moving--columns")}}},{key:"onMouseMove",value:function(e){var t=k.get(this);if(t.pressed){if(e.realTarget===this.backlight.element){var o=this.backlight.getSize().width;this.backlight.setSize(0),setTimeout(function(){this.backlight.setPosition(o)})}t.target.eventPageX=e.pageX,this.refreshPositions()}}},{key:"onBeforeOnCellMouseOver",value:function(e,t,o,n){var r=this.hot.getSelectedRange(),i=k.get(this);r&&i.pressed&&(i.columnsToMove.indexOf(t.col)>-1?(0,p.removeClass)(this.hot.rootElement,"show-ui"):(0,p.addClass)(this.hot.rootElement,"show-ui"),n.row=!0,n.column=!0,n.cell=!0,i.coordsColumn=t.col,i.target.TD=o)}},{key:"onMouseUp",value:function(){var e=k.get(this);if(e.coordsColumn=void 0,e.pressed=!1,e.backlightWidth=0,(0,p.removeClass)(this.hot.rootElement,["on-moving--columns","show-ui","after-selection--columns"]),this.hot.selection.selectedHeader.cols&&(0,p.addClass)(this.hot.rootElement,"after-selection--columns"),e.columnsToMove.length>=1&&void 0!==e.target.col&&-1>=e.columnsToMove.indexOf(e.target.col)){if(this.moveColumns(e.columnsToMove,e.target.col),this.persistentStateSave(),this.hot.render(),this.hot.view.wt.wtOverlays.adjustElementsSize(!0),!e.disallowMoving){this.changeSelection(this.columnsMapper.getIndexByValue(e.columnsToMove[0]),this.columnsMapper.getIndexByValue(e.columnsToMove[e.columnsToMove.length-1]))}e.columnsToMove.length=0}}},{key:"onAfterScrollVertically",value:function(){var e=this.hot.view.wt.wtTable,t=e.getColumnHeaderHeight(0)+1,o=e.holder.scrollTop,n=t+o;this.backlight.setPosition(n),this.backlight.setSize(null,e.hider.offsetHeight-n)}},{key:"onAfterCreateCol",value:function(e,t){this.columnsMapper.shiftItems(e,t)}},{key:"onBeforeRemoveCol",value:function(e,t){var o=this;this.removedColumns.length=0,!1!==e&&(0,g.rangeEach)(e,e+t-1,function(e){o.removedColumns.push(o.hot.runHooks("modifyCol",e,o.pluginName))})}},{key:"onAfterRemoveCol",value:function(){this.columnsMapper.unshiftItems(this.removedColumns)}},{key:"onAfterLoadData",value:function(){this.updateColumnsMapper()}},{key:"onModifyCol",value:function(e,t){if(t!==this.pluginName){var o=this.columnsMapper.getValueByIndex(e);e=null===o?e:o}return e}},{key:"onUnmodifyCol",value:function(e){var t=this.columnsMapper.getIndexByValue(e);return null===t?e:t}},{key:"onAfterPluginsInitialized",value:function(){this.updateColumnsMapper(),this.initialSettings(),this.backlight.build(),this.guideline.build()}},{key:"destroy",value:function(){this.backlight.destroy(),this.guideline.destroy(),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}}]),t}(c.default);(0,y.registerPlugin)("ManualColumnMove",T),t.default=T},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=o(176),s=function(e){return e&&e.__esModule?e:{default:e}}(i),l=o(2),a=o(1),u=o(6),c=function(){function e(t){n(this,e),this.manualColumnMove=t}return r(e,[{key:"createMap",value:function(e){var t=this,o=void 0===e?this._arrayMap.length:e;this._arrayMap.length=0,(0,u.rangeEach)(o-1,function(e){t._arrayMap[e]=e})}},{key:"destroy",value:function(){this._arrayMap=null}},{key:"moveColumn",value:function(e,t){var o=this._arrayMap[e];this._arrayMap[e]=null,this._arrayMap.splice(t,0,o)}},{key:"clearNull",value:function(){this._arrayMap=(0,l.arrayFilter)(this._arrayMap,function(e){return null!==e})}}]),e}();(0,a.mixin)(c,s.default),t.default=c},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var s=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),l=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},a=o(177),u=function(e){return e&&e.__esModule?e:{default:e}}(a),c=o(0);t.default=function(e){function t(){return n(this,t),r(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return i(t,e),s(t,[{key:"build",value:function(){l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"build",this).call(this),(0,c.addClass)(this._element,"ht__manualColumnMove--backlight")}}]),t}(u.default)},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var s=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),l=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},a=o(177),u=function(e){return e&&e.__esModule?e:{default:e}}(a),c=o(0);t.default=function(e){function t(){return n(this,t),r(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return i(t,e),s(t,[{key:"build",value:function(){l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"build",this).call(this),(0,c.addClass)(this._element,"ht__manualColumnMove--guideline")}}]),t}(u.default)},function(e,t){},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var l=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),a=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},u=o(13),c=n(u),h=o(0),d=o(4),f=n(d),p=o(10),g=o(2),v=o(6),m=o(5),y=function(e){function t(e){r(this,t);var o=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.currentTH=null,o.currentCol=null,o.selectedCols=[],o.currentWidth=null,o.newSize=null,o.startY=null,o.startWidth=null,o.startOffset=null,o.handle=document.createElement("DIV"),o.guide=document.createElement("DIV"),o.eventManager=new f.default(o),o.pressed=null,o.dblclick=0,o.autoresizeTimeout=null,o.manualColumnWidths=[],(0,h.addClass)(o.handle,"manualColumnResizer"),(0,h.addClass)(o.guide,"manualColumnResizerGuide"),o}return s(t,e),l(t,[{key:"isEnabled",value:function(){return this.hot.getSettings().manualColumnResize}},{key:"enablePlugin",value:function(){var e=this;if(!this.enabled){this.manualColumnWidths=[];var o=this.hot.getSettings().manualColumnResize,n=this.loadManualColumnWidths();this.addHook("modifyColWidth",function(t,o){return e.onModifyColWidth(t,o)}),this.addHook("beforeStretchingColumnWidth",function(t,o){return e.onBeforeStretchingColumnWidth(t,o)}),this.addHook("beforeColumnResize",function(t,o,n){return e.onBeforeColumnResize(t,o,n)}),this.manualColumnWidths=void 0!==n?n:Array.isArray(o)?o:[],this.bindEvents(),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this)}}},{key:"updatePlugin",value:function(){var e=this.hot.getSettings().manualColumnResize;Array.isArray(e)?this.manualColumnWidths=e:e||(this.manualColumnWidths=[])}},{key:"disablePlugin",value:function(){a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"saveManualColumnWidths",value:function(){this.hot.runHooks("persistentStateSave","manualColumnWidths",this.manualColumnWidths)}},{key:"loadManualColumnWidths",value:function(){var e={};return this.hot.runHooks("persistentStateLoad","manualColumnWidths",e),e.value}},{key:"setupHandlePosition",value:function(e){var t=this;if(!e.parentNode)return!1;this.currentTH=e;var o=this.hot.view.wt.wtTable.getCoords(e).col,n=(0,h.outerHeight)(this.currentTH);if(o>=0){var r=this.currentTH.getBoundingClientRect();if(this.currentCol=o,this.selectedCols=[],this.hot.selection.isSelected()&&this.hot.selection.selectedHeader.cols){var i=this.hot.getSelectedRange(),s=i.from,l=i.to,a=s.col,u=l.col;u>a||(a=l.col,u=s.col),a>this.currentCol||this.currentCol>u?this.selectedCols.push(this.currentCol):(0,v.rangeEach)(a,u,function(e){return t.selectedCols.push(e)})}else this.selectedCols.push(this.currentCol);this.startOffset=r.left-6,this.startWidth=parseInt(r.width,10),this.handle.style.top=r.top+"px",this.handle.style.left=this.startOffset+this.startWidth+"px",this.handle.style.height=n+"px",this.hot.rootElement.appendChild(this.handle)}}},{key:"refreshHandlePosition",value:function(){this.handle.style.left=this.startOffset+this.currentWidth+"px"}},{key:"setupGuidePosition",value:function(){var e=parseInt((0,h.outerHeight)(this.handle),10),t=parseInt(this.handle.style.top,10)+e,o=parseInt(this.hot.view.maximumVisibleElementHeight(0),10);(0,h.addClass)(this.handle,"active"),(0,h.addClass)(this.guide,"active"),this.guide.style.top=t+"px",this.guide.style.left=this.handle.style.left,this.guide.style.height=o-e+"px",this.hot.rootElement.appendChild(this.guide)}},{key:"refreshGuidePosition",value:function(){this.guide.style.left=this.handle.style.left}},{key:"hideHandleAndGuide",value:function(){(0,h.removeClass)(this.handle,"active"),(0,h.removeClass)(this.guide,"active")}},{key:"checkIfColumnHeader",value:function(e){if(e!=this.hot.rootElement){var t=e.parentNode;return"THEAD"===t.tagName||this.checkIfColumnHeader(t)}return!1}},{key:"getTHFromTargetElement",value:function(e){return"TABLE"!=e.tagName?"TH"==e.tagName?e:this.getTHFromTargetElement(e.parentNode):null}},{key:"onMouseOver",value:function(e){if(this.checkIfColumnHeader(e.target)){var t=this.getTHFromTargetElement(e.target);if(!t)return;var o=t.getAttribute("colspan");!t||null!==o&&1!==o||this.pressed||this.setupHandlePosition(t)}}},{key:"afterMouseDownTimeout",value:function(){var e=this,t=function(){e.hot.forceFullRender=!0,e.hot.view.render(),e.hot.view.wt.wtOverlays.adjustElementsSize(!0)},o=function(o,n){var r=e.hot.runHooks("beforeColumnResize",o,e.newSize,!0);void 0!==r&&(e.newSize=r),"all"===e.hot.getSettings().stretchH?e.clearManualSize(o):e.setManualSize(o,e.newSize),n&&t(),e.saveManualColumnWidths(),e.hot.runHooks("afterColumnResize",o,e.newSize,!0)};if(this.dblclick>=2){this.selectedCols.length>1?((0,g.arrayEach)(this.selectedCols,function(e){o(e)}),t()):(0,g.arrayEach)(this.selectedCols,function(e){o(e,!0)})}this.dblclick=0,this.autoresizeTimeout=null}},{key:"onMouseDown",value:function(e){var t=this;(0,h.hasClass)(e.target,"manualColumnResizer")&&(this.setupGuidePosition(),this.pressed=this.hot,null===this.autoresizeTimeout&&(this.autoresizeTimeout=setTimeout(function(){return t.afterMouseDownTimeout()},500),this.hot._registerTimeout(this.autoresizeTimeout)),this.dblclick++,this.startX=(0,p.pageX)(e),this.newSize=this.startWidth)}},{key:"onMouseMove",value:function(e){var t=this;this.pressed&&(this.currentWidth=this.startWidth+((0,p.pageX)(e)-this.startX),(0,g.arrayEach)(this.selectedCols,function(e){t.newSize=t.setManualSize(e,t.currentWidth)}),this.refreshHandlePosition(),this.refreshGuidePosition())}},{key:"onMouseUp",value:function(e){var t=this,o=function(){t.hot.forceFullRender=!0,t.hot.view.render(),t.hot.view.wt.wtOverlays.adjustElementsSize(!0)},n=function(e,n){t.hot.runHooks("beforeColumnResize",e,t.newSize),n&&o(),t.saveManualColumnWidths(),t.hot.runHooks("afterColumnResize",e,t.newSize)};if(this.pressed){if(this.hideHandleAndGuide(),this.pressed=!1,this.newSize!=this.startWidth){this.selectedCols.length>1?((0,g.arrayEach)(this.selectedCols,function(e){n(e)}),o()):(0,g.arrayEach)(this.selectedCols,function(e){n(e,!0)})}this.setupHandlePosition(this.currentTH)}}},{key:"bindEvents",value:function(){var e=this;this.eventManager.addEventListener(this.hot.rootElement,"mouseover",function(t){return e.onMouseOver(t)}),this.eventManager.addEventListener(this.hot.rootElement,"mousedown",function(t){return e.onMouseDown(t)}),this.eventManager.addEventListener(window,"mousemove",function(t){return e.onMouseMove(t)}),this.eventManager.addEventListener(window,"mouseup",function(t){return e.onMouseUp(t)})}},{key:"setManualSize",value:function(e,t){return t=Math.max(t,20),e=this.hot.runHooks("modifyCol",e),this.manualColumnWidths[e]=t,t}},{key:"clearManualSize",value:function(e){e=this.hot.runHooks("modifyCol",e),this.manualColumnWidths[e]=void 0}},{key:"onModifyColWidth",value:function(e,t){return this.enabled&&(t=this.hot.runHooks("modifyCol",t),this.hot.getSettings().manualColumnResize&&this.manualColumnWidths[t])?this.manualColumnWidths[t]:e}},{key:"onBeforeStretchingColumnWidth",value:function(e,t){var o=this.manualColumnWidths[t];return void 0===o&&(o=e),o}},{key:"onBeforeColumnResize",value:function(){this.hot.view.wt.wtViewport.hasOversizedColumnHeadersMarked={}}}]),t}(c.default);(0,m.registerPlugin)("manualColumnResize",y),t.default=y},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var l=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),a=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},u=o(13),c=n(u),h=o(7),d=n(h),f=o(2),p=o(0),g=o(6),v=o(4),m=n(v),y=o(5),w=o(296),C=n(w),b=o(297),S=n(b),E=o(298),R=n(E),O=o(12);o(299),d.default.getSingleton().register("beforeRowMove"),d.default.getSingleton().register("afterRowMove"),d.default.getSingleton().register("unmodifyRow");var k=new WeakMap,T=function(e){function t(e){r(this,t);var o=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return k.set(o,{rowsToMove:[],pressed:void 0,disallowMoving:void 0,target:{eventPageY:void 0,coords:void 0,TD:void 0,row:void 0}}),o.removedRows=[],o.rowsMapper=new C.default(o),o.eventManager=new m.default(o),o.backlight=new S.default(e),o.guideline=new R.default(e),o}return s(t,e),l(t,[{key:"isEnabled",value:function(){return!!this.hot.getSettings().manualRowMove}},{key:"enablePlugin",value:function(){var e=this;this.enabled||(this.addHook("beforeOnCellMouseDown",function(t,o,n,r){return e.onBeforeOnCellMouseDown(t,o,n,r)}),this.addHook("beforeOnCellMouseOver",function(t,o,n,r){return e.onBeforeOnCellMouseOver(t,o,n,r)}),this.addHook("afterScrollHorizontally",function(){return e.onAfterScrollHorizontally()}),this.addHook("modifyRow",function(t,o){return e.onModifyRow(t,o)}),this.addHook("beforeRemoveRow",function(t,o){return e.onBeforeRemoveRow(t,o)}),this.addHook("afterRemoveRow",function(){return e.onAfterRemoveRow()}),this.addHook("afterCreateRow",function(t,o){return e.onAfterCreateRow(t,o)}),this.addHook("afterLoadData",function(){return e.onAfterLoadData()}),this.addHook("beforeColumnSort",function(t,o){return e.onBeforeColumnSort(t,o)}),this.addHook("unmodifyRow",function(t){return e.onUnmodifyRow(t)}),this.registerEvents(),(0,p.addClass)(this.hot.rootElement,"ht__manualRowMove"),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{key:"updatePlugin",value:function(){this.disablePlugin(),this.enablePlugin(),this.onAfterPluginsInitialized(),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"updatePlugin",this).call(this)}},{key:"disablePlugin",value:function(){var e=this.hot.getSettings().manualRowMove;Array.isArray(e)&&this.rowsMapper.clearMap(),(0,p.removeClass)(this.hot.rootElement,"ht__manualRowMove"),this.unregisterEvents(),this.backlight.destroy(),this.guideline.destroy(),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"moveRow",value:function(e,t){this.moveRows([e],t)}},{key:"moveRows",value:function(e,t){var o=this,n=k.get(this);n.disallowMoving=!1===this.hot.runHooks("beforeRowMove",e,t),n.disallowMoving||((0,f.arrayEach)(e,function(e,t,n){n[t]=o.rowsMapper.getValueByIndex(e)}),(0,f.arrayEach)(e,function(e,n){var r=o.rowsMapper.getIndexByValue(e);r!==t&&o.rowsMapper.moveRow(r,t+n)}),this.rowsMapper.clearNull()),this.hot.runHooks("afterRowMove",e,t)}},{key:"changeSelection",value:function(e,t){var o=this.hot.selection,n=this.hot.countCols()-1;o.setRangeStartOnly(new O.CellCoords(e,0)),o.setRangeEnd(new O.CellCoords(t,n),!1)}},{key:"getRowsHeight",value:function(e,t){for(var o=0,n=e;t>n;n++){o+=this.hot.view.wt.wtTable.getRowHeight(n)||23}return o}},{key:"initialSettings",value:function(){var e=this.hot.getSettings().manualRowMove;if(Array.isArray(e))this.moveRows(e,0);else if(void 0!==e){var t=this.persistentStateLoad();t.length&&this.moveRows(t,0)}}},{key:"isFixedRowTop",value:function(e){return e<this.hot.getSettings().fixedRowsTop}},{key:"isFixedRowBottom",value:function(e){return e>this.hot.getSettings().fixedRowsBottom}},{key:"persistentStateSave",value:function(){this.hot.runHooks("persistentStateSave","manualRowMove",this.rowsMapper._arrayMap)}},{key:"persistentStateLoad",value:function(){var e={};return this.hot.runHooks("persistentStateLoad","manualRowMove",e),e.value?e.value:[]}},{key:"prepareRowsToMoving",value:function(){var e=this.hot.getSelectedRange(),t=[];if(!e)return t;var o=e.from,n=e.to,r=Math.min(o.row,n.row),i=Math.max(o.row,n.row);return(0,g.rangeEach)(r,i,function(e){t.push(e)}),t}},{key:"refreshPositions",value:function(){var e=k.get(this),t=e.target.coords,o=this.hot.view.wt.wtTable.getFirstVisibleRow(),n=this.hot.view.wt.wtTable.getLastVisibleRow(),r=this.hot.getSettings().fixedRowsTop,i=this.hot.countRows();r>t.row&&o>0&&this.hot.scrollViewportTo(o-1),t.row>=n&&i>n&&this.hot.scrollViewportTo(n+1,void 0,!0);var s=this.hot.view.wt.wtTable,l=e.target.TD,a=(0,p.offset)(this.hot.rootElement),u=this.hot.view.THEAD.offsetHeight+this.getRowsHeight(0,t.row),c=e.target.eventPageY-a.top+s.holder.scrollTop,h=s.hider.offsetHeight,d=s.TBODY.offsetTop,f=this.backlight.getOffset().top,g=this.backlight.getSize().height;this.isFixedRowTop(t.row)&&(u+=s.holder.scrollTop),0>t.row?e.target.row=o>0?o-1:o:l.offsetHeight/2+u>c?e.target.row=t.row:(e.target.row=t.row+1,u+=0===t.row?l.offsetHeight-1:l.offsetHeight);var v=c,m=u;h>c+g+f?d>c+f&&(v=d+Math.abs(f)):v=h-g-f,h-1>u||(m=h-1);var y=0;this.hot.view.wt.wtOverlays.topOverlay&&(y=this.hot.view.wt.wtOverlays.topOverlay.clone.wtTable.TABLE.offsetHeight),t.row>=r&&y>m-s.holder.scrollTop&&this.hot.scrollViewportTo(t.row),this.backlight.setPosition(v),this.guideline.setPosition(m)}},{key:"updateRowsMapper",value:function(){var e=this.hot.countSourceRows(),t=this.rowsMapper._arrayMap.length;if(0===t)this.rowsMapper.createMap(e||this.hot.getSettings().startRows);else if(e>t){var o=e-t;this.rowsMapper.insertItems(t,o)}else if(t>e){var n=e-1,r=[];(0,f.arrayEach)(this.rowsMapper._arrayMap,function(e,t){e>n&&r.push(t)}),this.rowsMapper.removeItems(r)}}},{key:"registerEvents",value:function(){var e=this;this.eventManager.addEventListener(document.documentElement,"mousemove",function(t){return e.onMouseMove(t)}),this.eventManager.addEventListener(document.documentElement,"mouseup",function(){return e.onMouseUp()})}},{key:"unregisterEvents",value:function(){this.eventManager.clear()}},{key:"onBeforeColumnSort",value:function(e,t){k.get(this).disallowMoving=void 0!==t}},{key:"onBeforeOnCellMouseDown",value:function(e,t,o,n){var r=this.hot.view.wt.wtTable,i=this.hot.selection.selectedHeader.rows,s=this.hot.getSelectedRange(),l=k.get(this);if(!s||!i||l.pressed||0!==e.button)return l.pressed=!1,l.rowsToMove.length=0,void(0,p.removeClass)(this.hot.rootElement,["on-moving--rows","show-ui"]);var a=this.guideline.isBuilt()&&!this.guideline.isAppended(),u=this.backlight.isBuilt()&&!this.backlight.isAppended();a&&u&&(this.guideline.appendTo(r.hider),this.backlight.appendTo(r.hider));var c=s.from,h=s.to,d=Math.min(c.row,h.row),f=Math.max(c.row,h.row);if(0<=t.col||t.row<d||f<t.row)(0,p.removeClass)(this.hot.rootElement,"after-selection--rows"),l.pressed=!1,l.rowsToMove.length=0;else{n.row=!0,l.pressed=!0,l.target.eventPageY=e.pageY,l.target.coords=t,l.target.TD=o,l.rowsToMove=this.prepareRowsToMoving();var g=r.holder.scrollLeft+this.hot.view.wt.wtViewport.getRowHeaderWidth();this.backlight.setPosition(null,g),this.backlight.setSize(r.hider.offsetWidth-g,this.getRowsHeight(d,f+1)),this.backlight.setOffset(-1*(this.getRowsHeight(d,t.row)+e.layerY),null),(0,p.addClass)(this.hot.rootElement,"on-moving--rows"),this.refreshPositions()}}},{key:"onMouseMove",value:function(e){var t=k.get(this);if(t.pressed){if(e.realTarget===this.backlight.element){var o=this.backlight.getSize().height;this.backlight.setSize(null,0),setTimeout(function(){this.backlight.setPosition(null,o)})}t.target.eventPageY=e.pageY,this.refreshPositions()}}},{key:"onBeforeOnCellMouseOver",value:function(e,t,o,n){var r=this.hot.getSelectedRange(),i=k.get(this);r&&i.pressed&&(i.rowsToMove.indexOf(t.row)>-1?(0,p.removeClass)(this.hot.rootElement,"show-ui"):(0,p.addClass)(this.hot.rootElement,"show-ui"),n.row=!0,n.column=!0,n.cell=!0,i.target.coords=t,i.target.TD=o)}},{key:"onMouseUp",value:function(){var e=k.get(this),t=e.target.row,o=e.rowsToMove.length;if(e.pressed=!1,e.backlightHeight=0,(0,p.removeClass)(this.hot.rootElement,["on-moving--rows","show-ui","after-selection--rows"]),this.hot.selection.selectedHeader.rows&&(0,p.addClass)(this.hot.rootElement,"after-selection--rows"),o>=1&&void 0!==t&&-1>=e.rowsToMove.indexOf(t)&&e.rowsToMove[o-1]!==t-1){if(this.moveRows(e.rowsToMove,t),this.persistentStateSave(),this.hot.render(),!e.disallowMoving){this.changeSelection(this.rowsMapper.getIndexByValue(e.rowsToMove[0]),this.rowsMapper.getIndexByValue(e.rowsToMove[o-1]))}e.rowsToMove.length=0}}},{key:"onAfterScrollHorizontally",value:function(){var e=this.hot.view.wt.wtTable,t=this.hot.view.wt.wtViewport.getRowHeaderWidth(),o=e.holder.scrollLeft,n=t+o;this.backlight.setPosition(null,n),this.backlight.setSize(e.hider.offsetWidth-n)}},{key:"onAfterCreateRow",value:function(e,t){this.rowsMapper.shiftItems(e,t)}},{key:"onBeforeRemoveRow",value:function(e,t){var o=this;this.removedRows.length=0,!1!==e&&(0,g.rangeEach)(e,e+t-1,function(e){o.removedRows.push(o.hot.runHooks("modifyRow",e,o.pluginName))})}},{key:"onAfterRemoveRow",value:function(){this.rowsMapper.unshiftItems(this.removedRows)}},{key:"onAfterLoadData",value:function(){this.updateRowsMapper()}},{key:"onModifyRow",value:function(e,t){if(t!==this.pluginName){var o=this.rowsMapper.getValueByIndex(e);e=null===o?e:o}return e}},{key:"onUnmodifyRow",value:function(e){var t=this.rowsMapper.getIndexByValue(e);return null===t?e:t}},{key:"onAfterPluginsInitialized",value:function(){this.updateRowsMapper(),this.initialSettings(),this.backlight.build(),this.guideline.build()}},{key:"destroy",value:function(){this.backlight.destroy(),this.guideline.destroy(),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}}]),t}(c.default);(0,y.registerPlugin)("ManualRowMove",T),t.default=T},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),i=o(176),s=function(e){return e&&e.__esModule?e:{default:e}}(i),l=o(2),a=o(1),u=o(6),c=function(){function e(t){n(this,e),this.manualRowMove=t}return r(e,[{key:"createMap",value:function(e){var t=this,o=void 0===e?this._arrayMap.length:e;this._arrayMap.length=0,(0,u.rangeEach)(o-1,function(e){t._arrayMap[e]=e})}},{key:"destroy",value:function(){this._arrayMap=null}},{key:"moveRow",value:function(e,t){var o=this._arrayMap[e];this._arrayMap[e]=null,this._arrayMap.splice(t,0,o)}},{key:"clearNull",value:function(){this._arrayMap=(0,l.arrayFilter)(this._arrayMap,function(e){return null!==e})}}]),e}();(0,a.mixin)(c,s.default),t.default=c},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var s=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),l=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},a=o(178),u=function(e){return e&&e.__esModule?e:{default:e}}(a),c=o(0);t.default=function(e){function t(){return n(this,t),r(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return i(t,e),s(t,[{key:"build",value:function(){l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"build",this).call(this),(0,c.addClass)(this._element,"ht__manualRowMove--backlight")}}]),t}(u.default)},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var s=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),l=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},a=o(178),u=function(e){return e&&e.__esModule?e:{default:e}}(a),c=o(0);t.default=function(e){function t(){return n(this,t),r(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return i(t,e),s(t,[{key:"build",value:function(){l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"build",this).call(this),(0,c.addClass)(this._element,"ht__manualRowMove--guideline")}}]),t}(u.default)},function(e,t){},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var l=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),a=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},u=o(13),c=n(u),h=o(0),d=o(4),f=n(d),p=o(10),g=o(2),v=o(6),m=o(5),y=function(e){function t(e){r(this,t);var o=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.currentTH=null,o.currentRow=null,o.selectedRows=[],o.currentHeight=null,o.newSize=null,o.startY=null,o.startHeight=null,o.startOffset=null,o.handle=document.createElement("DIV"),o.guide=document.createElement("DIV"),o.eventManager=new f.default(o),o.pressed=null,o.dblclick=0,o.autoresizeTimeout=null,o.manualRowHeights=[],(0,h.addClass)(o.handle,"manualRowResizer"),(0,h.addClass)(o.guide,"manualRowResizerGuide"),o}return s(t,e),l(t,[{key:"isEnabled",value:function(){return this.hot.getSettings().manualRowResize}},{key:"enablePlugin",value:function(){var e=this;if(!this.enabled){this.manualRowHeights=[];var o=this.hot.getSettings().manualRowResize,n=this.loadManualRowHeights();this.manualRowHeights=void 0!==n?n:Array.isArray(o)?o:[],this.addHook("modifyRowHeight",function(t,o){return e.onModifyRowHeight(t,o)}),this.bindEvents(),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this)}}},{key:"updatePlugin",value:function(){var e=this.hot.getSettings().manualRowResize;Array.isArray(e)?this.manualRowHeights=e:e||(this.manualRowHeights=[])}},{key:"disablePlugin",value:function(){a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"saveManualRowHeights",value:function(){this.hot.runHooks("persistentStateSave","manualRowHeights",this.manualRowHeights)}},{key:"loadManualRowHeights",value:function(){var e={};return this.hot.runHooks("persistentStateLoad","manualRowHeights",e),e.value}},{key:"setupHandlePosition",value:function(e){var t=this;this.currentTH=e;var o=this.hot.view.wt.wtTable.getCoords(e).row,n=(0,h.outerWidth)(this.currentTH);if(o>=0){var r=this.currentTH.getBoundingClientRect();if(this.currentRow=o,this.selectedRows=[],this.hot.selection.isSelected()&&this.hot.selection.selectedHeader.rows){var i=this.hot.getSelectedRange(),s=i.from,l=i.to,a=s.row,u=l.row;u>a||(a=l.row,u=s.row),a>this.currentRow||this.currentRow>u?this.selectedRows.push(this.currentRow):(0,v.rangeEach)(a,u,function(e){return t.selectedRows.push(e)})}else this.selectedRows.push(this.currentRow);this.startOffset=r.top-6,this.startHeight=parseInt(r.height,10),this.handle.style.left=r.left+"px",this.handle.style.top=this.startOffset+this.startHeight+"px",this.handle.style.width=n+"px",this.hot.rootElement.appendChild(this.handle)}}},{key:"refreshHandlePosition",value:function(){this.handle.style.top=this.startOffset+this.currentHeight+"px"}},{key:"setupGuidePosition",value:function(){var e=parseInt((0,h.outerWidth)(this.handle),10),t=parseInt(this.handle.style.left,10)+e,o=parseInt(this.hot.view.maximumVisibleElementWidth(0),10);(0,h.addClass)(this.handle,"active"),(0,h.addClass)(this.guide,"active"),this.guide.style.top=this.handle.style.top,this.guide.style.left=t+"px",this.guide.style.width=o-e+"px",this.hot.rootElement.appendChild(this.guide)}},{key:"refreshGuidePosition",value:function(){this.guide.style.top=this.handle.style.top}},{key:"hideHandleAndGuide",value:function(){(0,h.removeClass)(this.handle,"active"),(0,h.removeClass)(this.guide,"active")}},{key:"checkIfRowHeader",value:function(e){if(e!=this.hot.rootElement){var t=e.parentNode;return"TBODY"===t.tagName||this.checkIfRowHeader(t)}return!1}},{key:"getTHFromTargetElement",value:function(e){return"TABLE"!=e.tagName?"TH"==e.tagName?e:this.getTHFromTargetElement(e.parentNode):null}},{key:"onMouseOver",value:function(e){if(this.checkIfRowHeader(e.target)){var t=this.getTHFromTargetElement(e.target);t&&(this.pressed||this.setupHandlePosition(t))}}},{key:"afterMouseDownTimeout",value:function(){var e=this,t=function(){e.hot.forceFullRender=!0,e.hot.view.render(),e.hot.view.wt.wtOverlays.adjustElementsSize(!0)},o=function(o,n){var r=e.hot.runHooks("beforeRowResize",o,e.newSize,!0);void 0!==r&&(e.newSize=r),e.setManualSize(o,e.newSize),n&&t(),e.hot.runHooks("afterRowResize",o,e.newSize,!0)};if(this.dblclick>=2){this.selectedRows.length>1?((0,g.arrayEach)(this.selectedRows,function(e){o(e)}),t()):(0,g.arrayEach)(this.selectedRows,function(e){o(e,!0)})}this.dblclick=0,this.autoresizeTimeout=null}},{key:"onMouseDown",value:function(e){var t=this;(0,h.hasClass)(e.target,"manualRowResizer")&&(this.setupGuidePosition(),this.pressed=this.hot,null==this.autoresizeTimeout&&(this.autoresizeTimeout=setTimeout(function(){return t.afterMouseDownTimeout()},500),this.hot._registerTimeout(this.autoresizeTimeout)),this.dblclick++,this.startY=(0,p.pageY)(e),this.newSize=this.startHeight)}},{key:"onMouseMove",value:function(e){var t=this;this.pressed&&(this.currentHeight=this.startHeight+((0,p.pageY)(e)-this.startY),(0,g.arrayEach)(this.selectedRows,function(e){t.newSize=t.setManualSize(e,t.currentHeight)}),this.refreshHandlePosition(),this.refreshGuidePosition())}},{key:"onMouseUp",value:function(e){var t=this,o=function(){t.hot.forceFullRender=!0,t.hot.view.render(),t.hot.view.wt.wtOverlays.adjustElementsSize(!0)},n=function(e,n){t.hot.runHooks("beforeRowResize",e,t.newSize),n&&o(),t.saveManualRowHeights(),t.hot.runHooks("afterRowResize",e,t.newSize)};if(this.pressed){if(this.hideHandleAndGuide(),this.pressed=!1,this.newSize!=this.startHeight){this.selectedRows.length>1?((0,g.arrayEach)(this.selectedRows,function(e){n(e)}),o()):(0,g.arrayEach)(this.selectedRows,function(e){n(e,!0)})}this.setupHandlePosition(this.currentTH)}}},{key:"bindEvents",value:function(){var e=this;this.eventManager.addEventListener(this.hot.rootElement,"mouseover",function(t){return e.onMouseOver(t)}),this.eventManager.addEventListener(this.hot.rootElement,"mousedown",function(t){return e.onMouseDown(t)}),this.eventManager.addEventListener(window,"mousemove",function(t){return e.onMouseMove(t)}),this.eventManager.addEventListener(window,"mouseup",function(t){return e.onMouseUp(t)})}},{key:"setManualSize",value:function(e,t){return e=this.hot.runHooks("modifyRow",e),this.manualRowHeights[e]=t,t}},{key:"onModifyRowHeight",value:function(e,t){if(this.enabled){var o=this.hot.getPlugin("autoRowSize"),n=o?o.heights[t]:null;t=this.hot.runHooks("modifyRow",t);var r=this.manualRowHeights[t];if(void 0!==r&&(r===n||r>(e||0)))return r}return e}}]),t}(c.default);(0,m.registerPlugin)("manualRowResize",y),t.default=y},function(e,t,o){"use strict";function n(){var e=[];return e.getInfo=function(e,t){for(var o=0,n=this.length;n>o;o++)if(!(this[o].row>e||e>this[o].row+this[o].rowspan-1||this[o].col>t||t>this[o].col+this[o].colspan-1))return this[o]},e.setInfo=function(e){for(var t=0,o=this.length;o>t;t++)if(this[t].row===e.row&&this[t].col===e.col)return void(this[t]=e);this.push(e)},e.removeInfo=function(e,t){for(var o=0,n=this.length;n>o;o++)if(this[o].row===e&&this[o].col===t){this.splice(o,1);break}},e}function r(e){if(this.mergedCellInfoCollection=new n,Array.isArray(e))for(var t=0,o=e.length;o>t;t++)this.mergedCellInfoCollection.setInfo(e[t])}function i(e,t){if(this.getSettings().mergeCells&&!this.selection.isMultiple()){var o=this.mergeCells.mergedCellInfoCollection.getInfo(e[0],e[1]);o&&(e[0]=o.row,e[1]=o.col,e[2]=o.row+o.rowspan-1,e[3]=o.col+o.colspan-1)}}function s(e,t){this.mergeCells&&this.mergeCells.shiftCollection("right",e,t)}function l(e,t){this.mergeCells&&this.mergeCells.shiftCollection("left",e,t)}function a(e,t){this.mergeCells&&this.mergeCells.shiftCollection("down",e,t)}function u(e,t){this.mergeCells&&this.mergeCells.shiftCollection("up",e,t)}t.__esModule=!0;var c=o(7),h=function(e){return e&&e.__esModule?e:{default:e}}(c),d=(o(5),o(10)),f=o(12);r.prototype.canMergeRange=function(e){return!e.isSingle()},r.prototype.mergeRange=function(e){if(this.canMergeRange(e)){var t=e.getTopLeftCorner(),o=e.getBottomRightCorner(),n={};n.row=t.row,n.col=t.col,n.rowspan=o.row-t.row+1,n.colspan=o.col-t.col+1,this.mergedCellInfoCollection.setInfo(n)}},r.prototype.mergeOrUnmergeSelection=function(e){this.mergedCellInfoCollection.getInfo(e.from.row,e.from.col)?this.unmergeSelection(e.from):this.mergeSelection(e)},r.prototype.mergeSelection=function(e){this.mergeRange(e)},r.prototype.unmergeSelection=function(e){var t=this.mergedCellInfoCollection.getInfo(e.row,e.col);this.mergedCellInfoCollection.removeInfo(t.row,t.col)},r.prototype.applySpanProperties=function(e,t,o){var n=this.mergedCellInfoCollection.getInfo(t,o);n?n.row===t&&n.col===o?(e.setAttribute("rowspan",n.rowspan),e.setAttribute("colspan",n.colspan)):(e.removeAttribute("rowspan"),e.removeAttribute("colspan"),e.style.display="none"):(e.removeAttribute("rowspan"),e.removeAttribute("colspan"))},r.prototype.modifyTransform=function(e,t,o){var n={row:o.row,col:o.col};if("modifyTransformStart"==e){var r;this.lastDesiredCoords||(this.lastDesiredCoords=new f.CellCoords(null,null));for(var i=new f.CellCoords(t.highlight.row,t.highlight.col),s=this.mergedCellInfoCollection.getInfo(i.row,i.col),l=0,a=this.mergedCellInfoCollection.length;a>l;l++){var u=this.mergedCellInfoCollection[l];if(u=new f.CellCoords(u.row+u.rowspan-1,u.col+u.colspan-1),t.includes(u)){!0;break}}if(s){var c=new f.CellCoords(s.row,s.col),h=new f.CellCoords(s.row+s.rowspan-1,s.col+s.colspan-1);new f.CellRange(c,c,h).includes(this.lastDesiredCoords)||(this.lastDesiredCoords=new f.CellCoords(null,null)),n.row=this.lastDesiredCoords.row?this.lastDesiredCoords.row-i.row:n.row,n.col=this.lastDesiredCoords.col?this.lastDesiredCoords.col-i.col:n.col,o.row>0?n.row=s.row+s.rowspan-1-i.row+o.row:0>o.row&&(n.row=i.row-s.row+o.row),o.col>0?n.col=s.col+s.colspan-1-i.col+o.col:0>o.col&&(n.col=i.col-s.col+o.col)}r=new f.CellCoords(t.highlight.row+n.row,t.highlight.col+n.col);var d=this.mergedCellInfoCollection.getInfo(r.row,r.col);d&&(this.lastDesiredCoords=r,n={row:d.row-i.row,col:d.col-i.col})}else if("modifyTransformEnd"==e)for(var p=0,g=this.mergedCellInfoCollection.length;g>p;p++){var v=this.mergedCellInfoCollection[p],m=new f.CellCoords(v.row,v.col),y=new f.CellCoords(v.row+v.rowspan-1,v.col+v.colspan-1),w=new f.CellRange(m,m,y),C=t.getBordersSharedWith(w);if(w.isEqual(t))t.setDirection("NW-SE");else if(C.length>0){var b=t.highlight.isEqual(w.from);C.indexOf("top")>-1?t.to.isSouthEastOf(w.from)&&b?t.setDirection("NW-SE"):t.to.isSouthWestOf(w.from)&&b&&t.setDirection("NE-SW"):C.indexOf("bottom")>-1&&(t.to.isNorthEastOf(w.from)&&b?t.setDirection("SW-NE"):t.to.isNorthWestOf(w.from)&&b&&t.setDirection("SE-NW"))}r=function(e){return new f.CellCoords(t.to.row+e.row,t.to.col+e.col)}(n);var S=function(e,t){return t.row>=e.row&&e.row+e.rowspan-1>=t.row}(v,r),E=function(e,t){return t.col>=e.col&&e.col+e.colspan-1>=t.col}(v,r);t.includesRange(w)&&(w.includes(r)||S||E)&&(S&&(0>n.row?n.row-=v.rowspan-1:n.row>0&&(n.row+=v.rowspan-1)),E&&(0>n.col?n.col-=v.colspan-1:n.col>0&&(n.col+=v.colspan-1)))}0!==n.row&&(o.row=n.row),0!==n.col&&(o.col=n.col)},r.prototype.shiftCollection=function(e,t,o){var n=[0,0];switch(e){case"right":n[0]+=1;break;case"left":n[0]-=1;break;case"down":n[1]+=1;break;case"up":n[1]-=1}for(var r=0;this.mergedCellInfoCollection.length>r;r++){var i=this.mergedCellInfoCollection[r];"right"===e||"left"===e?t>i.col||(i.col+=n[0]):t>i.row||(i.row+=n[1])}};var p=function(){var e=this,t=e.getSettings().mergeCells;t&&(e.mergeCells||(e.mergeCells=new r(t)))},g=function(){var e=this;e.mergeCells&&(e.view.wt.wtTable.getCell=function(t){if(e.getSettings().mergeCells){var o=e.mergeCells.mergedCellInfoCollection.getInfo(t.row,t.col);o&&(t=o)}return f.Table.prototype.getCell.call(this,t)})},v=function(){var e=this,t=e.getSettings().mergeCells;if(t)if(e.mergeCells){if(e.mergeCells.mergedCellInfoCollection=new n,Array.isArray(t))for(var o=0,i=t.length;i>o;o++)e.mergeCells.mergedCellInfoCollection.setInfo(t[o])}else e.mergeCells=new r(t);else e.mergeCells&&(e.mergeCells.mergedCellInfoCollection=new n)},m=function(e){if(this.mergeCells){(e.ctrlKey||e.metaKey)&&!e.altKey&&77===e.keyCode&&(this.mergeCells.mergeOrUnmergeSelection(this.getSelectedRange()),this.render(),(0,d.stopImmediatePropagation)(e))}},y=function(e){this.getSettings().mergeCells&&(e.items.push({name:"---------"}),e.items.push({key:"mergeCells",name:function(){var e=this.getSelected();return this.mergeCells.mergedCellInfoCollection.getInfo(e[0],e[1])?"Unmerge cells":"Merge cells"},callback:function(){this.mergeCells.mergeOrUnmergeSelection(this.getSelectedRange()),this.render()},disabled:function(){return this.selection.selectedHeader.corner}}))},w=function(e,t,o,n,r,i){this.mergeCells&&this.mergeCells.applySpanProperties(e,t,o)},C=function(e){return function(t){if(this.getSettings().mergeCells){var o=this.getSelectedRange();if(this.mergeCells.modifyTransform(e,o,t),"modifyTransformEnd"===e){var n=this.countRows(),r=this.countCols();0>o.from.row?o.from.row=0:o.from.row>0&&o.from.row>=n&&(o.from.row=o.from-1),0>o.from.col?o.from.col=0:o.from.col>0&&o.from.col>=r&&(o.from.col=r-1)}}}},b=function(e){if(this.lastDesiredCoords=null,this.getSettings().mergeCells){var t=this.getSelectedRange();t.highlight=new f.CellCoords(t.highlight.row,t.highlight.col),t.to=e;var o=!1;do{o=!1;for(var n=0,r=this.mergeCells.mergedCellInfoCollection.length;r>n;n++){var i=this.mergeCells.mergedCellInfoCollection[n],s=new f.CellCoords(i.row,i.col),l=new f.CellCoords(i.row+i.rowspan-1,i.col+i.colspan-1);t.expandByRange(new f.CellRange(s,s,l))&&(e.row=t.to.row,e.col=t.to.col,o=!0)}}while(o)}},S=function(e,t){if(t&&"area"==t){if(this.getSettings().mergeCells)for(var o=this.getSelectedRange(),n=new f.CellRange(o.from,o.from,o.from),r=new f.CellRange(o.to,o.to,o.to),i=0,s=this.mergeCells.mergedCellInfoCollection.length;s>i;i++){var l=this.mergeCells.mergedCellInfoCollection[i],a=new f.CellCoords(l.row,l.col),u=new f.CellCoords(l.row+l.rowspan-1,l.col+l.colspan-1),c=new f.CellRange(a,a,u);n.expandByRange(c)&&(e[0]=n.from.row,e[1]=n.from.col),r.expandByRange(c)&&(e[2]=r.from.row,e[3]=r.from.col)}}},E=function(e,t,o){if(this.getSettings().mergeCells){var n=this.mergeCells.mergedCellInfoCollection.getInfo(e,t);!n||n.row==e&&n.col==t||(o.copyable=!1)}},R=function e(t){if(this.getSettings().mergeCells)for(var o,n=this.countCols(),r=0;n>r;r++){if((o=this.mergeCells.mergedCellInfoCollection.getInfo(t.startRow,r))&&t.startRow>o.row)return t.startRow=o.row,e.call(this,t);if(o=this.mergeCells.mergedCellInfoCollection.getInfo(t.endRow,r)){var i=o.row+o.rowspan-1;if(i>t.endRow)return t.endRow=i,e.call(this,t)}}},O=function e(t){if(this.getSettings().mergeCells)for(var o,n=this.countRows(),r=0;n>r;r++){if((o=this.mergeCells.mergedCellInfoCollection.getInfo(r,t.startColumn))&&t.startColumn>o.col)return t.startColumn=o.col,e.call(this,t);if(o=this.mergeCells.mergedCellInfoCollection.getInfo(r,t.endColumn)){var i=o.col+o.colspan-1;if(i>t.endColumn)return t.endColumn=i,e.call(this,t)}}},k=function(e){if(e&&this.mergeCells){var t=this.mergeCells.mergedCellInfoCollection,o=this.getSelectedRange();for(var n in t)if(o.highlight.row==t[n].row&&o.highlight.col==t[n].col&&o.to.row==t[n].row+t[n].rowspan-1&&o.to.col==t[n].col+t[n].colspan-1)return!1}return e},T=h.default.getSingleton();T.add("beforeInit",p),T.add("afterInit",g),T.add("afterUpdateSettings",v),T.add("beforeKeyDown",m),T.add("modifyTransformStart",C("modifyTransformStart")),T.add("modifyTransformEnd",C("modifyTransformEnd")),T.add("beforeSetRangeEnd",b),T.add("beforeDrawBorders",S),T.add("afterIsMultipleSelection",k),T.add("afterRenderer",w),T.add("afterContextMenuDefaultOptions",y),T.add("afterGetCellMeta",E),T.add("afterViewportRowCalculatorOverride",R),T.add("afterViewportColumnCalculatorOverride",O),T.add("modifyAutofillRange",i),T.add("afterCreateCol",s),T.add("afterRemoveCol",l),T.add("afterCreateRow",a),T.add("afterRemoveRow",u),t.default=r},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var l=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),a=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},u=o(7),c=(n(u),o(0)),h=o(26),d=o(13),f=n(d),p=o(4),g=n(p),v=o(5),m=o(12),y=function(e){function t(e){r(this,t);var o=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.dragged=[],o.eventManager=null,o.lastSetCell=null,o}return s(t,e),l(t,[{key:"isEnabled",value:function(){return(0,h.isMobileBrowser)()}},{key:"enablePlugin",value:function(){this.enabled||(this.eventManager||(this.eventManager=new g.default(this)),this.registerListeners(),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{key:"registerListeners",value:function(){function e(e){if(1===t.dragged.length)return t.dragged.splice(0,t.dragged.length),!0;var o=t.dragged.indexOf(e);if(-1==o)return!1;0===o?t.dragged=t.dragged.slice(0,1):1==o&&(t.dragged=t.dragged.slice(-1))}var t=this;this.eventManager.addEventListener(this.hot.rootElement,"touchstart",function(e){var o=void 0;return(0,c.hasClass)(e.target,"topLeftSelectionHandle-HitArea")?(o=t.hot.getSelectedRange(),t.dragged.push("topLeft"),t.touchStartRange={width:o.getWidth(),height:o.getHeight(),direction:o.getDirection()},e.preventDefault(),!1):(0,c.hasClass)(e.target,"bottomRightSelectionHandle-HitArea")?(o=t.hot.getSelectedRange(),t.dragged.push("bottomRight"),t.touchStartRange={width:o.getWidth(),height:o.getHeight(),direction:o.getDirection()},e.preventDefault(),!1):void 0}),this.eventManager.addEventListener(this.hot.rootElement,"touchend",function(o){return(0,c.hasClass)(o.target,"topLeftSelectionHandle-HitArea")?(e.call(t,"topLeft"),t.touchStartRange=void 0,o.preventDefault(),!1):(0,c.hasClass)(o.target,"bottomRightSelectionHandle-HitArea")?(e.call(t,"bottomRight"),t.touchStartRange=void 0,o.preventDefault(),!1):void 0}),this.eventManager.addEventListener(this.hot.rootElement,"touchmove",function(e){var o=(0,c.getWindowScrollTop)(),n=(0,c.getWindowScrollLeft)(),r=void 0,i=void 0,s=void 0,l=void 0,a=void 0,u=void 0,h=void 0;0!==t.dragged.length&&(r=document.elementFromPoint(e.touches[0].screenX-n,e.touches[0].screenY-o))&&r!==t.lastSetCell&&("TD"!=r.nodeName&&"TH"!=r.nodeName||(i=t.hot.getCoords(r),-1==i.col&&(i.col=0),s=t.hot.getSelectedRange(),l=s.getWidth(),a=s.getHeight(),u=s.getDirection(),1==l&&1==a&&t.hot.selection.setRangeEnd(i),h=t.getCurrentRangeCoords(s,i,t.touchStartRange.direction,u,t.dragged[0]),null!==h.start&&t.hot.selection.setRangeStart(h.start),t.hot.selection.setRangeEnd(h.end),t.lastSetCell=r),e.preventDefault())})}},{key:"getCurrentRangeCoords",value:function(e,t,o,n,r){var i=e.getTopLeftCorner(),s=e.getBottomRightCorner(),l=e.getBottomLeftCorner(),a=e.getTopRightCorner(),u={start:null,end:null};switch(o){case"NE-SW":switch(n){case"NE-SW":case"NW-SE":u="topLeft"==r?{start:new m.CellCoords(t.row,e.highlight.col),end:new m.CellCoords(l.row,t.col)}:{start:new m.CellCoords(e.highlight.row,t.col),end:new m.CellCoords(t.row,i.col)};break;case"SE-NW":"bottomRight"==r&&(u={start:new m.CellCoords(s.row,t.col),end:new m.CellCoords(t.row,i.col)})}break;case"NW-SE":switch(n){case"NE-SW":"topLeft"==r?u={start:t,end:l}:u.end=t;break;case"NW-SE":"topLeft"==r?u={start:t,end:s}:u.end=t;break;case"SE-NW":"topLeft"==r?u={start:t,end:i}:u.end=t;break;case"SW-NE":"topLeft"==r?u={start:t,end:a}:u.end=t}break;case"SW-NE":switch(n){case"NW-SE":u="bottomRight"==r?{start:new m.CellCoords(t.row,i.col),end:new m.CellCoords(l.row,t.col)}:{start:new m.CellCoords(i.row,t.col),end:new m.CellCoords(t.row,s.col)};break;case"SW-NE":u="topLeft"==r?{start:new m.CellCoords(e.highlight.row,t.col),end:new m.CellCoords(t.row,s.col)}:{start:new m.CellCoords(t.row,i.col),end:new m.CellCoords(i.row,t.col)};break;case"SE-NW":"bottomRight"==r?u={start:new m.CellCoords(t.row,a.col),end:new m.CellCoords(i.row,t.col)}:"topLeft"==r&&(u={start:l,end:t})}break;case"SE-NW":switch(n){case"NW-SE":case"NE-SW":case"SW-NE":"topLeft"==r&&(u.end=t);break;case"SE-NW":"topLeft"==r?u.end=t:u={start:t,end:i}}}return u}},{key:"isDragged",value:function(){return this.dragged.length>0}}]),t}(f.default);(0,v.registerPlugin)("multipleSelectionHandles",y),t.default=y},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var l=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),a=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},u=o(13),c=n(u),h=o(179),d=(n(h),o(304)),f=n(d),p=o(2),g=o(5),v=function(e){function t(e){r(this,t);var o=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.observer=null,o}return s(t,e),l(t,[{key:"isEnabled",value:function(){return this.hot.getSettings().observeChanges}},{key:"enablePlugin",value:function(){var e=this;this.enabled||(this.observer||(this.observer=new f.default(this.hot.getSourceData()),this._exposePublicApi()),this.observer.addLocalHook("change",function(t){return e.onDataChange(t)}),this.addHook("afterCreateRow",function(){return e.onAfterTableAlter()}),this.addHook("afterRemoveRow",function(){return e.onAfterTableAlter()}),this.addHook("afterCreateCol",function(){return e.onAfterTableAlter()}),this.addHook("afterRemoveCol",function(){return e.onAfterTableAlter()}),this.addHook("afterChange",function(t,o){return e.onAfterTableAlter(o)}),this.addHook("afterLoadData",function(t){return e.onAfterLoadData(t)}),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{key:"disablePlugin",value:function(){this.observer&&(this.observer.destroy(),this.observer=null,this._deletePublicApi()),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"onDataChange",value:function(e){var t=this;if(!this.observer.isPaused()){var o=this.pluginName+".change",n={add:function(e){isNaN(e.col)?t.hot.runHooks("afterCreateRow",e.row,1,o):t.hot.runHooks("afterCreateCol",e.col,1,o)},remove:function(e){isNaN(e.col)?t.hot.runHooks("afterRemoveRow",e.row,1,o):t.hot.runHooks("afterRemoveCol",e.col,1,o)},replace:function(e){t.hot.runHooks("afterChange",[e.row,e.col,null,e.value],o)}};(0,p.arrayEach)(e,function(e){n[e.op]&&n[e.op](e)}),this.hot.render()}this.hot.runHooks("afterChangesObserved")}},{key:"onAfterTableAlter",value:function(e){var t=this;"loadData"!==e&&(this.observer.pause(),this.hot.addHookOnce("afterChangesObserved",function(){return t.observer.resume()}))}},{key:"onAfterLoadData",value:function(e){e||this.observer.setObservedData(this.hot.getSourceData())}},{key:"destroy",value:function(){this.observer&&(this.observer.destroy(),this._deletePublicApi()),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}},{key:"_exposePublicApi",value:function(){var e=this,t=this.hot;t.pauseObservingChanges=function(){return e.observer.pause()},t.resumeObservingChanges=function(){return e.observer.resume()},t.isPausedObservingChanges=function(){return e.observer.isPaused()}}},{key:"_deletePublicApi",value:function(){var e=this.hot;delete e.pauseObservingChanges,delete e.resumeObservingChanges,delete e.isPausedObservingChanges}}]),t}(c.default);t.default=v,(0,g.registerPlugin)("observeChanges",v)},function(e,t,o){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var i=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),s=o(179),l=n(s),a=o(87),u=n(a),c=o(1),h=o(305),d=function(){function e(t){r(this,e),this.observedData=null,this.observer=null,this.paused=!1,this.setObservedData(t)}return i(e,[{key:"setObservedData",value:function(e){var t=this;this.observer&&l.default.unobserve(this.observedData,this.observer),this.observedData=e,this.observer=l.default.observe(this.observedData,function(e){return t.onChange(e)})}},{key:"isPaused",value:function(){return this.paused}},{key:"pause",value:function(){this.paused=!0}},{key:"resume",value:function(){this.paused=!1}},{key:"onChange",value:function(e){this.runLocalHooks("change",(0,h.cleanPatches)(e))}},{key:"destroy",value:function(){l.default.unobserve(this.observedData,this.observer),this.observedData=null,this.observer=null}}]),e}();(0,c.mixin)(d,u.default),t.default=d},function(e,t,o){"use strict";function n(e){var t=[];return e=(0,s.arrayFilter)(e,function(e){return!/[\/]length/gi.test(e.path)&&!!r(e.path)}),e=(0,s.arrayMap)(e,function(e){var t=r(e.path);return e.row=t.row,e.col=t.col,e}),e=(0,s.arrayFilter)(e,function(e){if(-1!==["add","remove"].indexOf(e.op)&&!isNaN(e.col)){if(-1!==t.indexOf(e.col))return!1;t.push(e.col)}return!0}),t.length=0,e}function r(e){var t=e.match(/^\/(\d+)\/?(.*)?$/);if(!t)return null;var o=i(t,3),n=o[1],r=o[2];return{row:parseInt(n,10),col:/^\d*$/.test(r)?parseInt(r,10):r}}t.__esModule=!0;var i=function(){function e(e,t){var o=[],n=!0,r=!1,i=void 0;try{for(var s,l=e[Symbol.iterator]();!(n=(s=l.next()).done)&&(o.push(s.value),!t||o.length!==t);n=!0);}catch(e){r=!0,i=e}finally{try{!n&&l.return&&l.return()}finally{if(r)throw i}}return o}return function(t,o){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,o);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}();t.cleanPatches=n,t.parsePath=r;var s=o(2)},function(e,t,o){"use strict";function n(e){var t,o=function(){window.localStorage[e+"__persistentStateKeys"]=JSON.stringify(t)},n=function(){t=[],o()};!function(){var o=window.localStorage[e+"__persistentStateKeys"],n="string"==typeof o?JSON.parse(o):void 0;t=n||[]}(),this.saveValue=function(n,r){window.localStorage[e+"_"+n]=JSON.stringify(r),-1==t.indexOf(n)&&(t.push(n),o())},this.loadValue=function(t,o){t=void 0===t?o:t;var n=window.localStorage[e+"_"+t];return void 0===n?void 0:JSON.parse(n)},this.reset=function(t){window.localStorage.removeItem(e+"_"+t)},this.resetAll=function(){for(var o=0;t.length>o;o++)window.localStorage.removeItem(e+"_"+t[o]);n()}}function r(){function e(){var e=this;for(var t in r)(0,l.hasOwnProperty)(r,t)&&e.addHook(t,r[t])}function t(){var e=this;for(var t in r)(0,l.hasOwnProperty)(r,t)&&e.removeHook(t,r[t])}var o=this;this.init=function(){var r=this,i=r.getSettings().persistentState;if(!(o.enabled=!!i))return void t.call(r);r.storage||(r.storage=new n(r.rootElement.id)),r.resetState=o.resetValue,e.call(r)},this.saveValue=function(e,t){this.storage.saveValue(e,t)},this.loadValue=function(e,t){t.value=this.storage.loadValue(e)},this.resetValue=function(e){var t=this;void 0===e?t.storage.resetAll():t.storage.reset(e)};var r={persistentStateSave:o.saveValue,persistentStateLoad:o.loadValue,persistentStateReset:o.resetValue};for(var i in r)(0,l.hasOwnProperty)(r,i)&&s.default.getSingleton().register(i)}t.__esModule=!0;var i=o(7),s=function(e){return e&&e.__esModule?e:{default:e}}(i),l=(o(5),o(1)),a=new r;s.default.getSingleton().add("beforeInit",a.init),s.default.getSingleton().add("afterUpdateSettings",a.init),t.default=r},function(e,t,o){"use strict";function n(e){this.query=function(t,o,r){var i=e.countRows(),s=e.countCols(),l=[];o||(o=n.global.getDefaultCallback()),r||(r=n.global.getDefaultQueryMethod());for(var a=0;i>a;a++)for(var u=0;s>u;u++){var c=e.getDataAtCell(a,u),h=e.getCellMeta(a,u),d=h.search.callback||o,f=h.search.queryMethod||r,p=f(t,c);if(p){var g={row:a,col:u,data:c};l.push(g)}d&&d(e,a,u,c,p)}return l}}function r(e,t,o,r,i,l,a){var c=null!==a.search&&"object"==s(a.search)&&a.search.searchResultClass||n.global.getDefaultSearchResultClass();a.isSearchResult?(0,u.addClass)(t,c):(0,u.removeClass)(t,c)}function i(){var e=this;!e.getSettings().search?delete e.search:e.search=new n(e)}t.__esModule=!0;var s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},l=o(7),a=function(e){return e&&e.__esModule?e:{default:e}}(l),u=o(0),c=o(8);n.DEFAULT_CALLBACK=function(e,t,o,n,r){e.getCellMeta(t,o).isSearchResult=r},n.DEFAULT_QUERY_METHOD=function(e,t){return!(void 0===e||null==e||!e.toLowerCase||0===e.length)&&(void 0!==t&&null!=t&&-1!=(""+t).toLowerCase().indexOf(e.toLowerCase()))},n.DEFAULT_SEARCH_RESULT_CLASS="htSearchResult",n.global=function(){var e=n.DEFAULT_CALLBACK,t=n.DEFAULT_QUERY_METHOD,o=n.DEFAULT_SEARCH_RESULT_CLASS;return{getDefaultCallback:function(){return e},setDefaultCallback:function(t){e=t},getDefaultQueryMethod:function(){return t},setDefaultQueryMethod:function(e){t=e},getDefaultSearchResultClass:function(){return o},setDefaultSearchResultClass:function(e){o=e}}}();var h=(0,c.getRenderer)("base");(0,c.registerRenderer)("base",function(e,t,o,n,i,s,l){h.apply(this,arguments),r.apply(this,arguments)}),a.default.getSingleton().add("afterInit",i),a.default.getSingleton().add("afterUpdateSettings",i),t.default=n},function(e,t,o){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var s=function(){function e(e,t){for(var o=0;t.length>o;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,o,n){return o&&e(t.prototype,o),n&&e(t,n),t}}(),l=function e(t,o,n){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,o);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,o,n)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(n)},a=o(0),u=o(2),c=o(13),h=function(e){return e&&e.__esModule?e:{default:e}}(c),d=o(5),f=o(34),p=function(e){function t(e){n(this,t);var o=r(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return o.scrollbars=[],o.clones=[],o.lockedCollection=!1,o.freezeOverlays=!1,o}return i(t,e),s(t,[{key:"isEnabled",value:function(){return(0,f.isTouchSupported)()}},{key:"enablePlugin",value:function(){var e=this;this.enabled||(this.addHook("afterRender",function(){return e.onAfterRender()}),this.registerEvents(),l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{key:"updatePlugin",value:function(){this.lockedCollection=!1,l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"updatePlugin",this).call(this)}},{key:"disablePlugin",value:function(){l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"registerEvents",value:function(){var e=this;this.addHook("beforeTouchScroll",function(){return e.onBeforeTouchScroll()}),this.addHook("afterMomentumScroll",function(){return e.onAfterMomentumScroll()})}},{key:"onAfterRender",value:function(){if(!this.lockedCollection){var e=this.hot.view.wt.wtOverlays,t=e.topOverlay,o=e.bottomOverlay,n=e.leftOverlay,r=e.topLeftCornerOverlay,i=e.bottomLeftCornerOverlay;this.lockedCollection=!0,this.scrollbars.length=0,this.scrollbars.push(t),o.clone&&this.scrollbars.push(o),this.scrollbars.push(n),r&&this.scrollbars.push(r),i&&i.clone&&this.scrollbars.push(i),this.clones.length=0,t.needFullRender&&this.clones.push(t.clone.wtTable.holder.parentNode),o.needFullRender&&this.clones.push(o.clone.wtTable.holder.parentNode),n.needFullRender&&this.clones.push(n.clone.wtTable.holder.parentNode),r&&this.clones.push(r.clone.wtTable.holder.parentNode),i&&i.clone&&this.clones.push(i.clone.wtTable.holder.parentNode)}}},{key:"onBeforeTouchScroll",value:function(){this.freezeOverlays=!0,(0,u.arrayEach)(this.clones,function(e){(0,a.addClass)(e,"hide-tween")})}},{key:"onAfterMomentumScroll",value:function(){var e=this;this.freezeOverlays=!1,(0,u.arrayEach)(this.clones,function(e){(0,a.removeClass)(e,"hide-tween"),(0,a.addClass)(e,"show-tween")}),setTimeout(function(){(0,u.arrayEach)(e.clones,function(e){(0,a.removeClass)(e,"show-tween")})},400),(0,u.arrayEach)(this.scrollbars,function(e){e.refresh(),e.resetFixedPosition()}),this.hot.view.wt.wtOverlays.syncScrollWithMaster()}}]),t}(h.default);(0,d.registerPlugin)("touchScroll",p),t.default=p},function(e,t,o){"use strict";function n(e){var t=this;this.instance=e,this.doneActions=[],this.undoneActions=[],this.ignoreNewActions=!1,e.addHook("afterChange",function(e,o){e&&"UndoRedo.undo"!==o&&"UndoRedo.redo"!==o&&t.done(new n.ChangeAction(e))}),e.addHook("afterCreateRow",function(e,o,r){if("UndoRedo.undo"!==r&&"UndoRedo.undo"!==r&&"auto"!==r){var i=new n.CreateRowAction(e,o);t.done(i)}}),e.addHook("beforeRemoveRow",function(e,o,r,i){if("UndoRedo.undo"!==i&&"UndoRedo.redo"!==i&&"auto"!==i){var s=t.instance.getSourceDataArray();e=(s.length+e)%s.length;var l=(0,f.deepClone)(s.slice(e,e+o));t.done(new n.RemoveRowAction(e,l))}}),e.addHook("afterCreateCol",function(e,o,r){"UndoRedo.undo"!==r&&"UndoRedo.redo"!==r&&"auto"!==r&&t.done(new n.CreateColumnAction(e,o))}),e.addHook("beforeRemoveCol",function(o,r,i,s){if("UndoRedo.undo"!==s&&"UndoRedo.redo"!==s&&"auto"!==s){var l=t.instance.getSourceDataArray();o=(t.instance.countCols()+o)%t.instance.countCols();var a=[],u=[],c=[];(0,d.rangeEach)(l.length-1,function(t){var n=[],i=l[t];(0,d.rangeEach)(o,o+(r-1),function(t){n.push(i[e.runHooks("modifyCol",t)])}),a.push(n)}),(0,d.rangeEach)(r-1,function(t){c.push(e.runHooks("modifyCol",o+t))}),Array.isArray(e.getSettings().colHeaders)&&(0,d.rangeEach)(r-1,function(t){u.push(e.getSettings().colHeaders[e.runHooks("modifyCol",o+t)]||null)});var h=t.instance.getPlugin("manualColumnMove"),f=h.isEnabled()?h.columnsMapper.__arrayMap:[],p=new n.RemoveColumnAction(o,c,a,u,f);t.done(p)}}),e.addHook("beforeCellAlignment",function(e,o,r,i){var s=new n.CellAlignmentAction(e,o,r,i);t.done(s)}),e.addHook("beforeFilter",function(e){t.done(new n.FiltersAction(e))}),e.addHook("beforeRowMove",function(e,o){!1!==e&&t.done(new n.RowMoveAction(e,o))})}function r(){var e=this;void 0===e.getSettings().undo||e.getSettings().undo?e.undoRedo||(e.undoRedo=new n(e),l(e),e.addHook("beforeKeyDown",i),e.addHook("afterChange",s)):e.undoRedo&&(delete e.undoRedo,a(e),e.removeHook("beforeKeyDown",i),e.removeHook("afterChange",s))}function i(e){var t=this;(e.ctrlKey||e.metaKey)&&!e.altKey&&(89===e.keyCode||e.shiftKey&&90===e.keyCode?(t.undoRedo.redo(),(0,p.stopImmediatePropagation)(e)):90===e.keyCode&&(t.undoRedo.undo(),(0,p.stopImmediatePropagation)(e)))}function s(e,t){var o=this;if("loadData"===t)return o.undoRedo.clear()}function l(e){e.undo=function(){return e.undoRedo.undo()},e.redo=function(){return e.undoRedo.redo()},e.isUndoAvailable=function(){return e.undoRedo.isUndoAvailable()},e.isRedoAvailable=function(){return e.undoRedo.isRedoAvailable()},e.clearUndo=function(){return e.undoRedo.clear()}}function a(e){delete e.undo,delete e.redo,delete e.isUndoAvailable,delete e.isRedoAvailable,delete e.clearUndo}var u=o(7),c=function(e){return e&&e.__esModule?e:{default:e}}(u),h=o(2),d=o(6),f=o(1),p=o(10),g=o(12);n.prototype.done=function(e){this.ignoreNewActions||(this.doneActions.push(e),this.undoneActions.length=0)},n.prototype.undo=function(){if(this.isUndoAvailable()){var e=this.doneActions.pop(),t=(0,f.deepClone)(e),o=this.instance;if(!1===o.runHooks("beforeUndo",t))return;this.ignoreNewActions=!0;var n=this;e.undo(this.instance,function(){n.ignoreNewActions=!1,n.undoneActions.push(e)}),o.runHooks("afterUndo",t)}},n.prototype.redo=function(){if(this.isRedoAvailable()){var e=this.undoneActions.pop(),t=(0,f.deepClone)(e),o=this.instance;if(!1===o.runHooks("beforeRedo",t))return;this.ignoreNewActions=!0;var n=this;e.redo(this.instance,function(){n.ignoreNewActions=!1,n.doneActions.push(e)}),o.runHooks("afterRedo",t)}},n.prototype.isUndoAvailable=function(){return this.doneActions.length>0},n.prototype.isRedoAvailable=function(){return this.undoneActions.length>0},n.prototype.clear=function(){this.doneActions.length=0,this.undoneActions.length=0},n.Action=function(){},n.Action.prototype.undo=function(){},n.Action.prototype.redo=function(){},n.ChangeAction=function(e){this.changes=e,this.actionType="change"},(0,f.inherit)(n.ChangeAction,n.Action),n.ChangeAction.prototype.undo=function(e,t){for(var o=(0,f.deepClone)(this.changes),n=e.countEmptyRows(!0),r=e.countEmptyCols(!0),i=0,s=o.length;s>i;i++)o[i].splice(3,1);e.addHookOnce("afterChange",t),e.setDataAtRowProp(o,null,null,"UndoRedo.undo");for(var l=0,a=o.length;a>l;l++)e.getSettings().minSpareRows&&o[l][0]+1+e.getSettings().minSpareRows===e.countRows()&&n==e.getSettings().minSpareRows&&(e.alter("remove_row",parseInt(o[l][0]+1,10),e.getSettings().minSpareRows),e.undoRedo.doneActions.pop()),e.getSettings().minSpareCols&&o[l][1]+1+e.getSettings().minSpareCols===e.countCols()&&r==e.getSettings().minSpareCols&&(e.alter("remove_col",parseInt(o[l][1]+1,10),e.getSettings().minSpareCols),e.undoRedo.doneActions.pop())},n.ChangeAction.prototype.redo=function(e,t){for(var o=(0,f.deepClone)(this.changes),n=0,r=o.length;r>n;n++)o[n].splice(2,1);e.addHookOnce("afterChange",t),e.setDataAtRowProp(o,null,null,"UndoRedo.redo")},n.CreateRowAction=function(e,t){this.index=e,this.amount=t,this.actionType="insert_row"},(0,f.inherit)(n.CreateRowAction,n.Action),n.CreateRowAction.prototype.undo=function(e,t){var o=e.countRows(),n=e.getSettings().minSpareRows;this.index>=o&&o>this.index-n&&(this.index-=n),e.addHookOnce("afterRemoveRow",t),e.alter("remove_row",this.index,this.amount,"UndoRedo.undo")},n.CreateRowAction.prototype.redo=function(e,t){e.addHookOnce("afterCreateRow",t),e.alter("insert_row",this.index,this.amount,"UndoRedo.redo")},n.RemoveRowAction=function(e,t){this.index=e,this.data=t,this.actionType="remove_row"},(0,f.inherit)(n.RemoveRowAction,n.Action),n.RemoveRowAction.prototype.undo=function(e,t){e.alter("insert_row",this.index,this.data.length,"UndoRedo.undo"),e.addHookOnce("afterRender",t),e.populateFromArray(this.index,0,this.data,void 0,void 0,"UndoRedo.undo")},n.RemoveRowAction.prototype.redo=function(e,t){e.addHookOnce("afterRemoveRow",t),e.alter("remove_row",this.index,this.data.length,"UndoRedo.redo")},n.CreateColumnAction=function(e,t){this.index=e,this.amount=t,this.actionType="insert_col"},(0,f.inherit)(n.CreateColumnAction,n.Action),n.CreateColumnAction.prototype.undo=function(e,t){e.addHookOnce("afterRemoveCol",t),e.alter("remove_col",this.index,this.amount,"UndoRedo.undo")},n.CreateColumnAction.prototype.redo=function(e,t){e.addHookOnce("afterCreateCol",t),e.alter("insert_col",this.index,this.amount,"UndoRedo.redo")},n.RemoveColumnAction=function(e,t,o,n,r){this.index=e,this.indexes=t,this.data=o,this.amount=this.data[0].length,this.headers=n,this.columnPositions=r.slice(0),this.actionType="remove_col"},(0,f.inherit)(n.RemoveColumnAction,n.Action),n.RemoveColumnAction.prototype.undo=function(e,t){var o=this,n=void 0,r=this.indexes.slice(0).sort(),i=function(e,t,n){return n[o.indexes.indexOf(r[t])]},s=[];(0,d.rangeEach)(this.data.length-1,function(e){s[e]=(0,h.arrayMap)(o.data[e],i)});var l=[];l=(0,h.arrayMap)(this.headers,i);var a=[];e.runHooks("beforeCreateCol",this.indexes[0],this.indexes[this.indexes.length-1],"UndoRedo.undo"),(0,d.rangeEach)(this.data.length-1,function(t){n=e.getSourceDataAtRow(t),(0,d.rangeEach)(r.length-1,function(e){n.splice(r[e],0,s[t][e]),a.push([t,r[e],null,s[t][e]])})}),e.getPlugin("formulas")&&e.getPlugin("formulas").onAfterSetDataAtCell(a),void 0!==this.headers&&(0,d.rangeEach)(l.length-1,function(t){e.getSettings().colHeaders.splice(r[t],0,l[t])}),e.getPlugin("manualColumnMove")&&(e.getPlugin("manualColumnMove").columnsMapper.__arrayMap=this.columnPositions),e.addHookOnce("afterRender",t),e.runHooks("afterCreateCol",this.indexes[0],this.indexes[this.indexes.length-1],"UndoRedo.undo"),e.getPlugin("formulas")&&e.getPlugin("formulas").recalculateFull(),e.render()},n.RemoveColumnAction.prototype.redo=function(e,t){e.addHookOnce("afterRemoveCol",t),e.alter("remove_col",this.index,this.amount,"UndoRedo.redo")},n.CellAlignmentAction=function(e,t,o,n){this.stateBefore=e,this.range=t,this.type=o,this.alignment=n},n.CellAlignmentAction.prototype.undo=function(e,t){if(e.getPlugin("contextMenu").isEnabled()){for(var o=this.range.from.row;this.range.to.row>=o;o++)for(var n=this.range.from.col;this.range.to.col>=n;n++)e.setCellMeta(o,n,"className",this.stateBefore[o][n]||" htLeft");e.addHookOnce("afterRender",t),e.render()}},n.CellAlignmentAction.prototype.redo=function(e,t){e.getPlugin("contextMenu").isEnabled()&&(e.selectCell(this.range.from.row,this.range.from.col,this.range.to.row,this.range.to.col),e.getPlugin("contextMenu").executeCommand("alignment:"+this.alignment.replace("ht","").toLowerCase()),e.addHookOnce("afterRender",t),e.render())},n.FiltersAction=function(e){this.conditionsStack=e,this.actionType="filter"},(0,f.inherit)(n.FiltersAction,n.Action),n.FiltersAction.prototype.undo=function(e,t){var o=e.getPlugin("filters");e.addHookOnce("afterRender",t),o.conditionCollection.importAllConditions(this.conditionsStack.slice(0,this.conditionsStack.length-1)),o.filter()},n.FiltersAction.prototype.redo=function(e,t){var o=e.getPlugin("filters");e.addHookOnce("afterRender",t),o.conditionCollection.importAllConditions(this.conditionsStack),o.filter()},n.RowMoveAction=function(e,t){this.rows=e.slice(),this.target=t},(0,f.inherit)(n.RowMoveAction,n.Action),n.RowMoveAction.prototype.undo=function(e,t){var o=e.getPlugin("manualRowMove");e.addHookOnce("afterRender",t);for(var n=this.target>this.rows[0]?-1*this.rows.length:0,r=this.rows[0]>this.target?this.rows[0]+this.rows.length:this.rows[0],i=[],s=this.rows.length+n,l=n;s>l;l++)i.push(this.target+l);o.moveRows(i.slice(),r),e.render(),e.selection.setRangeStartOnly(new g.CellCoords(this.rows[0],0)),e.selection.setRangeEnd(new g.CellCoords(this.rows[this.rows.length-1],e.countCols()-1))},n.RowMoveAction.prototype.redo=function(e,t){var o=e.getPlugin("manualRowMove");e.addHookOnce("afterRender",t),o.moveRows(this.rows.slice(),this.target),e.render();var n=this.target>this.rows[0]?this.target-this.rows.length:this.target;e.selection.setRangeStartOnly(new g.CellCoords(n,0)),e.selection.setRangeEnd(new g.CellCoords(n+this.rows.length-1,e.countCols()-1))};var v=c.default.getSingleton();v.add("afterInit",r),v.add("afterUpdateSettings",r),v.register("beforeUndo"),v.register("afterUndo"),v.register("beforeRedo"),v.register("afterRedo")}]).default});
|