Skip to content

Instantly share code, notes, and snippets.

@timelyportfolio
Last active June 5, 2018 11:38
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save timelyportfolio/8921acd5236418278b5899e14745788c to your computer and use it in GitHub Desktop.
Save timelyportfolio/8921acd5236418278b5899e14745788c to your computer and use it in GitHub Desktop.
rhandsontable widget with JavaScript calc
license: mit

handsontable pro version allows formula-based cells similar to Excel. With the R htmlwidget rhandsontable we might want similar functionality with the calculations staying within JavaScript. Here is a very simple example to make a totals row.

library(rhandsontable)

# create some quick data to test and append a row for totals
dat <- rbind(
  head(mtcars,10),
  # sum doesn't really make sense for the total but use
  #  in this example as an aggregate function
  lapply(head(mtcars,10), sum)
)
rownames(dat)[11] <- "Totals"

rht <- rhandsontable(dat) %>%
  # make totals row readOnly to prevent user from overwriting
  hot_row(11, readOnly = TRUE)

htmlwidgets::onRender(
  rht,
"
function(el, x) {
  var hot = this.hot
  hot.addHook(
    'afterChange',
    function(changes, source) {
      if(source === 'edit') {
        //debugger
        changes.forEach(function(change) {
          var sum = hot.getData(0,change[1],9,change[1]).map(
              function(d){ return parseFloat(d[0]) || 0 }
            ).reduce(
            // simple reduce to calculate sum
            function(left,right) {
              return left + right
            },
            0
          )
          hot.setDataAtCell(10, change[1], sum, 'calculate') // make sure to specify 'calculate' so no infinte loop
        })
      }
    }
  )
}
"
)
This file has been truncated, but you can view the full file.
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<title>rhandsontable</title>
<script>(function() {
// If window.HTMLWidgets is already defined, then use it; otherwise create a
// new object. This allows preceding code to set options that affect the
// initialization process (though none currently exist).
window.HTMLWidgets = window.HTMLWidgets || {};
// See if we're running in a viewer pane. If not, we're in a web browser.
var viewerMode = window.HTMLWidgets.viewerMode =
/\bviewer_pane=1\b/.test(window.location);
// See if we're running in Shiny mode. If not, it's a static document.
// Note that static widgets can appear in both Shiny and static modes, but
// obviously, Shiny widgets can only appear in Shiny apps/documents.
var shinyMode = window.HTMLWidgets.shinyMode =
typeof(window.Shiny) !== "undefined" && !!window.Shiny.outputBindings;
// We can't count on jQuery being available, so we implement our own
// version if necessary.
function querySelectorAll(scope, selector) {
if (typeof(jQuery) !== "undefined" && scope instanceof jQuery) {
return scope.find(selector);
}
if (scope.querySelectorAll) {
return scope.querySelectorAll(selector);
}
}
function asArray(value) {
if (value === null)
return [];
if ($.isArray(value))
return value;
return [value];
}
// Implement jQuery's extend
function extend(target /*, ... */) {
if (arguments.length == 1) {
return target;
}
for (var i = 1; i < arguments.length; i++) {
var source = arguments[i];
for (var prop in source) {
if (source.hasOwnProperty(prop)) {
target[prop] = source[prop];
}
}
}
return target;
}
// IE8 doesn't support Array.forEach.
function forEach(values, callback, thisArg) {
if (values.forEach) {
values.forEach(callback, thisArg);
} else {
for (var i = 0; i < values.length; i++) {
callback.call(thisArg, values[i], i, values);
}
}
}
// Replaces the specified method with the return value of funcSource.
//
// Note that funcSource should not BE the new method, it should be a function
// that RETURNS the new method. funcSource receives a single argument that is
// the overridden method, it can be called from the new method. The overridden
// method can be called like a regular function, it has the target permanently
// bound to it so "this" will work correctly.
function overrideMethod(target, methodName, funcSource) {
var superFunc = target[methodName] || function() {};
var superFuncBound = function() {
return superFunc.apply(target, arguments);
};
target[methodName] = funcSource(superFuncBound);
}
// Add a method to delegator that, when invoked, calls
// delegatee.methodName. If there is no such method on
// the delegatee, but there was one on delegator before
// delegateMethod was called, then the original version
// is invoked instead.
// For example:
//
// var a = {
// method1: function() { console.log('a1'); }
// method2: function() { console.log('a2'); }
// };
// var b = {
// method1: function() { console.log('b1'); }
// };
// delegateMethod(a, b, "method1");
// delegateMethod(a, b, "method2");
// a.method1();
// a.method2();
//
// The output would be "b1", "a2".
function delegateMethod(delegator, delegatee, methodName) {
var inherited = delegator[methodName];
delegator[methodName] = function() {
var target = delegatee;
var method = delegatee[methodName];
// The method doesn't exist on the delegatee. Instead,
// call the method on the delegator, if it exists.
if (!method) {
target = delegator;
method = inherited;
}
if (method) {
return method.apply(target, arguments);
}
};
}
// Implement a vague facsimilie of jQuery's data method
function elementData(el, name, value) {
if (arguments.length == 2) {
return el["htmlwidget_data_" + name];
} else if (arguments.length == 3) {
el["htmlwidget_data_" + name] = value;
return el;
} else {
throw new Error("Wrong number of arguments for elementData: " +
arguments.length);
}
}
// http://stackoverflow.com/questions/3446170/escape-string-for-use-in-javascript-regex
function escapeRegExp(str) {
return str.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g, "\\$&");
}
function hasClass(el, className) {
var re = new RegExp("\\b" + escapeRegExp(className) + "\\b");
return re.test(el.className);
}
// elements - array (or array-like object) of HTML elements
// className - class name to test for
// include - if true, only return elements with given className;
// if false, only return elements *without* given className
function filterByClass(elements, className, include) {
var results = [];
for (var i = 0; i < elements.length; i++) {
if (hasClass(elements[i], className) == include)
results.push(elements[i]);
}
return results;
}
function on(obj, eventName, func) {
if (obj.addEventListener) {
obj.addEventListener(eventName, func, false);
} else if (obj.attachEvent) {
obj.attachEvent(eventName, func);
}
}
function off(obj, eventName, func) {
if (obj.removeEventListener)
obj.removeEventListener(eventName, func, false);
else if (obj.detachEvent) {
obj.detachEvent(eventName, func);
}
}
// Translate array of values to top/right/bottom/left, as usual with
// the "padding" CSS property
// https://developer.mozilla.org/en-US/docs/Web/CSS/padding
function unpackPadding(value) {
if (typeof(value) === "number")
value = [value];
if (value.length === 1) {
return {top: value[0], right: value[0], bottom: value[0], left: value[0]};
}
if (value.length === 2) {
return {top: value[0], right: value[1], bottom: value[0], left: value[1]};
}
if (value.length === 3) {
return {top: value[0], right: value[1], bottom: value[2], left: value[1]};
}
if (value.length === 4) {
return {top: value[0], right: value[1], bottom: value[2], left: value[3]};
}
}
// Convert an unpacked padding object to a CSS value
function paddingToCss(paddingObj) {
return paddingObj.top + "px " + paddingObj.right + "px " + paddingObj.bottom + "px " + paddingObj.left + "px";
}
// Makes a number suitable for CSS
function px(x) {
if (typeof(x) === "number")
return x + "px";
else
return x;
}
// Retrieves runtime widget sizing information for an element.
// The return value is either null, or an object with fill, padding,
// defaultWidth, defaultHeight fields.
function sizingPolicy(el) {
var sizingEl = document.querySelector("script[data-for='" + el.id + "'][type='application/htmlwidget-sizing']");
if (!sizingEl)
return null;
var sp = JSON.parse(sizingEl.textContent || sizingEl.text || "{}");
if (viewerMode) {
return sp.viewer;
} else {
return sp.browser;
}
}
// @param tasks Array of strings (or falsy value, in which case no-op).
// Each element must be a valid JavaScript expression that yields a
// function. Or, can be an array of objects with "code" and "data"
// properties; in this case, the "code" property should be a string
// of JS that's an expr that yields a function, and "data" should be
// an object that will be added as an additional argument when that
// function is called.
// @param target The object that will be "this" for each function
// execution.
// @param args Array of arguments to be passed to the functions. (The
// same arguments will be passed to all functions.)
function evalAndRun(tasks, target, args) {
if (tasks) {
forEach(tasks, function(task) {
var theseArgs = args;
if (typeof(task) === "object") {
theseArgs = theseArgs.concat([task.data]);
task = task.code;
}
var taskFunc = eval("(" + task + ")");
if (typeof(taskFunc) !== "function") {
throw new Error("Task must be a function! Source:\n" + task);
}
taskFunc.apply(target, theseArgs);
});
}
}
function initSizing(el) {
var sizing = sizingPolicy(el);
if (!sizing)
return;
var cel = document.getElementById("htmlwidget_container");
if (!cel)
return;
if (typeof(sizing.padding) !== "undefined") {
document.body.style.margin = "0";
document.body.style.padding = paddingToCss(unpackPadding(sizing.padding));
}
if (sizing.fill) {
document.body.style.overflow = "hidden";
document.body.style.width = "100%";
document.body.style.height = "100%";
document.documentElement.style.width = "100%";
document.documentElement.style.height = "100%";
if (cel) {
cel.style.position = "absolute";
var pad = unpackPadding(sizing.padding);
cel.style.top = pad.top + "px";
cel.style.right = pad.right + "px";
cel.style.bottom = pad.bottom + "px";
cel.style.left = pad.left + "px";
el.style.width = "100%";
el.style.height = "100%";
}
return {
getWidth: function() { return cel.offsetWidth; },
getHeight: function() { return cel.offsetHeight; }
};
} else {
el.style.width = px(sizing.width);
el.style.height = px(sizing.height);
return {
getWidth: function() { return el.offsetWidth; },
getHeight: function() { return el.offsetHeight; }
};
}
}
// Default implementations for methods
var defaults = {
find: function(scope) {
return querySelectorAll(scope, "." + this.name);
},
renderError: function(el, err) {
var $el = $(el);
this.clearError(el);
// Add all these error classes, as Shiny does
var errClass = "shiny-output-error";
if (err.type !== null) {
// use the classes of the error condition as CSS class names
errClass = errClass + " " + $.map(asArray(err.type), function(type) {
return errClass + "-" + type;
}).join(" ");
}
errClass = errClass + " htmlwidgets-error";
// Is el inline or block? If inline or inline-block, just display:none it
// and add an inline error.
var display = $el.css("display");
$el.data("restore-display-mode", display);
if (display === "inline" || display === "inline-block") {
$el.hide();
if (err.message !== "") {
var errorSpan = $("<span>").addClass(errClass);
errorSpan.text(err.message);
$el.after(errorSpan);
}
} else if (display === "block") {
// If block, add an error just after the el, set visibility:none on the
// el, and position the error to be on top of the el.
// Mark it with a unique ID and CSS class so we can remove it later.
$el.css("visibility", "hidden");
if (err.message !== "") {
var errorDiv = $("<div>").addClass(errClass).css("position", "absolute")
.css("top", el.offsetTop)
.css("left", el.offsetLeft)
// setting width can push out the page size, forcing otherwise
// unnecessary scrollbars to appear and making it impossible for
// the element to shrink; so use max-width instead
.css("maxWidth", el.offsetWidth)
.css("height", el.offsetHeight);
errorDiv.text(err.message);
$el.after(errorDiv);
// Really dumb way to keep the size/position of the error in sync with
// the parent element as the window is resized or whatever.
var intId = setInterval(function() {
if (!errorDiv[0].parentElement) {
clearInterval(intId);
return;
}
errorDiv
.css("top", el.offsetTop)
.css("left", el.offsetLeft)
.css("maxWidth", el.offsetWidth)
.css("height", el.offsetHeight);
}, 500);
}
}
},
clearError: function(el) {
var $el = $(el);
var display = $el.data("restore-display-mode");
$el.data("restore-display-mode", null);
if (display === "inline" || display === "inline-block") {
if (display)
$el.css("display", display);
$(el.nextSibling).filter(".htmlwidgets-error").remove();
} else if (display === "block"){
$el.css("visibility", "inherit");
$(el.nextSibling).filter(".htmlwidgets-error").remove();
}
},
sizing: {}
};
// Called by widget bindings to register a new type of widget. The definition
// object can contain the following properties:
// - name (required) - A string indicating the binding name, which will be
// used by default as the CSS classname to look for.
// - initialize (optional) - A function(el) that will be called once per
// widget element; if a value is returned, it will be passed as the third
// value to renderValue.
// - renderValue (required) - A function(el, data, initValue) that will be
// called with data. Static contexts will cause this to be called once per
// element; Shiny apps will cause this to be called multiple times per
// element, as the data changes.
window.HTMLWidgets.widget = function(definition) {
if (!definition.name) {
throw new Error("Widget must have a name");
}
if (!definition.type) {
throw new Error("Widget must have a type");
}
// Currently we only support output widgets
if (definition.type !== "output") {
throw new Error("Unrecognized widget type '" + definition.type + "'");
}
// TODO: Verify that .name is a valid CSS classname
// Support new-style instance-bound definitions. Old-style class-bound
// definitions have one widget "object" per widget per type/class of
// widget; the renderValue and resize methods on such widget objects
// take el and instance arguments, because the widget object can't
// store them. New-style instance-bound definitions have one widget
// object per widget instance; the definition that's passed in doesn't
// provide renderValue or resize methods at all, just the single method
// factory(el, width, height)
// which returns an object that has renderValue(x) and resize(w, h).
// This enables a far more natural programming style for the widget
// author, who can store per-instance state using either OO-style
// instance fields or functional-style closure variables (I guess this
// is in contrast to what can only be called C-style pseudo-OO which is
// what we required before).
if (definition.factory) {
definition = createLegacyDefinitionAdapter(definition);
}
if (!definition.renderValue) {
throw new Error("Widget must have a renderValue function");
}
// For static rendering (non-Shiny), use a simple widget registration
// scheme. We also use this scheme for Shiny apps/documents that also
// contain static widgets.
window.HTMLWidgets.widgets = window.HTMLWidgets.widgets || [];
// Merge defaults into the definition; don't mutate the original definition.
var staticBinding = extend({}, defaults, definition);
overrideMethod(staticBinding, "find", function(superfunc) {
return function(scope) {
var results = superfunc(scope);
// Filter out Shiny outputs, we only want the static kind
return filterByClass(results, "html-widget-output", false);
};
});
window.HTMLWidgets.widgets.push(staticBinding);
if (shinyMode) {
// Shiny is running. Register the definition with an output binding.
// The definition itself will not be the output binding, instead
// we will make an output binding object that delegates to the
// definition. This is because we foolishly used the same method
// name (renderValue) for htmlwidgets definition and Shiny bindings
// but they actually have quite different semantics (the Shiny
// bindings receive data that includes lots of metadata that it
// strips off before calling htmlwidgets renderValue). We can't
// just ignore the difference because in some widgets it's helpful
// to call this.renderValue() from inside of resize(), and if
// we're not delegating, then that call will go to the Shiny
// version instead of the htmlwidgets version.
// Merge defaults with definition, without mutating either.
var bindingDef = extend({}, defaults, definition);
// This object will be our actual Shiny binding.
var shinyBinding = new Shiny.OutputBinding();
// With a few exceptions, we'll want to simply use the bindingDef's
// version of methods if they are available, otherwise fall back to
// Shiny's defaults. NOTE: If Shiny's output bindings gain additional
// methods in the future, and we want them to be overrideable by
// HTMLWidget binding definitions, then we'll need to add them to this
// list.
delegateMethod(shinyBinding, bindingDef, "getId");
delegateMethod(shinyBinding, bindingDef, "onValueChange");
delegateMethod(shinyBinding, bindingDef, "onValueError");
delegateMethod(shinyBinding, bindingDef, "renderError");
delegateMethod(shinyBinding, bindingDef, "clearError");
delegateMethod(shinyBinding, bindingDef, "showProgress");
// The find, renderValue, and resize are handled differently, because we
// want to actually decorate the behavior of the bindingDef methods.
shinyBinding.find = function(scope) {
var results = bindingDef.find(scope);
// Only return elements that are Shiny outputs, not static ones
var dynamicResults = results.filter(".html-widget-output");
// It's possible that whatever caused Shiny to think there might be
// new dynamic outputs, also caused there to be new static outputs.
// Since there might be lots of different htmlwidgets bindings, we
// schedule execution for later--no need to staticRender multiple
// times.
if (results.length !== dynamicResults.length)
scheduleStaticRender();
return dynamicResults;
};
// Wrap renderValue to handle initialization, which unfortunately isn't
// supported natively by Shiny at the time of this writing.
shinyBinding.renderValue = function(el, data) {
Shiny.renderDependencies(data.deps);
// Resolve strings marked as javascript literals to objects
if (!(data.evals instanceof Array)) data.evals = [data.evals];
for (var i = 0; data.evals && i < data.evals.length; i++) {
window.HTMLWidgets.evaluateStringMember(data.x, data.evals[i]);
}
if (!bindingDef.renderOnNullValue) {
if (data.x === null) {
el.style.visibility = "hidden";
return;
} else {
el.style.visibility = "inherit";
}
}
if (!elementData(el, "initialized")) {
initSizing(el);
elementData(el, "initialized", true);
if (bindingDef.initialize) {
var result = bindingDef.initialize(el, el.offsetWidth,
el.offsetHeight);
elementData(el, "init_result", result);
}
}
bindingDef.renderValue(el, data.x, elementData(el, "init_result"));
evalAndRun(data.jsHooks.render, elementData(el, "init_result"), [el, data.x]);
};
// Only override resize if bindingDef implements it
if (bindingDef.resize) {
shinyBinding.resize = function(el, width, height) {
// Shiny can call resize before initialize/renderValue have been
// called, which doesn't make sense for widgets.
if (elementData(el, "initialized")) {
bindingDef.resize(el, width, height, elementData(el, "init_result"));
}
};
}
Shiny.outputBindings.register(shinyBinding, bindingDef.name);
}
};
var scheduleStaticRenderTimerId = null;
function scheduleStaticRender() {
if (!scheduleStaticRenderTimerId) {
scheduleStaticRenderTimerId = setTimeout(function() {
scheduleStaticRenderTimerId = null;
window.HTMLWidgets.staticRender();
}, 1);
}
}
// Render static widgets after the document finishes loading
// Statically render all elements that are of this widget's class
window.HTMLWidgets.staticRender = function() {
var bindings = window.HTMLWidgets.widgets || [];
forEach(bindings, function(binding) {
var matches = binding.find(document.documentElement);
forEach(matches, function(el) {
var sizeObj = initSizing(el, binding);
if (hasClass(el, "html-widget-static-bound"))
return;
el.className = el.className + " html-widget-static-bound";
var initResult;
if (binding.initialize) {
initResult = binding.initialize(el,
sizeObj ? sizeObj.getWidth() : el.offsetWidth,
sizeObj ? sizeObj.getHeight() : el.offsetHeight
);
elementData(el, "init_result", initResult);
}
if (binding.resize) {
var lastSize = {};
var resizeHandler = function(e) {
var size = {
w: sizeObj ? sizeObj.getWidth() : el.offsetWidth,
h: sizeObj ? sizeObj.getHeight() : el.offsetHeight
};
if (size.w === 0 && size.h === 0)
return;
if (size.w === lastSize.w && size.h === lastSize.h)
return;
lastSize = size;
binding.resize(el, size.w, size.h, initResult);
};
on(window, "resize", resizeHandler);
// This is needed for cases where we're running in a Shiny
// app, but the widget itself is not a Shiny output, but
// rather a simple static widget. One example of this is
// an rmarkdown document that has runtime:shiny and widget
// that isn't in a render function. Shiny only knows to
// call resize handlers for Shiny outputs, not for static
// widgets, so we do it ourselves.
if (window.jQuery) {
window.jQuery(document).on(
"shown.htmlwidgets shown.bs.tab.htmlwidgets shown.bs.collapse.htmlwidgets",
resizeHandler
);
window.jQuery(document).on(
"hidden.htmlwidgets hidden.bs.tab.htmlwidgets hidden.bs.collapse.htmlwidgets",
resizeHandler
);
}
// This is needed for the specific case of ioslides, which
// flips slides between display:none and display:block.
// Ideally we would not have to have ioslide-specific code
// here, but rather have ioslides raise a generic event,
// but the rmarkdown package just went to CRAN so the
// window to getting that fixed may be long.
if (window.addEventListener) {
// It's OK to limit this to window.addEventListener
// browsers because ioslides itself only supports
// such browsers.
on(document, "slideenter", resizeHandler);
on(document, "slideleave", resizeHandler);
}
}
var scriptData = document.querySelector("script[data-for='" + el.id + "'][type='application/json']");
if (scriptData) {
var data = JSON.parse(scriptData.textContent || scriptData.text);
// Resolve strings marked as javascript literals to objects
if (!(data.evals instanceof Array)) data.evals = [data.evals];
for (var k = 0; data.evals && k < data.evals.length; k++) {
window.HTMLWidgets.evaluateStringMember(data.x, data.evals[k]);
}
binding.renderValue(el, data.x, initResult);
evalAndRun(data.jsHooks.render, initResult, [el, data.x]);
}
});
});
invokePostRenderHandlers();
}
// Wait until after the document has loaded to render the widgets.
if (document.addEventListener) {
document.addEventListener("DOMContentLoaded", function() {
document.removeEventListener("DOMContentLoaded", arguments.callee, false);
window.HTMLWidgets.staticRender();
}, false);
} else if (document.attachEvent) {
document.attachEvent("onreadystatechange", function() {
if (document.readyState === "complete") {
document.detachEvent("onreadystatechange", arguments.callee);
window.HTMLWidgets.staticRender();
}
});
}
window.HTMLWidgets.getAttachmentUrl = function(depname, key) {
// If no key, default to the first item
if (typeof(key) === "undefined")
key = 1;
var link = document.getElementById(depname + "-" + key + "-attachment");
if (!link) {
throw new Error("Attachment " + depname + "/" + key + " not found in document");
}
return link.getAttribute("href");
};
window.HTMLWidgets.dataframeToD3 = function(df) {
var names = [];
var length;
for (var name in df) {
if (df.hasOwnProperty(name))
names.push(name);
if (typeof(df[name]) !== "object" || typeof(df[name].length) === "undefined") {
throw new Error("All fields must be arrays");
} else if (typeof(length) !== "undefined" && length !== df[name].length) {
throw new Error("All fields must be arrays of the same length");
}
length = df[name].length;
}
var results = [];
var item;
for (var row = 0; row < length; row++) {
item = {};
for (var col = 0; col < names.length; col++) {
item[names[col]] = df[names[col]][row];
}
results.push(item);
}
return results;
};
window.HTMLWidgets.transposeArray2D = function(array) {
if (array.length === 0) return array;
var newArray = array[0].map(function(col, i) {
return array.map(function(row) {
return row[i]
})
});
return newArray;
};
// Split value at splitChar, but allow splitChar to be escaped
// using escapeChar. Any other characters escaped by escapeChar
// will be included as usual (including escapeChar itself).
function splitWithEscape(value, splitChar, escapeChar) {
var results = [];
var escapeMode = false;
var currentResult = "";
for (var pos = 0; pos < value.length; pos++) {
if (!escapeMode) {
if (value[pos] === splitChar) {
results.push(currentResult);
currentResult = "";
} else if (value[pos] === escapeChar) {
escapeMode = true;
} else {
currentResult += value[pos];
}
} else {
currentResult += value[pos];
escapeMode = false;
}
}
if (currentResult !== "") {
results.push(currentResult);
}
return results;
}
// Function authored by Yihui/JJ Allaire
window.HTMLWidgets.evaluateStringMember = function(o, member) {
var parts = splitWithEscape(member, '.', '\\');
for (var i = 0, l = parts.length; i < l; i++) {
var part = parts[i];
// part may be a character or 'numeric' member name
if (o !== null && typeof o === "object" && part in o) {
if (i == (l - 1)) { // if we are at the end of the line then evalulate
if (typeof o[part] === "string")
o[part] = eval("(" + o[part] + ")");
} else { // otherwise continue to next embedded object
o = o[part];
}
}
}
};
// Retrieve the HTMLWidget instance (i.e. the return value of an
// HTMLWidget binding's initialize() or factory() function)
// associated with an element, or null if none.
window.HTMLWidgets.getInstance = function(el) {
return elementData(el, "init_result");
};
// Finds the first element in the scope that matches the selector,
// and returns the HTMLWidget instance (i.e. the return value of
// an HTMLWidget binding's initialize() or factory() function)
// associated with that element, if any. If no element matches the
// selector, or the first matching element has no HTMLWidget
// instance associated with it, then null is returned.
//
// The scope argument is optional, and defaults to window.document.
window.HTMLWidgets.find = function(scope, selector) {
if (arguments.length == 1) {
selector = scope;
scope = document;
}
var el = scope.querySelector(selector);
if (el === null) {
return null;
} else {
return window.HTMLWidgets.getInstance(el);
}
};
// Finds all elements in the scope that match the selector, and
// returns the HTMLWidget instances (i.e. the return values of
// an HTMLWidget binding's initialize() or factory() function)
// associated with the elements, in an array. If elements that
// match the selector don't have an associated HTMLWidget
// instance, the returned array will contain nulls.
//
// The scope argument is optional, and defaults to window.document.
window.HTMLWidgets.findAll = function(scope, selector) {
if (arguments.length == 1) {
selector = scope;
scope = document;
}
var nodes = scope.querySelectorAll(selector);
var results = [];
for (var i = 0; i < nodes.length; i++) {
results.push(window.HTMLWidgets.getInstance(nodes[i]));
}
return results;
};
var postRenderHandlers = [];
function invokePostRenderHandlers() {
while (postRenderHandlers.length) {
var handler = postRenderHandlers.shift();
if (handler) {
handler();
}
}
}
// Register the given callback function to be invoked after the
// next time static widgets are rendered.
window.HTMLWidgets.addPostRenderHandler = function(callback) {
postRenderHandlers.push(callback);
};
// Takes a new-style instance-bound definition, and returns an
// old-style class-bound definition. This saves us from having
// to rewrite all the logic in this file to accomodate both
// types of definitions.
function createLegacyDefinitionAdapter(defn) {
var result = {
name: defn.name,
type: defn.type,
initialize: function(el, width, height) {
return defn.factory(el, width, height);
},
renderValue: function(el, x, instance) {
return instance.renderValue(x);
},
resize: function(el, width, height, instance) {
return instance.resize(width, height);
}
};
if (defn.find)
result.find = defn.find;
if (defn.renderError)
result.renderError = defn.renderError;
if (defn.clearError)
result.clearError = defn.clearError;
return result;
}
})();
</script>
<style type="text/css">@charset "UTF-8";
.handsontable .table td,.handsontable .table th{border-top:none}.handsontable tr{background:#fff}.handsontable td{background-color:inherit}.handsontable .table caption+thead tr:first-child td,.handsontable .table caption+thead tr:first-child th,.handsontable .table colgroup+thead tr:first-child td,.handsontable .table colgroup+thead tr:first-child th,.handsontable .table thead:first-child tr:first-child td,.handsontable .table thead:first-child tr:first-child th{border-top:1px solid #ccc}.handsontable .table-bordered{border:0;border-collapse:separate}.handsontable .table-bordered td,.handsontable .table-bordered th{border-left:none}.handsontable .table-bordered td:first-child,.handsontable .table-bordered th:first-child{border-left:1px solid #ccc}.handsontable .table>tbody>tr>td,.handsontable .table>tbody>tr>th,.handsontable .table>tfoot>tr>td,.handsontable .table>tfoot>tr>th,.handsontable .table>thead>tr>td,.handsontable .table>thead>tr>th{line-height:21px;padding:0 4px}.col-lg-1.handsontable,.col-lg-2.handsontable,.col-lg-3.handsontable,.col-lg-4.handsontable,.col-lg-5.handsontable,.col-lg-6.handsontable,.col-lg-7.handsontable,.col-lg-8.handsontable,.col-lg-9.handsontable,.col-lg-10.handsontable,.col-lg-11.handsontable,.col-lg-12.handsontable,.col-md-1.handsontable,.col-md-2.handsontable,.col-md-3.handsontable,.col-md-4.handsontable,.col-md-5.handsontable,.col-md-6.handsontable,.col-md-7.handsontable,.col-md-8.handsontable,.col-md-9.handsontable .col-sm-1.handsontable,.col-md-10.handsontable,.col-md-11.handsontable,.col-md-12.handsontable,.col-sm-2.handsontable,.col-sm-3.handsontable,.col-sm-4.handsontable,.col-sm-5.handsontable,.col-sm-6.handsontable,.col-sm-7.handsontable,.col-sm-8.handsontable,.col-sm-9.handsontable .col-xs-1.handsontable,.col-sm-10.handsontable,.col-sm-11.handsontable,.col-sm-12.handsontable,.col-xs-2.handsontable,.col-xs-3.handsontable,.col-xs-4.handsontable,.col-xs-5.handsontable,.col-xs-6.handsontable,.col-xs-7.handsontable,.col-xs-8.handsontable,.col-xs-9.handsontable,.col-xs-10.handsontable,.col-xs-11.handsontable,.col-xs-12.handsontable{padding-left:0;padding-right:0}.handsontable .table-striped>tbody>tr:nth-of-type(2n){background-color:#fff}.handsontable{position:relative}.handsontable .hide{display:none}.handsontable .relative{position:relative}.handsontable.htAutoSize{visibility:hidden;left:-99000px;position:absolute;top:-99000px}.handsontable .wtHider{width:0}.handsontable .wtSpreader{position:relative;width:0;height:auto}.handsontable div,.handsontable input,.handsontable table,.handsontable tbody,.handsontable td,.handsontable textarea,.handsontable th,.handsontable thead{box-sizing:content-box;-webkit-box-sizing:content-box;-moz-box-sizing:content-box}.handsontable input,.handsontable textarea{min-height:0}.handsontable table.htCore{border-collapse:separate;border-spacing:0;margin:0;border-width:0;table-layout:fixed;width:0;outline-width:0;max-width:none;max-height:none}.handsontable col,.handsontable col.rowHeader{width:50px}.handsontable td,.handsontable th{border-top-width:0;border-left-width:0;border-right:1px solid #ccc;border-bottom:1px solid #ccc;height:22px;empty-cells:show;line-height:21px;padding:0 4px;background-color:#fff;vertical-align:top;overflow:hidden;outline-width:0;white-space:pre-line;background-clip:padding-box}.handsontable td.htInvalid{background-color:#ff4c42!important}.handsontable td.htNoWrap{white-space:nowrap}.handsontable th:last-child{border-right:1px solid #ccc;border-bottom:1px solid #ccc}.handsontable th.htNoFrame,.handsontable th:first-child.htNoFrame,.handsontable tr:first-child th.htNoFrame{border-left-width:0;background-color:#fff;border-color:#fff}.handsontable .htNoFrame+td,.handsontable .htNoFrame+th,.handsontable.htRowHeaders thead tr th:nth-child(2),.handsontable td:first-of-type,.handsontable th:first-child,.handsontable th:nth-child(2){border-left:1px solid #ccc}.handsontable tr:first-child td,.handsontable tr:first-child th{border-top:1px solid #ccc}.ht_master:not(.innerBorderLeft):not(.emptyColumns)~.handsontable:not(.ht_clone_top) thead tr th:first-child,.ht_master:not(.innerBorderLeft):not(.emptyColumns)~.handsontable tbody tr th{border-right-width:0}.ht_master:not(.innerBorderTop) thead tr.lastChild th,.ht_master:not(.innerBorderTop) thead tr:last-child th,.ht_master:not(.innerBorderTop)~.handsontable thead tr.lastChild th,.ht_master:not(.innerBorderTop)~.handsontable thead tr:last-child th{border-bottom-width:0}.handsontable th{background-color:#f3f3f3;color:#222;text-align:center;font-weight:400;white-space:nowrap}.handsontable thead th{padding:0}.handsontable th.active{background-color:#ccc}.handsontable thead th .relative{padding:2px 4px}.handsontable tbody th.ht__highlight,.handsontable thead th.ht__highlight{background-color:#dcdcdc}.handsontable.ht__selection--columns thead th.ht__highlight,.handsontable.ht__selection--rows tbody th.ht__highlight{background-color:#8eb0e7;color:#000}#hot-display-license-info{font-size:9px;color:#323232;padding:5px 0 3px;font-family:Helvetica,Arial,sans-serif;text-align:left}.handsontable .manualColumnResizer{position:fixed;top:0;cursor:col-resize;z-index:6;width:5px;height:25px}.handsontable .manualRowResizer{position:fixed;left:0;cursor:row-resize;z-index:6;height:5px;width:50px}.handsontable .manualColumnResizer.active,.handsontable .manualColumnResizer:hover,.handsontable .manualRowResizer.active,.handsontable .manualRowResizer:hover{background-color:#aab}.handsontable .manualColumnResizerGuide{position:fixed;right:0;top:0;background-color:#aab;display:none;width:0;border-right:1px dashed #777;margin-left:5px}.handsontable .manualRowResizerGuide{position:fixed;left:0;bottom:0;background-color:#aab;display:none;height:0;border-bottom:1px dashed #777;margin-top:5px}.handsontable .manualColumnResizerGuide.active,.handsontable .manualRowResizerGuide.active{display:block;z-index:7}.handsontable .columnSorting{position:relative}.handsontable .columnSorting:hover{text-decoration:underline;cursor:pointer}.handsontable .columnSorting.ascending:after{content:"\25B2";color:#5f5f5f;position:absolute;right:-15px}.handsontable .columnSorting.descending:after{content:"\25BC";color:#5f5f5f;position:absolute;right:-15px}.handsontable .wtBorder{position:absolute;font-size:0}.handsontable .wtBorder.hidden{display:none!important}.handsontable td.area{background:linear-gradient(180deg,rgba(181,209,255,.34) 0,rgba(181,209,255,.34));filter:progid:DXImageTransform.Microsoft.gradient(startColorstr="#57b5d1ff",endColorstr="#57b5d1ff",GradientType=0);background-color:#fff}.handsontable .wtBorder.corner{font-size:0;cursor:crosshair}.handsontable .htBorder.htFillBorder{background:red;width:1px;height:1px}.handsontableInput{border:none;outline-width:0;margin:0;padding:1px 5px 0;font-family:inherit;line-height:21px;font-size:inherit;box-shadow:inset 0 0 0 2px #5292f7;resize:none;display:block;color:#000;border-radius:0;background-color:#fff}.handsontableInputHolder{position:absolute;top:0;left:0;z-index:1}.htSelectEditor{-webkit-appearance:menulist-button!important;position:absolute;width:auto}.handsontable .htDimmed{color:#777}.handsontable .htSubmenu{position:relative}.handsontable .htSubmenu :after{content:"\25B6";color:#777;position:absolute;right:5px}.handsontable .htLeft{text-align:left}.handsontable .htCenter{text-align:center}.handsontable .htRight{text-align:right}.handsontable .htJustify{text-align:justify}.handsontable .htTop{vertical-align:top}.handsontable .htMiddle{vertical-align:middle}.handsontable .htBottom{vertical-align:bottom}.handsontable .htPlaceholder{color:#999}.handsontable .htAutocompleteArrow{float:right;font-size:10px;color:#eee;cursor:default;width:16px;text-align:center}.handsontable td .htAutocompleteArrow:hover{color:#777}.handsontable td.area .htAutocompleteArrow{color:#d3d3d3}.handsontable .htCheckboxRendererInput{display:inline-block;vertical-align:middle}.handsontable .htCheckboxRendererInput.noValue{opacity:.5}.handsontable .htCheckboxRendererLabel{cursor:pointer;display:inline-block;width:100%}@-webkit-keyframes a{0%{opacity:1}to{opacity:0}}@keyframes a{0%{opacity:1}to{opacity:0}}@-webkit-keyframes b{0%{opacity:0}to{opacity:1}}@keyframes b{0%{opacity:0}to{opacity:1}}.handsontable .handsontable.ht_clone_top .wtHider{padding:0 0 5px}.handsontable .autocompleteEditor.handsontable{padding-right:17px}.handsontable .autocompleteEditor.handsontable.htMacScroll{padding-right:15px}.handsontable.listbox{margin:0}.handsontable.listbox .ht_master table{border:1px solid #ccc;border-collapse:separate;background:#fff}.handsontable.listbox td,.handsontable.listbox th,.handsontable.listbox tr:first-child td,.handsontable.listbox tr:first-child th,.handsontable.listbox tr:last-child th{border-color:transparent}.handsontable.listbox td,.handsontable.listbox th{white-space:nowrap;text-overflow:ellipsis}.handsontable.listbox td.htDimmed{cursor:default;color:inherit;font-style:inherit}.handsontable.listbox .wtBorder{visibility:hidden}.handsontable.listbox tr:hover td,.handsontable.listbox tr td.current{background:#eee}.ht_clone_top{z-index:2}.ht_clone_left{z-index:3}.ht_clone_bottom_left_corner,.ht_clone_debug,.ht_clone_top_left_corner{z-index:4}.handsontable td.htSearchResult{background:#fcedd9;color:#583707}.htBordered{border-width:1px}.htBordered.htTopBorderSolid{border-top-style:solid;border-top-color:#000}.htBordered.htRightBorderSolid{border-right-style:solid;border-right-color:#000}.htBordered.htBottomBorderSolid{border-bottom-style:solid;border-bottom-color:#000}.htBordered.htLeftBorderSolid{border-left-style:solid;border-left-color:#000}.handsontable tbody tr th:nth-last-child(2){border-right:1px solid #ccc}.handsontable thead tr:nth-last-child(2) th.htGroupIndicatorContainer{border-bottom:1px solid #ccc;padding-bottom:5px}.ht_clone_top_left_corner thead tr th:nth-last-child(2){border-right:1px solid #ccc}.htCollapseButton{width:10px;height:10px;line-height:10px;text-align:center;border-radius:5px;border:1px solid #f3f3f3;box-shadow:1px 1px 3px rgba(0,0,0,.4);cursor:pointer;margin-bottom:3px;position:relative}.htCollapseButton:after{content:"";height:300%;width:1px;display:block;background:#ccc;margin-left:4px;position:absolute;bottom:10px}thead .htCollapseButton{right:5px;position:absolute;top:5px;background:#fff}thead .htCollapseButton:after{height:1px;width:700%;right:10px;top:4px}.handsontable tr th .htExpandButton{position:absolute;width:10px;height:10px;line-height:10px;text-align:center;border-radius:5px;border:1px solid #f3f3f3;box-shadow:1px 1px 3px rgba(0,0,0,.4);cursor:pointer;top:0;display:none}.handsontable thead tr th .htExpandButton{top:5px}.handsontable tr th .htExpandButton.clickable{display:block}.collapsibleIndicator{position:absolute;top:50%;transform:translateY(-50%);right:5px;border:1px solid #a6a6a6;line-height:10px;color:#222;border-radius:10px;font-size:10px;width:10px;height:10px;cursor:pointer;box-shadow:0 0 0 6px #eee;background:#eee}.handsontable col.hidden{width:0!important}.handsontable table tr th.lightRightBorder{border-right:1px solid #e6e6e6}.handsontable tr.hidden,.handsontable tr.hidden td,.handsontable tr.hidden th{display:none}.ht_clone_bottom,.ht_clone_left,.ht_clone_top,.ht_master{overflow:hidden}.ht_master .wtHolder{overflow:auto}.ht_clone_left .wtHolder{overflow-x:hidden;overflow-y:auto}.ht_clone_bottom .wtHolder,.ht_clone_top .wtHolder{overflow-x:auto;overflow-y:hidden}.wtDebugHidden{display:none}.wtDebugVisible{display:block;-webkit-animation-duration:.5s;-webkit-animation-name:c;animation-duration:.5s;animation-name:c}@keyframes c{0%{display:none;opacity:0}1%{display:block;opacity:0}to{display:block;opacity:1}}@-webkit-keyframes c{0%{display:none;opacity:0}1%{display:block;opacity:0}to{display:block;opacity:1}}.handsontable.mobile,.handsontable.mobile .wtHolder{-webkit-touch-callout:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;-webkit-tap-highlight-color:rgba(0,0,0,0);-webkit-overflow-scrolling:touch}.htMobileEditorContainer{display:none;position:absolute;top:0;width:70%;height:54pt;background:#f8f8f8;border-radius:20px;border:1px solid #ebebeb;z-index:8;box-sizing:border-box;-webkit-box-sizing:border-box;-webkit-text-size-adjust:none}.topLeftSelectionHandle-HitArea:not(.ht_master .topLeftSelectionHandle-HitArea),.topLeftSelectionHandle:not(.ht_master .topLeftSelectionHandle){z-index:12}.bottomRightSelectionHandle,.bottomRightSelectionHandle-HitArea,.topLeftSelectionHandle,.topLeftSelectionHandle-HitArea{left:-10000px;top:-10000px}.htMobileEditorContainer.active{display:block}.htMobileEditorContainer .inputs{position:absolute;right:210pt;bottom:10pt;top:10pt;left:14px;height:34pt}.htMobileEditorContainer .inputs textarea{font-size:13pt;border:1px solid #a1a1a1;-webkit-appearance:none;box-shadow:none;position:absolute;left:14px;right:14px;top:0;bottom:0;padding:7pt}.htMobileEditorContainer .cellPointer{position:absolute;top:-13pt;height:0;width:0;left:30px;border-left:13pt solid transparent;border-right:13pt solid transparent;border-bottom:13pt solid #ebebeb}.htMobileEditorContainer .cellPointer.hidden{display:none}.htMobileEditorContainer .cellPointer:before{content:"";display:block;position:absolute;top:2px;height:0;width:0;left:-13pt;border-left:13pt solid transparent;border-right:13pt solid transparent;border-bottom:13pt solid #f8f8f8}.htMobileEditorContainer .moveHandle{position:absolute;top:10pt;left:5px;width:30px;bottom:0;cursor:move;z-index:12}.htMobileEditorContainer .moveHandle:after{content:"..\A..\A..\A..";white-space:pre;line-height:10px;font-size:20pt;display:inline-block;margin-top:-8px;color:#ebebeb}.htMobileEditorContainer .positionControls{width:205pt;position:absolute;right:5pt;top:0;bottom:0}.htMobileEditorContainer .positionControls>div{width:50pt;height:100%;float:left}.htMobileEditorContainer .positionControls>div:after{content:" ";display:block;width:15pt;height:15pt;text-align:center;line-height:50pt}.htMobileEditorContainer .downButton:after,.htMobileEditorContainer .leftButton:after,.htMobileEditorContainer .rightButton:after,.htMobileEditorContainer .upButton:after{transform-origin:5pt 5pt;-webkit-transform-origin:5pt 5pt;margin:21pt 0 0 21pt}.htMobileEditorContainer .leftButton:after{border-top:2px solid #288ffe;border-left:2px solid #288ffe;-webkit-transform:rotate(-45deg)}.htMobileEditorContainer .leftButton:active:after{border-color:#cfcfcf}.htMobileEditorContainer .rightButton:after{border-top:2px solid #288ffe;border-left:2px solid #288ffe;-webkit-transform:rotate(135deg)}.htMobileEditorContainer .rightButton:active:after{border-color:#cfcfcf}.htMobileEditorContainer .upButton:after{border-top:2px solid #288ffe;border-left:2px solid #288ffe;-webkit-transform:rotate(45deg)}.htMobileEditorContainer .upButton:active:after{border-color:#cfcfcf}.htMobileEditorContainer .downButton:after{border-top:2px solid #288ffe;border-left:2px solid #288ffe;-webkit-transform:rotate(225deg)}.htMobileEditorContainer .downButton:active:after{border-color:#cfcfcf}.handsontable.hide-tween{-webkit-animation:a .3s;animation:a .3s;animation-fill-mode:forwards;-webkit-animation-fill-mode:forwards}.handsontable.show-tween{-webkit-animation:b .3s;animation:b .3s;animation-fill-mode:forwards;-webkit-animation-fill-mode:forwards}
.pika-single{z-index:12;display:block;position:relative;color:#333;background:#fff;border:1px solid #ccc;border-bottom-color:#bbb;font-family:Helvetica Neue,Helvetica,Arial,sans-serif}.pika-single:after,.pika-single:before{content:" ";display:table}.pika-single:after{clear:both}.pika-single{*zoom:1}.pika-single.is-hidden{display:none}.pika-single.is-bound{position:absolute;box-shadow:0 5px 15px -5px rgba(0,0,0,.5)}.pika-lendar{float:left;width:240px;margin:8px}.pika-title{position:relative;text-align:center}.pika-label{display:inline-block;*display:inline;position:relative;z-index:12;overflow:hidden;margin:0;padding:5px 3px;font-size:14px;line-height:20px;font-weight:700;background-color:#fff}.pika-title select{cursor:pointer;position:absolute;z-index:11;margin:0;left:0;top:5px;filter:alpha(opacity=0);opacity:0}.pika-next,.pika-prev{display:block;cursor:pointer;position:relative;outline:none;border:0;padding:0;width:20px;height:30px;text-indent:20px;white-space:nowrap;overflow:hidden;background-color:transparent;background-position:50%;background-repeat:no-repeat;background-size:75% 75%;opacity:.5;*position:absolute;*top:0}.pika-next:hover,.pika-prev:hover{opacity:1}.is-rtl .pika-next,.pika-prev{float:left;background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAeCAYAAAAsEj5rAAAAUklEQVR42u3VMQoAIBADQf8Pgj+OD9hG2CtONJB2ymQkKe0HbwAP0xucDiQWARITIDEBEnMgMQ8S8+AqBIl6kKgHiXqQqAeJepBo/z38J/U0uAHlaBkBl9I4GwAAAABJRU5ErkJggg==");*left:0}.is-rtl .pika-prev,.pika-next{float:right;background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAeCAYAAAAsEj5rAAAAU0lEQVR42u3VOwoAMAgE0dwfAnNjU26bYkBCFGwfiL9VVWoO+BJ4Gf3gtsEKKoFBNTCoCAYVwaAiGNQGMUHMkjGbgjk2mIONuXo0nC8XnCf1JXgArVIZAQh5TKYAAAAASUVORK5CYII=");*right:0}.pika-next.is-disabled,.pika-prev.is-disabled{cursor:default;opacity:.2}.pika-select{display:inline-block;*display:inline}.pika-table{width:100%;border-collapse:collapse;border-spacing:0;border:0}.pika-table td,.pika-table th{width:14.285714285714286%;padding:0}.pika-table th{color:#999;font-size:12px;line-height:25px;font-weight:700;text-align:center}.pika-button{cursor:pointer;display:block;box-sizing:border-box;-moz-box-sizing:border-box;outline:none;border:0;margin:0;width:100%;padding:5px;color:#666;font-size:12px;line-height:15px;text-align:right;background:#f5f5f5}.pika-week{font-size:11px;color:#999}.is-today .pika-button{color:#3af;font-weight:700}.is-selected .pika-button{color:#fff;font-weight:700;background:#3af;box-shadow:inset 0 1px 3px #178fe5;border-radius:3px}.is-inrange .pika-button{background:#d5e9f7}.is-startrange .pika-button{color:#fff;background:#6cb31d;box-shadow:none;border-radius:3px}.is-endrange .pika-button{color:#fff;background:#3af;box-shadow:none;border-radius:3px}.is-disabled .pika-button,.is-outside-current-month .pika-button{pointer-events:none;cursor:default;color:#999;opacity:.3}.pika-button:hover{color:#fff;background:#ff8000;box-shadow:none;border-radius:3px}.pika-table abbr{border-bottom:none;cursor:help}.htCommentCell{position:relative}.htCommentCell:after{content:"";position:absolute;top:0;right:0;border-left:6px solid transparent;border-top:6px solid #000}.htComments{display:none;z-index:9;position:absolute}.htCommentTextArea{box-shadow:0 1px 3px rgba(0,0,0,.117647),0 1px 2px rgba(0,0,0,.239216);box-sizing:border-box;border:none;border-left:3px solid #ccc;background-color:#fff;width:215px;height:90px;font-size:12px;padding:5px;outline:0!important;-webkit-appearance:none}.htCommentTextArea:focus{box-shadow:0 1px 3px rgba(0,0,0,.117647),0 1px 2px rgba(0,0,0,.239216),inset 0 0 0 1px #5292f7;border-left:3px solid #5292f7}
.htContextMenu{display:none;position:absolute;z-index:10}.htContextMenu .ht_clone_corner,.htContextMenu .ht_clone_debug,.htContextMenu .ht_clone_left,.htContextMenu .ht_clone_top{display:none}.htContextMenu table.htCore{border:1px solid #ccc;border-bottom-width:2px;border-right-width:2px}.htContextMenu .wtBorder{visibility:hidden}.htContextMenu table tbody tr td{background:#fff;border-width:0;padding:4px 6px 0;cursor:pointer;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.htContextMenu table tbody tr td:first-child{border:0}.htContextMenu table tbody tr td.htDimmed{font-style:normal;color:#323232}.htContextMenu table tbody tr td.current,.htContextMenu table tbody tr td.zeroclipboard-is-hover{background:#f3f3f3}.htContextMenu table tbody tr td.htSeparator{border-top:1px solid #bbb;height:0;padding:0;cursor:default}.htContextMenu table tbody tr td.htDisabled{color:#999;cursor:default}.htContextMenu table tbody tr td.htDisabled:hover{background:#fff;color:#999;cursor:default}.htContextMenu table tbody tr.htHidden{display:none}.htContextMenu table tbody tr td .htItemWrapper{margin-left:10px;margin-right:6px}.htContextMenu table tbody tr td div span.selected{margin-top:-2px;position:absolute;left:4px}.htContextMenu .ht_master .wtHolder{overflow:hidden}textarea#HandsontableCopyPaste{position:fixed!important;top:0!important;right:100%!important;overflow:hidden;opacity:0;outline:0 none!important}.htRowHeaders .ht_master.innerBorderLeft~.ht_clone_left td:first-of-type,.htRowHeaders .ht_master.innerBorderLeft~.ht_clone_top_left_corner th:nth-child(2){border-left:0 none}.handsontable.ht__manualColumnMove.after-selection--columns thead th.ht__highlight{cursor:move;cursor:-webkit-grab;cursor:grab}.handsontable.ht__manualColumnMove.on-moving--columns,.handsontable.ht__manualColumnMove.on-moving--columns thead th.ht__highlight{cursor:move;cursor:-webkit-grabbing;cursor:grabbing}.handsontable.ht__manualColumnMove.on-moving--columns .manualColumnResizer{display:none}.handsontable .ht__manualColumnMove--backlight,.handsontable .ht__manualColumnMove--guideline{position:absolute;height:100%;display:none}.handsontable .ht__manualColumnMove--guideline{background:#757575;width:2px;top:0;margin-left:-1px;z-index:5}.handsontable .ht__manualColumnMove--backlight{background:#343434;background:rgba(52,52,52,.25);display:none;z-index:5;pointer-events:none}.handsontable.on-moving--columns .ht__manualColumnMove--backlight,.handsontable.on-moving--columns.show-ui .ht__manualColumnMove--guideline{display:block}.handsontable .wtHider{position:relative}.handsontable.ht__manualRowMove.after-selection--rows tbody th.ht__highlight{cursor:move;cursor:-webkit-grab;cursor:grab}.handsontable.ht__manualRowMove.on-moving--rows,.handsontable.ht__manualRowMove.on-moving--rows tbody th.ht__highlight{cursor:move;cursor:-webkit-grabbing;cursor:grabbing}.handsontable.ht__manualRowMove.on-moving--rows .manualRowResizer{display:none}.handsontable .ht__manualRowMove--backlight,.handsontable .ht__manualRowMove--guideline{position:absolute;width:100%;display:none}.handsontable .ht__manualRowMove--guideline{background:#757575;height:2px;left:0;margin-top:-1px;z-index:5}.handsontable .ht__manualRowMove--backlight{background:#343434;background:rgba(52,52,52,.25);display:none;z-index:5;pointer-events:none}.handsontable.on-moving--rows .ht__manualRowMove--backlight,.handsontable.on-moving--rows.show-ui .ht__manualRowMove--guideline{display:block}</style>
<script>/*!
* (The MIT License)
*
* Copyright (c) 2012-2014 Marcin Warpechowski
* Copyright (c) 2015 Handsoncode sp. z o.o. <hello@handsoncode.net>
*
* Permission is hereby granted, free of charge, to any person obtaining
* a copy of this software and associated documentation files (the
* 'Software'), to deal in the Software without restriction, including
* without limitation the rights to use, copy, modify, merge, publish,
* distribute, sublicense, and/or sell copies of the Software, and to
* permit persons to whom the Software is furnished to do so, subject to
* the following conditions:
*
* The above copyright notice and this permission notice shall be
* included in all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*
* Version: 0.35.0
* Release date: 06/12/2017 (built at 06/12/2017 09:46:21)
*/
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define("Handsontable",[],t):"object"==typeof exports?exports.Handsontable=t():e.Handsontable=t()}(this,function(){return function(e){function t(o){if(n[o])return n[o].exports;var r=n[o]={i:o,l:!1,exports:{}};return e[o].call(r.exports,r,r.exports,t),r.l=!0,r.exports}var n={};return t.m=e,t.c=n,t.d=function(e,n,o){t.o(e,n)||Object.defineProperty(e,n,{configurable:!1,enumerable:!0,get:o})},t.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,"a",n),n},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=300)}([function(e,t,n){"use strict";function o(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=-1,o=null;null!=e;){if(n===t){o=e;break}e.host&&e.nodeType===Node.DOCUMENT_FRAGMENT_NODE?e=e.host:(n++,e=e.parentNode)}return o}function r(e,t,n){for(;null!=e&&e!==n;){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,n){for(var o=[];e&&(e=r(e,t,n))&&(!n||n.contains(e));)o.push(e),e=e.host&&e.nodeType===Node.DOCUMENT_FRAGMENT_NODE?e.host:e.parentNode;var i=o.length;return i?o[i-1]:null}function s(e,t){var n=e.parentNode,o=[];for("string"==typeof t?o=Array.prototype.slice.call(document.querySelectorAll(t),0):o.push(t);null!=n;){if(o.indexOf(n)>-1)return!0;n=n.parentNode}return!1}function a(e){function t(e){return e.nodeType===Node.ELEMENT_NODE&&e.nodeName===o.toUpperCase()}var n,o="hot-table",r=!1;for(n=l(e);null!=n;){if(t(n)){r=!0;break}if(n.host&&n.nodeType===Node.DOCUMENT_FRAGMENT_NODE){if(r=t(n.host))break;n=n.host}n=n.parentNode}return r}function l(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 n=document.querySelector(".ht_clone_"+e);return n?n.contains(t):null}function d(e){var t=0,n=[];if(!e||!e.length)return n;for(;e[t];)n.push(e[t]),t++;return n}function f(e,t){return q(e,t)}function p(e,t){return $(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 n=e.childNodes,o=n.length-1;o>=0;o--)v(n[o],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 n=e.firstChild;n&&3===n.nodeType&&null===n.nextSibling?ie?n.textContent=t:n.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,n,o,r,i;if(r=document.documentElement,(0,Q.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,n=e.offsetTop,o=e;(e=e.offsetParent)&&e!==document.body;)t+=e.offsetLeft,n+=e.offsetTop,o=e;return o&&"fixed"===o.style.position&&(t+=window.pageXOffset||r.scrollLeft,n+=window.pageYOffset||r.scrollTop),{left:t,top:n}}function E(){var e=window.scrollY;return void 0===e&&(e=document.documentElement.scrollTop),e}function _(){var e=window.scrollX;return void 0===e&&(e=document.documentElement.scrollLeft),e}function S(e){return e===window?E():e.scrollTop}function O(e){return e===window?_():e.scrollLeft}function T(e){for(var t,n,o,r=e.parentNode,i=["auto","scroll"],s="",a="",l="",u="";r&&r.style&&document.body!==r;){if(t=r.style.overflow,n=r.style.overflowX,o=r.style.overflowY,"scroll"==t||"scroll"==n||"scroll"==o)return r;if(window.getComputedStyle&&(s=window.getComputedStyle(r),a=s.getPropertyValue("overflow"),l=s.getPropertyValue("overflow-y"),u=s.getPropertyValue("overflow-x"),"scroll"===a||"scroll"===u||"scroll"===l))return r;if(r.scrollHeight+1>=r.clientHeight&&(-1!==i.indexOf(o)||-1!==i.indexOf(t)||-1!==i.indexOf(a)||-1!==i.indexOf(l)))return r;if(r.scrollWidth+1>=r.clientWidth&&(-1!==i.indexOf(n)||-1!==i.indexOf(t)||-1!==i.indexOf(a)||-1!==i.indexOf(u)))return r;r=r.parentNode}return window}function R(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 n=window.getComputedStyle(t);if("visible"!==n.getPropertyValue("overflow")&&""!==n.getPropertyValue("overflow"))return t}t=t.parentNode}return window}function k(e,t){if(e){if(e!==window){var n,o=e.style[t];return""!==o&&void 0!==o?o:(n=M(e),""!==n[t]&&void 0!==n[t]?n[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 N(e){return e.offsetWidth}function D(e){return(0,Q.hasCaptionProblem)()&&e.firstChild&&"CAPTION"===e.firstChild.nodeName?e.offsetHeight+e.firstChild.offsetHeight:e.offsetHeight}function A(e){return e.clientHeight||e.innerHeight}function H(e){return e.clientWidth||e.innerWidth}function P(e,t,n){window.addEventListener?e.addEventListener(t,n,!1):e.attachEvent("on"+t,n)}function x(e,t,n){window.removeEventListener?e.removeEventListener(t,n,!1):e.detachEvent("on"+t,n)}function L(e){if(e.selectionStart)return e.selectionStart;if(document.selection){e.focus();var t=document.selection.createRange();if(null==t)return 0;var n=e.createTextRange(),o=n.duplicate();return n.moveToBookmark(t.getBookmark()),o.setEndPoint("EndToStart",n),o.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,n){if(void 0===n&&(n=t),e.setSelectionRange){e.focus();try{e.setSelectionRange(t,n)}catch(i){var o=e.parentNode,r=o.style.display;o.style.display="block",e.setSelectionRange(t,n),o.style.display=r}}else if(e.createTextRange){var i=e.createTextRange();i.collapse(!0),i.moveEnd("character",n),i.moveStart("character",t),i.select()}}function F(){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 n=e.offsetWidth;t.style.overflow="scroll";var o=e.offsetWidth;return n==o&&(o=t.clientWidth),(document.body||document.documentElement).removeChild(t),n-o}function B(){return void 0===oe&&(oe=F()),oe}function V(e){return e.offsetWidth!==e.clientWidth}function U(e){return e.offsetHeight!==e.clientHeight}function Y(e,t,n){(0,Z.isIE8)()||(0,Z.isIE9)()?(e.style.top=n,e.style.left=t):(0,Z.isSafari)()?e.style["-webkit-transform"]="translate3d("+t+","+n+",0)":e.style.transform="translate3d("+t+","+n+",0)"}function z(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 G(e){e.style.transform&&""!==e.style.transform?e.style.transform="":e.style["-webkit-transform"]&&""!==e.style["-webkit-transform"]&&(e.style["-webkit-transform"]="")}function X(e){var t=["INPUT","SELECT","TEXTAREA"];return e&&(t.indexOf(e.nodeName)>-1||"true"===e.contentEditable)}function K(e){return X(e)&&-1==e.className.indexOf("handsontableInput")&&-1==e.className.indexOf("copyPaste")}t.__esModule=!0,t.HTML_CHARACTERS=void 0,t.getParent=o,t.closest=r,t.closestDown=i,t.isChildOf=s,t.isChildOfWebComponentTable=a,t.polymerWrap=l,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=E,t.getWindowScrollLeft=_,t.getScrollTop=S,t.getScrollLeft=O,t.getScrollableElement=T,t.getTrimmingContainer=R,t.getStyle=k,t.getComputedStyle=M,t.outerWidth=N,t.outerHeight=D,t.innerHeight=A,t.innerWidth=H,t.addEvent=P,t.removeEvent=x,t.getCaretPosition=L,t.getSelectionEndPosition=I,t.getSelectionText=j,t.setCaretPosition=W,t.getScrollbarWidth=B,t.hasVerticalScrollbar=V,t.hasHorizontalScrollbar=U,t.setOverlayPosition=Y,t.getCssTransform=z,t.resetCssTransform=G,t.isInput=X,t.isOutsideInput=K;var q,$,J,Z=n(27),Q=n(35),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)},$=function(e,t){var n=0;if("string"==typeof t&&(t=t.split(" ")),t=d(t),te)e.classList.add.apply(e.classList,t);else for(;t&&t[n];)e.classList.add(t[n]),n++},J=function(e,t){var n=0;if("string"==typeof t&&(t=t.split(" ")),t=d(t),te)e.classList.remove.apply(e.classList,t);else for(;t&&t[n];)e.classList.remove(t[n]),n++}}else{var ne=function(e){return RegExp("(\\s|^)"+e+"(\\s|$)")};q=function(e,t){return void 0!==e.className&&ne(t).test(e.className)},$=function(e,t){var n=0,o=e.className;if("string"==typeof t&&(t=t.split(" ")),""===o)o=t.join(" ");else for(;t&&t[n];)ne(t[n]).test(o)||(o+=" "+t[n]),n++;e.className=o},J=function(e,t){var n=0,o=e.className;for("string"==typeof t&&(t=t.split(" "));t&&t[n];)o=o.replace(ne(t[n])," ").trim(),n++;e.className!==o&&(e.className=o)}}var oe,re=t.HTML_CHARACTERS=/(<(.*)>|&(.*);)/,ie=!!document.createTextNode("test").textContent},function(e,t,n){"use strict";function o(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function r(e){var t;return Array.isArray(e)?t=[]:(t={},p(e,function(e,n){"__children"!==n&&(t[n]=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,n){e[n]=t}),e}function a(e,t){p(t,function(n,o){t[o]&&"object"===w(t[o])?(e[o]||(e[o]=Array.isArray(t[o])?[]:"[object Date]"===Object.prototype.toString.call(t[o])?t[o]:{}),a(e[o],t[o])):e[o]=t[o]})}function l(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,n){t[n]=e}),t}function c(e){e.MIXINS||(e.MIXINS=[]);for(var t=arguments.length,n=Array(t>1?t-1:0),o=1;t>o;o++)n[o-1]=arguments[o];return(0,C.arrayEach)(n,function(t){e.MIXINS.push(t.MIXIN_NAME),p(t,function(t,n){if(void 0!==e.prototype[n])throw Error("Mixin conflict. Property '"+n+"' already exist and cannot be overwritten.");if("function"==typeof t)e.prototype[n]=t;else{Object.defineProperty(e.prototype,n,{get:function(e,t){e="_"+e;var n=function(e){return(Array.isArray(e)||d(e))&&(e=l(e)),e};return function(){return void 0===this[e]&&(this[e]=n(t)),this[e]}}(n,t),set:function(e){return e="_"+e,function(t){this[e]=t}}(n),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,n,o){o.value=n,o.writable=!1!==o.writable,o.enumerable=!1!==o.enumerable,o.configurable=!1!==o.configurable,Object.defineProperty(e,t,o)}function p(e,t){for(var n in e)if((!e.hasOwnProperty||e.hasOwnProperty&&Object.prototype.hasOwnProperty.call(e,n))&&!1===t(e[n],n,e))break;return e}function g(e,t){var n=t.split("."),o=e;return p(n,function(e){if(void 0===(o=o[e]))return o=void 0,!1}),o}function v(e){if(!d(e))return 0;return function e(t){var n=0;return d(t)?p(t,function(t){n+=e(t)}):n++,n}(e)}function m(e){var t,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"value",r="_"+n,i=(t={_touched:!1},o(t,r,e),o(t,"isTouched",function(){return this._touched}),t);return Object.defineProperty(i,n,{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=a,t.deepClone=l,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=n(2)},function(e,t,n){"use strict";function o(e){for(var t=0,n=e.length;n>t;)e[t]=[e[t]],t++}function r(e,t){for(var n=0,o=t.length;o>n;)e.push(t[n]),n++}function i(e){var t=[];if(!e||0===e.length||!e[0]||0===e[0].length)return t;for(var n=e.length,o=e[0].length,r=0;n>r;r++)for(var i=0;o>i;i++)t[i]||(t[i]=[]),t[i][r]=e[r][i];return t}function s(e,t,n,o){var r=-1,i=e.length;for(o&&i&&(n=e[++r]);++r<i;)n=t(n,e[r],r,e);return n}function a(e,t){for(var n=-1,o=e.length,r=-1,i=[];++n<o;){var s=e[n];t(s,n,e)&&(i[++r]=s)}return i}function l(e,t){for(var n=-1,o=e.length,r=-1,i=[];++n<o;){var s=e[n];i[++r]=t(s,n,e)}return i}function u(e,t){for(var n=-1,o=e.length;++n<o&&!1!==t(e[n],n,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=o,t.extendArray=r,t.pivot=i,t.arrayReduce=s,t.arrayFilter=a,t.arrayMap=l,t.arrayEach=u,t.arraySum=c,t.arrayMax=h,t.arrayMin=d,t.arrayAvg=f,t.arrayFlatten=p,t.arrayUnique=g},function(e,t,n){var o=n(12),r=n(47),i=n(30),s=n(29),a=n(31),l=function(e,t,n){var u,c,h,d,f=e&l.F,p=e&l.G,g=e&l.S,v=e&l.P,m=e&l.B,y=p?o:g?o[t]||(o[t]={}):(o[t]||{}).prototype,w=p?r:r[t]||(r[t]={}),C=w.prototype||(w.prototype={});p&&(n=t);for(u in n)c=!f&&y&&void 0!==y[u],h=(c?y:n)[u],d=m&&c?a(h,o):v&&"function"==typeof h?a(Function.call,h):h,y&&s(y,u,h,e&l.U),w[u]!=h&&i(w,u,d),v&&C[u]!=h&&(C[u]=h)};o.core=r,l.F=1,l.G=2,l.S=4,l.P=8,l.B=16,l.W=32,l.U=64,l.R=128,e.exports=l},function(e,t,n){"use strict";function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){var n=void 0,o=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,a.polymerWrap)(t),s=t.path?t.path.length:0;s--;){if("HOT-TABLE"===t.path[s].nodeName)n=!0;else if(n&&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,l.hasOwnProperty)(e,"hot")||e.isHotTableEnv||e.wtTable)&&((0,l.hasOwnProperty)(e,"hot")?o=e.hot?e.hot.view.wt.wtTable.TABLE:null:e.isHotTableEnv?o=e.view.activeWt.wtTable.TABLE.parentNode.parentNode:e.wtTable&&(o=e.wtTable.TABLE.parentNode.parentNode),r=(0,a.closest)(t.target,["HOT-TABLE"],o),t.realTarget=r?o.querySelector("HOT-TABLE")||t.target:t.target),Object.defineProperty(t,"target",{get:function(){return(0,a.polymerWrap)(i)},enumerable:!0,configurable:!0}),t}function i(){return h}t.__esModule=!0;var s=function(){function e(e,t){for(var n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}();t.getListenersCounter=i;var a=n(0),l=n(1),u=n(35),c=n(11),h=0,d=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;o(this,e),this.context=t||this,this.context.eventListeners||(this.context.eventListeners=[])}return s(e,[{key:"addEventListener",value:function(e,t,n){function o(e){e=r(s,e),n.call(this,e)}var i=this,s=this.context;return this.context.eventListeners.push({element:e,event:t,callback:n,callbackProxy:o}),window.addEventListener?e.addEventListener(t,o,!1):e.attachEvent("on"+t,o),h++,function(){i.removeEventListener(e,t,n)}}},{key:"removeEventListener",value:function(e,t,n){for(var o=this.context.eventListeners.length,r=void 0;o--;)if(r=this.context.eventListeners[o],r.event==t&&r.element==e){if(n&&n!=r.callback)continue;this.context.eventListeners.splice(o,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 n,o={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?(n=document.createEvent("MouseEvents"),n.initMouseEvent(t,o.bubbles,o.cancelable,o.view,o.detail,o.screenX,o.screenY,o.clientX,o.clientY,o.ctrlKey,o.altKey,o.shiftKey,o.metaKey,o.button,o.relatedTarget||document.body.parentNode)):n=document.createEventObject(),e.dispatchEvent?e.dispatchEvent(n):e.fireEvent("on"+t,n)}}]),e}();t.default=d},function(e,t,n){"use strict";function o(e){var t=void 0===e?"undefined":a(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,n){var o=-1;for("function"==typeof t?(n=t,t=e):o=e-1;++o<=t&&!1!==n(o););}function i(e,t,n){var o=e+1;for("function"==typeof t&&(n=t,t=0);--o>=t&&!1!==n(o););}function s(e,t){return t=parseInt((""+t).replace("%",""),10),t=parseInt(e*t/100,10)}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};t.isNumeric=o,t.rangeEach=r,t.rangeEachReverse=i,t.valueAccordingPercent=s},function(e,t,n){"use strict";function o(e,t){e=(0,c.toUpperCaseFirst)(e),l.default.getSingleton().add("construct",function(){var n=void 0;h.has(this)||h.set(this,{}),n=h.get(this),n[e]||(n[e]=new t(this))}),l.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 n=(0,c.toUpperCaseFirst)(t);if(h.has(e)&&h.get(e)[n])return h.get(e)[n]}function i(e){return h.has(e)?Object.keys(h.get(e)):[]}function s(e,t){var n=null;return h.has(e)&&(0,u.objectEach)(h.get(e),function(e,o){e===t&&(n=o)}),n}t.__esModule=!0,t.getPluginName=t.getRegistredPluginNames=t.getPlugin=t.registerPlugin=void 0;var a=n(8),l=function(e){return e&&e.__esModule?e:{default:e}}(a),u=n(1),c=n(33),h=new WeakMap;t.registerPlugin=o,t.getPlugin=r,t.getRegistredPluginNames=i,t.getPluginName=s},function(e,t,n){"use strict";t.__esModule=!0;var o=t.CONTEXT_MENU_ITEMS_NAMESPACE="ContextMenu:items",r=(t.CONTEXTMENU_ITEMS_ROW_ABOVE=o+".insertRowAbove",t.CONTEXTMENU_ITEMS_ROW_BELOW=o+".insertRowBelow",t.CONTEXTMENU_ITEMS_INSERT_LEFT=o+".insertColumnOnTheLeft",t.CONTEXTMENU_ITEMS_INSERT_RIGHT=o+".insertColumnOnTheRight",t.CONTEXTMENU_ITEMS_REMOVE_ROW=o+".removeRow",t.CONTEXTMENU_ITEMS_REMOVE_COLUMN=o+".removeColumn",t.CONTEXTMENU_ITEMS_UNDO=o+".undo",t.CONTEXTMENU_ITEMS_REDO=o+".redo",t.CONTEXTMENU_ITEMS_READ_ONLY=o+".readOnly",t.CONTEXTMENU_ITEMS_CLEAR_COLUMN=o+".clearColumn",t.CONTEXTMENU_ITEMS_COPY=o+".copy",t.CONTEXTMENU_ITEMS_CUT=o+".cut",t.CONTEXTMENU_ITEMS_FREEZE_COLUMN=o+".freezeColumn",t.CONTEXTMENU_ITEMS_UNFREEZE_COLUMN=o+".unfreezeColumn",t.CONTEXTMENU_ITEMS_MERGE_CELLS=o+".mergeCells",t.CONTEXTMENU_ITEMS_UNMERGE_CELLS=o+".unmergeCells",t.CONTEXTMENU_ITEMS_ADD_COMMENT=o+".addComment",t.CONTEXTMENU_ITEMS_EDIT_COMMENT=o+".editComment",t.CONTEXTMENU_ITEMS_REMOVE_COMMENT=o+".removeComment",t.CONTEXTMENU_ITEMS_READ_ONLY_COMMENT=o+".readOnlyComment",t.CONTEXTMENU_ITEMS_ALIGNMENT=o+".align",t.CONTEXTMENU_ITEMS_ALIGNMENT_LEFT=o+".align.left",t.CONTEXTMENU_ITEMS_ALIGNMENT_CENTER=o+".align.center",t.CONTEXTMENU_ITEMS_ALIGNMENT_RIGHT=o+".align.right",t.CONTEXTMENU_ITEMS_ALIGNMENT_JUSTIFY=o+".align.justify",t.CONTEXTMENU_ITEMS_ALIGNMENT_TOP=o+".align.top",t.CONTEXTMENU_ITEMS_ALIGNMENT_MIDDLE=o+".align.middle",t.CONTEXTMENU_ITEMS_ALIGNMENT_BOTTOM=o+".align.bottom",t.CONTEXTMENU_ITEMS_BORDERS=o+".borders",t.CONTEXTMENU_ITEMS_BORDERS_TOP=o+".borders.top",t.CONTEXTMENU_ITEMS_BORDERS_RIGHT=o+".borders.right",t.CONTEXTMENU_ITEMS_BORDERS_BOTTOM=o+".borders.bottom",t.CONTEXTMENU_ITEMS_BORDERS_LEFT=o+".borders.left",t.CONTEXTMENU_ITEMS_REMOVE_BORDERS=o+".borders.remove",t.CONTEXTMENU_ITEMS_NESTED_ROWS_INSERT_CHILD=o+".nestedHeaders.insertChildRow",t.CONTEXTMENU_ITEMS_NESTED_ROWS_DETACH_CHILD=o+".nestedHeaders.detachFromParent",t.CONTEXTMENU_ITEMS_HIDE_COLUMN=o+".hideColumn",t.CONTEXTMENU_ITEMS_SHOW_COLUMN=o+".showColumn",t.CONTEXTMENU_ITEMS_HIDE_ROW=o+".hideRow",t.CONTEXTMENU_ITEMS_SHOW_ROW=o+".showRow",t.FILTERS_NAMESPACE="Filters:"),i=t.FILTERS_CONDITIONS_NAMESPACE=r+"conditions";t.FILTERS_CONDITIONS_NONE=i+".none",t.FILTERS_CONDITIONS_EMPTY=i+".isEmpty",t.FILTERS_CONDITIONS_NOT_EMPTY=i+".isNotEmpty",t.FILTERS_CONDITIONS_EQUAL=i+".isEqualTo",t.FILTERS_CONDITIONS_NOT_EQUAL=i+".isNotEqualTo",t.FILTERS_CONDITIONS_BEGINS_WITH=i+".beginsWith",t.FILTERS_CONDITIONS_ENDS_WITH=i+".endsWith",t.FILTERS_CONDITIONS_CONTAINS=i+".contains",t.FILTERS_CONDITIONS_NOT_CONTAIN=i+".doesNotContain",t.FILTERS_CONDITIONS_BY_VALUE=i+".byValue",t.FILTERS_CONDITIONS_GREATER_THAN=i+".greaterThan",t.FILTERS_CONDITIONS_GREATER_THAN_OR_EQUAL=i+".greaterThanOrEqualTo",t.FILTERS_CONDITIONS_LESS_THAN=i+".lessThan",t.FILTERS_CONDITIONS_LESS_THAN_OR_EQUAL=i+".lessThanOrEqualTo",t.FILTERS_CONDITIONS_BETWEEN=i+".isBetween",t.FILTERS_CONDITIONS_NOT_BETWEEN=i+".isNotBetween",t.FILTERS_CONDITIONS_AFTER=i+".after",t.FILTERS_CONDITIONS_BEFORE=i+".before",t.FILTERS_CONDITIONS_TODAY=i+".today",t.FILTERS_CONDITIONS_TOMORROW=i+".tomorrow",t.FILTERS_CONDITIONS_YESTERDAY=i+".yesterday",t.FILTERS_DIVS_FILTER_BY_CONDITION=r+"labels.filterByCondition",t.FILTERS_DIVS_FILTER_BY_VALUE=r+"labels.filterByValue",t.FILTERS_LABELS_CONJUNCTION=r+"labels.conjunction",t.FILTERS_LABELS_DISJUNCTION=r+"labels.disjunction",t.FILTERS_VALUES_BLANK_CELLS=r+"values.blankCells",t.FILTERS_BUTTONS_SELECT_ALL=r+"buttons.selectAll",t.FILTERS_BUTTONS_CLEAR=r+"buttons.clear",t.FILTERS_BUTTONS_OK=r+"buttons.ok",t.FILTERS_BUTTONS_CANCEL=r+"buttons.cancel",t.FILTERS_BUTTONS_PLACEHOLDER_SEARCH=r+"buttons.placeholder.search",t.FILTERS_BUTTONS_PLACEHOLDER_VALUE=r+"buttons.placeholder.value",t.FILTERS_BUTTONS_PLACEHOLDER_SECOND_VALUE=r+"buttons.placeholder.secondValue"},function(e,t,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=n(2),s=n(1),a=["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","beforeLanguageChange","afterLanguageChange","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"],l=function(){function e(){o(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)(a,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 n=this,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;if(Array.isArray(t))(0,i.arrayEach)(t,function(t){return n.add(e,t,o)});else{var r=this.getBucket(o);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(n,o){if(n.initialHook)return r[e][o]=t,s=!0,!1}),s||r[e].push(t)}}return this}},{key:"once",value:function(e,t){var n=this,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;Array.isArray(t)?(0,i.arrayEach)(t,function(t){return n.once(e,t,o)}):(t.runOnce=!0,this.add(e,t,o))}},{key:"remove",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,o=this.getBucket(n);return void 0!==o[e]&&o[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,n=this.getBucket(t);return!(void 0===n[e]||!n[e].length)}},{key:"run",value:function(e,t,n,o,r,i,s,a){var l=this.globalBucket[t],u=-1,c=l?l.length:0;if(c)for(;++u<c;)if(l[u]&&!l[u].skip){var h=l[u].call(e,n,o,r,i,s,a);void 0!==h&&(n=h),l[u]&&l[u].runOnce&&this.remove(t,l[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,n,o,r,i,s,a);void 0!==g&&(n=g),d[f]&&d[f].runOnce&&this.remove(t,d[f],e)}return n}},{key:"destroy",value:function(){(0,s.objectEach)(this.getBucket(arguments.length>0&&void 0!==arguments[0]?arguments[0]:null),function(e,t,n){return n[t].length=0})}},{key:"register",value:function(e){this.isRegistered(e)||a.push(e)}},{key:"deregister",value:function(e){this.isRegistered(e)&&a.splice(a.indexOf(e),1)}},{key:"isRegistered",value:function(e){return a.indexOf(e)>=0}},{key:"getRegistered",value:function(){return a}}]),e}(),u=new l;t.default=l},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}function r(e){if("function"==typeof e)return e;if(!S(e))throw Error('No registered renderer found under "'+e+'" name');return _(e)}t.__esModule=!0,t.getRegisteredRenderers=t.getRegisteredRendererNames=t.hasRenderer=t.getRenderer=t.registerRenderer=void 0;var i=n(43),s=o(i),a=n(342),l=o(a),u=n(343),c=o(u),h=n(344),d=o(h),f=n(345),p=o(f),g=n(346),v=o(g),m=n(347),y=o(m),w=n(348),C=o(w),b=(0,s.default)("renderers"),E=b.register,_=b.getItem,S=b.hasItem,O=b.getNames,T=b.getValues;E("base",l.default),E("autocomplete",c.default),E("checkbox",d.default),E("html",p.default),E("numeric",v.default),E("password",y.default),E("text",C.default),t.registerRenderer=E,t.getRenderer=r,t.hasRenderer=S,t.getRegisteredRendererNames=O,t.getRegisteredRenderers=T},function(e,t,n){var o=n(72)("wks"),r=n(45),i=n(12).Symbol,s="function"==typeof i;(e.exports=function(e){return o[e]||(o[e]=s&&i[e]||(s?i:r)("Symbol."+e))}).store=o},function(e,t,n){"use strict";function o(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 a(e){return e.pageY?e.pageY:e.clientY+(0,c.getWindowScrollTop)()}function l(e){return 2===e.button}function u(e){return 0===e.button}t.__esModule=!0,t.stopImmediatePropagation=o,t.isImmediatePropagationStopped=r,t.stopPropagation=i,t.pageX=s,t.pageY=a,t.isRightClick=l,t.isLeftClick=u;var c=n(0)},function(e,t){var n=e.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=n)},function(e,t,n){"use strict";function o(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,n(91),n(105),n(106),n(110),n(111),n(113),n(115),n(116),n(117),n(118),n(119),n(120),n(121),n(122),n(124),n(126),n(127),n(128),n(129),n(130),n(131),n(132),n(133),n(134),n(135),n(136),n(137),n(138),n(81),n(139),n(140),n(142),n(143),n(144),n(145),n(146),n(147),n(148),n(150),n(151),n(152),n(154),n(155),n(156);var r=n(157),i=o(r),s=n(158),a=o(s),l=n(52),u=o(l),c=n(82),h=o(c),d=n(159),f=o(d),p=n(160),g=o(p),v=n(324),m=o(v),y=n(327),w=o(y),C=n(328),b=o(C),E=n(329),_=o(E),S=n(285),O=o(S),T=n(161),R=o(T),k=n(278),M=o(k),N=n(279),D=o(N),A=n(280),H=o(A),P=n(330),x=o(P),L=n(281),I=o(L),j=n(282),W=o(j),F=n(283),B=o(F),V=n(284),U=o(V);t.ViewportColumnsCalculator=i.default,t.ViewportRowsCalculator=a.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=_.default,t.Border=O.default,t.default=R.default,t.Core=R.default,t.Event=M.default,t.Overlays=D.default,t.Scroll=H.default,t.Selection=x.default,t.Settings=I.default,t.Table=W.default,t.TableRenderer=B.default,t.Viewport=U.default},function(e,t,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=n(1),s=n(2),a=n(290),l=n(6),u=new WeakMap,c=null;t.default=function(){function e(t){var n=this;o(this,e),(0,i.defineGetter)(this,"hot",t,{writable:!1}),(0,i.defineGetter)(this,"t",(0,a.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 n.onAfterPluginsInitialized()}),this.hot.addHook("afterUpdateSettings",function(){return n.onUpdateSettings()}),this.hot.addHook("beforeInit",function(){return n.init()})}return r(e,[{key:"init",value:function(){this.pluginName=(0,l.getPluginName)(this.hot,this),this.isEnabled&&this.isEnabled()&&this.enablePlugin(),c||(c=(0,l.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 n=u.get(this).hooks[e];this.hot.addHook(e,t),n.push(t),u.get(this).hooks[e]=n}},{key:"removeHooks",value:function(e){var t=this;(0,s.arrayEach)(u.get(this).hooks[e]||[],function(n){t.hot.removeHook(e,n)})}},{key:"clearHooks",value:function(){var e=this,t=u.get(this).hooks;(0,i.objectEach)(t,function(t,n){return e.removeHooks(n)}),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,n){"hot"!==n&&"t"!==n&&(e[n]=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,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}function r(e){var t={},n=e;this.getConstructor=function(){return e},this.getInstance=function(e){return e.guid in t||(t[e.guid]=new n(e)),t[e.guid]},h.default.getSingleton().add("afterDestroy",function(){t={}})}function i(e,t){var n=void 0;if("function"==typeof e)P.get(e)||a(null,e),n=P.get(e);else{if("string"!=typeof e)throw Error('Only strings and functions can be passed as "editor" parameter');n=I(e)}if(!n)throw Error('No editor registered under name "'+e+'"');return n.getInstance(t)}function s(e){if(!j(e))throw Error('No registered editor found under "'+e+'" name');return I(e).getConstructor()}function a(e,t){var n=new r(t);"string"==typeof e&&L(e,n),P.set(t,n)}t.__esModule=!0,t.getRegisteredEditors=t.getRegisteredEditorNames=t.hasEditor=t.getEditorInstance=t.getEditor=t.registerEditor=void 0,t.RegisteredEditor=r,t._getEditorInstance=i;var l=n(43),u=o(l),c=n(8),h=o(c),d=n(44),f=o(d),p=n(286),g=o(p),v=n(332),m=o(v),y=n(333),w=o(y),C=n(336),b=o(C),E=n(287),_=o(E),S=n(337),O=o(S),T=n(338),R=o(T),k=n(340),M=o(k),N=n(341),D=o(N),A=n(53),H=o(A),P=new WeakMap,x=(0,u.default)("editors"),L=x.register,I=x.getItem,j=x.hasItem,W=x.getNames,F=x.getValues;a("base",f.default),a("autocomplete",g.default),a("checkbox",m.default),a("date",w.default),a("dropdown",b.default),a("handsontable",_.default),a("mobile",O.default),a("numeric",R.default),a("password",M.default),a("select",D.default),a("text",H.default),t.registerEditor=a,t.getEditor=s,t.getEditorInstance=i,t.hasEditor=j,t.getRegisteredEditorNames=W,t.getRegisteredEditors=F},function(e,t,n){"use strict";function o(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 a(e){return"[object RegExp]"===Object.prototype.toString.call(e)}function l(e,t){e=C(e||"");var n="",o=!0,r=u(e),i=E(),a=s(e)||"trial"===e;if(a||r)if(r){var l=Math.floor((0,f.default)("06/12/2017","DD/MM/YYYY").toDate().getTime()/864e5),c=b(e);(c>45e3||c!==parseInt(c,10))&&(n="The license key provided to Handsontable Pro is invalid. Make sure you pass it correctly."),n||(l>c+1&&(n=(0,p.toSingleLine)(h)),o=l>c+15)}else n="Evaluation version of Handsontable Pro. Not licensed for use in a production environment.";else n="The license key provided to Handsontable Pro is invalid. Make sure you pass it correctly.";if(i&&(n=!1,o=!1),n&&!_&&(console[a?"info":"warn"](n),_=!0),o&&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],n=t;if(e[g]!==w("Z"))return!1;for(var o="",r="B<H4P+".split(""),i=w(r.shift());i;i=w(r.shift()||"A"))--i<""[g]?n|=(m(""+m(v(o)+(v(y(e,Math.abs(i),2))+[]).padStart(2,"0")))%97||2)>>1:o=y(e,i,i?1===r[g]?9:8:6);return n===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=o,t.isDefined=r,t.isUndefined=i,t.isEmpty=s,t.isRegExp=a,t._injectProductInfo=l;var d=n(36),f=function(e){return e&&e.__esModule?e:{default:e}}(d),p=n(277),g="length",v=function(e){return parseInt(e,16)},m=function(e){return parseInt(e,10)},y=function(e,t,n){return e.substr(t,n)},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)},E=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)},_=!1},function(e,t,n){var o=n(15);e.exports=function(e){if(!o(e))throw TypeError(e+" is not an object!");return e}},function(e,t,n){var o=n(18),r=n(93),i=n(68),s=Object.defineProperty;t.f=n(22)?Object.defineProperty:function(e,t,n){if(o(e),t=i(t,!0),o(n),r)try{return s(e,t,n)}catch(e){}if("get"in n||"set"in n)throw TypeError("Accessors not supported!");return"value"in n&&(e[t]=n.value),e}},function(e,t,n){"use strict";function o(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!==[l.ARROW_DOWN,l.ARROW_UP,l.ARROW_LEFT,l.ARROW_RIGHT,l.HOME,l.END,l.DELETE,l.BACKSPACE,l.F1,l.F2,l.F3,l.F4,l.F5,l.F6,l.F7,l.F8,l.F9,l.F10,l.F11,l.F12,l.TAB,l.PAGE_DOWN,l.PAGE_UP,l.ENTER,l.ESCAPE,l.SHIFT,l.CAPS_LOCK,l.ALT].indexOf(e)}function i(e){return-1!==[l.CONTROL_LEFT,224,l.COMMAND_LEFT,l.COMMAND_RIGHT].indexOf(e)}function s(e,t){var n=t.split("|"),o=!1;return(0,a.arrayEach)(n,function(t){if(e===l[t])return o=!0,!1}),o}t.__esModule=!0,t.KEY_CODES=void 0,t.isPrintableChar=o,t.isMetaKey=r,t.isCtrlKey=i,t.isKey=s;var a=n(2),l=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,n){"use strict";function o(e){return{start:e.getTopLeftCorner(),end:e.getBottomRightCorner()}}function r(e){return(0,E.hasClass)(e,"htSeparator")}function i(e){return(0,E.hasClass)(e,"htSubmenu")}function s(e){return(0,E.hasClass)(e,"htDisabled")}function a(e){return(0,E.hasClass)(e,"htSelectionDisabled")}function l(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 n={},o=e.from.row;e.to.row>=o;o++)for(var r=e.from.col;e.to.col>=r;r++)n[o]||(n[o]=[]),n[o][r]=t(o,r);return n}function d(e,t,n,o,r){if(e.from.row==e.to.row&&e.from.col==e.to.col)f(e.from.row,e.from.col,t,n,o,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,n,o,r)}function f(e,t,n,o,r,i){var s=r(e,t),a=o;s.className&&(a="vertical"===n?u(s.className,o):c(s.className,o)),i(e,t,"className",a)}function p(e,t){var n=!1;return e&&e.forAll(function(e,o){if(t(e,o))return n=!0,!1}),n}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 n=e.slice(0);n.length>0&&n[0].name===t;)n.shift();return n}function y(e,t){var n=e.slice(0);return n.reverse(),n=m(n,t),n.reverse(),n}function w(e){var t=[];return(0,b.arrayEach)(e,function(e,n){n>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]:_.KEY,n=e.slice(0);return n=m(n,t),n=y(n,t),n=w(n)}t.__esModule=!0,t.normalizeSelection=o,t.isSeparator=r,t.hasSubMenu=i,t.isDisabled=s,t.isSelectionDisabled=a,t.getValidSelection=l,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=n(2),E=n(0),_=n(88)},function(e,t,n){e.exports=!n(24)(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})},function(e,t,n){var o=n(54),r=Math.min;e.exports=function(e){return e>0?r(o(e),9007199254740991):0}},function(e,t){e.exports=function(e){try{return!!e()}catch(e){return!0}}},function(e,t){var n={}.hasOwnProperty;e.exports=function(e,t){return n.call(e,t)}},function(e,t,n){var o=n(70),r=n(34);e.exports=function(e){return o(r(e))}},function(e,t,n){"use strict";function o(){return l}function r(){return u}function i(){return c}function s(){return h}function a(e){return e||(e=navigator.userAgent),/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(e)}t.__esModule=!0,t.isIE8=o,t.isIE9=r,t.isSafari=i,t.isChrome=s,t.isMobileBrowser=a;var l=!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,n){"use strict";function o(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=n(43),s=o(i),a=n(349),l=o(a),u=n(350),c=o(u),h=n(351),d=o(h),f=n(352),p=o(f),g=(0,s.default)("validators"),v=g.register,m=g.getItem,y=g.hasItem,w=g.getNames,C=g.getValues;v("autocomplete",l.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,n){var o=n(12),r=n(30),i=n(25),s=n(45)("src"),a=Function.toString,l=(""+a).split("toString");n(47).inspectSource=function(e){return a.call(e)},(e.exports=function(e,t,n,a){var u="function"==typeof n;u&&(i(n,"name")||r(n,"name",t)),e[t]!==n&&(u&&(i(n,s)||r(n,s,e[t]?""+e[t]:l.join(t+""))),e===o?e[t]=n:a?e[t]?e[t]=n:r(e,t,n):(delete e[t],r(e,t,n)))})(Function.prototype,"toString",function(){return"function"==typeof this&&this[s]||a.call(this)})},function(e,t,n){var o=n(19),r=n(46);e.exports=n(22)?function(e,t,n){return o.f(e,t,r(1,n))}:function(e,t,n){return e[t]=n,e}},function(e,t,n){var o=n(57);e.exports=function(e,t,n){if(o(e),void 0===t)return e;switch(n){case 1:return function(n){return e.call(t,n)};case 2:return function(n,o){return e.call(t,n,o)};case 3:return function(n,o,r){return e.call(t,n,o,r)}}return function(){return e.apply(t,arguments)}}},function(e,t,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),s=n(0),a=n(1),l=n(2),u=n(4),c=o(u),h=n(161),d=o(h),f={};t.default=function(){function e(t){r(this,e),(0,a.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,n){if(-1===e.CLONE_TYPES.indexOf(t))throw Error("Unsupported overlay ("+t+").");f[t]=n}},{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 n=document.createElement("DIV"),o=document.createElement("TABLE");n.className="ht_clone_"+t+" handsontable",n.style.position="absolute",n.style.top=0,n.style.left=0,n.style.overflow="hidden",o.className=this.wot.wtTable.TABLE.className,n.appendChild(o),this.type=t,this.wot.wtTable.wtRootElement.parentNode.appendChild(n);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:o})}},{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,l.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,n){"use strict";function o(e){return e[0].toUpperCase()+e.substr(1)}function r(){for(var e=[],t=arguments.length,n=Array(t),o=0;t>o;o++)n[o]=arguments[o];for(var r=n.length;r--;){var i=(0,u.stringify)(n[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 a(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return(""+e).replace(/(?:\\)?\[([^[\]]+)]/g,function(e,n){return"\\"===e.charAt(0)?e.substr(1,e.length-1):void 0===t[n]?"":t[n]})}function l(e){return e+="",e.replace(c,"")}t.__esModule=!0,t.toUpperCaseFirst=o,t.equalsIgnoreCase=r,t.randomString=i,t.isPercentValue=s,t.substitute=a,t.stripTags=l;var u=n(17),c=(n(5),/<\/?\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,n){"use strict";function o(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 a(){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 n=document.createElement("CAPTION");n.innerHTML="c<br>c<br>c<br>c",n.style.padding=0,n.style.margin=0,e.insertBefore(n,t),document.body.appendChild(e),v=2*e.lastChild.offsetHeight>e.offsetHeight,document.body.removeChild(e)}function l(){return void 0===v&&a(),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=o,t.cancelAnimationFrame=r,t.isTouchSupported=i,t.isWebComponentSupportedNatively=s,t.hasCaptionProblem=l,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(),n=Math.max(0,16-(t-h)),o=window.setTimeout(function(){e(t+n)},n);return h=t+n,o}),p||(p=function(e){clearTimeout(e)});var v,m=void 0},function(e,t,n){(function(e){!function(t,n){e.exports=n()}(0,function(){"use strict";function t(){return bo.apply(null,arguments)}function o(e){return e instanceof Array||"[object Array]"===Object.prototype.toString.call(e)}function r(e){return null!=e&&"[object Object]"===Object.prototype.toString.call(e)}function i(e){var t;for(t in e)return!1;return!0}function s(e){return void 0===e}function a(e){return"number"==typeof e||"[object Number]"===Object.prototype.toString.call(e)}function l(e){return e instanceof Date||"[object Date]"===Object.prototype.toString.call(e)}function u(e,t){var n,o=[];for(n=0;e.length>n;++n)o.push(t(e[n],n));return o}function c(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function h(e,t){for(var n in t)c(t,n)&&(e[n]=t[n]);return c(t,"toString")&&(e.toString=t.toString),c(t,"valueOf")&&(e.valueOf=t.valueOf),e}function d(e,t,n,o){return wt(e,t,n,o,!0).utc()}function f(){return{empty:!1,unusedTokens:[],unusedInput:[],overflow:-2,charsLeftOver:0,nullInput:!1,invalidMonth:null,invalidFormat:!1,userInvalidated:!1,iso:!1,parsedDateParts:[],meridiem:null,rfc2822:!1,weekdayMismatch:!1}}function p(e){return null==e._pf&&(e._pf=f()),e._pf}function g(e){if(null==e._isValid){var t=p(e),n=_o.call(t.parsedDateParts,function(e){return null!=e}),o=!isNaN(e._d.getTime())&&0>t.overflow&&!t.empty&&!t.invalidMonth&&!t.invalidWeekday&&!t.nullInput&&!t.invalidFormat&&!t.userInvalidated&&(!t.meridiem||t.meridiem&&n);if(e._strict&&(o=o&&0===t.charsLeftOver&&0===t.unusedTokens.length&&void 0===t.bigHour),null!=Object.isFrozen&&Object.isFrozen(e))return o;e._isValid=o}return e._isValid}function v(e){var t=d(NaN);return null!=e?h(p(t),e):p(t).userInvalidated=!0,t}function m(e,t){var n,o,r;if(s(t._isAMomentObject)||(e._isAMomentObject=t._isAMomentObject),s(t._i)||(e._i=t._i),s(t._f)||(e._f=t._f),s(t._l)||(e._l=t._l),s(t._strict)||(e._strict=t._strict),s(t._tzm)||(e._tzm=t._tzm),s(t._isUTC)||(e._isUTC=t._isUTC),s(t._offset)||(e._offset=t._offset),s(t._pf)||(e._pf=p(t)),s(t._locale)||(e._locale=t._locale),So.length>0)for(n=0;So.length>n;n++)o=So[n],r=t[o],s(r)||(e[o]=r);return e}function y(e){m(this,e),this._d=new Date(null!=e._d?e._d.getTime():NaN),this.isValid()||(this._d=new Date(NaN)),!1===Oo&&(Oo=!0,t.updateOffset(this),Oo=!1)}function w(e){return e instanceof y||null!=e&&null!=e._isAMomentObject}function C(e){return 0>e?Math.ceil(e)||0:Math.floor(e)}function b(e){var t=+e,n=0;return 0!==t&&isFinite(t)&&(n=C(t)),n}function E(e,t,n){var o,r=Math.min(e.length,t.length),i=Math.abs(e.length-t.length),s=0;for(o=0;r>o;o++)(n&&e[o]!==t[o]||!n&&b(e[o])!==b(t[o]))&&s++;return s+i}function _(e){!1===t.suppressDeprecationWarnings&&"undefined"!=typeof console&&console.warn&&console.warn("Deprecation warning: "+e)}function S(e,n){var o=!0;return h(function(){if(null!=t.deprecationHandler&&t.deprecationHandler(null,e),o){for(var r,i=[],s=0;arguments.length>s;s++){if(r="","object"==typeof arguments[s]){r+="\n["+s+"] ";for(var a in arguments[0])r+=a+": "+arguments[0][a]+", ";r=r.slice(0,-2)}else r=arguments[s];i.push(r)}_(e+"\nArguments: "+Array.prototype.slice.call(i).join("")+"\n"+Error().stack),o=!1}return n.apply(this,arguments)},n)}function O(e,n){null!=t.deprecationHandler&&t.deprecationHandler(e,n),To[e]||(_(n),To[e]=!0)}function T(e){return e instanceof Function||"[object Function]"===Object.prototype.toString.call(e)}function R(e){var t,n;for(n in e)t=e[n],T(t)?this[n]=t:this["_"+n]=t;this._config=e,this._dayOfMonthOrdinalParseLenient=RegExp((this._dayOfMonthOrdinalParse.source||this._ordinalParse.source)+"|"+/\d{1,2}/.source)}function k(e,t){var n,o=h({},e);for(n in t)c(t,n)&&(r(e[n])&&r(t[n])?(o[n]={},h(o[n],e[n]),h(o[n],t[n])):null!=t[n]?o[n]=t[n]:delete o[n]);for(n in e)c(e,n)&&!c(t,n)&&r(e[n])&&(o[n]=h({},o[n]));return o}function M(e){null!=e&&this.set(e)}function N(e,t,n){var o=this._calendar[e]||this._calendar.sameElse;return T(o)?o.call(t,n):o}function D(e){var t=this._longDateFormat[e],n=this._longDateFormat[e.toUpperCase()];return t||!n?t:this._longDateFormat[e]=n.replace(/MMMM|MM|DD|dddd/g,function(e){return e.slice(1)})}function A(){return this._invalidDate}function H(e){return this._ordinal.replace("%d",e)}function P(e,t,n,o){var r=this._relativeTime[n];return T(r)?r(e,t,n,o):r.replace(/%d/i,e)}function x(e,t){var n=this._relativeTime[e>0?"future":"past"];return T(n)?n(t):n.replace(/%s/i,t)}function L(e,t){var n=e.toLowerCase();Po[n]=Po[n+"s"]=Po[t]=e}function I(e){return"string"==typeof e?Po[e]||Po[e.toLowerCase()]:void 0}function j(e){var t,n,o={};for(n in e)c(e,n)&&(t=I(n))&&(o[t]=e[n]);return o}function W(e,t){xo[e]=t}function F(e){var t=[];for(var n in e)t.push({unit:n,priority:xo[n]});return t.sort(function(e,t){return e.priority-t.priority}),t}function B(e,n){return function(o){return null!=o?(U(this,e,o),t.updateOffset(this,n),this):V(this,e)}}function V(e,t){return e.isValid()?e._d["get"+(e._isUTC?"UTC":"")+t]():NaN}function U(e,t,n){e.isValid()&&e._d["set"+(e._isUTC?"UTC":"")+t](n)}function Y(e){return e=I(e),T(this[e])?this[e]():this}function z(e,t){if("object"==typeof e){e=j(e);for(var n=F(e),o=0;n.length>o;o++)this[n[o].unit](e[n[o].unit])}else if(e=I(e),T(this[e]))return this[e](t);return this}function G(e,t,n){var o=""+Math.abs(e),r=t-o.length;return(0>e?"-":n?"+":"")+(""+Math.pow(10,Math.max(0,r))).substr(1)+o}function X(e,t,n,o){var r=o;"string"==typeof o&&(r=function(){return this[o]()}),e&&(Wo[e]=r),t&&(Wo[t[0]]=function(){return G(r.apply(this,arguments),t[1],t[2])}),n&&(Wo[n]=function(){return this.localeData().ordinal(r.apply(this,arguments),e)})}function K(e){return e.match(/\[[\s\S]/)?e.replace(/^\[|\]$/g,""):e.replace(/\\/g,"")}function q(e){var t,n,o=e.match(Lo);for(t=0,n=o.length;n>t;t++)o[t]=Wo[o[t]]?Wo[o[t]]:K(o[t]);return function(t){var r,i="";for(r=0;n>r;r++)i+=T(o[r])?o[r].call(t,e):o[r];return i}}function $(e,t){return e.isValid()?(t=J(t,e.localeData()),(jo[t]=jo[t]||q(t))(e)):e.localeData().invalidDate()}function J(e,t){function n(e){return t.longDateFormat(e)||e}var o=5;for(Io.lastIndex=0;o>=0&&Io.test(e);)e=e.replace(Io,n),Io.lastIndex=0,o-=1;return e}function Z(e,t,n){or[e]=T(t)?t:function(e,o){return e&&n?n:t}}function Q(e,t){return c(or,e)?or[e](t._strict,t._locale):RegExp(ee(e))}function ee(e){return te(e.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,function(e,t,n,o,r){return t||n||o||r}))}function te(e){return e.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}function ne(e,t){var n,o=t;for("string"==typeof e&&(e=[e]),a(t)&&(o=function(e,n){n[t]=b(e)}),n=0;e.length>n;n++)rr[e[n]]=o}function oe(e,t){ne(e,function(e,n,o,r){o._w=o._w||{},t(e,o._w,o,r)})}function re(e,t,n){null!=t&&c(rr,e)&&rr[e](t,n._a,n,e)}function ie(e,t){return new Date(Date.UTC(e,t+1,0)).getUTCDate()}function se(e,t){return e?o(this._months)?this._months[e.month()]:this._months[(this._months.isFormat||gr).test(t)?"format":"standalone"][e.month()]:o(this._months)?this._months:this._months.standalone}function ae(e,t){return e?o(this._monthsShort)?this._monthsShort[e.month()]:this._monthsShort[gr.test(t)?"format":"standalone"][e.month()]:o(this._monthsShort)?this._monthsShort:this._monthsShort.standalone}function le(e,t,n){var o,r,i,s=e.toLocaleLowerCase();if(!this._monthsParse)for(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[],o=0;12>o;++o)i=d([2e3,o]),this._shortMonthsParse[o]=this.monthsShort(i,"").toLocaleLowerCase(),this._longMonthsParse[o]=this.months(i,"").toLocaleLowerCase();return n?"MMM"===t?(r=pr.call(this._shortMonthsParse,s),-1!==r?r:null):(r=pr.call(this._longMonthsParse,s),-1!==r?r:null):"MMM"===t?-1!==(r=pr.call(this._shortMonthsParse,s))?r:(r=pr.call(this._longMonthsParse,s),-1!==r?r:null):-1!==(r=pr.call(this._longMonthsParse,s))?r:(r=pr.call(this._shortMonthsParse,s),-1!==r?r:null)}function ue(e,t,n){var o,r,i;if(this._monthsParseExact)return le.call(this,e,t,n);for(this._monthsParse||(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[]),o=0;12>o;o++){if(r=d([2e3,o]),n&&!this._longMonthsParse[o]&&(this._longMonthsParse[o]=RegExp("^"+this.months(r,"").replace(".","")+"$","i"),this._shortMonthsParse[o]=RegExp("^"+this.monthsShort(r,"").replace(".","")+"$","i")),n||this._monthsParse[o]||(i="^"+this.months(r,"")+"|^"+this.monthsShort(r,""),this._monthsParse[o]=RegExp(i.replace(".",""),"i")),n&&"MMMM"===t&&this._longMonthsParse[o].test(e))return o;if(n&&"MMM"===t&&this._shortMonthsParse[o].test(e))return o;if(!n&&this._monthsParse[o].test(e))return o}}function ce(e,t){var n;if(!e.isValid())return e;if("string"==typeof t)if(/^\d+$/.test(t))t=b(t);else if(t=e.localeData().monthsParse(t),!a(t))return e;return n=Math.min(e.date(),ie(e.year(),t)),e._d["set"+(e._isUTC?"UTC":"")+"Month"](t,n),e}function he(e){return null!=e?(ce(this,e),t.updateOffset(this,!0),this):V(this,"Month")}function de(){return ie(this.year(),this.month())}function fe(e){return this._monthsParseExact?(c(this,"_monthsRegex")||ge.call(this),e?this._monthsShortStrictRegex:this._monthsShortRegex):(c(this,"_monthsShortRegex")||(this._monthsShortRegex=yr),this._monthsShortStrictRegex&&e?this._monthsShortStrictRegex:this._monthsShortRegex)}function pe(e){return this._monthsParseExact?(c(this,"_monthsRegex")||ge.call(this),e?this._monthsStrictRegex:this._monthsRegex):(c(this,"_monthsRegex")||(this._monthsRegex=wr),this._monthsStrictRegex&&e?this._monthsStrictRegex:this._monthsRegex)}function ge(){function e(e,t){return t.length-e.length}var t,n,o=[],r=[],i=[];for(t=0;12>t;t++)n=d([2e3,t]),o.push(this.monthsShort(n,"")),r.push(this.months(n,"")),i.push(this.months(n,"")),i.push(this.monthsShort(n,""));for(o.sort(e),r.sort(e),i.sort(e),t=0;12>t;t++)o[t]=te(o[t]),r[t]=te(r[t]);for(t=0;24>t;t++)i[t]=te(i[t]);this._monthsRegex=RegExp("^("+i.join("|")+")","i"),this._monthsShortRegex=this._monthsRegex,this._monthsStrictRegex=RegExp("^("+r.join("|")+")","i"),this._monthsShortStrictRegex=RegExp("^("+o.join("|")+")","i")}function ve(e){return me(e)?366:365}function me(e){return e%4==0&&e%100!=0||e%400==0}function ye(){return me(this.year())}function we(e,t,n,o,r,i,s){var a=new Date(e,t,n,o,r,i,s);return 100>e&&e>=0&&isFinite(a.getFullYear())&&a.setFullYear(e),a}function Ce(e){var t=new Date(Date.UTC.apply(null,arguments));return 100>e&&e>=0&&isFinite(t.getUTCFullYear())&&t.setUTCFullYear(e),t}function be(e,t,n){var o=7+t-n;return-(7+Ce(e,0,o).getUTCDay()-t)%7+o-1}function Ee(e,t,n,o,r){var i,s,a=(7+n-o)%7,l=be(e,o,r),u=1+7*(t-1)+a+l;return u>0?u>ve(e)?(i=e+1,s=u-ve(e)):(i=e,s=u):(i=e-1,s=ve(i)+u),{year:i,dayOfYear:s}}function _e(e,t,n){var o,r,i=be(e.year(),t,n),s=Math.floor((e.dayOfYear()-i-1)/7)+1;return 1>s?(r=e.year()-1,o=s+Se(r,t,n)):s>Se(e.year(),t,n)?(o=s-Se(e.year(),t,n),r=e.year()+1):(r=e.year(),o=s),{week:o,year:r}}function Se(e,t,n){var o=be(e,t,n),r=be(e+1,t,n);return(ve(e)-o+r)/7}function Oe(e){return _e(e,this._week.dow,this._week.doy).week}function Te(){return this._week.dow}function Re(){return this._week.doy}function ke(e){var t=this.localeData().week(this);return null==e?t:this.add(7*(e-t),"d")}function Me(e){var t=_e(this,1,4).week;return null==e?t:this.add(7*(e-t),"d")}function Ne(e,t){return"string"!=typeof e?e:isNaN(e)?(e=t.weekdaysParse(e),"number"==typeof e?e:null):parseInt(e,10)}function De(e,t){return"string"==typeof e?t.weekdaysParse(e)%7||7:isNaN(e)?null:e}function Ae(e,t){return e?o(this._weekdays)?this._weekdays[e.day()]:this._weekdays[this._weekdays.isFormat.test(t)?"format":"standalone"][e.day()]:o(this._weekdays)?this._weekdays:this._weekdays.standalone}function He(e){return e?this._weekdaysShort[e.day()]:this._weekdaysShort}function Pe(e){return e?this._weekdaysMin[e.day()]:this._weekdaysMin}function xe(e,t,n){var o,r,i,s=e.toLocaleLowerCase();if(!this._weekdaysParse)for(this._weekdaysParse=[],this._shortWeekdaysParse=[],this._minWeekdaysParse=[],o=0;7>o;++o)i=d([2e3,1]).day(o),this._minWeekdaysParse[o]=this.weekdaysMin(i,"").toLocaleLowerCase(),this._shortWeekdaysParse[o]=this.weekdaysShort(i,"").toLocaleLowerCase(),this._weekdaysParse[o]=this.weekdays(i,"").toLocaleLowerCase();return n?"dddd"===t?(r=pr.call(this._weekdaysParse,s),-1!==r?r:null):"ddd"===t?(r=pr.call(this._shortWeekdaysParse,s),-1!==r?r:null):(r=pr.call(this._minWeekdaysParse,s),-1!==r?r:null):"dddd"===t?-1!==(r=pr.call(this._weekdaysParse,s))?r:-1!==(r=pr.call(this._shortWeekdaysParse,s))?r:(r=pr.call(this._minWeekdaysParse,s),-1!==r?r:null):"ddd"===t?-1!==(r=pr.call(this._shortWeekdaysParse,s))?r:-1!==(r=pr.call(this._weekdaysParse,s))?r:(r=pr.call(this._minWeekdaysParse,s),-1!==r?r:null):-1!==(r=pr.call(this._minWeekdaysParse,s))?r:-1!==(r=pr.call(this._weekdaysParse,s))?r:(r=pr.call(this._shortWeekdaysParse,s),-1!==r?r:null)}function Le(e,t,n){var o,r,i;if(this._weekdaysParseExact)return xe.call(this,e,t,n);for(this._weekdaysParse||(this._weekdaysParse=[],this._minWeekdaysParse=[],this._shortWeekdaysParse=[],this._fullWeekdaysParse=[]),o=0;7>o;o++){if(r=d([2e3,1]).day(o),n&&!this._fullWeekdaysParse[o]&&(this._fullWeekdaysParse[o]=RegExp("^"+this.weekdays(r,"").replace(".",".?")+"$","i"),this._shortWeekdaysParse[o]=RegExp("^"+this.weekdaysShort(r,"").replace(".",".?")+"$","i"),this._minWeekdaysParse[o]=RegExp("^"+this.weekdaysMin(r,"").replace(".",".?")+"$","i")),this._weekdaysParse[o]||(i="^"+this.weekdays(r,"")+"|^"+this.weekdaysShort(r,"")+"|^"+this.weekdaysMin(r,""),this._weekdaysParse[o]=RegExp(i.replace(".",""),"i")),n&&"dddd"===t&&this._fullWeekdaysParse[o].test(e))return o;if(n&&"ddd"===t&&this._shortWeekdaysParse[o].test(e))return o;if(n&&"dd"===t&&this._minWeekdaysParse[o].test(e))return o;if(!n&&this._weekdaysParse[o].test(e))return o}}function Ie(e){if(!this.isValid())return null!=e?this:NaN;var t=this._isUTC?this._d.getUTCDay():this._d.getDay();return null!=e?(e=Ne(e,this.localeData()),this.add(e-t,"d")):t}function je(e){if(!this.isValid())return null!=e?this:NaN;var t=(this.day()+7-this.localeData()._week.dow)%7;return null==e?t:this.add(e-t,"d")}function We(e){if(!this.isValid())return null!=e?this:NaN;if(null!=e){var t=De(e,this.localeData());return this.day(this.day()%7?t:t-7)}return this.day()||7}function Fe(e){return this._weekdaysParseExact?(c(this,"_weekdaysRegex")||Ue.call(this),e?this._weekdaysStrictRegex:this._weekdaysRegex):(c(this,"_weekdaysRegex")||(this._weekdaysRegex=Or),this._weekdaysStrictRegex&&e?this._weekdaysStrictRegex:this._weekdaysRegex)}function Be(e){return this._weekdaysParseExact?(c(this,"_weekdaysRegex")||Ue.call(this),e?this._weekdaysShortStrictRegex:this._weekdaysShortRegex):(c(this,"_weekdaysShortRegex")||(this._weekdaysShortRegex=Tr),this._weekdaysShortStrictRegex&&e?this._weekdaysShortStrictRegex:this._weekdaysShortRegex)}function Ve(e){return this._weekdaysParseExact?(c(this,"_weekdaysRegex")||Ue.call(this),e?this._weekdaysMinStrictRegex:this._weekdaysMinRegex):(c(this,"_weekdaysMinRegex")||(this._weekdaysMinRegex=Rr),this._weekdaysMinStrictRegex&&e?this._weekdaysMinStrictRegex:this._weekdaysMinRegex)}function Ue(){function e(e,t){return t.length-e.length}var t,n,o,r,i,s=[],a=[],l=[],u=[];for(t=0;7>t;t++)n=d([2e3,1]).day(t),o=this.weekdaysMin(n,""),r=this.weekdaysShort(n,""),i=this.weekdays(n,""),s.push(o),a.push(r),l.push(i),u.push(o),u.push(r),u.push(i);for(s.sort(e),a.sort(e),l.sort(e),u.sort(e),t=0;7>t;t++)a[t]=te(a[t]),l[t]=te(l[t]),u[t]=te(u[t]);this._weekdaysRegex=RegExp("^("+u.join("|")+")","i"),this._weekdaysShortRegex=this._weekdaysRegex,this._weekdaysMinRegex=this._weekdaysRegex,this._weekdaysStrictRegex=RegExp("^("+l.join("|")+")","i"),this._weekdaysShortStrictRegex=RegExp("^("+a.join("|")+")","i"),this._weekdaysMinStrictRegex=RegExp("^("+s.join("|")+")","i")}function Ye(){return this.hours()%12||12}function ze(){return this.hours()||24}function Ge(e,t){X(e,0,0,function(){return this.localeData().meridiem(this.hours(),this.minutes(),t)})}function Xe(e,t){return t._meridiemParse}function Ke(e){return"p"===(e+"").toLowerCase().charAt(0)}function qe(e,t,n){return e>11?n?"pm":"PM":n?"am":"AM"}function $e(e){return e?e.toLowerCase().replace("_","-"):e}function Je(e){for(var t,n,o,r,i=0;e.length>i;){for(r=$e(e[i]).split("-"),t=r.length,n=$e(e[i+1]),n=n?n.split("-"):null;t>0;){if(o=Ze(r.slice(0,t).join("-")))return o;if(n&&n.length>=t&&E(r,n,!0)>=t-1)break;t--}i++}return null}function Ze(t){var o=null;if(!Ar[t]&&void 0!==e&&e&&e.exports)try{o=kr._abbr,n(326)("./"+t),Qe(o)}catch(e){}return Ar[t]}function Qe(e,t){var n;return e&&(n=s(t)?nt(e):et(e,t))&&(kr=n),kr._abbr}function et(e,t){if(null!==t){var n=Dr;if(t.abbr=e,null!=Ar[e])O("defineLocaleOverride","use moment.updateLocale(localeName, config) to change an existing locale. moment.defineLocale(localeName, config) should only be used for creating a new locale See http://momentjs.com/guides/#/warnings/define-locale/ for more info."),n=Ar[e]._config;else if(null!=t.parentLocale){if(null==Ar[t.parentLocale])return Hr[t.parentLocale]||(Hr[t.parentLocale]=[]),Hr[t.parentLocale].push({name:e,config:t}),null;n=Ar[t.parentLocale]._config}return Ar[e]=new M(k(n,t)),Hr[e]&&Hr[e].forEach(function(e){et(e.name,e.config)}),Qe(e),Ar[e]}return delete Ar[e],null}function tt(e,t){if(null!=t){var n,o=Dr;null!=Ar[e]&&(o=Ar[e]._config),t=k(o,t),n=new M(t),n.parentLocale=Ar[e],Ar[e]=n,Qe(e)}else null!=Ar[e]&&(null!=Ar[e].parentLocale?Ar[e]=Ar[e].parentLocale:null!=Ar[e]&&delete Ar[e]);return Ar[e]}function nt(e){var t;if(e&&e._locale&&e._locale._abbr&&(e=e._locale._abbr),!e)return kr;if(!o(e)){if(t=Ze(e))return t;e=[e]}return Je(e)}function ot(){return Mo(Ar)}function rt(e){var t,n=e._a;return n&&-2===p(e).overflow&&(t=0>n[sr]||n[sr]>11?sr:1>n[ar]||n[ar]>ie(n[ir],n[sr])?ar:0>n[lr]||n[lr]>24||24===n[lr]&&(0!==n[ur]||0!==n[cr]||0!==n[hr])?lr:0>n[ur]||n[ur]>59?ur:0>n[cr]||n[cr]>59?cr:0>n[hr]||n[hr]>999?hr:-1,p(e)._overflowDayOfYear&&(ir>t||t>ar)&&(t=ar),p(e)._overflowWeeks&&-1===t&&(t=dr),p(e)._overflowWeekday&&-1===t&&(t=fr),p(e).overflow=t),e}function it(e){var t,n,o,r,i,s,a=e._i,l=Pr.exec(a)||xr.exec(a);if(l){for(p(e).iso=!0,t=0,n=Ir.length;n>t;t++)if(Ir[t][1].exec(l[1])){r=Ir[t][0],o=!1!==Ir[t][2];break}if(null==r)return void(e._isValid=!1);if(l[3]){for(t=0,n=jr.length;n>t;t++)if(jr[t][1].exec(l[3])){i=(l[2]||" ")+jr[t][0];break}if(null==i)return void(e._isValid=!1)}if(!o&&null!=i)return void(e._isValid=!1);if(l[4]){if(!Lr.exec(l[4]))return void(e._isValid=!1);s="Z"}e._f=r+(i||"")+(s||""),dt(e)}else e._isValid=!1}function st(e){var t,n,o,r,i,s,a,l,u={" GMT":" +0000"," EDT":" -0400"," EST":" -0500"," CDT":" -0500"," CST":" -0600"," MDT":" -0600"," MST":" -0700"," PDT":" -0700"," PST":" -0800"},c="YXWVUTSRQPONZABCDEFGHIKLM";if(t=e._i.replace(/\([^\)]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").replace(/^\s|\s$/g,""),n=Fr.exec(t)){if(o=n[1]?"ddd"+(5===n[1].length?", ":" "):"",r="D MMM "+(n[2].length>10?"YYYY ":"YY "),i="HH:mm"+(n[4]?":ss":""),n[1]){var h=new Date(n[2]),d=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"][h.getDay()];if(n[1].substr(0,3)!==d)return p(e).weekdayMismatch=!0,void(e._isValid=!1)}switch(n[5].length){case 2:0===l?a=" +0000":(l=c.indexOf(n[5][1].toUpperCase())-12,a=(0>l?" -":" +")+(""+l).replace(/^-?/,"0").match(/..$/)[0]+"00");break;case 4:a=u[n[5]];break;default:a=" +0000"}n[5]=a,e._i=n.splice(1).join(""),s=" ZZ",e._f=o+r+i+s,dt(e),p(e).rfc2822=!0}else e._isValid=!1}function at(e){var n=Wr.exec(e._i);if(null!==n)return void(e._d=new Date(+n[1]));it(e),!1===e._isValid&&(delete e._isValid,st(e),!1===e._isValid&&(delete e._isValid,t.createFromInputFallback(e)))}function lt(e,t,n){return null!=e?e:null!=t?t:n}function ut(e){var n=new Date(t.now());return e._useUTC?[n.getUTCFullYear(),n.getUTCMonth(),n.getUTCDate()]:[n.getFullYear(),n.getMonth(),n.getDate()]}function ct(e){var t,n,o,r,i=[];if(!e._d){for(o=ut(e),e._w&&null==e._a[ar]&&null==e._a[sr]&&ht(e),null!=e._dayOfYear&&(r=lt(e._a[ir],o[ir]),(e._dayOfYear>ve(r)||0===e._dayOfYear)&&(p(e)._overflowDayOfYear=!0),n=Ce(r,0,e._dayOfYear),e._a[sr]=n.getUTCMonth(),e._a[ar]=n.getUTCDate()),t=0;3>t&&null==e._a[t];++t)e._a[t]=i[t]=o[t];for(;7>t;t++)e._a[t]=i[t]=null==e._a[t]?2===t?1:0:e._a[t];24===e._a[lr]&&0===e._a[ur]&&0===e._a[cr]&&0===e._a[hr]&&(e._nextDay=!0,e._a[lr]=0),e._d=(e._useUTC?Ce:we).apply(null,i),null!=e._tzm&&e._d.setUTCMinutes(e._d.getUTCMinutes()-e._tzm),e._nextDay&&(e._a[lr]=24)}}function ht(e){var t,n,o,r,i,s,a,l;if(t=e._w,null!=t.GG||null!=t.W||null!=t.E)i=1,s=4,n=lt(t.GG,e._a[ir],_e(Ct(),1,4).year),o=lt(t.W,1),(1>(r=lt(t.E,1))||r>7)&&(l=!0);else{i=e._locale._week.dow,s=e._locale._week.doy;var u=_e(Ct(),i,s);n=lt(t.gg,e._a[ir],u.year),o=lt(t.w,u.week),null!=t.d?(0>(r=t.d)||r>6)&&(l=!0):null!=t.e?(r=t.e+i,(0>t.e||t.e>6)&&(l=!0)):r=i}1>o||o>Se(n,i,s)?p(e)._overflowWeeks=!0:null!=l?p(e)._overflowWeekday=!0:(a=Ee(n,o,r,i,s),e._a[ir]=a.year,e._dayOfYear=a.dayOfYear)}function dt(e){if(e._f===t.ISO_8601)return void it(e);if(e._f===t.RFC_2822)return void st(e);e._a=[],p(e).empty=!0;var n,o,r,i,s,a=""+e._i,l=a.length,u=0;for(r=J(e._f,e._locale).match(Lo)||[],n=0;r.length>n;n++)i=r[n],o=(a.match(Q(i,e))||[])[0],o&&(s=a.substr(0,a.indexOf(o)),s.length>0&&p(e).unusedInput.push(s),a=a.slice(a.indexOf(o)+o.length),u+=o.length),Wo[i]?(o?p(e).empty=!1:p(e).unusedTokens.push(i),re(i,o,e)):e._strict&&!o&&p(e).unusedTokens.push(i);p(e).charsLeftOver=l-u,a.length>0&&p(e).unusedInput.push(a),12>=e._a[lr]&&!0===p(e).bigHour&&e._a[lr]>0&&(p(e).bigHour=void 0),p(e).parsedDateParts=e._a.slice(0),p(e).meridiem=e._meridiem,e._a[lr]=ft(e._locale,e._a[lr],e._meridiem),ct(e),rt(e)}function ft(e,t,n){var o;return null==n?t:null!=e.meridiemHour?e.meridiemHour(t,n):null!=e.isPM?(o=e.isPM(n),o&&12>t&&(t+=12),o||12!==t||(t=0),t):t}function pt(e){var t,n,o,r,i;if(0===e._f.length)return p(e).invalidFormat=!0,void(e._d=new Date(NaN));for(r=0;e._f.length>r;r++)i=0,t=m({},e),null!=e._useUTC&&(t._useUTC=e._useUTC),t._f=e._f[r],dt(t),g(t)&&(i+=p(t).charsLeftOver,i+=10*p(t).unusedTokens.length,p(t).score=i,(null==o||o>i)&&(o=i,n=t));h(e,n||t)}function gt(e){if(!e._d){var t=j(e._i);e._a=u([t.year,t.month,t.day||t.date,t.hour,t.minute,t.second,t.millisecond],function(e){return e&&parseInt(e,10)}),ct(e)}}function vt(e){var t=new y(rt(mt(e)));return t._nextDay&&(t.add(1,"d"),t._nextDay=void 0),t}function mt(e){var t=e._i,n=e._f;return e._locale=e._locale||nt(e._l),null===t||void 0===n&&""===t?v({nullInput:!0}):("string"==typeof t&&(e._i=t=e._locale.preparse(t)),w(t)?new y(rt(t)):(l(t)?e._d=t:o(n)?pt(e):n?dt(e):yt(e),g(e)||(e._d=null),e))}function yt(e){var n=e._i;s(n)?e._d=new Date(t.now()):l(n)?e._d=new Date(n.valueOf()):"string"==typeof n?at(e):o(n)?(e._a=u(n.slice(0),function(e){return parseInt(e,10)}),ct(e)):r(n)?gt(e):a(n)?e._d=new Date(n):t.createFromInputFallback(e)}function wt(e,t,n,s,a){var l={};return!0!==n&&!1!==n||(s=n,n=void 0),(r(e)&&i(e)||o(e)&&0===e.length)&&(e=void 0),l._isAMomentObject=!0,l._useUTC=l._isUTC=a,l._l=n,l._i=e,l._f=t,l._strict=s,vt(l)}function Ct(e,t,n,o){return wt(e,t,n,o,!1)}function bt(e,t){var n,r;if(1===t.length&&o(t[0])&&(t=t[0]),!t.length)return Ct();for(n=t[0],r=1;t.length>r;++r)t[r].isValid()&&!t[r][e](n)||(n=t[r]);return n}function Et(){return bt("isBefore",[].slice.call(arguments,0))}function _t(){return bt("isAfter",[].slice.call(arguments,0))}function St(e){for(var t in e)if(-1===Yr.indexOf(t)||null!=e[t]&&isNaN(e[t]))return!1;for(var n=!1,o=0;Yr.length>o;++o)if(e[Yr[o]]){if(n)return!1;parseFloat(e[Yr[o]])!==b(e[Yr[o]])&&(n=!0)}return!0}function Ot(){return this._isValid}function Tt(){return zt(NaN)}function Rt(e){var t=j(e),n=t.year||0,o=t.quarter||0,r=t.month||0,i=t.week||0,s=t.day||0,a=t.hour||0,l=t.minute||0,u=t.second||0,c=t.millisecond||0;this._isValid=St(t),this._milliseconds=+c+1e3*u+6e4*l+1e3*a*60*60,this._days=+s+7*i,this._months=+r+3*o+12*n,this._data={},this._locale=nt(),this._bubble()}function kt(e){return e instanceof Rt}function Mt(e){return 0>e?-1*Math.round(-1*e):Math.round(e)}function Nt(e,t){X(e,0,0,function(){var e=this.utcOffset(),n="+";return 0>e&&(e=-e,n="-"),n+G(~~(e/60),2)+t+G(~~e%60,2)})}function Dt(e,t){var n=(t||"").match(e);if(null===n)return null;var o=n[n.length-1]||[],r=(o+"").match(zr)||["-",0,0],i=60*r[1]+b(r[2]);return 0===i?0:"+"===r[0]?i:-i}function At(e,n){var o,r;return n._isUTC?(o=n.clone(),r=(w(e)||l(e)?e.valueOf():Ct(e).valueOf())-o.valueOf(),o._d.setTime(o._d.valueOf()+r),t.updateOffset(o,!1),o):Ct(e).local()}function Ht(e){return 15*-Math.round(e._d.getTimezoneOffset()/15)}function Pt(e,n,o){var r,i=this._offset||0;if(!this.isValid())return null!=e?this:NaN;if(null!=e){if("string"==typeof e){if(null===(e=Dt(er,e)))return this}else 16>Math.abs(e)&&!o&&(e*=60);return!this._isUTC&&n&&(r=Ht(this)),this._offset=e,this._isUTC=!0,null!=r&&this.add(r,"m"),i!==e&&(!n||this._changeInProgress?$t(this,zt(e-i,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,t.updateOffset(this,!0),this._changeInProgress=null)),this}return this._isUTC?i:Ht(this)}function xt(e,t){return null!=e?("string"!=typeof e&&(e=-e),this.utcOffset(e,t),this):-this.utcOffset()}function Lt(e){return this.utcOffset(0,e)}function It(e){return this._isUTC&&(this.utcOffset(0,e),this._isUTC=!1,e&&this.subtract(Ht(this),"m")),this}function jt(){if(null!=this._tzm)this.utcOffset(this._tzm,!1,!0);else if("string"==typeof this._i){var e=Dt(Qo,this._i);null!=e?this.utcOffset(e):this.utcOffset(0,!0)}return this}function Wt(e){return!!this.isValid()&&(e=e?Ct(e).utcOffset():0,(this.utcOffset()-e)%60==0)}function Ft(){return this.utcOffset()>this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()}function Bt(){if(!s(this._isDSTShifted))return this._isDSTShifted;var e={};if(m(e,this),e=mt(e),e._a){var t=e._isUTC?d(e._a):Ct(e._a);this._isDSTShifted=this.isValid()&&E(e._a,t.toArray())>0}else this._isDSTShifted=!1;return this._isDSTShifted}function Vt(){return!!this.isValid()&&!this._isUTC}function Ut(){return!!this.isValid()&&this._isUTC}function Yt(){return!!this.isValid()&&(this._isUTC&&0===this._offset)}function zt(e,t){var n,o,r,i=e,s=null;return kt(e)?i={ms:e._milliseconds,d:e._days,M:e._months}:a(e)?(i={},t?i[t]=e:i.milliseconds=e):(s=Gr.exec(e))?(n="-"===s[1]?-1:1,i={y:0,d:b(s[ar])*n,h:b(s[lr])*n,m:b(s[ur])*n,s:b(s[cr])*n,ms:b(Mt(1e3*s[hr]))*n}):(s=Xr.exec(e))?(n="-"===s[1]?-1:1,i={y:Gt(s[2],n),M:Gt(s[3],n),w:Gt(s[4],n),d:Gt(s[5],n),h:Gt(s[6],n),m:Gt(s[7],n),s:Gt(s[8],n)}):null==i?i={}:"object"==typeof i&&("from"in i||"to"in i)&&(r=Kt(Ct(i.from),Ct(i.to)),i={},i.ms=r.milliseconds,i.M=r.months),o=new Rt(i),kt(e)&&c(e,"_locale")&&(o._locale=e._locale),o}function Gt(e,t){var n=e&&parseFloat(e.replace(",","."));return(isNaN(n)?0:n)*t}function Xt(e,t){var n={milliseconds:0,months:0};return n.months=t.month()-e.month()+12*(t.year()-e.year()),e.clone().add(n.months,"M").isAfter(t)&&--n.months,n.milliseconds=+t-+e.clone().add(n.months,"M"),n}function Kt(e,t){var n;return e.isValid()&&t.isValid()?(t=At(t,e),e.isBefore(t)?n=Xt(e,t):(n=Xt(t,e),n.milliseconds=-n.milliseconds,n.months=-n.months),n):{milliseconds:0,months:0}}function qt(e,t){return function(n,o){var r,i;return null===o||isNaN(+o)||(O(t,"moment()."+t+"(period, number) is deprecated. Please use moment()."+t+"(number, period). See http://momentjs.com/guides/#/warnings/add-inverted-param/ for more info."),i=n,n=o,o=i),n="string"==typeof n?+n:n,r=zt(n,o),$t(this,r,e),this}}function $t(e,n,o,r){var i=n._milliseconds,s=Mt(n._days),a=Mt(n._months);e.isValid()&&(r=null==r||r,i&&e._d.setTime(e._d.valueOf()+i*o),s&&U(e,"Date",V(e,"Date")+s*o),a&&ce(e,V(e,"Month")+a*o),r&&t.updateOffset(e,s||a))}function Jt(e,t){var n=e.diff(t,"days",!0);return-6>n?"sameElse":-1>n?"lastWeek":0>n?"lastDay":1>n?"sameDay":2>n?"nextDay":7>n?"nextWeek":"sameElse"}function Zt(e,n){var o=e||Ct(),r=At(o,this).startOf("day"),i=t.calendarFormat(this,r)||"sameElse";return this.format(n&&(T(n[i])?n[i].call(this,o):n[i])||this.localeData().calendar(i,this,Ct(o)))}function Qt(){return new y(this)}function en(e,t){var n=w(e)?e:Ct(e);return!(!this.isValid()||!n.isValid())&&(t=I(s(t)?"millisecond":t),"millisecond"===t?this.valueOf()>n.valueOf():n.valueOf()<this.clone().startOf(t).valueOf())}function tn(e,t){var n=w(e)?e:Ct(e);return!(!this.isValid()||!n.isValid())&&(t=I(s(t)?"millisecond":t),"millisecond"===t?this.valueOf()<n.valueOf():this.clone().endOf(t).valueOf()<n.valueOf())}function nn(e,t,n,o){return o=o||"()",("("===o[0]?this.isAfter(e,n):!this.isBefore(e,n))&&(")"===o[1]?this.isBefore(t,n):!this.isAfter(t,n))}function on(e,t){var n,o=w(e)?e:Ct(e);return!(!this.isValid()||!o.isValid())&&(t=I(t||"millisecond"),"millisecond"===t?this.valueOf()===o.valueOf():(n=o.valueOf(),this.clone().startOf(t).valueOf()<=n&&n<=this.clone().endOf(t).valueOf()))}function rn(e,t){return this.isSame(e,t)||this.isAfter(e,t)}function sn(e,t){return this.isSame(e,t)||this.isBefore(e,t)}function an(e,t,n){var o,r,i,s;return this.isValid()?(o=At(e,this),o.isValid()?(r=6e4*(o.utcOffset()-this.utcOffset()),t=I(t),"year"===t||"month"===t||"quarter"===t?(s=ln(this,o),"quarter"===t?s/=3:"year"===t&&(s/=12)):(i=this-o,s="second"===t?i/1e3:"minute"===t?i/6e4:"hour"===t?i/36e5:"day"===t?(i-r)/864e5:"week"===t?(i-r)/6048e5:i),n?s:C(s)):NaN):NaN}function ln(e,t){var n,o,r=12*(t.year()-e.year())+(t.month()-e.month()),i=e.clone().add(r,"months");return 0>t-i?(n=e.clone().add(r-1,"months"),o=(t-i)/(i-n)):(n=e.clone().add(r+1,"months"),o=(t-i)/(n-i)),-(r+o)||0}function un(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")}function cn(){if(!this.isValid())return null;var e=this.clone().utc();return 0>e.year()||e.year()>9999?$(e,"YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]"):T(Date.prototype.toISOString)?this.toDate().toISOString():$(e,"YYYY-MM-DD[T]HH:mm:ss.SSS[Z]")}function hn(){if(!this.isValid())return"moment.invalid(/* "+this._i+" */)";var e="moment",t="";this.isLocal()||(e=0===this.utcOffset()?"moment.utc":"moment.parseZone",t="Z");return this.format("["+e+'("]'+(0>this.year()||this.year()>9999?"YYYYYY":"YYYY")+"-MM-DD[T]HH:mm:ss.SSS"+t+'[")]')}function dn(e){e||(e=this.isUtc()?t.defaultFormatUtc:t.defaultFormat);var n=$(this,e);return this.localeData().postformat(n)}function fn(e,t){return this.isValid()&&(w(e)&&e.isValid()||Ct(e).isValid())?zt({to:this,from:e}).locale(this.locale()).humanize(!t):this.localeData().invalidDate()}function pn(e){return this.from(Ct(),e)}function gn(e,t){return this.isValid()&&(w(e)&&e.isValid()||Ct(e).isValid())?zt({from:this,to:e}).locale(this.locale()).humanize(!t):this.localeData().invalidDate()}function vn(e){return this.to(Ct(),e)}function mn(e){var t;return void 0===e?this._locale._abbr:(t=nt(e),null!=t&&(this._locale=t),this)}function yn(){return this._locale}function wn(e){switch(e=I(e)){case"year":this.month(0);case"quarter":case"month":this.date(1);case"week":case"isoWeek":case"day":case"date":this.hours(0);case"hour":this.minutes(0);case"minute":this.seconds(0);case"second":this.milliseconds(0)}return"week"===e&&this.weekday(0),"isoWeek"===e&&this.isoWeekday(1),"quarter"===e&&this.month(3*Math.floor(this.month()/3)),this}function Cn(e){return void 0===(e=I(e))||"millisecond"===e?this:("date"===e&&(e="day"),this.startOf(e).add(1,"isoWeek"===e?"week":e).subtract(1,"ms"))}function bn(){return this._d.valueOf()-6e4*(this._offset||0)}function En(){return Math.floor(this.valueOf()/1e3)}function _n(){return new Date(this.valueOf())}function Sn(){var e=this;return[e.year(),e.month(),e.date(),e.hour(),e.minute(),e.second(),e.millisecond()]}function On(){var e=this;return{years:e.year(),months:e.month(),date:e.date(),hours:e.hours(),minutes:e.minutes(),seconds:e.seconds(),milliseconds:e.milliseconds()}}function Tn(){return this.isValid()?this.toISOString():null}function Rn(){return g(this)}function kn(){return h({},p(this))}function Mn(){return p(this).overflow}function Nn(){return{input:this._i,format:this._f,locale:this._locale,isUTC:this._isUTC,strict:this._strict}}function Dn(e,t){X(0,[e,e.length],0,t)}function An(e){return Ln.call(this,e,this.week(),this.weekday(),this.localeData()._week.dow,this.localeData()._week.doy)}function Hn(e){return Ln.call(this,e,this.isoWeek(),this.isoWeekday(),1,4)}function Pn(){return Se(this.year(),1,4)}function xn(){var e=this.localeData()._week;return Se(this.year(),e.dow,e.doy)}function Ln(e,t,n,o,r){var i;return null==e?_e(this,o,r).year:(i=Se(e,o,r),t>i&&(t=i),In.call(this,e,t,n,o,r))}function In(e,t,n,o,r){var i=Ee(e,t,n,o,r),s=Ce(i.year,0,i.dayOfYear);return this.year(s.getUTCFullYear()),this.month(s.getUTCMonth()),this.date(s.getUTCDate()),this}function jn(e){return null==e?Math.ceil((this.month()+1)/3):this.month(3*(e-1)+this.month()%3)}function Wn(e){var t=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864e5)+1;return null==e?t:this.add(e-t,"d")}function Fn(e,t){t[hr]=b(1e3*("0."+e))}function Bn(){return this._isUTC?"UTC":""}function Vn(){return this._isUTC?"Coordinated Universal Time":""}function Un(e){return Ct(1e3*e)}function Yn(){return Ct.apply(null,arguments).parseZone()}function zn(e){return e}function Gn(e,t,n,o){return nt()[n](d().set(o,t),e)}function Xn(e,t,n){if(a(e)&&(t=e,e=void 0),e=e||"",null!=t)return Gn(e,t,n,"month");var o,r=[];for(o=0;12>o;o++)r[o]=Gn(e,o,n,"month");return r}function Kn(e,t,n,o){"boolean"==typeof e?(a(t)&&(n=t,t=void 0),t=t||""):(t=e,n=t,e=!1,a(t)&&(n=t,t=void 0),t=t||"");var r=nt(),i=e?r._week.dow:0;if(null!=n)return Gn(t,(n+i)%7,o,"day");var s,l=[];for(s=0;7>s;s++)l[s]=Gn(t,(s+i)%7,o,"day");return l}function qn(e,t){return Xn(e,t,"months")}function $n(e,t){return Xn(e,t,"monthsShort")}function Jn(e,t,n){return Kn(e,t,n,"weekdays")}function Zn(e,t,n){return Kn(e,t,n,"weekdaysShort")}function Qn(e,t,n){return Kn(e,t,n,"weekdaysMin")}function eo(){var e=this._data;return this._milliseconds=ri(this._milliseconds),this._days=ri(this._days),this._months=ri(this._months),e.milliseconds=ri(e.milliseconds),e.seconds=ri(e.seconds),e.minutes=ri(e.minutes),e.hours=ri(e.hours),e.months=ri(e.months),e.years=ri(e.years),this}function to(e,t,n,o){var r=zt(t,n);return e._milliseconds+=o*r._milliseconds,e._days+=o*r._days,e._months+=o*r._months,e._bubble()}function no(e,t){return to(this,e,t,1)}function oo(e,t){return to(this,e,t,-1)}function ro(e){return 0>e?Math.floor(e):Math.ceil(e)}function io(){var e,t,n,o,r,i=this._milliseconds,s=this._days,a=this._months,l=this._data;return(0>i||0>s||0>a)&&(i>0||s>0||a>0)&&(i+=864e5*ro(ao(a)+s),s=0,a=0),l.milliseconds=i%1e3,e=C(i/1e3),l.seconds=e%60,t=C(e/60),l.minutes=t%60,n=C(t/60),l.hours=n%24,s+=C(n/24),r=C(so(s)),a+=r,s-=ro(ao(r)),o=C(a/12),a%=12,l.days=s,l.months=a,l.years=o,this}function so(e){return 4800*e/146097}function ao(e){return 146097*e/4800}function lo(e){if(!this.isValid())return NaN;var t,n,o=this._milliseconds;if("month"===(e=I(e))||"year"===e)return t=this._days+o/864e5,n=this._months+so(t),"month"===e?n:n/12;switch(t=this._days+Math.round(ao(this._months)),e){case"week":return t/7+o/6048e5;case"day":return t+o/864e5;case"hour":return 24*t+o/36e5;case"minute":return 1440*t+o/6e4;case"second":return 86400*t+o/1e3;case"millisecond":return Math.floor(864e5*t)+o;default:throw Error("Unknown unit "+e)}}function uo(){return this.isValid()?this._milliseconds+864e5*this._days+this._months%12*2592e6+31536e6*b(this._months/12):NaN}function co(e){return function(){return this.as(e)}}function ho(e){return e=I(e),this.isValid()?this[e+"s"]():NaN}function fo(e){return function(){return this.isValid()?this._data[e]:NaN}}function po(){return C(this.days()/7)}function go(e,t,n,o,r){return r.relativeTime(t||1,!!n,e,o)}function vo(e,t,n){var o=zt(e).abs(),r=Ci(o.as("s")),i=Ci(o.as("m")),s=Ci(o.as("h")),a=Ci(o.as("d")),l=Ci(o.as("M")),u=Ci(o.as("y")),c=bi.ss>=r&&["s",r]||bi.s>r&&["ss",r]||1>=i&&["m"]||bi.m>i&&["mm",i]||1>=s&&["h"]||bi.h>s&&["hh",s]||1>=a&&["d"]||bi.d>a&&["dd",a]||1>=l&&["M"]||bi.M>l&&["MM",l]||1>=u&&["y"]||["yy",u];return c[2]=t,c[3]=+e>0,c[4]=n,go.apply(null,c)}function mo(e){return void 0===e?Ci:"function"==typeof e&&(Ci=e,!0)}function yo(e,t){return void 0!==bi[e]&&(void 0===t?bi[e]:(bi[e]=t,"s"===e&&(bi.ss=t-1),!0))}function wo(e){if(!this.isValid())return this.localeData().invalidDate();var t=this.localeData(),n=vo(this,!e,t);return e&&(n=t.pastFuture(+this,n)),t.postformat(n)}function Co(){if(!this.isValid())return this.localeData().invalidDate();var e,t,n,o=Ei(this._milliseconds)/1e3,r=Ei(this._days),i=Ei(this._months);e=C(o/60),t=C(e/60),o%=60,e%=60,n=C(i/12),i%=12;var s=n,a=i,l=r,u=t,c=e,h=o,d=this.asSeconds();return d?(0>d?"-":"")+"P"+(s?s+"Y":"")+(a?a+"M":"")+(l?l+"D":"")+(u||c||h?"T":"")+(u?u+"H":"")+(c?c+"M":"")+(h?h+"S":""):"P0D"}var bo,Eo;Eo=Array.prototype.some?Array.prototype.some:function(e){for(var t=Object(this),n=t.length>>>0,o=0;n>o;o++)if(o in t&&e.call(this,t[o],o,t))return!0;return!1};var _o=Eo,So=t.momentProperties=[],Oo=!1,To={};t.suppressDeprecationWarnings=!1,t.deprecationHandler=null;var Ro;Ro=Object.keys?Object.keys:function(e){var t,n=[];for(t in e)c(e,t)&&n.push(t);return n};var ko,Mo=Ro,No={sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},Do={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},Ao=/\d{1,2}/,Ho={future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},Po={},xo={},Lo=/(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|YYYYYY|YYYYY|YYYY|YY|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,Io=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,jo={},Wo={},Fo=/\d/,Bo=/\d\d/,Vo=/\d{3}/,Uo=/\d{4}/,Yo=/[+-]?\d{6}/,zo=/\d\d?/,Go=/\d\d\d\d?/,Xo=/\d\d\d\d\d\d?/,Ko=/\d{1,3}/,qo=/\d{1,4}/,$o=/[+-]?\d{1,6}/,Jo=/\d+/,Zo=/[+-]?\d+/,Qo=/Z|[+-]\d\d:?\d\d/gi,er=/Z|[+-]\d\d(?::?\d\d)?/gi,tr=/[+-]?\d+(\.\d{1,3})?/,nr=/[0-9]*['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+|[\u0600-\u06FF\/]+(\s*?[\u0600-\u06FF]+){1,2}/i,or={},rr={},ir=0,sr=1,ar=2,lr=3,ur=4,cr=5,hr=6,dr=7,fr=8;ko=Array.prototype.indexOf?Array.prototype.indexOf:function(e){var t;for(t=0;this.length>t;++t)if(this[t]===e)return t;return-1};var pr=ko;X("M",["MM",2],"Mo",function(){return this.month()+1}),X("MMM",0,0,function(e){return this.localeData().monthsShort(this,e)}),X("MMMM",0,0,function(e){return this.localeData().months(this,e)}),L("month","M"),W("month",8),Z("M",zo),Z("MM",zo,Bo),Z("MMM",function(e,t){return t.monthsShortRegex(e)}),Z("MMMM",function(e,t){return t.monthsRegex(e)}),ne(["M","MM"],function(e,t){t[sr]=b(e)-1}),ne(["MMM","MMMM"],function(e,t,n,o){var r=n._locale.monthsParse(e,o,n._strict);null!=r?t[sr]=r:p(n).invalidMonth=e});var gr=/D[oD]?(\[[^\[\]]*\]|\s)+MMMM?/,vr="January_February_March_April_May_June_July_August_September_October_November_December".split("_"),mr="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),yr=nr,wr=nr;X("Y",0,0,function(){var e=this.year();return e>9999?"+"+e:""+e}),X(0,["YY",2],0,function(){return this.year()%100}),X(0,["YYYY",4],0,"year"),X(0,["YYYYY",5],0,"year"),X(0,["YYYYYY",6,!0],0,"year"),L("year","y"),W("year",1),Z("Y",Zo),Z("YY",zo,Bo),Z("YYYY",qo,Uo),Z("YYYYY",$o,Yo),Z("YYYYYY",$o,Yo),ne(["YYYYY","YYYYYY"],ir),ne("YYYY",function(e,n){n[ir]=2===e.length?t.parseTwoDigitYear(e):b(e)}),ne("YY",function(e,n){n[ir]=t.parseTwoDigitYear(e)}),ne("Y",function(e,t){t[ir]=parseInt(e,10)}),t.parseTwoDigitYear=function(e){return b(e)+(b(e)>68?1900:2e3)};var Cr=B("FullYear",!0);X("w",["ww",2],"wo","week"),X("W",["WW",2],"Wo","isoWeek"),L("week","w"),L("isoWeek","W"),W("week",5),W("isoWeek",5),Z("w",zo),Z("ww",zo,Bo),Z("W",zo),Z("WW",zo,Bo),oe(["w","ww","W","WW"],function(e,t,n,o){t[o.substr(0,1)]=b(e)});var br={dow:0,doy:6};X("d",0,"do","day"),X("dd",0,0,function(e){return this.localeData().weekdaysMin(this,e)}),X("ddd",0,0,function(e){return this.localeData().weekdaysShort(this,e)}),X("dddd",0,0,function(e){return this.localeData().weekdays(this,e)}),X("e",0,0,"weekday"),X("E",0,0,"isoWeekday"),L("day","d"),L("weekday","e"),L("isoWeekday","E"),W("day",11),W("weekday",11),W("isoWeekday",11),Z("d",zo),Z("e",zo),Z("E",zo),Z("dd",function(e,t){return t.weekdaysMinRegex(e)}),Z("ddd",function(e,t){return t.weekdaysShortRegex(e)}),Z("dddd",function(e,t){return t.weekdaysRegex(e)}),oe(["dd","ddd","dddd"],function(e,t,n,o){var r=n._locale.weekdaysParse(e,o,n._strict);null!=r?t.d=r:p(n).invalidWeekday=e}),oe(["d","e","E"],function(e,t,n,o){t[o]=b(e)});var Er="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),_r="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),Sr="Su_Mo_Tu_We_Th_Fr_Sa".split("_"),Or=nr,Tr=nr,Rr=nr;X("H",["HH",2],0,"hour"),X("h",["hh",2],0,Ye),X("k",["kk",2],0,ze),X("hmm",0,0,function(){return""+Ye.apply(this)+G(this.minutes(),2)}),X("hmmss",0,0,function(){return""+Ye.apply(this)+G(this.minutes(),2)+G(this.seconds(),2)}),X("Hmm",0,0,function(){return""+this.hours()+G(this.minutes(),2)}),X("Hmmss",0,0,function(){return""+this.hours()+G(this.minutes(),2)+G(this.seconds(),2)}),Ge("a",!0),Ge("A",!1),L("hour","h"),W("hour",13),Z("a",Xe),Z("A",Xe),Z("H",zo),Z("h",zo),Z("k",zo),Z("HH",zo,Bo),Z("hh",zo,Bo),Z("kk",zo,Bo),Z("hmm",Go),Z("hmmss",Xo),Z("Hmm",Go),Z("Hmmss",Xo),ne(["H","HH"],lr),ne(["k","kk"],function(e,t,n){var o=b(e);t[lr]=24===o?0:o}),ne(["a","A"],function(e,t,n){n._isPm=n._locale.isPM(e),n._meridiem=e}),ne(["h","hh"],function(e,t,n){t[lr]=b(e),p(n).bigHour=!0}),ne("hmm",function(e,t,n){var o=e.length-2;t[lr]=b(e.substr(0,o)),t[ur]=b(e.substr(o)),p(n).bigHour=!0}),ne("hmmss",function(e,t,n){var o=e.length-4,r=e.length-2;t[lr]=b(e.substr(0,o)),t[ur]=b(e.substr(o,2)),t[cr]=b(e.substr(r)),p(n).bigHour=!0}),ne("Hmm",function(e,t,n){var o=e.length-2;t[lr]=b(e.substr(0,o)),t[ur]=b(e.substr(o))}),ne("Hmmss",function(e,t,n){var o=e.length-4,r=e.length-2;t[lr]=b(e.substr(0,o)),t[ur]=b(e.substr(o,2)),t[cr]=b(e.substr(r))});var kr,Mr=/[ap]\.?m?\.?/i,Nr=B("Hours",!0),Dr={calendar:No,longDateFormat:Do,invalidDate:"Invalid date",ordinal:"%d",dayOfMonthOrdinalParse:Ao,relativeTime:Ho,months:vr,monthsShort:mr,week:br,weekdays:Er,weekdaysMin:Sr,weekdaysShort:_r,meridiemParse:Mr},Ar={},Hr={},Pr=/^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?$/,xr=/^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?$/,Lr=/Z|[+-]\d\d(?::?\d\d)?/,Ir=[["YYYYYY-MM-DD",/[+-]\d{6}-\d\d-\d\d/],["YYYY-MM-DD",/\d{4}-\d\d-\d\d/],["GGGG-[W]WW-E",/\d{4}-W\d\d-\d/],["GGGG-[W]WW",/\d{4}-W\d\d/,!1],["YYYY-DDD",/\d{4}-\d{3}/],["YYYY-MM",/\d{4}-\d\d/,!1],["YYYYYYMMDD",/[+-]\d{10}/],["YYYYMMDD",/\d{8}/],["GGGG[W]WWE",/\d{4}W\d{3}/],["GGGG[W]WW",/\d{4}W\d{2}/,!1],["YYYYDDD",/\d{7}/]],jr=[["HH:mm:ss.SSSS",/\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss,SSSS",/\d\d:\d\d:\d\d,\d+/],["HH:mm:ss",/\d\d:\d\d:\d\d/],["HH:mm",/\d\d:\d\d/],["HHmmss.SSSS",/\d\d\d\d\d\d\.\d+/],["HHmmss,SSSS",/\d\d\d\d\d\d,\d+/],["HHmmss",/\d\d\d\d\d\d/],["HHmm",/\d\d\d\d/],["HH",/\d\d/]],Wr=/^\/?Date\((\-?\d+)/i,Fr=/^((?:Mon|Tue|Wed|Thu|Fri|Sat|Sun),?\s)?(\d?\d\s(?:Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(?:\d\d)?\d\d\s)(\d\d:\d\d)(\:\d\d)?(\s(?:UT|GMT|[ECMP][SD]T|[A-IK-Za-ik-z]|[+-]\d{4}))$/;t.createFromInputFallback=S("value provided is not in a recognized RFC2822 or ISO format. moment construction falls back to js Date(), which is not reliable across all browsers and versions. Non RFC2822/ISO date formats are discouraged and will be removed in an upcoming major release. Please refer to http://momentjs.com/guides/#/warnings/js-date/ for more info.",function(e){e._d=new Date(e._i+(e._useUTC?" UTC":""))}),t.ISO_8601=function(){},t.RFC_2822=function(){};var Br=S("moment().min is deprecated, use moment.max instead. http://momentjs.com/guides/#/warnings/min-max/",function(){var e=Ct.apply(null,arguments);return this.isValid()&&e.isValid()?this>e?this:e:v()}),Vr=S("moment().max is deprecated, use moment.min instead. http://momentjs.com/guides/#/warnings/min-max/",function(){var e=Ct.apply(null,arguments);return this.isValid()&&e.isValid()?e>this?this:e:v()}),Ur=function(){return Date.now?Date.now():+new Date},Yr=["year","quarter","month","week","day","hour","minute","second","millisecond"];Nt("Z",":"),Nt("ZZ",""),Z("Z",er),Z("ZZ",er),ne(["Z","ZZ"],function(e,t,n){n._useUTC=!0,n._tzm=Dt(er,e)});var zr=/([\+\-]|\d\d)/gi;t.updateOffset=function(){};var Gr=/^(\-)?(?:(\d*)[. ])?(\d+)\:(\d+)(?:\:(\d+)(\.\d*)?)?$/,Xr=/^(-)?P(?:(-?[0-9,.]*)Y)?(?:(-?[0-9,.]*)M)?(?:(-?[0-9,.]*)W)?(?:(-?[0-9,.]*)D)?(?:T(?:(-?[0-9,.]*)H)?(?:(-?[0-9,.]*)M)?(?:(-?[0-9,.]*)S)?)?$/;zt.fn=Rt.prototype,zt.invalid=Tt;var Kr=qt(1,"add"),qr=qt(-1,"subtract");t.defaultFormat="YYYY-MM-DDTHH:mm:ssZ",t.defaultFormatUtc="YYYY-MM-DDTHH:mm:ss[Z]";var $r=S("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",function(e){return void 0===e?this.localeData():this.locale(e)});X(0,["gg",2],0,function(){return this.weekYear()%100}),X(0,["GG",2],0,function(){return this.isoWeekYear()%100}),Dn("gggg","weekYear"),Dn("ggggg","weekYear"),Dn("GGGG","isoWeekYear"),Dn("GGGGG","isoWeekYear"),L("weekYear","gg"),L("isoWeekYear","GG"),W("weekYear",1),W("isoWeekYear",1),Z("G",Zo),Z("g",Zo),Z("GG",zo,Bo),Z("gg",zo,Bo),Z("GGGG",qo,Uo),Z("gggg",qo,Uo),Z("GGGGG",$o,Yo),Z("ggggg",$o,Yo),oe(["gggg","ggggg","GGGG","GGGGG"],function(e,t,n,o){t[o.substr(0,2)]=b(e)}),oe(["gg","GG"],function(e,n,o,r){n[r]=t.parseTwoDigitYear(e)}),X("Q",0,"Qo","quarter"),L("quarter","Q"),W("quarter",7),Z("Q",Fo),ne("Q",function(e,t){t[sr]=3*(b(e)-1)}),X("D",["DD",2],"Do","date"),L("date","D"),W("date",9),Z("D",zo),Z("DD",zo,Bo),Z("Do",function(e,t){return e?t._dayOfMonthOrdinalParse||t._ordinalParse:t._dayOfMonthOrdinalParseLenient}),ne(["D","DD"],ar),ne("Do",function(e,t){t[ar]=b(e.match(zo)[0],10)});var Jr=B("Date",!0);X("DDD",["DDDD",3],"DDDo","dayOfYear"),L("dayOfYear","DDD"),W("dayOfYear",4),Z("DDD",Ko),Z("DDDD",Vo),ne(["DDD","DDDD"],function(e,t,n){n._dayOfYear=b(e)}),X("m",["mm",2],0,"minute"),L("minute","m"),W("minute",14),Z("m",zo),Z("mm",zo,Bo),ne(["m","mm"],ur);var Zr=B("Minutes",!1);X("s",["ss",2],0,"second"),L("second","s"),W("second",15),Z("s",zo),Z("ss",zo,Bo),ne(["s","ss"],cr);var Qr=B("Seconds",!1);X("S",0,0,function(){return~~(this.millisecond()/100)}),X(0,["SS",2],0,function(){return~~(this.millisecond()/10)}),X(0,["SSS",3],0,"millisecond"),X(0,["SSSS",4],0,function(){return 10*this.millisecond()}),X(0,["SSSSS",5],0,function(){return 100*this.millisecond()}),X(0,["SSSSSS",6],0,function(){return 1e3*this.millisecond()}),X(0,["SSSSSSS",7],0,function(){return 1e4*this.millisecond()}),X(0,["SSSSSSSS",8],0,function(){return 1e5*this.millisecond()}),X(0,["SSSSSSSSS",9],0,function(){return 1e6*this.millisecond()}),L("millisecond","ms"),W("millisecond",16),Z("S",Ko,Fo),Z("SS",Ko,Bo),Z("SSS",Ko,Vo);var ei;for(ei="SSSS";9>=ei.length;ei+="S")Z(ei,Jo);for(ei="S";9>=ei.length;ei+="S")ne(ei,Fn);var ti=B("Milliseconds",!1);X("z",0,0,"zoneAbbr"),X("zz",0,0,"zoneName");var ni=y.prototype;ni.add=Kr,ni.calendar=Zt,ni.clone=Qt,ni.diff=an,ni.endOf=Cn,ni.format=dn,ni.from=fn,ni.fromNow=pn,ni.to=gn,ni.toNow=vn,ni.get=Y,ni.invalidAt=Mn,ni.isAfter=en,ni.isBefore=tn,ni.isBetween=nn,ni.isSame=on,ni.isSameOrAfter=rn,ni.isSameOrBefore=sn,ni.isValid=Rn,ni.lang=$r,ni.locale=mn,ni.localeData=yn,ni.max=Vr,ni.min=Br,ni.parsingFlags=kn,ni.set=z,ni.startOf=wn,ni.subtract=qr,ni.toArray=Sn,ni.toObject=On,ni.toDate=_n,ni.toISOString=cn,ni.inspect=hn,ni.toJSON=Tn,ni.toString=un,ni.unix=En,ni.valueOf=bn,ni.creationData=Nn,ni.year=Cr,ni.isLeapYear=ye,ni.weekYear=An,ni.isoWeekYear=Hn,ni.quarter=ni.quarters=jn,ni.month=he,ni.daysInMonth=de,ni.week=ni.weeks=ke,ni.isoWeek=ni.isoWeeks=Me,ni.weeksInYear=xn,ni.isoWeeksInYear=Pn,ni.date=Jr,ni.day=ni.days=Ie,ni.weekday=je,ni.isoWeekday=We,ni.dayOfYear=Wn,ni.hour=ni.hours=Nr,ni.minute=ni.minutes=Zr,ni.second=ni.seconds=Qr,ni.millisecond=ni.milliseconds=ti,ni.utcOffset=Pt,ni.utc=Lt,ni.local=It,ni.parseZone=jt,ni.hasAlignedHourOffset=Wt,ni.isDST=Ft,ni.isLocal=Vt,ni.isUtcOffset=Ut,ni.isUtc=Yt,ni.isUTC=Yt,ni.zoneAbbr=Bn,ni.zoneName=Vn,ni.dates=S("dates accessor is deprecated. Use date instead.",Jr),ni.months=S("months accessor is deprecated. Use month instead",he),ni.years=S("years accessor is deprecated. Use year instead",Cr),ni.zone=S("moment().zone is deprecated, use moment().utcOffset instead. http://momentjs.com/guides/#/warnings/zone/",xt),ni.isDSTShifted=S("isDSTShifted is deprecated. See http://momentjs.com/guides/#/warnings/dst-shifted/ for more information",Bt);var oi=M.prototype;oi.calendar=N,oi.longDateFormat=D,oi.invalidDate=A,oi.ordinal=H,oi.preparse=zn,oi.postformat=zn,oi.relativeTime=P,oi.pastFuture=x,oi.set=R,oi.months=se,oi.monthsShort=ae,oi.monthsParse=ue,oi.monthsRegex=pe,oi.monthsShortRegex=fe,oi.week=Oe,oi.firstDayOfYear=Re,oi.firstDayOfWeek=Te,oi.weekdays=Ae,oi.weekdaysMin=Pe,oi.weekdaysShort=He,oi.weekdaysParse=Le,oi.weekdaysRegex=Fe,oi.weekdaysShortRegex=Be,oi.weekdaysMinRegex=Ve,oi.isPM=Ke,oi.meridiem=qe,Qe("en",{dayOfMonthOrdinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(e){var t=e%10;return e+(1===b(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th")}}),t.lang=S("moment.lang is deprecated. Use moment.locale instead.",Qe),t.langData=S("moment.langData is deprecated. Use moment.localeData instead.",nt);var ri=Math.abs,ii=co("ms"),si=co("s"),ai=co("m"),li=co("h"),ui=co("d"),ci=co("w"),hi=co("M"),di=co("y"),fi=fo("milliseconds"),pi=fo("seconds"),gi=fo("minutes"),vi=fo("hours"),mi=fo("days"),yi=fo("months"),wi=fo("years"),Ci=Math.round,bi={ss:44,s:45,m:45,h:22,d:26,M:11},Ei=Math.abs,_i=Rt.prototype;return _i.isValid=Ot,_i.abs=eo,_i.add=no,_i.subtract=oo,_i.as=lo,_i.asMilliseconds=ii,_i.asSeconds=si,_i.asMinutes=ai,_i.asHours=li,_i.asDays=ui,_i.asWeeks=ci,_i.asMonths=hi,_i.asYears=di,_i.valueOf=uo,_i._bubble=io,_i.get=ho,_i.milliseconds=fi,_i.seconds=pi,_i.minutes=gi,_i.hours=vi,_i.days=mi,_i.weeks=po,_i.months=yi,_i.years=wi,_i.humanize=wo,_i.toISOString=Co,_i.toString=Co,_i.toJSON=Co,_i.locale=mn,_i.localeData=yn,_i.toIsoString=S("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",Co),_i.lang=$r,X("X",0,0,"unix"),X("x",0,0,"valueOf"),Z("x",Zo),Z("X",tr),ne("X",function(e,t,n){n._d=new Date(1e3*parseFloat(e,10))}),ne("x",function(e,t,n){n._d=new Date(b(e))}),t.version="2.18.1",function(e){bo=e}(Ct),t.fn=ni,t.min=Et,t.max=_t,t.now=Ur,t.utc=d,t.unix=Un,t.months=qn,t.isDate=l,t.locale=Qe,t.invalid=v,t.duration=zt,t.isMoment=w,t.weekdays=Jn,t.parseZone=Yn,t.localeData=nt,t.isDuration=kt,t.monthsShort=$n,t.weekdaysMin=Qn,t.defineLocale=et,t.updateLocale=tt,t.locales=ot,t.weekdaysShort=Zn,t.normalizeUnits=I,t.relativeTimeRounding=mo,t.relativeTimeThreshold=yo,t.calendarFormat=Jt,t.prototype=ni,t}),window.moment=n(36)}).call(t,n(325)(e))},function(e,t,n){"use strict";function o(e){return"function"==typeof e}function r(e){function t(){var t=this,s=arguments,a=Date.now(),l=!1;r.lastCallThrottled=!0,o||(o=a,l=!0);var u=n-(a-o);return l?(r.lastCallThrottled=!1,e.apply(this,s)):(i&&clearTimeout(i),i=setTimeout(function(){r.lastCallThrottled=!1,e.apply(t,s),o=0,i=void 0},u)),r}var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:200,o=0,r={lastCallThrottled:!0},i=null;return t}function i(e){function t(){a=i}function n(){return a?(a--,e.apply(this,arguments)):s.apply(this,arguments)}var o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:200,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:10,s=r(e,o),a=i;return n.clearHits=t,n}function s(e){function t(){var t=this,i=arguments;return o&&clearTimeout(o),o=setTimeout(function(){r=e.apply(t,i)},n),r}var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:200,o=null,r=void 0;return t}function a(){for(var e=arguments.length,t=Array(e),n=0;e>n;n++)t[n]=arguments[n];var o=t[0],r=t.slice(1);return function(){return(0,h.arrayReduce)(r,function(e,t){return t(e)},o.apply(this,arguments))}}function l(e){for(var t=arguments.length,n=Array(t>1?t-1:0),o=1;t>o;o++)n[o-1]=arguments[o];return function(){for(var t=arguments.length,o=Array(t),r=0;t>r;r++)o[r]=arguments[r];return e.apply(this,n.concat(o))}}function u(e){function t(o){return function(){for(var r=arguments.length,i=Array(r),s=0;r>s;s++)i[s]=arguments[s];var a=o.concat(i);return n>a.length?t(a):e.apply(this,a)}}var n=e.length;return t([])}function c(e){function t(o){return function(){for(var r=arguments.length,i=Array(r),s=0;r>s;s++)i[s]=arguments[s];var a=o.concat(i.reverse());return n>a.length?t(a):e.apply(this,a)}}var n=e.length;return t([])}t.__esModule=!0,t.isFunction=o,t.throttle=r,t.throttleAfterHits=i,t.debounce=s,t.pipe=a,t.partial=l,t.curry=u,t.curryRight=c;var h=n(2)},function(e,t,n){var o=n(94),r=n(73);e.exports=Object.keys||function(e){return o(e,r)}},function(e,t){var n={}.toString;e.exports=function(e){return n.call(e).slice(8,-1)}},function(e,t,n){var o=n(34);e.exports=function(e){return Object(o(e))}},function(e,t,n){var o=n(15);e.exports=function(e,t){if(!o(e)||e._t!==t)throw TypeError("Incompatible receiver, "+t+" required!");return e}},function(e,t,n){var o=n(10)("unscopables"),r=Array.prototype;void 0==r[o]&&n(30)(r,o,{}),e.exports=function(e){r[o][e]=!0}},function(e,t,n){"use strict";function o(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);e.length>t;t++)n[t]=e[t];return n}return Array.from(e)}function r(){function e(e,t){l.set(e,t)}function t(e){return l.get(e)}function n(e){return l.has(e)}function r(){return[].concat(o(l.keys()))}function s(){return[].concat(o(l.values()))}var a=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"common";i.has(a)||i.set(a,new Map);var l=i.get(a);return{register:e,getItem:t,hasItem:n,getNames:r,getValues:s}}t.__esModule=!0,t.default=r;var i=t.collection=new Map},function(e,t,n){"use strict";function o(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=n(13),i=n(17),s=t.EditorState={VIRGIN:"STATE_VIRGIN",EDITING:"STATE_EDITING",WAITING:"STATE_WAITING",FINISHED:"STATE_FINISHED"};o.prototype._fireCallbacks=function(e){this._closeCallback&&(this._closeCallback(e),this._closeCallback=null)},o.prototype.init=function(){},o.prototype.getValue=function(){throw Error("Editor getValue() method unimplemented")},o.prototype.setValue=function(e){throw Error("Editor setValue() method unimplemented")},o.prototype.open=function(){throw Error("Editor open() method unimplemented")},o.prototype.close=function(){throw Error("Editor close() method unimplemented")},o.prototype.prepare=function(e,t,n,o,r,i){this.TD=o,this.row=e,this.col=t,this.prop=n,this.originalValue=r,this.cellProperties=i,this.state=s.VIRGIN},o.prototype.extend=function(){function e(){t.apply(this,arguments)}var t=this.constructor;return function(e,t){function n(){}return n.prototype=t.prototype,e.prototype=new n,e.prototype.constructor=e,e}(e,t)},o.prototype.saveValue=function(e,t){var n=void 0,o=void 0;t?(n=this.instance.getSelected(),n[0]>n[2]&&(o=n[0],n[0]=n[2],n[2]=o),n[1]>n[3]&&(o=n[1],n[1]=n[3],n[3]=o)):n=[this.row,this.col,null,null],this.instance.populateFromArray(n[0],n[1],e,n[2],n[3],"edit")},o.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))},o.prototype.finishEditing=function(e,t,n){var o,r=this;if(n){var i=this._closeCallback;this._closeCallback=function(e){i&&i(e),n(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 a=this.getValue();o=this.instance.getSettings().trimWhitespace?[["string"==typeof a?String.prototype.trim.call(a||""):a]]:[[a]],this.state=s.WAITING,this.saveValue(o,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))}}},o.prototype.cancelChanges=function(){this.state=s.FINISHED,this.discardEditor()},o.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)))},o.prototype.enableFullEditMode=function(){this._fullEditMode=!0},o.prototype.isInFullEditMode=function(){return this._fullEditMode},o.prototype.isOpened=function(){return this._opened},o.prototype.isWaiting=function(){return this.state===s.WAITING},o.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=o},function(e,t){var n=0,o=Math.random();e.exports=function(e){return"Symbol(".concat(void 0===e?"":e,")_",(++n+o).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 n=e.exports={version:"2.5.1"};"number"==typeof __e&&(__e=n)},function(e,t){e.exports={}},function(e,t,n){var o=n(19).f,r=n(25),i=n(10)("toStringTag");e.exports=function(e,t,n){e&&!r(e=n?e:e.prototype,i)&&o(e,i,{configurable:!0,value:t})}},function(e,t,n){var o=n(45)("meta"),r=n(15),i=n(25),s=n(19).f,a=0,l=Object.isExtensible||function(){return!0},u=!n(24)(function(){return l(Object.preventExtensions({}))}),c=function(e){s(e,o,{value:{i:"O"+ ++a,w:{}}})},h=function(e,t){if(!r(e))return"symbol"==typeof e?e:("string"==typeof e?"S":"P")+e;if(!i(e,o)){if(!l(e))return"F";if(!t)return"E";c(e)}return e[o].i},d=function(e,t){if(!i(e,o)){if(!l(e))return!0;if(!t)return!1;c(e)}return e[o].w},f=function(e){return u&&p.NEED&&l(e)&&!i(e,o)&&c(e),e},p=e.exports={KEY:o,NEED:!1,fastKey:h,getWeak:d,onFreeze:f}},function(e,t){t.f={}.propertyIsEnumerable},function(e,t,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}();t.default=function(){function e(t,n){o(this,e),void 0!==t&&void 0!==n?(this.row=t,this.col=n):(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,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}t.__esModule=!0;var r=n(0),i=n(331),s=o(i),a=n(44),l=o(a),u=n(4),c=o(u),h=n(20),d=n(11),f=l.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,n=this,o=n.getActiveEditor();if(t=(e.ctrlKey||e.metaKey)&&!e.altKey,e.target===o.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:o.isInFullEditMode()&&(!o.isWaiting()&&!o.allowKeyEventPropagation||!o.isWaiting()&&o.allowKeyEventPropagation&&!o.allowKeyEventPropagation(e.keyCode))&&(0,d.stopImmediatePropagation)(e);break;case h.KEY_CODES.ARROW_UP:case h.KEY_CODES.ARROW_DOWN:o.isInFullEditMode()&&(!o.isWaiting()&&!o.allowKeyEventPropagation||!o.isWaiting()&&o.allowKeyEventPropagation&&!o.allowKeyEventPropagation(e.keyCode))&&(0,d.stopImmediatePropagation)(e);break;case h.KEY_CODES.ENTER:var i=o.instance.getSelected(),s=!(i[0]===i[2]&&i[1]===i[3]);if(t&&!s||e.altKey){if(o.isOpened()){var a=(0,r.getCaretPosition)(o.TEXTAREA),l=o.getValue();o.setValue(l.slice(0,a)+"\n"+l.slice(a)),(0,r.setCaretPosition)(o.TEXTAREA,a+1)}else o.beginEditing(o.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)&&o.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===a.EditorState.EDITING){if(!(this.TD=this.getEditedCell()))return void this.close(!0);var e,t=(0,r.offset)(this.TD),n=(0,r.offset)(this.instance.rootElement),o=(0,r.getScrollableElement)(this.TD),i=this.instance.countRows(),s=t.top===n.top?0:1,l=t.top-n.top-s-(o.scrollTop||0),u=t.left-n.left-1-(o.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)&&(l+=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=l+"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,E=(0,r.hasVerticalScrollbar)(o)?y:0,_=(0,r.hasHorizontalScrollbar)(o)?y:0,S=this.instance.view.maximumVisibleElementWidth(C)-9-E,O=this.TD.scrollHeight+1,T=Math.max(this.instance.view.maximumVisibleElementHeight(w)-_,23),R=(0,r.getComputedStyle)(this.TD);this.TEXTAREA.style.fontSize=R.fontSize,this.TEXTAREA.style.fontFamily=R.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,T),maxHeight:T,minWidth:Math.min(b,S),maxWidth:S},!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 n=Math.ceil,o=Math.floor;e.exports=function(e){return isNaN(e=+e)?0:(e>0?o:n)(e)}},function(e,t,n){var o=n(54),r=Math.max,i=Math.min;e.exports=function(e,t){return e=o(e),0>e?r(e+t,0):i(e,t)}},function(e,t,n){var o=n(29);e.exports=function(e,t,n){for(var r in t)o(e,r,t[r],n);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,n,o){if(!(e instanceof t)||void 0!==o&&o in e)throw TypeError(n+": incorrect invocation!");return e}},function(e,t,n){var o=n(31),r=n(97),i=n(98),s=n(18),a=n(23),l=n(99),u={},c={},t=e.exports=function(e,t,n,h,d){var f,p,g,v,m=d?function(){return e}:l(e),y=o(n,h,t?2:1),w=0;if("function"!=typeof m)throw TypeError(e+" is not iterable!");if(i(m)){for(f=a(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,n){"use strict";var o=n(12),r=n(3),i=n(29),s=n(56),a=n(50),l=n(59),u=n(58),c=n(15),h=n(24),d=n(74),f=n(49),p=n(304);e.exports=function(e,t,n,g,v,m){var y=o[e],w=y,C=v?"set":"add",b=w&&w.prototype,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,n){return t.call(this,0===e?0:e,n),this})};if("function"==typeof w&&(m||b.forEach&&!h(function(){(new w).entries().next()}))){var S=new w,O=S[C](m?{}:-0,1)!=S,T=h(function(){S.has(1)}),R=d(function(e){new w(e)}),k=!m&&h(function(){for(var e=new w,t=5;t--;)e[C](t,t);return!e.has(-0)});R||(w=t(function(t,n){u(t,w,e);var o=p(new y,t,w);return void 0!=n&&l(n,v,o[C],o),o}),w.prototype=b,b.constructor=w),(T||k)&&(_("delete"),_("has"),v&&_("get")),(k||O)&&_(C),m&&b.clear&&delete b.clear}else w=g.getConstructor(t,e,v,C),s(w.prototype,n),a.NEED=!0;return f(w,e),E[e]=w,r(r.G+r.W+r.F*(w!=y),E),m||g.setStrong(w,e,v),w}},function(e,t,n){var o=n(31),r=n(70),i=n(40),s=n(23),a=n(305);e.exports=function(e,t){var n=1==e,l=2==e,u=3==e,c=4==e,h=6==e,d=5==e||h,f=t||a;return function(t,a,p){for(var g,v,m=i(t),y=r(m),w=o(a,p,3),C=s(y.length),b=0,E=n?f(t,C):l?f(t,0):void 0;C>b;b++)if((d||b in y)&&(g=y[b],v=w(g,b,m),e))if(n)E[b]=v;else if(v)switch(e){case 3:return!0;case 5:return g;case 6:return b;case 2:E.push(g)}else if(c)return!1;return h?-1:u||c?c:E}}},function(e,t){t.f=Object.getOwnPropertySymbols},function(e,t,n){"use strict";var o=n(30),r=n(29),i=n(24),s=n(34),a=n(10);e.exports=function(e,t,n){var l=a(e),u=n(s,l,""[e]),c=u[0],h=u[1];i(function(){var t={};return t[l]=function(){return 7},7!=""[e](t)})&&(r(String.prototype,e,c),o(RegExp.prototype,l,2==t?function(e,t){return h.call(e,this,t)}:function(e){return h.call(e,this)}))}},function(e,t,n){var o,r;/*!
* numbro.js
* version : 1.11.0
* author : Företagsplatsen AB
* license : MIT
* http://www.foretagsplatsen.se
*/
(function(){"use strict";function i(e){this._value=e}function s(e){return 0===e?1:Math.floor(Math.log(Math.abs(e))/Math.LN10)+1}function a(e){var t,n="";for(t=0;e>t;t++)n+="0";return n}function l(e,t){var n,o,r,i,s,l,u,c;return c=""+e,n=c.split("e")[0],i=c.split("e")[1],o=n.split(".")[0],r=n.split(".")[1]||"",+i>0?c=o+r+a(i-r.length):(s=0>+o?"-0":"0",t>0&&(s+="."),u=a(-1*i-1),l=(u+Math.abs(o)+r).substr(0,t),c=s+l),+i>0&&t>0&&(c+="."+a(t)),c}function u(e,t,n,o){var r,i,s=Math.pow(10,t);return(""+e).indexOf("e")>-1?(i=l(e,t),"-"!==i.charAt(0)||0>+i||(i=i.substr(1))):i=(n(e+"e+"+t)/s).toFixed(t),o&&(r=RegExp("0{1,"+o+"}$"),i=i.replace(r,"")),i}function c(e,t,n){var o=t.replace(/\{[^\{\}]*\}/g,"");return o.indexOf("$")>-1?d(e,k[N].currency.symbol,t,n):o.indexOf("%")>-1?p(e,t,n):o.indexOf(":")>-1?g(e):y(e._value,t,n)}function h(e,t){var n,o,r,i,s,a=t,l=!1;if(t.indexOf(":")>-1)e._value=v(t);else if(t===D)e._value=0;else{for("."!==k[N].delimiters.decimal&&(t=t.replace(/\./g,"").replace(k[N].delimiters.decimal,".")),n=RegExp("[^a-zA-Z]"+k[N].abbreviations.thousand+"(?:\\)|(\\"+k[N].currency.symbol+")?(?:\\))?)?$"),o=RegExp("[^a-zA-Z]"+k[N].abbreviations.million+"(?:\\)|(\\"+k[N].currency.symbol+")?(?:\\))?)?$"),r=RegExp("[^a-zA-Z]"+k[N].abbreviations.billion+"(?:\\)|(\\"+k[N].currency.symbol+")?(?:\\))?)?$"),i=RegExp("[^a-zA-Z]"+k[N].abbreviations.trillion+"(?:\\)|(\\"+k[N].currency.symbol+")?(?:\\))?)?$"),s=1;S.length>s&&!l;++s)t.indexOf(S[s])>-1?l=Math.pow(1024,s):t.indexOf(O[s])>-1&&(l=Math.pow(1e3,s));var u=t.replace(/[^0-9\.]+/g,"");""===u?e._value=NaN:(e._value=(l||1)*(a.match(n)?Math.pow(10,3):1)*(a.match(o)?Math.pow(10,6):1)*(a.match(r)?Math.pow(10,9):1)*(a.match(i)?Math.pow(10,12):1)*(t.indexOf("%")>-1?.01:1)*((t.split("-").length+Math.min(t.split("(").length-1,t.split(")").length-1))%2?1:-1)*+u,e._value=l?Math.ceil(e._value):e._value)}return e._value}function d(e,t,n,o){var r,i,s=n,a=s.indexOf("$"),l=s.indexOf("("),u=s.indexOf("+"),c=s.indexOf("-"),h="",d="";if(-1===s.indexOf("$")?"infix"===k[N].currency.position?(d=t,k[N].currency.spaceSeparated&&(d=" "+d+" ")):k[N].currency.spaceSeparated&&(h=" "):s.indexOf(" $")>-1?(h=" ",s=s.replace(" $","")):s.indexOf("$ ")>-1?(h=" ",s=s.replace("$ ","")):s=s.replace("$",""),i=y(e._value,s,o,d),-1===n.indexOf("$"))switch(k[N].currency.position){case"postfix":i.indexOf(")")>-1?(i=i.split(""),i.splice(-1,0,h+t),i=i.join("")):i=i+h+t;break;case"infix":break;case"prefix":i.indexOf("(")>-1||i.indexOf("-")>-1?(i=i.split(""),r=Math.max(l,c)+1,i.splice(r,0,t+h),i=i.join("")):i=t+h+i;break;default:throw Error('Currency position should be among ["prefix", "infix", "postfix"]')}else a>1?i.indexOf(")")>-1?(i=i.split(""),i.splice(-1,0,h+t),i=i.join("")):i=i+h+t:i.indexOf("(")>-1||i.indexOf("+")>-1||i.indexOf("-")>-1?(i=i.split(""),r=1,(l>a||u>a||c>a)&&(r=0),i.splice(r,0,t+h),i=i.join("")):i=t+h+i;return i}function f(e,t,n,o){return d(e,t,n,o)}function p(e,t,n){var o,r="",i=100*e._value;return t.indexOf(" %")>-1?(r=" ",t=t.replace(" %","")):t=t.replace("%",""),o=y(i,t,n),o.indexOf(")")>-1?(o=o.split(""),o.splice(-1,0,r+"%"),o=o.join("")):o=o+r+"%",o}function g(e){var t=Math.floor(e._value/60/60),n=Math.floor((e._value-60*t*60)/60),o=Math.round(e._value-60*t*60-60*n);return t+":"+(10>n?"0"+n:n)+":"+(10>o?"0"+o:o)}function v(e){var t=e.split(":"),n=0;return 3===t.length?(n+=60*+t[0]*60,n+=60*+t[1],n+=+t[2]):2===t.length&&(n+=60*+t[0],n+=+t[1]),+n}function m(e,t,n){var o,r,i,s=t[0],a=Math.abs(e);if(a>=n){for(o=1;t.length>o;++o)if(r=Math.pow(n,o),i=Math.pow(n,o+1),a>=r&&i>a){s=t[o],e/=r;break}s===t[0]&&(e/=Math.pow(n,t.length-1),s=t[t.length-1])}return{value:e,suffix:s}}function y(e,t,n,o){var r,i,l,c,h,d,f,p,g,v,y,w,C,b,E,_,S=!1,O=!1,T=!1,M="",A=!1,H=!1,P=!1,x=!1,L=!1,I="",j="",W=Math.abs(e),F="",B=!1,V=!1,U="";if(0===e&&null!==D)return D;if(!isFinite(e))return""+e;if(0===t.indexOf("{")){var Y=t.indexOf("}");if(-1===Y)throw Error('Format should also contain a "}"');v=t.slice(1,Y),t=t.slice(Y+1)}else v="";if(t.indexOf("}")===t.length-1&&t.length){var z=t.indexOf("{");if(-1===z)throw Error('Format should also contain a "{"');y=t.slice(z+1,-1),t=t.slice(0,z+1)}else y="";var G;for(G=t.match(-1===t.indexOf(".")?/([0-9]+).*/:/([0-9]+)\..*/),E=null===G?-1:G[1].length,-1!==t.indexOf("-")&&(B=!0),t.indexOf("(")>-1?(S=!0,t=t.slice(1,-1)):t.indexOf("+")>-1&&(O=!0,t=t.replace(/\+/g,"")),t.indexOf("a")>-1&&(p=t.split(".")[0].match(/[0-9]+/g)||["0"],p=parseInt(p[0],10),A=t.indexOf("aK")>=0,H=t.indexOf("aM")>=0,P=t.indexOf("aB")>=0,x=t.indexOf("aT")>=0,L=A||H||P||x,t.indexOf(" a")>-1?(M=" ",t=t.replace(" a","")):t=t.replace("a",""),l=s(e),h=l%3,h=0===h?3:h,p&&0!==W&&(d=3*~~((Math.min(p,l)-h)/3),W/=Math.pow(10,d)),l!==p&&(W>=Math.pow(10,12)&&!L||x?(M+=k[N].abbreviations.trillion,e/=Math.pow(10,12)):W<Math.pow(10,12)&&W>=Math.pow(10,9)&&!L||P?(M+=k[N].abbreviations.billion,e/=Math.pow(10,9)):W<Math.pow(10,9)&&W>=Math.pow(10,6)&&!L||H?(M+=k[N].abbreviations.million,e/=Math.pow(10,6)):(W<Math.pow(10,6)&&W>=Math.pow(10,3)&&!L||A)&&(M+=k[N].abbreviations.thousand,e/=Math.pow(10,3))),c=s(e),p&&p>c&&-1===t.indexOf(".")&&(t+="[.]",t+=a(p-c))),_=0;R.length>_;++_)if(r=R[_],t.indexOf(r.marker)>-1){t.indexOf(" "+r.marker)>-1&&(I=" "),t=t.replace(I+r.marker,""),i=m(e,r.suffixes,r.scale),e=i.value,I+=i.suffix;break}if(t.indexOf("o")>-1&&(t.indexOf(" o")>-1?(j=" ",t=t.replace(" o","")):t=t.replace("o",""),k[N].ordinal&&(j+=k[N].ordinal(e))),t.indexOf("[.]")>-1&&(T=!0,t=t.replace("[.]",".")),g=t.split(".")[1],w=t.indexOf(","),g){var X=[];if(-1!==g.indexOf("*")?(F=""+e,X=F.split("."),X.length>1&&(F=u(e,X[1].length,n))):g.indexOf("[")>-1?(g=g.replace("]",""),g=g.split("["),F=u(e,g[0].length+g[1].length,n,g[1].length)):F=u(e,g.length,n),X=F.split("."),f=X[0],X.length>1&&X[1].length){F=(o?M+o:k[N].delimiters.decimal)+X[1]}else F="";T&&0==+F.slice(1)&&(F="")}else f=u(e,0,n);return f.indexOf("-")>-1&&(f=f.slice(1),V=!0),E>f.length&&(f=a(E-f.length)+f),w>-1&&(f=(""+f).replace(/(\d)(?=(\d{3})+(?!\d))/g,"$1"+k[N].delimiters.thousands)),0===t.indexOf(".")&&(f=""),C=t.indexOf("("),b=t.indexOf("-"),U=b>C?(S&&V?"(":"")+(B&&V||!S&&V?"-":""):(B&&V||!S&&V?"-":"")+(S&&V?"(":""),v+U+(!V&&O&&0!==e?"+":"")+f+F+(j||"")+(M&&!o?M:"")+(I||"")+(S&&V?")":"")+y}function w(e,t){k[e]=t}function C(e){N=e;var t=k[e].defaults;t&&t.format&&_.defaultFormat(t.format),t&&t.currencyFormat&&_.defaultCurrencyFormat(t.currencyFormat)}function b(e){var t=(""+e).split(".");return 2>t.length?1:Math.pow(10,t[1].length)}function E(){return Array.prototype.slice.call(arguments).reduce(function(e,t){var n=b(e),o=b(t);return n>o?n:o},-1/0)}var _,S=["B","KiB","MiB","GiB","TiB","PiB","EiB","ZiB","YiB"],O=["B","KB","MB","GB","TB","PB","EB","ZB","YB"],T={general:{scale:1024,suffixes:O,marker:"bd"},binary:{scale:1024,suffixes:S,marker:"b"},decimal:{scale:1e3,suffixes:O,marker:"d"}},R=[T.general,T.binary,T.decimal],k={},M=k,N="en-US",D=null,A="0,0",H="0$",P=void 0!==e&&e.exports,x={delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(e){var t=e%10;return 1==~~(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th"},currency:{symbol:"$",position:"prefix"},defaults:{currencyFormat:",0000 a"},formats:{fourDigits:"0000 a",fullWithTwoDecimals:"$ ,0.00",fullWithTwoDecimalsNoCurrency:",0.00"}};_=function(e){return e=_.isNumbro(e)?e.value():"string"==typeof e||"number"==typeof e?_.fn.unformat(e):NaN,new i(+e)},_.version="1.11.0",_.isNumbro=function(e){return e instanceof i},_.setLanguage=function(e,t){console.warn("`setLanguage` is deprecated since version 1.6.0. Use `setCulture` instead");var n=e,o=e.split("-")[0],r=null;M[n]||(Object.keys(M).forEach(function(e){r||e.split("-")[0]!==o||(r=e)}),n=r||t||"en-US"),C(n)},_.setCulture=function(e,t){var n=e,o=e.split("-")[1],r=null;k[n]||(o&&Object.keys(k).forEach(function(e){r||e.split("-")[1]!==o||(r=e)}),n=r||t||"en-US"),C(n)},_.language=function(e,t){if(console.warn("`language` is deprecated since version 1.6.0. Use `culture` instead"),!e)return N;if(e&&!t){if(!M[e])throw Error("Unknown language : "+e);C(e)}return!t&&M[e]||w(e,t),_},_.culture=function(e,t){if(!e)return N;if(e&&!t){if(!k[e])throw Error("Unknown culture : "+e);C(e)}return!t&&k[e]||w(e,t),_},_.languageData=function(e){if(console.warn("`languageData` is deprecated since version 1.6.0. Use `cultureData` instead"),!e)return M[N];if(!M[e])throw Error("Unknown language : "+e);return M[e]},_.cultureData=function(e){if(!e)return k[N];if(!k[e])throw Error("Unknown culture : "+e);return k[e]},_.culture("en-US",x),_.languages=function(){return console.warn("`languages` is deprecated since version 1.6.0. Use `cultures` instead"),M},_.cultures=function(){return k},_.zeroFormat=function(e){D="string"==typeof e?e:null},_.defaultFormat=function(e){A="string"==typeof e?e:"0.0"},_.defaultCurrencyFormat=function(e){H="string"==typeof e?e:"0$"},_.validate=function(e,t){var n,o,r,i,s,a,l,u;if("string"!=typeof e&&(e+="",console.warn&&console.warn("Numbro.js: Value is not string. It has been co-erced to: ",e)),e=e.trim(),e=e.replace(/^[+-]?/,""),e.match(/^\d+$/))return!0;if(""===e)return!1;try{l=_.cultureData(t)}catch(e){l=_.cultureData(_.culture())}return r=l.currency.symbol,s=l.abbreviations,n=l.delimiters.decimal,o="."===l.delimiters.thousands?"\\.":l.delimiters.thousands,(null===(u=e.match(/^[^\d\.\,]+/))||(e=e.substr(1),u[0]===r))&&((null===(u=e.match(/[^\d]+$/))||(e=e.slice(0,-1),u[0]===s.thousand||u[0]===s.million||u[0]===s.billion||u[0]===s.trillion))&&(a=RegExp(o+"{2}"),!e.match(/[^\d.,]/g)&&(i=e.split(n),2>=i.length&&(2>i.length?!!i[0].match(/^\d+.*\d$/)&&!i[0].match(a):""===i[0]?!i[0].match(a)&&!!i[1].match(/^\d+$/):1===i[0].length?!!i[0].match(/^\d+$/)&&!i[0].match(a)&&!!i[1].match(/^\d+$/):!!i[0].match(/^\d+.*\d$/)&&!i[0].match(a)&&!!i[1].match(/^\d+$/)))))},_.loadLanguagesInNode=function(){console.warn("`loadLanguagesInNode` is deprecated since version 1.6.0. Use `loadCulturesInNode` instead"),_.loadCulturesInNode()},_.loadCulturesInNode=function(){var e=n(339);for(var t in e)t&&_.culture(t,e[t])},"function"!=typeof Array.prototype.reduce&&(Array.prototype.reduce=function(e,t){if(null===this||void 0===this)throw new TypeError("Array.prototype.reduce called on null or undefined");if("function"!=typeof e)throw new TypeError(e+" is not a function");var n,o,r=this.length>>>0,i=!1;for(arguments.length>1&&(o=t,i=!0),n=0;r>n;++n)this.hasOwnProperty(n)&&(i?o=e(o,this[n],n,this):(o=this[n],i=!0));if(!i)throw new TypeError("Reduce of empty array with no initial value");return o}),_.fn=i.prototype={clone:function(){return _(this)},format:function(e,t){return c(this,e||A,void 0!==t?t:Math.round)},formatCurrency:function(e,t){return d(this,k[N].currency.symbol,e||H,void 0!==t?t:Math.round)},formatForeignCurrency:function(e,t,n){return f(this,e,t||H,void 0!==n?n:Math.round)},unformat:function(e){if("number"==typeof e)return e;if("string"==typeof e){var t=h(this,e);return isNaN(t)?void 0:t}},binaryByteUnits:function(){return m(this._value,T.binary.suffixes,T.binary.scale).suffix},byteUnits:function(){return m(this._value,T.general.suffixes,T.general.scale).suffix},decimalByteUnits:function(){return m(this._value,T.decimal.suffixes,T.decimal.scale).suffix},value:function(){return this._value},valueOf:function(){return this._value},set:function(e){return this._value=+e,this},add:function(e){function t(e,t){return e+n*t}var n=E.call(null,this._value,e);return this._value=[this._value,e].reduce(t,0)/n,this},subtract:function(e){function t(e,t){return e-n*t}var n=E.call(null,this._value,e);return this._value=[e].reduce(t,this._value*n)/n,this},multiply:function(e){function t(e,t){var n=E(e,t),o=e*n;return o*=t*n,o/=n*n}return this._value=[this._value,e].reduce(t,1),this},divide:function(e){function t(e,t){var n=E(e,t);return e*n/(t*n)}return this._value=[this._value,e].reduce(t),this},difference:function(e){return Math.abs(_(this._value).subtract(e).value())}},function(){return"undefined"!=typeof process&&void 0===process.browser&&process.title&&(-1!==process.title.indexOf("node")||process.title.indexOf("meteor-tool")>0||"grunt"===process.title||"gulp"===process.title)&&!0}()&&_.loadCulturesInNode(),P?e.exports=_:("undefined"==typeof ender&&(this.numbro=_),o=[],void 0!==(r=function(){return _}.apply(t,o))&&(e.exports=r))}).call("undefined"==typeof window?this:window),window.numbro=n(65)},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}function r(e,t){var n=e;return(0,c.isObject)(e)&&(t=e,n=t.languageCode),l(n,t),y(n,(0,c.deepClone)(t)),(0,c.deepClone)(t)}function i(e){return s(e)?(0,c.deepClone)(w(e)):null}function s(e){return C(e)}function a(){return g.default}function l(e,t){e!==v&&(0,h.extendNotExistingKeys)(t,w(v))}function u(){return b()}t.__esModule=!0,t.DEFAULT_LANGUAGE_CODE=t.getLanguagesDictionaries=t.getDefaultLanguageDictionary=t.hasLanguageDictionary=t.getLanguageDictionary=t.registerLanguageDictionary=void 0;var c=n(1),h=n(294),d=n(43),f=o(d),p=n(368),g=o(p),v=g.default.languageCode,m=(0,f.default)("languagesDictionaries"),y=m.register,w=m.getItem,C=m.hasItem,b=m.getValues;t.registerLanguageDictionary=r,t.getLanguageDictionary=i,t.hasLanguageDictionary=s,t.getDefaultLanguageDictionary=a,t.getLanguagesDictionaries=u,t.DEFAULT_LANGUAGE_CODE=v,r(g.default)},function(e,t,n){var o=n(15),r=n(12).document,i=o(r)&&o(r.createElement);e.exports=function(e){return i?r.createElement(e):{}}},function(e,t,n){var o=n(15);e.exports=function(e,t){if(!o(e))return e;var n,r;if(t&&"function"==typeof(n=e.toString)&&!o(r=n.call(e)))return r;if("function"==typeof(n=e.valueOf)&&!o(r=n.call(e)))return r;if(!t&&"function"==typeof(n=e.toString)&&!o(r=n.call(e)))return r;throw TypeError("Can't convert object to primitive value")}},function(e,t,n){var o=n(18),r=n(301),i=n(73),s=n(71)("IE_PROTO"),a=function(){},l=function(){var e,t=n(67)("iframe"),o=i.length;for(t.style.display="none",n(96).appendChild(t),t.src="javascript:",e=t.contentWindow.document,e.open(),e.write("<script>document.F=Object<\/script>"),e.close(),l=e.F;o--;)delete l.prototype[i[o]];return l()};e.exports=Object.create||function(e,t){var n;return null!==e?(a.prototype=o(e),n=new a,a.prototype=null,n[s]=e):n=l(),void 0===t?n:r(n,t)}},function(e,t,n){var o=n(39);e.exports=Object("z").propertyIsEnumerable(0)?Object:function(e){return"String"==o(e)?e.split(""):Object(e)}},function(e,t,n){var o=n(72)("keys"),r=n(45);e.exports=function(e){return o[e]||(o[e]=r(e))}},function(e,t,n){var o=n(12),r=o["__core-js_shared__"]||(o["__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,n){var o=n(10)("iterator"),r=!1;try{var i=[7][o]();i.return=function(){r=!0},Array.from(i,function(){throw 2})}catch(e){}e.exports=function(e,t){if(!t&&!r)return!1;var n=!1;try{var i=[7],s=i[o]();s.next=function(){return{done:n=!0}},i[o]=function(){return s},e(i)}catch(e){}return n}},function(e,t,n){var o=n(51),r=n(46),i=n(26),s=n(68),a=n(25),l=n(93),u=Object.getOwnPropertyDescriptor;t.f=n(22)?u:function(e,t){if(e=i(e),t=s(t,!0),l)try{return u(e,t)}catch(e){}if(a(e,t))return r(!o.f.call(e,t),e[t])}},function(e,t,n){var o,r,i,s=n(31),a=n(308),l=n(96),u=n(67),c=n(12),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=[],n=1;arguments.length>n;)t.push(arguments[n++]);return m[++v]=function(){a("function"==typeof e?e:Function(e),t)},o(v),v},f=function(e){delete m[e]},"process"==n(39)(h)?o=function(e){h.nextTick(s(y,e,1))}:g&&g.now?o=function(e){g.now(s(y,e,1))}:p?(r=new p,i=r.port2,r.port1.onmessage=w,o=s(i.postMessage,i,1)):c.addEventListener&&"function"==typeof postMessage&&!c.importScripts?(o=function(e){c.postMessage(e+"","*")},c.addEventListener("message",w,!1)):o="onreadystatechange"in u("script")?function(e){l.appendChild(u("script")).onreadystatechange=function(){l.removeChild(this),y.call(e)}}:function(e){setTimeout(s(y,e,1),0)}),e.exports={set:d,clear:f}},function(e,t,n){var o=n(94),r=n(73).concat("length","prototype");t.f=Object.getOwnPropertyNames||function(e){return o(e,r)}},function(e,t,n){var o=n(125),r=n(34);e.exports=function(e,t,n){if(o(t))throw TypeError("String#"+n+" doesn't accept regex!");return r(e)+""}},function(e,t,n){var o=n(10)("match");e.exports=function(e){var t=/./;try{"/./"[e](t)}catch(n){try{return t[o]=!1,!"/./"[e](t)}catch(e){}}return!0}},function(e,t,n){"use strict";var o=n(19),r=n(46);e.exports=function(e,t,n){t in e?o.f(e,t,r(0,n)):e[t]=n}},function(e,t,n){"use strict";var o=n(42),r=n(102),i=n(48),s=n(26);e.exports=n(101)(Array,"Array",function(e,t){this._t=s(e),this._i=0,this._k=t},function(){var e=this._t,t=this._k,n=this._i++;return e&&e.length>n?"keys"==t?r(0,n):"values"==t?r(0,e[n]):r(0,[n,e[n]]):(this._t=void 0,r(1))},"values"),i.Arguments=i.Array,o("keys"),o("values"),o("entries")},function(e,t,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=n(52),s=function(e){return e&&e.__esModule?e:{default:e}}(i);t.default=function(){function e(t,n,r){o(this,e),this.highlight=t,this.from=n,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,n=e.col,o=this.getTopLeftCorner(),r=this.getBottomRightCorner();return!(o.row>t||t>r.row||o.col>n||n>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(),n=this.getBottomRightCorner();return(t.row>e.row||t.col>e.col||e.row>n.row||e.col>n.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(n.row,e.row),Math.max(n.col,e.col)),!0)}},{key:"expandByRange",value:function(t){if(this.includesRange(t)||!this.overlaps(t))return!1;var n=this.getTopLeftCorner(),o=this.getBottomRightCorner(),r=(this.getTopRightCorner(),this.getBottomLeftCorner(),t.getTopLeftCorner()),i=t.getBottomRightCorner(),a=Math.min(n.row,r.row),l=Math.min(n.col,r.col),u=Math.max(o.row,i.row),c=Math.max(o.col,i.col),h=new s.default(a,l),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=l),this.from.row>h.row&&(h.row=u,d.row=a)),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 n=[this.getTopRightCorner(),this.getBottomLeftCorner()];this.from=n[0],this.to=n[1];break;case"SE-NW":var o=[this.getBottomRightCorner(),this.getTopLeftCorner()];this.from=o[0],this.to=o[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)},n={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)},o=[];return t.top==n.top&&o.push("top"),t.right==n.right&&o.push("right"),t.bottom==n.bottom&&o.push("bottom"),t.left==n.left&&o.push("left"),o}},{key:"getInner",value:function(){for(var e=this.getTopLeftCorner(),t=this.getBottomRightCorner(),n=[],o=e.row;t.row>=o;o++)for(var r=e.col;t.col>=r;r++)this.from.row===o&&this.from.col===r||this.to.row===o&&this.to.col===r||n.push(new s.default(o,r));return n}},{key:"getAll",value:function(){for(var e=this.getTopLeftCorner(),t=this.getBottomRightCorner(),n=[],o=e.row;t.row>=o;o++)for(var r=e.col;t.col>=r;r++)n.push(e.row===o&&e.col===r?e:t.row===o&&t.col===r?t:new s.default(o,r));return n}},{key:"forAll",value:function(e){for(var t=this.getTopLeftCorner(),n=this.getBottomRightCorner(),o=t.row;n.row>=o;o++)for(var r=t.col;n.col>=r;r++){var i=e(o,r);if(!1===i)return}}}]),e}()},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}function r(e){if(!A(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 D(e)}function i(e,t){var n=t.editor,o=t.renderer,r=t.validator;n&&(0,l.registerEditor)(e,n),o&&(0,u.registerRenderer)(e,o),r&&(0,c.registerValidator)(e,r),N(e,t)}t.__esModule=!0,t.getRegisteredCellTypes=t.getRegisteredCellTypeNames=t.hasCellType=t.getCellType=t.registerCellType=void 0;var s=n(43),a=o(s),l=n(16),u=n(9),c=n(28),h=n(353),d=o(h),f=n(354),p=o(f),g=n(355),v=o(g),m=n(356),y=o(m),w=n(357),C=o(w),b=n(358),E=o(b),_=n(359),S=o(_),O=n(360),T=o(O),R=n(361),k=o(R),M=(0,a.default)("cellTypes"),N=M.register,D=M.getItem,A=M.hasItem,H=M.getNames,P=M.getValues;i("autocomplete",d.default),i("checkbox",p.default),i("date",v.default),i("dropdown",y.default),i("handsontable",C.default),i("numeric",E.default),i("password",S.default),i("text",T.default),i("time",k.default),t.registerCellType=i,t.getCellType=r,t.hasCellType=A,t.getRegisteredCellTypeNames=H,t.getRegisteredCellTypes=P},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}function r(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);e.length>t;t++)n[t]=e[t];return n}return Array.from(e)}function i(e,t){function n(e){var t=(0,U.normalizeLanguageCode)(e);(0,V.hasLanguageDictionary)(t)?(K.runHooks("beforeLanguageChange",t),k.settings.language=t,K.runHooks("afterLanguageChange",t)):(0,U.warnUserAboutLanguageRegistration)(e)}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 i(e,t,n){function r(){var o;e.length&&(o=K.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 a=e[s][0],l=N.propToCol(e[s][1]),h=K.getCellMeta(a,l),p=h.numericFormat,g=p&&p.culture,v=p&&p.pattern;if("numeric"===h.type&&"string"==typeof e[s][3]&&e[s][3].length>0&&(/^-?[\d\s]*(\.|,)?\d*$/.test(e[s][3])||v)){var m=e[s][3].length;u.default.culture((0,f.isUndefined)(g)?"en-US":e[s][3].indexOf(".")===m-3&&-1===e[s][3].indexOf(",")?"en-US":g),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]}K.getCellValidator(h)&&(i.addValidatorToQueue(),K.validateCell(e[s][3],h,function(t,n){return function(o){if("boolean"!=typeof o)throw Error("Validation error: result is not boolean");if(!1===o&&!1===n.allowInvalid){e.splice(t,1),n.valid=!0;var r=K.getCell(n.visualRow,n.visualCol);(0,c.removeClass)(r,K.getSettings().invalidCellClassName),--t}i.removeValidatorFormQueue()}}(s,h),t))}i.checkIfQueueIsEmpty()}function l(e,t){var n=e.length-1;if(n>=0){for(;n>=0;n--){var o=!1;if(null!==e[n]){if(null!=e[n][2]||null!=e[n][3]){if(k.settings.allowInsertRow)for(;e[n][0]>K.countRows()-1;){var r=N.createRow(void 0,void 0,t);if(0===r){o=!0;break}}if(!o){if("array"===K.dataType&&(!k.settings.columns||0===k.settings.columns.length)&&k.settings.allowInsertColumn)for(;N.propToCol(e[n][1])>K.countCols()-1;)N.createCol(void 0,void 0,t);N.set(e[n][0],e[n][1],e[n][3])}}}else e.splice(n,1)}K.forceFullRender=!0,j.adjustRowsAndCols(),K.runHooks("beforeChangeRender",e,t),z.refreshBorders(null,!0),K.view.wt.wtOverlays.adjustElementsSize(),K.runHooks("afterChange",e,t||"edit");var i=K.getActiveEditor();i&&(0,f.isDefined)(i.refreshValue)&&i.refreshValue()}}function g(e,t,n){return"object"===(void 0===e?"undefined":a(e))?e:[[e,t,n]]}function m(e){if((0,b.hasOwnProperty)(e,"type")){var t,n={};"object"===a(e.type)?t=e.type:"string"==typeof e.type&&(t=(0,F.getCellType)(e.type));for(var o in t)(0,b.hasOwnProperty)(t,o)&&!(0,b.hasOwnProperty)(e,o)&&(n[o]=t[o]);return n}}function w(){throw Error("This method cannot be called because this Handsontable instance has been destroyed")}var k,N,L,j,z,G,X=arguments.length>2&&void 0!==arguments[2]&&arguments[2],K=this,q=function(){},$=new C.default(K);(0,b.extend)(q.prototype,W.default.prototype),(0,b.extend)(q.prototype,t),(0,b.extend)(q.prototype,m(t)),(0,U.applyLanguageSetting)(t.language,q.prototype),(0,P.hasValidParameter)(X)&&(0,P.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,T.randomString)();var J=(0,H.getTranslator)(K);L=new D.default(K),this.rootElement.id&&"ht_"!==this.rootElement.id.substring(0,3)||(this.rootElement.id=this.guid),k={cellSettings:[],columnSettings:[],columnsSettingConflicts:["data","width","language"],settings:new q,selRange:null,isPopulated:null,scrollable:null,firstRun:!0},j={alter:function(e,t,n,o,i){function s(e,t,n,o){var i=function(){var e=void 0;return"array"===o?e=[]:"object"===o&&(e={}),e},s=(0,E.arrayMap)(Array(n),function(){return i()});s.unshift(t,0),e.splice.apply(e,r(s))}var a;switch(n=n||1,e){case"insert_row":var l=K.countSourceRows();if(K.getSettings().maxRows===l)return;t=(0,f.isDefined)(t)?t:l,a=N.createRow(t,n,o),s(k.cellSettings,t,n,"array"),a&&(z.isSelected()&&k.selRange.from.row>=t?(k.selRange.from.row+=a,z.transformEnd(a,0)):z.refreshBorders());break;case"insert_col":a=N.createCol(t,n,o);for(var u=0,c=K.countSourceRows();c>u;u++)k.cellSettings[u]&&s(k.cellSettings[u],t,n);if(a){if(Array.isArray(K.getSettings().colHeaders)){var h=[t,0];h.length+=a,Array.prototype.splice.apply(K.getSettings().colHeaders,h)}z.isSelected()&&k.selRange.from.col>=t?(k.selRange.from.col+=a,z.transformEnd(0,a)):z.refreshBorders()}break;case"remove_row":N.removeRow(t,n,o),k.cellSettings.splice(t,n);var d=K.countRows(),p=K.getSettings().fixedRowsTop;t+1>p||(K.getSettings().fixedRowsTop-=Math.min(n,p-t));var g=K.getSettings().fixedRowsBottom;g&&t>=d-g&&(K.getSettings().fixedRowsBottom-=Math.min(n,g)),j.adjustRowsAndCols(),z.refreshBorders();break;case"remove_col":var v=J.toPhysicalColumn(t);N.removeCol(t,n,o);for(var m=0,y=K.countSourceRows();y>m;m++)k.cellSettings[m]&&k.cellSettings[m].splice(v,n);var w=K.getSettings().fixedColumnsLeft;t+1>w||(K.getSettings().fixedColumnsLeft-=Math.min(n,w-t)),Array.isArray(K.getSettings().colHeaders)&&(void 0===v&&(v=-1),K.getSettings().colHeaders.splice(v,n)),j.adjustRowsAndCols(),z.refreshBorders();break;default:throw Error('There is no such action "'+e+'"')}i||j.adjustRowsAndCols()},adjustRowsAndCols:function(){if(k.settings.minRows){var e=K.countRows();if(k.settings.minRows>e)for(var t=0,n=k.settings.minRows;n-e>t;t++)N.createRow(K.countRows(),1,"auto")}if(k.settings.minSpareRows){var o=K.countEmptyRows(!0);if(k.settings.minSpareRows>o)for(;k.settings.minSpareRows>o&&K.countSourceRows()<k.settings.maxRows;o++)N.createRow(K.countRows(),1,"auto")}var r=void 0;if((k.settings.minCols||k.settings.minSpareCols)&&(r=K.countEmptyCols(!0)),k.settings.minCols&&!k.settings.columns&&K.countCols()<k.settings.minCols)for(;K.countCols()<k.settings.minCols;r++)N.createCol(K.countCols(),1,"auto");if(k.settings.minSpareCols&&!k.settings.columns&&"array"===K.dataType&&k.settings.minSpareCols>r)for(;k.settings.minSpareCols>r&&K.countCols()<k.settings.maxCols;r++)N.createCol(K.countCols(),1,"auto");var i=K.countRows(),s=K.countCols();if(0!==i&&0!==s||z.deselect(),z.isSelected()){var a=!1,l=k.selRange.from.row,u=k.selRange.from.col,c=k.selRange.to.row,h=k.selRange.to.col;l>i-1?(l=i-1,a=!0,c>l&&(c=l)):c>i-1&&(c=i-1,a=!0,l>c&&(l=c)),u>s-1?(u=s-1,a=!0,h>u&&(h=u)):h>s-1&&(h=s-1,a=!0,u>h&&(u=h)),a&&K.selectCell(l,u,c,h)}K.view&&K.view.wt.wtOverlays.adjustElementsSize()},populateFromArray:function(e,t,n,o,i,s,l){var u,c,h,d,p=[],g={};if(0===(c=t.length))return!1;var v,m,y,w;switch(i){case"shift_down":for(v=n?n.col-e.col+1:0,m=n?n.row-e.row+1:0,t=(0,A.translateRowsToColumns)(t),h=0,d=t.length,y=Math.max(d,v);y>h;h++)if(d>h){var C;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),(C=K).spliceCol.apply(C,r(t[h]))}else{var E;t[h%d][0]=e.col+h,(E=K).spliceCol.apply(E,r(t[h%d]))}break;case"shift_right":for(v=n?n.col-e.col+1:0,m=n?n.row-e.row+1:0,u=0,c=t.length,w=Math.max(c,m);w>u;u++)if(c>u){var _;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),(_=K).spliceRow.apply(_,r(t[u]))}else{var S;t[u%c][0]=e.row+u,(S=K).spliceRow.apply(S,r(t[u%c]))}break;case"overwrite":default:g.row=e.row,g.col=e.col;var O={row:n&&e?n.row-e.row+1:1,col:n&&e?n.col-e.col+1:1},T=0,R=0,M=!0,N=void 0,D=function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,o=t[e%t.length];return null!==n?o[n%o.length]:o},H=t.length,P=n?n.row-e.row+1:0;for(c=n?P:Math.max(H,P),u=0;c>u&&(!(n&&g.row>n.row&&P>H||!k.settings.allowInsertRow&&g.row>K.countRows()-1)&&g.row<k.settings.maxRows);u++){var x=u-T,L=D(x).length,I=n?n.col-e.col+1:0;if(d=n?I:Math.max(L,I),g.col=e.col,N=K.getCellMeta(g.row,g.col),"CopyPaste.paste"!==o&&"Autofill.autofill"!==o||!N.skipRowOnPaste){for(R=0,h=0;d>h&&(!(n&&g.col>n.col&&I>L||!k.settings.allowInsertColumn&&g.col>K.countCols()-1)&&g.col<k.settings.maxCols);h++)if(N=K.getCellMeta(g.row,g.col),"CopyPaste.paste"!==o&&"Autofill.fill"!==o||!N.skipColumnOnPaste)if(N.readOnly)g.col++;else{var j=h-R,W=D(x,j),F=K.getDataAtCell(g.row,g.col),B={row:x,col:j};if("Autofill.fill"===o){var V=K.runHooks("beforeAutofillInsidePopulate",B,s,t,l,{},O);V&&(W=(0,f.isUndefined)(V.value)?W:V.value)}if(null!==W&&"object"===(void 0===W?"undefined":a(W)))if(null===F||"object"!==(void 0===F?"undefined":a(F)))M=!1;else{var U=(0,b.duckSchema)(F[0]||F),Y=(0,b.duckSchema)(W[0]||W);(0,b.isObjectEquals)(U,Y)?W=(0,b.deepClone)(W):M=!1}else null!==F&&"object"===(void 0===F?"undefined":a(F))&&(M=!1);M&&p.push([g.row,g.col,W]),M=!0,g.col++}else R++,g.col++,d++;g.row++}else T++,g.row++,c++}K.setDataAtCell(p,null,null,o||"populateFromArray")}}},this.selection=z={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],n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];K.selection.selectedHeader.rows=e,K.selection.selectedHeader.cols=t,K.selection.selectedHeader.corner=n},begin:function(){K.selection.inProgress=!0},finish:function(){var e=K.getSelected();K.runHooks("afterSelectionEnd",e[0],e[1],e[2],e[3]),K.runHooks("afterSelectionEndByProp",e[0],K.colToProp(e[1]),e[2],K.colToProp(e[3])),K.selection.inProgress=!1},isInProgress:function(){return K.selection.inProgress},setRangeStart:function(e,t){K.runHooks("beforeSetRangeStart",e),k.selRange=new x.CellRange(e,e,e),z.setRangeEnd(e,null,t)},setRangeStartOnly:function(e){K.runHooks("beforeSetRangeStartOnly",e),k.selRange=new x.CellRange(e,e,e)},setRangeEnd:function(e,t,n){if(null!==k.selRange){var o,r=!1,i=!0,s=K.view.wt.wtTable.getFirstVisibleRow(),a=K.view.wt.wtTable.getFirstVisibleColumn(),l={row:null,col:null};K.runHooks("beforeSetRangeEnd",e),K.selection.begin(),l.row=0>e.row?s:e.row,l.col=0>e.col?a:e.col,k.selRange.to=new x.CellCoords(l.row,l.col),k.settings.multiSelect||(k.selRange.from=e),K.view.wt.selections.current.clear(),o=K.getCellMeta(k.selRange.highlight.row,k.selRange.highlight.col).disableVisualSelection,"string"==typeof o&&(o=[o]),(!1===o||Array.isArray(o)&&-1===o.indexOf("current"))&&K.view.wt.selections.current.add(k.selRange.highlight),K.view.wt.selections.area.clear(),(!1===o||Array.isArray(o)&&-1===o.indexOf("area"))&&z.isMultiple()&&(K.view.wt.selections.area.add(k.selRange.from),K.view.wt.selections.area.add(k.selRange.to)),(k.settings.currentHeaderClassName||k.settings.currentRowClassName||k.settings.currentColClassName)&&(K.view.wt.selections.highlight.clear(),K.view.wt.selections.highlight.add(k.selRange.from),K.view.wt.selections.highlight.add(k.selRange.to));var u=(0,b.createObjectPropListener)("value");K.runHooks("afterSelection",k.selRange.from.row,k.selRange.from.col,k.selRange.to.row,k.selRange.to.col,u),K.runHooks("afterSelectionByProp",k.selRange.from.row,N.colToProp(k.selRange.from.col),k.selRange.to.row,N.colToProp(k.selRange.to.col),u),(K.selection.selectedHeader.cols||K.selection.selectedHeader.rows)&&(r=!0),(0>e.row||0>e.col)&&(i=!1),u.isTouched()&&(t=!u.value),!1!==t&&!r&&i&&K.view.scrollViewport(k.selRange.from&&!z.isMultiple()?k.selRange.from:e),z.selectedHeader.rows&&z.selectedHeader.cols?(0,c.addClass)(K.rootElement,["ht__selection--rows","ht__selection--columns"]):z.selectedHeader.rows?((0,c.removeClass)(K.rootElement,"ht__selection--columns"),(0,c.addClass)(K.rootElement,"ht__selection--rows")):z.selectedHeader.cols?((0,c.removeClass)(K.rootElement,"ht__selection--rows"),(0,c.addClass)(K.rootElement,"ht__selection--columns")):(0,c.removeClass)(K.rootElement,["ht__selection--rows","ht__selection--columns"]),z.refreshBorders(null,n)}},refreshBorders:function(e,t){t||G.destroyEditor(e),K.view.render(),z.isSelected()&&!t&&G.prepareEditor()},isMultiple:function(){var e=!(k.selRange.to.col===k.selRange.from.col&&k.selRange.to.row===k.selRange.from.row),t=K.runHooks("afterIsMultipleSelection",e);if(e)return t},transformStart:function(e,t,n,o){var r,i,s,a,l=new x.CellCoords(e,t),u=0,c=0;K.runHooks("modifyTransformStart",l),r=K.countRows(),i=K.countCols(),a=K.getSettings().fixedRowsBottom,k.selRange.highlight.row+e>r-1?n&&k.settings.minSpareRows>0&&(!a||r-a-1>k.selRange.highlight.row)?(K.alter("insert_row",r),r=K.countRows()):k.settings.autoWrapCol&&(l.row=1-r,l.col=k.selRange.highlight.col+l.col==i-1?1-i:1):k.settings.autoWrapCol&&0>k.selRange.highlight.row+l.row&&k.selRange.highlight.col+l.col>=0&&(l.row=r-1,l.col=k.selRange.highlight.col+l.col==0?i-1:-1),k.selRange.highlight.col+l.col>i-1?n&&k.settings.minSpareCols>0?(K.alter("insert_col",i),i=K.countCols()):k.settings.autoWrapRow&&(l.row=k.selRange.highlight.row+l.row==r-1?1-r:1,l.col=1-i):k.settings.autoWrapRow&&0>k.selRange.highlight.col+l.col&&k.selRange.highlight.row+l.row>=0&&(l.row=k.selRange.highlight.row+l.row==0?r-1:-1,l.col=i-1),s=new x.CellCoords(k.selRange.highlight.row+l.row,k.selRange.highlight.col+l.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),K.runHooks("afterModifyTransformStart",s,u,c),z.setRangeStart(s,o)},transformEnd:function(e,t){var n,o,r,i=new x.CellCoords(e,t),s=0,a=0;K.runHooks("modifyTransformEnd",i),n=K.countRows(),o=K.countCols(),r=new x.CellCoords(k.selRange.to.row+i.row,k.selRange.to.col+i.col),0>r.row?(s=-1,r.row=0):r.row>0&&r.row>=n&&(s=1,r.row=n-1),0>r.col?(a=-1,r.col=0):r.col>0&&r.col>=o&&(a=1,r.col=o-1),K.runHooks("afterModifyTransformEnd",r,s,a),z.setRangeEnd(r,!0)},isSelected:function(){return null!==k.selRange},inInSelection:function(e){return!!z.isSelected()&&k.selRange.includes(e)},deselect:function(){z.isSelected()&&(K.selection.inProgress=!1,k.selRange=null,K.view.wt.selections.current.clear(),K.view.wt.selections.area.clear(),(k.settings.currentHeaderClassName||k.settings.currentRowClassName||k.settings.currentColClassName)&&K.view.wt.selections.highlight.clear(),G.destroyEditor(),z.refreshBorders(),(0,c.removeClass)(K.rootElement,["ht__selection--rows","ht__selection--columns"]),K.runHooks("afterDeselect"))},selectAll:function(){k.settings.multiSelect&&(z.setSelectedHeaders(!0,!0,!0),z.setRangeStart(new x.CellCoords(0,0)),z.setRangeEnd(new x.CellCoords(K.countRows()-1,K.countCols()-1),!1))},empty:function(){if(z.isSelected()){var e,t,n=k.selRange.getTopLeftCorner(),o=k.selRange.getBottomRightCorner(),r=[];for(e=n.row;o.row>=e;e++)for(t=n.col;o.col>=t;t++)K.getCellMeta(e,t).readOnly||r.push([e,t,""]);K.setDataAtCell(r)}}},this.init=function(){L.setData(k.settings.data),K.runHooks("beforeInit"),(0,p.isMobileBrowser)()&&(0,c.addClass)(K.rootElement,"mobile"),this.updateSettings(k.settings,!0),this.view=new M.default(this),G=new y.default(K,k,z,N),this.forceFullRender=!0,K.runHooks("init"),this.view.render(),"object"===a(k.firstRun)&&(K.runHooks("afterChange",k.firstRun[0],k.firstRun[1]),k.firstRun=!1),K.runHooks("afterInit")},this.validateCell=function(e,t,n,o){function r(e){var o=t.visualCol,r=t.visualRow,i=K.getCell(r,o,!0);i&&"TH"!=i.nodeName&&K.view.wt.wtSettings.settings.cellRenderer(r,o,i),n(e)}var i=K.getCellValidator(t);(0,f.isRegExp)(i)&&(i=function(e){return function(t,n){n(e.test(t))}}(i)),(0,d.isFunction)(i)?(e=K.runHooks("beforeValidate",e,t.visualRow,t.prop,o),K._registerTimeout(setTimeout(function(){i.call(t,e,function(n){n=K.runHooks("afterValidate",n,e,t.visualRow,t.prop,o),t.valid=n,r(n),K.runHooks("postAfterValidate",n,e,t.visualRow,t.prop,o)})},0))):K._registerTimeout(setTimeout(function(){t.valid=!0,r(t.valid)},0))},this.setDataAtCell=function(e,t,n,o){var r,s,u,c=g(e,t,n),h=[];for(r=0,s=c.length;s>r;r++){if("object"!==a(c[r]))throw Error("Method `setDataAtCell` accepts row number or changes array of arrays as its first parameter");if("number"!=typeof c[r][1])throw Error("Method `setDataAtCell` accepts row and column number as its parameters. If you want to use object property name, use method `setDataAtRowProp`");u=N.colToProp(c[r][1]),h.push([c[r][0],u,L.getAtCell(J.toPhysicalRow(c[r][0]),c[r][1]),c[r][2]])}o||"object"!==(void 0===e?"undefined":a(e))||(o=t),K.runHooks("afterSetDataAtCell",h,o),i(h,o,function(){l(h,o)})},this.setDataAtRowProp=function(e,t,n,o){var r,s,u=g(e,t,n),c=[];for(r=0,s=u.length;s>r;r++)c.push([u[r][0],u[r][1],L.getAtCell(J.toPhysicalRow(u[r][0]),u[r][1]),u[r][2]]);o||"object"!==(void 0===e?"undefined":a(e))||(o=t),K.runHooks("afterSetDataAtRowProp",c,o),i(c,o,function(){l(c,o)})},this.listen=function(){if(0>=arguments.length||void 0===arguments[0]||arguments[0]){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()}K&&!K.isListening()&&(Y=K.guid,K.runHooks("afterListen"))},this.unlisten=function(){this.isListening()&&(Y=null,K.runHooks("afterUnlisten"))},this.isListening=function(){return Y===K.guid},this.destroyEditor=function(e){z.refreshBorders(e)},this.populateFromArray=function(e,t,n,o,r,i,s,l,u){var c;if("object"!==(void 0===n?"undefined":a(n))||"object"!==a(n[0]))throw Error("populateFromArray parameter `input` must be an array of arrays");return c="number"==typeof o?new x.CellCoords(o,r):null,j.populateFromArray(new x.CellCoords(e,t),n,c,i,s,l,u)},this.spliceCol=function(e,t,n){var o;return(o=N).spliceCol.apply(o,arguments)},this.spliceRow=function(e,t,n){var o;return(o=N).spliceRow.apply(o,arguments)},this.getSelected=function(){if(z.isSelected())return[k.selRange.from.row,k.selRange.from.col,k.selRange.to.row,k.selRange.to.col]},this.getSelectedRange=function(){if(z.isSelected())return k.selRange},this.render=function(){K.view&&(K.renderCall=!0,K.forceFullRender=!0,z.refreshBorders(null,!0))},this.loadData=function(e){if(K.dataType=Array.isArray(k.settings.dataSchema)?"array":(0,d.isFunction)(k.settings.dataSchema)?"function":"object",N&&N.destroy(),N=new v.default(K,k,q),"object"===(void 0===e?"undefined":a(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":a(e))+" given)");e=[];var t,n=0,o=0,r=N.getSchema();for(n=0,o=k.settings.startRows;o>n;n++)if("object"!==K.dataType&&"function"!==K.dataType||!k.settings.dataSchema)if("array"===K.dataType)t=(0,b.deepClone)(r[0]),e.push(t);else{t=[];for(var i=0,s=k.settings.startCols;s>i;i++)t.push(null);e.push(t)}else t=(0,b.deepClone)(r),e.push(t)}k.isPopulated=!1,q.prototype.data=e,Array.isArray(e[0])&&(K.dataType="array"),N.dataSource=e,L.data=e,L.dataType=K.dataType,L.colToProp=N.colToProp.bind(N),L.propToCol=N.propToCol.bind(N),function(){k.cellSettings.length=0}(),j.adjustRowsAndCols(),K.runHooks("afterLoadData",k.firstRun),k.firstRun?k.firstRun=[null,"loadData"]:(K.runHooks("afterChange",null,"loadData"),K.render()),k.isPopulated=!0},this.getData=function(e,t,n,o){return(0,f.isUndefined)(e)?N.getAll():N.getRange(new x.CellCoords(e,t),new x.CellCoords(n,o),N.DESTINATION_RENDERER)},this.getCopyableText=function(e,t,n,o){return N.getCopyableText(new x.CellCoords(e,t),new x.CellCoords(n,o))},this.getCopyableData=function(e,t){return N.getCopyable(e,N.colToProp(t))},this.getSchema=function(){return N.getSchema()},this.updateSettings=function(e,t){var o=!1,r=void 0,i=void 0,s=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(r in e)"data"!==r&&("language"!==r?I.default.getSingleton().getRegistered().indexOf(r)>-1?((0,d.isFunction)(e[r])||Array.isArray(e[r]))&&(e[r].initialHook=!0,K.addHook(r,e[r])):!t&&(0,b.hasOwnProperty)(e,r)&&(q.prototype[r]=e[r]):n(e.language));void 0===e.data&&void 0===k.settings.data?K.loadData(null):void 0!==e.data?K.loadData(e.data):void 0!==e.columns&&N.createMap(),s=K.countCols();var a=e.columns||q.prototype.columns;if(a&&(0,d.isFunction)(a)&&(s=K.countSourceCols(),o=!0),void 0===e.cell&&void 0===e.cells&&void 0===e.columns||(k.cellSettings.length=0),s>0){var l=void 0,u=void 0;for(r=0,i=0;s>r;r++)o&&!a(r)||(k.columnSettings[i]=(0,h.columnFactory)(q,k.columnsSettingConflicts),l=k.columnSettings[i].prototype,a&&(u=o?a(r):a[i])&&((0,b.extend)(l,u),(0,b.extend)(l,m(u))),i++)}if((0,f.isDefined)(e.cell))for(var p in e.cell)if((0,b.hasOwnProperty)(e.cell,p)){var g=e.cell[p];K.setCellMetaObject(g.row,g.col,g)}K.runHooks("afterCellMetaReset"),(0,f.isDefined)(e.className)&&(q.prototype.className&&(0,c.removeClass)(K.rootElement,q.prototype.className),e.className&&(0,c.addClass)(K.rootElement,e.className));var v=K.rootElement.style.height;""!==v&&(v=parseInt(K.rootElement.style.height,10));var y=e.height;if((0,d.isFunction)(y)&&(y=y()),t){K.rootElement.getAttribute("style")&&K.rootElement.setAttribute("data-initialstyle",K.rootElement.getAttribute("style"))}if(null===y){var w=K.rootElement.getAttribute("data-initialstyle");w&&(w.indexOf("height")>-1||w.indexOf("overflow")>-1)?K.rootElement.setAttribute("style",w):(K.rootElement.style.height="",K.rootElement.style.overflow="")}else void 0!==y&&(K.rootElement.style.height=y+"px",K.rootElement.style.overflow="hidden");if(void 0!==e.width){var C=e.width;(0,d.isFunction)(C)&&(C=C()),K.rootElement.style.width=C+"px"}t||(N.clearLengthCache(),K.view&&K.view.wt.wtViewport.resetHasOversizedColumnHeadersMarked(),K.runHooks("afterUpdateSettings",e)),j.adjustRowsAndCols(),K.view&&!k.firstRun&&(K.forceFullRender=!0,z.refreshBorders(null,!0)),t||!K.view||""!==v&&""!==y&&void 0!==y||v===y||K.view.wt.wtOverlays.updateMainScrollableElements()},this.getValue=function(){var e=K.getSelected();if(q.prototype.getValue){if((0,d.isFunction)(q.prototype.getValue))return q.prototype.getValue.call(K);if(e)return K.getData()[e[0]][q.prototype.getValue]}else if(e)return K.getDataAtCell(e[0],e[1])},this.getSettings=function(){return k.settings},this.clear=function(){z.selectAll(),z.empty()},this.alter=function(e,t,n,o,r){j.alter(e,t,n,o,r)},this.getCell=function(e,t,n){return K.view.getCellAtCoords(new x.CellCoords(e,t),n)},this.getCoords=function(e){return this.view.wt.wtTable.getCoords.call(this.view.wt.wtTable,e)},this.colToProp=function(e){return N.colToProp(e)},this.propToCol=function(e){return N.propToCol(e)},this.toVisualRow=function(e){return J.toVisualRow(e)},this.toVisualColumn=function(e){return J.toVisualColumn(e)},this.toPhysicalRow=function(e){return J.toPhysicalRow(e)},this.toPhysicalColumn=function(e){return J.toPhysicalColumn(e)},this.getDataAtCell=function(e,t){return N.get(e,N.colToProp(t))},this.getDataAtRowProp=function(e,t){return N.get(e,t)},this.getDataAtCol=function(e){var t=[];return t.concat.apply(t,r(N.getRange(new x.CellCoords(0,e),new x.CellCoords(k.settings.data.length-1,e),N.DESTINATION_RENDERER)))},this.getDataAtProp=function(e){var t,n=[];return t=N.getRange(new x.CellCoords(0,N.propToCol(e)),new x.CellCoords(k.settings.data.length-1,N.propToCol(e)),N.DESTINATION_RENDERER),n.concat.apply(n,r(t))},this.getSourceData=function(e,t,n,o){return void 0===e?L.getData():L.getByRange(new x.CellCoords(e,t),new x.CellCoords(n,o))},this.getSourceDataArray=function(e,t,n,o){return void 0===e?L.getData(!0):L.getByRange(new x.CellCoords(e,t),new x.CellCoords(n,o),!0)},this.getSourceDataAtCol=function(e){return L.getAtColumn(e)},this.getSourceDataAtRow=function(e){return L.getAtRow(e)},this.getSourceDataAtCell=function(e,t){return L.getAtCell(e,t)},this.getDataAtRow=function(e){return N.getRange(new x.CellCoords(e,0),new x.CellCoords(e,this.countCols()-1),N.DESTINATION_RENDERER)[0]||[]},this.getDataType=function(e,t,n,o){var r=this,i=null,s=null;void 0===e&&(e=0,n=this.countRows(),t=0,o=this.countCols()),void 0===n&&(n=e),void 0===o&&(o=t);var a="mixed";return(0,R.rangeEach)(Math.min(e,n),Math.max(e,n),function(e){var n=!0;return(0,R.rangeEach)(Math.min(t,o),Math.max(t,o),function(t){var o=r.getCellMeta(e,t);return s=o.type,i?n=i===s:i=s,n}),a=n?s:"mixed",n}),a},this.removeCellMeta=function(e,t,n){var o=J.toPhysical(e,t),r=s(o,2),i=r[0],a=r[1],l=k.cellSettings[i][a][n];!1!==K.runHooks("beforeRemoveCellMeta",e,t,n,l)&&(delete k.cellSettings[i][a][n],K.runHooks("afterRemoveCellMeta",e,t,n,l)),l=null},this.spliceCellsMeta=function(e,t){for(var n,o=arguments.length,r=Array(o>2?o-2:0),i=2;o>i;i++)r[i-2]=arguments[i];(n=k.cellSettings).splice.apply(n,[e,t].concat(r))},this.setCellMetaObject=function(e,t,n){if("object"===(void 0===n?"undefined":a(n)))for(var o in n)if((0,b.hasOwnProperty)(n,o)){var r=n[o];this.setCellMeta(e,t,o,r)}},this.setCellMeta=function(e,t,n,o){var r=J.toPhysical(e,t),i=s(r,2),a=i[0],l=i[1];k.columnSettings[l]||(k.columnSettings[l]=(0,h.columnFactory)(q,k.columnsSettingConflicts)),k.cellSettings[a]||(k.cellSettings[a]=[]),k.cellSettings[a][l]||(k.cellSettings[a][l]=new k.columnSettings[l]),k.cellSettings[a][l][n]=o,K.runHooks("afterSetCellMeta",e,t,n,o)},this.getCellsMeta=function(){return(0,E.arrayFlatten)(k.cellSettings)},this.getCellMeta=function(e,t){var n=N.colToProp(t),o=void 0,r=J.toPhysical(e,t),i=s(r,2),a=i[0],l=i[1];if(k.columnSettings[l]||(k.columnSettings[l]=(0,h.columnFactory)(q,k.columnsSettingConflicts)),k.cellSettings[a]||(k.cellSettings[a]=[]),k.cellSettings[a][l]||(k.cellSettings[a][l]=new k.columnSettings[l]),o=k.cellSettings[a][l],o.row=a,o.col=l,o.visualRow=e,o.visualCol=t,o.prop=n,o.instance=K,K.runHooks("beforeGetCellMeta",e,t,o),(0,b.extend)(o,m(o)),o.cells){var u=o.cells.call(o,a,l,n);u&&((0,b.extend)(o,u),(0,b.extend)(o,m(u)))}return K.runHooks("afterGetCellMeta",e,t,o),o},this.getCellMetaAtRow=function(e){return k.cellSettings[e]},this.isColumnModificationAllowed=function(){return!("object"===K.dataType||K.getSettings().columns)};var Z=(0,A.cellMethodLookupFactory)("renderer");this.getCellRenderer=function(e,t){return(0,S.getRenderer)(Z.call(this,e,t))},this.getCellEditor=(0,A.cellMethodLookupFactory)("editor");var Q=(0,A.cellMethodLookupFactory)("validator");this.getCellValidator=function(e,t){var n=Q.call(this,e,t);return"string"==typeof n&&(n=(0,O.getValidator)(n)),n},this.validateCells=function(e){this._validateCells(e)},this.validateRows=function(e,t){if(!Array.isArray(e))throw Error("validateRows parameter `rows` must be an array");this._validateCells(t,e)},this.validateColumns=function(e,t){if(!Array.isArray(e))throw Error("validateColumns parameter `columns` must be an array");this._validateCells(t,void 0,e)},this._validateCells=function(e,t,n){var r=new o;e&&(r.onQueueEmpty=e);for(var i=K.countRows()-1;i>=0;)if(void 0===t||-1!==t.indexOf(i)){for(var s=K.countCols()-1;s>=0;)void 0===n||-1!==n.indexOf(s)?(r.addValidatorToQueue(),K.validateCell(K.getDataAtCell(i,s),K.getCellMeta(i,s),function(e){if("boolean"!=typeof e)throw Error("Validation error: result is not boolean");!1===e&&(r.valid=!1),r.removeValidatorFormQueue()},"validateCells"),s--):s--;i--}else i--;r.checkIfQueueIsEmpty()},this.getRowHeader=function(e){var t=k.settings.rowHeaders;return void 0!==e&&(e=K.runHooks("modifyRowHeader",e)),void 0===e?(t=[],(0,R.rangeEach)(K.countRows()-1,function(e){t.push(K.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!!k.settings.rowHeaders},this.hasColHeaders=function(){if(void 0!==k.settings.colHeaders&&null!==k.settings.colHeaders)return!!k.settings.colHeaders;for(var e=0,t=K.countCols();t>e;e++)if(K.getColHeader(e))return!0;return!1},this.getColHeader=function(e){var t=k.settings.columns&&(0,d.isFunction)(k.settings.columns),n=k.settings.colHeaders;if(void 0===(e=K.runHooks("modifyColHeader",e))){for(var o=[],r=t?K.countSourceCols():K.countCols(),i=0;r>i;i++)o.push(K.getColHeader(i));n=o}else{var s=e;e=K.runHooks("modifyCol",e);var a=function(e){for(var t=[],n=K.countSourceCols(),o=0;n>o;o++)(0,d.isFunction)(K.getSettings().columns)&&K.getSettings().columns(o)&&t.push(o);return t[e]}(e);k.settings.columns&&(0,d.isFunction)(k.settings.columns)&&k.settings.columns(a)&&k.settings.columns(a).title?n=k.settings.columns(a).title:k.settings.columns&&k.settings.columns[e]&&k.settings.columns[e].title?n=k.settings.columns[e].title:Array.isArray(k.settings.colHeaders)&&void 0!==k.settings.colHeaders[e]?n=k.settings.colHeaders[e]:(0,d.isFunction)(k.settings.colHeaders)?n=k.settings.colHeaders(e):k.settings.colHeaders&&"string"!=typeof k.settings.colHeaders&&"number"!=typeof k.settings.colHeaders&&(n=(0,A.spreadsheetColumnLabel)(s))}return n},this._getColWidthFromSettings=function(e){var t=K.getCellMeta(0,e),n=t.width;if(void 0!==n&&n!==k.settings.width||(n=t.colWidths),void 0!==n&&null!==n){switch(void 0===n?"undefined":a(n)){case"object":n=n[e];break;case"function":n=n(e)}"string"==typeof n&&(n=parseInt(n,10))}return n},this.getColWidth=function(e){var t=K._getColWidthFromSettings(e);return t=K.runHooks("modifyColWidth",t,e),void 0===t&&(t=x.ViewportColumnsCalculator.DEFAULT_WIDTH),t},this._getRowHeightFromSettings=function(e){var t=k.settings.rowHeights;if(void 0!==t&&null!==t){switch(void 0===t?"undefined":a(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=K._getRowHeightFromSettings(e);return t=K.runHooks("modifyRowHeight",t,e)},this.countSourceRows=function(){return K.runHooks("modifySourceLength")||(K.getSourceData()?K.getSourceData().length:0)},this.countSourceCols=function(){var e=K.getSourceData()&&K.getSourceData()[0]?K.getSourceData()[0]:[];return(0,b.isObject)(e)?(0,b.deepObjectSize)(e):e.length||0},this.countRows=function(){return N.getLength()},this.countCols=function(){var e=this.getSettings().maxCols,t=!1,n=0;if("array"===K.dataType&&(t=k.settings.data&&k.settings.data[0]&&k.settings.data[0].length),t&&(n=k.settings.data[0].length),k.settings.columns){if((0,d.isFunction)(k.settings.columns))if("array"===K.dataType){for(var o=0,r=0;n>r;r++)k.settings.columns(r)&&o++;n=o}else"object"!==K.dataType&&"function"!==K.dataType||(n=N.colToPropCache.length);else n=k.settings.columns.length}else"object"!==K.dataType&&"function"!==K.dataType||(n=N.colToPropCache.length);return Math.min(e,n)},this.rowOffset=function(){return K.view.wt.wtTable.getFirstRenderedRow()},this.colOffset=function(){return K.view.wt.wtTable.getFirstRenderedColumn()},this.countRenderedRows=function(){return K.view.wt.drawn?K.view.wt.wtTable.getRenderedRowsCount():-1},this.countVisibleRows=function(){return K.view.wt.drawn?K.view.wt.wtTable.getVisibleRowsCount():-1},this.countRenderedCols=function(){return K.view.wt.drawn?K.view.wt.wtTable.getRenderedColumnsCount():-1},this.countVisibleCols=function(){return K.view.wt.drawn?K.view.wt.wtTable.getVisibleColumnsCount():-1},this.countEmptyRows=function(e){for(var t,n=K.countRows()-1,o=0;n>=0;){if(t=K.runHooks("modifyRow",n),K.isEmptyRow(t))o++;else if(e)break;n--}return o},this.countEmptyCols=function(e){if(1>K.countRows())return 0;for(var t=K.countCols()-1,n=0;t>=0;){if(K.isEmptyCol(t))n++;else if(e)break;t--}return n},this.isEmptyRow=function(e){return k.settings.isEmptyRow.call(K,e)},this.isEmptyCol=function(e){return k.settings.isEmptyCol.call(K,e)},this.selectCell=function(e,t,n,o,r,i){var s;if(i=(0,f.isUndefined)(i)||!0===i,"number"!=typeof e||0>e||e>=K.countRows())return!1;if("number"!=typeof t||0>t||t>=K.countCols())return!1;if((0,f.isDefined)(n)){if("number"!=typeof n||0>n||n>=K.countRows())return!1;if("number"!=typeof o||0>o||o>=K.countCols())return!1}return s=new x.CellCoords(e,t),k.selRange=new x.CellRange(s,s,s),i&&K.listen(),(0,f.isUndefined)(n)?z.setRangeEnd(k.selRange.from,r):z.setRangeEnd(new x.CellCoords(n,o),r),K.selection.finish(),!0},this.selectCellByProp=function(e,t,n,o,r){var i;return arguments[1]=N.propToCol(arguments[1]),(0,f.isDefined)(arguments[3])&&(arguments[3]=N.propToCol(arguments[3])),(i=K).selectCell.apply(i,arguments)},this.deselectCell=function(){z.deselect()},this.scrollViewportTo=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],o=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(void 0!==e&&(0>e||e>=K.countRows()))return!1;if(void 0!==t&&(0>t||t>=K.countCols()))return!1;var r=!1;return void 0!==e&&void 0!==t&&(K.view.wt.wtOverlays.topOverlay.scrollTo(e,n),K.view.wt.wtOverlays.leftOverlay.scrollTo(t,o),r=!0),"number"==typeof e&&"number"!=typeof t&&(K.view.wt.wtOverlays.topOverlay.scrollTo(e,n),r=!0),"number"==typeof t&&"number"!=typeof e&&(K.view.wt.wtOverlays.leftOverlay.scrollTo(t,o),r=!0),r},this.destroy=function(){K._clearTimeouts(),K.view&&K.view.destroy(),L&&L.destroy(),L=null;(0,c.empty)(K.rootElement),$.destroy(),K.runHooks("afterDestroy"),I.default.getSingleton().destroy(K);for(var e in K)(0,b.hasOwnProperty)(K,e)&&((0,d.isFunction)(K[e])?K[e]=w:"guid"!==e&&(K[e]=null));N&&N.destroy(),N=null,k=null,j=null,z=null,G=null,K=null,q=null},this.getActiveEditor=function(){return G.getActiveEditor()},this.getPlugin=function(e){return(0,_.getPlugin)(this,e)},this.getInstance=function(){return K},this.addHook=function(e,t){I.default.getSingleton().add(e,t,K)},this.hasHook=function(e){return I.default.getSingleton().has(e,K)},this.addHookOnce=function(e,t){I.default.getSingleton().once(e,t,K)},this.removeHook=function(e,t){I.default.getSingleton().remove(e,t,K)},this.runHooks=function(e,t,n,o,r,i,s){return I.default.getSingleton().run(K,e,t,n,o,r,i,s)},this.getTranslatedPhrase=function(e,t){return(0,B.getTranslatedPhrase)(k.settings.language,e,t)},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(K,"construct")}t.__esModule=!0;var s=function(){function e(e,t){var n=[],o=!0,r=!1,i=void 0;try{for(var s,a=e[Symbol.iterator]();!(o=(s=a.next()).done)&&(n.push(s.value),!t||n.length!==t);o=!0);}catch(e){r=!0,i=e}finally{try{!o&&a.return&&a.return()}finally{if(r)throw i}}return n}return function(t,n){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),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};t.default=i;var l=n(65),u=o(l),c=n(0),h=n(85),d=n(37),f=n(17),p=n(27),g=n(362),v=o(g),m=n(365),y=o(m),w=n(4),C=o(w),b=n(1),E=n(2),_=n(6),S=n(9),O=n(28),T=n(33),R=n(5),k=n(366),M=o(k),N=n(367),D=o(N),A=n(86),H=n(290),P=n(291),x=n(13),L=n(8),I=o(L),j=n(292),W=o(j),F=n(83),B=n(293),V=n(66),U=n(294),Y=null},function(e,t,n){"use strict";function o(e,t){function n(){}(0,r.inherit)(n,e);for(var o=0,i=t.length;i>o;o++)n.prototype[t[o]]=void 0;return n}t.__esModule=!0,t.columnFactory=o;var r=n(1)},function(e,t,n){"use strict";function o(e){for(var t=e+1,n="",o=void 0;t>0;)o=(t-1)%f,n=String.fromCharCode(65+o)+n,t=parseInt((t-o)/f,10);return n}function r(e){var t=0;if(e)for(var n=0,o=e.length-1;e.length>n;n+=1,o-=1)t+=Math.pow(f,o)*(d.indexOf(e[n])+1);return--t}function i(){var e,t,n=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;n>e;e++){var s=[];for(t=0;r>t;t++)s.push(o(t)+(e+1));i.push(s)}return i}function s(){var e,t,n=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;n>e;e++){var s={};for(t=0;r>t;t++)s["prop"+t]=o(t)+(e+1);i.push(s)}return i}function a(e,t){for(var n=[],o=void 0,r=0;e>r;r++){o=[];for(var i=0;t>i;i++)o.push("");n.push(o)}return n}function l(e){var t,n,o,r,i=[],s=0;for(t=0,n=e.length;n>t;t++)for(o=0,r=e[t].length;r>o;o++)o==s&&(i.push([]),s++),i[o].push(e[t][o]);return i}function u(e,t){return t=void 0===t||t,function(n,o){return function n(o){if(o){if((0,h.hasOwnProperty)(o,e)&&void 0!==o[e])return o[e];if((0,h.hasOwnProperty)(o,"type")&&o.type){var r;if("string"!=typeof o.type)throw Error("Cell type must be a string ");if(r=(0,c.getCellType)(o.type),(0,h.hasOwnProperty)(r,e))return r[e];if(t)return}return n(Object.getPrototypeOf(o))}}("number"==typeof n?this.getCellMeta(n,o):n)}}t.__esModule=!0,t.spreadsheetColumnLabel=o,t.spreadsheetColumnIndex=r,t.createSpreadsheetData=i,t.createSpreadsheetObjectData=s,t.createEmptySpreadsheetData=a,t.translateRowsToColumns=l,t.cellMethodLookupFactory=u;var c=n(83),h=n(1),d="ABCDEFGHIJKLMNOPQRSTUVWXYZ",f=d.length},function(e,t,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=n(0),s=n(2);t.default=function(){function e(t){o(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 n={row:e};this.rows.push(n),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),n.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 n={col:e};this.columns.push(n),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),n.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,n=t.createDocumentFragment();return this.hot.hasRowHeaders()&&n.appendChild(this.createColElement(-1)),this.samples.forEach(function(t){(0,s.arrayEach)(t.strings,function(t){n.appendChild(e.createColElement(t.col))})}),n}},{key:"createRow",value:function(e){var t=this,n=document,o=n.createDocumentFragment(),r=n.createElement("th");return this.hot.hasRowHeaders()&&(this.hot.view.appendRowHeader(e,r),o.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 a=t.hot.getCellRenderer(s),l=n.createElement("td");a(t.hot,l,e,i,t.hot.colToProp(i),r.value,s),o.appendChild(l)})}),o}},{key:"createColumnHeadersRow",value:function(){var e=this,t=document,n=t.createDocumentFragment();if(this.hot.hasRowHeaders()){var o=t.createElement("th");this.hot.view.appendColHeader(-1,o),n.appendChild(o)}return this.samples.forEach(function(o){(0,s.arrayEach)(o.strings,function(o){var r=o.col,i=t.createElement("th");e.hot.view.appendColHeader(r,i),n.appendChild(i)})}),n}},{key:"createCol",value:function(e){var t=this,n=document,o=n.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 a=t.hot.getCellRenderer(s),l=n.createElement("td"),u=n.createElement("tr");a(t.hot,l,i,e,t.hot.colToProp(e),r.value,s),u.appendChild(l),o.appendChild(u)})}),o}},{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,n=t.createElement("col");return n.style.width=this.hot.view.wt.wtTable.getStretchedColumnWidth(e)+"px",n}},{key:"createTable",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=document,n=t.createDocumentFragment(),o=t.createElement("table"),r=t.createElement("thead"),s=t.createElement("tbody"),a=t.createElement("colgroup"),l=t.createElement("tr"),u=t.createElement("th");return this.isVertical()&&o.appendChild(a),this.isHorizontal()&&(l.appendChild(u),r.appendChild(l),o.style.tableLayout="auto",o.style.width="auto"),o.appendChild(r),this.isVertical()&&s.appendChild(l),o.appendChild(s),(0,i.addClass)(o,e),n.appendChild(o),{fragment:n,table:o,tHead:r,tBody:s,colGroup:a,tr:l,th:u}}},{key:"createContainer",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=document,n=t.createDocumentFragment(),o=t.createElement("div");return e="htGhostTable htAutoSize "+e.trim(),(0,i.addClass)(o,e),n.appendChild(o),{fragment:n,container:o}}},{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,n){"use strict";function o(){return{name:r}}t.__esModule=!0,t.default=o;var r=t.KEY="---------"},function(e,t,n){"use strict";t.__esModule=!0;var o=n(2),r=n(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,n=arguments.length,r=Array(n>1?n-1:0),i=1;n>i;i++)r[i-1]=arguments[i];this._localHooks[e]&&(0,o.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,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function i(){var e={};return(0,C.objectEach)(P,function(t,n){e[n]=t()}),e}function s(e,t){-1===H.indexOf(e)&&(P[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 a,l=n(387);Object.defineProperty(t,"ALIGNMENT",{enumerable:!0,get:function(){return l.KEY}});var u=n(388);Object.defineProperty(t,"CLEAR_COLUMN",{enumerable:!0,get:function(){return u.KEY}});var c=n(389);Object.defineProperty(t,"COLUMN_LEFT",{enumerable:!0,get:function(){return c.KEY}});var h=n(390);Object.defineProperty(t,"COLUMN_RIGHT",{enumerable:!0,get:function(){return h.KEY}});var d=n(391);Object.defineProperty(t,"READ_ONLY",{enumerable:!0,get:function(){return d.KEY}});var f=n(392);Object.defineProperty(t,"REDO",{enumerable:!0,get:function(){return f.KEY}});var p=n(393);Object.defineProperty(t,"REMOVE_COLUMN",{enumerable:!0,get:function(){return p.KEY}});var g=n(394);Object.defineProperty(t,"REMOVE_ROW",{enumerable:!0,get:function(){return g.KEY}});var v=n(395);Object.defineProperty(t,"ROW_ABOVE",{enumerable:!0,get:function(){return v.KEY}});var m=n(396);Object.defineProperty(t,"ROW_BELOW",{enumerable:!0,get:function(){return m.KEY}});var y=n(88);Object.defineProperty(t,"SEPARATOR",{enumerable:!0,get:function(){return y.KEY}});var w=n(397);Object.defineProperty(t,"UNDO",{enumerable:!0,get:function(){return w.KEY}}),t.predefinedItems=i,t.addItem=s;var C=n(1),b=o(l),E=o(u),_=o(c),S=o(h),O=o(d),T=o(f),R=o(p),k=o(g),M=o(v),N=o(m),D=o(y),A=o(w),H=t.ITEMS=[v.KEY,m.KEY,c.KEY,h.KEY,u.KEY,g.KEY,p.KEY,w.KEY,f.KEY,d.KEY,l.KEY,y.KEY],P=(a={},r(a,y.KEY,D.default),r(a,v.KEY,M.default),r(a,m.KEY,N.default),r(a,c.KEY,_.default),r(a,h.KEY,S.default),r(a,u.KEY,E.default),r(a,g.KEY,k.default),r(a,p.KEY,R.default),r(a,w.KEY,A.default),r(a,f.KEY,T.default),r(a,d.KEY,O.default),r(a,l.KEY,b.default),a)},function(e,t,n){"use strict";var o=n(92),r=n(41);e.exports=n(61)("Map",function(e){return function(){return e(this,arguments.length>0?arguments[0]:void 0)}},{get:function(e){var t=o.getEntry(r(this,"Map"),e);return t&&t.v},set:function(e,t){return o.def(r(this,"Map"),0===e?0:e,t)}},o,!0)},function(e,t,n){"use strict";var o=n(19).f,r=n(69),i=n(56),s=n(31),a=n(58),l=n(59),u=n(101),c=n(102),h=n(103),d=n(22),f=n(50).fastKey,p=n(41),g=d?"_s":"size",v=function(e,t){var n,o=f(t);if("F"!==o)return e._i[o];for(n=e._f;n;n=n.n)if(n.k==t)return n};e.exports={getConstructor:function(e,t,n,u){var c=e(function(e,o){a(e,c,t,"_i"),e._t=t,e._i=r(null),e._f=void 0,e._l=void 0,e[g]=0,void 0!=o&&l(o,n,e[u],e)});return i(c.prototype,{clear:function(){for(var e=p(this,t),n=e._i,o=e._f;o;o=o.n)o.r=!0,o.p&&(o.p=o.p.n=void 0),delete n[o.i];e._f=e._l=void 0,e[g]=0},delete:function(e){var n=p(this,t),o=v(n,e);if(o){var r=o.n,i=o.p;delete n._i[o.i],o.r=!0,i&&(i.n=r),r&&(r.p=i),n._f==o&&(n._f=r),n._l==o&&(n._l=i),n[g]--}return!!o},forEach:function(e){p(this,t);for(var n,o=s(e,arguments.length>1?arguments[1]:void 0,3);n=n?n.n:this._f;)for(o(n.v,n.k,this);n&&n.r;)n=n.p},has:function(e){return!!v(p(this,t),e)}}),d&&o(c.prototype,"size",{get:function(){return p(this,t)[g]}}),c},def:function(e,t,n){var o,r,i=v(e,t);return i?i.v=n:(e._l=i={i:r=f(t,!0),k:t,v:n,p:o=e._l,n:void 0,r:!1},e._f||(e._f=i),o&&(o.n=i),e[g]++,"F"!==r&&(e._i[r]=i)),e},getEntry:v,setStrong:function(e,t,n){u(e,t,function(e,n){this._t=p(e,t),this._k=n,this._l=void 0},function(){for(var e=this,t=e._k,n=e._l;n&&n.r;)n=n.p;return e._t&&(e._l=n=n?n.n:e._t._f)?"keys"==t?c(0,n.k):"values"==t?c(0,n.v):c(0,[n.k,n.v]):(e._t=void 0,c(1))},n?"entries":"values",!n,!0),h(t)}}},function(e,t,n){e.exports=!n(22)&&!n(24)(function(){return 7!=Object.defineProperty(n(67)("div"),"a",{get:function(){return 7}}).a})},function(e,t,n){var o=n(25),r=n(26),i=n(95)(!1),s=n(71)("IE_PROTO");e.exports=function(e,t){var n,a=r(e),l=0,u=[];for(n in a)n!=s&&o(a,n)&&u.push(n);for(;t.length>l;)o(a,n=t[l++])&&(~i(u,n)||u.push(n));return u}},function(e,t,n){var o=n(26),r=n(23),i=n(55);e.exports=function(e){return function(t,n,s){var a,l=o(t),u=r(l.length),c=i(s,u);if(e&&n!=n){for(;u>c;)if((a=l[c++])!=a)return!0}else for(;u>c;c++)if((e||c in l)&&l[c]===n)return e||c||0;return!e&&-1}}},function(e,t,n){var o=n(12).document;e.exports=o&&o.documentElement},function(e,t,n){var o=n(18);e.exports=function(e,t,n,r){try{return r?t(o(n)[0],n[1]):t(n)}catch(t){var i=e.return;throw void 0!==i&&o(i.call(e)),t}}},function(e,t,n){var o=n(48),r=n(10)("iterator"),i=Array.prototype;e.exports=function(e){return void 0!==e&&(o.Array===e||i[r]===e)}},function(e,t,n){var o=n(100),r=n(10)("iterator"),i=n(48);e.exports=n(47).getIteratorMethod=function(e){if(void 0!=e)return e[r]||e["@@iterator"]||i[o(e)]}},function(e,t,n){var o=n(39),r=n(10)("toStringTag"),i="Arguments"==o(function(){return arguments}()),s=function(e,t){try{return e[t]}catch(e){}};e.exports=function(e){var t,n,a;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(n=s(t=Object(e),r))?n:i?o(t):"Object"==(a=o(t))&&"function"==typeof t.callee?"Arguments":a}},function(e,t,n){"use strict";var o=n(60),r=n(3),i=n(29),s=n(30),a=n(25),l=n(48),u=n(302),c=n(49),h=n(303),d=n(10)("iterator"),f=!([].keys&&"next"in[].keys()),p=function(){return this};e.exports=function(e,t,n,g,v,m,y){u(n,t,g);var w,C,b,E=function(e){if(!f&&e in T)return T[e];switch(e){case"keys":case"values":return function(){return new n(this,e)}}return function(){return new n(this,e)}},_=t+" Iterator",S="values"==v,O=!1,T=e.prototype,R=T[d]||T["@@iterator"]||v&&T[v],k=R||E(v),M=v?S?E("entries"):k:void 0,N="Array"==t?T.entries||R:R;if(N&&(b=h(N.call(new e)))!==Object.prototype&&b.next&&(c(b,_,!0),o||a(b,d)||s(b,d,p)),S&&R&&"values"!==R.name&&(O=!0,k=function(){return R.call(this)}),o&&!y||!f&&!O&&T[d]||s(T,d,k),l[t]=k,l[_]=p,v)if(w={values:S?k:E("values"),keys:m?k:E("keys"),entries:M},y)for(C in w)C in T||i(T,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,n){"use strict";var o=n(12),r=n(19),i=n(22),s=n(10)("species");e.exports=function(e){var t=o[e];i&&t&&!t[s]&&r.f(t,s,{configurable:!0,get:function(){return this}})}},function(e,t,n){var o=n(15),r=n(18),i=function(e,t){if(r(e),!o(t)&&null!==t)throw TypeError(t+": can't set as prototype!")};e.exports={set:Object.setPrototypeOf||("__proto__"in{}?function(e,t,o){try{o=n(31)(Function.call,n(75).f(Object.prototype,"__proto__").set,2),o(e,[]),t=!(e instanceof Array)}catch(e){t=!0}return function(e,n){return i(e,n),t?e.__proto__=n:o(e,n),e}}({},!1):void 0),check:i}},function(e,t,n){"use strict";var o=n(92),r=n(41);e.exports=n(61)("Set",function(e){return function(){return e(this,arguments.length>0?arguments[0]:void 0)}},{add:function(e){return o.def(r(this,"Set"),e=0===e?0:e,e)}},o)},function(e,t,n){"use strict";var o,r=n(62)(0),i=n(29),s=n(50),a=n(108),l=n(109),u=n(15),c=n(24),h=n(41),d=s.getWeak,f=Object.isExtensible,p=l.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 l.def(h(this,"WeakMap"),e,t)}},y=e.exports=n(61)("WeakMap",v,m,l,!0,!0);c(function(){return 7!=(new y).set((Object.freeze||Object)(g),7).get(g)})&&(o=l.getConstructor(v,"WeakMap"),a(o.prototype,m),s.NEED=!0,r(["delete","has","get","set"],function(e){var t=y.prototype,n=t[e];i(t,e,function(t,r){if(u(t)&&!f(t)){this._f||(this._f=new o);var i=this._f[e](t,r);return"set"==e?this:i}return n.call(this,t,r)})}))},function(e,t,n){var o=n(39);e.exports=Array.isArray||function(e){return"Array"==o(e)}},function(e,t,n){"use strict";var o=n(38),r=n(63),i=n(51),s=n(40),a=n(70),l=Object.assign;e.exports=!l||n(24)(function(){var e={},t={},n=Symbol(),o="abcdefghijklmnopqrst";return e[n]=7,o.split("").forEach(function(e){t[e]=e}),7!=l({},e)[n]||Object.keys(l({},t)).join("")!=o})?function(e,t){for(var n=s(e),l=arguments.length,u=1,c=r.f,h=i.f;l>u;)for(var d,f=a(arguments[u++]),p=c?o(f).concat(c(f)):o(f),g=p.length,v=0;g>v;)h.call(f,d=p[v++])&&(n[d]=f[d]);return n}:l},function(e,t,n){"use strict";var o=n(56),r=n(50).getWeak,i=n(18),s=n(15),a=n(58),l=n(59),u=n(62),c=n(25),h=n(41),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 n=m(this,e);n?n[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,n,i){var u=e(function(e,o){a(e,u,t,"_i"),e._t=t,e._i=p++,e._l=void 0,void 0!=o&&l(o,n,e[i],e)});return o(u.prototype,{delete:function(e){if(!s(e))return!1;var n=r(e);return!0===n?g(h(this,t)).delete(e):n&&c(n,this._i)&&delete n[this._i]},has:function(e){if(!s(e))return!1;var n=r(e);return!0===n?g(h(this,t)).has(e):n&&c(n,this._i)}}),u},def:function(e,t,n){var o=r(i(t),!0);return!0===o?g(e).set(t,n):o[e._i]=n,e},ufstore:g}},function(e,t,n){"use strict";var o=n(109),r=n(41);n(61)("WeakSet",function(e){return function(){return e(this,arguments.length>0?arguments[0]:void 0)}},{add:function(e){return o.def(r(this,"WeakSet"),e,!0)}},o,!1,!0)},function(e,t,n){"use strict";var o,r,i,s,a=n(60),l=n(12),u=n(31),c=n(100),h=n(3),d=n(15),f=n(57),p=n(58),g=n(59),v=n(307),m=n(76).set,y=n(309)(),w=n(112),C=n(310),b=n(311),E=l.TypeError,_=l.process,S=l.Promise,O="process"==c(_),T=function(){},R=r=w.f,k=!!function(){try{var e=S.resolve(1),t=(e.constructor={})[n(10)("species")]=function(e){e(T,T)};return(O||"function"==typeof PromiseRejectionEvent)&&e.then(T)instanceof t}catch(e){}}(),M=function(e){var t;return!(!d(e)||"function"!=typeof(t=e.then))&&t},N=function(e,t){if(!e._n){e._n=!0;var n=e._c;y(function(){for(var o=e._v,r=1==e._s,i=0;n.length>i;)!function(t){var n,i,s=r?t.ok:t.fail,a=t.resolve,l=t.reject,u=t.domain;try{s?(r||(2==e._h&&H(e),e._h=1),!0===s?n=o:(u&&u.enter(),n=s(o),u&&u.exit()),n===t.promise?l(E("Promise-chain cycle")):(i=M(n))?i.call(n,a,l):a(n)):l(o)}catch(e){l(e)}}(n[i++]);e._c=[],e._n=!1,t&&!e._h&&D(e)})}},D=function(e){m.call(l,function(){var t,n,o,r=e._v,i=A(e);if(i&&(t=C(function(){O?_.emit("unhandledRejection",r,e):(n=l.onunhandledrejection)?n({promise:e,reason:r}):(o=l.console)&&o.error&&o.error("Unhandled promise rejection",r)}),e._h=O||A(e)?2:1),e._a=void 0,i&&t.e)throw t.v})},A=function(e){if(1==e._h)return!1;for(var t,n=e._a||e._c,o=0;n.length>o;)if(t=n[o++],t.fail||!A(t.promise))return!1;return!0},H=function(e){m.call(l,function(){var t;O?_.emit("rejectionHandled",e):(t=l.onrejectionhandled)&&t({promise:e,reason:e._v})})},P=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()),N(t,!0))},x=function(e){var t,n=this;if(!n._d){n._d=!0,n=n._w||n;try{if(n===e)throw E("Promise can't be resolved itself");(t=M(e))?y(function(){var o={_w:n,_d:!1};try{t.call(e,u(x,o,1),u(P,o,1))}catch(e){P.call(o,e)}}):(n._v=e,n._s=1,N(n,!1))}catch(e){P.call({_w:n,_d:!1},e)}}};k||(S=function(e){p(this,S,"Promise","_h"),f(e),o.call(this);try{e(u(x,this,1),u(P,this,1))}catch(e){P.call(this,e)}},o=function(e){this._c=[],this._a=void 0,this._s=0,this._d=!1,this._v=void 0,this._h=0,this._n=!1},o.prototype=n(56)(S.prototype,{then:function(e,t){var n=R(v(this,S));return n.ok="function"!=typeof e||e,n.fail="function"==typeof t&&t,n.domain=O?_.domain:void 0,this._c.push(n),this._a&&this._a.push(n),this._s&&N(this,!1),n.promise},catch:function(e){return this.then(void 0,e)}}),i=function(){var e=new o;this.promise=e,this.resolve=u(x,e,1),this.reject=u(P,e,1)},w.f=R=function(e){return e===S||e===s?new i(e):r(e)}),h(h.G+h.W+h.F*!k,{Promise:S}),n(49)(S,"Promise"),n(103)("Promise"),s=n(47).Promise,h(h.S+h.F*!k,"Promise",{reject:function(e){var t=R(this);return(0,t.reject)(e),t.promise}}),h(h.S+h.F*(a||!k),"Promise",{resolve:function(e){return b(a&&this===s?S:this,e)}}),h(h.S+h.F*!(k&&n(74)(function(e){S.all(e).catch(T)})),"Promise",{all:function(e){var t=this,n=R(t),o=n.resolve,r=n.reject,i=C(function(){var n=[],i=0,s=1;g(e,!1,function(e){var a=i++,l=!1;n.push(void 0),s++,t.resolve(e).then(function(e){l||(l=!0,n[a]=e,--s||o(n))},r)}),--s||o(n)});return i.e&&r(i.v),n.promise},race:function(e){var t=this,n=R(t),o=n.reject,r=C(function(){g(e,!1,function(e){t.resolve(e).then(n.resolve,o)})});return r.e&&o(r.v),n.promise}})},function(e,t,n){"use strict";function o(e){var t,n;this.promise=new e(function(e,o){if(void 0!==t||void 0!==n)throw TypeError("Bad Promise constructor");t=e,n=o}),this.resolve=r(t),this.reject=r(n)}var r=n(57);e.exports.f=function(e){return new o(e)}},function(e,t,n){"use strict";var o=n(12),r=n(25),i=n(22),s=n(3),a=n(29),l=n(50).KEY,u=n(24),c=n(72),h=n(49),d=n(45),f=n(10),p=n(114),g=n(312),v=n(313),m=n(107),y=n(18),w=n(26),C=n(68),b=n(46),E=n(69),_=n(314),S=n(75),O=n(19),T=n(38),R=S.f,k=O.f,M=_.f,N=o.Symbol,D=o.JSON,A=D&&D.stringify,H=f("_hidden"),P=f("toPrimitive"),x={}.propertyIsEnumerable,L=c("symbol-registry"),I=c("symbols"),j=c("op-symbols"),W=Object.prototype,F="function"==typeof N,B=o.QObject,V=!B||!B.prototype||!B.prototype.findChild,U=i&&u(function(){return 7!=E(k({},"a",{get:function(){return k(this,"a",{value:7}).a}})).a})?function(e,t,n){var o=R(W,t);o&&delete W[t],k(e,t,n),o&&e!==W&&k(W,t,o)}:k,Y=function(e){var t=I[e]=E(N.prototype);return t._k=e,t},z=F&&"symbol"==typeof N.iterator?function(e){return"symbol"==typeof e}:function(e){return e instanceof N},G=function(e,t,n){return e===W&&G(j,t,n),y(e),t=C(t,!0),y(n),r(I,t)?(n.enumerable?(r(e,H)&&e[H][t]&&(e[H][t]=!1),n=E(n,{enumerable:b(0,!1)})):(r(e,H)||k(e,H,b(1,{})),e[H][t]=!0),U(e,t,n)):k(e,t,n)},X=function(e,t){y(e);for(var n,o=v(t=w(t)),r=0,i=o.length;i>r;)G(e,n=o[r++],t[n]);return e},K=function(e,t){return void 0===t?E(e):X(E(e),t)},q=function(e){var t=x.call(this,e=C(e,!0));return!(this===W&&r(I,e)&&!r(j,e))&&(!(t||!r(this,e)||!r(I,e)||r(this,H)&&this[H][e])||t)},$=function(e,t){if(e=w(e),t=C(t,!0),e!==W||!r(I,t)||r(j,t)){var n=R(e,t);return!n||!r(I,t)||r(e,H)&&e[H][t]||(n.enumerable=!0),n}},J=function(e){for(var t,n=M(w(e)),o=[],i=0;n.length>i;)r(I,t=n[i++])||t==H||t==l||o.push(t);return o},Z=function(e){for(var t,n=e===W,o=M(n?j:w(e)),i=[],s=0;o.length>s;)!r(I,t=o[s++])||n&&!r(W,t)||i.push(I[t]);return i};F||(N=function(){if(this instanceof N)throw TypeError("Symbol is not a constructor!");var e=d(arguments.length>0?arguments[0]:void 0),t=function(n){this===W&&t.call(j,n),r(this,H)&&r(this[H],e)&&(this[H][e]=!1),U(this,e,b(1,n))};return i&&V&&U(W,e,{configurable:!0,set:t}),Y(e)},a(N.prototype,"toString",function(){return this._k}),S.f=$,O.f=G,n(77).f=_.f=J,n(51).f=q,n(63).f=Z,i&&!n(60)&&a(W,"propertyIsEnumerable",q,!0),p.f=function(e){return Y(f(e))}),s(s.G+s.W+s.F*!F,{Symbol:N});for(var Q="hasInstance,isConcatSpreadable,iterator,match,replace,search,species,split,toPrimitive,toStringTag,unscopables".split(","),ee=0;Q.length>ee;)f(Q[ee++]);for(var te=T(f.store),ne=0;te.length>ne;)g(te[ne++]);s(s.S+s.F*!F,"Symbol",{for:function(e){return r(L,e+="")?L[e]:L[e]=N(e)},keyFor:function(e){if(!z(e))throw TypeError(e+" is not a symbol!");for(var t in L)if(L[t]===e)return t},useSetter:function(){V=!0},useSimple:function(){V=!1}}),s(s.S+s.F*!F,"Object",{create:K,defineProperty:G,defineProperties:X,getOwnPropertyDescriptor:$,getOwnPropertyNames:J,getOwnPropertySymbols:Z}),D&&s(s.S+s.F*(!F||u(function(){var e=N();return"[null]"!=A([e])||"{}"!=A({a:e})||"{}"!=A(Object(e))})),"JSON",{stringify:function(e){if(void 0!==e&&!z(e)){for(var t,n,o=[e],r=1;arguments.length>r;)o.push(arguments[r++]);return t=o[1],"function"==typeof t&&(n=t),!n&&m(t)||(t=function(e,t){if(n&&(t=n.call(this,e,t)),!z(t))return t}),o[1]=t,A.apply(D,o)}}}),N.prototype[P]||n(30)(N.prototype,P,N.prototype.valueOf),h(N,"Symbol"),h(Math,"Math",!0),h(o.JSON,"JSON",!0)},function(e,t,n){t.f=n(10)},function(e,t,n){var o=n(3);o(o.S+o.F,"Object",{assign:n(108)})},function(e,t,n){var o=n(3);o(o.S,"Object",{is:n(315)})},function(e,t,n){var o=n(3);o(o.S,"Object",{setPrototypeOf:n(104).set})},function(e,t,n){var o=n(19).f,r=Function.prototype,i=/^\s*function ([^ (]*)/;"name"in r||n(22)&&o(r,"name",{configurable:!0,get:function(){try{return(""+this).match(i)[1]}catch(e){return""}}})},function(e,t,n){var o=n(3),r=n(26),i=n(23);o(o.S,"String",{raw:function(e){for(var t=r(e.raw),n=i(t.length),o=arguments.length,s=[],a=0;n>a;)s.push(t[a++]+""),o>a&&s.push(arguments[a]+"");return s.join("")}})},function(e,t,n){var o=n(3),r=n(55),i=String.fromCharCode,s=String.fromCodePoint;o(o.S+o.F*(!!s&&1!=s.length),"String",{fromCodePoint:function(e){for(var t,n=[],o=arguments.length,s=0;o>s;){if(t=+arguments[s++],r(t,1114111)!==t)throw RangeError(t+" is not a valid code point");n.push(65536>t?i(t):i(55296+((t-=65536)>>10),t%1024+56320))}return n.join("")}})},function(e,t,n){"use strict";var o=n(3),r=n(316)(!1);o(o.P,"String",{codePointAt:function(e){return r(this,e)}})},function(e,t,n){var o=n(3);o(o.P,"String",{repeat:n(123)})},function(e,t,n){"use strict";var o=n(54),r=n(34);e.exports=function(e){var t=r(this)+"",n="",i=o(e);if(0>i||i==1/0)throw RangeError("Count can't be negative");for(;i>0;(i>>>=1)&&(t+=t))1&i&&(n+=t);return n}},function(e,t,n){"use strict";var o=n(3),r=n(23),i=n(78),s="".startsWith;o(o.P+o.F*n(79)("startsWith"),"String",{startsWith:function(e){var t=i(this,e,"startsWith"),n=r(Math.min(arguments.length>1?arguments[1]:void 0,t.length)),o=e+"";return s?s.call(t,o,n):t.slice(n,n+o.length)===o}})},function(e,t,n){var o=n(15),r=n(39),i=n(10)("match");e.exports=function(e){var t;return o(e)&&(void 0!==(t=e[i])?!!t:"RegExp"==r(e))}},function(e,t,n){"use strict";var o=n(3),r=n(23),i=n(78),s="".endsWith;o(o.P+o.F*n(79)("endsWith"),"String",{endsWith:function(e){var t=i(this,e,"endsWith"),n=arguments.length>1?arguments[1]:void 0,o=r(t.length),a=void 0===n?o:Math.min(r(n),o),l=e+"";return s?s.call(t,l,a):t.slice(a-l.length,a)===l}})},function(e,t,n){"use strict";var o=n(3),r=n(78);o(o.P+o.F*n(79)("includes"),"String",{includes:function(e){return!!~r(this,e,"includes").indexOf(e,arguments.length>1?arguments[1]:void 0)}})},function(e,t,n){n(22)&&"g"!=/./g.flags&&n(19).f(RegExp.prototype,"flags",{configurable:!0,get:n(317)})},function(e,t,n){n(64)("match",1,function(e,t,n){return[function(n){"use strict";var o=e(this),r=void 0==n?void 0:n[t];return void 0!==r?r.call(n,o):RegExp(n)[t](o+"")},n]})},function(e,t,n){n(64)("replace",2,function(e,t,n){return[function(o,r){"use strict";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,n){n(64)("split",2,function(e,t,o){"use strict";var r=n(125),i=o,s=[].push,a="length";if("c"=="abbc".split(/(b)*/)[1]||4!="test".split(/(?:)/,-1)[a]||2!="ab".split(/(?:ab)*/)[a]||4!=".".split(/(.?)(.?)/)[a]||".".split(/()()/)[a]>1||"".split(/.?/)[a]){var l=void 0===/()??/.exec("")[1];o=function(e,t){var n=this+"";if(void 0===e&&0===t)return[];if(!r(e))return i.call(n,e,t);var o,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(l||(o=RegExp("^"+m.source+"$(?!\\s)",p));(u=m.exec(n))&&((c=u.index+u[0][a])<=g||(f.push(n.slice(g,u.index)),!l&&u[a]>1&&u[0].replace(o,function(){for(d=1;arguments[a]-2>d;d++)void 0===arguments[d]&&(u[d]=void 0)}),u[a]>1&&n[a]>u.index&&s.apply(f,u.slice(1)),h=u[0][a],g=c,v>f[a]));)m.lastIndex===u.index&&m.lastIndex++;return g===n[a]?!h&&m.test("")||f.push(""):f.push(n.slice(g)),f[a]>v?f.slice(0,v):f}}else"0".split(void 0,0)[a]&&(o=function(e,t){return void 0===e&&0===t?[]:i.call(this,e,t)});return[function(n,r){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,n){n(64)("search",1,function(e,t,n){return[function(n){"use strict";var o=e(this),r=void 0==n?void 0:n[t];return void 0!==r?r.call(n,o):RegExp(n)[t](o+"")},n]})},function(e,t,n){"use strict";var o=n(31),r=n(3),i=n(40),s=n(97),a=n(98),l=n(23),u=n(80),c=n(99);r(r.S+r.F*!n(74)(function(e){Array.from(e)}),"Array",{from:function(e){var t,n,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=o(g,p>2?arguments[2]:void 0,2)),void 0==y||f==Array&&a(y))for(t=l(d.length),n=new f(t);t>m;m++)u(n,m,v?g(d[m],m):d[m]);else for(h=y.call(d),n=new f;!(r=h.next()).done;m++)u(n,m,v?s(h,g,[r.value,m],!0):r.value);return n.length=m,n}})},function(e,t,n){"use strict";var o=n(3),r=n(80);o(o.S+o.F*n(24)(function(){function e(){}return!(Array.of.call(e)instanceof e)}),"Array",{of:function(){for(var e=0,t=arguments.length,n=new("function"==typeof this?this:Array)(t);t>e;)r(n,e,arguments[e++]);return n.length=t,n}})},function(e,t,n){var o=n(3);o(o.P,"Array",{copyWithin:n(318)}),n(42)("copyWithin")},function(e,t,n){"use strict";var o=n(3),r=n(62)(5),i=!0;"find"in[]&&Array(1).find(function(){i=!1}),o(o.P+o.F*i,"Array",{find:function(e){return r(this,e,arguments.length>1?arguments[1]:void 0)}}),n(42)("find")},function(e,t,n){"use strict";var o=n(3),r=n(62)(6),i="findIndex",s=!0;i in[]&&Array(1)[i](function(){s=!1}),o(o.P+o.F*s,"Array",{findIndex:function(e){return r(this,e,arguments.length>1?arguments[1]:void 0)}}),n(42)(i)},function(e,t,n){var o=n(3);o(o.P,"Array",{fill:n(319)}),n(42)("fill")},function(e,t,n){var o=n(3),r=n(12).isFinite;o(o.S,"Number",{isFinite:function(e){return"number"==typeof e&&r(e)}})},function(e,t,n){var o=n(3);o(o.S,"Number",{isInteger:n(141)})},function(e,t,n){var o=n(15),r=Math.floor;e.exports=function(e){return!o(e)&&isFinite(e)&&r(e)===e}},function(e,t,n){var o=n(3),r=n(141),i=Math.abs;o(o.S,"Number",{isSafeInteger:function(e){return r(e)&&9007199254740991>=i(e)}})},function(e,t,n){var o=n(3);o(o.S,"Number",{isNaN:function(e){return e!=e}})},function(e,t,n){var o=n(3);o(o.S,"Number",{EPSILON:Math.pow(2,-52)})},function(e,t,n){var o=n(3);o(o.S,"Number",{MIN_SAFE_INTEGER:-9007199254740991})},function(e,t,n){var o=n(3);o(o.S,"Number",{MAX_SAFE_INTEGER:9007199254740991})},function(e,t,n){"use strict";var o=n(3),r=n(95)(!0);o(o.P,"Array",{includes:function(e){return r(this,e,arguments.length>1?arguments[1]:void 0)}}),n(42)("includes")},function(e,t,n){var o=n(3),r=n(149)(!1);o(o.S,"Object",{values:function(e){return r(e)}})},function(e,t,n){var o=n(38),r=n(26),i=n(51).f;e.exports=function(e){return function(t){for(var n,s=r(t),a=o(s),l=a.length,u=0,c=[];l>u;)i.call(s,n=a[u++])&&c.push(e?[n,s[n]]:s[n]);return c}}},function(e,t,n){var o=n(3),r=n(149)(!0);o(o.S,"Object",{entries:function(e){return r(e)}})},function(e,t,n){var o=n(3),r=n(320),i=n(26),s=n(75),a=n(80);o(o.S,"Object",{getOwnPropertyDescriptors:function(e){for(var t,n,o=i(e),l=s.f,u=r(o),c={},h=0;u.length>h;)void 0!==(n=l(o,t=u[h++]))&&a(c,t,n);return c}})},function(e,t,n){"use strict";var o=n(3),r=n(153);o(o.P,"String",{padStart:function(e){return r(this,e,arguments.length>1?arguments[1]:void 0,!0)}})},function(e,t,n){var o=n(23),r=n(123),i=n(34);e.exports=function(e,t,n,s){var a=i(e)+"",l=a.length,u=void 0===n?" ":n+"",c=o(t);if(l>=c||""==u)return a;var h=c-l,d=r.call(u,Math.ceil(h/u.length));return d.length>h&&(d=d.slice(0,h)),s?d+a:a+d}},function(e,t,n){"use strict";var o=n(3),r=n(153);o(o.P,"String",{padEnd:function(e){return r(this,e,arguments.length>1?arguments[1]:void 0,!1)}})},function(e,t,n){var o=n(3),r=n(76);o(o.G+o.B,{setImmediate:r.set,clearImmediate:r.clear})},function(e,t,n){for(var o=n(81),r=n(38),i=n(29),s=n(12),a=n(30),l=n(48),u=n(10),c=u("iterator"),h=u("toStringTag"),d=l.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]||a(C,c,d),C[h]||a(C,h,m),l[m]=d,y))for(v in o)C[v]||i(C,v,o[v],!0)}},function(e,t,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=new WeakMap;t.default=function(){function e(t,n,r,s,a,l,u){var c=arguments.length>7&&void 0!==arguments[7]?arguments[7]:function(e){return e};o(this,e),i.set(this,{viewportWidth:t,scrollOffset:n,totalColumns:r,columnWidthFn:s,overrideFn:a,onlyFullyVisible:l,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,n=[],o=void 0,r=i.get(this),s=r.onlyFullyVisible,a=r.overrideFn,l=r.scrollOffset,u=r.totalColumns,c=r.viewportWidth,h=0;u>h;h++){o=this._getColumnWidth(h),e>l||s||(this.startColumn=h);var d=l>0?c+1:c;if(l>e||e+o>l+d||(null==this.startColumn&&(this.startColumn=h),this.endColumn=h),n.push(e),e+=o,s||(this.endColumn=h),e>=l+c){t=!1;break}}if(this.endColumn===u-1&&t)for(this.startColumn=this.endColumn;this.startColumn>0;){var f=n[this.endColumn]+o-n[this.startColumn-1];if(f>c&&s||this.startColumn--,f>c)break}null!==this.startColumn&&a&&a(this),this.startPosition=n[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),n=t.totalColumns,o=0,r=0;n>r;r++){var s=this._getColumnWidth(r),a=t.stretchingColumnWidthFn(void 0,r);"number"==typeof a?e-=a:o+=s}var l=e-o;if("all"===this.stretch&&l>0)this.stretchAllRatio=e/o,this.stretchAllColumnsWidth=[],this.needVerifyLastColumnWidth=!0;else if("last"===this.stretch&&e!==1/0){var u=this._getColumnWidth(n-1),c=l+u;this.stretchLastWidth=0>c?u:c}}}},{key:"getStretchedColumnWidth",value:function(e,t){var n=null;return"all"===this.stretch&&0!==this.stretchAllRatio?n=this._getStretchedAllColumnWidth(e,t):"last"===this.stretch&&0!==this.stretchLastWidth&&(n=this._getStretchedLastColumnWidth(e)),n}},{key:"_getStretchedAllColumnWidth",value:function(e,t){var n=0,o=i.get(this),r=o.totalColumns;if(!this.stretchAllColumnsWidth[e]){var s=Math.round(t*this.stretchAllRatio),a=o.stretchingColumnWidthFn(s,e);this.stretchAllColumnsWidth[e]=void 0===a?s:isNaN(a)?this._getColumnWidth(e):a}if(this.stretchAllColumnsWidth.length===r&&this.needVerifyLastColumnWidth){this.needVerifyLastColumnWidth=!1;for(var l=0;this.stretchAllColumnsWidth.length>l;l++)n+=this.stretchAllColumnsWidth[l];n!==this.totalTargetWidth&&(this.stretchAllColumnsWidth[this.stretchAllColumnsWidth.length-1]+=this.totalTargetWidth-n)}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 n=i.get(this).columnWidthFn(t);return void 0===n&&(n=e.DEFAULT_WIDTH),n}}]),e}()},function(e,t,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=new WeakMap;t.default=function(){function e(t,n,r,s,a,l,u){o(this,e),i.set(this,{viewportHeight:t,scrollOffset:n,totalRows:r,rowHeightFn:s,overrideFn:a,onlyFullyVisible:l,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,n=!0,o=[],r=i.get(this),s=r.onlyFullyVisible,a=r.overrideFn,l=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=l(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),o.push(t),t+=f,s||(this.endRow=p),t>=u+h-d){n=!1;break}if(this.endRow===c-1&&n)for(this.startRow=this.endRow;this.startRow>0;){var g=o[this.endRow]+f-o[this.startRow-1];if(g>h-d&&s||this.startRow--,g>=h-d)break}null!==this.startRow&&a&&a(this),this.startPosition=o[this.startRow],void 0==this.startPosition&&(this.startPosition=null),null!==this.startRow&&(this.count=this.endRow-this.startRow+1)}}]),e}()},function(e,t,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}();t.default=function(){function e(t,n,r){o(this,e),this.offset=t,this.total=n,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,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}();t.default=function(){function e(t,n,r){o(this,e),this.offset=t,this.total=n,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,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),s=n(0),a=n(1),l=n(33),u=n(278),c=o(u),h=n(279),d=o(h),f=n(280),p=o(f),g=n(281),v=o(g),m=n(282),y=o(m),w=n(284),C=o(w);t.default=function(){function e(t){r(this,e);var n=[];if(this.guid="wt_"+(0,l.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 o=0,i=this.wtTable.THEAD.childNodes[0].childNodes.length;i>o;o++)n.push(this.wtTable.THEAD.childNodes[0].childNodes[o].innerHTML);this.getSetting("columnHeaders").length||this.update("columnHeaders",[function(e,t){(0,s.fastInnerText)(t,n[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"),n=this.wtSettings.getSetting("fixedRowsTop"),o=this.wtSettings.getSetting("fixedRowsBottom"),r=this.wtSettings.getSetting("fixedColumnsLeft");if(n>e.row&&r>e.col)return this.wtOverlays.topLeftCornerOverlay.clone.wtTable.getCell(e);if(n>e.row)return this.wtOverlays.topOverlay.clone.wtTable.getCell(e);if(r>e.col&&e.row>=t-o){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-o&&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"]},n=[],o=[];(0,a.objectEach)(t,function(t,r){t.indexOf("array")>-1&&e.getSetting(r).length&&o.push("ht"+(0,l.toUpperCaseFirst)(r)),n.push("ht"+(0,l.toUpperCaseFirst)(r))}),(0,s.removeClass)(this.wtTable.wtRootElement.parentNode,n),(0,s.addClass)(this.wtTable.wtRootElement.parentNode,o)}},{key:"getSetting",value:function(e,t,n,o,r){return this.wtSettings.getSetting(e,t,n,o,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){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t,n){"use strict";function o(e){for(var t=arguments.length,n=Array(t>1?t-1:0),o=1;t>o;o++)n[o-1]=arguments[o];return(0,r.arrayReduce)(e,function(e,t,o){return e+t.replace(/(?:\r?\n\s+)/g,"")+(n[o]?n[o]:"")},"").trim()}t.__esModule=!0,t.toSingleLine=o;var r=n(2)},function(e,t,n){"use strict";function o(e){var t=this,n=new l.default(e);this.instance=e;var o=[null,null];this.dblClickTimeout=[null,null];var a=function(e){var n=document.activeElement,s=(0,i.partial)(r.getParent,e.realTarget),a=e.realTarget;if(a!==n&&s(0)!==n&&s(1)!==n){var l=t.parentCell(a);(0,r.hasClass)(a,"corner")?t.instance.getSetting("onCellCornerMouseDown",e,a):l.TD&&t.instance.hasSetting("onCellMouseDown")&&t.instance.getSetting("onCellMouseDown",e,l.coords,l.TD,t.instance),2!==e.button&&l.TD&&(o[0]=l.TD,clearTimeout(t.dblClickTimeout[0]),t.dblClickTimeout[0]=setTimeout(function(){o[0]=null},1e3))}},u=function(e){t.instance.touchMoving=!0},c=function(e){n.addEventListener(this,"touchmove",u),t.checkIfTouchMove=setTimeout(function(){!0===t.instance.touchMoving&&(t.instance.touchMoving=void 0,n.removeEventListener("touchmove",u,!1)),a(e)},30)},h=function(e){var n,o,i;t.instance.hasSetting("onCellMouseOver")&&(n=t.instance.wtTable.TABLE,o=(0,r.closestDown)(e.realTarget,["TD","TH"],n),i=t.instance.cloneSource||t.instance,o&&o!==i.lastMouseOver&&(0,r.isChildOf)(o,n)&&(i.lastMouseOver=o,t.instance.getSetting("onCellMouseOver",e,t.instance.wtTable.getCoords(o),o,t.instance)))},d=function(e){var n=void 0,o=void 0,i=void 0;t.instance.hasSetting("onCellMouseOut")&&(n=t.instance.wtTable.TABLE,o=(0,r.closestDown)(e.realTarget,["TD","TH"],n),i=(0,r.closestDown)(e.relatedTarget,["TD","TH"],n),o&&o!==i&&(0,r.isChildOf)(o,n)&&t.instance.getSetting("onCellMouseOut",e,t.instance.wtTable.getCoords(o),o,t.instance))},f=function(e){if(2!==e.button){var n=t.parentCell(e.realTarget);n.TD===o[0]&&n.TD===o[1]?((0,r.hasClass)(e.realTarget,"corner")?t.instance.getSetting("onCellCornerDblClick",e,n.coords,n.TD,t.instance):t.instance.getSetting("onCellDblClick",e,n.coords,n.TD,t.instance),o[0]=null,o[1]=null):n.TD===o[0]?(t.instance.getSetting("onCellMouseUp",e,n.coords,n.TD,t.instance),o[1]=n.TD,clearTimeout(t.dblClickTimeout[1]),t.dblClickTimeout[1]=setTimeout(function(){o[1]=null},500)):n.TD&&t.instance.hasSetting("onCellMouseUp")&&t.instance.getSetting("onCellMouseUp",e,n.coords,n.TD,t.instance)}},p=function(e){clearTimeout(void 0),e.preventDefault(),f(e)};if(n.addEventListener(this.instance.wtTable.holder,"mousedown",a),n.addEventListener(this.instance.wtTable.TABLE,"mouseover",h),n.addEventListener(this.instance.wtTable.TABLE,"mouseout",d),n.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(".");n.addEventListener(this.instance.wtTable.holder,"touchstart",function(e){t.instance.touchApplied=!0,(0,r.isChildOf)(e.target,g)&&c.call(e.target,e)}),n.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={}),n.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)})}n.addEventListener(window,"resize",function(){"none"!==t.instance.getSetting("stretchH")&&t.instance.draw()}),this.destroy=function(){clearTimeout(this.dblClickTimeout[0]),clearTimeout(this.dblClickTimeout[1]),n.destroy()}}t.__esModule=!0;var r=n(0),i=n(37),s=n(27),a=n(4),l=function(e){return e&&e.__esModule?e:{default:e}}(a);o.prototype.parentCell=function(e){var t={},n=this.instance.wtTable.TABLE,o=(0,r.closestDown)(e,["TD","TH"],n);return o?(t.coords=this.instance.wtTable.getCoords(o),t.TD=o):(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=o},function(e,t,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),s=n(0),a=n(2),l=n(20),u=n(27),c=n(4),h=o(c),d=n(32),f=o(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,n=this.leftOverlay.mainTableScrollableElement,o=[];for(o.push([document.documentElement,"keydown",function(t){return e.onKeyDown(t)}]),o.push([document.documentElement,"keyup",function(){return e.onKeyUp()}]),o.push([document,"visibilitychange",function(){return e.onKeyUp()}]),o.push([t,"scroll",function(t){return e.onTableScroll(t)}]),t!==n&&o.push([n,"scroll",function(t){return e.onTableScroll(t)}]),this.topOverlay.needFullRender&&(o.push([this.topOverlay.clone.wtTable.holder,"scroll",function(t){return e.onTableScroll(t)}]),o.push([this.topOverlay.clone.wtTable.holder,"wheel",function(t){return e.onTableScroll(t)}])),this.bottomOverlay.needFullRender&&(o.push([this.bottomOverlay.clone.wtTable.holder,"scroll",function(t){return e.onTableScroll(t)}]),o.push([this.bottomOverlay.clone.wtTable.holder,"wheel",function(t){return e.onTableScroll(t)}])),this.leftOverlay.needFullRender&&(o.push([this.leftOverlay.clone.wtTable.holder,"scroll",function(t){return e.onTableScroll(t)}]),o.push([this.leftOverlay.clone.wtTable.holder,"wheel",function(t){return e.onTableScroll(t)}])),this.topLeftCornerOverlay&&this.topLeftCornerOverlay.needFullRender&&o.push([this.topLeftCornerOverlay.clone.wtTable.holder,"wheel",function(t){return e.onTableScroll(t)}]),this.bottomLeftCornerOverlay&&this.bottomLeftCornerOverlay.needFullRender&&o.push([this.bottomLeftCornerOverlay.clone.wtTable.holder,"wheel",function(t){return e.onTableScroll(t)}]),this.topOverlay.trimmingContainer!==window&&this.leftOverlay.trimmingContainer!==window&&o.push([window,"wheel",function(t){var n=void 0,o=t.wheelDeltaY||t.deltaY,r=t.wheelDeltaX||t.deltaX;e.topOverlay.clone.wtTable.holder.contains(t.realTarget)?n="top":e.bottomOverlay.clone&&e.bottomOverlay.clone.wtTable.holder.contains(t.realTarget)?n="bottom":e.leftOverlay.clone.wtTable.holder.contains(t.realTarget)?n="left":e.topLeftCornerOverlay&&e.topLeftCornerOverlay.clone&&e.topLeftCornerOverlay.clone.wtTable.holder.contains(t.realTarget)?n="topLeft":e.bottomLeftCornerOverlay&&e.bottomLeftCornerOverlay.clone&&e.bottomLeftCornerOverlay.clone.wtTable.holder.contains(t.realTarget)&&(n="bottomLeft"),("top"==n&&0!==o||"left"==n&&0!==r||"bottom"==n&&0!==o||("topLeft"===n||"bottomLeft"===n)&&(0!==o||0!==r))&&t.preventDefault()}]);o.length;){var r=o.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,n=this.topOverlay.mainTableScrollableElement,o=e.target;this.keyPressed&&(n!==window&&o!==window&&!e.target.contains(n)||t!==window&&o!==window&&!e.target.contains(t))||("scroll"===e.type?this.syncScrollPositions(e):this.translateMouseWheelToScroll(e))}}},{key:"onKeyDown",value:function(e){this.keyPressed=(0,l.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,n=this.bottomOverlay.clone?this.bottomOverlay.clone.wtTable.holder:null,o=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,a=e.wheelDeltaX||-1*e.deltaX,l=null,u={type:"wheel"},c=e.target,h=null;for(1===e.deltaMode&&(s*=120,a*=120);c!=document&&null!=c;){if(c.className.indexOf("wtHolder")>-1){l=c;break}c=c.parentNode}return u.target=l,l===r||l===i?(this.syncScrollPositions(u,-.2*a,"x"),this.syncScrollPositions(u,-.2*s,"y")):(l===t||l===n?h=s:l===o&&(h=a),this.syncScrollPositions(u,-.2*h)),!1}},{key:"syncScrollPositions",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;if(!this.destroyed){if(0===arguments.length)return void this.syncScrollWithMaster();var o=this.leftOverlay.mainTableScrollableElement,r=this.topOverlay.mainTableScrollableElement,i=e.target,a=0,l=!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===o||i===r?(a=(0,s.getScrollLeft)(g?this.scrollableElement:i),this.horizontalScrolling=this.overlayScrollPositions.master.left!==a,this.overlayScrollPositions.master.left=a,l=!0,this.pendingScrollCallbacks.master.left>0?this.pendingScrollCallbacks.master.left--:(u&&u.scrollLeft!==a&&(null==t&&this.pendingScrollCallbacks.top.left++,u.scrollLeft=a,p=o!==window),f&&f.scrollLeft!==a&&(null==t&&this.pendingScrollCallbacks.bottom.left++,f.scrollLeft=a,p=o!==window)),a=(0,s.getScrollTop)(i),this.verticalScrolling=this.overlayScrollPositions.master.top!==a,this.overlayScrollPositions.master.top=a,l=!0,this.pendingScrollCallbacks.master.top>0?this.pendingScrollCallbacks.master.top--:c&&c.scrollTop!==a&&(null==t&&this.pendingScrollCallbacks.left.top++,c.scrollTop=a,p=r!==window)):i===f?(a=(0,s.getScrollLeft)(i),this.overlayScrollPositions.bottom.left=a,l=!0,this.pendingScrollCallbacks.bottom.left>0?this.pendingScrollCallbacks.bottom.left--:(null==t&&this.pendingScrollCallbacks.master.left++,o.scrollLeft=a,u&&u.scrollLeft!==a&&(null==t&&this.pendingScrollCallbacks.top.left++,u.scrollLeft=a,p=r!==window)),null!==t&&(l=!0,r.scrollTop+=t)):i===u?(a=(0,s.getScrollLeft)(i),this.overlayScrollPositions.top.left=a,l=!0,this.pendingScrollCallbacks.top.left>0?this.pendingScrollCallbacks.top.left--:(null==t&&this.pendingScrollCallbacks.master.left++,o.scrollLeft=a),null!==t&&(l=!0,r.scrollTop+=t),f&&f.scrollLeft!==a&&(null==t&&this.pendingScrollCallbacks.bottom.left++,f.scrollLeft=a,p=r!==window)):i===c?(a=(0,s.getScrollTop)(i),this.overlayScrollPositions.left.top!==a&&(this.overlayScrollPositions.left.top=a,l=!0,this.pendingScrollCallbacks.left.top>0?this.pendingScrollCallbacks.left.top--:(null==t&&this.pendingScrollCallbacks.master.top++,r.scrollTop=a)),null!==t&&(l=!0,r.scrollLeft+=t)):i!==h&&i!==d||null!==t&&(l=!0,"x"===n?r.scrollLeft+=t:"y"===n&&(r.scrollTop+=t)),!this.keyPressed&&l&&"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,n=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=n)}},{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,n=t.clientWidth,o=t.clientHeight;n===this.spreaderLastSize.width&&o===this.spreaderLastSize.height||(this.spreaderLastSize.width=n,this.spreaderLastSize.height=o,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"),n=this.wot.getSetting("totalRows"),o=this.wot.wtViewport.getRowHeaderWidth(),r=this.wot.wtViewport.getColumnHeaderHeight(),i=this.wot.wtTable.hider.style;i.width=o+this.leftOverlay.sumCellSizes(0,t)+"px",i.height=r+this.topOverlay.sumCellSizes(0,n)+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],n=null;return(0,a.arrayEach)(t,function(t,o){t&&t.clone&&t.clone.wtTable.TABLE.contains(e)&&(n=t.clone)}),n}}]),e}()},function(e,t,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=n(0),s=n(5);t.default=function(){function e(t){o(this,e),this.wot=t,this.instance=t}return r(e,[{key:"scrollViewport",value:function(e){if(this.wot.drawn){var t=this._getVariables(),n=t.topOverlay,o=t.leftOverlay,r=t.totalRows,i=t.totalColumns,s=t.fixedRowsTop,a=t.fixedRowsBottom,l=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()?n.scrollTo(e.row):e.row>this.getLastVisibleRow()&&r-a>e.row&&n.scrollTo(e.row,!0),e.col>=l&&e.col<this.getFirstVisibleColumn()?o.scrollTo(e.col):e.col>this.getLastVisibleColumn()&&o.scrollTo(e.col,!0)}}},{key:"getFirstVisibleRow",value:function(){var e=this._getVariables(),t=e.topOverlay,n=e.wtTable,o=e.wtViewport,r=e.totalRows,a=e.fixedRowsTop,l=n.getFirstVisibleRow();if(t.mainTableScrollableElement===window){var u=(0,i.offset)(n.wtRootElement),c=(0,i.innerHeight)(n.hider),h=(0,i.innerHeight)(window),d=(0,i.getScrollTop)(window);if(d>=u.top+c-h){var f=o.getColumnHeaderHeight();f+=t.sumCellSizes(0,a),(0,s.rangeEachReverse)(r,1,function(e){if(f+=t.sumCellSizes(e-1,e),d>=u.top+c-f)return l=e,!1})}}return l}},{key:"getLastVisibleRow",value:function(){var e=this._getVariables(),t=e.topOverlay,n=e.wtTable,o=e.wtViewport,r=e.totalRows,a=n.getLastVisibleRow();if(t.mainTableScrollableElement===window){var l=(0,i.offset)(n.wtRootElement),u=(0,i.innerHeight)(window),c=(0,i.getScrollTop)(window);if(l.top>c){var h=o.getColumnHeaderHeight();(0,s.rangeEach)(1,r,function(e){if(h+=t.sumCellSizes(e-1,e),l.top+h-c>=u)return a=e-2,!1})}}return a}},{key:"getFirstVisibleColumn",value:function(){var e=this._getVariables(),t=e.leftOverlay,n=e.wtTable,o=e.wtViewport,r=e.totalColumns,a=n.getFirstVisibleColumn();if(t.mainTableScrollableElement===window){var l=(0,i.offset)(n.wtRootElement),u=(0,i.innerWidth)(n.hider),c=(0,i.innerWidth)(window),h=(0,i.getScrollLeft)(window);if(h>=l.left+u-c){var d=o.getRowHeaderWidth();(0,s.rangeEachReverse)(r,1,function(e){if(d+=t.sumCellSizes(e-1,e),h>=l.left+u-d)return a=e,!1})}}return a}},{key:"getLastVisibleColumn",value:function(){var e=this._getVariables(),t=e.leftOverlay,n=e.wtTable,o=e.wtViewport,r=e.totalColumns,a=n.getLastVisibleColumn();if(t.mainTableScrollableElement===window){var l=(0,i.offset)(n.wtRootElement),u=(0,i.innerWidth)(window),c=(0,i.getScrollLeft)(window);if(l.left>c){var h=o.getRowHeaderWidth();(0,s.rangeEach)(1,r,function(e){if(h+=t.sumCellSizes(e-1,e),l.left+h-c>=u)return a=e-2,!1})}}return a}},{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,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=n(0),s=n(1);t.default=function(){function e(t,n){var r=this;o(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,n){var o=r.getSetting("data",e,t);(0,i.fastInnerText)(n,void 0===o||null===o?"":o)},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 a in this.defaults)if((0,s.hasOwnProperty)(this.defaults,a))if(void 0!==n[a])this.settings[a]=n[a];else{if(void 0===this.defaults[a])throw Error('A required setting "'+a+'" was not provided');this.settings[a]=this.defaults[a]}}return r(e,[{key:"update",value:function(e,t){if(void 0===t)for(var n in e)(0,s.hasOwnProperty)(e,n)&&(this.settings[n]=e[n]);else this.settings[e]=t;return this.wot}},{key:"getSetting",value:function(e,t,n,o,r){return"function"==typeof this.settings[e]?this.settings[e](t,n,o,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,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}function r(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);e.length>t;t++)n[t]=e[t];return n}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},a=function(){function e(e,t){for(var n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),l=n(0),u=n(37),c=n(52),h=o(c),d=n(82),f=(o(d),n(159)),p=o(f),g=n(160),v=o(g),m=n(283),y=o(m),w=n(32),C=o(w);t.default=function(){function e(t,n){var o=this;i(this,e),this.wot=t,this.instance=this.wot,this.TABLE=n,this.TBODY=null,this.THEAD=null,this.COLGROUP=null,this.tableOffset=0,this.holderOffset=0,(0,l.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 o._modifyRowHeaderWidth(r)}}return a(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,n=void 0;return t&&1===t.nodeType&&(0,l.hasClass)(t,"wtHolder")||(n=document.createElement("div"),n.className="wtSpreader",t&&t.insertBefore(n,e),n.appendChild(e)),n.style.position="relative",n}},{key:"createHider",value:function(e){var t=e.parentNode,n=void 0;return t&&1===t.nodeType&&(0,l.hasClass)(t,"wtHolder")||(n=document.createElement("div"),n.className="wtHider",t&&t.insertBefore(n,e),n.appendChild(e)),n}},{key:"createHolder",value:function(e){var t=e.parentNode,n=void 0;return t&&1===t.nodeType&&(0,l.hasClass)(t,"wtHolder")||(n=document.createElement("div"),n.style.position="relative",n.className="wtHolder",t&&t.insertBefore(n,e),this.isWorkingOnClone()||(n.parentNode.className+="ht_master handsontable"),n.appendChild(e)),n}},{key:"alignOverlaysWithTrimmingContainer",value:function(){var e=(0,l.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,l.getStyle)(e,"width"),this.holder.style.height=(0,l.getStyle)(e,"height"),this.holder.style.overflow=""}},{key:"isWorkingOnClone",value:function(){return!!this.wot.cloneSource}},{key:"draw",value:function(e){var t=this.wot,n=t.wtOverlays,o=t.wtViewport,r=this.instance.getSetting("totalRows"),i=this.wot.getSetting("rowHeaders").length,s=this.wot.getSetting("columnHeaders").length,a=!1;if(!this.isWorkingOnClone()&&(this.holderOffset=(0,l.offset)(this.holder),e=o.createRenderCalculators(e),i&&!this.wot.getSetting("fixedColumnsLeft"))){var u=n.leftOverlay.getScrollPosition(),c=this.correctHeaderWidth;this.correctHeaderWidth=u>0,c!==this.correctHeaderWidth&&(e=!1)}if(this.isWorkingOnClone()||(a=n.prepareOverlays()),e)this.isWorkingOnClone()||o.createVisibleCalculators(),n&&n.refresh(!0);else{this.tableOffset=this.isWorkingOnClone()?this.wot.cloneSource.wtTable.tableOffset:(0,l.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):o.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:o.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()||(n.topOverlay.resetFixedPosition(),n.bottomOverlay.clone&&n.bottomOverlay.resetFixedPosition(),n.leftOverlay.resetFixedPosition(),n.topLeftCornerOverlay&&n.topLeftCornerOverlay.resetFixedPosition(),n.bottomLeftCornerOverlay&&n.bottomLeftCornerOverlay.clone&&n.bottomLeftCornerOverlay.resetFixedPosition()),a&&n.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),n=0,o=t.length;o>n;n++)(0,l.removeClass)(t[n],e)}},{key:"refreshSelections",value:function(e){if(this.wot.selections){var t=this.wot.selections.length;if(e)for(var n=0;t>n;n++)this.wot.selections[n].settings.className&&this.removeClassFromCells(this.wot.selections[n].settings.className),this.wot.selections[n].settings.highlightHeaderClassName&&this.removeClassFromCells(this.wot.selections[n].settings.highlightHeaderClassName),this.wot.selections[n].settings.highlightRowClassName&&this.removeClassFromCells(this.wot.selections[n].settings.highlightRowClassName),this.wot.selections[n].settings.highlightColumnClassName&&this.removeClassFromCells(this.wot.selections[n].settings.highlightColumnClassName);for(var o=0;t>o;o++)this.wot.selections[o].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,n=this.THEAD.childNodes[t];if(n)return n.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,l.closest)(e,["TD","TH"])),null===e)return null;var t=e.parentNode,n=t.parentNode,o=(0,l.index)(t),r=e.cellIndex;return(0,l.overlayContainsElement)(C.default.CLONE_TOP_LEFT_CORNER,e)||(0,l.overlayContainsElement)(C.default.CLONE_TOP,e)?"THEAD"===n.nodeName&&(o-=n.childNodes.length):o=n===this.THEAD?this.rowFilter.visibleColHeadedRowToSourceRow(o):this.rowFilter.renderedToSource(o),r=(0,l.overlayContainsElement)(C.default.CLONE_TOP_LEFT_CORNER,e)||(0,l.overlayContainsElement)(C.default.CLONE_LEFT,e)?this.columnFilter.offsettedTH(r):this.columnFilter.visibleRowHeadedColumnToSourceColumn(r),new h.default(o,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),n=this.wot.wtViewport.oversizedRows[e];return void 0!==n&&(t=void 0===t?n:Math.max(t,n)),t}},{key:"getColumnHeaderHeight",value:function(e){var t=this.wot.wtSettings.settings.defaultRowHeight,n=this.wot.wtViewport.oversizedColumnHeaders[e];return void 0!==n&&(t=t?Math.max(t,n):n),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),n=null==t?this.instance.wtSettings.settings.defaultColumnWidth:t,o=this.wot.wtViewport.columnsRenderCalculator;if(o){var r=o.getStretchedColumnWidth(e,n);r&&(n=r)}return n}},{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,n){"use strict";function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){var n=document.createElement("TH");return t.insertBefore(n,e),t.removeChild(e),n}function i(e,t){var n=document.createElement("TD");return t.insertBefore(n,e),t.removeChild(e),n}t.__esModule=!0;var s=function(){function e(e,t){for(var n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),a=n(0),l=n(32),u=function(e){return e&&e.__esModule?e:{default:e}}(l),c=!1;t.default=function(){function e(t){o(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(),n=this.wtTable.getRenderedRowsCount(),o=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>o||(this.adjustAvailableNodes(),s=!0,this.renderColumnHeaders(),this.renderRows(r,n,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(n),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 l=(0,a.outerWidth)(this.wtTable.hider),c=(0,a.outerWidth)(this.wtTable.TABLE);if(0!==l&&c!==l&&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,n){for(var o=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(o=this.getOrCreateTrForRow(r,o),this.renderRowHeaders(i,o),this.adjustColumns(o,n+this.rowHeaderCount),this.renderCells(i,o,n),s&&!this.wot.isOverlayName(u.default.CLONE_BOTTOM)||this.resetOversizedRow(i),o.firstChild){var a=this.wot.wtTable.getRowHeight(i);a?(a--,o.firstChild.style.height=a+"px"):o.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,n=(0,a.innerHeight)(this.instance.wtTable.TBODY)-1,o=void 0,r=void 0,i=void 0,s=void 0,l=void 0;this.instance.getSetting("totalRows");if(t!==n||this.instance.getSetting("fixedRowsBottom"))for(;e;)e--,i=this.instance.wtTable.rowFilter.renderedToSource(e),o=this.instance.wtTable.getRowHeight(i),s=this.instance.wtTable.getTrForRow(i),l=s.querySelector("th"),r=l?(0,a.innerHeight)(l):(0,a.innerHeight)(s)-1,(!o&&r>this.instance.wtSettings.settings.defaultRowHeight||r>o)&&(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(),n=0;this.columnHeaderCount>n;n++)for(var o=-1*this.rowHeaderCount;t>o;o++)this.markIfOversizedColumnHeader(o);this.wot.wtViewport.hasOversizedColumnHeadersMarked[e]=!0}}},{key:"adjustColumnHeaderHeights",value:function(){for(var e=this.wot.getSetting("columnHeaders"),t=this.wot.wtTable.THEAD.childNodes,n=this.wot.wtViewport.oversizedColumnHeaders,o=0,r=e.length;r>o;o++)if(n[o]){if(!t[o]||0===t[o].childNodes.length)return;t[o].childNodes[0].style.height=n[o]+"px"}}},{key:"markIfOversizedColumnHeader",value:function(e){for(var t=this.wot.wtTable.columnFilter.renderedToSource(e),n=this.columnHeaderCount,o=this.wot.wtSettings.settings.defaultRowHeight,r=void 0,i=void 0,s=void 0,l=this.wot.getSetting("columnHeaderHeight")||[];n;)n--,r=this.wot.wtTable.getColumnHeaderHeight(n),(i=this.wot.wtTable.getColumnHeader(t,n))&&(s=(0,a.innerHeight)(i),(!r&&s>o||s>r)&&(this.wot.wtViewport.oversizedColumnHeaders[n]=s),Array.isArray(l)?null!=l[n]&&(this.wot.wtViewport.oversizedColumnHeaders[n]=l[n]):isNaN(l)||(this.wot.wtViewport.oversizedColumnHeaders[n]=l),(l[n]||l)>this.wot.wtViewport.oversizedColumnHeaders[n]&&(this.wot.wtViewport.oversizedColumnHeaders[n]=l[n]||l))}},{key:"renderCells",value:function(e,t,n){for(var o=void 0,r=void 0,s=0;n>s;s++)r=this.columnFilter.renderedToSource(s),o=0===s?t.childNodes[this.columnFilter.sourceColumnToVisibleRowHeadedColumn(r)]:o.nextSibling,"TH"==o.nodeName&&(o=i(o,t)),(0,a.hasClass)(o,"hide")||(o.className=""),o.removeAttribute("style"),this.wot.wtSettings.settings.cellRenderer(e,r,o);return o}},{key:"adjustColumnWidths",value:function(e){var t=0,n=this.wot.cloneSource?this.wot.cloneSource:this.wot,o=n.wtTable.holder,r=this.wot.getSetting("defaultColumnWidth"),i=this.wot.getSetting("rowHeaderWidth");if(o.scrollHeight>o.offsetHeight&&(t=(0,a.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 l=Array.isArray(i)?i[s]:i;l=null==l?r:l,this.COLGROUP.childNodes[s].style.width=l+"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 n=void 0;return this.wtTable.tbodyChildrenLength>e?n=0===e?this.TBODY.firstChild:t.nextSibling:(n=this.createRow(),this.appendToTbody(n)),n.className&&n.removeAttribute("class"),n}},{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,n){n.className="",n.removeAttribute("style"),this.rowHeaders[t](e,n,t)}},{key:"renderRowHeaders",value:function(e,t){for(var n=t.firstChild,o=0;this.rowHeaderCount>o;o++)n?"TD"==n.nodeName&&(n=r(n,t)):(n=document.createElement("TH"),t.appendChild(n)),this.renderRowHeader(e,o,n),n=n.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 n=this.getTrForColumnHeaders(t),o=-1*this.rowHeaderCount;e>o;o++){var r=this.columnFilter.renderedToSource(o);this.renderColumnHeader(t,r,n.childNodes[o+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,a.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 n=0,o=this.columnHeaders.length;o>n;n++){for(t=this.THEAD.childNodes[n],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,a.empty)(t)}},{key:"getTrForColumnHeaders",value:function(e){return this.THEAD.childNodes[e]}},{key:"renderColumnHeader",value:function(e,t,n){return n.className="",n.removeAttribute("style"),this.columnHeaders[e](t,n,e)}},{key:"adjustColumns",value:function(e,t){for(var n=e.childNodes.length;t>n;){e.appendChild(document.createElement("TD")),n++}for(;n>t;)e.removeChild(e.lastChild),n--}},{key:"removeRedundantColumns",value:function(e){for(;this.wtTable.tbodyChildrenLength>e;)this.TBODY.removeChild(this.TBODY.lastChild),this.wtTable.tbodyChildrenLength--}}]),e}()},function(e,t,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),s=n(0),a=n(1),l=n(4),u=o(l),c=n(157),h=o(c),d=n(158),f=o(d);t.default=function(){function e(t){var n=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(){n.clientHeight=n.getWorkspaceHeight()})}return i(e,[{key:"getWorkspaceHeight",value:function(){var e=this.instance.wtOverlays.topOverlay.trimmingContainer,t=void 0,n=0;return e===window?n=document.documentElement.clientHeight:(t=(0,s.outerHeight)(e),n=t>0&&e.clientHeight>0?e.clientHeight:1/0),n}},{key:"getWorkspaceWidth",value:function(){var e=void 0,t=this.wot.getSetting("totalColumns"),n=this.instance.wtOverlays.leftOverlay.trimmingContainer,o=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),n===window&&t>0&&this.sumColumnWidths(0,t-1)>e?document.documentElement.clientWidth:n===window||"scroll"!=(o=(0,s.getStyle)(this.instance.wtOverlays.leftOverlay.trimmingContainer,"overflow"))&&"hidden"!=o&&"auto"!=o?"none"!==r&&r?e:Math.max(e,(0,s.outerWidth)(this.instance.wtTable.TABLE)):Math.max(e,n.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 n=0;t>e;)n+=this.wot.wtTable.getColumnWidth(e),e++;return n}},{key:"getContainerFillWidth",value:function(){if(this.containerWidth)return this.containerWidth;var e=this.instance.wtTable.holder,t=void 0,n=void 0;return n=document.createElement("div"),n.style.width="100%",n.style.height="1px",e.appendChild(n),t=n.offsetWidth,this.containerWidth=t,e.removeChild(n),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 n=0,o=t.length;o>n;n++)this.rowHeaderWidth+=e[n]||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,a=t.length;a>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],n=void 0,o=void 0,r=void 0,i=void 0,a=void 0,l=void 0,u=void 0;return this.rowHeaderWidth=NaN,n=this.wot.wtSettings.settings.renderAllRows&&!t?1/0:this.getViewportHeight(),o=this.wot.wtOverlays.topOverlay.getScrollPosition()-this.wot.wtOverlays.topOverlay.getTableParentOffset(),0>o&&(o=0),r=this.wot.getSetting("fixedRowsTop"),a=this.wot.getSetting("fixedRowsBottom"),u=this.wot.getSetting("totalRows"),r&&(l=this.wot.wtOverlays.topOverlay.sumCellSizes(0,r),o+=l,n-=l),a&&this.wot.wtOverlays.bottomOverlay.clone&&(l=this.wot.wtOverlays.bottomOverlay.sumCellSizes(u-a,u),n-=l),i=this.wot.wtTable.holder.clientHeight===this.wot.wtTable.holder.offsetHeight?0:(0,s.getScrollbarWidth)(),new f.default(n,o,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],n=this.getViewportWidth(),o=void 0,r=void 0;if(this.columnHeaderHeight=NaN,o=this.wot.wtOverlays.leftOverlay.getScrollPosition()-this.wot.wtOverlays.leftOverlay.getTableParentOffset(),0>o&&(o=0),r=this.wot.getSetting("fixedColumnsLeft")){var i=this.wot.wtOverlays.leftOverlay.sumCellSizes(0,r);o+=i,n-=i}return this.wot.wtTable.holder.clientWidth!==this.wot.wtTable.holder.offsetWidth&&(n-=(0,s.getScrollbarWidth)()),new h.default(n,o,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,n){return e.wot.getSetting("onBeforeStretchingColumnWidth",t,n)})}},{key:"createRenderCalculators",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(e){var t=this.createRowsCalculator(!0),n=this.createColumnsCalculator(!0);this.areAllProposedVisibleRowsAlreadyRendered(t)&&this.areAllProposedVisibleColumnsAlreadyRendered(n)||(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,a.objectEach)(this.hasOversizedColumnHeadersMarked,function(e,t,n){n[t]=void 0})}}]),e}()},function(e,t,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),s=n(0),a=n(11),l=n(1),u=n(27),c=n(4),h=o(c),d=n(52),f=o(d),p=n(32);o(p);t.default=function(){function e(t,n){r(this,e),n&&(this.eventManager=new h.default(t),this.instance=t,this.wot=t,this.settings=n,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(n),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,n=this.main.childNodes.length;n>t;t++)!function(t,n){e.eventManager.addEventListener(e.main.childNodes[t],"mouseenter",function(n){return e.onMouseEnter(n,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 n(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 o(e){n(e)&&(r.eventManager.removeEventListener(document.body,"mousemove",o),t.style.display="block")}if(this.mouseDown&&this.wot.getSetting("hideBorderOnMouseDownOver")){e.preventDefault(),(0,a.stopImmediatePropagation)(e);var r=this,i=t.getBoundingClientRect();t.style.display="none",this.eventManager.addEventListener(document.body,"mousemove",o)}}},{key:"createBorders",value:function(e){this.main=document.createElement("div");var t=["top","left","bottom","right","corner"],n=this.main.style;n.position="absolute",n.top=0,n.left=0;for(var o=0;5>o;o++){var r=t[o],i=document.createElement("div");i.className="wtBorder "+(this.settings.className||""),this.settings[r]&&this.settings[r].hide&&(i.className+=" hidden"),n=i.style,n.backgroundColor=this.settings[r]&&this.settings[r].color?this.settings[r].color:e.border.color,n.height=this.settings[r]&&this.settings[r].width?this.settings[r].width+"px":e.border.width+"px",n.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,l.hasOwnProperty)(e,t)&&(this.selectionHandles.styles.bottomRightHitArea[t]=e[t],this.selectionHandles.styles.topLeftHitArea[t]=e[t]);var n={position:"absolute",height:"10px",width:"10px","border-radius":parseInt(10/1.5,10)+"px",background:"#F5F5FF",border:"1px solid #4285c8"};for(var o in n)(0,l.hasOwnProperty)(n,o)&&(this.selectionHandles.styles.bottomRight[o]=n[o],this.selectionHandles.styles.topLeft[o]=n[o]);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,n,o,r,i){var s=parseInt(this.selectionHandles.styles.topLeft.width,10),a=parseInt(this.selectionHandles.styles.topLeftHitArea.width,10);this.selectionHandles.styles.topLeft.top=parseInt(n-s,10)+"px",this.selectionHandles.styles.topLeft.left=parseInt(o-s,10)+"px",this.selectionHandles.styles.topLeftHitArea.top=parseInt(n-a/4*3,10)+"px",this.selectionHandles.styles.topLeftHitArea.left=parseInt(o-a/4*3,10)+"px",this.selectionHandles.styles.bottomRight.top=parseInt(n+i,10)+"px",this.selectionHandles.styles.bottomRight.left=parseInt(o+r,10)+"px",this.selectionHandles.styles.bottomRightHitArea.top=parseInt(n+i-a/4,10)+"px",this.selectionHandles.styles.bottomRightHitArea.left=parseInt(o+r-a/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,n,o,r,i,a,l,c,h,d,p,g,v,m,y,w,C,b;b=this.wot.wtTable.getRenderedRowsCount();for(var E=0;b>E;E++){var _=this.wot.wtTable.rowFilter.renderedToSource(E);if(_>=e[0]&&e[2]>=_){v=_;break}}for(var S=b-1;S>=0;S--){var O=this.wot.wtTable.rowFilter.renderedToSource(S);if(O>=e[0]&&e[2]>=O){y=O;break}}b=this.wot.wtTable.getRenderedColumnsCount();for(var T=0;b>T;T++){var R=this.wot.wtTable.columnFilter.renderedToSource(T);if(R>=e[1]&&e[3]>=R){m=R;break}}for(var k=b-1;k>=0;k--){var M=this.wot.wtTable.columnFilter.renderedToSource(k);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,n=this.wot.wtTable.getCell(new f.default(v,m)),o=t?this.wot.wtTable.getCell(new f.default(y,w)):n,r=(0,s.offset)(n),i=t?(0,s.offset)(o):r,a=(0,s.offset)(this.wot.wtTable.TABLE),c=r.top,p=i.top+(0,s.outerHeight)(o)-c,d=r.left,g=i.left+(0,s.outerWidth)(o)-d,l=c-a.top-1,h=d-a.left-1;var N=(0,s.getComputedStyle)(n);parseInt(N.borderTopWidth,10)>0&&(l+=1,p=p>0?p-1:0),parseInt(N.borderLeftWidth,10)>0&&(h+=1,g=g>0?g-1:0),this.topStyle.top=l+"px",this.topStyle.left=h+"px",this.topStyle.width=g+"px",this.topStyle.display="block",this.leftStyle.top=l+"px",this.leftStyle.left=h+"px",this.leftStyle.height=p+"px",this.leftStyle.display="block";var D=Math.floor(this.settings.border.width/2);this.bottomStyle.top=l+p-D+"px",this.bottomStyle.left=h+"px",this.bottomStyle.width=g+"px",this.bottomStyle.display="block",this.rightStyle.top=l+"px",this.rightStyle.left=h+g-D+"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=l+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&&o.offsetLeft+(0,s.outerWidth)(o)+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&&o.offsetTop+(0,s.outerHeight)(o)+parseInt(this.cornerDefaultStyle.height,10)/2>=(0,s.innerHeight)(C)&&(this.cornerStyle.top=Math.floor(l+p-3-parseInt(this.cornerDefaultStyle.height,10)/2)+"px",this.cornerStyle.borderBottomWidth=0),this.cornerStyle.display="block"),(0,u.isMobileBrowser)()&&this.updateMultipleSelectionHandlesPosition(v,m,l,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,n){"use strict";function o(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 n=0;if(e.keyCode===r.KEY_CODES.C&&(e.ctrlKey||e.metaKey))return;t.isOpened()||(n+=10),t.htEditor&&t.instance._registerTimeout(setTimeout(function(){t.queryChoices(t.TEXTAREA.value),d=!0},n))}}t.__esModule=!0;var r=n(20),i=n(17),s=n(33),a=n(2),l=n(0),u=n(287),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,l.addClass)(this.htContainer,"autocompleteEditor"),(0,l.addClass)(this.htContainer,-1===window.navigator.platform.indexOf("Mac")?"":"htMacScroll")};var d=!1;h.prototype.prepare=function(){this.instance.addHook("beforeKeyDown",o),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,n=void 0===this.cellProperties.trimDropdown||this.cellProperties.trimDropdown;this.TEXTAREA.style.visibility="visible",this.focus(),e.updateSettings({colWidths:n?[(0,l.outerWidth)(this.TEXTAREA)-2]:void 0,width:n?(0,l.outerWidth)(this.TEXTAREA)+(0,l.getScrollbarWidth)()+2:void 0,afterRenderer:function(e,n,o,r,s,a){var l=t.cellProperties,u=l.filteringCaseSensitive,c=l.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 o=this.getPlugin("autoColumnSize").widths;return o[t]&&(e=o[t]),n?e:e+15}}),this.htEditor.view.wt.wtTable.holder.parentNode.style["padding-right"]=(0,l.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 n=this.cellProperties.source;"function"==typeof n?n.call(this.cellProperties,e,function(e){t.rawChoices=e,t.updateChoicesList(t.stripValuesIfNeeded(e))}):Array.isArray(n)?(this.rawChoices=n,this.updateChoicesList(this.stripValuesIfNeeded(n))):this.updateChoicesList([])},h.prototype.updateChoicesList=function(e){var t=(0,l.getCaretPosition)(this.TEXTAREA),n=(0,l.getSelectionEndPosition)(this.TEXTAREA),o=this.cellProperties.sortByRelevance,r=this.cellProperties.filter,i=null,s=null;o&&(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&&(!o||d<u);d++)c.push(u?e[i[d]]:e[d]);s=0,e=c}this.strippedChoices=e,this.htEditor.loadData((0,a.pivot)([e])),this.updateDropdownHeight(),this.flipDropdownIfNeeded(),!0===this.cellProperties.strict&&this.highlightBestMatchingChoice(s),this.instance.listen(!1),(0,l.setCaretPosition)(this.TEXTAREA,t,t===n?void 0:n)},h.prototype.flipDropdownIfNeeded=function(){var e=(0,l.offset)(this.TEXTAREA),t=(0,l.outerHeight)(this.TEXTAREA),n=this.getDropdownHeight(),o=(0,l.getTrimmingContainer)(this.instance.view.wt.wtTable.TABLE),r=o.scrollTop,i=(0,l.outerHeight)(this.instance.view.wt.wtTable.THEAD),s={row:0,col:0};o!==window&&(s=(0,l.offset)(o));var a=e.top-s.top-i+r,u=o.scrollHeight-a-i-t,c=n>u&&a>u;return c?this.flipDropdown(n):this.unflipDropdown(),this.limitDropdownIfNeeded(c?a:u,n),c},h.prototype.limitDropdownIfNeeded=function(e,t){if(t>e){var n=0,o=0,r=0,i=null;do{r=this.htEditor.getRowHeight(o)||this.htEditor.view.wt.wtSettings.settings.defaultRowHeight,n+=r,o++}while(e>n);i=n-r,this.htEditor.flipped&&(this.htEditor.rootElement.style.top=parseInt(this.htEditor.rootElement.style.top,10)+t-i+"px"),this.setDropdownHeight(n-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,l.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",o),c.default.prototype.finishEditing.apply(this,arguments)},h.prototype.highlightBestMatchingChoice=function(e){"number"==typeof e?this.htEditor.selectCell(e,0,void 0,void 0,void 0,!1):this.htEditor.deselectCell()},h.sortByRelevance=function(e,t,n){var o=[],r=void 0,a=e.length,l=void 0,u=void 0,c=[],h=void 0,d=t.length;if(0===a){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!==(l=n?r.indexOf(e):r.toLowerCase().indexOf(e.toLowerCase()))&&(u=r.length-l-a,o.push({baseIndex:h,index:l,charsLeft:u,value:r}));for(o.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=o.length;d>h;h++)c.push(o[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,n=(0,a.arrayMap)(e,function(e){return(0,i.stringify)(e)});return(0,a.arrayMap)(n,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},n=!1;return e===r.KEY_CODES.ARROW_DOWN&&t.row>0&&t.row<this.htEditor.countRows()-1&&(n=!0),e===r.KEY_CODES.ARROW_UP&&t.row>-1&&(n=!0),n},h.prototype.discardEditor=function(e){c.default.prototype.discardEditor.apply(this,arguments),this.instance.view.render()},t.default=h},function(e,t,n){"use strict";t.__esModule=!0;var o=n(20),r=n(1),i=n(0),s=n(11),a=n(53),l=function(e){return e&&e.__esModule?e:{default:e}}(a),u=l.default.prototype.extend();u.prototype.createElements=function(){l.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,n,o,i,s){l.default.prototype.prepare.apply(this,arguments);var a=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 n=this.getSourceData(t.row,t.col);void 0!==n&&a.setValue(n),a.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,n,r=this.getActiveEditor(),i=r.htEditor.getInstance();if(e.keyCode==o.KEY_CODES.ARROW_DOWN)if(i.getSelected()||i.flipped){if(i.getSelected())if(i.flipped)t=i.getSelected()[0]+1;else if(!i.flipped){n=i.getSelected()[0];var a=i.countRows()-1;t=Math.min(a,n+1)}}else t=0;else e.keyCode==o.KEY_CODES.ARROW_UP&&(!i.getSelected()&&i.flipped?t=i.countRows()-1:i.getSelected()&&(i.flipped?(n=i.getSelected()[0],t=Math.max(0,n-1)):(n=i.getSelected()[0],t=n-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),l.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(),l.default.prototype.close.apply(this,arguments)},u.prototype.focus=function(){this.instance.listen(),l.default.prototype.focus.apply(this,arguments)},u.prototype.beginEditing=function(e){var t=this.instance.getSettings().onBeginEditing;t&&!1===t()||l.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 n=this.htEditor.getInstance().getValue();void 0!==n&&this.setValue(n)}return l.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,n){"use strict";function o(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=o},function(e,t,n){"use strict";!function(e){function n(e){return e.split('"').length-1}var o={parse:function(e){var t,o,r,i,s,a,l,u=[],c=0;for(r=e.split("\n"),r.length>1&&""===r[r.length-1]&&r.pop(),t=0,o=r.length;o>t;t+=1){for(r[t]=r[t].split("\t"),i=0,s=r[t].length;s>i;i+=1)u[c]||(u[c]=[]),a&&0===i?(l=u[c].length-1,u[c][l]=u[c][l]+"\n"+r[t][0],a&&1&n(r[t][0])&&(a=!1,u[c][l]=u[c][l].substring(0,u[c][l].length-1).replace(/""/g,'"'))):i===s-1&&0===r[t][i].indexOf('"')&&1&n(r[t][i])?(u[c].push(r[t][i].substring(1).replace(/""/g,'"')),a=!0):(u[c].push(r[t][i].replace(/""/g,'"')),a=!1);a||(c+=1)}return u},stringify:function(e){var t,n,o,r,i,s="";for(t=0,n=e.length;n>t;t+=1){for(r=e[t].length,o=0;r>o;o+=1)o>0&&(s+="\t"),i=e[t][o],"string"==typeof i?i.indexOf("\n")>-1?s+='"'+i.replace(/"/g,'""')+'"':s+=i:s+=null===i||void 0===i?"":i;t!==n-1&&(s+="\n")}return s}};t.parse=o.parse,t.stringify=o.stringify}(window)},function(e,t,n){"use strict";function o(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 l.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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}();t.registerIdentity=r,t.getTranslator=i;var a=n(84),l=function(e){return e&&e.__esModule?e:{default:e}}(a),u=n(1),c=function(){function e(t){o(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,n){"use strict";function o(e){s.set(e,!0)}function r(e){return e===a}function i(e){return s.has(e)}t.__esModule=!0,t.registerAsRootInstance=o,t.hasValidParameter=r,t.isRootInstance=i;var s=t.holder=new WeakMap,a=t.rootInstanceSymbol=Symbol("rootInstance")},function(e,t,n){"use strict";function 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},i=n(17),s=n(1);o.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,n,o,a;for(t=0,n=this.countCols();n>t;t++)if(""!==(o=this.getDataAtCell(e,t))&&null!==o&&(0,i.isDefined)(o))return"object"===(void 0===o?"undefined":r(o))&&(a=this.getCellMeta(e,t),(0,s.isObjectEquals)(this.getSchema()[a.prop],o));return!0},isEmptyCol:function(e){var t,n,o;for(t=0,n=this.countRows();n>t;t++)if(""!==(o=this.getDataAtCell(t,e))&&null!==o&&(0,i.isDefined)(o))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,numericFormat: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=o},function(e,t,n){"use strict";function o(e,t,n){var o=(0,s.getLanguageDictionary)(e);if(null===o)return null;var i=o[t];if((0,l.isUndefined)(i))return null;var a=r(i,n);return Array.isArray(a)?a[0]:a}function r(e,t){var n=e;return(0,i.arrayEach)((0,a.getPhraseFormatters)(),function(o){n=o(e,t)}),n}t.__esModule=!0,t.getTranslatedPhrase=o;var i=n(2),s=n(66),a=n(369),l=n(17)},function(e,t,n){"use strict";function o(e,t){return(0,c.objectEach)(t,function(t,n){(0,u.isUndefined)(e[n])&&(e[n]=t)}),e}function r(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:e,o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:t;if(e>t){var r=[o,n];n=r[0],o=r[1]}return n+"-"+o}function i(e){var t=/^([a-zA-Z]{2})-([a-zA-Z]{2})$/,n=t.exec(e);return n?n[1].toLowerCase()+"-"+n[2].toUpperCase():e}function s(e,t){var n=i(e);(0,d.hasLanguageDictionary)(n)?t.language=n:(t.language=d.DEFAULT_LANGUAGE_CODE,a(e))}function a(e){(0,u.isDefined)(e)&&console.error((0,h.toSingleLine)(l,e))}t.__esModule=!0;var l=function(e,t){return Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}(['Language with code "','" was not found. You should register particular language \n before using it. Read more about this issue at: https://docs.handsontable.com/i18n/missing-language-code.'],['Language with code "','" was not found. You should register particular language \n before using it. Read more about this issue at: https://docs.handsontable.com/i18n/missing-language-code.']);t.extendNotExistingKeys=o,t.createCellHeadersRange=r,t.normalizeLanguageCode=i,t.applyLanguageSetting=s,t.warnUserAboutLanguageRegistration=a;var u=n(17),c=n(1),h=n(277),d=n(66)},function(e,t,n){"use strict";function o(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),s=n(1),a=n(5),l=n(17);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,n){var o=this,r=new Map;return"number"==typeof n&&(n={from:n,to:n}),(0,a.rangeEach)(n.from,n.to,function(n){var i=o.generateSample(e,t,n);r.set(n,i)}),r}},{key:"generateSample",value:function(e,t,n){var r=this,i=new Map,u=[],c=void 0;return(0,a.rangeEach)(t.from,t.to,function(t){var a=void 0;if("row"===e)a=r.dataFactory(n,t);else{if("col"!==e)throw Error("Unsupported sample type");a=r.dataFactory(t,n)}c=(0,s.isObject)(a)?Object.keys(a).length:Array.isArray(a)?a.length:(0,l.stringify)(a).length,i.has(c)||i.set(c,{needed:r.getSampleCount(),strings:[]});var h=i.get(c);if(h.needed){if(!(u.indexOf(a)>-1)||r.allowDuplicates){h.strings.push(o({value:a},"row"===e?"col":"row",t)),u.push(a),h.needed--}}}),i}}]),e}()},function(e,t,n){"use strict";t.__esModule=!0;var o=n(2),r=n(1),i=n(5),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,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,r=(0,o.arrayMax)(this._arrayMap)+1,s=[];return(0,i.rangeEach)(n-1,function(n){s.push(t._arrayMap.splice(e+n,0,r+n))}),s},removeItems:function(e){var t=this,n=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,o.arrayReduce)(e,function(e,n){return t._arrayMap.splice(n,1),e.concat(i.slice(n,n+1))},[])}else r=this._arrayMap.splice(e,n);return r},unshiftItems:function(e){function t(e){return(0,o.arrayReduce)(r,function(t,n){return e>n&&t++,t},0)}var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,r=this.removeItems(e,n);this._arrayMap=(0,o.arrayMap)(this._arrayMap,function(e,n){var o=t(e);return o&&(e-=o),e})},shiftItems:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1;this._arrayMap=(0,o.arrayMap)(this._arrayMap,function(t){return e>t||(t+=n),t}),(0,i.rangeEach)(n-1,function(n){t._arrayMap.splice(e+n,0,e+n)})},clearMap:function(){this._arrayMap.length=0}};(0,r.defineGetter)(s,"MIXIN_NAME","arrayMapper",{writable:!1,enumerable:!1}),t.default=s},function(e,t,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=n(5),s=0;t.default=function(){function e(t){o(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,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=0;t.default=function(){function e(t){o(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,n){"use strict";var o,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 n(){this.constructor=e}for(var o in t)t.hasOwnProperty(o)&&(e[o]=t[o]);e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)},s=Error;!function(e){function t(e,n){switch(void 0===e?"undefined":r(e)){case"undefined":case"boolean":case"string":case"number":return e===n;case"object":if(null===e)return null===n;if(R(e)){if(!R(n)||e.length!==n.length)return!1;for(var o=0,i=e.length;i>o;o++)if(!t(e[o],n[o]))return!1;return!0}var s=C(n),a=s.length;if(C(e).length!==a)return!1;for(var o=0;a>o;o++)if(!t(e[o],n[o]))return!1;return!0;default:return!1}}function n(e){return-1===e.indexOf("/")&&-1===e.indexOf("~")?e:e.replace(/~/g,"~0").replace(/\//g,"~1")}function o(e){for(var t=0,n=S.length;n>t;t++)if(S[t].obj===e)return S[t]}function a(e,t){for(var n=0,o=e.observers.length;o>n;n++)if(e.observers[n].callback===t)return e.observers[n].observer}function l(e,t){for(var n=0,o=e.observers.length;o>n;n++)if(e.observers[n].observer===t)return void e.observers.splice(n,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 n,r=[],i=o(e);if(i?n=a(i,t):(i=new O(e),S.push(i)),n)return n;if(n={},i.value=c(e),t){n.callback=t,n.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(n)},p=function(){clearTimeout(n.next),n.next=setTimeout(function(){f(),h=0,n.next=setTimeout(g,u[h++])},0)},g=function e(){f(),h==u.length&&(h=u.length-1),n.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))),n.next=setTimeout(g,u[h++])}return n.patches=r,n.object=e,n.unobserve=function(){d(n),clearTimeout(n.next),l(i,n),"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 T(t,n)),n}function d(e){for(var t,n=0,o=S.length;o>n;n++)if(S[n].obj===e.object){t=S[n];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,o,i){for(var s=C(t),a=C(e),l=!1,u=a.length-1;u>=0;u--){var h=a[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,o,i+"/"+n(h)):d!=p&&(!0,o.push({op:"replace",path:i+"/"+n(h),value:c(p)}))}else o.push({op:"remove",path:i+"/"+n(h)}),l=!0}if(l||s.length!=a.length)for(var u=0;s.length>u;u++){var h=s[u];e.hasOwnProperty(h)||o.push({op:"add",path:i+"/"+n(h),value:c(t[h])})}}function p(e){for(var t,n=0,o=e.length;o>n;){t=e.charCodeAt(n);{if(48>t||t>57)return!1;n++}}return!0}function g(e,t,n){for(var o,r,i=!1,s=0,a=t.length;a>s;){o=t[s],s++;for(var l=o.path||"",u=l.split("/"),c=e,h=1,d=u.length,f=void 0;;){if(r=u[h],n&&void 0===f&&(void 0===c[r]?f=u.slice(0,h).join("/"):h==d-1&&(f=o.path),void 0!==f&&this.validator(o,s-1,e,f)),h++,void 0===r&&h>=d){i=_[o.op].call(o,c,r,e);break}if(R(c)){if("-"===r)r=c.length;else{if(n&&!p(r))throw new k("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,o.path,o);r=parseInt(r,10)}if(h>=d){if(n&&"add"===o.op&&r>c.length)throw new k("The specified index MUST NOT be greater than the number of elements in the array","OPERATION_VALUE_OUT_OF_BOUNDS",s-1,o.path,o);i=E[o.op].call(o,c,r,e);break}}else if(r&&-1!=r.indexOf("~")&&(r=r.replace(/~1/g,"/").replace(/~0/g,"~")),h>=d){i=b[o.op].call(o,c,r,e);break}c=c[r]}}return i}function v(e,t){var n=[];return f(e,t,n,""),n}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,n,o,i){if("object"!==(void 0===t?"undefined":r(t))||null===t||R(t))throw new k("Operation is not an object","OPERATION_NOT_AN_OBJECT",n,t,o);if(!b[t.op])throw new k("Operation `op` property is not one of operations defined in RFC-6902","OPERATION_OP_INVALID",n,t,o);if("string"!=typeof t.path)throw new k("Operation `path` property is not a string","OPERATION_PATH_INVALID",n,t,o);if(("move"===t.op||"copy"===t.op)&&"string"!=typeof t.from)throw new k("Operation `from` property is not present (applicable in `move` and `copy` operations)","OPERATION_FROM_REQUIRED",n,t,o);if(("add"===t.op||"replace"===t.op||"test"===t.op)&&void 0===t.value)throw new k("Operation `value` property is not present (applicable in `add`, `replace` and `test` operations)","OPERATION_VALUE_REQUIRED",n,t,o);if(("add"===t.op||"replace"===t.op||"test"===t.op)&&m(t.value))throw new k("Operation `value` property is not present (applicable in `add`, `replace` and `test` operations)","OPERATION_VALUE_CANNOT_CONTAIN_UNDEFINED",n,t,o);if(o)if("add"==t.op){var s=t.path.split("/").length,a=i.split("/").length;if(s!==a+1&&s!==a)throw new k("Cannot perform an `add` operation at the desired path","OPERATION_PATH_CANNOT_ADD",n,t,o)}else if("replace"===t.op||"remove"===t.op||"_get"===t.op){if(t.path!==i)throw new k("Cannot perform the operation at a path that does not exist","OPERATION_PATH_UNRESOLVABLE",n,t,o)}else if("move"===t.op||"copy"===t.op){var l={op:"_get",path:t.from,value:void 0},u=e.validate([l],o);if(u&&"OPERATION_PATH_UNRESOLVABLE"===u.name)throw new k("Cannot perform the operation from a path that does not exist","OPERATION_FROM_UNRESOLVABLE",n,t,o)}}function w(e,t){try{if(!R(e))throw new k("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 n=0;e.length>n;n++)this.validator(e[n],n)}catch(e){if(e instanceof k)return e;throw e}}var C=function(e){if(R(e)){for(var t=Array(e.length),n=0;t.length>n;n++)t[n]=""+n;return t}if(Object.keys)return Object.keys(e);var t=[];for(var o in e)e.hasOwnProperty(o)&&t.push(o);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,n){var o={op:"_get",path:this.from};return g(n,[o]),g(n,[{op:"remove",path:this.from}]),g(n,[{op:"add",path:this.path,value:o.value}]),!0},copy:function(e,t,n){var o={op:"_get",path:this.from};return g(n,[o]),g(n,[{op:"add",path:this.path,value:o.value}]),!0},test:function(e,n){return t(e[n],this.value)},_get:function(e,t){this.value=e[t]}},E={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},_={add:function(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}},S=[],O=function(){function e(e){this.observers=[],this.obj=e}return e}(),T=function(){function e(e,t){this.callback=e,this.observer=t}return e}();e.unobserve=u,e.observe=h,e.generate=d;var R;R=Array.isArray?Array.isArray:function(e){return e.push&&"number"==typeof e.length},e.apply=g,e.compare=v;var k=function(e){function t(t,n,o,r,i){e.call(this,t),this.message=t,this.name=n,this.index=o,this.operation=r,this.tree=i}return i(t,e),t}(s);e.JsonPatchError=k,e.Error=k,e.validator=y,e.validate=w}(o||(o={})),t.apply=o.apply,t.observe=o.observe,t.unobserve=o.unobserve,t.generate=o.generate,t.compare=o.compare,t.validate=o.validate,t.validator=o.validator,t.JsonPatchError=o.JsonPatchError,t.Error=o.Error},function(e,t,n){"use strict";function o(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){var n=new h.default(e,t||{},Q.rootInstanceSymbol);return n.init(),n}t.__esModule=!0,n(91),n(105),n(106),n(110),n(111),n(113),n(115),n(116),n(117),n(118),n(119),n(120),n(121),n(122),n(124),n(126),n(127),n(128),n(129),n(130),n(131),n(132),n(133),n(134),n(135),n(136),n(137),n(138),n(81),n(139),n(140),n(142),n(143),n(144),n(145),n(146),n(147),n(148),n(150),n(151),n(152),n(154),n(155),n(156),n(321),n(322),n(323);var s=n(16),a=n(9),l=n(28),u=n(83),c=n(84),h=r(c),d=n(371),f=r(d),p=n(4),g=r(p),v=n(8),m=r(v),y=n(87),w=r(y),C=n(2),b=o(C),E=n(27),_=o(E),S=n(86),O=o(S),T=n(288),R=o(T),k=n(35),M=o(k),N=n(37),D=o(N),A=n(17),H=o(A),P=n(5),x=o(P),L=n(1),I=o(L),j=n(85),W=o(j),F=n(33),B=o(F),V=n(20),U=o(V),Y=n(0),z=o(Y),G=n(11),X=o(G),K=n(372),q=o(K),$=n(6),J=n(292),Z=r(J),Q=n(291),ee=n(293),te=n(7),ne=o(te),oe=n(66);(0,f.default)(i),i.Core=h.default,i.DefaultSettings=Z.default,i.EventManager=g.default,i._getListenersCounter=p.getListenersCounter,i.buildDate="06/12/2017 09:46:21",i.packageName="handsontable",i.version="0.35.0";i.hooks=m.default.getSingleton(),i.__GhostTable=w.default;var re=[b,_,O,R,M,D,H,x,I,W,B,U],ie=[z,X];i.helper={},i.dom={},b.arrayEach(re,function(e){b.arrayEach(Object.getOwnPropertyNames(e),function(t){"_"!==t.charAt(0)&&(i.helper[t]=e[t])})}),b.arrayEach(ie,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[B.toUpperCaseFirst(e)+"Editor"]=(0,s.getEditor)(e)}),i.editors.registerEditor=s.registerEditor,i.editors.getEditor=s.getEditor,i.renderers={},b.arrayEach((0,a.getRegisteredRendererNames)(),function(e){var t=(0,a.getRenderer)(e);"base"===e&&(i.renderers.cellDecorator=t),i.renderers[B.toUpperCaseFirst(e)+"Renderer"]=t}),i.renderers.registerRenderer=a.registerRenderer,i.renderers.getRenderer=a.getRenderer,i.validators={},b.arrayEach((0,l.getRegisteredValidatorNames)(),function(e){i.validators[B.toUpperCaseFirst(e)+"Validator"]=(0,l.getValidator)(e)}),i.validators.registerValidator=l.registerValidator,i.validators.getValidator=l.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=$.registerPlugin,i.languages={},i.languages.dictionaryKeys=ne,i.languages.getLanguageDictionary=oe.getLanguageDictionary,i.languages.getLanguagesDictionaries=oe.getLanguagesDictionaries,i.languages.registerLanguageDictionary=oe.registerLanguageDictionary,i.languages.getTranslatedPhrase=function(){return ee.getTranslatedPhrase.apply(void 0,arguments)},t.default=i},function(e,t,n){var o=n(19),r=n(18),i=n(38);e.exports=n(22)?Object.defineProperties:function(e,t){r(e);for(var n,s=i(t),a=s.length,l=0;a>l;)o.f(e,n=s[l++],t[n]);return e}},function(e,t,n){"use strict";var o=n(69),r=n(46),i=n(49),s={};n(30)(s,n(10)("iterator"),function(){return this}),e.exports=function(e,t,n){e.prototype=o(s,{next:r(1,n)}),i(e,t+" Iterator")}},function(e,t,n){var o=n(25),r=n(40),i=n(71)("IE_PROTO"),s=Object.prototype;e.exports=Object.getPrototypeOf||function(e){return e=r(e),o(e,i)?e[i]:"function"==typeof e.constructor&&e instanceof e.constructor?e.constructor.prototype:e instanceof Object?s:null}},function(e,t,n){var o=n(15),r=n(104).set;e.exports=function(e,t,n){var i,s=t.constructor;return s!==n&&"function"==typeof s&&(i=s.prototype)!==n.prototype&&o(i)&&r&&r(e,i),e}},function(e,t,n){var o=n(306);e.exports=function(e,t){return new(o(e))(t)}},function(e,t,n){var o=n(15),r=n(107),i=n(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),o(t)&&null===(t=t[i])&&(t=void 0)),void 0===t?Array:t}},function(e,t,n){var o=n(18),r=n(57),i=n(10)("species");e.exports=function(e,t){var n,s=o(e).constructor;return void 0===s||void 0==(n=o(s)[i])?t:r(n)}},function(e,t){e.exports=function(e,t,n){var o=void 0===n;switch(t.length){case 0:return o?e():e.call(n);case 1:return o?e(t[0]):e.call(n,t[0]);case 2:return o?e(t[0],t[1]):e.call(n,t[0],t[1]);case 3:return o?e(t[0],t[1],t[2]):e.call(n,t[0],t[1],t[2]);case 4:return o?e(t[0],t[1],t[2],t[3]):e.call(n,t[0],t[1],t[2],t[3])}return e.apply(n,t)}},function(e,t,n){var o=n(12),r=n(76).set,i=o.MutationObserver||o.WebKitMutationObserver,s=o.process,a=o.Promise,l="process"==n(39)(s);e.exports=function(){var e,t,n,u=function(){var o,r;for(l&&(o=s.domain)&&o.exit();e;){r=e.fn,e=e.next;try{r()}catch(o){throw e?n():t=void 0,o}}t=void 0,o&&o.enter()};if(l)n=function(){s.nextTick(u)};else if(i){var c=!0,h=document.createTextNode("");new i(u).observe(h,{characterData:!0}),n=function(){h.data=c=!c}}else if(a&&a.resolve){var d=a.resolve();n=function(){d.then(u)}}else n=function(){r.call(o,u)};return function(o){var r={fn:o,next:void 0};t&&(t.next=r),e||(e=r,n()),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,n){var o=n(18),r=n(15),i=n(112);e.exports=function(e,t){if(o(e),r(t)&&t.constructor===e)return t;var n=i.f(e);return(0,n.resolve)(t),n.promise}},function(e,t,n){var o=n(12),r=n(47),i=n(60),s=n(114),a=n(19).f;e.exports=function(e){var t=r.Symbol||(r.Symbol=i?{}:o.Symbol||{});"_"==e.charAt(0)||e in t||a(t,e,{value:s.f(e)})}},function(e,t,n){var o=n(38),r=n(63),i=n(51);e.exports=function(e){var t=o(e),n=r.f;if(n)for(var s,a=n(e),l=i.f,u=0;a.length>u;)l.call(e,s=a[u++])&&t.push(s);return t}},function(e,t,n){var o=n(26),r=n(77).f,i={}.toString,s="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],a=function(e){try{return r(e)}catch(e){return s.slice()}};e.exports.f=function(e){return s&&"[object Window]"==i.call(e)?a(e):r(o(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,n){var o=n(54),r=n(34);e.exports=function(e){return function(t,n){var i,s,a=r(t)+"",l=o(n),u=a.length;return 0>l||l>=u?e?"":void 0:(i=a.charCodeAt(l),55296>i||i>56319||l+1===u||56320>(s=a.charCodeAt(l+1))||s>57343?e?a.charAt(l):i:e?a.slice(l,l+2):s-56320+(i-55296<<10)+65536)}}},function(e,t,n){"use strict";var o=n(18);e.exports=function(){var e=o(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,n){"use strict";var o=n(40),r=n(55),i=n(23);e.exports=[].copyWithin||function(e,t){var n=o(this),s=i(n.length),a=r(e,s),l=r(t,s),u=arguments.length>2?arguments[2]:void 0,c=Math.min((void 0===u?s:r(u,s))-l,s-a),h=1;for(a>l&&l+c>a&&(h=-1,l+=c-1,a+=c-1);c-- >0;)l in n?n[a]=n[l]:delete n[a],a+=h,l+=h;return n}},function(e,t,n){"use strict";var o=n(40),r=n(55),i=n(23);e.exports=function(e){for(var t=o(this),n=i(t.length),s=arguments.length,a=r(s>1?arguments[1]:void 0,n),l=s>2?arguments[2]:void 0,u=void 0===l?n:r(l,n);u>a;)t[a++]=e;return t}},function(e,t,n){var o=n(77),r=n(63),i=n(18),s=n(12).Reflect;e.exports=s&&s.ownKeys||function(e){var t=o.f(i(e)),n=r.f;return n?t.concat(n(e)):t}},function(e,t){},function(e,t){},function(e,t){},function(e,t,n){"use strict";function o(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=n(0),a=n(32),l=function(e){return e&&e.__esModule?e:{default:e}}(a),u=function(e){function t(e){o(this,t);var n=r(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.clone=n.makeClone(l.default.CLONE_DEBUG),n.clone.wtTable.holder.style.opacity=.4,n.clone.wtTable.holder.style.textShadow="0 0 2px #ff0000",(0,s.addClass)(n.clone.wtTable.holder.parentNode,"wtDebugVisible"),n}return i(t,e),t}(l.default);l.default.registerOverlay(l.default.CLONE_DEBUG,u),t.default=u},function(e,t){e.exports=function(e){return e.webpackPolyfill||(e.deprecate=function(){},e.paths=[],e.children||(e.children=[]),Object.defineProperty(e,"loaded",{enumerable:!0,get:function(){return e.l}}),Object.defineProperty(e,"id",{enumerable:!0,get:function(){return e.i}}),e.webpackPolyfill=1),e}},function(e,t,n){function o(e){return n(r(e))}function r(e){var t=i[e];if(!(t+1))throw Error("Cannot find module '"+e+"'.");return t}var i={"./af":162,"./af.js":162,"./ar":163,"./ar-dz":164,"./ar-dz.js":164,"./ar-kw":165,"./ar-kw.js":165,"./ar-ly":166,"./ar-ly.js":166,"./ar-ma":167,"./ar-ma.js":167,"./ar-sa":168,"./ar-sa.js":168,"./ar-tn":169,"./ar-tn.js":169,"./ar.js":163,"./az":170,"./az.js":170,"./be":171,"./be.js":171,"./bg":172,"./bg.js":172,"./bn":173,"./bn.js":173,"./bo":174,"./bo.js":174,"./br":175,"./br.js":175,"./bs":176,"./bs.js":176,"./ca":177,"./ca.js":177,"./cs":178,"./cs.js":178,"./cv":179,"./cv.js":179,"./cy":180,"./cy.js":180,"./da":181,"./da.js":181,"./de":182,"./de-at":183,"./de-at.js":183,"./de-ch":184,"./de-ch.js":184,"./de.js":182,"./dv":185,"./dv.js":185,"./el":186,"./el.js":186,"./en-au":187,"./en-au.js":187,"./en-ca":188,"./en-ca.js":188,"./en-gb":189,"./en-gb.js":189,"./en-ie":190,"./en-ie.js":190,"./en-nz":191,"./en-nz.js":191,"./eo":192,"./eo.js":192,"./es":193,"./es-do":194,"./es-do.js":194,"./es.js":193,"./et":195,"./et.js":195,"./eu":196,"./eu.js":196,"./fa":197,"./fa.js":197,"./fi":198,"./fi.js":198,"./fo":199,"./fo.js":199,"./fr":200,"./fr-ca":201,"./fr-ca.js":201,"./fr-ch":202,"./fr-ch.js":202,"./fr.js":200,"./fy":203,"./fy.js":203,"./gd":204,"./gd.js":204,"./gl":205,"./gl.js":205,"./gom-latn":206,"./gom-latn.js":206,"./he":207,"./he.js":207,"./hi":208,"./hi.js":208,"./hr":209,"./hr.js":209,"./hu":210,"./hu.js":210,"./hy-am":211,"./hy-am.js":211,"./id":212,"./id.js":212,"./is":213,"./is.js":213,"./it":214,"./it.js":214,"./ja":215,"./ja.js":215,"./jv":216,"./jv.js":216,"./ka":217,"./ka.js":217,"./kk":218,"./kk.js":218,"./km":219,"./km.js":219,"./kn":220,"./kn.js":220,"./ko":221,"./ko.js":221,"./ky":222,"./ky.js":222,"./lb":223,"./lb.js":223,"./lo":224,"./lo.js":224,"./lt":225,"./lt.js":225,"./lv":226,"./lv.js":226,"./me":227,"./me.js":227,"./mi":228,"./mi.js":228,"./mk":229,"./mk.js":229,"./ml":230,"./ml.js":230,"./mr":231,"./mr.js":231,"./ms":232,"./ms-my":233,"./ms-my.js":233,"./ms.js":232,"./my":234,"./my.js":234,"./nb":235,"./nb.js":235,"./ne":236,"./ne.js":236,"./nl":237,"./nl-be":238,"./nl-be.js":238,"./nl.js":237,"./nn":239,"./nn.js":239,"./pa-in":240,"./pa-in.js":240,"./pl":241,"./pl.js":241,"./pt":242,"./pt-br":243,"./pt-br.js":243,"./pt.js":242,"./ro":244,"./ro.js":244,"./ru":245,"./ru.js":245,"./sd":246,"./sd.js":246,"./se":247,"./se.js":247,"./si":248,"./si.js":248,"./sk":249,"./sk.js":249,"./sl":250,"./sl.js":250,"./sq":251,"./sq.js":251,"./sr":252,"./sr-cyrl":253,"./sr-cyrl.js":253,"./sr.js":252,"./ss":254,"./ss.js":254,"./sv":255,"./sv.js":255,"./sw":256,"./sw.js":256,"./ta":257,"./ta.js":257,"./te":258,"./te.js":258,"./tet":259,"./tet.js":259,"./th":260,"./th.js":260,"./tl-ph":261,"./tl-ph.js":261,"./tlh":262,"./tlh.js":262,"./tr":263,"./tr.js":263,"./tzl":264,"./tzl.js":264,"./tzm":265,"./tzm-latn":266,"./tzm-latn.js":266,"./tzm.js":265,"./uk":267,"./uk.js":267,"./ur":268,"./ur.js":268,"./uz":269,"./uz-latn":270,"./uz-latn.js":270,"./uz.js":269,"./vi":271,"./vi.js":271,"./x-pseudo":272,"./x-pseudo.js":272,"./yo":273,"./yo.js":273,"./zh-cn":274,"./zh-cn.js":274,"./zh-hk":275,"./zh-hk.js":275,"./zh-tw":276,"./zh-tw.js":276};o.keys=function(){return Object.keys(i)},o.resolve=r,e.exports=o,o.id=326},function(e,t,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),a=n(0),l=n(32),u=function(e){return e&&e.__esModule?e:{default:e}}(l),c=function(e){function t(e){o(this,t);var n=r(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.clone=n.makeClone(u.default.CLONE_LEFT),n}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,n=this.wot.getSetting("preventOverflow");if(this.trimmingContainer!==window||n&&"horizontal"===n)t=this.getScrollPosition(),(0,a.resetCssTransform)(e);else{var o=this.wot.wtTable.hider.getBoundingClientRect(),r=Math.ceil(o.left),i=Math.ceil(o.right),s=void 0,l=void 0;l=this.wot.wtTable.hider.style.top,l=""===l?0:l,s=0>r&&i-e.offsetWidth>0?-r:0,t=s,s+="px",(0,a.setOverlayPosition)(e,s,l)}this.adjustHeaderBordersPosition(t),this.adjustElementsSize()}}},{key:"setScrollPosition",value:function(e){this.mainTableScrollableElement===window?window.scrollTo(e,(0,a.getWindowScrollTop)()):this.mainTableScrollableElement.scrollLeft=e}},{key:"onScroll",value:function(){this.wot.getSetting("onScrollVertically")}},{key:"sumCellSizes",value:function(e,t){for(var n=0,o=this.wot.wtSettings.defaultColumnWidth;t>e;)n+=this.wot.wtTable.getStretchedColumnWidth(e)||o,e++;return n}},{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,a.getScrollbarWidth)(),n=this.clone.wtTable.holder.parentNode,o=n.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,a.innerHeight)(this.wot.wtTable.wtRootElement)),o.height=s+"px"}else o.height="";this.clone.wtTable.holder.style.height=o.height,i=(0,a.outerWidth)(this.clone.wtTable.TABLE),o.width=(0===i?i:i+4)+"px"}},{key:"adjustRootChildrenSize",value:function(){var e=(0,a.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 n=this.getTableParentOffset(),o=this.wot.cloneSource?this.wot.cloneSource:this.wot,r=o.wtTable.holder,i=0;t&&r.offsetWidth!==r.clientWidth&&(i=(0,a.getScrollbarWidth)()),t?(n+=this.sumCellSizes(0,e+1),n-=this.wot.wtViewport.getViewportWidth()):n+=this.sumCellSizes(this.wot.getSetting("fixedColumnsLeft"),e),n+=i,this.setScrollPosition(n)}},{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,a.getScrollLeft)(this.mainTableScrollableElement)}},{key:"adjustHeaderBordersPosition",value:function(e){var t=this.wot.wtTable.holder.parentNode,n=this.wot.getSetting("rowHeaders"),o=this.wot.getSetting("fixedColumnsLeft");if(this.wot.getSetting("totalRows")?(0,a.removeClass)(t,"emptyRows"):(0,a.addClass)(t,"emptyRows"),o&&!n.length)(0,a.addClass)(t,"innerBorderLeft");else if(!o&&n.length){var r=(0,a.hasClass)(t,"innerBorderLeft");e?(0,a.addClass)(t,"innerBorderLeft"):(0,a.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,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),a=n(0),l=n(32),u=function(e){return e&&e.__esModule?e:{default:e}}(l),c=function(e){function t(e){o(this,t);var n=r(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.clone=n.makeClone(u.default.CLONE_TOP),n}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,n=this.wot.getSetting("preventOverflow");if(this.trimmingContainer!==window||n&&"vertical"===n)t=this.getScrollPosition(),(0,a.resetCssTransform)(e);else{var o=this.wot.wtTable.hider.getBoundingClientRect(),r=Math.ceil(o.top),i=Math.ceil(o.bottom),s=void 0,l=void 0;s=this.wot.wtTable.hider.style.left,s=""===s?0:s,l=0>r&&i-e.offsetHeight>0?-r:0,t=l,l+="px",(0,a.setOverlayPosition)(e,s,l)}this.adjustHeaderBordersPosition(t),this.adjustElementsSize()}}},{key:"setScrollPosition",value:function(e){this.mainTableScrollableElement===window?window.scrollTo((0,a.getWindowScrollLeft)(),e):this.mainTableScrollableElement.scrollTop=e}},{key:"onScroll",value:function(){this.wot.getSetting("onScrollHorizontally")}},{key:"sumCellSizes",value:function(e,t){for(var n=0,o=this.wot.wtSettings.settings.defaultRowHeight;t>e;){var r=this.wot.wtTable.getRowHeight(e);n+=void 0===r?o:r,e++}return n}},{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,a.getScrollbarWidth)(),n=this.clone.wtTable.holder.parentNode,o=n.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,a.innerWidth)(this.wot.wtTable.wtRootElement)),o.width=s+"px"}else o.width="";this.clone.wtTable.holder.style.width=o.width,i=(0,a.outerHeight)(this.clone.wtTable.TABLE),o.height=(0===i?i:i+4)+"px"}},{key:"adjustRootChildrenSize",value:function(){var e=(0,a.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 n=this.getTableParentOffset(),o=this.wot.cloneSource?this.wot.cloneSource:this.wot,r=o.wtTable.holder,i=0;if(t&&r.offsetHeight!==r.clientHeight&&(i=(0,a.getScrollbarWidth)()),t){var s=this.wot.getSetting("fixedRowsBottom"),l=(this.wot.getSetting("fixedRowsTop"),this.wot.getSetting("totalRows"));n+=this.sumCellSizes(0,e+1),n-=this.wot.wtViewport.getViewportHeight()-this.sumCellSizes(l-s,l),n+=1}else n+=this.sumCellSizes(this.wot.getSetting("fixedRowsTop"),e);n+=i,this.setScrollPosition(n)}},{key:"getTableParentOffset",value:function(){return this.mainTableScrollableElement===window?this.wot.wtTable.holderOffset.top:0}},{key:"getScrollPosition",value:function(){return(0,a.getScrollTop)(this.mainTableScrollableElement)}},{key:"redrawSelectionBorders",value:function(e){if(e&&e.cellRange){var t=e.getBorder(this.wot);if(t){var n=e.getCorners();t.disappear(),t.appear(n)}}}},{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,a.removeClass)(t,"emptyColumns"):(0,a.addClass)(t,"emptyColumns"),0===this.wot.getSetting("fixedRowsTop")&&this.wot.getSetting("columnHeaders").length>0){var n=(0,a.hasClass)(t,"innerBorderTop");e||0===this.wot.getSetting("totalRows")?(0,a.addClass)(t,"innerBorderTop"):(0,a.removeClass)(t,"innerBorderTop"),(!n&&e||n&&!e)&&(this.wot.wtOverlays.adjustElementsSize(),this.redrawAllSelectionsBorders())}if(0===this.wot.getSetting("rowHeaders").length){var o=this.clone.wtTable.THEAD.querySelectorAll("th:nth-of-type(2)");if(o)for(var r=0;o.length>r;r++)o[r].style["border-left-width"]=0}}}]),t}(u.default);u.default.registerOverlay(u.default.CLONE_TOP,c),t.default=c},function(e,t,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),a=n(0),l=n(32),u=function(e){return e&&e.__esModule?e:{default:e}}(l),c=function(e){function t(e){o(this,t);var n=r(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.clone=n.makeClone(u.default.CLONE_TOP_LEFT_CORNER),n}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,a.outerHeight)(this.clone.wtTable.TABLE),n=(0,a.outerWidth)(this.clone.wtTable.TABLE),o=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),l=Math.ceil(r.bottom),u=Math.ceil(r.right),c="0",h="0";o&&"vertical"!==o||0>s&&u-e.offsetWidth>0&&(c=-s+"px"),o&&"horizontal"!==o||0>i&&l-e.offsetHeight>0&&(h=-i+"px"),(0,a.setOverlayPosition)(e,c,h)}else(0,a.resetCssTransform)(e);e.style.height=(0===t?t:t+4)+"px",e.style.width=(0===n?n:n+4)+"px"}}}]),t}(u.default);u.default.registerOverlay(u.default.CLONE_TOP_LEFT_CORNER,c),t.default=c},function(e,t,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),a=n(0),l=n(285),u=o(l),c=n(52),h=o(c),d=n(82),f=o(d);t.default=function(){function e(t,n){r(this,e),this.settings=t,this.cellRange=n||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,n,o){var r=e.wtTable.getCell(new h.default(t,n));"object"===(void 0===r?"undefined":i(r))&&(0,a.addClass)(r,o)}},{key:"draw",value:function(e){if(this.isEmpty()){if(this.settings.border){var t=this.getBorder(e);t&&t.disappear()}}else{for(var n=e.wtTable.getRenderedRowsCount(),o=e.wtTable.getRenderedColumnsCount(),r=this.getCorners(),i=void 0,s=void 0,l=void 0,u=0;o>u;u++)if((s=e.wtTable.columnFilter.renderedToSource(u))>=r[1]&&r[3]>=s&&(l=e.wtTable.getColumnHeader(s))){var c=[];this.settings.highlightHeaderClassName&&c.push(this.settings.highlightHeaderClassName),this.settings.highlightColumnClassName&&c.push(this.settings.highlightColumnClassName),(0,a.addClass)(l,c)}for(var h=0;n>h;h++){if((i=e.wtTable.rowFilter.renderedToSource(h))>=r[0]&&r[2]>=i&&(l=e.wtTable.getRowHeader(i))){var d=[];this.settings.highlightHeaderClassName&&d.push(this.settings.highlightHeaderClassName),this.settings.highlightRowClassName&&d.push(this.settings.highlightRowClassName),(0,a.addClass)(l,d)}for(var f=0;o>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,n){"use strict";function o(){function e(e){return e.currentStyle||document.defaultView.getComputedStyle(e)}var t,n={minHeight:200,maxHeight:300,minWidth:100,maxWidth:300},o=document.body,r=document.createTextNode(""),i=document.createElement("SPAN"),s=function(e,t,n){e.attachEvent?e.attachEvent("on"+t,n):e.addEventListener(t,n,!1)},a=function(e,t,n){e.removeEventListener?e.removeEventListener(t,n,!1):e.detachEvent("on"+t,n)},l=function(s){var a,l;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",o.appendChild(i),a=i.clientWidth+2,o.removeChild(i),t.style.height=n.minHeight+"px",t.style.width=n.minWidth>a?n.minWidth+"px":a>n.maxWidth?n.maxWidth+"px":a+"px",l=t.scrollHeight?t.scrollHeight-1:0,n.minHeight>l?t.style.height=n.minHeight+"px":l>n.maxHeight?(t.style.height=n.maxHeight+"px",t.style.overflowY="visible"):t.style.height=l+"px"},u=function(){window.setTimeout(l,0)},c=function(e){if(e&&e.minHeight)if("inherit"==e.minHeight)n.minHeight=t.clientHeight;else{var o=parseInt(e.minHeight);isNaN(o)||(n.minHeight=o)}if(e&&e.maxHeight)if("inherit"==e.maxHeight)n.maxHeight=t.clientHeight;else{var s=parseInt(e.maxHeight);isNaN(s)||(n.maxHeight=s)}if(e&&e.minWidth)if("inherit"==e.minWidth)n.minWidth=t.clientWidth;else{var a=parseInt(e.minWidth);isNaN(a)||(n.minWidth=a)}if(e&&e.maxWidth)if("inherit"==e.maxWidth)n.maxWidth=t.clientWidth;else{var l=parseInt(e.maxWidth);isNaN(l)||(n.maxWidth=l)}i.firstChild||(i.className="autoResize",i.style.display="inline-block",i.appendChild(r))},h=function(e,o,r){t=e,c(o),"TEXTAREA"==t.nodeName&&(t.style.resize="none",t.style.overflowY="",t.style.height=n.minHeight+"px",t.style.minWidth=n.minWidth+"px",t.style.maxWidth=n.maxWidth+"px",t.style.overflowY="hidden"),r&&(s(t,"change",l),s(t,"cut",u),s(t,"paste",u),s(t,"drop",u),s(t,"keydown",u),s(t,"focus",l)),l()};return{init:function(e,t,n){h(e,t,n)},unObserve:function(){a(t,"change",l),a(t,"cut",u),a(t,"paste",u),a(t,"drop",u),a(t,"keydown",u),a(t,"focus",l)},resize:l}}e.exports=o},function(e,t,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),a=n(44),l=function(e){return e&&e.__esModule?e:{default:e}}(a),u=n(0);t.default=function(e){function t(){return o(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 n=this.TD.querySelector('input[type="checkbox"]');(0,u.hasClass)(n,"htBadValue")||n.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}(l.default)},function(e,t,n){"use strict";function o(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 a=function(){function e(e,t){for(var n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),l=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(o)},u=n(36),c=o(u),h=n(334),d=o(h);n(335);var f=n(0),p=n(1),g=n(4),v=o(g),m=n(20),y=n(11),w=n(53),C=o(w);t.default=function(e){function t(e){r(this,t);var n=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.defaultDateFormat="DD/MM/YYYY",n.isCellEdited=!1,n.parentDestroyed=!1,n}return s(t,e),a(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.");l(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(){l(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,n,o,r,i,s){this._opened=!1,l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"prepare",this).call(this,e,n,o,r,i,s)}},{key:"open",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;l(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)),l(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],n=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(e){var o=this.originalValue;void 0!==o&&this.setValue(o)}this.hideDatepicker(),l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"finishEditing",this).call(this,e,n)}},{key:"showDatepicker",value:function(e){this.$datePicker.config(this.getDatePickerConfig());var t=this.TD.getBoundingClientRect(),n=this.cellProperties.dateFormat||this.defaultDateFormat,o=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(){},o.format=n,this.originalValue?(r=this.originalValue,(0,c.default)(r,n,!0).isValid()&&this.$datePicker.setMoment((0,c.default)(r,n),!0),this.getValue()!==this.originalValue&&this.setValue(this.originalValue),s||i||this.setValue("")):this.cellProperties.defaultDate?(r=this.cellProperties.defaultDate,o.defaultDate=r,(0,c.default)(r,n,!0).isValid()&&this.$datePicker.setMoment((0,c.default)(r,n),!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,n={};this.cellProperties&&this.cellProperties.datePickerConfig&&(0,p.deepExtend)(n,this.cellProperties.datePickerConfig);var o=n.onSelect,r=n.onClose;return n.field=t,n.trigger=t,n.container=this.datePicker,n.bound=!1,n.format=n.format||this.defaultDateFormat,n.reposition=n.reposition||!1,n.onSelect=function(t){isNaN(t.getTime())||(t=(0,c.default)(t).format(e.cellProperties.dateFormat||e.defaultDateFormat)),e.setValue(t),e.hideDatepicker(),o&&o()},n.onClose=function(){e.parentDestroyed||e.finishEditing(!1),r&&r()},n}}]),t}(C.default)},function(e,t,n){/*!
* Pikaday
*
* Copyright © 2014 David Bushell | BSD & MIT license | https://github.com/dbushell/Pikaday
*/
!function(t,o){"use strict";var r;try{r=n(36)}catch(e){}e.exports=o(r)}(0,function(e){"use strict";var t="function"==typeof e,n=!!window.addEventListener,o=window.document,r=window.setTimeout,i=function(e,t,o,r){n?e.addEventListener(t,o,!!r):e.attachEvent("on"+t,o)},s=function(e,t,o,r){n?e.removeEventListener(t,o,!!r):e.detachEvent("on"+t,o)},a=function(e,t,n){var r;o.createEvent?(r=o.createEvent("HTMLEvents"),r.initEvent(t,!0,!1),r=w(r,n),e.dispatchEvent(r)):o.createEventObject&&(r=o.createEventObject(),r=w(r,n),e.fireEvent("on"+t,r))},l=function(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")},u=function(e,t){return-1!==(" "+e.className+" ").indexOf(" "+t+" ")},c=function(e,t){u(e,t)||(e.className=""===e.className?t:e.className+" "+t)},h=function(e,t){e.className=l((" "+e.className+" ").replace(" "+t+" "," "))},d=function(e){return/Array/.test(Object.prototype.toString.call(e))},f=function(e){return/Date/.test(Object.prototype.toString.call(e))&&!isNaN(e.getTime())},p=function(e){var t=e.getDay();return 0===t||6===t},g=function(e){return e%4==0&&e%100!=0||e%400==0},v=function(e,t){return[31,g(e)?29:28,31,30,31,30,31,31,30,31,30,31][t]},m=function(e){f(e)&&e.setHours(0,0,0,0)},y=function(e,t){return e.getTime()===t.getTime()},w=function(e,t,n){var o,r;for(o in t)r=void 0!==e[o],r&&"object"==typeof t[o]&&null!==t[o]&&void 0===t[o].nodeName?f(t[o])?n&&(e[o]=new Date(t[o].getTime())):d(t[o])?n&&(e[o]=t[o].slice(0)):e[o]=w({},t[o],n):!n&&r||(e[o]=t[o]);return e},C=function(e){return 0>e.month&&(e.year-=Math.ceil(Math.abs(e.month)/12),e.month+=12),e.month>11&&(e.year+=Math.floor(Math.abs(e.month)/12),e.month-=12),e},b={field:null,bound:void 0,position:"bottom left",reposition:!0,format:"YYYY-MM-DD",defaultDate:null,setDefaultDate:!1,firstDay:0,formatStrict:!1,minDate:null,maxDate:null,yearRange:10,showWeekNumber:!1,minYear:0,maxYear:9999,minMonth:void 0,maxMonth:void 0,startRange:null,endRange:null,isRTL:!1,yearSuffix:"",showMonthAfterYear:!1,showDaysInNextAndPreviousMonths:!1,numberOfMonths:1,mainCalendar:"left",container:void 0,i18n:{previousMonth:"Previous Month",nextMonth:"Next Month",months:["January","February","March","April","May","June","July","August","September","October","November","December"],weekdays:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],weekdaysShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"]},theme:null,onSelect:null,onOpen:null,onClose:null,onDraw:null},E=function(e,t,n){for(t+=e.firstDay;t>=7;)t-=7;return n?e.i18n.weekdaysShort[t]:e.i18n.weekdays[t]},_=function(e){var t=[],n="false";if(e.isEmpty){if(!e.showDaysInNextAndPreviousMonths)return'<td class="is-empty"></td>';t.push("is-outside-current-month")}return e.isDisabled&&t.push("is-disabled"),e.isToday&&t.push("is-today"),e.isSelected&&(t.push("is-selected"),n="true"),e.isInRange&&t.push("is-inrange"),e.isStartRange&&t.push("is-startrange"),e.isEndRange&&t.push("is-endrange"),'<td data-day="'+e.day+'" class="'+t.join(" ")+'" aria-selected="'+n+'"><button class="pika-button pika-day" type="button" data-pika-year="'+e.year+'" data-pika-month="'+e.month+'" data-pika-day="'+e.day+'">'+e.day+"</button></td>"},S=function(e,t,n){var o=new Date(n,0,1);return'<td class="pika-week">'+Math.ceil(((new Date(n,t,e)-o)/864e5+o.getDay()+1)/7)+"</td>"},O=function(e,t){return"<tr>"+(t?e.reverse():e).join("")+"</tr>"},T=function(e){return"<tbody>"+e.join("")+"</tbody>"},R=function(e){var t,n=[];for(e.showWeekNumber&&n.push("<th></th>"),t=0;7>t;t++)n.push('<th scope="col"><abbr title="'+E(e,t)+'">'+E(e,t,!0)+"</abbr></th>");return"<thead><tr>"+(e.isRTL?n.reverse():n).join("")+"</tr></thead>"},k=function(e,t,n,o,r,i){var s,a,l,u,c,h=e._o,f=n===h.minYear,p=n===h.maxYear,g='<div id="'+i+'" class="pika-title" role="heading" aria-live="assertive">',v=!0,m=!0;for(l=[],s=0;12>s;s++)l.push('<option value="'+(n===r?s-t:12+s-t)+'"'+(s===o?' selected="selected"':"")+(f&&h.minMonth>s||p&&s>h.maxMonth?'disabled="disabled"':"")+">"+h.i18n.months[s]+"</option>");for(u='<div class="pika-label">'+h.i18n.months[o]+'<select class="pika-select pika-select-month" tabindex="-1">'+l.join("")+"</select></div>",d(h.yearRange)?(s=h.yearRange[0],a=h.yearRange[1]+1):(s=n-h.yearRange,a=1+n+h.yearRange),l=[];a>s&&h.maxYear>=s;s++)h.minYear>s||l.push('<option value="'+s+'"'+(s===n?' selected="selected"':"")+">"+s+"</option>");return c='<div class="pika-label">'+n+h.yearSuffix+'<select class="pika-select pika-select-year" tabindex="-1">'+l.join("")+"</select></div>",g+=h.showMonthAfterYear?c+u:u+c,!f||0!==o&&o>h.minMonth||(v=!1),!p||11!==o&&h.maxMonth>o||(m=!1),0===t&&(g+='<button class="pika-prev'+(v?"":" is-disabled")+'" type="button">'+h.i18n.previousMonth+"</button>"),t===e._o.numberOfMonths-1&&(g+='<button class="pika-next'+(m?"":" is-disabled")+'" type="button">'+h.i18n.nextMonth+"</button>"),g+="</div>"},M=function(e,t,n){return'<table cellpadding="0" cellspacing="0" class="pika-table" role="grid" aria-labelledby="'+n+'">'+R(e)+T(t)+"</table>"},N=function(s){var a=this,l=a.config(s);a._onMouseDown=function(e){if(a._v){e=e||window.event;var t=e.target||e.srcElement;if(t)if(u(t,"is-disabled")||(!u(t,"pika-button")||u(t,"is-empty")||u(t.parentNode,"is-disabled")?u(t,"pika-prev")?a.prevMonth():u(t,"pika-next")&&a.nextMonth():(a.setDate(new Date(t.getAttribute("data-pika-year"),t.getAttribute("data-pika-month"),t.getAttribute("data-pika-day"))),l.bound&&r(function(){a.hide(),l.field&&l.field.blur()},100))),u(t,"pika-select"))a._c=!0;else{if(!e.preventDefault)return e.returnValue=!1,!1;e.preventDefault()}}},a._onChange=function(e){e=e||window.event;var t=e.target||e.srcElement;t&&(u(t,"pika-select-month")?a.gotoMonth(t.value):u(t,"pika-select-year")&&a.gotoYear(t.value))},a._onKeyChange=function(e){if(e=e||window.event,a.isVisible())switch(e.keyCode){case 13:case 27:l.field.blur();break;case 37:e.preventDefault(),a.adjustDate("subtract",1);break;case 38:a.adjustDate("subtract",7);break;case 39:a.adjustDate("add",1);break;case 40:a.adjustDate("add",7)}},a._onInputChange=function(n){var o;n.firedBy!==a&&(t?(o=e(l.field.value,l.format,l.formatStrict),o=o&&o.isValid()?o.toDate():null):o=new Date(Date.parse(l.field.value)),f(o)&&a.setDate(o),a._v||a.show())},a._onInputFocus=function(){a.show()},a._onInputClick=function(){a.show()},a._onInputBlur=function(){var e=o.activeElement;do{if(u(e,"pika-single"))return}while(e=e.parentNode);a._c||(a._b=r(function(){a.hide()},50)),a._c=!1},a._onClick=function(e){e=e||window.event;var t=e.target||e.srcElement,o=t;if(t){!n&&u(t,"pika-select")&&(t.onchange||(t.setAttribute("onchange","return;"),i(t,"change",a._onChange)));do{if(u(o,"pika-single")||o===l.trigger)return}while(o=o.parentNode);a._v&&t!==l.trigger&&o!==l.trigger&&a.hide()}},a.el=o.createElement("div"),a.el.className="pika-single"+(l.isRTL?" is-rtl":"")+(l.theme?" "+l.theme:""),i(a.el,"mousedown",a._onMouseDown,!0),i(a.el,"touchend",a._onMouseDown,!0),i(a.el,"change",a._onChange),i(o,"keydown",a._onKeyChange),l.field&&(l.container?l.container.appendChild(a.el):l.bound?o.body.appendChild(a.el):l.field.parentNode.insertBefore(a.el,l.field.nextSibling),i(l.field,"change",a._onInputChange),l.defaultDate||(l.defaultDate=t&&l.field.value?e(l.field.value,l.format).toDate():new Date(Date.parse(l.field.value)),l.setDefaultDate=!0));var c=l.defaultDate;f(c)?l.setDefaultDate?a.setDate(c,!0):a.gotoDate(c):a.gotoDate(new Date),l.bound?(this.hide(),a.el.className+=" is-bound",i(l.trigger,"click",a._onInputClick),i(l.trigger,"focus",a._onInputFocus),i(l.trigger,"blur",a._onInputBlur)):this.show()};return N.prototype={config:function(e){this._o||(this._o=w({},b,!0));var t=w(this._o,e,!0);t.isRTL=!!t.isRTL,t.field=t.field&&t.field.nodeName?t.field:null,t.theme="string"==typeof t.theme&&t.theme?t.theme:null,t.bound=!!(void 0!==t.bound?t.field&&t.bound:t.field),t.trigger=t.trigger&&t.trigger.nodeName?t.trigger:t.field,t.disableWeekends=!!t.disableWeekends,t.disableDayFn="function"==typeof t.disableDayFn?t.disableDayFn:null;var n=parseInt(t.numberOfMonths,10)||1;if(t.numberOfMonths=n>4?4:n,f(t.minDate)||(t.minDate=!1),f(t.maxDate)||(t.maxDate=!1),t.minDate&&t.maxDate&&t.minDate>t.maxDate&&(t.maxDate=t.minDate=!1),t.minDate&&this.setMinDate(t.minDate),t.maxDate&&this.setMaxDate(t.maxDate),d(t.yearRange)){var o=(new Date).getFullYear()-10;t.yearRange[0]=parseInt(t.yearRange[0],10)||o,t.yearRange[1]=parseInt(t.yearRange[1],10)||o}else(t.yearRange=Math.abs(parseInt(t.yearRange,10))||b.yearRange)>100&&(t.yearRange=100);return t},toString:function(n){return f(this._d)?t?e(this._d).format(n||this._o.format):this._d.toDateString():""},getMoment:function(){return t?e(this._d):null},setMoment:function(n,o){t&&e.isMoment(n)&&this.setDate(n.toDate(),o)},getDate:function(){return f(this._d)?new Date(this._d.getTime()):new Date},setDate:function(e,t){if(!e)return this._d=null,this._o.field&&(this._o.field.value="",a(this._o.field,"change",{firedBy:this})),this.draw();if("string"==typeof e&&(e=new Date(Date.parse(e))),f(e)){var n=this._o.minDate,o=this._o.maxDate;f(n)&&n>e?e=n:f(o)&&e>o&&(e=o),this._d=new Date(e.getTime()),m(this._d),this.gotoDate(this._d),this._o.field&&(this._o.field.value=""+this,a(this._o.field,"change",{firedBy:this})),t||"function"!=typeof this._o.onSelect||this._o.onSelect.call(this,this.getDate())}},gotoDate:function(e){var t=!0;if(f(e)){if(this.calendars){var n=new Date(this.calendars[0].year,this.calendars[0].month,1),o=new Date(this.calendars[this.calendars.length-1].year,this.calendars[this.calendars.length-1].month,1),r=e.getTime();o.setMonth(o.getMonth()+1),o.setDate(o.getDate()-1),t=r<n.getTime()||o.getTime()<r}t&&(this.calendars=[{month:e.getMonth(),year:e.getFullYear()}],"right"===this._o.mainCalendar&&(this.calendars[0].month+=1-this._o.numberOfMonths)),this.adjustCalendars()}},adjustDate:function(n,o){var r,i=this.getDate(),s=24*parseInt(o)*60*60*1e3;"add"===n?r=new Date(i.valueOf()+s):"subtract"===n&&(r=new Date(i.valueOf()-s)),t&&("add"===n?r=e(i).add(o,"days").toDate():"subtract"===n&&(r=e(i).subtract(o,"days").toDate())),this.setDate(r)},adjustCalendars:function(){this.calendars[0]=C(this.calendars[0]);for(var e=1;this._o.numberOfMonths>e;e++)this.calendars[e]=C({month:this.calendars[0].month+e,year:this.calendars[0].year});this.draw()},gotoToday:function(){this.gotoDate(new Date)},gotoMonth:function(e){isNaN(e)||(this.calendars[0].month=parseInt(e,10),this.adjustCalendars())},nextMonth:function(){this.calendars[0].month++,this.adjustCalendars()},prevMonth:function(){this.calendars[0].month--,this.adjustCalendars()},gotoYear:function(e){isNaN(e)||(this.calendars[0].year=parseInt(e,10),this.adjustCalendars())},setMinDate:function(e){e instanceof Date?(m(e),this._o.minDate=e,this._o.minYear=e.getFullYear(),this._o.minMonth=e.getMonth()):(this._o.minDate=b.minDate,this._o.minYear=b.minYear,this._o.minMonth=b.minMonth,this._o.startRange=b.startRange),this.draw()},setMaxDate:function(e){e instanceof Date?(m(e),this._o.maxDate=e,this._o.maxYear=e.getFullYear(),this._o.maxMonth=e.getMonth()):(this._o.maxDate=b.maxDate,this._o.maxYear=b.maxYear,this._o.maxMonth=b.maxMonth,this._o.endRange=b.endRange),this.draw()},setStartRange:function(e){this._o.startRange=e},setEndRange:function(e){this._o.endRange=e},draw:function(e){if(this._v||e){var t,n=this._o,o=n.minYear,i=n.maxYear,s=n.minMonth,a=n.maxMonth,l="";this._y>o||(this._y=o,!isNaN(s)&&s>this._m&&(this._m=s)),i>this._y||(this._y=i,!isNaN(a)&&this._m>a&&(this._m=a)),t="pika-title-"+Math.random().toString(36).replace(/[^a-z]+/g,"").substr(0,2);for(var u=0;n.numberOfMonths>u;u++)l+='<div class="pika-lendar">'+k(this,u,this.calendars[u].year,this.calendars[u].month,this.calendars[0].year,t)+this.render(this.calendars[u].year,this.calendars[u].month,t)+"</div>";this.el.innerHTML=l,n.bound&&"hidden"!==n.field.type&&r(function(){n.trigger.focus()},1),"function"==typeof this._o.onDraw&&this._o.onDraw(this),n.bound&&n.field.setAttribute("aria-label","Use the arrow keys to pick a date")}},adjustPosition:function(){var e,t,n,r,i,s,a,l,u,c;if(!this._o.container){if(this.el.style.position="absolute",e=this._o.trigger,t=e,n=this.el.offsetWidth,r=this.el.offsetHeight,i=window.innerWidth||o.documentElement.clientWidth,s=window.innerHeight||o.documentElement.clientHeight,a=window.pageYOffset||o.body.scrollTop||o.documentElement.scrollTop,"function"==typeof e.getBoundingClientRect)c=e.getBoundingClientRect(),l=c.left+window.pageXOffset,u=c.bottom+window.pageYOffset;else for(l=t.offsetLeft,u=t.offsetTop+t.offsetHeight;t=t.offsetParent;)l+=t.offsetLeft,u+=t.offsetTop;(this._o.reposition&&l+n>i||this._o.position.indexOf("right")>-1&&l-n+e.offsetWidth>0)&&(l=l-n+e.offsetWidth),(this._o.reposition&&u+r>s+a||this._o.position.indexOf("top")>-1&&u-r-e.offsetHeight>0)&&(u=u-r-e.offsetHeight),this.el.style.left=l+"px",this.el.style.top=u+"px"}},render:function(e,t,n){var o=this._o,r=new Date,i=v(e,t),s=new Date(e,t,1).getDay(),a=[],l=[];m(r),o.firstDay>0&&0>(s-=o.firstDay)&&(s+=7);for(var u=0===t?11:t-1,c=11===t?0:t+1,h=0===t?e-1:e,d=11===t?e+1:e,g=v(h,u),w=i+s,C=w;C>7;)C-=7;w+=7-C;for(var b=0,E=0;w>b;b++){var T=new Date(e,t,b-s+1),R=!!f(this._d)&&y(T,this._d),k=y(T,r),N=s>b||b>=i+s,D=b-s+1,A=t,H=e,P=o.startRange&&y(o.startRange,T),x=o.endRange&&y(o.endRange,T),L=o.startRange&&o.endRange&&T>o.startRange&&o.endRange>T,I=o.minDate&&o.minDate>T||o.maxDate&&T>o.maxDate||o.disableWeekends&&p(T)||o.disableDayFn&&o.disableDayFn(T);N&&(s>b?(D=g+D,A=u,H=h):(D-=i,A=c,H=d));l.push(_({day:D,month:A,year:H,isSelected:R,isToday:k,isDisabled:I,isEmpty:N,isStartRange:P,isEndRange:x,isInRange:L,showDaysInNextAndPreviousMonths:o.showDaysInNextAndPreviousMonths})),7==++E&&(o.showWeekNumber&&l.unshift(S(b-s,t,e)),a.push(O(l,o.isRTL)),l=[],E=0)}return M(o,a,n)},isVisible:function(){return this._v},show:function(){this.isVisible()||(h(this.el,"is-hidden"),this._v=!0,this.draw(),this._o.bound&&(i(o,"click",this._onClick),this.adjustPosition()),"function"==typeof this._o.onOpen&&this._o.onOpen.call(this))},hide:function(){var e=this._v;!1!==e&&(this._o.bound&&s(o,"click",this._onClick),this.el.style.position="static",this.el.style.left="auto",this.el.style.top="auto",c(this.el,"is-hidden"),this._v=!1,void 0!==e&&"function"==typeof this._o.onClose&&this._o.onClose.call(this))},destroy:function(){this.hide(),s(this.el,"mousedown",this._onMouseDown,!0),s(this.el,"touchend",this._onMouseDown,!0),s(this.el,"change",this._onChange),this._o.field&&(s(this._o.field,"change",this._onInputChange),this._o.bound&&(s(this._o.trigger,"click",this._onInputClick),s(this._o.trigger,"focus",this._onInputFocus),s(this._o.trigger,"blur",this._onInputBlur))),this.el.parentNode&&this.el.parentNode.removeChild(this.el)}},N})},function(e,t){},function(e,t,n){"use strict";function o(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 a=function(){function e(e,t){for(var n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),l=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(o)},u=n(286),c=o(u),h=n(8),d=o(h),f=function(e){function t(){return r(this,t),i(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return s(t,e),a(t,[{key:"prepare",value:function(e,n,o,r,i,s){l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"prepare",this).call(this,e,n,o,r,i,s),this.cellProperties.filter=!1,this.cellProperties.strict=!0}}]),t}(c.default);d.default.getSingleton().add("beforeValidate",function(e,t,n,o){var r=this.getCellMeta(t,this.propToCol(n));r.editor===f&&void 0===r.strict&&(r.filter=!1,r.strict=!0)}),t.default=f},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}t.__esModule=!0;var r=n(20),i=n(11),s=n(0),a=n(44),l=o(a),u=n(4),c=o(u),h=l.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,n=t.getActiveEditor();if(e.target===n.TEXTAREA&&!(0,i.isImmediatePropagationStopped)(e))switch(e.keyCode){case r.KEY_CODES.ENTER:n.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 n=this.instance.getSelected(),o=this.instance.getCell(n[0],n[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!==o){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),a=(0,s.offset)(o),l=(0,s.outerWidth)(o),u={x:r,y:i};this.editorContainer.style.top=parseInt(a.top+(0,s.outerHeight)(o)-u.y+d.cellPointer.height,10)+"px",this.editorContainer.style.left=parseInt(window.innerWidth/2-d.editorContainer.width/2,10)+"px",a.left+l/2>parseInt(this.editorContainer.style.left,10)+d.editorContainer.width?this.editorContainer.style.left=window.innerWidth-d.editorContainer.width+"px":a.left+l/2<parseInt(this.editorContainer.style.left,10)+20&&(this.editorContainer.style.left="0px"),this.cellPointer.style.left=parseInt(a.left-d.cellPointer.width/2-(0,s.offset)(this.editorContainer).left+l/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 n=t.touches[0],o={x:e.editorContainer.offsetLeft,y:e.editorContainer.offsetTop},r={x:n.pageX-o.x,y:n.pageY-o.y};e.eventManager.addEventListener(this,"touchmove",function(t){var n=t.touches[0];e.updateEditorPosition(n.pageX-r.x,n.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,n){"use strict";function o(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 a=function(){function e(e,t){for(var n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),l=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(o)},u=n(65),c=o(u),h=n(53),d=o(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),a(t,[{key:"beginEditing",value:function(e){if(void 0===e&&this.originalValue){var n=c.default.cultureData().delimiters.decimal,o=this.cellProperties.numericFormat,r=o&&o.culture;void 0!==r&&c.default.culture(r),e=(""+this.originalValue).replace(".",n)}l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"beginEditing",this).call(this,e)}}]),t}(d.default)},function(e,t){},function(e,t,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),a=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(o)},l=n(0),u=n(53),c=function(e){return e&&e.__esModule?e:{default:e}}(u);t.default=function(e){function t(){return o(this,t),r(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return i(t,e),s(t,[{key:"createElements",value:function(){a(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,l.empty)(this.TEXTAREA_PARENT),this.TEXTAREA_PARENT.appendChild(this.TEXTAREA)}}]),t}(c.default)},function(e,t,n){"use strict";t.__esModule=!0;var o="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=n(0),i=n(11),s=n(20),a=n(44),l=function(e){return e&&e.__esModule?e:{default:e}}(a),u=l.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(){l.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 n in e)if(Object.prototype.hasOwnProperty.call(e,n)){var o=document.createElement("OPTION");o.value=n,(0,r.fastInnerHTML)(o,e[n]),this.select.appendChild(o)}},u.prototype.prepareOptions=function(e){var t={};if(Array.isArray(e))for(var n=0,r=e.length;r>n;n++)t[e[n]]=e[n];else"object"==(void 0===e?"undefined":o(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,n=t.getActiveEditor();switch(e.keyCode){case s.KEY_CODES.ARROW_UP:var o=n.select.selectedIndex-1;0>o||(n.select[o].selected=!0),(0,i.stopImmediatePropagation)(e),e.preventDefault();break;case s.KEY_CODES.ARROW_DOWN:var r=n.select.selectedIndex+1;r>n.select.length-1||(n.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===a.EditorState.EDITING){if(!(this.TD=this.getEditedCell()))return void this.close();var e,t=(0,r.outerWidth)(this.TD)+1,n=(0,r.outerHeight)(this.TD)+1,o=(0,r.offset)(this.TD),i=(0,r.offset)(this.instance.rootElement),s=(0,r.getScrollableElement)(this.TD),l=o.top-i.top-1-(s.scrollTop||0),u=o.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]&&(l+=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&&(n-=1),parseInt(d.borderLeftWidth,10)>0&&(t-=1),h.height=n+"px",h.minWidth=t+"px",h.top=l+"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,n){"use strict";function o(e,t,n,o,i,s,a){a.className&&(t.className=t.className?t.className+" "+a.className:a.className),a.readOnly&&(0,r.addClass)(t,a.readOnlyCellClassName),!1===a.valid&&a.invalidCellClassName?(0,r.addClass)(t,a.invalidCellClassName):(0,r.removeClass)(t,a.invalidCellClassName),!1===a.wordWrap&&a.noWordWrapClassName&&(0,r.addClass)(t,a.noWordWrapClassName),!s&&a.placeholder&&(0,r.addClass)(t,a.placeholderCellClassName)}t.__esModule=!0;var r=n(0);t.default=o},function(e,t,n){"use strict";function o(e,t,n,o,i,h,d){var f=(u.cloneNode(!0),c.cloneNode(!0));if(d.allowHtml?(0,l.getRenderer)("html").apply(this,arguments):(0,l.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 a.CellCoords(n,o),t)},p.addEventListener(e.rootElement,"mousedown",e.acArrowListener),e.addHookOnce("afterDestroy",function(){p.destroy()})}}t.__esModule=!0;var r=n(0),i=n(4),s=function(e){return e&&e.__esModule?e:{default:e}}(i),a=n(13),l=n(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=o},function(e,t,n){"use strict";function o(e,t,n,o,a,l,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],n=e.getSelectedRange();if(n){for(var o=n.getTopLeftCorner(),r=o.row,i=o.col,s=n.getBottomRightCorner(),a=s.row,l=s.col,u=[],c=r;a>=c;c+=1)for(var h=i;l>=h;h+=1){var d=e.getCellMeta(c,h);if("checkbox"!==d.type)return;if(!0!==d.readOnly){void 0===d.checkedTemplate&&(d.checkedTemplate=!0),void 0===d.uncheckedTemplate&&(d.uncheckedTemplate=!1);var f=e.getDataAtCell(c,h);!1===t?[d.checkedTemplate,""+d.checkedTemplate].includes(f)?u.push([c,h,d.uncheckedTemplate]):[d.uncheckedTemplate,""+d.uncheckedTemplate,null,void 0].includes(f)&&u.push([c,h,d.checkedTemplate]):u.push([c,h,d.uncheckedTemplate])}}u.length>0&&e.setDataAtCell(u)}}function p(t){var n=e.getSelectedRange();if(n)for(var o=n.getTopLeftCorner(),r=n.getBottomRightCorner(),i=o.row;r.row>=i;i++)for(var s=o.col;r.col>=s;s++){var a=e.getCellMeta(i,s);if("checkbox"!==a.type)return;var l=e.getCell(i,s);if(null==l)t(i,s,a);else{var u=l.querySelectorAll("input[type=checkbox]");u.length>0&&!a.readOnly&&t(u)}}}(0,y.getRenderer)("base").apply(this,arguments);var C=(r(e),i()),E=u.label,_=!1;if(void 0===u.checkedTemplate&&(u.checkedTemplate=!0),void 0===u.uncheckedTemplate&&(u.uncheckedTemplate=!1),(0,h.empty)(t),l===u.checkedTemplate||(0,d.equalsIgnoreCase)(l,u.checkedTemplate)?C.checked=!0:l===u.uncheckedTemplate||(0,d.equalsIgnoreCase)(l,u.uncheckedTemplate)?C.checked=!1:null===l?(0,h.addClass)(C,"noValue"):(C.style.display="none",(0,h.addClass)(C,b),_=!0),C.setAttribute("data-row",n),C.setAttribute("data-col",o),!_&&E){var S="";E.value?S="function"==typeof E.value?E.value.call(this,n,o,a,l):E.value:E.property&&(S=e.getDataAtRowProp(n,E.property));var O=s(S);"before"===E.position?O.appendChild(C):O.insertBefore(C,O.firstChild),C=O}t.appendChild(C),_&&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 l(t,e)}),t.addEventListener(e.rootElement,"mouseup",function(t){return a(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 a(e,t){c(e.target)&&setTimeout(t.listen,10)}function l(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 n=parseInt(e.target.getAttribute("data-row"),10),o=parseInt(e.target.getAttribute("data-col"),10),r=t.getCellMeta(n,o);if(!r.readOnly){var i=null;i=e.target.checked?void 0===r.uncheckedTemplate||r.checkedTemplate:void 0!==r.uncheckedTemplate&&r.uncheckedTemplate,t.setDataAtCell(n,o,i)}}function c(e){return"INPUT"===e.tagName&&"checkbox"===e.getAttribute("type")}t.__esModule=!0;var h=n(0),d=n(33),f=n(4),p=function(e){return e&&e.__esModule?e:{default:e}}(f),g=n(20),v=n(37),m=n(11),y=n(9),w=new WeakMap,C=new WeakMap,b="htBadValue";t.default=o},function(e,t,n){"use strict";function o(e,t,n,o,s,a,l){(0,i.getRenderer)("base").apply(this,arguments),null!==a&&void 0!==a||(a=""),(0,r.fastInnerHTML)(t,a)}t.__esModule=!0;var r=n(0),i=n(9);t.default=o},function(e,t,n){"use strict";function o(e,t,n,o,r,l,u){if((0,a.isNumeric)(l)){var c=u.numericFormat,h=c&&c.culture,d=c&&c.pattern,f=u.className||"",p=f.length?f.split(" "):[];void 0!==h&&i.default.culture(h),l=(0,i.default)(l).format(d||"0"),0>p.indexOf("htLeft")&&0>p.indexOf("htCenter")&&0>p.indexOf("htRight")&&0>p.indexOf("htJustify")&&p.push("htRight"),0>p.indexOf("htNumeric")&&p.push("htNumeric"),u.className=p.join(" ")}(0,s.getRenderer)("text")(e,t,n,o,r,l,u)}t.__esModule=!0;var r=n(65),i=function(e){return e&&e.__esModule?e:{default:e}}(r),s=n(9),a=n(5);t.default=o},function(e,t,n){"use strict";function o(e,t,n,o,a,l,u){(0,i.getRenderer)("text").apply(this,arguments),l=t.innerHTML;var c=u.hashLength||l.length,h=u.hashSymbol||"*",d="";(0,s.rangeEach)(c-1,function(){d+=h}),(0,r.fastInnerHTML)(t,d)}t.__esModule=!0;var r=n(0),i=n(9),s=n(5);t.default=o},function(e,t,n){"use strict";function o(e,t,n,o,a,l,u){(0,s.getRenderer)("base").apply(this,arguments),!l&&u.placeholder&&(l=u.placeholder);var c=(0,i.stringify)(l);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(n),t.appendChild(h)}else(0,r.fastInnerText)(t,c)}t.__esModule=!0;var r=n(0),i=n(17),s=n(9);t.default=o},function(e,t,n){"use strict";function o(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 n=e;return function(e){for(var o=!1,r=0,i=e.length;i>r;r++)if(n===e[r]){o=!0;break}t(o)}}t.__esModule=!0,t.default=o},function(e,t,n){"use strict";function o(e,t){var n=!0,o=(0,l.getEditorInstance)("date",this.instance);null==e&&(e="");var i=(0,s.default)(new Date(e)).isValid()||(0,s.default)(e,o.defaultDateFormat).isValid(),a=(0,s.default)(e,this.dateFormat||o.defaultDateFormat,!0).isValid();if(this.allowEmpty&&""===e&&(i=!0,a=!0),i||(n=!1),!i&&a&&(n=!0),i&&!a)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"),n=!0}else n=!1;t(n)}function r(e,t){var n=(0,s.default)((0,a.getNormalizedDate)(e)),o=(0,s.default)(e,t),r=e.search(/[A-z]/g)>-1,i=void 0;return i=n.isValid()&&n.format("x")===o.format("x")||!o.isValid()||r?n:o,i.format(t)}t.__esModule=!0,t.default=o,t.correctFormat=r;var i=n(36),s=function(e){return e&&e.__esModule?e:{default:e}}(i),a=n(288),l=n(16)},function(e,t,n){"use strict";function o(e,t){null==e&&(e=""),t(this.allowEmpty&&""===e?!0:""===e?!1:/^-?\d*(\.|,)?\d*$/.test(e))}t.__esModule=!0,t.default=o},function(e,t,n){"use strict";function o(e,t){var n=!0,o=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 a=(0,i.default)(e,s,!0).isValid()?(0,i.default)(e):(0,i.default)(e,o),l=a.isValid(),u=(0,i.default)(e,o,!0).isValid()&&!r;if(this.allowEmpty&&""===e&&(l=!0,u=!0),l||(n=!1),!l&&u&&(n=!0),l&&!u)if(!0===this.correctFormat){var c=a.format(o),h=this.instance.runHooks("unmodifyRow",this.row),d=this.instance.runHooks("unmodifyCol",this.col);this.instance.setDataAtCell(h,d,c,"timeValidator"),n=!0}else n=!1;t(n)}t.__esModule=!0,t.default=o;var r=n(36),i=function(e){return e&&e.__esModule?e:{default:e}}(r),s=["YYYY-MM-DDTHH:mm:ss.SSSZ","X","x"]},function(e,t,n){"use strict";t.__esModule=!0;var o=n(16),r=n(9),i=n(28);t.default={editor:(0,o.getEditor)("autocomplete"),renderer:(0,r.getRenderer)("autocomplete"),validator:(0,i.getValidator)("autocomplete")}},function(e,t,n){"use strict";t.__esModule=!0;var o=n(16),r=n(9);t.default={editor:(0,o.getEditor)("checkbox"),renderer:(0,r.getRenderer)("checkbox")}},function(e,t,n){"use strict";t.__esModule=!0;var o=n(16),r=n(9),i=n(28);t.default={editor:(0,o.getEditor)("date"),renderer:(0,r.getRenderer)("autocomplete"),validator:(0,i.getValidator)("date")}},function(e,t,n){"use strict";t.__esModule=!0;var o=n(16),r=n(9),i=n(28);t.default={editor:(0,o.getEditor)("dropdown"),renderer:(0,r.getRenderer)("autocomplete"),validator:(0,i.getValidator)("autocomplete")}},function(e,t,n){"use strict";t.__esModule=!0;var o=n(16),r=n(9);t.default={editor:(0,o.getEditor)("handsontable"),renderer:(0,r.getRenderer)("autocomplete")}},function(e,t,n){"use strict";t.__esModule=!0;var o=n(16),r=n(9),i=n(28);t.default={editor:(0,o.getEditor)("numeric"),renderer:(0,r.getRenderer)("numeric"),validator:(0,i.getValidator)("numeric"),dataType:"number"}},function(e,t,n){"use strict";t.__esModule=!0;var o=n(16),r=n(9);n(28);t.default={editor:(0,o.getEditor)("password"),renderer:(0,r.getRenderer)("password"),copyable:!1}},function(e,t,n){"use strict";t.__esModule=!0;var o=n(27),r=n(16),i=n(9);t.default={editor:(0,r.getEditor)((0,o.isMobileBrowser)()?"mobile":"text"),renderer:(0,i.getRenderer)("text")}},function(e,t,n){"use strict";t.__esModule=!0;var o=n(16),r=n(9),i=n(28);t.default={editor:(0,o.getEditor)("text"),renderer:(0,r.getRenderer)("text"),validator:(0,i.getValidator)("time")}},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}function r(e,t,n){var o=this;this.instance=e,this.priv=t,this.GridSettings=n,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 o.clearLengthCache()},"15fps"),this.instance.addHook("skipLengthCache",function(e){return o.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=n(289),a=o(s),l=n(86),u=n(85),c=n(1),h=n(2),d=n(363),f=o(d),p=n(5),g=n(364),v=o(g),m=n(8);o(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,n){var o,r;if(void 0===t&&(t=0,n=""),"object"===(void 0===e?"undefined":i(e))&&!Array.isArray(e))for(r in e)(0,c.hasOwnProperty)(e,r)&&(null===e[r]?(o=n+r,this.colToPropCache.push(o),this.propToColCache.set(o,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 n=this.instance.getSettings().columns;if(n){var o=this.instance.getSettings().maxCols,r=Math.min(o,n.length),i=0,s=!1,a=(0,c.deepObjectSize)(t);for("function"==typeof n&&(r=a>0?a:this.instance.countSourceCols(),s=!0),e=0;r>e;e++){var l=s?n(e):n[e];if((0,c.isObject)(l)){if(void 0!==l.data){var u=s?i:e;this.colToPropCache[u]=l.data,this.propToColCache.set(l.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,n){var o,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,n),r=e;for(var a=this.instance.getSettings().maxRows;t>s&&this.instance.countSourceRows()<a;)"array"===this.instance.dataType?this.instance.getSettings().dataSchema?o=(0,c.deepClone)(this.getSchema()):(o=[],(0,p.rangeEach)(i-1,function(){return o.push(null)})):"function"===this.instance.dataType?o=this.instance.getSettings().dataSchema(e):(o={},(0,c.deepExtend)(o,this.getSchema())),e===this.instance.countSourceRows()?this.dataSource.push(o):this.spliceData(e,0,o),s++,r++;return this.instance.runHooks("afterCreateRow",e,s,n),this.instance.forceFullRender=!0,s},r.prototype.createCol=function(e,t,n){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 o,r,i=this.instance.countSourceRows(),s=this.dataSource,a=0;t||(t=1),"number"==typeof e&&e<this.instance.countCols()||(e=this.instance.countCols()),this.instance.runHooks("beforeCreateCol",e,t,n),r=e;for(var l=this.instance.getSettings().maxCols;t>a&&this.instance.countCols()<l;){if(o=(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,o)}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(o)}a++,r++}return this.instance.runHooks("afterCreateCol",e,a,n),this.instance.forceFullRender=!0,a},r.prototype.removeRow=function(e,t,n){t||(t=1),"number"!=typeof e&&(e=-t),t=this.instance.runHooks("modifyRemovedAmount",t,e),e=(this.instance.countSourceRows()+e)%this.instance.countSourceRows();var o=this.visualRowsToPhysical(e,t);if(!1!==this.instance.runHooks("beforeRemoveRow",e,t,o,n)){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,o,n),this.instance.forceFullRender=!0}},r.prototype.removeCol=function(e,t,n){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 o=this.visualColumnsToPhysical(e,t),r=o.slice(0).sort(function(e,t){return t-e});if(!1!==this.instance.runHooks("beforeRemoveCol",e,t,o,n)){for(var i=!0,s=r.length,a=this.dataSource,l=0;s>l;l++)i&&o[0]!==o[l]-l&&(i=!1);if(i)for(var u=0,c=this.instance.countSourceRows();c>u;u++)a[u].splice(o[0],t);else{for(var h=0,d=this.instance.countSourceRows();d>h;h++)for(var f=0;s>f;f++)a[h].splice(r[f],1);for(var p=0;s>p;p++)this.priv.columnSettings.splice(o[p],1)}this.instance.runHooks("afterRemoveCol",e,t,o,n),this.instance.forceFullRender=!0}},r.prototype.spliceCol=function(e,t,n){var o=4>arguments.length?[]:[].slice.call(arguments,3),r=this.instance.getDataAtCol(e),i=r.slice(t,t+n),s=r.slice(t+n);(0,h.extendArray)(o,s);for(var a=0;n>a;)o.push(null),a++;return(0,h.to2dArray)(o),this.instance.populateFromArray(t,e,o,null,null,"spliceCol"),i},r.prototype.spliceRow=function(e,t,n){var o=4>arguments.length?[]:[].slice.call(arguments,3),r=this.instance.getSourceDataAtRow(e),i=r.slice(t,t+n),s=r.slice(t+n);(0,h.extendArray)(o,s);for(var a=0;n>a;)o.push(null),a++;return this.instance.populateFromArray(e,t,[o],null,null,"spliceRow"),i},r.prototype.spliceData=function(e,t,n){!1!==this.instance.runHooks("beforeDataSplice",e,t,n)&&this.dataSource.splice(e,t,n)},r.prototype.filterData=function(e,t){var n=this.visualRowsToPhysical(e,t);if(!1!==this.instance.runHooks("beforeDataFilter",e,t,n))return this.dataSource.filter(function(e,t){return-1==n.indexOf(t)})},r.prototype.get=function(e,t){e=this.instance.runHooks("modifyRow",e);var n=this.dataSource[e],o=this.instance.runHooks("modifyRowData",e);n=isNaN(o)?o:n;var r=null;if(n&&n.hasOwnProperty&&(0,c.hasOwnProperty)(n,t))r=n[t];else if("string"==typeof t&&t.indexOf(".")>-1){var i=t.split("."),s=n;if(!s)return null;for(var a=0,l=i.length;l>a;a++)if(void 0===(s=s[i[a]]))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,l.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,n,o){e=this.instance.runHooks("modifyRow",e,o||"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)(n);this.instance.runHooks("modifyData",e,this.propToCol(t),s,"set"),s.isTouched()&&(n=s.value)}if(r&&r.hasOwnProperty&&(0,c.hasOwnProperty)(r,t))r[t]=n;else if("string"==typeof t&&t.indexOf(".")>-1){var a=t.split("."),l=r,u=0,h=void 0;for(u=0,h=a.length-1;h>u;u++)void 0===l[a[u]]&&(l[a[u]]={}),l=l[a[u]];l[a[u]]=n}else"function"==typeof t?t(this.dataSource.slice(e,e+1)[0],n):r[t]=n},r.prototype.visualRowsToPhysical=function(e,t){for(var n,o=this.instance.countSourceRows(),r=(o+e)%o,i=[],s=t;o>r&&s;)n=this.instance.runHooks("modifyRow",r),i.push(n),s--,r++;return i},r.prototype.visualColumnsToPhysical=function(e,t){for(var n=this.instance.countCols(),o=(n+e)%n,r=[],i=t;n>o&&i;){r.push(this.instance.runHooks("modifyCol",o)),i--,o++}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,n=this.instance.getSettings().maxRows;t=0>n||0===n?0:n||1/0;var o=this.instance.countSourceRows();if(this.instance.hasHook("modifyRow")){var r=this.skipCache;this.interval.start(),o!==this.latestSourceRowsCount&&(r=!0),this.latestSourceRowsCount=o,null===this.cachedLength||r?((0,p.rangeEach)(o-1,function(t){null===(t=e.instance.runHooks("modifyRow",t))&&--o}),this.cachedLength=o):o=this.cachedLength}else this.interval.stop();return Math.min(o,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,n){var o,r,i,s,a,l=[],u=this.instance.getSettings().maxRows,c=this.instance.getSettings().maxCols;if(0===u||0===c)return[];var h=n===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)),o=Math.min(e.row,t.row);r>=o;o++){a=[];var d=this.instance.runHooks("modifyRow",o);for(i=Math.min(e.col,t.col);s>=i&&null!==d;i++)a.push(h.call(this,o,this.colToProp(i)));null!==d&&l.push(a)}return l},r.prototype.getText=function(e,t){return a.default.stringify(this.getRange(e,t,this.DESTINATION_RENDERER))},r.prototype.getCopyableText=function(e,t){return a.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,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}();t.parseDelay=r;var s=n(35);t.default=function(){function e(t,n){var i=this;o(this,e),this.timer=null,this.func=t,this.delay=r(n),this.stopped=!0,this._then=null,this._callback=function(){return i.__callback()}}return i(e,null,[{key:"create",value:function(t,n){return new e(t,n)}}]),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,n){"use strict";function o(){function e(e){return null!==e&&!n(e)&&("string"==typeof e||"number"==typeof e)}function t(e){return null!==e&&("object"==(void 0===e?"undefined":r(e))||"function"==typeof e)}function n(e){return e!==e}var o={arrayMap:[],weakMap:new WeakMap};return{get:function(n){return e(n)?o.arrayMap[n]:t(n)?o.weakMap.get(n):void 0},set:function(n,r){if(e(n))o.arrayMap[n]=r;else{if(!t(n))throw Error("Invalid key type");o.weakMap.set(n,r)}},delete:function(n){e(n)?delete o.arrayMap[n]:t(n)&&o.weakMap.delete(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};t.default=o},function(e,t,n){"use strict";function o(e,t,n){function o(e){n.setSelectedHeaders(!1,!1,!1);var o="function"==typeof t.settings.enterMoves?t.settings.enterMoves(event):t.settings.enterMoves;e?n.transformStart(-o.row,-o.col):n.transformStart(o.row,o.col,!0)}function l(e){e?(n.selectedHeader.cols&&n.setSelectedHeaders(n.selectedHeader.rows,!1,!1),n.transformEnd(-1,0)):(n.setSelectedHeaders(!1,!1,!1),n.transformStart(-1,0))}function h(e){e?n.transformEnd(1,0):(n.setSelectedHeaders(!1,!1,!1),n.transformStart(1,0))}function d(e){e?n.transformEnd(0,1):(n.setSelectedHeaders(!1,!1,!1),n.transformStart(0,1))}function f(e){e?(n.selectedHeader.rows&&n.setSelectedHeaders(!1,n.selectedHeader.cols,!1),n.transformEnd(0,-1)):(n.setSelectedHeaders(!1,!1,!1),n.transformStart(0,-1))}function p(a){var u,p;if(e.isListening()&&(e.runHooks("beforeKeyDown",a),!y&&!(0,s.isImmediatePropagationStopped)(a)&&(t.lastKeyCode=a.keyCode,n.isSelected()))){if(u=(a.ctrlKey||a.metaKey)&&!a.altKey,v&&!v.isWaiting()&&!((0,i.isMetaKey)(a.keyCode)||(0,i.isCtrlKey)(a.keyCode)||u||m.isEditorOpened()))return void m.openEditor("",a);switch(p=a.shiftKey?n.setRangeEnd:n.setRangeStart,a.keyCode){case i.KEY_CODES.A:!m.isEditorOpened()&&u&&(n.selectAll(),a.preventDefault(),(0,s.stopPropagation)(a));break;case i.KEY_CODES.ARROW_UP:m.isEditorOpened()&&!v.isWaiting()&&m.closeEditorAndSaveChanges(u),l(a.shiftKey),a.preventDefault(),(0,s.stopPropagation)(a);break;case i.KEY_CODES.ARROW_DOWN:m.isEditorOpened()&&!v.isWaiting()&&m.closeEditorAndSaveChanges(u),h(a.shiftKey),a.preventDefault(),(0,s.stopPropagation)(a);break;case i.KEY_CODES.ARROW_RIGHT:m.isEditorOpened()&&!v.isWaiting()&&m.closeEditorAndSaveChanges(u),d(a.shiftKey),a.preventDefault(),(0,s.stopPropagation)(a);break;case i.KEY_CODES.ARROW_LEFT:m.isEditorOpened()&&!v.isWaiting()&&m.closeEditorAndSaveChanges(u),f(a.shiftKey),a.preventDefault(),(0,s.stopPropagation)(a);break;case i.KEY_CODES.TAB:n.setSelectedHeaders(!1,!1,!1);var g="function"==typeof t.settings.tabMoves?t.settings.tabMoves(a):t.settings.tabMoves;a.shiftKey?n.transformStart(-g.row,-g.col):n.transformStart(g.row,g.col,!0),a.preventDefault(),(0,s.stopPropagation)(a);break;case i.KEY_CODES.BACKSPACE:case i.KEY_CODES.DELETE:n.empty(a),m.prepareEditor(),a.preventDefault();break;case i.KEY_CODES.F2:m.openEditor(null,a),v&&v.enableFullEditMode(),a.preventDefault();break;case i.KEY_CODES.ENTER:m.isEditorOpened()?(v&&v.state!==c.EditorState.WAITING&&m.closeEditorAndSaveChanges(u),o(a.shiftKey)):e.getSettings().enterBeginsEditing?(m.openEditor(null,a),v&&v.enableFullEditMode()):o(a.shiftKey),a.preventDefault(),(0,s.stopImmediatePropagation)(a);break;case i.KEY_CODES.ESCAPE:m.isEditorOpened()&&m.closeEditorAndRestoreOriginalValue(u),a.preventDefault();break;case i.KEY_CODES.HOME:n.setSelectedHeaders(!1,!1,!1),p(a.ctrlKey||a.metaKey?new r.CellCoords(0,t.selRange.from.col):new r.CellCoords(t.selRange.from.row,0)),a.preventDefault(),(0,s.stopPropagation)(a);break;case i.KEY_CODES.END:n.setSelectedHeaders(!1,!1,!1),p(a.ctrlKey||a.metaKey?new r.CellCoords(e.countRows()-1,t.selRange.from.col):new r.CellCoords(t.selRange.from.row,e.countCols()-1)),a.preventDefault(),(0,s.stopPropagation)(a);break;case i.KEY_CODES.PAGE_UP:n.setSelectedHeaders(!1,!1,!1),n.transformStart(-e.countVisibleRows(),0),a.preventDefault(),(0,s.stopPropagation)(a);break;case i.KEY_CODES.PAGE_DOWN:n.setSelectedHeaders(!1,!1,!1),n.transformStart(e.countVisibleRows(),0),a.preventDefault(),(0,s.stopPropagation)(a)}}}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 n,o,r,i,s,l,u;if(v&&v.isWaiting())return void this.closeEditor(!1,!1,function(e){e&&m.prepareEditor()});n=t.selRange.highlight.row,o=t.selRange.highlight.col,r=e.colToProp(o),i=e.getCell(n,o),s=e.getSourceDataAtCell(e.runHooks("modifyRow",n),o),l=e.getCellMeta(n,o),u=e.getCellEditor(l),u?(v=(0,a.getEditorInstance)(u,e),v.prepare(n,o,r,i,s,l)):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&&o()},this.closeEditor=function(e,t,n){v?v.finishEditing(e,t,n):n&&n(!1)},this.closeEditorAndSaveChanges=function(e){return this.closeEditor(!1,e)},this.closeEditorAndRestoreOriginalValue=function(e){return this.closeEditor(!0,e)},function(){function t(e,t,n){"TD"==n.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=n(13),i=n(20),s=n(11),a=n(16),l=n(4),u=function(e){return e&&e.__esModule?e:{default:e}}(l),c=n(44);t.default=o},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}function r(e){var t=this,n=this;this.eventManager=new u.default(e),this.instance=e,this.settings=e.getSettings(),this.selectionMouseDown=!1;var o=e.rootElement.getAttribute("style");o&&e.rootElement.setAttribute("data-originalstyle",o),(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,n.isTextSelectionAllowed(e.target)||(l(),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&&!n.isTextSelectionAllowed(e.target)&&(l(),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 o=t.target,r=t.target,a=t.x||t.clientX,l=t.y||t.clientY;if(!i&&e.rootElement){if(r===e.view.wt.wtTable.holder){var u=(0,s.getScrollbarWidth)();if(document.elementFromPoint(a+u,l)!==e.view.wt.wtTable.holder||document.elementFromPoint(a,l+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 n.settings.outsideClickDeselects?n.settings.outsideClickDeselects(o):n.settings.outsideClickDeselects)?e.deselectCell():e.destroyEditor()}}),this.eventManager.addEventListener(r,"selectstart",function(e){n.settings.fragmentSelection||(0,s.isInput)(e.target)||e.preventDefault()});var l=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 n.settings.fillHandle&&!n.isCellEdited()&&!e.selection.isMultiple()},multipleSelectionHandlesVisible:function(){return!n.isCellEdited()&&!e.selection.isMultiple()}}}),new h.Selection({className:"area",border:{width:1,color:"#89AFF9",cornerVisible:function(){return n.settings.fillHandle&&!n.isCellEdited()&&e.selection.isMultiple()},multipleSelectionHandlesVisible:function(){return!n.isCellEdited()&&e.selection.isMultiple()}}}),new h.Selection({className:"highlight",highlightHeaderClassName:n.settings.currentHeaderClassName,highlightRowClassName:n.settings.currentRowClassName,highlightColumnClassName:n.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 n.settings.debug},externalRowCalculator:this.instance.getPlugin("autoRowSize")&&this.instance.getPlugin("autoRowSize").isEnabled(),table:r,preventOverflow:function(){return t.settings.preventOverflow},stretchH:function(){return n.settings.stretchH},data:e.getDataAtCell,totalRows:function(){return e.countRows()},totalColumns:function(){return e.countCols()},fixedColumnsLeft:function(){return n.settings.fixedColumnsLeft},fixedRowsTop:function(){return n.settings.fixedRowsTop},fixedRowsBottom:function(){return n.settings.fixedRowsBottom},minSpareRows:function(){return n.settings.minSpareRows},renderAllRows:n.settings.renderAllRows,rowHeaders:function(){var t=[];return e.hasRowHeaders()&&t.push(function(e,t){n.appendRowHeader(e,t)}),e.runHooks("afterGetRowHeaderRenderers",t),t},columnHeaders:function(){var t=[];return e.hasColHeaders()&&t.push(function(e,t){n.appendColHeader(e,t)}),e.runHooks("afterGetColumnHeaderRenderers",t),t},columnWidth:e.getColWidth,rowHeight:e.getRowHeight,cellRenderer:function(e,t,o){var r=n.instance.getCellMeta(e,t),i=n.instance.colToProp(t),s=n.instance.getDataAtRowProp(e,i);n.instance.hasHook("beforeValueRender")&&(s=n.instance.runHooks("beforeValueRender",s)),n.instance.runHooks("beforeRenderer",o,e,t,i,s,r),n.instance.getCellRenderer(r)(n.instance,o,e,t,i,s,r),n.instance.runHooks("afterRenderer",o,e,t,i,s,r)},selections:f,hideBorderOnMouseDownOver:function(){return n.settings.fragmentSelection},onCellMouseDown:function(t,o,r,s){var a={row:!1,column:!1,cells:!1};if(e.listen(),n.activeWt=s,i=!0,e.runHooks("beforeOnCellMouseDown",t,o,r,a),!(0,c.isImmediatePropagationStopped)(t)){var l=e.getSelectedRange(),u=e.selection,d=u.selectedHeader;if(t.shiftKey&&l)0>o.row||0>o.col||a.cells?!d.cols&&!d.rows||0>o.row||0>o.col||a.cells?d.cols&&0>o.row&&!a.column?u.setRangeEnd(new h.CellCoords(l.to.row,o.col)):d.rows&&0>o.col&&!a.row?u.setRangeEnd(new h.CellCoords(o.row,l.to.col)):(!d.cols&&!d.rows&&0>o.col||d.cols&&0>o.col)&&!a.row?(u.setSelectedHeaders(!0,!1),u.setRangeStartOnly(new h.CellCoords(l.from.row,0)),u.setRangeEnd(new h.CellCoords(o.row,e.countCols()-1))):(!d.cols&&!d.rows&&0>o.row||d.rows&&0>o.row)&&!a.column&&(u.setSelectedHeaders(!1,!0),u.setRangeStartOnly(new h.CellCoords(0,l.from.col)),u.setRangeEnd(new h.CellCoords(e.countRows()-1,o.col))):(u.setSelectedHeaders(!1,!1),u.setRangeEnd(new h.CellCoords(o.row,o.col))):(u.setSelectedHeaders(!1,!1),u.setRangeEnd(o));else{var f=!0;if(l){var p=l.from,g=l.to,v=!u.inInSelection(o);if(0>o.row&&d.cols){var m=Math.min(p.col,g.col),y=Math.max(p.col,g.col);f=m>o.col||o.col>y}else if(0>o.col&&d.rows){var w=Math.min(p.row,g.row),C=Math.max(p.row,g.row);f=w>o.row||o.row>C}else f=v}var b=(0,c.isRightClick)(t),E=(0,c.isLeftClick)(t)||"touchstart"===t.type;o.row>=0||0>o.col||a.column?o.col>=0||0>o.row||a.row?0>o.col||0>o.row||a.cells?0>o.col&&0>o.row&&(o.row=0,o.col=0,u.setSelectedHeaders(!1,!1,!0),u.setRangeStart(o)):(E||b&&f)&&(u.setSelectedHeaders(!1,!1),u.setRangeStart(o)):(u.setSelectedHeaders(!0,!1),(E||b&&f)&&(u.setRangeStartOnly(new h.CellCoords(o.row,0)),u.setRangeEnd(new h.CellCoords(o.row,Math.max(e.countCols()-1,0)),!1))):(u.setSelectedHeaders(!1,!0),(E||b&&f)&&(u.setRangeStartOnly(new h.CellCoords(0,o.col)),u.setRangeEnd(new h.CellCoords(Math.max(e.countRows()-1,0),o.col),!1)))}e.runHooks("afterOnCellMouseDown",t,o,r),n.activeWt=n.wt}},onCellMouseOut:function(t,o,r,i){n.activeWt=i,e.runHooks("beforeOnCellMouseOut",t,o,r),(0,c.isImmediatePropagationStopped)(t)||(e.runHooks("afterOnCellMouseOut",t,o,r),n.activeWt=n.wt)},onCellMouseOver:function(t,o,r,s){var a={row:!1,column:!1,cell:!1};n.activeWt=s,e.runHooks("beforeOnCellMouseOver",t,o,r,a),(0,c.isImmediatePropagationStopped)(t)||(0===t.button&&i&&(e.selection.selectedHeader.cols&&!a.column?e.selection.setRangeEnd(new h.CellCoords(e.countRows()-1,o.col),!1):e.selection.selectedHeader.rows&&!a.row?e.selection.setRangeEnd(new h.CellCoords(o.row,e.countCols()-1),!1):a.cell||e.selection.setRangeEnd(o)),e.runHooks("afterOnCellMouseOver",t,o,r),n.activeWt=n.wt)},onCellMouseUp:function(t,o,r,i){n.activeWt=i,e.runHooks("beforeOnCellMouseUp",t,o,r),e.runHooks("afterOnCellMouseUp",t,o,r),n.activeWt=n.wt},onCellCornerMouseDown:function(t){t.preventDefault(),e.runHooks("afterOnCellCornerMouseDown",t)},onCellCornerDblClick:function(t){t.preventDefault(),e.runHooks("afterOnCellCornerDblClick",t)},beforeDraw:function(e,t){n.beforeRender(e,t)},onDraw:function(e){n.onDraw(e)},onScrollVertically:function(){e.runHooks("afterScrollVertically")},onScrollHorizontally:function(){e.runHooks("afterScrollHorizontally")},onBeforeDrawBorders:function(t,n){e.runHooks("beforeDrawBorders",t,n)},onBeforeTouchScroll:function(){e.runHooks("beforeTouchScroll")},onAfterMomentumScroll:function(){e.runHooks("afterMomentumScroll")},onBeforeStretchingColumnWidth:function(t,n){return e.runHooks("beforeStretchingColumnWidth",t,n)},onModifyRowHeaderWidth:function(t){return e.runHooks("modifyRowHeaderWidth",t)},viewportRowCalculatorOverride:function(t){var o=e.countRows(),r=n.settings.viewportRowRenderingOffset;if("auto"===r&&n.settings.fixedRowsTop&&(r=10),"number"==typeof r&&(t.startRow=Math.max(t.startRow-r,0),t.endRow=Math.min(t.endRow+r,o-1)),"auto"===r){var i=t.startRow+t.endRow-t.startRow,s=Math.ceil(i/o*12);t.startRow=Math.max(t.startRow-s,0),t.endRow=Math.min(t.endRow+s,o-1)}e.runHooks("afterViewportRowCalculatorOverride",t)},viewportColumnCalculatorOverride:function(t){var o=e.countCols(),r=n.settings.viewportColumnRenderingOffset;if("auto"===r&&n.settings.fixedColumnsLeft&&(r=10),"number"==typeof r&&(t.startColumn=Math.max(t.startColumn-r,0),t.endColumn=Math.min(t.endColumn+r,o-1)),"auto"===r){var i=t.startColumn+t.endColumn-t.startColumn,s=Math.ceil(i/o*12);t.startRow=Math.max(t.startColumn-s,0),t.endColumn=Math.min(t.endColumn+s,o-1)}e.runHooks("afterViewportColumnCalculatorOverride",t)},rowHeaderWidth:function(){return n.settings.rowHeaderWidth},columnHeaderHeight:function(){var t=e.runHooks("modifyColumnHeaderHeight");return n.settings.columnHeaderHeight||t}};e.runHooks("beforeInitWalkontable",p),this.wt=new d.default(p),this.activeWt=this.wt,(0,a.isChrome)()||(0,a.isSafari)()||this.eventManager.addEventListener(e.rootElement,"wheel",function(e){e.preventDefault();var t=parseInt((0,s.getComputedStyle)(document.body)["font-size"],10),o=n.wt.wtOverlays.scrollableElement,r=e.wheelDeltaY||e.deltaY,i=e.wheelDeltaX||e.deltaX;switch(e.deltaMode){case 0:o.scrollLeft+=i,o.scrollTop+=r;break;case 1:o.scrollLeft+=i*t,o.scrollTop+=r*t}}),this.eventManager.addEventListener(n.wt.wtTable.spreader,"mousedown",function(e){e.target===n.wt.wtTable.spreader&&3===e.which&&(0,c.stopPropagation)(e)}),this.eventManager.addEventListener(n.wt.wtTable.spreader,"contextmenu",function(e){e.target===n.wt.wtTable.spreader&&3===e.which&&(0,c.stopPropagation)(e)}),this.eventManager.addEventListener(document.documentElement,"click",function(){n.settings.observeDOMVisibility&&n.wt.drawInterrupted&&(n.instance.forceFullRender=!0,n.render())})}t.__esModule=!0;var i=function(){function e(e,t){var n=[],o=!0,r=!1,i=void 0;try{for(var s,a=e[Symbol.iterator]();!(o=(s=a.next()).done)&&(n.push(s.value),!t||n.length!==t);o=!0);}catch(e){r=!0,i=e}finally{try{!o&&a.return&&a.return()}finally{if(r)throw i}}return n}return function(t,n){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),s=n(0),a=n(27),l=n(4),u=o(l),c=n(11),h=n(13),d=o(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),n=t[0],o=t[1],r=t[2],s=t[3];return void 0!==n&&n===r&&o===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 n=this.wt.getCell(e,t);return 0>n?null:n},r.prototype.scrollViewport=function(e){this.wt.scrollViewport(e)},r.prototype.appendRowHeader=function(e,t){if(t.firstChild){var n=t.firstChild;if(!(0,s.hasClass)(n,"relative"))return(0,s.empty)(t),void this.appendRowHeader(e,t);this.updateCellHeader(n.querySelector(".rowHeader"),e,this.instance.getRowHeader)}else{var o=document.createElement("div"),r=document.createElement("span");o.className="relative",r.className="rowHeader",this.updateCellHeader(r,e,this.instance.getRowHeader),o.appendChild(r),t.appendChild(o)}this.instance.runHooks("afterGetRowHeader",e,t)},r.prototype.appendColHeader=function(e,t){if(t.firstChild){var n=t.firstChild;(0,s.hasClass)(n,"relative")?this.updateCellHeader(n.querySelector(".colHeader"),e,this.instance.getColHeader):((0,s.empty)(t),this.appendColHeader(e,t))}else{var o=document.createElement("div"),r=document.createElement("span");o.className="relative",r.className="colHeader",this.updateCellHeader(r,e,this.instance.getColHeader),o.appendChild(r),t.appendChild(o)}this.instance.runHooks("afterGetColHeader",e,t)},r.prototype.updateCellHeader=function(e,t,n){var o=t,r=this.wt.wtOverlays.getParentOverlay(e)||this.wt;e.parentNode&&((0,s.hasClass)(e,"colHeader")?o=r.wtTable.columnFilter.sourceToRendered(t):(0,s.hasClass)(e,"rowHeader")&&(o=r.wtTable.rowFilter.sourceToRendered(t))),o>-1?(0,s.fastInnerHTML)(e,n(t)):((0,s.fastInnerText)(e,String.fromCharCode(160)),(0,s.addClass)(e,"cornerHeader"))},r.prototype.maximumVisibleElementWidth=function(e){var t=this.wt.wtViewport.getWorkspaceWidth(),n=t-e;return n>0?n:0},r.prototype.maximumVisibleElementHeight=function(e){var t=this.wt.wtViewport.getWorkspaceHeight(),n=t-e;return n>0?n: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,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=n(1),s=n(2),a=n(5);t.default=function(){function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];o(this,e),this.hot=t,this.data=n,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,n=[];return(0,s.arrayEach)(this.data,function(o){var r=t.colToProp(e);o="string"==typeof r?(0,i.getProperty)(o,r):o[r],n.push(o)}),n}},{key:"getAtRow",value:function(e){return this.data[e]}},{key:"getAtCell",value:function(e,t){var n=null,o=this.hot.runHooks("modifyRowData",e),r=isNaN(o)?o:this.data[e];if(r){var s=this.colToProp(t);n="string"==typeof s?(0,i.getProperty)(r,s):"function"==typeof s?s(this.data.slice(e,e+1)[0]):r[s]}return n}},{key:"getByRange",value:function(e,t){var n=this,o=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),l=Math.max(e.col,t.col),u=[];return(0,a.rangeEach)(r,s,function(e){var t=n.getAtRow(e),r=void 0;"array"===n.dataType?r=t.slice(i,l+1):"object"===n.dataType&&(r=o?[]:{},(0,a.rangeEach)(i,l,function(e){var i=n.colToProp(e);o?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,n){"use strict";function o(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}t.__esModule=!0;var r,i=n(7),s=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}(i);t.default=(r={languageCode:"en-US"},o(r,s.CONTEXTMENU_ITEMS_ROW_ABOVE,"Insert row above"),o(r,s.CONTEXTMENU_ITEMS_ROW_BELOW,"Insert row below"),o(r,s.CONTEXTMENU_ITEMS_INSERT_LEFT,"Insert column left"),o(r,s.CONTEXTMENU_ITEMS_INSERT_RIGHT,"Insert column right"),o(r,s.CONTEXTMENU_ITEMS_REMOVE_ROW,["Remove row","Remove rows"]),o(r,s.CONTEXTMENU_ITEMS_REMOVE_COLUMN,["Remove column","Remove columns"]),o(r,s.CONTEXTMENU_ITEMS_UNDO,"Undo"),o(r,s.CONTEXTMENU_ITEMS_REDO,"Redo"),o(r,s.CONTEXTMENU_ITEMS_READ_ONLY,"Read only"),o(r,s.CONTEXTMENU_ITEMS_CLEAR_COLUMN,"Clear column"),o(r,s.CONTEXTMENU_ITEMS_ALIGNMENT,"Alignment"),o(r,s.CONTEXTMENU_ITEMS_ALIGNMENT_LEFT,"Left"),o(r,s.CONTEXTMENU_ITEMS_ALIGNMENT_CENTER,"Center"),o(r,s.CONTEXTMENU_ITEMS_ALIGNMENT_RIGHT,"Right"),o(r,s.CONTEXTMENU_ITEMS_ALIGNMENT_JUSTIFY,"Justify"),o(r,s.CONTEXTMENU_ITEMS_ALIGNMENT_TOP,"Top"),o(r,s.CONTEXTMENU_ITEMS_ALIGNMENT_MIDDLE,"Middle"),o(r,s.CONTEXTMENU_ITEMS_ALIGNMENT_BOTTOM,"Bottom"),o(r,s.CONTEXTMENU_ITEMS_FREEZE_COLUMN,"Freeze column"),o(r,s.CONTEXTMENU_ITEMS_UNFREEZE_COLUMN,"Unfreeze column"),o(r,s.CONTEXTMENU_ITEMS_BORDERS,"Borders"),o(r,s.CONTEXTMENU_ITEMS_BORDERS_TOP,"Top"),o(r,s.CONTEXTMENU_ITEMS_BORDERS_RIGHT,"Right"),o(r,s.CONTEXTMENU_ITEMS_BORDERS_BOTTOM,"Bottom"),o(r,s.CONTEXTMENU_ITEMS_BORDERS_LEFT,"Left"),o(r,s.CONTEXTMENU_ITEMS_REMOVE_BORDERS,"Remove border(s)"),o(r,s.CONTEXTMENU_ITEMS_ADD_COMMENT,"Add comment"),o(r,s.CONTEXTMENU_ITEMS_EDIT_COMMENT,"Edit comment"),o(r,s.CONTEXTMENU_ITEMS_REMOVE_COMMENT,"Delete comment"),o(r,s.CONTEXTMENU_ITEMS_READ_ONLY_COMMENT,"Read-only comment"),o(r,s.CONTEXTMENU_ITEMS_MERGE_CELLS,"Merge cells"),o(r,s.CONTEXTMENU_ITEMS_UNMERGE_CELLS,"Unmerge cells"),o(r,s.CONTEXTMENU_ITEMS_COPY,"Copy"),o(r,s.CONTEXTMENU_ITEMS_CUT,"Cut"),o(r,s.CONTEXTMENU_ITEMS_NESTED_ROWS_INSERT_CHILD,"Insert child row"),o(r,s.CONTEXTMENU_ITEMS_NESTED_ROWS_DETACH_CHILD,"Detach from parent"),o(r,s.CONTEXTMENU_ITEMS_HIDE_COLUMN,["Hide column","Hide columns"]),o(r,s.CONTEXTMENU_ITEMS_SHOW_COLUMN,["Show column","Show columns"]),o(r,s.CONTEXTMENU_ITEMS_HIDE_ROW,["Hide row","Hide rows"]),o(r,s.CONTEXTMENU_ITEMS_SHOW_ROW,["Show row","Show rows"]),o(r,s.FILTERS_CONDITIONS_NONE,"None"),o(r,s.FILTERS_CONDITIONS_EMPTY,"Is empty"),o(r,s.FILTERS_CONDITIONS_NOT_EMPTY,"Is not empty"),o(r,s.FILTERS_CONDITIONS_EQUAL,"Is equal to"),o(r,s.FILTERS_CONDITIONS_NOT_EQUAL,"Is not equal to"),o(r,s.FILTERS_CONDITIONS_BEGINS_WITH,"Begins with"),o(r,s.FILTERS_CONDITIONS_ENDS_WITH,"Ends with"),o(r,s.FILTERS_CONDITIONS_CONTAINS,"Contains"),o(r,s.FILTERS_CONDITIONS_NOT_CONTAIN,"Does not contain"),o(r,s.FILTERS_CONDITIONS_GREATER_THAN,"Greater than"),o(r,s.FILTERS_CONDITIONS_GREATER_THAN_OR_EQUAL,"Greater than or equal to"),o(r,s.FILTERS_CONDITIONS_LESS_THAN,"Less than"),o(r,s.FILTERS_CONDITIONS_LESS_THAN_OR_EQUAL,"Less than or equal to"),o(r,s.FILTERS_CONDITIONS_BETWEEN,"Is between"),o(r,s.FILTERS_CONDITIONS_NOT_BETWEEN,"Is not between"),o(r,s.FILTERS_CONDITIONS_AFTER,"After"),o(r,s.FILTERS_CONDITIONS_BEFORE,"Before"),o(r,s.FILTERS_CONDITIONS_TODAY,"Today"),o(r,s.FILTERS_CONDITIONS_TOMORROW,"Tomorrow"),o(r,s.FILTERS_CONDITIONS_YESTERDAY,"Yesterday"),o(r,s.FILTERS_VALUES_BLANK_CELLS,"Blank cells"),o(r,s.FILTERS_DIVS_FILTER_BY_CONDITION,"Filter by condition"),o(r,s.FILTERS_DIVS_FILTER_BY_VALUE,"Filter by value"),o(r,s.FILTERS_LABELS_CONJUNCTION,"And"),o(r,s.FILTERS_LABELS_DISJUNCTION,"Or"),o(r,s.FILTERS_BUTTONS_SELECT_ALL,"Select all"),o(r,s.FILTERS_BUTTONS_CLEAR,"Clear"),o(r,s.FILTERS_BUTTONS_OK,"OK"),o(r,s.FILTERS_BUTTONS_CANCEL,"Cancel"),o(r,s.FILTERS_BUTTONS_PLACEHOLDER_SEARCH,"Search"),o(r,s.FILTERS_BUTTONS_PLACEHOLDER_VALUE,"Value"),o(r,s.FILTERS_BUTTONS_PLACEHOLDER_SECOND_VALUE,"Second value"),r)},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}function r(e,t){h(e,t)}function i(){return d()}t.__esModule=!0,t.getPhraseFormatters=t.registerPhraseFormatter=void 0,t.register=r,t.getAll=i;var s=n(43),a=o(s),l=n(370),u=o(l),c=(0,a.default)("phraseFormatters"),h=c.register,d=c.getValues;t.registerPhraseFormatter=r,t.getPhraseFormatters=i,r("pluralize",u.default)},function(e,t,n){"use strict";function o(e,t){return Array.isArray(e)&&Number.isInteger(t)?e[t]:e}t.__esModule=!0,t.default=o},function(e,t,n){"use strict";function o(e){var t="undefined"!=typeof window&&window.jQuery;t&&(t.fn.handsontable=function(t){var n=this.first(),o=n.data("handsontable");if("string"!=typeof t){var r=t||{};return o?o.updateSettings(r):(o=new e.Core(n[0],r),n.data("handsontable",o),o.init()),n}var i=[],s=void 0;if(arguments.length>1)for(var a=1,l=arguments.length;l>a;a++)i.push(arguments[a]);if(o){if(void 0===o[t])throw Error("Handsontable do not provide action: "+t);s=o[t].apply(o,i),"destroy"===t&&n.removeData()}return s})}t.__esModule=!0,t.default=o},function(e,t,n){"use strict";function o(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=n(373),i=o(r),s=n(374),a=o(s),l=n(376),u=o(l),c=n(377),h=o(c),d=n(380),f=o(d),p=n(384),g=o(p),v=n(401),m=o(v),y=n(408),w=o(y),C=n(409),b=o(C),E=n(410),_=o(E),S=n(414),O=o(S),T=n(419),R=o(T),k=n(420),M=o(k),N=n(425),D=o(N),A=n(426),H=o(A),P=n(427),x=o(P),L=n(428),I=o(L),j=n(431),W=o(j),F=n(432),B=o(F),V=n(433),U=o(V),Y=n(434),z=o(Y),G=n(14),X=o(G);t.AutoColumnSize=i.default,t.AutoFill=a.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=_.default,t.ManualColumnMove=O.default,t.ManualColumnResize=R.default,t.ManualRowMove=M.default,t.ManualRowResize=D.default,t.MergeCells=H.default,t.MultipleSelectionHandles=x.default,t.ObserveChanges=I.default,t.PersistentState=W.default,t.Search=B.default,t.TouchScroll=U.default,t.UndoRedo=z.default,t.Base=X.default},function(e,t,n){"use strict";function o(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 a=function(){function e(e,t){var n=[],o=!0,r=!1,i=void 0;try{for(var s,a=e[Symbol.iterator]();!(o=(s=a.next()).done)&&(n.push(s.value),!t||n.length!==t);o=!0);}catch(e){r=!0,i=e}finally{try{!o&&a.return&&a.return()}finally{if(r)throw i}}return n}return function(t,n){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),l=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(o)},u=function(){function e(e,t){for(var n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),c=n(14),h=o(c),d=n(2),f=n(35),p=n(0),g=n(87),v=o(g),m=n(1),y=n(5),w=n(6),C=n(295),b=o(C),E=n(33),_=n(13),S=new WeakMap,O=function(e){function t(e){r(this,t);var n=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return S.set(n,{cachedColumnHeaders:[]}),n.widths=[],n.ghostTable=new v.default(n.hot),n.samplesGenerator=new b.default(function(e,t){return n.hot.getDataAtCell(e,t)}),n.firstCalculation=!0,n.inProgress=!1,n.addHook("beforeColumnResize",function(e,t,o){return n.onBeforeColumnResize(e,t,o)}),n}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 n=this.hot.getSettings().autoColumnSize;n&&null!=n.useHeaders&&this.ghostTable.setSetting("useHeaders",n.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,n){return e.getColumnWidth(n,t)}),this.addHook("afterInit",function(){return e.onAfterInit()}),l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this)}}},{key:"updatePlugin",value:function(){var e=this.findColumnsWhereHeaderWasChanged();e.length&&this.clearCache(e),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:"calculateColumnsWidth",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{from:0,to:this.hot.countCols()-1},t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{from:0,to:this.hot.countRows()-1},o=arguments.length>2&&void 0!==arguments[2]&&arguments[2];"number"==typeof e&&(e={from:e,to:e}),"number"==typeof n&&(n={from:n,to:n}),(0,y.rangeEach)(e.from,e.to,function(e){if(o||void 0===t.widths[e]&&!t.hot._getColWidthFromSettings(e)){t.samplesGenerator.generateColumnSamples(e,n).forEach(function(e,n){return t.ghostTable.addColumn(n,e)})}}),this.ghostTable.columns.length&&(this.ghostTable.getWidths(function(e,n){t.widths[e]=n}),this.ghostTable.clean())}},{key:"calculateAllColumnsWidth",value:function(){var e=this,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{from:0,to:this.hot.countRows()-1},o=0,r=this.hot.countCols()-1,i=null;this.inProgress=!0;this.firstCalculation&&this.getSyncCalculationLimit()&&(this.calculateColumnsWidth({from:0,to:this.getSyncCalculationLimit()},n),this.firstCalculation=!1,o=this.getSyncCalculationLimit()+1),r>o?function s(){if(!e.hot)return(0,f.cancelAnimationFrame)(i),void(e.inProgress=!1);e.calculateColumnsWidth({from:o,to:Math.min(o+t.CALCULATION_STEP,r)},n),o=o+t.CALCULATION_STEP+1,r>o?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,n=e&&(0,m.hasOwnProperty)(e,"allowSampleDuplicates")?this.hot.getSettings().autoColumnSize.allowSampleDuplicates:void 0;t&&!isNaN(t)&&this.samplesGenerator.setSampleCount(parseInt(t,10)),n&&this.samplesGenerator.setAllowDuplicates(n)}},{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,n=this.hot.countCols()-1;return(0,m.isObject)(this.hot.getSettings().autoColumnSize)&&(e=this.hot.getSettings().autoColumnSize.syncLimit,(0,E.isPercentValue)(e)?e=(0,y.valueAccordingPercent)(n,e):e>>=0),Math.min(e,n)}},{key:"getColumnWidth",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:void 0,n=2>=arguments.length||void 0===arguments[2]||arguments[2],o=t;return void 0===o&&(o=this.widths[e],n&&"number"==typeof o&&(o=Math.max(o,_.ViewportColumnsCalculator.DEFAULT_WIDTH))),o}},{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=S.get(this),n=t.cachedColumnHeaders;return(0,d.arrayReduce)(e,function(e,t,o){var r=n.length;return(o>r-1||n[o]!==t)&&e.push(o),o>r-1?n.push(t):n[o]=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 n=a(e,2);return t.hot.propToCol(n[1])}))}},{key:"onBeforeColumnResize",value:function(e,t,n){return n&&(this.calculateColumnsWidth(e,void 0,!0),t=this.getColumnWidth(e,void 0,!1)),t}},{key:"onAfterInit",value:function(){S.get(this).cachedColumnHeaders=this.hot.getColHeader()}},{key:"destroy",value:function(){this.ghostTable.clean(),l(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,n){"use strict";function o(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 a=function(){function e(e,t){for(var n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),l=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(o)},u=n(14),c=o(u),h=n(8),d=o(h),f=n(0),p=n(4),g=o(p),v=n(6),m=n(13),y=n(375);d.default.getSingleton().register("modifyAutofillRange"),d.default.getSingleton().register("beforeAutofill");var w=function(e){function t(e){r(this,t);var n=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.eventManager=new g.default(n),n.addingStarted=!1,n.mouseDownOnCellCorner=!1,n.mouseDragOutside=!1,n.handleDraggedCells=0,n.directions=[],n.autoInsertRow=!1,n}return s(t,e),a(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,n,o){return e.onBeforeCellMouseOver(n)}),l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{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.clearMappedSettings(),l(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(),n=(0,y.getDragDirectionAndRange)(t,e),o=n.directionOfDrag,r=n.startOfDragCoords,i=n.endOfDragCoords;if(this.hot.runHooks("modifyAutofillRange",t,e),r&&r.row>-1&&r.col>-1){var s=this.getSelectionData(),a=(0,y.getDeltas)(r,i,s,o),l=s;if(this.hot.runHooks("beforeAutofill",r,i,s),["up","left"].indexOf(o)>-1){l=[];var u=null,c=null;if("up"===o){u=i.row-r.row+1,c=u%s.length;for(var h=0;u>h;h++)l.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++){l.push([]);for(var f=0;u>f;f++)l[d].push(s[d][(f+(s[d].length-c))%s[d].length])}}}this.hot.populateFromArray(r.row,r.col,l,i.row,i.col,this.pluginName+".fill",null,o,a),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(),n=this.hot.getSelectedRange().getBottomRightCorner(),o=void 0;if(this.directions.includes(y.DIRECTIONS.vertical)&&(e.row>n.row||t.row>e.row))o=new m.CellCoords(e.row,n.col);else{if(!this.directions.includes(y.DIRECTIONS.horizontal))return;o=new m.CellCoords(n.row,e.col)}return this.reduceSelectionAreaIfNeeded(o)}},{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(),n=this.hot.countRows();n-1>e[2]&&t[2]===n-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(),n=this.hot.countRows(),o=void 0,r=e[2]+1;n>r;r++){for(var i=e[1];e[3]>=i;i++){if(t[r][i])return-1}var s=t[r][e[1]-1],a=t[r][e[3]+1];(s||a)&&(o=r)}return o}},{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),n=(0,f.offset)(this.hot.table).left-(window.pageXOffset||document.documentElement.scrollLeft)+(0,f.outerWidth)(this.hot.table);return e.clientY>t&&n>=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(){l(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,n){"use strict";function o(e,t,n,o){var r=n.length,i=n?n[0].length:0,s=[],a=t.row-e.row,l=t.col-e.col;if(-1!==["down","up"].indexOf(o)){for(var u=[],c=0;l>=c;c++){var h=parseInt(n[0][c],10),d=parseInt(n[r-1][c],10);u.push(("down"===o?d-h:h-d)/(r-1)||0)}s.push(u)}if(-1!==["right","left"].indexOf(o))for(var f=0;a>=f;f++){var p=parseInt(n[f][0],10),g=parseInt(n[f][i-1],10),v=("right"===o?g-p:p-g)/(i-1)||0;s.push([v])}return s}function r(e,t){var n=void 0,o=void 0,r=void 0;return t[0]===e[0]&&e[1]>t[1]?(r="left",n=new l.CellCoords(t[0],t[1]),o=new l.CellCoords(t[2],e[1]-1)):t[0]===e[0]&&t[3]>e[3]?(r="right",n=new l.CellCoords(t[0],e[3]+1),o=new l.CellCoords(t[2],t[3])):e[0]>t[0]&&t[1]===e[1]?(r="up",n=new l.CellCoords(t[0],t[1]),o=new l.CellCoords(e[0]-1,t[3])):t[2]>e[2]&&t[1]===e[1]&&(r="down",n=new l.CellCoords(e[2]+1,t[1]),o=new l.CellCoords(t[2],t[3])),{directionOfDrag:r,startOfDragCoords:n,endOfDragCoords:o}}function i(e){var t={};return!0===e?(t.directions=Object.keys(u),t.autoInsertRow=!0):(0,s.isObject)(e)?(t.autoInsertRow=!!(0,a.isDefined)(e.autoInsertRow)&&(e.direction!==u.horizontal&&e.autoInsertRow),t.directions=(0,a.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=o,t.getDragDirectionAndRange=r,t.getMappedFillHandleSetting=i;var s=n(1),a=n(17),l=n(13),u=t.DIRECTIONS={horizontal:"horizontal",vertical:"vertical"}},function(e,t,n){"use strict";function o(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 a=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(o)},l=function(){function e(e,t){for(var n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),u=n(14),c=o(u),h=n(2),d=n(35),f=n(0),p=n(87),g=o(p),v=n(1),m=n(5),y=n(6),w=n(295),C=o(w),b=n(33),E=function(e){function t(e){r(this,t);var n=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.heights=[],n.ghostTable=new g.default(n.hot),n.samplesGenerator=new C.default(function(e,t){return 0>e?-1===e?n.hot.getColHeader(t):null:n.hot.getDataAtCell(e,t)}),n.firstCalculation=!0,n.inProgress=!1,n.addHook("beforeRowResize",function(e,t,o){return n.onBeforeRowResize(e,t,o)}),n}return s(t,e),l(t,null,[{key:"CALCULATION_STEP",get:function(){return 50}},{key:"SYNC_CALCULATION_LIMIT",get:function(){return 500}}]),l(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,n){return e.onBeforeRowMove(t,n)}),this.addHook("modifyRowHeight",function(t,n){return e.getRowHeight(n,t)}),this.addHook("modifyColumnHeaderHeight",function(){return e.getColumnHeaderHeight()}),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{key:"disablePlugin",value:function(){a(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,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{from:0,to:this.hot.countCols()-1},o=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if("number"==typeof e&&(e={from:e,to:e}),"number"==typeof n&&(n={from:n,to:n}),null!==this.hot.getColHeader(0)){this.ghostTable.addColumnHeadersRow(this.samplesGenerator.generateRowSamples(-1,n).get(-1))}(0,m.rangeEach)(e.from,e.to,function(e){if(o||void 0===t.heights[e]){t.samplesGenerator.generateRowSamples(e,n).forEach(function(e,n){t.ghostTable.addRow(n,e)})}}),this.ghostTable.rows.length&&(this.ghostTable.getHeights(function(e,n){t.heights[e]=n}),this.ghostTable.clean())}},{key:"calculateAllRowsHeight",value:function(){var e=this,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{from:0,to:this.hot.countCols()-1},o=0,r=this.hot.countRows()-1,i=null;this.inProgress=!0;this.firstCalculation&&this.getSyncCalculationLimit()&&(this.calculateRowsHeight({from:0,to:this.getSyncCalculationLimit()},n),this.firstCalculation=!1,o=this.getSyncCalculationLimit()+1),r>o?function s(){if(!e.hot)return(0,d.cancelAnimationFrame)(i),void(e.inProgress=!1);e.calculateRowsHeight({from:o,to:Math.min(o+t.CALCULATION_STEP,r)},n),o=o+t.CALCULATION_STEP+1,r>o?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,n=e&&(0,v.hasOwnProperty)(e,"allowSampleDuplicates")?this.hot.getSettings().autoRowSize.allowSampleDuplicates:void 0;t&&!isNaN(t)&&this.samplesGenerator.setSampleCount(parseInt(t,10)),n&&this.samplesGenerator.setAllowDuplicates(n)}},{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,n=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)(n,e):e>>=0),Math.min(e,n)}},{key:"getRowHeight",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:void 0,n=t;return void 0!==this.heights[e]&&this.heights[e]>(t||0)&&(n=this.heights[e]),n}},{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 n=this.hot.countRows()-1;this.calculateRowsHeight({from:n-t,to:n})}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,n){return n&&(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(),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}}]),t}(c.default);(0,y.registerPlugin)("autoRowSize",E),t.default=E},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}function r(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);e.length>t;t++)n[t]=e[t];return n}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 a(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},u=function(){function e(e,t){for(var n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),c=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(o)},h=n(36),d=o(h),f=n(0),p=n(2),g=n(17),v=n(1),m=n(14),y=o(m),w=n(6),C=n(378),b=o(C),E=n(8),_=o(E);_.default.getSingleton().register("beforeColumnSort"),_.default.getSingleton().register("afterColumnSort");var S=function(e){function t(e){i(this,t);var n=s(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.sortIndicators=[],n.lastSortedColumn=null,n.sortEmptyCells=!1,n}return a(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 n=this;this.hot.sortIndex=[],this.hot.sort=function(){var e=Array.prototype.slice.call(arguments);return n.sortByColumn.apply(n,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,n){return e.getColHeader(t,n)}),this.addHook("afterOnCellMouseDown",function(t,n){return e.onAfterOnCellMouseDown(t,n)}),this.addHook("afterCreateRow",function(){n.afterCreateRow.apply(n,arguments)}),this.addHook("afterRemoveRow",function(){n.afterRemoveRow.apply(n,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(),n=void 0,o=void 0;void 0===t?(n=e.column,o=e.sortOrder):(n=t.sortColumn,o=t.sortOrder),"number"==typeof n&&(this.lastSortedColumn=n,this.sortByColumn(n,o))}},{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(n,o){return"string"==typeof n[1]&&(n[1]=n[1].toLowerCase()),"string"==typeof o[1]&&(o[1]=o[1].toLowerCase()),n[1]===o[1]?0:(0,g.isEmpty)(n[1])?(0,g.isEmpty)(o[1])?0:t.columnSorting.sortEmptyCells&&e?-1:1:(0,g.isEmpty)(o[1])?(0,g.isEmpty)(n[1])?0:t.columnSorting.sortEmptyCells&&e?1:-1:isNaN(n[1])&&!isNaN(o[1])?e?1:-1:!isNaN(n[1])&&isNaN(o[1])?e?-1:1:(isNaN(n[1])||isNaN(o[1])||(n[1]=parseFloat(n[1]),o[1]=parseFloat(o[1])),o[1]>n[1]?e?-1:1:n[1]>o[1]?e?1:-1:0)}}},{key:"dateSort",value:function(e,t){return function(n,o){if(n[1]===o[1])return 0;if((0,g.isEmpty)(n[1]))return(0,g.isEmpty)(o[1])?0:t.columnSorting.sortEmptyCells&&e?-1:1;if((0,g.isEmpty)(o[1]))return(0,g.isEmpty)(n[1])?0:t.columnSorting.sortEmptyCells&&e?1:-1;var r=(0,d.default)(n[1],t.dateFormat),i=(0,d.default)(o[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(n,o){var r=parseFloat(n[1]),i=parseFloat(o[1]);if(r===i||isNaN(r)&&isNaN(i))return 0;if(t.columnSorting.sortEmptyCells){if((0,g.isEmpty)(n[1]))return e?-1:1;if((0,g.isEmpty)(o[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(),n=void 0,o=void 0;this.hot.sortingEnabled=!1,this.hot.sortIndex.length=0,void 0===e.columnSorting.sortEmptyCells&&(e.columnSorting={sortEmptyCells:this.sortEmptyCells}),o=this.hot.getSettings().maxRows===Number.POSITIVE_INFINITY?this.hot.countRows()-this.hot.getSettings().minSpareRows:this.hot.countRows()-t;for(var r=0,i=o;i>r;r++)this.hot.sortIndex.push([r,this.hot.getDataAtCell(r,this.hot.sortColumn)]);if(e.sortFunction)n=e.sortFunction;else switch(e.type){case"date":n=this.dateSort;break;case"numeric":n=this.numericSort;break;default:n=this.defaultSort}(0,b.default)(this.hot.sortIndex,n(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 n=t.querySelector(".colHeader"),o=(t.getAttribute("colspan"),t.parentNode.parentNode.childNodes),r=Array.prototype.indexOf.call(o,t.parentNode);r-=o.length,n&&(this.hot.getSettings().columnSorting&&e>=0&&-1===r&&(0,f.addClass)(n,"columnSorting"),(0,f.removeClass)(n,"descending"),(0,f.removeClass)(n,"ascending"),this.sortIndicators[e]&&e===this.hot.sortColumn&&("ascending"===this.sortOrderClass?(0,f.addClass)(n,"ascending"):"descending"===this.sortOrderClass&&(0,f.addClass)(n,"descending")))}},{key:"isSorted",value:function(){return void 0!==this.hot.sortColumn}},{key:"afterCreateRow",value:function(e,t){if(this.isSorted()){for(var n=0;this.hot.sortIndex.length>n;n++)e>this.hot.sortIndex[n][0]||(this.hot.sortIndex[n][0]+=t);for(var o=0;t>o;o++)this.hot.sortIndex.splice(e+o,0,[e+o,this.hot.getSourceData()[e+o][this.hot.sortColumn+this.hot.colOffset()]]);this.saveSortingState()}}},{key:"afterRemoveRow",value:function(e,t){function n(e){return(0,p.arrayReduce)(o,function(t,n){return e>n&&t++,t},0)}if(this.isSorted()){var o=this.hot.sortIndex.splice(e,t);o=(0,p.arrayMap)(o,function(e){return e[0]}),this.hot.sortIndex=(0,p.arrayMap)(this.hot.sortIndex,function(e,t){var o=n(e[0]);return o&&(e[0]-=o),e}),this.saveSortingState()}}},{key:"setPluginOptions",value:function(){var e=this.hot.getSettings().columnSorting;this.sortEmptyCells="object"===(void 0===e?"undefined":l(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",S),t.default=S},function(e,t,n){"use strict";function o(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:a,n=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-n))return[];var s=Math.ceil((n+i)/2);return o(e,t,n,s),o(e,t,s,i),r(e,t,n,s,i)}function r(e,t,n,o,r){for(var i=new s.default,a=new s.default,l=o-n,u=r-o,c=Math.max(l,u),h=r-n,d=0;c>d;d+=1)l>d&&i.push(e[n+d]),u>d&&a.push(e[o+d]);for(var f=0;h>f;)e[n+f]=i.first&&a.first?t(i.first.data,a.first.data)>0?a.shift().data:i.shift().data:i.first?i.shift().data:a.shift().data,f+=1;return e}t.__esModule=!0,t.default=o,t.merge=r;var i=n(379),s=function(e){return e&&e.__esModule?e:{default:e}}(i),a=function(e,t){var n=""+e,o=""+t;return n===o?0:o>n?-1:1}},function(e,t,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=function e(t){o(this,e),this.data=t,this.next=null,this.prev=null},s=function(){function e(){o(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 n=this.last;this.last=t,t.prev=n,n.next=t}}},{key:"unshift",value:function(e){var t=new i(e);if(null===this.first)this.first=t,this.last=t;else{var n=this.first;this.first=t,t.next=n,n.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,n=void 0,o=void 0;t;){if(t.data===e)return n=t.next,o=t.prev,n&&(n.prev=o),o&&(o.next=n),t===this.first&&(this.first=n),t===this.last&&(this.last=o),!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,n){n&&(e(n,n.next),n.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,n=void 0;e;)n=e.next,e.next=t,t.prev=e,t=e,e=n;this.first.next=null,this.last.prev=null,n=this.first,this.first=t,this.last=n}}}]),e}();t.NodeStructure=i,t.default=s},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,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 a(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),u=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(o)},c=n(0),h=n(1),d=n(4),f=o(d),p=n(13),g=n(6),v=n(14),m=o(v),y=n(381),w=o(y),C=n(21),b=n(382),E=o(b),_=n(7),S=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}(_);n(383);var O=new WeakMap,T=function(e){function t(e){i(this,t);var n=s(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.editor=null,n.displaySwitch=null,n.eventManager=null,n.range={},n.mouseDown=!1,n.contextMenuEvent=!1,n.timer=null,O.set(n,{tempEditorDimensions:{},cellBelowCursor:null}),n}return a(t,e),l(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 E.default(this.getDisplayDelaySetting())),this.addHook("afterContextMenuDefaultOptions",function(t){return e.addToContextMenu(t)}),this.addHook("afterRenderer",function(t,n,o,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,n){return e.showAtCell(t,n)}),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(),n="";null!=e?n=e:null!=t&&(n=t),this.updateCommentMeta(this.range.from.row,this.range.from.col,r({},"value",n)),this.hot.render()}},{key:"setCommentAtCell",value:function(e,t,n){this.setRange({from:new p.CellCoords(e,t)}),this.setComment(n)}},{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 n=2>=arguments.length||void 0===arguments[2]||arguments[2];this.setRange({from:new p.CellCoords(e,t)}),this.removeComment(n)}},{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),n=this.range.from.row,o=this.range.from.col,r=(0,c.offset)(t),i=this.hot.view.wt.wtTable.getStretchedColumnWidth(o),s=0>r.top?0:r.top,a=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&&(a-=this.hot.view.wt.wtOverlays.leftOverlay.getScrollPosition());var l=a+i,u=s,h=this.getCommentMeta(n,o,"style"),d=this.getCommentMeta(n,o,"readOnly");h?this.editor.setSize(h.width,h.height):this.editor.resetSize(),this.editor.setReadOnlyState(d),this.editor.setPosition(l,u)}}},{key:"checkSelectionCommentsConsistency",value:function(){var e=this.hot.getSelectedRange();if(!e)return!1;var t=!1,n=e.from;return this.getCommentMeta(n.row,n.col,"value")&&(t=!0),t}},{key:"updateCommentMeta",value:function(e,t,n){var o=this.hot.getCellMeta(e,t).comment,r=void 0;o?(r=(0,h.deepClone)(o),(0,h.deepExtend)(r,n)):r=n,this.hot.setCellMeta(e,t,"comment",r)}},{key:"getCommentMeta",value:function(e,t,n){var o=this.hot.getCellMeta(e,t);if(o.comment)return o.comment[n]}},{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"),n=null;t&&(n=this.hot.view.wt.wtTable.getCoords(t)),(!t||this.range.from&&n&&(this.range.from.row!==n.row||this.range.from.col!==n.col))&&this.hide()}this.contextMenuEvent=!1}}},{key:"onMouseOver",value:function(e){var t=O.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 n=this.hot.view.wt.wtTable.getCoords(e.target),o={from:new p.CellCoords(n.row,n.col)};this.displaySwitch.show(o)}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){O.get(this).tempEditorDimensions={width:(0,c.outerWidth)(e.target),height:(0,c.outerHeight)(e.target)}}},{key:"onEditorMouseUp",value:function(e){var t=O.get(this),n=(0,c.outerWidth)(e.target),o=(0,c.outerHeight)(e.target);n===t.tempEditorDimensions.width+1&&o===t.tempEditorDimensions.height+2||this.updateCommentMeta(this.range.from.row,this.range.from.col,r({},"style",{width:n,height:o}))}},{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 n=e.start.col;e.end.col>=n;n++)this.removeCommentAtCell(t,n,!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 n=e.start.col;e.end.col>=n;n++){var o=!!this.getCommentMeta(t,n,"readOnly");this.updateCommentMeta(t,n,r({},"readOnly",!o))}}},{key:"addToContextMenu",value:function(e){var t=this;e.items.push({name:"---------"},{key:"commentsAddEdit",name:function(){return t.hot.getTranslatedPhrase(t.checkSelectionCommentsConsistency()?S.CONTEXTMENU_ITEMS_EDIT_COMMENT:S.CONTEXTMENU_ITEMS_ADD_COMMENT)},callback:function(){return t.onContextMenuAddComment()},disabled:function(){return!(this.getSelected()&&!this.selection.selectedHeader.corner)}},{key:"commentsRemove",name:function(){return this.getTranslatedPhrase(S.CONTEXTMENU_ITEMS_REMOVE_COMMENT)},callback:function(e,n){return t.onContextMenuRemoveComment(n)},disabled:function(){return t.hot.selection.selectedHeader.corner}},{key:"commentsReadOnly",name:function(){var e=this,t=this.getTranslatedPhrase(S.CONTEXTMENU_ITEMS_READ_ONLY_COMMENT);return(0,C.checkSelectionConsistency)(this.getSelectedRange(),function(t,n){var o=e.getCellMeta(t,n).comment;if(o&&(o=o.readOnly),o)return!0})&&(t=(0,C.markLabelAsSelected)(t)),t},callback:function(e,n){return t.onContextMenuMakeReadOnly(n)},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",T),t.default=T},function(e,t,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=n(0);t.default=function(){function e(){o(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 n=this.getInputElement();n.style.width=e+"px",n.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),n=void 0,o=void 0;return t||(t=document.createElement("div"),(0,i.addClass)(t,e.CLASS_EDITOR_CONTAINER),document.body.appendChild(t)),n=document.createElement("div"),(0,i.addClass)(n,e.CLASS_EDITOR),o=document.createElement("textarea"),(0,i.addClass)(o,e.CLASS_INPUT),n.appendChild(o),t.appendChild(n),n}},{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,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=n(37),s=n(1),a=n(89),l=function(e){return e&&e.__esModule?e:{default:e}}(a),u=function(){function e(t){o(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,l.default),t.default=u},function(e,t){},function(e,t,n){"use strict";function o(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 a=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(o)},l=function(){function e(e,t){for(var n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),u=n(14),c=o(u),h=n(8),d=o(h),f=n(2),p=n(385),g=o(p),v=n(4),m=o(v),y=n(386),w=o(y),C=n(398),b=o(C),E=n(6),_=n(11),S=n(0),O=n(90);n(400),d.default.getSingleton().register("afterContextMenuDefaultOptions"),d.default.getSingleton().register("afterContextMenuShow"),d.default.getSingleton().register("afterContextMenuHide"),d.default.getSingleton().register("afterContextMenuExecute");var T=function(e){function t(e){r(this,t);var n=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.eventManager=new m.default(n),n.commandExecutor=new g.default(n.hot),n.itemsFactory=null,n.menu=null,n}return s(t,e),l(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]}}]),l(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 n=this.hot.getSettings().contextMenu,o={items:this.itemsFactory.getItems(n)};this.registerEvents(),"function"==typeof n.callback&&this.commandExecutor.setCommonCallback(n.callback),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this);var r=function(){if(e.hot){e.hot.runHooks("afterContextMenuDefaultOptions",o),e.itemsFactory.setPredefinedItems(o.items);var t=e.itemsFactory.getItems(n);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,n=Array(t),o=0;t>o;o++)n[o]=arguments[o];return e.executeCommand.apply(e,n)}),(0,f.arrayEach)(t,function(t){return e.commandExecutor.registerCommand(t.key,t)})}};this.callOnPluginsReady(function(){e.isPluginsReady?setTimeout(r,0):r()})}}},{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.close(),this.menu&&(this.menu.destroy(),this.menu=null),a(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,_.pageY)(e),10)-(0,S.getWindowScrollTop)(),left:parseInt((0,_.pageX)(e),10)-(0,S.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),n=0;e>n;n++)t[n]=arguments[n];this.commandExecutor.execute.apply(this.commandExecutor,t)}},{key:"onContextMenu",value:function(e){var t=this.hot.getSettings(),n=t.rowHeaders,o=t.colHeaders,r=e.realTarget;this.close(),(0,S.hasClass)(r,"handsontableInput")||(e.preventDefault(),(0,_.stopPropagation)(e),(n||o||function(e){return"TD"===e.nodeName||"TD"===e.parentNode.nodeName}(r)||(0,S.hasClass)(r,"current")&&(0,S.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(),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}}]),t}(c.default);T.SEPARATOR={name:O.SEPARATOR},(0,E.registerPlugin)("contextMenu",T),t.default=T},function(e,t,n){"use strict";function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){var n=void 0;return(0,s.arrayEach)(t,function(t){var o=t.key?t.key.split(":"):null;if(Array.isArray(o)&&o[1]===e)return n=t,!1}),n}t.__esModule=!0;var i=function(){function e(e,t){for(var n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),s=n(2),a=n(1);t.default=function(){function e(t){o(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,n=arguments.length,o=Array(n>1?n-1:0),i=1;n>i;i++)o[i-1]=arguments[i];var l=e.split(":");e=l[0];var u=2===l.length?l[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,a.hasOwnProperty)(c,"submenu")){var h=[];"function"==typeof c.callback&&h.push(c.callback),"function"==typeof this.commonCallback&&h.push(this.commonCallback),o.unshift(l.join(":")),(0,s.arrayEach)(h,function(e){return e.apply(t.hot,o)})}}}]),e}()},function(e,t,n){"use strict";function o(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]:[],n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},o=[];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=n["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),o.push(r)}):(0,a.arrayEach)(e,function(e,t){var r=n[e];(r||0>l.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),o.push(r))}),o}t.__esModule=!0;var i=function(){function e(e,t){for(var n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),s=n(1),a=n(2),l=n(90);t.default=function(){function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;o(this,e),this.hot=t,this.predefinedItems=(0,l.predefinedItems)(),this.defaultOrderPattern=n}return i(e,[{key:"setPredefinedItems",value:function(e){var t=this,n={};this.defaultOrderPattern.length=0,(0,s.objectEach)(e,function(e,o){var r="";e.name===l.SEPARATOR?(n[l.SEPARATOR]=e,r=l.SEPARATOR):isNaN(parseInt(o,10))?(e.key=void 0===e.key?o:e.key,n[o]=e,r=e.key):(n[e.key]=e,r=e.key),t.defaultOrderPattern.push(r)}),this.predefinedItems=n}},{key:"getItems",value:function(){return r(arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,this.defaultOrderPattern,this.predefinedItems)}}]),e}()},function(e,t,n){"use strict";function o(){return{key:l,name:function(){return this.getTranslatedPhrase(a.CONTEXTMENU_ITEMS_ALIGNMENT)},disabled:function(){return!(this.getSelectedRange()&&!this.selection.selectedHeader.corner)},submenu:{items:[{key:l+":left",name:function(){var e=this,t=this.getTranslatedPhrase(a.CONTEXTMENU_ITEMS_ALIGNMENT_LEFT);return(0,r.checkSelectionConsistency)(this.getSelectedRange(),function(t,n){var o=e.getCellMeta(t,n).className;if(o&&-1!==o.indexOf("htLeft"))return!0})&&(t=(0,r.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),n=(0,r.getAlignmentClasses)(t,function(t,n){return e.getCellMeta(t,n).className});this.runHooks("beforeCellAlignment",n,t,"horizontal","htLeft"),(0,r.align)(t,"horizontal","htLeft",function(t,n){return e.getCellMeta(t,n)},function(t,n,o,r){return e.setCellMeta(t,n,o,r)}),this.render()},disabled:!1},{key:l+":center",name:function(){var e=this,t=this.getTranslatedPhrase(a.CONTEXTMENU_ITEMS_ALIGNMENT_CENTER);return(0,r.checkSelectionConsistency)(this.getSelectedRange(),function(t,n){var o=e.getCellMeta(t,n).className;if(o&&-1!==o.indexOf("htCenter"))return!0})&&(t=(0,r.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),n=(0,r.getAlignmentClasses)(t,function(t,n){return e.getCellMeta(t,n).className});this.runHooks("beforeCellAlignment",n,t,"horizontal","htCenter"),(0,r.align)(t,"horizontal","htCenter",function(t,n){return e.getCellMeta(t,n)},function(t,n,o,r){return e.setCellMeta(t,n,o,r)}),this.render()},disabled:!1},{key:l+":right",name:function(){var e=this,t=this.getTranslatedPhrase(a.CONTEXTMENU_ITEMS_ALIGNMENT_RIGHT);return(0,r.checkSelectionConsistency)(this.getSelectedRange(),function(t,n){var o=e.getCellMeta(t,n).className;if(o&&-1!==o.indexOf("htRight"))return!0})&&(t=(0,r.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),n=(0,r.getAlignmentClasses)(t,function(t,n){return e.getCellMeta(t,n).className});this.runHooks("beforeCellAlignment",n,t,"horizontal","htRight"),(0,r.align)(t,"horizontal","htRight",function(t,n){return e.getCellMeta(t,n)},function(t,n,o,r){return e.setCellMeta(t,n,o,r)}),this.render()},disabled:!1},{key:l+":justify",name:function(){var e=this,t=this.getTranslatedPhrase(a.CONTEXTMENU_ITEMS_ALIGNMENT_JUSTIFY);return(0,r.checkSelectionConsistency)(this.getSelectedRange(),function(t,n){var o=e.getCellMeta(t,n).className;if(o&&-1!==o.indexOf("htJustify"))return!0})&&(t=(0,r.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),n=(0,r.getAlignmentClasses)(t,function(t,n){return e.getCellMeta(t,n).className});this.runHooks("beforeCellAlignment",n,t,"horizontal","htJustify"),(0,r.align)(t,"horizontal","htJustify",function(t,n){return e.getCellMeta(t,n)},function(t,n,o,r){return e.setCellMeta(t,n,o,r)}),this.render()},disabled:!1},{name:i.KEY},{key:l+":top",name:function(){var e=this,t=this.getTranslatedPhrase(a.CONTEXTMENU_ITEMS_ALIGNMENT_TOP);return(0,r.checkSelectionConsistency)(this.getSelectedRange(),function(t,n){var o=e.getCellMeta(t,n).className;if(o&&-1!==o.indexOf("htTop"))return!0})&&(t=(0,r.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),n=(0,r.getAlignmentClasses)(t,function(t,n){return e.getCellMeta(t,n).className});this.runHooks("beforeCellAlignment",n,t,"vertical","htTop"),(0,r.align)(t,"vertical","htTop",function(t,n){return e.getCellMeta(t,n)},function(t,n,o,r){return e.setCellMeta(t,n,o,r)}),this.render()},disabled:!1},{key:l+":middle",name:function(){var e=this,t=this.getTranslatedPhrase(a.CONTEXTMENU_ITEMS_ALIGNMENT_MIDDLE);return(0,r.checkSelectionConsistency)(this.getSelectedRange(),function(t,n){var o=e.getCellMeta(t,n).className;if(o&&-1!==o.indexOf("htMiddle"))return!0})&&(t=(0,r.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),n=(0,r.getAlignmentClasses)(t,function(t,n){return e.getCellMeta(t,n).className});this.runHooks("beforeCellAlignment",n,t,"vertical","htMiddle"),(0,r.align)(t,"vertical","htMiddle",function(t,n){return e.getCellMeta(t,n)},function(t,n,o,r){return e.setCellMeta(t,n,o,r)}),this.render()},disabled:!1},{key:l+":bottom",name:function(){var e=this,t=this.getTranslatedPhrase(a.CONTEXTMENU_ITEMS_ALIGNMENT_BOTTOM);return(0,r.checkSelectionConsistency)(this.getSelectedRange(),function(t,n){var o=e.getCellMeta(t,n).className;if(o&&-1!==o.indexOf("htBottom"))return!0})&&(t=(0,r.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),n=(0,r.getAlignmentClasses)(t,function(t,n){return e.getCellMeta(t,n).className});this.runHooks("beforeCellAlignment",n,t,"vertical","htBottom"),(0,r.align)(t,"vertical","htBottom",function(t,n){return e.getCellMeta(t,n)},function(t,n,o,r){return e.setCellMeta(t,n,o,r)}),this.render()},disabled:!1}]}}}t.__esModule=!0,t.KEY=void 0,t.default=o;var r=n(21),i=n(88),s=n(7),a=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}(s),l=t.KEY="alignment"},function(e,t,n){"use strict";function o(){return{key:a,name:function(){return this.getTranslatedPhrase(s.CONTEXTMENU_ITEMS_CLEAR_COLUMN)},callback:function(e,t){var n=t.start.col;this.countRows()&&this.populateFromArray(0,n,[[null]],Math.max(t.start.row,t.end.row),n,"ContextMenu.clearColumn")},disabled:function(){var e=(0,r.getValidSelection)(this);if(!e)return!0;var t=[e[0],0,e[0],this.countCols()-1],n=t.join(",")===e.join(",");return 0>e[1]||this.countCols()>=this.getSettings().maxCols||n}}}t.__esModule=!0,t.KEY=void 0,t.default=o;var r=n(21),i=n(7),s=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}(i),a=t.KEY="clear_column"},function(e,t,n){"use strict";function o(){return{key:a,name:function(){return this.getTranslatedPhrase(s.CONTEXTMENU_ITEMS_INSERT_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],n=t.join(",")===e.join(","),o=1===this.countCols();return 0>e[1]||this.countCols()>=this.getSettings().maxCols||!o&&n},hidden:function(){return!this.getSettings().allowInsertColumn}}}t.__esModule=!0,t.KEY=void 0,t.default=o;var r=n(21),i=n(7),s=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}(i),a=t.KEY="col_left"},function(e,t,n){"use strict";function o(){return{key:a,name:function(){return this.getTranslatedPhrase(s.CONTEXTMENU_ITEMS_INSERT_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],n=t.join(",")===e.join(","),o=1===this.countCols();return 0>e[1]||this.countCols()>=this.getSettings().maxCols||!o&&n},hidden:function(){return!this.getSettings().allowInsertColumn}}}t.__esModule=!0,t.KEY=void 0,t.default=o;var r=n(21),i=n(7),s=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}(i),a=t.KEY="col_right"},function(e,t,n){"use strict";function o(){return{key:a,name:function(){var e=this,t=this.getTranslatedPhrase(s.CONTEXTMENU_ITEMS_READ_ONLY);return(0,r.checkSelectionConsistency)(this.getSelectedRange(),function(t,n){return e.getCellMeta(t,n).readOnly})&&(t=(0,r.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),n=(0,r.checkSelectionConsistency)(t,function(t,n){return e.getCellMeta(t,n).readOnly});t.forAll(function(t,o){e.setCellMeta(t,o,"readOnly",!n)}),this.render()},disabled:function(){return!(this.getSelectedRange()&&!this.selection.selectedHeader.corner)}}}t.__esModule=!0,t.KEY=void 0,t.default=o;var r=n(21),i=n(7),s=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}(i),a=t.KEY="make_read_only"},function(e,t,n){"use strict";function o(){return{key:s,name:function(){return this.getTranslatedPhrase(i.CONTEXTMENU_ITEMS_REDO)},callback:function(){this.redo()},disabled:function(){return this.undoRedo&&!this.undoRedo.isRedoAvailable()}}}t.__esModule=!0,t.KEY=void 0,t.default=o;var r=n(7),i=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}(r),s=t.KEY="redo"},function(e,t,n){"use strict";function o(){return{key:l,name:function(){var e=this.getSelected(),t=0;if(Array.isArray(e)){var n=r(e,4);n[1]-n[3]!=0&&(t=1)}return this.getTranslatedPhrase(a.CONTEXTMENU_ITEMS_REMOVE_COLUMN,t)},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,i.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;var r=function(){function e(e,t){var n=[],o=!0,r=!1,i=void 0;try{for(var s,a=e[Symbol.iterator]();!(o=(s=a.next()).done)&&(n.push(s.value),!t||n.length!==t);o=!0);}catch(e){r=!0,i=e}finally{try{!o&&a.return&&a.return()}finally{if(r)throw i}}return n}return function(t,n){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}();t.default=o;var i=n(21),s=n(7),a=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}(s),l=t.KEY="remove_col"},function(e,t,n){"use strict";function o(){return{key:l,name:function(){var e=this.getSelected(),t=0;if(Array.isArray(e)){var n=r(e,3);n[0]-n[2]!=0&&(t=1)}return this.getTranslatedPhrase(a.CONTEXTMENU_ITEMS_REMOVE_ROW,t)},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,i.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;var r=function(){function e(e,t){var n=[],o=!0,r=!1,i=void 0;try{for(var s,a=e[Symbol.iterator]();!(o=(s=a.next()).done)&&(n.push(s.value),!t||n.length!==t);o=!0);}catch(e){r=!0,i=e}finally{try{!o&&a.return&&a.return()}finally{if(r)throw i}}return n}return function(t,n){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}();t.default=o;var i=n(21),s=n(7),a=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}(s),l=t.KEY="remove_row"},function(e,t,n){"use strict";function o(){return{key:a,name:function(){return this.getTranslatedPhrase(s.CONTEXTMENU_ITEMS_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=o;var r=n(21),i=n(7),s=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}(i),a=t.KEY="row_above"},function(e,t,n){"use strict";function o(){return{key:a,name:function(){return this.getTranslatedPhrase(s.CONTEXTMENU_ITEMS_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=o;var r=n(21),i=n(7),s=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}(i),a=t.KEY="row_below"},function(e,t,n){"use strict";function o(){return{key:s,name:function(){return this.getTranslatedPhrase(i.CONTEXTMENU_ITEMS_UNDO)},callback:function(){this.undo()},disabled:function(){return this.undoRedo&&!this.undoRedo.isUndoAvailable()}}}t.__esModule=!0,t.KEY=void 0,t.default=o;var r=n(7),i=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}(r),s=t.KEY="undo"},function(e,t,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),s=n(84),a=o(s),l=n(0),u=n(2),c=n(399),h=o(c),d=n(4),f=o(d),p=n(1),g=n(17),v=n(37),m=n(21),y=n(20),w=n(89),C=o(w),b=n(90),E=n(11),_=function(){function e(t,n){r(this,e),this.hot=t,this.options=n||{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,v.debounce)(function(t){return e.openSubMenu(t)},300),n=(0,u.arrayFilter)(this.menuItems,function(t){return(0,m.isItemHidden)(t,e.hot)});n=(0,m.filterSeparators)(n,b.SEPARATOR);var o={data:n,colHeaders:!1,colWidths:[200],autoRowSize:!1,readOnly:!0,copyPaste:!1,columns:[{data:"name",renderer:function(t,n,o,r,i,s){return e.menuItemRenderer(t,n,o,r,i,s)}}],renderAllRows:!0,fragmentSelection:"cell",disableVisualSelection:"area",beforeKeyDown:function(t){return e.onBeforeKeyDown(t)},afterOnCellMouseOver:function(n,o,r){e.isAllSubMenusClosed()?t(o.row):e.openSubMenu(o.row)},rowHeights:function(e){return n[e].name===b.SEPARATOR?1:23}};this.origOutsideClickDeselects=this.hot.getSettings().outsideClickDeselects,this.hot.getSettings().outsideClickDeselects=!1,this.hotMenu=new a.default(this.container,o),this.hotMenu.addHook("afterInit",function(){return e.onAfterInit()}),this.hotMenu.addHook("afterSelection",function(t,n,o,r,i){return e.onAfterSelection(t,n,o,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 n=this.hotMenu.getCell(t,0);if(this.closeAllSubMenus(),!n||!(0,m.hasSubMenu)(n))return!1;var o=this.hotMenu.getSourceDataAtRow(t),r=new e(this.hot,{parent:this,name:o.name,className:this.options.className,keepInViewport:!0});return r.setMenuItems(o.submenu.items),r.open(),r.setPosition(n.getBoundingClientRect()),this.hotSubMenus[o.key]=r,r}},{key:"closeSubMenu",value:function(e){var t=this.hotMenu.getSourceDataAtRow(e),n=this.hotSubMenus[t.key];n&&(n.destroy(),delete this.hotSubMenus[t.key])}},{key:"closeAllSubMenus",value:function(){var e=this;(0,u.arrayEach)(this.hotMenu.getData(),function(t,n){return e.closeSubMenu(n)})}},{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!==b.SEPARATOR){var n=this.hot.getSelectedRange(),o=n?(0,m.normalizeSelection)(n):{},r=!0;(!0===t.disabled||"function"==typeof t.disabled&&!0===t.disabled.call(this.hot)||t.submenu)&&(r=!1),this.runLocalHooks("executeCommand",t.key,o,e),this.isSubMenu()&&this.parentMenu.runLocalHooks("executeCommand",t.key,o,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,l.getScrollbarWidth)()+4+"px"}},{key:"selectFirstCell",value:function(){var e=this.hotMenu.getCell(0,0);(0,m.isSeparator)(e)||(0,m.isDisabled)(e)||(0,m.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,m.isSeparator)(t)||(0,m.isDisabled)(t)||(0,m.isSelectionDisabled)(t)?this.selectPrevCell(e,0):this.hotMenu.selectCell(e,0)}},{key:"selectNextCell",value:function(e,t){var n=e+1,o=n<this.hotMenu.countRows()?this.hotMenu.getCell(n,t):null;o&&((0,m.isSeparator)(o)||(0,m.isDisabled)(o)||(0,m.isSelectionDisabled)(o)?this.selectNextCell(n,t):this.hotMenu.selectCell(n,t))}},{key:"selectPrevCell",value:function(e,t){var n=e-1,o=0>n?null:this.hotMenu.getCell(n,t);o&&((0,m.isSeparator)(o)||(0,m.isDisabled)(o)||(0,m.isSelectionDisabled)(o)?this.selectPrevCell(n,t):this.hotMenu.selectCell(n,t))}},{key:"menuItemRenderer",value:function(e,t,n,o,r,i){var s=this,a=e.getSourceDataAtRow(n),u=document.createElement("div"),c=function(e){return e.disableSelection};"function"==typeof i&&(i=i.call(this.hot)),(0,l.empty)(t),(0,l.addClass)(u,"htItemWrapper"),t.appendChild(u),!function(e){return RegExp(b.SEPARATOR,"i").test(e.name)}(a)?"function"==typeof a.renderer?((0,l.addClass)(t,"htCustomMenuRenderer"),t.appendChild(a.renderer(e,u,n,o,r,i))):(0,l.fastInnerHTML)(u,i):(0,l.addClass)(t,"htSeparator"),!function(e){return!0===e.disabled||"function"==typeof e.disabled&&!0===e.disabled.call(s.hot)}(a)?c(a)?((0,l.addClass)(t,"htSelectionDisabled"),this.eventManager.addEventListener(t,"mouseenter",function(){return e.deselectCell()})):!function(e){return(0,p.hasOwnProperty)(e,"submenu")}(a)?((0,l.removeClass)(t,"htSubmenu"),(0,l.removeClass)(t,"htDisabled"),c(a)?this.eventManager.addEventListener(t,"mouseenter",function(){return e.deselectCell()}):this.eventManager.addEventListener(t,"mouseenter",function(){return e.selectCell(n,o,void 0,void 0,!1,!1)})):((0,l.addClass)(t,"htSubmenu"),c(a)?this.eventManager.addEventListener(t,"mouseenter",function(){return e.deselectCell()}):this.eventManager.addEventListener(t,"mouseenter",function(){return e.selectCell(n,o,void 0,void 0,!1,!1)})):((0,l.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,t=void 0;return e?((0,v.isFunction)(e)&&(e=e.call(this.hot),e=null===e||(0,g.isUndefined)(e)?"":""+e),e=e.replace(/[^A-z0-9]/g,"_"),e=this.options.className+"Sub_"+e,t=document.querySelector("."+this.options.className+"."+e)):t=document.querySelector("."+this.options.className),t||(t=document.createElement("div"),(0,l.addClass)(t,"htMenu "+this.options.className),e&&(0,l.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(),n=!1;switch(this.keyEvent=!0,e.keyCode){case y.KEY_CODES.ESCAPE:this.close(),n=!0;break;case y.KEY_CODES.ENTER:t&&(this.hotMenu.getSourceDataAtRow(t[0]).submenu?n=!0:(this.executeCommand(e),this.close(!0)));break;case y.KEY_CODES.ARROW_DOWN:t?this.selectNextCell(t[0],t[1]):this.selectFirstCell(),n=!0;break;case y.KEY_CODES.ARROW_UP:t?this.selectPrevCell(t[0],t[1]):this.selectLastCell(),n=!0;break;case y.KEY_CODES.ARROW_RIGHT:if(t){var o=this.openSubMenu(t[0]);o&&o.selectFirstCell()}n=!0;break;case y.KEY_CODES.ARROW_LEFT:t&&this.isSubMenu()&&(this.close(),this.parentMenu&&this.parentMenu.hotMenu.listen(),n=!0)}n&&(e.preventDefault(),(0,E.stopImmediatePropagation)(e)),this.keyEvent=!1}},{key:"onAfterInit",value:function(){var e=this.hotMenu.getSettings().data,t=this.hotMenu.view.wt.wtTable.hider.style,n=this.hotMenu.view.wt.wtTable.holder.style,o=parseInt(t.width,10),r=(0,u.arrayReduce)(e,function(e,t){return e+(t.name===b.SEPARATOR?1:26)},0);n.width=o+22+"px",n.height=r+4+"px",t.height=n.height}},{key:"onAfterSelection",value:function(e,t,n,o,r){!1===this.keyEvent&&(r.value=!0)}},{key:"onDocumentMouseDown",value:function(e){this.isOpened()&&(this.container&&(0,l.isChildOf)(e.target,this.container)&&this.executeCommand(e),this.options.standalone&&this.hotMenu&&!(0,l.isChildOf)(e.target,this.hotMenu.rootElement)?this.close(!0):(this.isAllSubMenusClosed()||this.isSubMenu())&&!(0,l.isChildOf)(e.target,".htMenu")&&(0,l.isChildOf)(e.target,document)&&this.close(!0))}}]),e}();(0,p.mixin)(_,C.default),t.default=_},function(e,t,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=n(0),s=n(11);t.default=function(){function e(t){o(this,e);var n=(0,i.getWindowScrollTop)(),r=(0,i.getWindowScrollLeft)(),a=void 0,l=void 0,u=void 0,c=void 0,h=void 0,d=void 0;this.type=this.getSourceType(t),"literal"===this.type?(a=parseInt(t.top,10),u=parseInt(t.left,10),h=t.height||0,d=t.width||0,l=a,c=u,a+=n,u+=r):"event"===this.type&&(a=parseInt((0,s.pageY)(t),10),u=parseInt((0,s.pageX)(t),10),h=t.target.clientHeight,d=t.target.clientWidth,l=a-n,c=u-r),this.top=a,this.topRelative=l,this.left=u,this.leftRelative=c,this.scrollTop=n,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,n){"use strict";function o(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 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},l=function(){function e(e,t){for(var n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),u=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(o)},c=n(14),h=o(c),d=n(8),f=o(d),p=n(289),g=o(p),v=n(13),m=n(0),y=n(2),w=n(5),C=n(6),b=n(402),E=o(b),_=n(403),S=o(_),O=n(404),T=o(O),R=n(4),k=o(R),M=n(405),N=o(M);n(407),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 D=1e3,A=1e3,H=new WeakMap,P=function(e){function t(e){r(this,t);var n=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.eventManager=new k.default(n),n.columnsLimit=A,n.copyableRanges=[],n.pasteMode="overwrite",n.rowsLimit=D,n.textarea=void 0,H.set(n,{isTriggeredByCopy:!1,isTriggeredByCut:!1,isBeginEditing:!1,isFragmentSelectionEnabled:!1}),n}return s(t,e),l(t,[{key:"isEnabled",value:function(){return!!this.hot.getSettings().copyPaste}},{key:"enablePlugin",value:function(){var e=this;if(!this.enabled){var n=this.hot.getSettings(),o=H.get(this);this.textarea=E.default.getSingleton(),o.isFragmentSelectionEnabled=n.fragmentSelection,"object"===a(n.copyPaste)&&(this.pasteMode=n.copyPaste.pasteMode||this.pasteMode,this.rowsLimit=n.copyPaste.rowsLimit||this.rowsLimit,this.columnsLimit=n.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(),n=e.getBottomRightCorner(),o=t.row,r=t.col,i=n.row,s=n.col,a=Math.min(i,o+this.rowsLimit-1),l=Math.min(s,r+this.columnsLimit-1);this.copyableRanges.length=0,this.copyableRanges.push({startRow:o,startCol:r,endRow:a,endCol:l}),this.copyableRanges=this.hot.runHooks("modifyCopyableRange",this.copyableRanges),i===a&&s===l||this.hot.runHooks("afterCopyLimit",i-o+1,s-r+1,this.rowsLimit,this.columnsLimit)}}},{key:"getRangedCopyableData",value:function(e){var t=this,n=[],o=[],r=[];return(0,y.arrayEach)(e,function(e){(0,w.rangeEach)(e.startRow,e.endRow,function(e){-1===o.indexOf(e)&&o.push(e)}),(0,w.rangeEach)(e.startCol,e.endCol,function(e){-1===r.indexOf(e)&&r.push(e)})}),(0,y.arrayEach)(o,function(e){var o=[];(0,y.arrayEach)(r,function(n){o.push(t.hot.getCopyableData(e,n))}),n.push(o)}),g.default.stringify(n)}},{key:"getRangedData",value:function(e){var t=this,n=[],o=[],r=[];return(0,y.arrayEach)(e,function(e){(0,w.rangeEach)(e.startRow,e.endRow,function(e){-1===o.indexOf(e)&&o.push(e)}),(0,w.rangeEach)(e.startCol,e.endCol,function(e){-1===r.indexOf(e)&&r.push(e)})}),(0,y.arrayEach)(o,function(e){var o=[];(0,y.arrayEach)(r,function(n){o.push(t.hot.getCopyableData(e,n))}),n.push(o)}),n}},{key:"copy",value:function(){H.get(this).isTriggeredByCopy=!0,this.textarea.select(),document.execCommand("copy")}},{key:"cut",value:function(){H.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 N.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=H.get(this);if(this.hot.isListening()||t.isTriggeredByCopy){this.setCopyableText(),t.isTriggeredByCopy=!1;var n=this.getRangedData(this.copyableRanges),o=!!this.hot.runHooks("beforeCopy",n,this.copyableRanges),r="";o&&(r=g.default.stringify(n),e&&e.clipboardData?e.clipboardData.setData("text/plain",r):"undefined"==typeof ClipboardEvent&&window.clipboardData.setData("Text",r),this.hot.runHooks("afterCopy",n,this.copyableRanges)),e.preventDefault()}}},{key:"onCut",value:function(e){var t=H.get(this);if(this.hot.isListening()||t.isTriggeredByCut){this.setCopyableText(),t.isTriggeredByCut=!1;var n=this.getRangedData(this.copyableRanges),o=!!this.hot.runHooks("beforeCut",n,this.copyableRanges),r=void 0;o&&(r=g.default.stringify(n),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",n,this.copyableRanges)),e.preventDefault()}}},{key:"onPaste",value:function(e){var t=this;if(this.hot.isListening()){e&&e.preventDefault&&e.preventDefault();var n=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")),n=g.default.parse(this.textarea.getValue()),this.textarea.setValue(" "),0!==n.length){if(!!this.hot.runHooks("beforePaste",n,this.copyableRanges)){var o=this.hot.getSelected(),r=new v.CellCoords(o[0],o[1]),i=new v.CellCoords(o[2],o[3]),s=new v.CellRange(r,r,i),a=s.getTopLeftCorner(),l=s.getBottomRightCorner(),u=a,c=new v.CellCoords(Math.max(l.row,n.length-1+a.row),Math.max(l.col,n[0].length-1+a.col)),h=i.row-r.row>=n.length-1,d=i.col-r.col>=n[0].length-1;this.hot.addHookOnce("afterChange",function(e){var n=e?e.length:0;if(n){var o={row:0,col:0},r=-1;(0,y.arrayEach)(e,function(t,i){var s=n>i+1?e[i+1]:null;s&&(h||(o.row+=Math.max(s[0]-t[0]-1,0)),!d&&t[1]>r&&(r=t[1],o.col+=Math.max(s[1]-t[1]-1,0)))}),t.hot.selectCell(u.row,u.col,c.row+o.row,c.col+o.col)}}),this.hot.populateFromArray(u.row,u.col,n,c.row,c.col,"CopyPaste.paste",this.pasteMode),this.hot.runHooks("afterPaste",n,this.copyableRanges)}}}}},{key:"onAfterContextMenuDefaultOptions",value:function(e){e.items.push({name:"---------"},(0,S.default)(this),(0,T.default)(this))}},{key:"onAfterSelectionEnd",value:function(){var e=H.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",P),t.default=P},function(e,t,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=function(){function e(){o(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,n){"use strict";function o(e){return{key:"copy",name:function(){return this.getTranslatedPhrase(i.CONTEXTMENU_ITEMS_COPY)},callback:function(){e.copy()},disabled:function(){return!e.hot.getSelected()},hidden:!1}}t.__esModule=!0,t.default=o;var r=n(7),i=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}(r)},function(e,t,n){"use strict";function o(e){return{key:"cut",name:function(){return this.getTranslatedPhrase(i.CONTEXTMENU_ITEMS_CUT)},callback:function(){e.cut()},disabled:function(){return!e.hot.getSelected()},hidden:!1}}t.__esModule=!0,t.default=o;var r=n(7),i=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}(r)},function(e,t,n){"use strict";function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=n(406),i=function(e){return e&&e.__esModule?e:{default:e}}(r);t.default=function e(){o(this,e),this.clipboardData=new i.default}},function(e,t,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}();t.default=function(){function e(){o(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,n){"use strict";function o(){}t.__esModule=!0;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=n(8),a=function(e){return e&&e.__esModule?e:{default:e}}(s),l=n(1),u=n(13),c=n(7),h=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}(c),d=function(e){return"boolean"==typeof e&&!0===e||"object"===(void 0===e?"undefined":i(e))&&e.length>0},f=function(){d(this.getSettings().customBorders)&&(this.customBorders||(r=this,this.customBorders=new o))},p=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},g=function(e){var t={row:e.row,col:e.col},n=new u.Selection(e,new u.CellRange(t,t,t)),o=p(e.className);0>o?r.view.wt.selections.push(n):r.view.wt.selections[o]=n},v=function(e,t,n){var o=E(e,t);o=_(o,n),this.setCellMeta(e,t,"borders",o),g(o)},m=function(e){for(var t=e.range,n=t.from.row;t.to.row>=n;n++)for(var o=t.from.col;t.to.col>=o;o++){var r=E(n,o),i=0;n==t.from.row&&(i++,(0,l.hasOwnProperty)(e,"top")&&(r.top=e.top)),n==t.to.row&&(i++,(0,l.hasOwnProperty)(e,"bottom")&&(r.bottom=e.bottom)),o==t.from.col&&(i++,(0,l.hasOwnProperty)(e,"left")&&(r.left=e.left)),o==t.to.col&&(i++,(0,l.hasOwnProperty)(e,"right")&&(r.right=e.right)),i>0&&(this.setCellMeta(n,o,"borders",r),g(r))}},y=function(e,t){return"border_row"+e+"col"+t},w=function(){return{width:1,color:"#000"}},C=function(){return{hide:!0}},b=function(){return{width:1,color:"#000",cornerVisible:!1}},E=function(e,t){return{className:y(e,t),border:b(),row:e,col:t,top:C(),right:C(),bottom:C(),left:C()}},_=function(e,t){return(0,l.hasOwnProperty)(t,"border")&&(e.border=t.border),(0,l.hasOwnProperty)(t,"top")&&(e.top=t.top),(0,l.hasOwnProperty)(t,"right")&&(e.right=t.right),(0,l.hasOwnProperty)(t,"bottom")&&(e.bottom=t.bottom),(0,l.hasOwnProperty)(t,"left")&&(e.left=t.left),e},S=function(e){for(var t=document.querySelectorAll("."+e),n=0;t.length>n;n++)if(t[n]&&"TD"!=t[n].nodeName){var o=t[n].parentNode;o.parentNode&&o.parentNode.removeChild(o)}},O=function(e,t){var n=y(e,t);S(n),this.removeCellMeta(e,t,"borders")},T=function(e,t,n,o){var r=this.getCellMeta(e,t).borders;r&&void 0!=r.border||(r=E(e,t)),r[n]=o?C():w(),this.setCellMeta(e,t,"borders",r);var i=y(e,t);S(i),g(r),this.render()},R=function(e,t,n){if(e.from.row==e.to.row&&e.from.col==e.to.col)"noBorders"==t?O.call(this,e.from.row,e.from.col):T.call(this,e.from.row,e.from.col,t,n);else switch(t){case"noBorders":for(var o=e.from.col;e.to.col>=o;o++)for(var r=e.from.row;e.to.row>=r;r++)O.call(this,r,o);break;case"top":for(var i=e.from.col;e.to.col>=i;i++)T.call(this,e.from.row,i,t,n);break;case"right":for(var s=e.from.row;e.to.row>=s;s++)T.call(this,s,e.to.col,t);break;case"bottom":for(var a=e.from.col;e.to.col>=a;a++)T.call(this,e.to.row,a,t);break;case"left":for(var l=e.from.row;e.to.row>=l;l++)T.call(this,l,e.from.col,t)}},k=function(e,t){var n=!1;return e.getSelectedRange().forAll(function(o,r){var i=e.getCellMeta(o,r).borders;if(i){if(!t)return n=!0,!1;if(!(0,l.hasOwnProperty)(i[t],"hide"))return n=!0,!1}}),n},M=function(e){return'<span class="selected">'+String.fromCharCode(10003)+"</span>"+e},N=function(e){this.getSettings().customBorders&&(e.items.push({name:"---------"}),e.items.push({key:"borders",name:function(){return this.getTranslatedPhrase(h.CONTEXTMENU_ITEMS_BORDERS)},disabled:function(){return this.selection.selectedHeader.corner},submenu:{items:[{key:"borders:top",name:function(){var e=this.getTranslatedPhrase(h.CONTEXTMENU_ITEMS_BORDERS_TOP);return k(this,"top")&&(e=M(e)),e},callback:function(){var e=k(this,"top");R.call(this,this.getSelectedRange(),"top",e)}},{key:"borders:right",name:function(){var e=this.getTranslatedPhrase(h.CONTEXTMENU_ITEMS_BORDERS_RIGHT);return k(this,"right")&&(e=M(e)),e},callback:function(){var e=k(this,"right");R.call(this,this.getSelectedRange(),"right",e)}},{key:"borders:bottom",name:function(){var e=this.getTranslatedPhrase(h.CONTEXTMENU_ITEMS_BORDERS_BOTTOM);return k(this,"bottom")&&(e=M(e)),e},callback:function(){var e=k(this,"bottom");R.call(this,this.getSelectedRange(),"bottom",e)}},{key:"borders:left",name:function(){var e=this.getTranslatedPhrase(h.CONTEXTMENU_ITEMS_BORDERS_LEFT);return k(this,"left")&&(e=M(e)),e},callback:function(){var e=k(this,"left");R.call(this,this.getSelectedRange(),"left",e)}},{key:"borders:no_borders",name:function(){return this.getTranslatedPhrase(h.CONTEXTMENU_ITEMS_REMOVE_BORDERS)},callback:function(){R.call(this,this.getSelectedRange(),"noBorders")},disabled:function(){return!k(this)}}]}}))};a.default.getSingleton().add("beforeInit",f),a.default.getSingleton().add("afterContextMenuDefaultOptions",N),a.default.getSingleton().add("afterInit",function(){var e=this.getSettings().customBorders;if(e){for(var t=0;e.length>t;t++)e[t].range?m.call(this,e[t]):v.call(this,e[t].row,e[t].col,e[t]);this.render(),this.view.wt.draw(!0)}}),t.default=o},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}function r(){this.boundaries=null,this.callback=null}t.__esModule=!0;var i=n(8),s=o(i),a=n(4),l=o(a);n(6);r.prototype.setBoundaries=function(e){this.boundaries=e},r.prototype.setCallback=function(e){this.callback=e},r.prototype.check=function(e,t){var n=0,o=0;this.boundaries.top>t?o=t-this.boundaries.top:t>this.boundaries.bottom&&(o=t-this.boundaries.bottom),this.boundaries.left>e?n=e-this.boundaries.left:e>this.boundaries.right&&(n=e-this.boundaries.right),this.callback(n,o)};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,n){0>e?t.scrollLeft-=50:e>0&&(t.scrollLeft+=50),0>n?t.scrollTop-=20:n>0&&(t.scrollTop+=20)}),e.dragToScrollListening=!0)};s.default.getSingleton().add("afterInit",function(){var e=this,t=new l.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 l.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,n){"use strict";function o(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 a=function(){function e(e,t){for(var n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),l=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(o)},u=n(14),c=o(u),h=n(6),d=n(2),f=n(411),p=o(f),g=n(412),v=o(g);n(413);var m=new WeakMap,y=function(e){function t(e){r(this,t);var n=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return m.set(n,{moveByFreeze:!1,afterFirstUse:!1}),n.frozenColumnsBasePositions=[],n.manualColumnMovePlugin=void 0,n}return s(t,e),a(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,n){return e.onBeforeColumnMove(t,n)}),l(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,l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"updatePlugin",value:function(){this.disablePlugin(),this.enablePlugin(),l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"updatePlugin",this).call(this)}},{key:"freezeColumn",value:function(e){var t=m.get(this),n=this.hot.getSettings();t.afterFirstUse||(t.afterFirstUse=!0),n.fixedColumnsLeft!==this.hot.countCols()&&e>n.fixedColumnsLeft-1&&(t.moveByFreeze=!0,e!==this.getMovePlugin().columnsMapper.getValueByIndex(e)&&(this.frozenColumnsBasePositions[n.fixedColumnsLeft]=e),this.getMovePlugin().moveColumn(e,n.fixedColumnsLeft++))}},{key:"unfreezeColumn",value:function(e){var t=m.get(this),n=this.hot.getSettings();if(t.afterFirstUse||(t.afterFirstUse=!0),n.fixedColumnsLeft>0&&n.fixedColumnsLeft-1>=e){var o=this.getBestColumnReturnPosition(e);t.moveByFreeze=!0,n.fixedColumnsLeft--,this.getMovePlugin().moveColumn(e,o+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(),n=this.hot.getSettings(),o=n.fixedColumnsLeft,r=t.columnsMapper.getValueByIndex(o),i=void 0;if(null==this.frozenColumnsBasePositions[e])for(i=t.columnsMapper.getValueByIndex(e);i>r;)o++,r=t.columnsMapper.getValueByIndex(o);else{for(i=this.frozenColumnsBasePositions[e],this.frozenColumnsBasePositions[e]=void 0;i>=r;)o++,r=t.columnsMapper.getValueByIndex(o);o=r}return o-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 n=m.get(this);if(n.afterFirstUse&&!n.moveByFreeze){var o=this.hot.getSettings().fixedColumnsLeft,r=o>t;if(r||(0,d.arrayEach)(e,function(e,t,n){if(o>e)return r=!0,!1}),r)return!1}n.moveByFreeze&&(n.moveByFreeze=!1)}},{key:"destroy",value:function(){l(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,n){"use strict";function o(e){return{key:"freeze_column",name:function(){return this.getTranslatedPhrase(i.CONTEXTMENU_ITEMS_FREEZE_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=o;var r=n(7),i=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}(r)},function(e,t,n){"use strict";function o(e){return{key:"unfreeze_column",name:function(){return this.getTranslatedPhrase(i.CONTEXTMENU_ITEMS_UNFREEZE_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=o;var r=n(7),i=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}(r)},function(e,t){},function(e,t,n){"use strict";function o(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 a=function(){function e(e,t){for(var n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),l=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(o)},u=n(14),c=o(u),h=n(8),d=o(h),f=n(2),p=n(0),g=n(5),v=n(4),m=o(v),y=n(6),w=n(415),C=o(w),b=n(416),E=o(b),_=n(417),S=o(_),O=n(13);n(418),d.default.getSingleton().register("beforeColumnMove"),d.default.getSingleton().register("afterColumnMove"),d.default.getSingleton().register("unmodifyCol");var T=new WeakMap,R=function(e){function t(e){r(this,t);var n=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return T.set(n,{columnsToMove:[],countCols:0,fixedColumns:0,pressed:void 0,disallowMoving:void 0,target:{eventPageX:void 0,coords:void 0,TD:void 0,col:void 0}}),n.removedColumns=[],n.columnsMapper=new C.default(n),n.eventManager=new m.default(n),n.backlight=new E.default(e),n.guideline=new S.default(e),n}return s(t,e),a(t,[{key:"isEnabled",value:function(){return!!this.hot.getSettings().manualColumnMove}},{key:"enablePlugin",value:function(){var e=this;this.enabled||(this.addHook("beforeOnCellMouseDown",function(t,n,o,r){return e.onBeforeOnCellMouseDown(t,n,o,r)}),this.addHook("beforeOnCellMouseOver",function(t,n,o,r){return e.onBeforeOnCellMouseOver(t,n,o,r)}),this.addHook("afterScrollVertically",function(){return e.onAfterScrollVertically()}),this.addHook("modifyCol",function(t,n){return e.onModifyCol(t,n)}),this.addHook("beforeRemoveCol",function(t,n){return e.onBeforeRemoveCol(t,n)}),this.addHook("afterRemoveCol",function(){return e.onAfterRemoveCol()}),this.addHook("afterCreateCol",function(t,n){return e.onAfterCreateCol(t,n)}),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"),l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{key:"updatePlugin",value:function(){this.disablePlugin(),this.enablePlugin(),this.onAfterPluginsInitialized(),l(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(),l(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 n=this,o=T.get(this),r=this.hot.runHooks("beforeColumnMove",e,t);o.disallowMoving=!r,!1!==r&&((0,f.arrayEach)(e,function(e,t,o){o[t]=n.columnsMapper.getValueByIndex(e)}),(0,f.arrayEach)(e,function(e,o){var r=n.columnsMapper.getIndexByValue(e);r!==t&&n.columnsMapper.moveColumn(r,t+o)}),this.columnsMapper.clearNull()),this.hot.runHooks("afterColumnMove",e,t)}},{key:"changeSelection",value:function(e,t){var n=this.hot.selection,o=this.hot.countRows()-1;n.setRangeStartOnly(new O.CellCoords(0,e)),n.setRangeEnd(new O.CellCoords(o,t),!1)}},{key:"getColumnsWidth",value:function(e,t){for(var n=0,o=e;t>o;o++){var r=0;r=0>o?this.hot.view.wt.wtViewport.getRowHeaderWidth()||0:this.hot.view.wt.wtTable.getStretchedColumnWidth(o)||0,n+=r}return n}},{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 n=[];return(0,g.rangeEach)(e,t,function(e){n.push(e)}),n}},{key:"refreshPositions",value:function(){var e=T.get(this),t=this.hot.view.wt.wtTable.getFirstVisibleColumn(),n=this.hot.view.wt.wtTable.getLastVisibleColumn(),o=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),a=e.target.eventPageX-(e.rootElementOffset-(void 0===r.scrollX?i:0)),l=o.hider.offsetWidth,u=o.TBODY.offsetLeft,c=this.backlight.getOffset().left,h=this.backlight.getSize().width,d=0;if(e.target.eventPageX>e.rootElementOffset+o.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(a<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>n&&this.hot.scrollViewportTo(void 0,n+1,void 0,!0)}e.target.col>t||e.fixedColumns>e.target.col||this.hot.scrollViewportTo(void 0,t-1);var p=a,g=s;l>a+h+c?u+d>a+c&&(p=u+d+Math.abs(c)):p=l-h-c,l-1>s?0===g?g=1:void 0!==r.scrollX&&e.fixedColumns>e.coordsColumn&&(g-=e.rootElementOffset>r.scrollX?0:e.rootElementOffset):g=l-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 n=e-t;this.columnsMapper.insertItems(t,n)}else if(t>e){var o=e-1,r=[];(0,f.arrayEach)(this.columnsMapper._arrayMap,function(e,t){e>o&&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,n,o){var r=this.hot.view.wt.wtTable,i=this.hot.selection.selectedHeader.cols,s=this.hot.getSelectedRange(),a=T.get(this),l=e.realTarget.className.indexOf("columnSorting")>-1;if(!s||!i||a.pressed||0!==e.button||l)return a.pressed=!1,a.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"),a.pressed=!1,a.columnsToMove.length=0;else{o.column=!0,a.pressed=!0,a.target.eventPageX=e.pageX,a.coordsColumn=t.col,a.target.TD=n,a.target.col=t.col,a.columnsToMove=this.prepareColumnsToMoving(f,g),a.hasRowHeaders=!!this.hot.getSettings().rowHeaders,a.countCols=this.hot.countCols(),a.fixedColumns=this.hot.getSettings().fixedColumnsLeft,a.rootElementOffset=(0,p.offset)(this.hot.rootElement).left;var v=a.hasRowHeaders?-1:0,m=r.holder.scrollTop+r.getColumnHeaderHeight(0)+1,y=a.fixedColumns>t.col,w=this.hot.view.wt.wtOverlays.scrollableElement,C=w.scrollX?w.scrollX-a.rootElementOffset:0,b=e.layerX-(y?C:0),E=Math.abs(this.getColumnsWidth(f,t.col)+b);this.backlight.setPosition(m,this.getColumnsWidth(v,f)+E),this.backlight.setSize(this.getColumnsWidth(f,g+1),r.hider.offsetHeight-m),this.backlight.setOffset(null,-1*E),(0,p.addClass)(this.hot.rootElement,"on-moving--columns")}}},{key:"onMouseMove",value:function(e){var t=T.get(this);if(t.pressed){if(e.realTarget===this.backlight.element){var n=this.backlight.getSize().width;this.backlight.setSize(0),setTimeout(function(){this.backlight.setPosition(n)})}t.target.eventPageX=e.pageX,this.refreshPositions()}}},{key:"onBeforeOnCellMouseOver",value:function(e,t,n,o){var r=this.hot.getSelectedRange(),i=T.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"),o.row=!0,o.column=!0,o.cell=!0,i.coordsColumn=t.col,i.target.TD=n)}},{key:"onMouseUp",value:function(){var e=T.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,n=e.holder.scrollTop,o=t+n;this.backlight.setPosition(o),this.backlight.setSize(null,e.hider.offsetHeight-o)}},{key:"onAfterCreateCol",value:function(e,t){this.columnsMapper.shiftItems(e,t)}},{key:"onBeforeRemoveCol",value:function(e,t){var n=this;this.removedColumns.length=0,!1!==e&&(0,g.rangeEach)(e,e+t-1,function(e){n.removedColumns.push(n.hot.runHooks("modifyCol",e,n.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 n=this.columnsMapper.getValueByIndex(e);e=null===n?e:n}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(),l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}}]),t}(c.default);(0,y.registerPlugin)("ManualColumnMove",R),t.default=R},function(e,t,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=n(296),s=function(e){return e&&e.__esModule?e:{default:e}}(i),a=n(2),l=n(1),u=n(5),c=function(){function e(t){o(this,e),this.manualColumnMove=t}return r(e,[{key:"createMap",value:function(e){var t=this,n=void 0===e?this._arrayMap.length:e;this._arrayMap.length=0,(0,u.rangeEach)(n-1,function(e){t._arrayMap[e]=e})}},{key:"destroy",value:function(){this._arrayMap=null}},{key:"moveColumn",value:function(e,t){var n=this._arrayMap[e];this._arrayMap[e]=null,this._arrayMap.splice(t,0,n)}},{key:"clearNull",value:function(){this._arrayMap=(0,a.arrayFilter)(this._arrayMap,function(e){return null!==e})}}]),e}();(0,l.mixin)(c,s.default),t.default=c},function(e,t,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),a=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(o)},l=n(297),u=function(e){return e&&e.__esModule?e:{default:e}}(l),c=n(0);t.default=function(e){function t(){return o(this,t),r(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return i(t,e),s(t,[{key:"build",value:function(){a(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,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),a=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(o)},l=n(297),u=function(e){return e&&e.__esModule?e:{default:e}}(l),c=n(0);t.default=function(e){function t(){return o(this,t),r(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return i(t,e),s(t,[{key:"build",value:function(){a(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,n){"use strict";function o(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 a=function(){function e(e,t){for(var n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),l=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(o)},u=n(14),c=o(u),h=n(0),d=n(4),f=o(d),p=n(11),g=n(2),v=n(5),m=n(6),y=function(e){function t(e){r(this,t);var n=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.currentTH=null,n.currentCol=null,n.selectedCols=[],n.currentWidth=null,n.newSize=null,n.startY=null,n.startWidth=null,n.startOffset=null,n.handle=document.createElement("DIV"),n.guide=document.createElement("DIV"),n.eventManager=new f.default(n),n.pressed=null,n.dblclick=0,n.autoresizeTimeout=null,n.manualColumnWidths=[],(0,h.addClass)(n.handle,"manualColumnResizer"),(0,h.addClass)(n.guide,"manualColumnResizerGuide"),n}return s(t,e),a(t,[{key:"isEnabled",value:function(){return this.hot.getSettings().manualColumnResize}},{key:"enablePlugin",value:function(){var e=this;if(!this.enabled){this.manualColumnWidths=[];var n=this.hot.getSettings().manualColumnResize,o=this.loadManualColumnWidths();this.addHook("modifyColWidth",function(t,n){return e.onModifyColWidth(t,n)}),this.addHook("beforeStretchingColumnWidth",function(t,n){return e.onBeforeStretchingColumnWidth(t,n)}),this.addHook("beforeColumnResize",function(t,n,o){return e.onBeforeColumnResize(t,n,o)}),this.manualColumnWidths=void 0!==o?o:Array.isArray(n)?n:[],this.bindEvents(),l(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(){l(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 n=this.hot.view.wt.wtTable.getCoords(e).col,o=(0,h.outerHeight)(this.currentTH);if(n>=0){var r=this.currentTH.getBoundingClientRect();if(this.currentCol=n,this.selectedCols=[],this.hot.selection.isSelected()&&this.hot.selection.selectedHeader.cols){var i=this.hot.getSelectedRange(),s=i.from,a=i.to,l=s.col,u=a.col;u>l||(l=a.col,u=s.col),l>this.currentCol||this.currentCol>u?this.selectedCols.push(this.currentCol):(0,v.rangeEach)(l,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=o+"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,n=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=n-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 n=t.getAttribute("colspan");!t||null!==n&&1!==n||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)},n=function(n,o){var r=e.hot.runHooks("beforeColumnResize",n,e.newSize,!0);void 0!==r&&(e.newSize=r),"all"===e.hot.getSettings().stretchH?e.clearManualSize(n):e.setManualSize(n,e.newSize),o&&t(),e.saveManualColumnWidths(),e.hot.runHooks("afterColumnResize",n,e.newSize,!0)};if(this.dblclick>=2){this.selectedCols.length>1?((0,g.arrayEach)(this.selectedCols,function(e){n(e)}),t()):(0,g.arrayEach)(this.selectedCols,function(e){n(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,n=function(){t.hot.forceFullRender=!0,t.hot.view.render(),t.hot.view.wt.wtOverlays.adjustElementsSize(!0)},o=function(e,o){t.hot.runHooks("beforeColumnResize",e,t.newSize),o&&n(),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){o(e)}),n()):(0,g.arrayEach)(this.selectedCols,function(e){o(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 n=this.manualColumnWidths[t];return void 0===n&&(n=e),n}},{key:"onBeforeColumnResize",value:function(){this.hot.view.wt.wtViewport.hasOversizedColumnHeadersMarked={}}}]),t}(c.default);(0,m.registerPlugin)("manualColumnResize",y),t.default=y},function(e,t,n){"use strict";function o(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 a=function(){function e(e,t){for(var n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),l=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(o)},u=n(14),c=o(u),h=n(8),d=o(h),f=n(2),p=n(0),g=n(5),v=n(4),m=o(v),y=n(6),w=n(421),C=o(w),b=n(422),E=o(b),_=n(423),S=o(_),O=n(13);n(424),d.default.getSingleton().register("beforeRowMove"),d.default.getSingleton().register("afterRowMove"),d.default.getSingleton().register("unmodifyRow");var T=new WeakMap,R=function(e){function t(e){r(this,t);var n=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return T.set(n,{rowsToMove:[],pressed:void 0,disallowMoving:void 0,target:{eventPageY:void 0,coords:void 0,TD:void 0,row:void 0}}),n.removedRows=[],n.rowsMapper=new C.default(n),n.eventManager=new m.default(n),n.backlight=new E.default(e),n.guideline=new S.default(e),n}return s(t,e),a(t,[{key:"isEnabled",value:function(){return!!this.hot.getSettings().manualRowMove}},{key:"enablePlugin",value:function(){var e=this;this.enabled||(this.addHook("beforeOnCellMouseDown",function(t,n,o,r){return e.onBeforeOnCellMouseDown(t,n,o,r)}),this.addHook("beforeOnCellMouseOver",function(t,n,o,r){return e.onBeforeOnCellMouseOver(t,n,o,r)}),this.addHook("afterScrollHorizontally",function(){return e.onAfterScrollHorizontally()}),this.addHook("modifyRow",function(t,n){return e.onModifyRow(t,n)}),this.addHook("beforeRemoveRow",function(t,n){return e.onBeforeRemoveRow(t,n)}),this.addHook("afterRemoveRow",function(){return e.onAfterRemoveRow()}),this.addHook("afterCreateRow",function(t,n){return e.onAfterCreateRow(t,n)}),this.addHook("afterLoadData",function(){return e.onAfterLoadData()}),this.addHook("beforeColumnSort",function(t,n){return e.onBeforeColumnSort(t,n)}),this.addHook("unmodifyRow",function(t){return e.onUnmodifyRow(t)}),this.registerEvents(),(0,p.addClass)(this.hot.rootElement,"ht__manualRowMove"),l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{key:"updatePlugin",value:function(){this.disablePlugin(),this.enablePlugin(),this.onAfterPluginsInitialized(),l(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(),l(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 n=this,o=T.get(this);o.disallowMoving=!1===this.hot.runHooks("beforeRowMove",e,t),o.disallowMoving||((0,f.arrayEach)(e,function(e,t,o){o[t]=n.rowsMapper.getValueByIndex(e)}),(0,f.arrayEach)(e,function(e,o){var r=n.rowsMapper.getIndexByValue(e);r!==t&&n.rowsMapper.moveRow(r,t+o)}),this.rowsMapper.clearNull()),this.hot.runHooks("afterRowMove",e,t)}},{key:"changeSelection",value:function(e,t){var n=this.hot.selection,o=this.hot.countCols()-1;n.setRangeStartOnly(new O.CellCoords(e,0)),n.setRangeEnd(new O.CellCoords(t,o),!1)}},{key:"getRowsHeight",value:function(e,t){for(var n=0,o=e;t>o;o++){n+=this.hot.view.wt.wtTable.getRowHeight(o)||23}return n}},{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 n=e.from,o=e.to,r=Math.min(n.row,o.row),i=Math.max(n.row,o.row);return(0,g.rangeEach)(r,i,function(e){t.push(e)}),t}},{key:"refreshPositions",value:function(){var e=T.get(this),t=e.target.coords,n=this.hot.view.wt.wtTable.getFirstVisibleRow(),o=this.hot.view.wt.wtTable.getLastVisibleRow(),r=this.hot.getSettings().fixedRowsTop,i=this.hot.countRows();r>t.row&&n>0&&this.hot.scrollViewportTo(n-1),t.row>=o&&i>o&&this.hot.scrollViewportTo(o+1,void 0,!0);var s=this.hot.view.wt.wtTable,a=e.target.TD,l=(0,p.offset)(this.hot.rootElement),u=this.hot.view.THEAD.offsetHeight+this.getRowsHeight(0,t.row),c=e.target.eventPageY-l.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=n>0?n-1:n:a.offsetHeight/2+u>c?e.target.row=t.row:(e.target.row=t.row+1,u+=0===t.row?a.offsetHeight-1:a.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 n=e-t;this.rowsMapper.insertItems(t,n)}else if(t>e){var o=e-1,r=[];(0,f.arrayEach)(this.rowsMapper._arrayMap,function(e,t){e>o&&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){T.get(this).disallowMoving=void 0!==t}},{key:"onBeforeOnCellMouseDown",value:function(e,t,n,o){var r=this.hot.view.wt.wtTable,i=this.hot.selection.selectedHeader.rows,s=this.hot.getSelectedRange(),a=T.get(this);if(!s||!i||a.pressed||0!==e.button)return a.pressed=!1,a.rowsToMove.length=0,void(0,p.removeClass)(this.hot.rootElement,["on-moving--rows","show-ui"]);var l=this.guideline.isBuilt()&&!this.guideline.isAppended(),u=this.backlight.isBuilt()&&!this.backlight.isAppended();l&&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"),a.pressed=!1,a.rowsToMove.length=0;else{o.row=!0,a.pressed=!0,a.target.eventPageY=e.pageY,a.target.coords=t,a.target.TD=n,a.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=T.get(this);if(t.pressed){if(e.realTarget===this.backlight.element){var n=this.backlight.getSize().height;this.backlight.setSize(null,0),setTimeout(function(){this.backlight.setPosition(null,n)})}t.target.eventPageY=e.pageY,this.refreshPositions()}}},{key:"onBeforeOnCellMouseOver",value:function(e,t,n,o){var r=this.hot.getSelectedRange(),i=T.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"),o.row=!0,o.column=!0,o.cell=!0,i.target.coords=t,i.target.TD=n)}},{key:"onMouseUp",value:function(){var e=T.get(this),t=e.target.row,n=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"),n>=1&&void 0!==t&&-1>=e.rowsToMove.indexOf(t)&&e.rowsToMove[n-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[n-1]))}e.rowsToMove.length=0}}},{key:"onAfterScrollHorizontally",value:function(){var e=this.hot.view.wt.wtTable,t=this.hot.view.wt.wtViewport.getRowHeaderWidth(),n=e.holder.scrollLeft,o=t+n;this.backlight.setPosition(null,o),this.backlight.setSize(e.hider.offsetWidth-o)}},{key:"onAfterCreateRow",value:function(e,t){this.rowsMapper.shiftItems(e,t)}},{key:"onBeforeRemoveRow",value:function(e,t){var n=this;this.removedRows.length=0,!1!==e&&(0,g.rangeEach)(e,e+t-1,function(e){n.removedRows.push(n.hot.runHooks("modifyRow",e,n.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 n=this.rowsMapper.getValueByIndex(e);e=null===n?e:n}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(),l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}}]),t}(c.default);(0,y.registerPlugin)("ManualRowMove",R),t.default=R},function(e,t,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=n(296),s=function(e){return e&&e.__esModule?e:{default:e}}(i),a=n(2),l=n(1),u=n(5),c=function(){function e(t){o(this,e),this.manualRowMove=t}return r(e,[{key:"createMap",value:function(e){var t=this,n=void 0===e?this._arrayMap.length:e;this._arrayMap.length=0,(0,u.rangeEach)(n-1,function(e){t._arrayMap[e]=e})}},{key:"destroy",value:function(){this._arrayMap=null}},{key:"moveRow",value:function(e,t){var n=this._arrayMap[e];this._arrayMap[e]=null,this._arrayMap.splice(t,0,n)}},{key:"clearNull",value:function(){this._arrayMap=(0,a.arrayFilter)(this._arrayMap,function(e){return null!==e})}}]),e}();(0,l.mixin)(c,s.default),t.default=c},function(e,t,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),a=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(o)},l=n(298),u=function(e){return e&&e.__esModule?e:{default:e}}(l),c=n(0);t.default=function(e){function t(){return o(this,t),r(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return i(t,e),s(t,[{key:"build",value:function(){a(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,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),a=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(o)},l=n(298),u=function(e){return e&&e.__esModule?e:{default:e}}(l),c=n(0);t.default=function(e){function t(){return o(this,t),r(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return i(t,e),s(t,[{key:"build",value:function(){a(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,n){"use strict";function o(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 a=function(){function e(e,t){for(var n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),l=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(o)},u=n(14),c=o(u),h=n(0),d=n(4),f=o(d),p=n(11),g=n(2),v=n(5),m=n(6),y=function(e){function t(e){r(this,t);var n=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.currentTH=null,n.currentRow=null,n.selectedRows=[],n.currentHeight=null,n.newSize=null,n.startY=null,n.startHeight=null,n.startOffset=null,n.handle=document.createElement("DIV"),n.guide=document.createElement("DIV"),n.eventManager=new f.default(n),n.pressed=null,n.dblclick=0,n.autoresizeTimeout=null,n.manualRowHeights=[],(0,h.addClass)(n.handle,"manualRowResizer"),(0,h.addClass)(n.guide,"manualRowResizerGuide"),n}return s(t,e),a(t,[{key:"isEnabled",value:function(){return this.hot.getSettings().manualRowResize}},{key:"enablePlugin",value:function(){var e=this;if(!this.enabled){this.manualRowHeights=[];var n=this.hot.getSettings().manualRowResize,o=this.loadManualRowHeights();this.manualRowHeights=void 0!==o?o:Array.isArray(n)?n:[],this.addHook("modifyRowHeight",function(t,n){return e.onModifyRowHeight(t,n)}),this.bindEvents(),l(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(){l(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 n=this.hot.view.wt.wtTable.getCoords(e).row,o=(0,h.outerWidth)(this.currentTH);if(n>=0){var r=this.currentTH.getBoundingClientRect();if(this.currentRow=n,this.selectedRows=[],this.hot.selection.isSelected()&&this.hot.selection.selectedHeader.rows){var i=this.hot.getSelectedRange(),s=i.from,a=i.to,l=s.row,u=a.row;u>l||(l=a.row,u=s.row),l>this.currentRow||this.currentRow>u?this.selectedRows.push(this.currentRow):(0,v.rangeEach)(l,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=o+"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,n=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=n-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)},n=function(n,o){var r=e.hot.runHooks("beforeRowResize",n,e.newSize,!0);void 0!==r&&(e.newSize=r),e.setManualSize(n,e.newSize),o&&t(),e.hot.runHooks("afterRowResize",n,e.newSize,!0)};if(this.dblclick>=2){this.selectedRows.length>1?((0,g.arrayEach)(this.selectedRows,function(e){n(e)}),t()):(0,g.arrayEach)(this.selectedRows,function(e){n(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,n=function(){t.hot.forceFullRender=!0,t.hot.view.render(),t.hot.view.wt.wtOverlays.adjustElementsSize(!0)},o=function(e,o){t.hot.runHooks("beforeRowResize",e,t.newSize),o&&n(),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){o(e)}),n()):(0,g.arrayEach)(this.selectedRows,function(e){o(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 n=this.hot.getPlugin("autoRowSize"),o=n?n.heights[t]:null;t=this.hot.runHooks("modifyRow",t);var r=this.manualRowHeights[t];if(void 0!==r&&(r===o||r>(e||0)))return r}return e}}]),t}(c.default);(0,m.registerPlugin)("manualRowResize",y),t.default=y},function(e,t,n){"use strict";function o(){var e=[];return e.getInfo=function(e,t){for(var n=0,o=this.length;o>n;n++)if(!(this[n].row>e||e>this[n].row+this[n].rowspan-1||this[n].col>t||t>this[n].col+this[n].colspan-1))return this[n]},e.setInfo=function(e){for(var t=0,n=this.length;n>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 n=0,o=this.length;o>n;n++)if(this[n].row===e&&this[n].col===t){this.splice(n,1);break}},e}function r(e){if(this.mergedCellInfoCollection=new o,Array.isArray(e))for(var t=0,n=e.length;n>t;t++)this.mergedCellInfoCollection.setInfo(e[t])}function i(e,t){if(this.getSettings().mergeCells&&!this.selection.isMultiple()){var n=this.mergeCells.mergedCellInfoCollection.getInfo(e[0],e[1]);n&&(e[0]=n.row,e[1]=n.col,e[2]=n.row+n.rowspan-1,e[3]=n.col+n.colspan-1)}}function s(e,t){this.mergeCells&&this.mergeCells.shiftCollection("right",e,t)}function a(e,t){this.mergeCells&&this.mergeCells.shiftCollection("left",e,t)}function l(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=n(8),h=function(e){return e&&e.__esModule?e:{default:e}}(c),d=n(11),f=n(13),p=n(7),g=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}(p);r.prototype.canMergeRange=function(e){return!e.isSingle()},r.prototype.mergeRange=function(e){if(this.canMergeRange(e)){var t=e.getTopLeftCorner(),n=e.getBottomRightCorner(),o={};o.row=t.row,o.col=t.col,o.rowspan=n.row-t.row+1,o.colspan=n.col-t.col+1,this.mergedCellInfoCollection.setInfo(o)}},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,n){var o=this.mergedCellInfoCollection.getInfo(t,n);o?o.row===t&&o.col===n?(e.setAttribute("rowspan",o.rowspan),e.setAttribute("colspan",o.colspan)):(e.removeAttribute("rowspan"),e.removeAttribute("colspan"),e.style.display="none"):(e.removeAttribute("rowspan"),e.removeAttribute("colspan"))},r.prototype.modifyTransform=function(e,t,n){var o={row:n.row,col:n.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),a=0,l=this.mergedCellInfoCollection.length;l>a;a++){var u=this.mergedCellInfoCollection[a];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)),o.row=this.lastDesiredCoords.row?this.lastDesiredCoords.row-i.row:o.row,o.col=this.lastDesiredCoords.col?this.lastDesiredCoords.col-i.col:o.col,n.row>0?o.row=s.row+s.rowspan-1-i.row+n.row:0>n.row&&(o.row=i.row-s.row+n.row),n.col>0?o.col=s.col+s.colspan-1-i.col+n.col:0>n.col&&(o.col=i.col-s.col+n.col)}r=new f.CellCoords(t.highlight.row+o.row,t.highlight.col+o.col);var d=this.mergedCellInfoCollection.getInfo(r.row,r.col);d&&(this.lastDesiredCoords=r,o={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)}(o);var E=function(e,t){return t.row>=e.row&&e.row+e.rowspan-1>=t.row}(v,r),_=function(e,t){return t.col>=e.col&&e.col+e.colspan-1>=t.col}(v,r);t.includesRange(w)&&(w.includes(r)||E||_)&&(E&&(0>o.row?o.row-=v.rowspan-1:o.row>0&&(o.row+=v.rowspan-1)),_&&(0>o.col?o.col-=v.colspan-1:o.col>0&&(o.col+=v.colspan-1)))}0!==o.row&&(n.row=o.row),0!==o.col&&(n.col=o.col)},r.prototype.shiftCollection=function(e,t,n){var o=[0,0];switch(e){case"right":o[0]+=1;break;case"left":o[0]-=1;break;case"down":o[1]+=1;break;case"up":o[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+=o[0]):t>i.row||(i.row+=o[1])}};var v=function(){var e=this,t=e.getSettings().mergeCells;t&&(e.mergeCells||(e.mergeCells=new r(t)))},m=function(){var e=this;e.mergeCells&&(e.view.wt.wtTable.getCell=function(t){if(e.getSettings().mergeCells){var n=e.mergeCells.mergedCellInfoCollection.getInfo(t.row,t.col);n&&(t=n)}return f.Table.prototype.getCell.call(this,t)})},y=function(){var e=this,t=e.getSettings().mergeCells;if(t)if(e.mergeCells){if(e.mergeCells.mergedCellInfoCollection=new o,Array.isArray(t))for(var n=0,i=t.length;i>n;n++)e.mergeCells.mergedCellInfoCollection.setInfo(t[n])}else e.mergeCells=new r(t);else e.mergeCells&&(e.mergeCells.mergedCellInfoCollection=new o)},w=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))}},C=function(e){this.getSettings().mergeCells&&(e.items.push({name:"---------"}),e.items.push({key:"mergeCells",name:function(){var e=this.getSelected();return this.getTranslatedPhrase(this.mergeCells.mergedCellInfoCollection.getInfo(e[0],e[1])?g.CONTEXTMENU_ITEMS_UNMERGE_CELLS:g.CONTEXTMENU_ITEMS_MERGE_CELLS)},callback:function(){this.mergeCells.mergeOrUnmergeSelection(this.getSelectedRange()),this.render()},disabled:function(){return this.selection.selectedHeader.corner}}))},b=function(e,t,n,o,r,i){this.mergeCells&&this.mergeCells.applySpanProperties(e,t,n)},E=function(e){return function(t){if(this.getSettings().mergeCells){var n=this.getSelectedRange();if(this.mergeCells.modifyTransform(e,n,t),"modifyTransformEnd"===e){var o=this.countRows(),r=this.countCols();0>n.from.row?n.from.row=0:n.from.row>0&&n.from.row>=o&&(n.from.row=n.from-1),0>n.from.col?n.from.col=0:n.from.col>0&&n.from.col>=r&&(n.from.col=r-1)}}}},_=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 n=!1;do{n=!1;for(var o=0,r=this.mergeCells.mergedCellInfoCollection.length;r>o;o++){var i=this.mergeCells.mergedCellInfoCollection[o],s=new f.CellCoords(i.row,i.col),a=new f.CellCoords(i.row+i.rowspan-1,i.col+i.colspan-1);t.expandByRange(new f.CellRange(s,s,a))&&(e.row=t.to.row,e.col=t.to.col,n=!0)}}while(n)}},S=function(e,t){if(t&&"area"==t){if(this.getSettings().mergeCells)for(var n=this.getSelectedRange(),o=new f.CellRange(n.from,n.from,n.from),r=new f.CellRange(n.to,n.to,n.to),i=0,s=this.mergeCells.mergedCellInfoCollection.length;s>i;i++){var a=this.mergeCells.mergedCellInfoCollection[i],l=new f.CellCoords(a.row,a.col),u=new f.CellCoords(a.row+a.rowspan-1,a.col+a.colspan-1),c=new f.CellRange(l,l,u);o.expandByRange(c)&&(e[0]=o.from.row,e[1]=o.from.col),r.expandByRange(c)&&(e[2]=r.from.row,e[3]=r.from.col)}}},O=function(e,t,n){if(this.getSettings().mergeCells){var o=this.mergeCells.mergedCellInfoCollection.getInfo(e,t);!o||o.row==e&&o.col==t||(n.copyable=!1)}},T=function e(t){if(this.getSettings().mergeCells)for(var n,o=this.countCols(),r=0;o>r;r++){if((n=this.mergeCells.mergedCellInfoCollection.getInfo(t.startRow,r))&&t.startRow>n.row)return t.startRow=n.row,e.call(this,t);if(n=this.mergeCells.mergedCellInfoCollection.getInfo(t.endRow,r)){var i=n.row+n.rowspan-1;if(i>t.endRow)return t.endRow=i,e.call(this,t)}}},R=function e(t){if(this.getSettings().mergeCells)for(var n,o=this.countRows(),r=0;o>r;r++){if((n=this.mergeCells.mergedCellInfoCollection.getInfo(r,t.startColumn))&&t.startColumn>n.col)return t.startColumn=n.col,e.call(this,t);if(n=this.mergeCells.mergedCellInfoCollection.getInfo(r,t.endColumn)){var i=n.col+n.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,n=this.getSelectedRange();for(var o in t)if(n.highlight.row==t[o].row&&n.highlight.col==t[o].col&&n.to.row==t[o].row+t[o].rowspan-1&&n.to.col==t[o].col+t[o].colspan-1)return!1}return e},M=h.default.getSingleton();M.add("beforeInit",v),M.add("afterInit",m),M.add("afterUpdateSettings",y),M.add("beforeKeyDown",w),M.add("modifyTransformStart",E("modifyTransformStart")),M.add("modifyTransformEnd",E("modifyTransformEnd")),M.add("beforeSetRangeEnd",_),M.add("beforeDrawBorders",S),M.add("afterIsMultipleSelection",k),M.add("afterRenderer",b),M.add("afterContextMenuDefaultOptions",C),M.add("afterGetCellMeta",O),M.add("afterViewportRowCalculatorOverride",T),M.add("afterViewportColumnCalculatorOverride",R),M.add("modifyAutofillRange",i),M.add("afterCreateCol",s),M.add("afterRemoveCol",a),M.add("afterCreateRow",l),M.add("afterRemoveRow",u),t.default=r},function(e,t,n){"use strict";function o(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 a=function(){function e(e,t){for(var n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),l=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(o)},u=n(8),c=(o(u),n(0)),h=n(27),d=n(14),f=o(d),p=n(4),g=o(p),v=n(6),m=n(13),y=function(e){function t(e){r(this,t);var n=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.dragged=[],n.eventManager=null,n.lastSetCell=null,n}return s(t,e),a(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(),l(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 n=t.dragged.indexOf(e);if(-1==n)return!1;0===n?t.dragged=t.dragged.slice(0,1):1==n&&(t.dragged=t.dragged.slice(-1))}var t=this;this.eventManager.addEventListener(this.hot.rootElement,"touchstart",function(e){var n=void 0;return(0,c.hasClass)(e.target,"topLeftSelectionHandle-HitArea")?(n=t.hot.getSelectedRange(),t.dragged.push("topLeft"),t.touchStartRange={width:n.getWidth(),height:n.getHeight(),direction:n.getDirection()},e.preventDefault(),!1):(0,c.hasClass)(e.target,"bottomRightSelectionHandle-HitArea")?(n=t.hot.getSelectedRange(),t.dragged.push("bottomRight"),t.touchStartRange={width:n.getWidth(),height:n.getHeight(),direction:n.getDirection()},e.preventDefault(),!1):void 0}),this.eventManager.addEventListener(this.hot.rootElement,"touchend",function(n){return(0,c.hasClass)(n.target,"topLeftSelectionHandle-HitArea")?(e.call(t,"topLeft"),t.touchStartRange=void 0,n.preventDefault(),!1):(0,c.hasClass)(n.target,"bottomRightSelectionHandle-HitArea")?(e.call(t,"bottomRight"),t.touchStartRange=void 0,n.preventDefault(),!1):void 0}),this.eventManager.addEventListener(this.hot.rootElement,"touchmove",function(e){var n=(0,c.getWindowScrollTop)(),o=(0,c.getWindowScrollLeft)(),r=void 0,i=void 0,s=void 0,a=void 0,l=void 0,u=void 0,h=void 0;0!==t.dragged.length&&(r=document.elementFromPoint(e.touches[0].screenX-o,e.touches[0].screenY-n))&&r!==t.lastSetCell&&("TD"!=r.nodeName&&"TH"!=r.nodeName||(i=t.hot.getCoords(r),-1==i.col&&(i.col=0),s=t.hot.getSelectedRange(),a=s.getWidth(),l=s.getHeight(),u=s.getDirection(),1==a&&1==l&&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,n,o,r){var i=e.getTopLeftCorner(),s=e.getBottomRightCorner(),a=e.getBottomLeftCorner(),l=e.getTopRightCorner(),u={start:null,end:null};switch(n){case"NE-SW":switch(o){case"NE-SW":case"NW-SE":u="topLeft"==r?{start:new m.CellCoords(t.row,e.highlight.col),end:new m.CellCoords(a.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(o){case"NE-SW":"topLeft"==r?u={start:t,end:a}: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:l}:u.end=t}break;case"SW-NE":switch(o){case"NW-SE":u="bottomRight"==r?{start:new m.CellCoords(t.row,i.col),end:new m.CellCoords(a.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,l.col),end:new m.CellCoords(i.row,t.col)}:"topLeft"==r&&(u={start:a,end:t})}break;case"SE-NW":switch(o){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,n){"use strict";function o(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 a=function(){function e(e,t){for(var n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),l=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(o)},u=n(14),c=o(u),h=n(299),d=(o(h),n(429)),f=o(d),p=n(2),g=n(6),v=function(e){function t(e){r(this,t);var n=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.observer=null,n}return s(t,e),a(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,n){return e.onAfterTableAlter(n)}),this.addHook("afterLoadData",function(t){return e.onAfterLoadData(t)}),l(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()),l(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"onDataChange",value:function(e){var t=this;if(!this.observer.isPaused()){var n=this.pluginName+".change",o={add:function(e){isNaN(e.col)?t.hot.runHooks("afterCreateRow",e.row,1,n):t.hot.runHooks("afterCreateCol",e.col,1,n)},remove:function(e){isNaN(e.col)?t.hot.runHooks("afterRemoveRow",e.row,1,n):t.hot.runHooks("afterRemoveCol",e.col,1,n)},replace:function(e){t.hot.runHooks("afterChange",[e.row,e.col,null,e.value],n)}};(0,p.arrayEach)(e,function(e){o[e.op]&&o[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()),l(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,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),s=n(299),a=o(s),l=n(89),u=o(l),c=n(1),h=n(430),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&&a.default.unobserve(this.observedData,this.observer),this.observedData=e,this.observer=a.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(){a.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,n){"use strict";function o(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 n=i(t,3),o=n[1],r=n[2];return{row:parseInt(o,10),col:/^\d*$/.test(r)?parseInt(r,10):r}}t.__esModule=!0;var i=function(){function e(e,t){var n=[],o=!0,r=!1,i=void 0;try{for(var s,a=e[Symbol.iterator]();!(o=(s=a.next()).done)&&(n.push(s.value),!t||n.length!==t);o=!0);}catch(e){r=!0,i=e}finally{try{!o&&a.return&&a.return()}finally{if(r)throw i}}return n}return function(t,n){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}();t.cleanPatches=o,t.parsePath=r;var s=n(2)},function(e,t,n){"use strict";function o(e){var t,n=function(){window.localStorage[e+"__persistentStateKeys"]=JSON.stringify(t)},o=function(){t=[],n()};!function(){var n=window.localStorage[e+"__persistentStateKeys"],o="string"==typeof n?JSON.parse(n):void 0;t=o||[]}(),this.saveValue=function(o,r){window.localStorage[e+"_"+o]=JSON.stringify(r),-1==t.indexOf(o)&&(t.push(o),n())},this.loadValue=function(t,n){t=void 0===t?n:t;var o=window.localStorage[e+"_"+t];return void 0===o?void 0:JSON.parse(o)},this.reset=function(t){window.localStorage.removeItem(e+"_"+t)},this.resetAll=function(){for(var n=0;t.length>n;n++)window.localStorage.removeItem(e+"_"+t[n]);o()}}function r(){function e(){var e=this;for(var t in r)(0,a.hasOwnProperty)(r,t)&&e.addHook(t,r[t])}function t(){var e=this;for(var t in r)(0,a.hasOwnProperty)(r,t)&&e.removeHook(t,r[t])}var n=this;this.init=function(){var r=this,i=r.getSettings().persistentState;if(!(n.enabled=!!i))return void t.call(r);r.storage||(r.storage=new o(r.rootElement.id)),r.resetState=n.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:n.saveValue,persistentStateLoad:n.loadValue,persistentStateReset:n.resetValue};for(var i in r)(0,a.hasOwnProperty)(r,i)&&s.default.getSingleton().register(i)}t.__esModule=!0;var i=n(8),s=function(e){return e&&e.__esModule?e:{default:e}}(i),a=(n(6),n(1)),l=new r;s.default.getSingleton().add("beforeInit",l.init),s.default.getSingleton().add("afterUpdateSettings",l.init),t.default=r},function(e,t,n){"use strict";function o(e){this.query=function(t,n,r){var i=e.countRows(),s=e.countCols(),a=[];n||(n=o.global.getDefaultCallback()),r||(r=o.global.getDefaultQueryMethod());for(var l=0;i>l;l++)for(var u=0;s>u;u++){var c=e.getDataAtCell(l,u),h=e.getCellMeta(l,u),d=h.search.callback||n,f=h.search.queryMethod||r,p=f(t,c);if(p){var g={row:l,col:u,data:c};a.push(g)}d&&d(e,l,u,c,p)}return a}}function r(e,t,n,r,i,a,l){var c=null!==l.search&&"object"==s(l.search)&&l.search.searchResultClass||o.global.getDefaultSearchResultClass();l.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 o(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},a=n(8),l=function(e){return e&&e.__esModule?e:{default:e}}(a),u=n(0),c=n(9);o.DEFAULT_CALLBACK=function(e,t,n,o,r){e.getCellMeta(t,n).isSearchResult=r},o.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()))},o.DEFAULT_SEARCH_RESULT_CLASS="htSearchResult",o.global=function(){var e=o.DEFAULT_CALLBACK,t=o.DEFAULT_QUERY_METHOD,n=o.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 n},setDefaultSearchResultClass:function(e){n=e}}}();var h=(0,c.getRenderer)("base");(0,c.registerRenderer)("base",function(e,t,n,o,i,s,a){h.apply(this,arguments),r.apply(this,arguments)}),l.default.getSingleton().add("afterInit",i),l.default.getSingleton().add("afterUpdateSettings",i),t.default=o},function(e,t,n){"use strict";function o(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 n=0;t.length>n;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),a=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var s=r.get;if(void 0!==s)return s.call(o)},l=n(0),u=n(2),c=n(14),h=function(e){return e&&e.__esModule?e:{default:e}}(c),d=n(6),f=n(35),p=function(e){function t(e){o(this,t);var n=r(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.scrollbars=[],n.clones=[],n.lockedCollection=!1,n.freezeOverlays=!1,n}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(),a(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{key:"updatePlugin",value:function(){this.lockedCollection=!1,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:"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,n=e.bottomOverlay,o=e.leftOverlay,r=e.topLeftCornerOverlay,i=e.bottomLeftCornerOverlay;this.lockedCollection=!0,this.scrollbars.length=0,this.scrollbars.push(t),n.clone&&this.scrollbars.push(n),this.scrollbars.push(o),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),n.needFullRender&&this.clones.push(n.clone.wtTable.holder.parentNode),o.needFullRender&&this.clones.push(o.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,l.addClass)(e,"hide-tween")})}},{key:"onAfterMomentumScroll",value:function(){var e=this;this.freezeOverlays=!1,(0,u.arrayEach)(this.clones,function(e){(0,l.removeClass)(e,"hide-tween"),(0,l.addClass)(e,"show-tween")}),setTimeout(function(){(0,u.arrayEach)(e.clones,function(e){(0,l.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,n){"use strict";function o(e){var t=this;this.instance=e,this.doneActions=[],this.undoneActions=[],this.ignoreNewActions=!1,e.addHook("afterChange",function(e,n){e&&"UndoRedo.undo"!==n&&"UndoRedo.redo"!==n&&t.done(new o.ChangeAction(e))}),e.addHook("afterCreateRow",function(e,n,r){if("UndoRedo.undo"!==r&&"UndoRedo.undo"!==r&&"auto"!==r){var i=new o.CreateRowAction(e,n);t.done(i)}}),e.addHook("beforeRemoveRow",function(e,n,r,i){if("UndoRedo.undo"!==i&&"UndoRedo.redo"!==i&&"auto"!==i){var s=t.instance.getSourceDataArray();e=(s.length+e)%s.length;var a=(0,f.deepClone)(s.slice(e,e+n));t.done(new o.RemoveRowAction(e,a))}}),e.addHook("afterCreateCol",function(e,n,r){"UndoRedo.undo"!==r&&"UndoRedo.redo"!==r&&"auto"!==r&&t.done(new o.CreateColumnAction(e,n))}),e.addHook("beforeRemoveCol",function(n,r,i,s){if("UndoRedo.undo"!==s&&"UndoRedo.redo"!==s&&"auto"!==s){var a=t.instance.getSourceDataArray();n=(t.instance.countCols()+n)%t.instance.countCols();var l=[],u=[],c=[];(0,d.rangeEach)(a.length-1,function(t){var o=[],i=a[t];(0,d.rangeEach)(n,n+(r-1),function(t){o.push(i[e.runHooks("modifyCol",t)])}),l.push(o)}),(0,d.rangeEach)(r-1,function(t){c.push(e.runHooks("modifyCol",n+t))}),Array.isArray(e.getSettings().colHeaders)&&(0,d.rangeEach)(r-1,function(t){u.push(e.getSettings().colHeaders[e.runHooks("modifyCol",n+t)]||null)});var h=t.instance.getPlugin("manualColumnMove"),f=h.isEnabled()?h.columnsMapper.__arrayMap:[],p=new o.RemoveColumnAction(n,c,l,u,f);t.done(p)}}),e.addHook("beforeCellAlignment",function(e,n,r,i){var s=new o.CellAlignmentAction(e,n,r,i);t.done(s)}),e.addHook("beforeFilter",function(e){t.done(new o.FiltersAction(e))}),e.addHook("beforeRowMove",function(e,n){!1!==e&&t.done(new o.RowMoveAction(e,n))})}function r(){var e=this;void 0===e.getSettings().undo||e.getSettings().undo?e.undoRedo||(e.undoRedo=new o(e),a(e),e.addHook("beforeKeyDown",i),e.addHook("afterChange",s)):e.undoRedo&&(delete e.undoRedo,l(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 n=this;if("loadData"===t)return n.undoRedo.clear()}function a(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 l(e){delete e.undo,delete e.redo,delete e.isUndoAvailable,delete e.isRedoAvailable,delete e.clearUndo}t.__esModule=!0;var u=n(8),c=function(e){return e&&e.__esModule?e:{default:e}}(u),h=n(2),d=n(5),f=n(1),p=n(11),g=n(13);o.prototype.done=function(e){this.ignoreNewActions||(this.doneActions.push(e),this.undoneActions.length=0)},o.prototype.undo=function(){if(this.isUndoAvailable()){var e=this.doneActions.pop(),t=(0,f.deepClone)(e),n=this.instance;if(!1===n.runHooks("beforeUndo",t))return;this.ignoreNewActions=!0;var o=this;e.undo(this.instance,function(){o.ignoreNewActions=!1,o.undoneActions.push(e)}),n.runHooks("afterUndo",t)}},o.prototype.redo=function(){if(this.isRedoAvailable()){var e=this.undoneActions.pop(),t=(0,f.deepClone)(e),n=this.instance;if(!1===n.runHooks("beforeRedo",t))return;this.ignoreNewActions=!0;var o=this;e.redo(this.instance,function(){o.ignoreNewActions=!1,o.doneActions.push(e)}),n.runHooks("afterRedo",t)}},o.prototype.isUndoAvailable=function(){return this.doneActions.length>0},o.prototype.isRedoAvailable=function(){return this.undoneActions.length>0},o.prototype.clear=function(){this.doneActions.length=0,this.undoneActions.length=0},o.Action=function(){},o.Action.prototype.undo=function(){},o.Action.prototype.redo=function(){},o.ChangeAction=function(e){this.changes=e,this.actionType="change"},(0,f.inherit)(o.ChangeAction,o.Action),o.ChangeAction.prototype.undo=function(e,t){for(var n=(0,f.deepClone)(this.changes),o=e.countEmptyRows(!0),r=e.countEmptyCols(!0),i=0,s=n.length;s>i;i++)n[i].splice(3,1);e.addHookOnce("afterChange",t),e.setDataAtRowProp(n,null,null,"UndoRedo.undo");for(var a=0,l=n.length;l>a;a++)e.getSettings().minSpareRows&&n[a][0]+1+e.getSettings().minSpareRows===e.countRows()&&o==e.getSettings().minSpareRows&&(e.alter("remove_row",parseInt(n[a][0]+1,10),e.getSettings().minSpareRows),e.undoRedo.doneActions.pop()),e.getSettings().minSpareCols&&n[a][1]+1+e.getSettings().minSpareCols===e.countCols()&&r==e.getSettings().minSpareCols&&(e.alter("remove_col",parseInt(n[a][1]+1,10),e.getSettings().minSpareCols),e.undoRedo.doneActions.pop())},o.ChangeAction.prototype.redo=function(e,t){for(var n=(0,f.deepClone)(this.changes),o=0,r=n.length;r>o;o++)n[o].splice(2,1);e.addHookOnce("afterChange",t),e.setDataAtRowProp(n,null,null,"UndoRedo.redo")},o.CreateRowAction=function(e,t){this.index=e,this.amount=t,this.actionType="insert_row"},(0,f.inherit)(o.CreateRowAction,o.Action),o.CreateRowAction.prototype.undo=function(e,t){var n=e.countRows(),o=e.getSettings().minSpareRows;this.index>=n&&n>this.index-o&&(this.index-=o),e.addHookOnce("afterRemoveRow",t),e.alter("remove_row",this.index,this.amount,"UndoRedo.undo")},o.CreateRowAction.prototype.redo=function(e,t){e.addHookOnce("afterCreateRow",t),e.alter("insert_row",this.index,this.amount,"UndoRedo.redo")},o.RemoveRowAction=function(e,t){this.index=e,this.data=t,this.actionType="remove_row"},(0,f.inherit)(o.RemoveRowAction,o.Action),o.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")},o.RemoveRowAction.prototype.redo=function(e,t){e.addHookOnce("afterRemoveRow",t),e.alter("remove_row",this.index,this.data.length,"UndoRedo.redo")},o.CreateColumnAction=function(e,t){this.index=e,this.amount=t,this.actionType="insert_col"},(0,f.inherit)(o.CreateColumnAction,o.Action),o.CreateColumnAction.prototype.undo=function(e,t){e.addHookOnce("afterRemoveCol",t),e.alter("remove_col",this.index,this.amount,"UndoRedo.undo")},o.CreateColumnAction.prototype.redo=function(e,t){e.addHookOnce("afterCreateCol",t),e.alter("insert_col",this.index,this.amount,"UndoRedo.redo")},o.RemoveColumnAction=function(e,t,n,o,r){this.index=e,this.indexes=t,this.data=n,this.amount=this.data[0].length,this.headers=o,this.columnPositions=r.slice(0),this.actionType="remove_col"},(0,f.inherit)(o.RemoveColumnAction,o.Action),o.RemoveColumnAction.prototype.undo=function(e,t){var n=this,o=void 0,r=this.indexes.slice(0).sort(),i=function(e,t,o){return o[n.indexes.indexOf(r[t])]},s=[];(0,d.rangeEach)(this.data.length-1,function(e){s[e]=(0,h.arrayMap)(n.data[e],i)});var a=[];a=(0,h.arrayMap)(this.headers,i);var l=[];e.runHooks("beforeCreateCol",this.indexes[0],this.indexes[this.indexes.length-1],"UndoRedo.undo"),(0,d.rangeEach)(this.data.length-1,function(t){o=e.getSourceDataAtRow(t),(0,d.rangeEach)(r.length-1,function(e){o.splice(r[e],0,s[t][e]),l.push([t,r[e],null,s[t][e]])})}),e.getPlugin("formulas")&&e.getPlugin("formulas").onAfterSetDataAtCell(l),void 0!==this.headers&&(0,d.rangeEach)(a.length-1,function(t){e.getSettings().colHeaders.splice(r[t],0,a[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()},o.RemoveColumnAction.prototype.redo=function(e,t){e.addHookOnce("afterRemoveCol",t),e.alter("remove_col",this.index,this.amount,"UndoRedo.redo")},o.CellAlignmentAction=function(e,t,n,o){this.stateBefore=e,this.range=t,this.type=n,this.alignment=o},o.CellAlignmentAction.prototype.undo=function(e,t){if(e.getPlugin("contextMenu").isEnabled()){for(var n=this.range.from.row;this.range.to.row>=n;n++)for(var o=this.range.from.col;this.range.to.col>=o;o++)e.setCellMeta(n,o,"className",this.stateBefore[n][o]||" htLeft");e.addHookOnce("afterRender",t),e.render()}},o.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())},o.FiltersAction=function(e){this.conditionsStack=e,this.actionType="filter"},(0,f.inherit)(o.FiltersAction,o.Action),o.FiltersAction.prototype.undo=function(e,t){var n=e.getPlugin("filters");e.addHookOnce("afterRender",t),n.conditionCollection.importAllConditions(this.conditionsStack.slice(0,this.conditionsStack.length-1)),n.filter()},o.FiltersAction.prototype.redo=function(e,t){var n=e.getPlugin("filters");e.addHookOnce("afterRender",t),n.conditionCollection.importAllConditions(this.conditionsStack),n.filter()},o.RowMoveAction=function(e,t){this.rows=e.slice(),this.target=t},(0,f.inherit)(o.RowMoveAction,o.Action),o.RowMoveAction.prototype.undo=function(e,t){var n=e.getPlugin("manualRowMove");e.addHookOnce("afterRender",t);for(var o=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+o,a=o;s>a;a++)i.push(this.target+a);n.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))},o.RowMoveAction.prototype.redo=function(e,t){var n=e.getPlugin("manualRowMove");e.addHookOnce("afterRender",t),n.moveRows(this.rows.slice(),this.target),e.render();var o=this.target>this.rows[0]?this.target-this.rows.length:this.target;e.selection.setRangeStartOnly(new g.CellCoords(o,0)),e.selection.setRangeEnd(new g.CellCoords(o+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"),t.default=o}]).default});</script>
<script>/*!
* numbro.js language configuration
* language : Bulgarian
* author : Tim McIntosh (StayinFront NZ)
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'bg',
cultureCode: 'bg',
delimiters: {
thousands: ' ',
decimal: ','
},
abbreviations: {
thousand: 'И',
million: 'А',
billion: 'M',
trillion: 'T'
},
ordinal: function () {
return '.';
},
currency: {
symbol: 'лв.'
}
};
// Node
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
this.numbro.culture('bg', language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Czech
* locale: Czech Republic
* author : Jan Pesa : https://github.com/smajl (based on work from Anatoli Papirovski : https://github.com/apapirovski)
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'cs-CZ',
cultureCode: 'cs-CZ',
delimiters: {
thousands: '\u00a0',
decimal: ','
},
abbreviations: {
thousand: 'tis.',
million: 'mil.',
billion: 'mld.',
trillion: 'bil.'
},
ordinal: function () {
return '.';
},
currency: {
symbol: 'Kč',
position: 'postfix',
spaceSeparated: true
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Danish
* locale: Denmark
* author : Michael Storgaard : https://github.com/mstorgaard
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'da-DK',
cultureCode: 'da-DK',
delimiters: {
thousands: '.',
decimal: ','
},
abbreviations: {
thousand: 'k',
million: 'mio',
billion: 'mia',
trillion: 'b'
},
ordinal: function () {
return '.';
},
currency: {
symbol: 'kr',
position: 'postfix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : German
* locale: Austria
* author : Tim McIntosh (StayinFront NZ)
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'de-AT',
cultureCode: 'de-AT',
delimiters: {
thousands: ' ',
decimal: ','
},
abbreviations: {
thousand: 'k',
million: 'm',
billion: 'b',
trillion: 't'
},
ordinal: function () {
return '.';
},
currency: {
symbol: '€'
}
};
// Node
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : German
* locale: Switzerland
* author : Michael Piefel : https://github.com/piefel (based on work from Marco Krage : https://github.com/sinky)
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'de-CH',
cultureCode: 'de-CH',
delimiters: {
thousands: '\'',
decimal: '.'
},
abbreviations: {
thousand: 'k',
million: 'm',
billion: 'b',
trillion: 't'
},
ordinal: function () {
return '.';
},
currency: {
symbol: 'CHF',
position: 'postfix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : German
* locale: Germany
* author : Marco Krage : https://github.com/sinky
*
* Generally useful in Germany, Austria, Luxembourg, Belgium
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'de-DE',
cultureCode: 'de-DE',
delimiters: {
thousands: '.',
decimal: ','
},
abbreviations: {
thousand: 'k',
million: 'm',
billion: 'b',
trillion: 't'
},
ordinal: function () {
return '.';
},
currency: {
symbol: '€',
position: 'postfix',
spaceSeparated: true
},
defaults: {
currencyFormat: ',4'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : German
* locale: Liechtenstein
* author : Michael Piefel : https://github.com/piefel (based on work from Marco Krage : https://github.com/sinky)
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'de-LI',
cultureCode: 'de-LI',
delimiters: {
thousands: '\'',
decimal: '.'
},
abbreviations: {
thousand: 'k',
million: 'm',
billion: 'b',
trillion: 't'
},
ordinal: function () {
return '.';
},
currency: {
symbol: 'CHF',
position: 'postfix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Greek (el)
* author : Tim McIntosh (StayinFront NZ)
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'el',
cultureCode: 'el',
delimiters: {
thousands: '.',
decimal: ','
},
abbreviations: {
thousand: 'χ',
million: 'ε',
billion: 'δ',
trillion: 'τ'
},
ordinal: function () {
return '.';
},
currency: {
symbol: '€'
}
};
// Node
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture('el', language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : English
* locale: Australia
* author : Benedikt Huss : https://github.com/ben305
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'en-AU',
cultureCode: 'en-AU',
delimiters: {
thousands: ',',
decimal: '.'
},
abbreviations: {
thousand: 'k',
million: 'm',
billion: 'b',
trillion: 't'
},
ordinal: function (number) {
var b = number % 10;
return (~~ (number % 100 / 10) === 1) ? 'th' :
(b === 1) ? 'st' :
(b === 2) ? 'nd' :
(b === 3) ? 'rd' : 'th';
},
currency: {
symbol: '$',
position: 'prefix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: '$ ,0.00',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: '$ ,0'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : English
* locale: United Kingdom of Great Britain and Northern Ireland
* author : Dan Ristic : https://github.com/dristic
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'en-GB',
cultureCode: 'en-GB',
delimiters: {
thousands: ',',
decimal: '.'
},
abbreviations: {
thousand: 'k',
million: 'm',
billion: 'b',
trillion: 't'
},
ordinal: function (number) {
var b = number % 10;
return (~~ (number % 100 / 10) === 1) ? 'th' :
(b === 1) ? 'st' :
(b === 2) ? 'nd' :
(b === 3) ? 'rd' : 'th';
},
currency: {
symbol: '£',
position: 'prefix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: '$ ,0.00',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: '$ ,0'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
+ * numbro.js language configuration
* language : English
* locale: Ireland
* author : Tim McIntosh (StayinFront NZ)
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'en-IE',
cultureCode: 'en-IE',
delimiters: {
thousands: ',',
decimal: '.'
},
abbreviations: {
thousand: 'k',
million: 'm',
billion: 'b',
trillion: 't'
},
ordinal: function (number) {
var b = number % 10;
return (~~(number % 100 / 10) === 1) ? 'th' :
(b === 1) ? 'st' :
(b === 2) ? 'nd' :
(b === 3) ? 'rd' : 'th';
},
currency: {
symbol: '€'
}
};
// Node
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture('en-gb', language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : English
* locale: New Zealand
* author : Benedikt Huss : https://github.com/ben305
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'en-NZ',
cultureCode: 'en-NZ',
delimiters: {
thousands: ',',
decimal: '.'
},
abbreviations: {
thousand: 'k',
million: 'm',
billion: 'b',
trillion: 't'
},
ordinal: function (number) {
var b = number % 10;
return (~~ (number % 100 / 10) === 1) ? 'th' :
(b === 1) ? 'st' :
(b === 2) ? 'nd' :
(b === 3) ? 'rd' : 'th';
},
currency: {
symbol: '$',
position: 'prefix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: '$ ,0.00',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: '$ ,0'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : English
* locale: South Africa
* author : Stewart Scott https://github.com/stewart42
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'en-ZA',
cultureCode: 'en-ZA',
delimiters: {
thousands: ' ',
decimal: ','
},
abbreviations: {
thousand: 'k',
million: 'm',
billion: 'b',
trillion: 't'
},
ordinal: function (number) {
var b = number % 10;
return (~~ (number % 100 / 10) === 1) ? 'th' :
(b === 1) ? 'st' :
(b === 2) ? 'nd' :
(b === 3) ? 'rd' : 'th';
},
currency: {
symbol: 'R',
position: 'prefix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: '$ ,0.00',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: '$ ,0'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Spanish
* locale: Argentina
* author : Hernan Garcia : https://github.com/hgarcia
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'es-AR',
cultureCode: 'es-AR',
delimiters: {
thousands: '.',
decimal: ','
},
abbreviations: {
thousand: 'k',
million: 'mm',
billion: 'b',
trillion: 't'
},
ordinal: function (number) {
var b = number % 10;
return (b === 1 || b === 3) ? 'er' :
(b === 2) ? 'do' :
(b === 7 || b === 0) ? 'mo' :
(b === 8) ? 'vo' :
(b === 9) ? 'no' : 'to';
},
currency: {
symbol: '$',
position: 'postfix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Spanish
* locale: Chile
* author : Gwyn Judd : https://github.com/gwynjudd
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'es-CL',
cultureCode: 'es-CL',
delimiters: {
thousands: '.',
decimal: ','
},
abbreviations: {
thousand: 'k',
million: 'mm',
billion: 'b',
trillion: 't'
},
ordinal: function (number) {
var b = number % 10;
return (b === 1 || b === 3) ? 'er' :
(b === 2) ? 'do' :
(b === 7 || b === 0) ? 'mo' :
(b === 8) ? 'vo' :
(b === 9) ? 'no' : 'to';
},
currency: {
symbol: '$',
position: 'prefix'
},
defaults: {
currencyFormat: '$0,0'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Spanish
* locale: Colombia
* author : Gwyn Judd : https://github.com/gwynjudd
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'es-CO',
cultureCode: 'es-CO',
delimiters: {
thousands: '.',
decimal: ','
},
abbreviations: {
thousand: 'k',
million: 'mm',
billion: 'b',
trillion: 't'
},
ordinal: function (number) {
var b = number % 10;
return (b === 1 || b === 3) ? 'er' :
(b === 2) ? 'do' :
(b === 7 || b === 0) ? 'mo' :
(b === 8) ? 'vo' :
(b === 9) ? 'no' : 'to';
},
currency: {
symbol: '€',
position: 'postfix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Spanish
* locale: Costa Rica
* author : Gwyn Judd : https://github.com/gwynjudd
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'es-CR',
cultureCode: 'es-CR',
delimiters: {
thousands: ' ',
decimal: ','
},
abbreviations: {
thousand: 'k',
million: 'mm',
billion: 'b',
trillion: 't'
},
ordinal: function (number) {
var b = number % 10;
return (b === 1 || b === 3) ? 'er' :
(b === 2) ? 'do' :
(b === 7 || b === 0) ? 'mo' :
(b === 8) ? 'vo' :
(b === 9) ? 'no' : 'to';
},
currency: {
symbol: '₡',
position: 'postfix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Spanish
* locale: Spain
* author : Hernan Garcia : https://github.com/hgarcia
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'es-ES',
cultureCode: 'es-ES',
delimiters: {
thousands: '.',
decimal: ','
},
abbreviations: {
thousand: 'k',
million: 'mm',
billion: 'b',
trillion: 't'
},
ordinal: function (number) {
var b = number % 10;
return (b === 1 || b === 3) ? 'er' :
(b === 2) ? 'do' :
(b === 7 || b === 0) ? 'mo' :
(b === 8) ? 'vo' :
(b === 9) ? 'no' : 'to';
},
currency: {
symbol: '€',
position: 'postfix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Spanish
* locale: Nicaragua
* author : Gwyn Judd : https://github.com/gwynjudd
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'es-NI',
cultureCode: 'es-NI',
delimiters: {
thousands: ',',
decimal: '.'
},
abbreviations: {
thousand: 'k',
million: 'mm',
billion: 'b',
trillion: 't'
},
ordinal: function (number) {
var b = number % 10;
return (b === 1 || b === 3) ? 'er' :
(b === 2) ? 'do' :
(b === 7 || b === 0) ? 'mo' :
(b === 8) ? 'vo' :
(b === 9) ? 'no' : 'to';
},
currency: {
symbol: 'C$',
position: 'prefix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Spanish
* locale: Peru
* author : Gwyn Judd : https://github.com/gwynjudd
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'es-PE',
cultureCode: 'es-PE',
delimiters: {
thousands: ',',
decimal: '.'
},
abbreviations: {
thousand: 'k',
million: 'mm',
billion: 'b',
trillion: 't'
},
ordinal: function (number) {
var b = number % 10;
return (b === 1 || b === 3) ? 'er' :
(b === 2) ? 'do' :
(b === 7 || b === 0) ? 'mo' :
(b === 8) ? 'vo' :
(b === 9) ? 'no' : 'to';
},
currency: {
symbol: 'S/.',
position: 'prefix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Spanish
* locale: Puerto Rico
* author : Gwyn Judd : https://github.com/gwynjudd
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'es-PR',
cultureCode: 'es-PR',
delimiters: {
thousands: ',',
decimal: '.'
},
abbreviations: {
thousand: 'k',
million: 'mm',
billion: 'b',
trillion: 't'
},
ordinal: function (number) {
var b = number % 10;
return (b === 1 || b === 3) ? 'er' :
(b === 2) ? 'do' :
(b === 7 || b === 0) ? 'mo' :
(b === 8) ? 'vo' :
(b === 9) ? 'no' : 'to';
},
currency: {
symbol: '$',
position: 'prefix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Spanish
* locale: El Salvador
* author : Gwyn Judd : https://github.com/gwynjudd
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'es-SV',
cultureCode: 'es-SV',
delimiters: {
thousands: ',',
decimal: '.'
},
abbreviations: {
thousand: 'k',
million: 'mm',
billion: 'b',
trillion: 't'
},
ordinal: function (number) {
var b = number % 10;
return (b === 1 || b === 3) ? 'er' :
(b === 2) ? 'do' :
(b === 7 || b === 0) ? 'mo' :
(b === 8) ? 'vo' :
(b === 9) ? 'no' : 'to';
},
currency: {
symbol: '$',
position: 'prefix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Estonian
* locale: Estonia
* author : Illimar Tambek : https://github.com/ragulka
*
* Note: in Estonian, abbreviations are always separated
* from numbers with a space
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'et-EE',
cultureCode: 'et-EE',
delimiters: {
thousands: ' ',
decimal: ','
},
abbreviations: {
thousand: ' tuh',
million: ' mln',
billion: ' mld',
trillion: ' trl'
},
ordinal: function () {
return '.';
},
currency: {
symbol: '€',
position: 'postfix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Farsi
* locale: Iran
* author : neo13 : https://github.com/neo13
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'fa-IR',
cultureCode: 'fa-IR',
delimiters: {
thousands: '،',
decimal: '.'
},
abbreviations: {
thousand: 'هزار',
million: 'میلیون',
billion: 'میلیارد',
trillion: 'تریلیون'
},
ordinal: function () {
return 'ام';
},
currency: {
symbol: '﷼'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Finnish
* locale: Finland
* author : Sami Saada : https://github.com/samitheberber
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'fi-FI',
cultureCode: 'fi-FI',
delimiters: {
thousands: ' ',
decimal: ','
},
abbreviations: {
thousand: 'k',
million: 'M',
billion: 'G',
trillion: 'T'
},
ordinal: function () {
return '.';
},
currency: {
symbol: '€',
position: 'postfix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Filipino (Pilipino)
* locale: Philippines
* author : Michael Abadilla : https://github.com/mjmaix
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'fil-PH',
cultureCode: 'fil-PH',
delimiters: {
thousands: ',',
decimal: '.'
},
abbreviations: {
thousand: 'k',
million: 'm',
billion: 'b',
trillion: 't'
},
ordinal: function (number) {
var b = number % 10;
return (~~ (number % 100 / 10) === 1) ? 'th' :
(b === 1) ? 'st' :
(b === 2) ? 'nd' :
(b === 3) ? 'rd' : 'th';
},
currency: {
symbol: '₱'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : French
* locale: Canada
* author : Léo Renaud-Allaire : https://github.com/renaudleo
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'fr-CA',
cultureCode: 'fr-CA',
delimiters: {
thousands: ' ',
decimal: ','
},
abbreviations: {
thousand: 'k',
million: 'M',
billion: 'G',
trillion: 'T'
},
ordinal : function (number) {
return number === 1 ? 'er' : 'ème';
},
currency: {
symbol: '$',
position: 'postfix',
spaceSeparated : true
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: '$ ,0.00',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: '$ ,0'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : French
* locale: Switzerland
* author : Adam Draper : https://github.com/adamwdraper
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'fr-CH',
cultureCode: 'fr-CH',
delimiters: {
thousands: ' ',
decimal: '.'
},
abbreviations: {
thousand: 'k',
million: 'm',
billion: 'b',
trillion: 't'
},
ordinal : function (number) {
return number === 1 ? 'er' : 'ème';
},
currency: {
symbol: 'CHF',
position: 'postfix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : French
* locale: France
* author : Adam Draper : https://github.com/adamwdraper
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'fr-FR',
cultureCode: 'fr-FR',
delimiters: {
thousands: ' ',
decimal: ','
},
abbreviations: {
thousand: 'k',
million: 'm',
billion: 'b',
trillion: 't'
},
ordinal : function (number) {
return number === 1 ? 'er' : 'ème';
},
currency: {
symbol: '€',
position: 'postfix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Hebrew
* locale : IL
* author : Eli Zehavi : https://github.com/eli-zehavi
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'he-IL',
cultureCode: 'he-IL',
delimiters: {
thousands: ',',
decimal: '.'
},
abbreviations: {
thousand: 'אלף',
million: 'מליון',
billion: 'בליון',
trillion: 'טריליון'
},
currency: {
symbol: '₪',
position: 'prefix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: '₪ ,0.00',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: '₪ ,0'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Hungarian
* locale: Hungary
* author : Peter Bakondy : https://github.com/pbakondy
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'hu-HU',
cultureCode: 'hu-HU',
delimiters: {
thousands: ' ',
decimal: ','
},
abbreviations: {
thousand: 'E', // ezer
million: 'M', // millió
billion: 'Mrd', // milliárd
trillion: 'T' // trillió
},
ordinal: function () {
return '.';
},
currency: {
symbol: ' Ft',
position: 'postfix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Indonesian
* author : Tim McIntosh (StayinFront NZ)
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'id',
cultureCode: 'id',
delimiters: {
thousands: ',',
decimal: '.'
},
abbreviations: {
thousand: 'r',
million: 'j',
billion: 'm',
trillion: 't'
},
ordinal: function () {
return '.';
},
currency: {
symbol: 'Rp'
}
};
// Node
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture('id', language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Italian
* locale: Switzerland
* author : Tim McIntosh (StayinFront NZ)
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'it-CH',
cultureCode: 'it-CH',
delimiters: {
thousands: '\'',
decimal: '.'
},
abbreviations: {
thousand: 'mila',
million: 'mil',
billion: 'b',
trillion: 't'
},
ordinal: function () {
return '°';
},
currency: {
symbol: 'CHF'
}
};
// Node
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture('it-CH', language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Italian
* locale: Italy
* author : Giacomo Trombi : http://cinquepunti.it
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'it-IT',
cultureCode: 'it-IT',
delimiters: {
thousands: '.',
decimal: ','
},
abbreviations: {
thousand: 'mila',
million: 'mil',
billion: 'b',
trillion: 't'
},
ordinal: function () {
return 'º';
},
currency: {
symbol: '€',
position: 'postfix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Japanese
* locale: Japan
* author : teppeis : https://github.com/teppeis
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'ja-JP',
cultureCode: 'ja-JP',
delimiters: {
thousands: ',',
decimal: '.'
},
abbreviations: {
thousand: '千',
million: '百万',
billion: '十億',
trillion: '兆'
},
ordinal: function () {
return '.';
},
currency: {
symbol: '¥',
position: 'prefix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: '$ ,0.00',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: '$ ,0'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Korean
* author (numbro.js Version): Randy Wilander : https://github.com/rocketedaway
* author (numeral.js Version) : Rich Daley : https://github.com/pedantic-git
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'ko-KR',
cultureCode: 'ko-KR',
delimiters: {
thousands: ',',
decimal: '.'
},
abbreviations: {
thousand: '천',
million: '백만',
billion: '십억',
trillion: '일조'
},
ordinal: function () {
return '.';
},
currency: {
symbol: '₩'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Latvian
* locale: Latvia
* author : Lauris Bukšis-Haberkorns : https://github.com/Lafriks
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'lv-LV',
cultureCode: 'lv-LV',
delimiters: {
thousands: ' ',
decimal: ','
},
abbreviations: {
thousand: ' tūkst.',
million: ' milj.',
billion: ' mljrd.',
trillion: ' trilj.'
},
ordinal: function () {
return '.';
},
currency: {
symbol: '€',
position: 'postfix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language: Norwegian Bokmål
* locale: Norway
* author : Benjamin Van Ryseghem
*/
(function() {
'use strict';
var language = {
langLocaleCode: 'nb-NO',
cultureCode: 'nb-NO',
delimiters: {
thousands: ' ',
decimal: ','
},
abbreviations: {
thousand: 't',
million: 'M',
billion: 'md',
trillion: 't'
},
currency: {
symbol: 'kr',
position: 'postfix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Norwegian Bokmål (nb)
* author : Tim McIntosh (StayinFront NZ)
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'nb',
cultureCode: 'nb',
delimiters: {
thousands: ' ',
decimal: ','
},
abbreviations: {
thousand: 't',
million: 'mil',
billion: 'mia',
trillion: 'b'
},
ordinal: function () {
return '.';
},
currency: {
symbol: 'kr'
}
};
// Node
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture('nb', language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Dutch
* locale: Belgium
* author : Dieter Luypaert : https://github.com/moeriki
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'nl-BE',
cultureCode: 'nl-BE',
delimiters: {
thousands: ' ',
decimal : ','
},
abbreviations: {
thousand : 'k',
million : 'mln',
billion : 'mld',
trillion : 'bln'
},
ordinal : function (number) {
var remainder = number % 100;
return (number !== 0 && remainder <= 1 || remainder === 8 || remainder >= 20) ? 'ste' : 'de';
},
currency: {
symbol: '€',
position: 'postfix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Dutch
* locale: Netherlands
* author : Dave Clayton : https://github.com/davedx
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'nl-NL',
cultureCode: 'nl-NL',
delimiters: {
thousands: '.',
decimal : ','
},
abbreviations: {
thousand : 'k',
million : 'mln',
billion : 'mrd',
trillion : 'bln'
},
ordinal : function (number) {
var remainder = number % 100;
return (number !== 0 && remainder <= 1 || remainder === 8 || remainder >= 20) ? 'ste' : 'de';
},
currency: {
symbol: '€',
position: 'postfix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Norwegian Nynorsk (nn)
* author : Tim McIntosh (StayinFront NZ)
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'nn',
cultureCode: 'nn',
delimiters: {
thousands: ' ',
decimal: ','
},
abbreviations: {
thousand: 't',
million: 'mil',
billion: 'mia',
trillion: 'b'
},
ordinal: function () {
return '.';
},
currency: {
symbol: 'kr'
}
};
// Node
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.language) {
window.numbro.language('nn', language);
}
}());
/*!
* numbro.js language configuration
* language : Polish
* locale : Poland
* author : Dominik Bulaj : https://github.com/dominikbulaj
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'pl-PL',
cultureCode: 'pl-PL',
delimiters: {
thousands: ' ',
decimal: ','
},
abbreviations: {
thousand: 'tys.',
million: 'mln',
billion: 'mld',
trillion: 'bln'
},
ordinal: function () {
return '.';
},
currency: {
symbol: ' zł',
position: 'postfix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Portuguese
* locale : Brazil
* author : Ramiro Varandas Jr : https://github.com/ramirovjr
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'pt-BR',
cultureCode: 'pt-BR',
delimiters: {
thousands: '.',
decimal: ','
},
abbreviations: {
thousand: 'mil',
million: 'milhões',
billion: 'b',
trillion: 't'
},
ordinal: function () {
return 'º';
},
currency: {
symbol: 'R$',
position: 'prefix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Portuguese
* locale : Portugal
* author : Diogo Resende : https://github.com/dresende
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'pt-PT',
cultureCode: 'pt-PT',
delimiters: {
thousands: ' ',
decimal: ','
},
abbreviations: {
thousand: 'k',
million: 'm',
billion: 'b',
trillion: 't'
},
ordinal : function () {
return 'º';
},
currency: {
symbol: '€',
position: 'postfix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numeral.js language configuration
* language : Romanian
* author : Andrei Alecu https://github.com/andreialecu
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'ro-RO',
cultureCode: 'ro-RO',
delimiters: {
thousands: '.',
decimal: ','
},
abbreviations: {
thousand: 'mii',
million: 'mil',
billion: 'mld',
trillion: 'bln'
},
ordinal: function () {
return '.';
},
currency: {
symbol: ' lei',
position: 'postfix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Romanian (ro)
* author : Tim McIntosh (StayinFront NZ)
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'ro',
cultureCode: 'ro',
delimiters: {
thousands: '.',
decimal: ','
},
abbreviations: {
thousand: 'mie',
million: 'mln',
billion: 'mld',
trillion: 't'
},
ordinal: function () {
return '.';
},
currency: {
symbol: 'RON'
}
};
// Node
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture('ro', language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Russian
* locale : Russsia
* author : Anatoli Papirovski : https://github.com/apapirovski
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'ru-RU',
cultureCode: 'ru-RU',
delimiters: {
thousands: ' ',
decimal: ','
},
abbreviations: {
thousand: 'тыс.',
million: 'млн',
billion: 'b',
trillion: 't'
},
ordinal: function () {
// not ideal, but since in Russian it can taken on
// different forms (masculine, feminine, neuter)
// this is all we can do
return '.';
},
currency: {
symbol: 'руб.',
position: 'postfix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Russian
* locale : Ukraine
* author : Anatoli Papirovski : https://github.com/apapirovski
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'ru-UA',
cultureCode: 'ru-UA',
delimiters: {
thousands: ' ',
decimal: ','
},
abbreviations: {
thousand: 'тыс.',
million: 'млн',
billion: 'b',
trillion: 't'
},
ordinal: function () {
// not ideal, but since in Russian it can taken on
// different forms (masculine, feminine, neuter)
// this is all we can do
return '.';
},
currency: {
symbol: '\u20B4',
position: 'postfix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Slovak
* locale : Slovakia
* author : Jan Pesa : https://github.com/smajl (based on work from Ahmed Al Hafoudh : http://www.freevision.sk)
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'sk-SK',
cultureCode: 'sk-SK',
delimiters: {
thousands: '\u00a0',
decimal: ','
},
abbreviations: {
thousand: 'tis.',
million: 'mil.',
billion: 'mld.',
trillion: 'bil.'
},
ordinal: function () {
return '.';
},
currency: {
symbol: '€',
position: 'postfix',
spaceSeparated: true
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Slovene
* locale: Slovenia
* author : Tim McIntosh (StayinFront NZ)
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'sl',
cultureCode: 'sl',
delimiters: {
thousands: '.',
decimal: ','
},
abbreviations: {
thousand: 'tis.',
million: 'mil.',
billion: 'b',
trillion: 't'
},
ordinal: function () {
return '.';
},
currency: {
symbol: '€'
}
};
// Node
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture('sl', language);
}
}());
/*!
* numbro.js language configuration
* language : Serbian (sr)
* country : Serbia (Cyrillic)
* author : Tim McIntosh (StayinFront NZ)
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'sr-Cyrl-RS',
cultureCode: 'sr-Cyrl-RS',
delimiters: {
thousands: '.',
decimal: ','
},
abbreviations: {
thousand: 'тыс.',
million: 'млн',
billion: 'b',
trillion: 't'
},
ordinal: function () {
return '.';
},
currency: {
symbol: 'RSD'
}
};
// Node
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture('sr-Cyrl-RS', language);
}
}());
/*!
* numbro.js language configuration
* language : Swedish
* locale : Sweden
* author : Benjamin Van Ryseghem (benjamin.vanryseghem.com)
*/
(function() {
'use strict';
var language = {
langLocaleCode: 'sv-SE',
cultureCode: 'sv-SE',
delimiters: {
thousands: ' ',
decimal: ','
},
abbreviations: {
thousand: 't',
million: 'M',
billion: 'md',
trillion: 'tmd'
},
currency: {
symbol: 'kr',
position: 'postfix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Thai
* locale : Thailand
* author : Sathit Jittanupat : https://github.com/jojosati
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'th-TH',
cultureCode: 'th-TH',
delimiters: {
thousands: ',',
decimal: '.'
},
abbreviations: {
thousand: 'พัน',
million: 'ล้าน',
billion: 'พันล้าน',
trillion: 'ล้านล้าน'
},
ordinal: function () {
return '.';
},
currency: {
symbol: '฿',
position: 'postfix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Turkish
* locale : Turkey
* author : Ecmel Ercan : https://github.com/ecmel,
* Erhan Gundogan : https://github.com/erhangundogan,
* Burak Yiğit Kaya: https://github.com/BYK
*/
(function() {
'use strict';
var suffixes = {
1: '\'inci',
5: '\'inci',
8: '\'inci',
70: '\'inci',
80: '\'inci',
2: '\'nci',
7: '\'nci',
20: '\'nci',
50: '\'nci',
3: '\'üncü',
4: '\'üncü',
100: '\'üncü',
6: '\'ncı',
9: '\'uncu',
10: '\'uncu',
30: '\'uncu',
60: '\'ıncı',
90: '\'ıncı'
},
language = {
langLocaleCode: 'tr-TR',
cultureCode: 'tr-TR',
delimiters: {
thousands: '.',
decimal: ','
},
abbreviations: {
thousand: 'bin',
million: 'milyon',
billion: 'milyar',
trillion: 'trilyon'
},
ordinal: function(number) {
if (number === 0) { // special case for zero
return '\'ıncı';
}
var a = number % 10,
b = number % 100 - a,
c = number >= 100 ? 100 : null;
return suffixes[a] || suffixes[b] || suffixes[c];
},
currency: {
symbol: '\u20BA',
position: 'postfix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Ukrainian
* locale : Ukraine
* author : Michael Piefel : https://github.com/piefel (with help from Tetyana Kuzmenko)
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'uk-UA',
cultureCode: 'uk-UA',
delimiters: {
thousands: ' ',
decimal: ','
},
abbreviations: {
thousand: 'тис.',
million: 'млн',
billion: 'млрд',
trillion: 'блн'
},
ordinal: function () {
// not ideal, but since in Ukrainian it can taken on
// different forms (masculine, feminine, neuter)
// this is all we can do
return '';
},
currency: {
symbol: '\u20B4',
position: 'postfix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: ',0.00 $',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: ',0 $'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : simplified chinese
* locale : China
* author : badplum : https://github.com/badplum
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'zh-CN',
cultureCode: 'zh-CN',
delimiters: {
thousands: ',',
decimal: '.'
},
abbreviations: {
thousand: '千',
million: '百万',
billion: '十亿',
trillion: '兆'
},
ordinal: function () {
return '.';
},
currency: {
symbol: '¥',
position: 'prefix'
},
defaults: {
currencyFormat: ',4 a'
},
formats: {
fourDigits: '4 a',
fullWithTwoDecimals: '$ ,0.00',
fullWithTwoDecimalsNoCurrency: ',0.00',
fullWithNoDecimals: '$ ,0'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Chinese traditional
* locale: Macau
* author : Tim McIntosh (StayinFront NZ)
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'zh-MO',
cultureCode: 'zh-MO',
delimiters: {
thousands: ',',
decimal: '.'
},
abbreviations: {
thousand: '千',
million: '百萬',
billion: '十億',
trillion: '兆'
},
ordinal: function () {
return '.';
},
currency: {
symbol: 'MOP'
}
};
// Node
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture('zh-MO', language);
}
}());
/*!
* numbro.js language configuration
* language : Chinese simplified
* locale: Singapore
* author : Tim McIntosh (StayinFront NZ)
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'zh-SG',
cultureCode: 'zh-SG',
delimiters: {
thousands: ',',
decimal: '.'
},
abbreviations: {
thousand: '千',
million: '百万',
billion: '十亿',
trillion: '兆'
},
ordinal: function () {
return '.';
},
currency: {
symbol: '$'
}
};
// Node
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture('zh-SG', language);
}
}.call(typeof window === 'undefined' ? this : window));
/*!
* numbro.js language configuration
* language : Chinese (Taiwan)
* author (numbro.js Version): Randy Wilander : https://github.com/rocketedaway
* author (numeral.js Version) : Rich Daley : https://github.com/pedantic-git
*/
(function () {
'use strict';
var language = {
langLocaleCode: 'zh-TW',
cultureCode: 'zh-TW',
delimiters: {
thousands: ',',
decimal: '.'
},
abbreviations: {
thousand: '千',
million: '百萬',
billion: '十億',
trillion: '兆'
},
ordinal: function () {
return '第';
},
currency: {
symbol: 'NT$'
}
};
// CommonJS
if (typeof module !== 'undefined' && module.exports) {
module.exports = language;
}
// Browser
if (typeof window !== 'undefined' && window.numbro && window.numbro.culture) {
window.numbro.culture(language.cultureCode, language);
}
}.call(typeof window === 'undefined' ? this : window));
</script>
<script>/*
chroma.js - JavaScript library for color conversions
Copyright (c) 2011-2017, Gregor Aisch
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
3. The name Gregor Aisch may not be used to endorse or promote products
derived from this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL GREGOR AISCH OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
(function(){var a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,A,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q,R,S,T,U,V,W,X,Y,Z,$,_,aa,ba,ca,da,ea,fa,ga,ha,ia,ja,ka,la,ma,na,oa,pa,qa,ra,sa,ta,ua,va,wa,xa,ya,za,Aa=[].slice;va=function(){var a,b,c,d,e;for(a={},e="Boolean Number String Function Array Date RegExp Undefined Null".split(" "),d=0,b=e.length;d<b;d++)c=e[d],a["[object "+c+"]"]=c.toLowerCase();return function(b){var c;return c=Object.prototype.toString.call(b),a[c]||"object"}}(),S=function(a,b,c){return null==b&&(b=0),null==c&&(c=1),a<b&&(a=b),a>c&&(a=c),a},wa=function(a){return a.length>=3?[].slice.call(a):a[0]},t=function(a){var b,c;for(a._clipped=!1,a._unclipped=a.slice(0),b=c=0;c<3;b=++c)b<3?((a[b]<0||a[b]>255)&&(a._clipped=!0),a[b]<0&&(a[b]=0),a[b]>255&&(a[b]=255)):3===b&&(a[b]<0&&(a[b]=0),a[b]>1&&(a[b]=1));return a._clipped||delete a._unclipped,a},d=Math.PI,qa=Math.round,v=Math.cos,A=Math.floor,_=Math.pow,T=Math.log,sa=Math.sin,ta=Math.sqrt,m=Math.atan2,W=Math.max,l=Math.abs,g=2*d,e=d/3,b=d/180,f=180/d,s=function(){return arguments[0]instanceof a?arguments[0]:function(a,b,c){c.prototype=a.prototype;var d=new c,e=a.apply(d,b);return Object(e)===e?e:d}(a,arguments,function(){})},k=[],"undefined"!=typeof module&&null!==module&&null!=module.exports&&(module.exports=s),"function"==typeof define&&define.amd?define([],function(){return s}):(pa="undefined"!=typeof exports&&null!==exports?exports:this,pa.chroma=s),s.version="1.3.3",j={},h=[],i=!1,a=function(){function a(){var a,b,c,d,e,f,g,k,l;for(f=this,b=[],k=0,d=arguments.length;k<d;k++)null!=(a=arguments[k])&&b.push(a);if(g=b[b.length-1],null!=j[g])f._rgb=t(j[g](wa(b.slice(0,-1))));else{for(i||(h=h.sort(function(a,b){return b.p-a.p}),i=!0),l=0,e=h.length;l<e&&(c=h[l],!(g=c.test.apply(c,b)));l++);g&&(f._rgb=t(j[g].apply(j,b)))}null==f._rgb&&console.warn("unknown format: "+b),null==f._rgb&&(f._rgb=[0,0,0]),3===f._rgb.length&&f._rgb.push(1)}return a.prototype.toString=function(){return this.hex()},a}(),s._input=j,s.brewer=q={OrRd:["#fff7ec","#fee8c8","#fdd49e","#fdbb84","#fc8d59","#ef6548","#d7301f","#b30000","#7f0000"],PuBu:["#fff7fb","#ece7f2","#d0d1e6","#a6bddb","#74a9cf","#3690c0","#0570b0","#045a8d","#023858"],BuPu:["#f7fcfd","#e0ecf4","#bfd3e6","#9ebcda","#8c96c6","#8c6bb1","#88419d","#810f7c","#4d004b"],Oranges:["#fff5eb","#fee6ce","#fdd0a2","#fdae6b","#fd8d3c","#f16913","#d94801","#a63603","#7f2704"],BuGn:["#f7fcfd","#e5f5f9","#ccece6","#99d8c9","#66c2a4","#41ae76","#238b45","#006d2c","#00441b"],YlOrBr:["#ffffe5","#fff7bc","#fee391","#fec44f","#fe9929","#ec7014","#cc4c02","#993404","#662506"],YlGn:["#ffffe5","#f7fcb9","#d9f0a3","#addd8e","#78c679","#41ab5d","#238443","#006837","#004529"],Reds:["#fff5f0","#fee0d2","#fcbba1","#fc9272","#fb6a4a","#ef3b2c","#cb181d","#a50f15","#67000d"],RdPu:["#fff7f3","#fde0dd","#fcc5c0","#fa9fb5","#f768a1","#dd3497","#ae017e","#7a0177","#49006a"],Greens:["#f7fcf5","#e5f5e0","#c7e9c0","#a1d99b","#74c476","#41ab5d","#238b45","#006d2c","#00441b"],YlGnBu:["#ffffd9","#edf8b1","#c7e9b4","#7fcdbb","#41b6c4","#1d91c0","#225ea8","#253494","#081d58"],Purples:["#fcfbfd","#efedf5","#dadaeb","#bcbddc","#9e9ac8","#807dba","#6a51a3","#54278f","#3f007d"],GnBu:["#f7fcf0","#e0f3db","#ccebc5","#a8ddb5","#7bccc4","#4eb3d3","#2b8cbe","#0868ac","#084081"],Greys:["#ffffff","#f0f0f0","#d9d9d9","#bdbdbd","#969696","#737373","#525252","#252525","#000000"],YlOrRd:["#ffffcc","#ffeda0","#fed976","#feb24c","#fd8d3c","#fc4e2a","#e31a1c","#bd0026","#800026"],PuRd:["#f7f4f9","#e7e1ef","#d4b9da","#c994c7","#df65b0","#e7298a","#ce1256","#980043","#67001f"],Blues:["#f7fbff","#deebf7","#c6dbef","#9ecae1","#6baed6","#4292c6","#2171b5","#08519c","#08306b"],PuBuGn:["#fff7fb","#ece2f0","#d0d1e6","#a6bddb","#67a9cf","#3690c0","#02818a","#016c59","#014636"],Viridis:["#440154","#482777","#3f4a8a","#31678e","#26838f","#1f9d8a","#6cce5a","#b6de2b","#fee825"],Spectral:["#9e0142","#d53e4f","#f46d43","#fdae61","#fee08b","#ffffbf","#e6f598","#abdda4","#66c2a5","#3288bd","#5e4fa2"],RdYlGn:["#a50026","#d73027","#f46d43","#fdae61","#fee08b","#ffffbf","#d9ef8b","#a6d96a","#66bd63","#1a9850","#006837"],RdBu:["#67001f","#b2182b","#d6604d","#f4a582","#fddbc7","#f7f7f7","#d1e5f0","#92c5de","#4393c3","#2166ac","#053061"],PiYG:["#8e0152","#c51b7d","#de77ae","#f1b6da","#fde0ef","#f7f7f7","#e6f5d0","#b8e186","#7fbc41","#4d9221","#276419"],PRGn:["#40004b","#762a83","#9970ab","#c2a5cf","#e7d4e8","#f7f7f7","#d9f0d3","#a6dba0","#5aae61","#1b7837","#00441b"],RdYlBu:["#a50026","#d73027","#f46d43","#fdae61","#fee090","#ffffbf","#e0f3f8","#abd9e9","#74add1","#4575b4","#313695"],BrBG:["#543005","#8c510a","#bf812d","#dfc27d","#f6e8c3","#f5f5f5","#c7eae5","#80cdc1","#35978f","#01665e","#003c30"],RdGy:["#67001f","#b2182b","#d6604d","#f4a582","#fddbc7","#ffffff","#e0e0e0","#bababa","#878787","#4d4d4d","#1a1a1a"],PuOr:["#7f3b08","#b35806","#e08214","#fdb863","#fee0b6","#f7f7f7","#d8daeb","#b2abd2","#8073ac","#542788","#2d004b"],Set2:["#66c2a5","#fc8d62","#8da0cb","#e78ac3","#a6d854","#ffd92f","#e5c494","#b3b3b3"],Accent:["#7fc97f","#beaed4","#fdc086","#ffff99","#386cb0","#f0027f","#bf5b17","#666666"],Set1:["#e41a1c","#377eb8","#4daf4a","#984ea3","#ff7f00","#ffff33","#a65628","#f781bf","#999999"],Set3:["#8dd3c7","#ffffb3","#bebada","#fb8072","#80b1d3","#fdb462","#b3de69","#fccde5","#d9d9d9","#bc80bd","#ccebc5","#ffed6f"],Dark2:["#1b9e77","#d95f02","#7570b3","#e7298a","#66a61e","#e6ab02","#a6761d","#666666"],Paired:["#a6cee3","#1f78b4","#b2df8a","#33a02c","#fb9a99","#e31a1c","#fdbf6f","#ff7f00","#cab2d6","#6a3d9a","#ffff99","#b15928"],Pastel2:["#b3e2cd","#fdcdac","#cbd5e8","#f4cae4","#e6f5c9","#fff2ae","#f1e2cc","#cccccc"],Pastel1:["#fbb4ae","#b3cde3","#ccebc5","#decbe4","#fed9a6","#ffffcc","#e5d8bd","#fddaec","#f2f2f2"]},function(){var a,b;b=[];for(a in q)b.push(q[a.toLowerCase()]=q[a]);b}(),xa={aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflower:"#6495ed",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",gold:"#ffd700",goldenrod:"#daa520",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",laserlemon:"#ffff54",lavender:"#e6e6fa",lavenderblush:"#fff0f5",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrod:"#fafad2",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",maroon2:"#7f0000",maroon3:"#b03060",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",purple2:"#7f007f",purple3:"#a020f0",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"},s.colors=xa,N=function(){var a,b,d,e,f,g,h,i,j;return b=wa(arguments),f=b[0],a=b[1],d=b[2],i=(f+16)/116,h=isNaN(a)?i:i+a/500,j=isNaN(d)?i:i-d/200,i=c.Yn*O(i),h=c.Xn*O(h),j=c.Zn*O(j),g=za(3.2404542*h-1.5371385*i-.4985314*j),e=za(-.969266*h+1.8760108*i+.041556*j),d=za(.0556434*h-.2040259*i+1.0572252*j),[g,e,d,b.length>3?b[3]:1]},za=function(a){return 255*(a<=.00304?12.92*a:1.055*_(a,1/2.4)-.055)},O=function(a){return a>c.t1?a*a*a:c.t2*(a-c.t0)},c={Kn:18,Xn:.95047,Yn:1,Zn:1.08883,t0:.137931034,t1:.206896552,t2:.12841855,t3:.008856452},ha=function(){var a,b,c,d,e,f,g,h;return d=wa(arguments),c=d[0],b=d[1],a=d[2],e=ma(c,b,a),f=e[0],g=e[1],h=e[2],[116*g-16,500*(f-g),200*(g-h)]},na=function(a){return(a/=255)<=.04045?a/12.92:_((a+.055)/1.055,2.4)},ya=function(a){return a>c.t3?_(a,1/3):a/c.t2+c.t0},ma=function(){var a,b,d,e,f,g,h;return e=wa(arguments),d=e[0],b=e[1],a=e[2],d=na(d),b=na(b),a=na(a),f=ya((.4124564*d+.3575761*b+.1804375*a)/c.Xn),g=ya((.2126729*d+.7151522*b+.072175*a)/c.Yn),h=ya((.0193339*d+.119192*b+.9503041*a)/c.Zn),[f,g,h]},s.lab=function(){return function(a,b,c){c.prototype=a.prototype;var d=new c,e=a.apply(d,b);return Object(e)===e?e:d}(a,Aa.call(arguments).concat(["lab"]),function(){})},j.lab=N,a.prototype.lab=function(){return ha(this._rgb)},n=function(a){var b,c,d,e,f,g,h,i,j,k,l;return a=function(){var b,c,d;for(d=[],c=0,b=a.length;c<b;c++)e=a[c],d.push(s(e));return d}(),2===a.length?(j=function(){var b,c,d;for(d=[],c=0,b=a.length;c<b;c++)e=a[c],d.push(e.lab());return d}(),f=j[0],g=j[1],b=function(a){var b,c;return c=function(){var c,d;for(d=[],b=c=0;c<=2;b=++c)d.push(f[b]+a*(g[b]-f[b]));return d}(),s.lab.apply(s,c)}):3===a.length?(k=function(){var b,c,d;for(d=[],c=0,b=a.length;c<b;c++)e=a[c],d.push(e.lab());return d}(),f=k[0],g=k[1],h=k[2],b=function(a){var b,c;return c=function(){var c,d;for(d=[],b=c=0;c<=2;b=++c)d.push((1-a)*(1-a)*f[b]+2*(1-a)*a*g[b]+a*a*h[b]);return d}(),s.lab.apply(s,c)}):4===a.length?(l=function(){var b,c,d;for(d=[],c=0,b=a.length;c<b;c++)e=a[c],d.push(e.lab());return d}(),f=l[0],g=l[1],h=l[2],i=l[3],b=function(a){var b,c;return c=function(){var c,d;for(d=[],b=c=0;c<=2;b=++c)d.push((1-a)*(1-a)*(1-a)*f[b]+3*(1-a)*(1-a)*a*g[b]+3*(1-a)*a*a*h[b]+a*a*a*i[b]);return d}(),s.lab.apply(s,c)}):5===a.length&&(c=n(a.slice(0,3)),d=n(a.slice(2,5)),b=function(a){return a<.5?c(2*a):d(2*(a-.5))}),b},s.bezier=function(a){var b;return b=n(a),b.scale=function(){return s.scale(b)},b},s.cubehelix=function(a,b,c,d,e){var f,h,i;return null==a&&(a=300),null==b&&(b=-1.5),null==c&&(c=1),null==d&&(d=1),null==e&&(e=[0,1]),f=0,"array"===va(e)?h=e[1]-e[0]:(h=0,e=[e,e]),i=function(i){var j,k,l,m,n,o,p,q,r;return j=g*((a+120)/360+b*i),p=_(e[0]+h*i,d),o=0!==f?c[0]+i*f:c,k=o*p*(1-p)/2,m=v(j),r=sa(j),q=p+k*(-.14861*m+1.78277*r),n=p+k*(-.29227*m-.90649*r),l=p+k*(1.97294*m),s(t([255*q,255*n,255*l]))},i.start=function(b){return null==b?a:(a=b,i)},i.rotations=function(a){return null==a?b:(b=a,i)},i.gamma=function(a){return null==a?d:(d=a,i)},i.hue=function(a){return null==a?c:(c=a,"array"===va(c)?0===(f=c[1]-c[0])&&(c=c[1]):f=0,i)},i.lightness=function(a){return null==a?e:("array"===va(a)?(e=a,h=a[1]-a[0]):(e=[a,a],h=0),i)},i.scale=function(){return s.scale(i)},i.hue(c),i},s.random=function(){var b,c,d;for(c="0123456789abcdef",b="#",d=0;d<6;++d)b+=c.charAt(A(16*Math.random()));return new a(b)},s.average=function(a,b){var c,e,f,g,h,i,j,k,l,n,o,p,q;null==b&&(b="rgb"),l=a.length,a=a.map(function(a){return s(a)}),j=a.splice(0,1)[0],p=j.get(b),g=[],h=0,i=0;for(k in p)p[k]=p[k]||0,g.push(isNaN(p[k])?0:1),"h"!==b.charAt(k)||isNaN(p[k])||(c=p[k]/180*d,h+=v(c),i+=sa(c));for(e=j.alpha(),o=0,n=a.length;o<n;o++){f=a[o],q=f.get(b),e+=f.alpha();for(k in p)isNaN(q[k])||(p[k]+=q[k],g[k]+=1,"h"===b.charAt(k)&&(c=p[k]/180*d,h+=v(c),i+=sa(c)))}for(k in p)if(p[k]=p[k]/g[k],"h"===b.charAt(k)){for(c=m(i/g[k],h/g[k])/d*180;c<0;)c+=360;for(;c>=360;)c-=360;p[k]=c}return s(p,b).alpha(e/l)},j.rgb=function(){var a,b,c,d;b=wa(arguments),c=[];for(a in b)d=b[a],c.push(d);return c},s.rgb=function(){return function(a,b,c){c.prototype=a.prototype;var d=new c,e=a.apply(d,b);return Object(e)===e?e:d}(a,Aa.call(arguments).concat(["rgb"]),function(){})},a.prototype.rgb=function(a){return null==a&&(a=!0),a?this._rgb.map(Math.round).slice(0,3):this._rgb.slice(0,3)},a.prototype.rgba=function(a){return null==a&&(a=!0),a?[Math.round(this._rgb[0]),Math.round(this._rgb[1]),Math.round(this._rgb[2]),this._rgb[3]]:this._rgb.slice(0)},h.push({p:3,test:function(a){var b;return b=wa(arguments),"array"===va(b)&&3===b.length?"rgb":4===b.length&&"number"===va(b[3])&&b[3]>=0&&b[3]<=1?"rgb":void 0}}),C=function(a){var b,c,d,e,f,g;if(a.match(/^#?([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$/))return 4!==a.length&&7!==a.length||(a=a.substr(1)),3===a.length&&(a=a.split(""),a=a[0]+a[0]+a[1]+a[1]+a[2]+a[2]),g=parseInt(a,16),e=g>>16,d=g>>8&255,c=255&g,[e,d,c,1];if(a.match(/^#?([A-Fa-f0-9]{8})$/))return 9===a.length&&(a=a.substr(1)),g=parseInt(a,16),e=g>>24&255,d=g>>16&255,c=g>>8&255,b=qa((255&g)/255*100)/100,[e,d,c,b];if(null!=j.css&&(f=j.css(a)))return f;throw"unknown color: "+a},da=function(a,b){var c,d,e,f,g,h,i;return null==b&&(b="rgb"),g=a[0],e=a[1],d=a[2],c=a[3],g=Math.round(g),e=Math.round(e),d=Math.round(d),i=g<<16|e<<8|d,h="000000"+i.toString(16),h=h.substr(h.length-6),f="0"+qa(255*c).toString(16),f=f.substr(f.length-2),"#"+function(){switch(b.toLowerCase()){case"rgba":return h+f;case"argb":return f+h;default:return h}}()},j.hex=function(a){return C(a)},s.hex=function(){return function(a,b,c){c.prototype=a.prototype;var d=new c,e=a.apply(d,b);return Object(e)===e?e:d}(a,Aa.call(arguments).concat(["hex"]),function(){})},a.prototype.hex=function(a){return null==a&&(a="rgb"),da(this._rgb,a)},h.push({p:4,test:function(a){if(1===arguments.length&&"string"===va(a))return"hex"}}),F=function(){var a,b,c,d,e,f,g,h,i,j,k,l,m,n;if(a=wa(arguments),e=a[0],k=a[1],g=a[2],0===k)i=d=b=255*g;else{for(n=[0,0,0],c=[0,0,0],m=g<.5?g*(1+k):g+k-g*k,l=2*g-m,e/=360,n[0]=e+1/3,n[1]=e,n[2]=e-1/3,f=h=0;h<=2;f=++h)n[f]<0&&(n[f]+=1),n[f]>1&&(n[f]-=1),6*n[f]<1?c[f]=l+6*(m-l)*n[f]:2*n[f]<1?c[f]=m:3*n[f]<2?c[f]=l+(m-l)*(2/3-n[f])*6:c[f]=l;j=[qa(255*c[0]),qa(255*c[1]),qa(255*c[2])],i=j[0],d=j[1],b=j[2]}return a.length>3?[i,d,b,a[3]]:[i,d,b]},fa=function(a,b,c){var d,e,f,g,h;return void 0!==a&&a.length>=3&&(g=a,a=g[0],b=g[1],c=g[2]),a/=255,b/=255,c/=255,f=Math.min(a,b,c),W=Math.max(a,b,c),e=(W+f)/2,W===f?(h=0,d=Number.NaN):h=e<.5?(W-f)/(W+f):(W-f)/(2-W-f),a===W?d=(b-c)/(W-f):b===W?d=2+(c-a)/(W-f):c===W&&(d=4+(a-b)/(W-f)),d*=60,d<0&&(d+=360),[d,h,e]},s.hsl=function(){return function(a,b,c){c.prototype=a.prototype;var d=new c,e=a.apply(d,b);return Object(e)===e?e:d}(a,Aa.call(arguments).concat(["hsl"]),function(){})},j.hsl=F,a.prototype.hsl=function(){return fa(this._rgb)},G=function(){var a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r;if(a=wa(arguments),e=a[0],p=a[1],r=a[2],r*=255,0===p)i=d=b=r;else switch(360===e&&(e=0),e>360&&(e-=360),e<0&&(e+=360),e/=60,f=A(e),c=e-f,g=r*(1-p),h=r*(1-p*c),q=r*(1-p*(1-c)),f){case 0:j=[r,q,g],i=j[0],d=j[1],b=j[2];break;case 1:k=[h,r,g],i=k[0],d=k[1],b=k[2];break;case 2:l=[g,r,q],i=l[0],d=l[1],b=l[2];break;case 3:m=[g,h,r],i=m[0],d=m[1],b=m[2];break;case 4:n=[q,g,r],i=n[0],d=n[1],b=n[2];break;case 5:o=[r,g,h],i=o[0],d=o[1],b=o[2]}return[i,d,b,a.length>3?a[3]:1]},ga=function(){var a,b,c,d,e,f,g,h,i;return g=wa(arguments),f=g[0],c=g[1],a=g[2],e=Math.min(f,c,a),W=Math.max(f,c,a),b=W-e,i=W/255,0===W?(d=Number.NaN,h=0):(h=b/W,f===W&&(d=(c-a)/b),c===W&&(d=2+(a-f)/b),a===W&&(d=4+(f-c)/b),(d*=60)<0&&(d+=360)),[d,h,i]},s.hsv=function(){return function(a,b,c){c.prototype=a.prototype;var d=new c,e=a.apply(d,b);return Object(e)===e?e:d}(a,Aa.call(arguments).concat(["hsv"]),function(){})},j.hsv=G,a.prototype.hsv=function(){return ga(this._rgb)},Z=function(a){var b,c,d;return"number"===va(a)&&a>=0&&a<=16777215?(d=a>>16,c=a>>8&255,b=255&a,[d,c,b,1]):(console.warn("unknown num color: "+a),[0,0,0,1])},ka=function(){var a,b,c,d;return d=wa(arguments),c=d[0],b=d[1],a=d[2],(c<<16)+(b<<8)+a},s.num=function(b){return new a(b,"num")},a.prototype.num=function(a){return null==a&&(a="rgb"),ka(this._rgb,a)},j.num=Z,h.push({p:1,test:function(a){if(1===arguments.length&&"number"===va(a)&&a>=0&&a<=16777215)return"num"}}),B=function(){var a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t;if(c=wa(arguments),h=c[0],e=c[1],b=c[2],e/=100,g=g/100*255,a=255*e,0===e)l=g=d=b;else switch(360===h&&(h=0),h>360&&(h-=360),h<0&&(h+=360),h/=60,i=A(h),f=h-i,j=b*(1-e),k=j+a*(1-f),s=j+a*f,t=j+a,i){case 0:m=[t,s,j],l=m[0],g=m[1],d=m[2];break;case 1:n=[k,t,j],l=n[0],g=n[1],d=n[2];break;case 2:o=[j,t,s],l=o[0],g=o[1],d=o[2];break;case 3:p=[j,k,t],l=p[0],g=p[1],d=p[2];break;case 4:q=[s,j,t],l=q[0],g=q[1],d=q[2];break;case 5:r=[t,j,k],l=r[0],g=r[1],d=r[2]}return[l,g,d,c.length>3?c[3]:1]},ca=function(){var a,b,c,d,e,f,g,h,i;return i=wa(arguments),h=i[0],e=i[1],b=i[2],g=Math.min(h,e,b),W=Math.max(h,e,b),d=W-g,c=100*d/255,a=g/(255-d)*100,0===d?f=Number.NaN:(h===W&&(f=(e-b)/d),e===W&&(f=2+(b-h)/d),b===W&&(f=4+(h-e)/d),(f*=60)<0&&(f+=360)),[f,c,a]},s.hcg=function(){return function(a,b,c){c.prototype=a.prototype;var d=new c,e=a.apply(d,b);return Object(e)===e?e:d}(a,Aa.call(arguments).concat(["hcg"]),function(){})},j.hcg=B,a.prototype.hcg=function(){return ca(this._rgb)},w=function(a){var b,c,d,e,f,g,h,i;if(a=a.toLowerCase(),null!=s.colors&&s.colors[a])return C(s.colors[a]);if(f=a.match(/rgb\(\s*(\-?\d+),\s*(\-?\d+)\s*,\s*(\-?\d+)\s*\)/)){for(h=f.slice(1,4),e=g=0;g<=2;e=++g)h[e]=+h[e];h[3]=1}else if(f=a.match(/rgba\(\s*(\-?\d+),\s*(\-?\d+)\s*,\s*(\-?\d+)\s*,\s*([01]|[01]?\.\d+)\)/))for(h=f.slice(1,5),e=i=0;i<=3;e=++i)h[e]=+h[e];else if(f=a.match(/rgb\(\s*(\-?\d+(?:\.\d+)?)%,\s*(\-?\d+(?:\.\d+)?)%\s*,\s*(\-?\d+(?:\.\d+)?)%\s*\)/)){for(h=f.slice(1,4),e=b=0;b<=2;e=++b)h[e]=qa(2.55*h[e]);h[3]=1}else if(f=a.match(/rgba\(\s*(\-?\d+(?:\.\d+)?)%,\s*(\-?\d+(?:\.\d+)?)%\s*,\s*(\-?\d+(?:\.\d+)?)%\s*,\s*([01]|[01]?\.\d+)\)/)){for(h=f.slice(1,5),e=c=0;c<=2;e=++c)h[e]=qa(2.55*h[e]);h[3]=+h[3]}else(f=a.match(/hsl\(\s*(\-?\d+(?:\.\d+)?),\s*(\-?\d+(?:\.\d+)?)%\s*,\s*(\-?\d+(?:\.\d+)?)%\s*\)/))?(d=f.slice(1,4),d[1]*=.01,d[2]*=.01,h=F(d),h[3]=1):(f=a.match(/hsla\(\s*(\-?\d+(?:\.\d+)?),\s*(\-?\d+(?:\.\d+)?)%\s*,\s*(\-?\d+(?:\.\d+)?)%\s*,\s*([01]|[01]?\.\d+)\)/))&&(d=f.slice(1,4),d[1]*=.01,d[2]*=.01,h=F(d),h[3]=+f[4]);return h},ba=function(a){var b;return b=a[3]<1?"rgba":"rgb","rgb"===b?b+"("+a.slice(0,3).map(qa).join(",")+")":"rgba"===b?b+"("+a.slice(0,3).map(qa).join(",")+","+a[3]+")":void 0},oa=function(a){return qa(100*a)/100},E=function(a,b){var c;return c=b<1?"hsla":"hsl",a[0]=oa(a[0]||0),a[1]=oa(100*a[1])+"%",a[2]=oa(100*a[2])+"%","hsla"===c&&(a[3]=b),c+"("+a.join(",")+")"},j.css=function(a){return w(a)},s.css=function(){return function(a,b,c){c.prototype=a.prototype;var d=new c,e=a.apply(d,b);return Object(e)===e?e:d}(a,Aa.call(arguments).concat(["css"]),function(){})},a.prototype.css=function(a){return null==a&&(a="rgb"),"rgb"===a.slice(0,3)?ba(this._rgb):"hsl"===a.slice(0,3)?E(this.hsl(),this.alpha()):void 0},j.named=function(a){return C(xa[a])},h.push({p:5,test:function(a){if(1===arguments.length&&null!=xa[a])return"named"}}),a.prototype.name=function(a){var b,c;arguments.length&&(xa[a]&&(this._rgb=C(xa[a])),this._rgb[3]=1),b=this.hex();for(c in xa)if(b===xa[c])return c;return b},P=function(){var a,c,d,e;return e=wa(arguments),d=e[0],a=e[1],c=e[2],c*=b,[d,v(c)*a,sa(c)*a]},Q=function(){var a,b,c,d,e,f,g,h,i,j,k;return c=wa(arguments),h=c[0],e=c[1],g=c[2],j=P(h,e,g),a=j[0],b=j[1],d=j[2],k=N(a,b,d),i=k[0],f=k[1],d=k[2],[i,f,d,c.length>3?c[3]:1]},M=function(){var a,b,c,d,e,g;return g=wa(arguments),e=g[0],a=g[1],b=g[2],c=ta(a*a+b*b),d=(m(b,a)*f+360)%360,0===qa(1e4*c)&&(d=Number.NaN),[e,c,d]},ia=function(){var a,b,c,d,e,f,g;return f=wa(arguments),e=f[0],c=f[1],b=f[2],g=ha(e,c,b),d=g[0],a=g[1],b=g[2],M(d,a,b)},s.lch=function(){var b;return b=wa(arguments),new a(b,"lch")},s.hcl=function(){var b;return b=wa(arguments),new a(b,"hcl")},j.lch=Q,j.hcl=function(){var a,b,c,d;return d=wa(arguments),b=d[0],a=d[1],c=d[2],Q([c,a,b])},a.prototype.lch=function(){return ia(this._rgb)},a.prototype.hcl=function(){return ia(this._rgb).reverse()},aa=function(a){var b,c,d,e,f,g,h,i,j;return null==a&&(a="rgb"),i=wa(arguments),h=i[0],e=i[1],b=i[2],h/=255,e/=255,b/=255,f=1-Math.max(h,Math.max(e,b)),d=f<1?1/(1-f):0,c=(1-h-f)*d,g=(1-e-f)*d,j=(1-b-f)*d,[c,g,j,f]},u=function(){var a,b,c,d,e,f,g,h,i;return b=wa(arguments),d=b[0],g=b[1],i=b[2],f=b[3],a=b.length>4?b[4]:1,1===f?[0,0,0,a]:(h=d>=1?0:255*(1-d)*(1-f),e=g>=1?0:255*(1-g)*(1-f),c=i>=1?0:255*(1-i)*(1-f),[h,e,c,a])},j.cmyk=function(){return u(wa(arguments))},s.cmyk=function(){return function(a,b,c){c.prototype=a.prototype;var d=new c,e=a.apply(d,b);return Object(e)===e?e:d}(a,Aa.call(arguments).concat(["cmyk"]),function(){})},a.prototype.cmyk=function(){return aa(this._rgb)},j.gl=function(){var a,b,c,d,e;for(d=function(){var a,c;a=wa(arguments),c=[];for(b in a)e=a[b],c.push(e);return c}.apply(this,arguments),a=c=0;c<=2;a=++c)d[a]*=255;return d},s.gl=function(){return function(a,b,c){c.prototype=a.prototype;var d=new c,e=a.apply(d,b);return Object(e)===e?e:d}(a,Aa.call(arguments).concat(["gl"]),function(){})},a.prototype.gl=function(){var a;return a=this._rgb,[a[0]/255,a[1]/255,a[2]/255,a[3]]},ja=function(a,b,c){var d;return d=wa(arguments),a=d[0],b=d[1],c=d[2],a=U(a),b=U(b),c=U(c),.2126*a+.7152*b+.0722*c},U=function(a){return a/=255,a<=.03928?a/12.92:_((a+.055)/1.055,2.4)},k=[],H=function(a,b,c,d){var e,f,g,h;for(null==c&&(c=.5),null==d&&(d="rgb"),"object"!==va(a)&&(a=s(a)),"object"!==va(b)&&(b=s(b)),g=0,f=k.length;g<f;g++)if(e=k[g],d===e[0]){h=e[1](a,b,c,d);break}if(null==h)throw"color mode "+d+" is not supported";return h.alpha(a.alpha()+c*(b.alpha()-a.alpha()))},s.interpolate=H,a.prototype.interpolate=function(a,b,c){return H(this,a,b,c)},s.mix=H,a.prototype.mix=a.prototype.interpolate,L=function(b,c,d,e){var f,g;return f=b._rgb,g=c._rgb,new a(f[0]+d*(g[0]-f[0]),f[1]+d*(g[1]-f[1]),f[2]+d*(g[2]-f[2]),e)},k.push(["rgb",L]),a.prototype.luminance=function(a,b){var c,d,e,f;return null==b&&(b="rgb"),arguments.length?(0===a?this._rgb=[0,0,0,this._rgb[3]]:1===a?this._rgb=[255,255,255,this._rgb[3]]:(d=1e-7,e=20,f=function(c,g){var h,i;return i=c.interpolate(g,.5,b),h=i.luminance(),Math.abs(a-h)<d||!e--?i:h>a?f(c,i):f(i,g)},c=ja(this._rgb),this._rgb=(c>a?f(s("black"),this):f(this,s("white"))).rgba()),this):ja(this._rgb)},ua=function(a){var b,c,d,e;return e=a/100,e<66?(d=255,c=-155.25485562709179-.44596950469579133*(c=e-2)+104.49216199393888*T(c),b=e<20?0:-254.76935184120902+.8274096064007395*(b=e-10)+115.67994401066147*T(b)):(d=351.97690566805693+.114206453784165*(d=e-55)-40.25366309332127*T(d),c=325.4494125711974+.07943456536662342*(c=e-50)-28.0852963507957*T(c),b=255),[d,c,b]},la=function(){var a,b,c,d,e,f,g,h;for(f=wa(arguments),e=f[0],f[1],a=f[2],d=1e3,c=4e4,b=.4;c-d>b;)h=.5*(c+d),g=ua(h),g[2]/g[0]>=a/e?c=h:d=h;return qa(h)},s.temperature=s.kelvin=function(){return function(a,b,c){c.prototype=a.prototype;var d=new c,e=a.apply(d,b);return Object(e)===e?e:d}(a,Aa.call(arguments).concat(["temperature"]),function(){})},j.temperature=j.kelvin=j.K=ua,a.prototype.temperature=function(){return la(this._rgb)},a.prototype.kelvin=a.prototype.temperature,s.contrast=function(b,c){var d,e,f,g;return"string"!==(f=va(b))&&"number"!==f||(b=new a(b)),"string"!==(g=va(c))&&"number"!==g||(c=new a(c)),d=b.luminance(),e=c.luminance(),d>e?(d+.05)/(e+.05):(e+.05)/(d+.05)},s.distance=function(b,c,d){var e,f,g,h,i,j,k;null==d&&(d="lab"),"string"!==(i=va(b))&&"number"!==i||(b=new a(b)),"string"!==(j=va(c))&&"number"!==j||(c=new a(c)),g=b.get(d),h=c.get(d),k=0;for(f in g)e=(g[f]||0)-(h[f]||0),k+=e*e;return Math.sqrt(k)},s.deltaE=function(b,c,e,f){var g,h,i,j,k,n,o,p,q,r,s,t,u,w,x,y,z,A,B,C,D,E,F,G,H,I,J;for(null==e&&(e=1),null==f&&(f=1),"string"!==(z=va(b))&&"number"!==z||(b=new a(b)),"string"!==(A=va(c))&&"number"!==A||(c=new a(c)),B=b.lab(),g=B[0],i=B[1],k=B[2],C=c.lab(),h=C[0],j=C[1],n=C[2],o=ta(i*i+k*k),p=ta(j*j+n*n),F=g<16?.511:.040975*g/(1+.01765*g),D=.0638*o/(1+.0131*o)+.638,y=o<1e-6?0:180*m(k,i)/d;y<0;)y+=360;for(;y>=360;)y-=360;return G=y>=164&&y<=345?.56+l(.2*v(d*(y+168)/180)):.36+l(.4*v(d*(y+35)/180)),q=o*o*o*o,x=ta(q/(q+1900)),E=D*(x*G+1-x),w=g-h,u=o-p,s=i-j,t=k-n,r=s*s+t*t-u*u,H=w/(e*F),I=u/(f*D),J=E,ta(H*H+I*I+r/(J*J))},a.prototype.get=function(a){var b,c,d,e,f,g;return d=this,f=a.split("."),e=f[0],b=f[1],g=d[e](),b?(c=e.indexOf(b),c>-1?g[c]:console.warn("unknown channel "+b+" in mode "+e)):g},a.prototype.set=function(a,b){var c,d,e,f,g,h;if(e=this,g=a.split("."),f=g[0],c=g[1],c)if(h=e[f](),(d=f.indexOf(c))>-1)if("string"===va(b))switch(b.charAt(0)){case"+":case"-":h[d]+=+b;break;case"*":h[d]*=+b.substr(1);break;case"/":h[d]/=+b.substr(1);break;default:h[d]=+b}else h[d]=b;else console.warn("unknown channel "+c+" in mode "+f);else h=b;return s(h,f).alpha(e.alpha())},a.prototype.clipped=function(){return this._rgb._clipped||!1},a.prototype.alpha=function(a){return arguments.length?s.rgb([this._rgb[0],this._rgb[1],this._rgb[2],a]):this._rgb[3]},a.prototype.darken=function(a){var b,d;return null==a&&(a=1),d=this,b=d.lab(),b[0]-=c.Kn*a,s.lab(b).alpha(d.alpha())},a.prototype.brighten=function(a){return null==a&&(a=1),this.darken(-a)},a.prototype.darker=a.prototype.darken,a.prototype.brighter=a.prototype.brighten,a.prototype.saturate=function(a){var b,d;return null==a&&(a=1),d=this,b=d.lch(),b[1]+=a*c.Kn,b[1]<0&&(b[1]=0),s.lch(b).alpha(d.alpha())},a.prototype.desaturate=function(a){return null==a&&(a=1),this.saturate(-a)},a.prototype.premultiply=function(){var a,b;return b=this.rgb(),a=this.alpha(),s(b[0]*a,b[1]*a,b[2]*a,a)},o=function(a,b,c){if(!o[c])throw"unknown blend mode "+c;return o[c](a,b)},p=function(a){return function(b,c){var d,e;return d=s(c).rgb(),e=s(b).rgb(),s(a(d,e),"rgb")}},z=function(a){return function(b,c){var d,e,f;for(f=[],d=e=0;e<=3;d=++e)f[d]=a(b[d],c[d]);return f}},Y=function(a,b){return a},X=function(a,b){return a*b/255},x=function(a,b){return a>b?b:a},R=function(a,b){return a>b?a:b},ra=function(a,b){return 255*(1-(1-a/255)*(1-b/255))},$=function(a,b){return b<128?2*a*b/255:255*(1-2*(1-a/255)*(1-b/255))},r=function(a,b){return 255*(1-(1-b/255)/(a/255))},y=function(a,b){return 255===a?255:(a=b/255*255/(1-a/255),a>255?255:a)},o.normal=p(z(Y)),o.multiply=p(z(X)),o.screen=p(z(ra)),o.overlay=p(z($)),o.darken=p(z(x)),o.lighten=p(z(R)),o.dodge=p(z(y)),o.burn=p(z(r)),s.blend=o,s.analyze=function(a){var b,c,d,e;for(d={min:Number.MAX_VALUE,max:Number.MAX_VALUE*-1,sum:0,values:[],count:0},c=0,b=a.length;c<b;c++)null==(e=a[c])||isNaN(e)||(d.values.push(e),d.sum+=e,e<d.min&&(d.min=e),e>d.max&&(d.max=e),d.count+=1);return d.domain=[d.min,d.max],d.limits=function(a,b){return s.limits(d,a,b)},d},s.scale=function(a,b){var c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,t,u,v,w;return j="rgb",k=s("#ccc"),o=0,!1,g=[0,1],n=[],m=[0,0],c=!1,e=[],l=!1,i=0,h=1,f=!1,d={},p=!0,v=function(a){var b,c,d,f,g,h;if(null==a&&(a=["#fff","#000"]),null!=a&&"string"===va(a)&&null!=s.brewer&&(a=s.brewer[a]||s.brewer[a.toLowerCase()]||a),"array"===va(a)){for(a=a.slice(0),b=d=0,f=a.length-1;0<=f?d<=f:d>=f;b=0<=f?++d:--d)c=a[b],"string"===va(c)&&(a[b]=s(c));for(n.length=0,b=h=0,g=a.length-1;0<=g?h<=g:h>=g;b=0<=g?++h:--h)n.push(b/(a.length-1))}return u(),e=a},r=function(a){var b,d;if(null!=c){for(d=c.length-1,b=0;b<d&&a>=c[b];)b++;return b-1}return 0},w=function(a){return a},function(a){var b,d,e,f,g;return g=a,c.length>2&&(f=c.length-1,b=r(a),e=c[0]+(c[1]-c[0])*(0+.5*o),d=c[f-1]+(c[f]-c[f-1])*(1-.5*o),g=i+(c[b]+.5*(c[b+1]-c[b])-e)/(d-e)*(h-i)),g},t=function(a,b){var f,g,l,o,q,t,u,v;if(null==b&&(b=!1),isNaN(a))return k;if(b?v=a:c&&c.length>2?(f=r(a),v=f/(c.length-2),v=m[0]+v*(1-m[0]-m[1])):h!==i?(v=(a-i)/(h-i),v=m[0]+v*(1-m[0]-m[1]),v=Math.min(1,Math.max(0,v))):v=1,b||(v=w(v)),o=Math.floor(1e4*v),p&&d[o])g=d[o];else{if("array"===va(e))for(l=q=0,u=n.length-1;0<=u?q<=u:q>=u;l=0<=u?++q:--q){if(t=n[l],v<=t){g=e[l];break}if(v>=t&&l===n.length-1){g=e[l];break}if(v>t&&v<n[l+1]){v=(v-t)/(n[l+1]-t),g=s.interpolate(e[l],e[l+1],v,j);break}}else"function"===va(e)&&(g=e(v));p&&(d[o]=g)}return g},u=function(){return d={}},v(a),q=function(a){var b;return b=s(t(a)),l&&b[l]?b[l]():b},q.classes=function(a){var b;return null!=a?("array"===va(a)?(c=a,g=[a[0],a[a.length-1]]):(b=s.analyze(g),c=0===a?[b.min,b.max]:s.limits(b,"e",a)),q):c},q.domain=function(a){var b,c,d,f,j,k,l;if(!arguments.length)return g;if(i=a[0],h=a[a.length-1],n=[],d=e.length,a.length===d&&i!==h)for(j=0,f=a.length;j<f;j++)c=a[j],n.push((c-i)/(h-i));else for(b=l=0,k=d-1;0<=k?l<=k:l>=k;b=0<=k?++l:--l)n.push(b/(d-1));return g=[i,h],q},q.mode=function(a){return arguments.length?(j=a,u(),q):j},q.range=function(a,b){return v(a,b),q},q.out=function(a){return l=a,q},q.spread=function(a){return arguments.length?(o=a,q):o},q.correctLightness=function(a){return null==a&&(a=!0),f=a,u(),w=f?function(a){var b,c,d,e,f,g,h,i,j;for(b=t(0,!0).lab()[0],c=t(1,!0).lab()[0],h=b>c,d=t(a,!0).lab()[0],f=b+(c-b)*a,e=d-f,i=0,j=1,g=20;Math.abs(e)>.01&&g-- >0;)!function(){h&&(e*=-1),e<0?(i=a,a+=.5*(j-a)):(j=a,a+=.5*(i-a)),d=t(a,!0).lab()[0],e=d-f}();return a}:function(a){return a},q},q.padding=function(a){return null!=a?("number"===va(a)&&(a=[a,a]),m=a,q):m},q.colors=function(b,d){var f,h,i,j,k,l,m;if(null==d&&(d="hex"),0===arguments.length)return e.map(function(a){return a[d]()});if(b)return 1===b?[q(.5)[d]()]:(h=g[0],f=g[1]-h,function(){k=[];for(var a=0;0<=b?a<b:a>b;0<=b?a++:a--)k.push(a);return k}.apply(this).map(function(a){return q(h+a/(b-1)*f)[d]()}));if(a=[],l=[],c&&c.length>2)for(i=m=1,j=c.length;1<=j?m<j:m>j;i=1<=j?++m:--m)l.push(.5*(c[i-1]+c[i]));else l=g;return l.map(function(a){return q(a)[d]()})},q.cache=function(a){return null!=a?p=a:p},q},null==s.scales&&(s.scales={}),s.scales.cool=function(){return s.scale([s.hsl(180,1,.9),s.hsl(250,.7,.4)])},s.scales.hot=function(){return s.scale(["#000","#f00","#ff0","#fff"],[0,.25,.75,1]).mode("rgb")},s.analyze=function(a,b,c){var d,e,f,g,h,i,j;if(h={min:Number.MAX_VALUE,max:Number.MAX_VALUE*-1,sum:0,values:[],count:0},null==c&&(c=function(){return!0}),d=function(a){null==a||isNaN(a)||(h.values.push(a),h.sum+=a,a<h.min&&(h.min=a),a>h.max&&(h.max=a),h.count+=1)},j=function(a,e){if(c(a,e))return d(null!=b&&"function"===va(b)?b(a):null!=b&&"string"===va(b)||"number"===va(b)?a[b]:a)},"array"===va(a))for(g=0,f=a.length;g<f;g++)i=a[g],j(i);else for(e in a)i=a[e],j(i,e);return h.domain=[h.min,h.max],h.limits=function(a,b){return s.limits(h,a,b)},h},s.limits=function(a,b,c){var d,e,f,g,h,i,j,k,m,n,o,p,q,r,t,u,v,w,x,y,z,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q,R,S,U,V,X,Y,Z,$,aa,ba,ca,da,ea,fa,ga,ha,ia,ja;if(null==b&&(b="equal"),null==c&&(c=7),"array"===va(a)&&(a=s.analyze(a)),E=a.min,W=a.max,a.sum,ia=a.values.sort(function(a,b){return a-b}),1===c)return[E,W];if(C=[],"c"===b.substr(0,1)&&(C.push(E),C.push(W)),"e"===b.substr(0,1)){for(C.push(E),y=K=1,O=c-1;1<=O?K<=O:K>=O;y=1<=O?++K:--K)C.push(E+y/c*(W-E));C.push(W)}else if("l"===b.substr(0,1)){
if(E<=0)throw"Logarithmic scales are only possible for values > 0";for(F=Math.LOG10E*T(E),D=Math.LOG10E*T(W),C.push(E),y=ja=1,P=c-1;1<=P?ja<=P:ja>=P;y=1<=P?++ja:--ja)C.push(_(10,F+y/c*(D-F)));C.push(W)}else if("q"===b.substr(0,1)){for(C.push(E),y=d=1,X=c-1;1<=X?d<=X:d>=X;y=1<=X?++d:--d)L=(ia.length-1)*y/c,M=A(L),M===L?C.push(ia[M]):(N=L-M,C.push(ia[M]*(1-N)+ia[M+1]*N));C.push(W)}else if("k"===b.substr(0,1)){for(H=ia.length,r=new Array(H),w=new Array(c),ea=!0,I=0,u=null,u=[],u.push(E),y=e=1,Y=c-1;1<=Y?e<=Y:e>=Y;y=1<=Y?++e:--e)u.push(E+y/c*(W-E));for(u.push(W);ea;){for(z=f=0,Z=c-1;0<=Z?f<=Z:f>=Z;z=0<=Z?++f:--f)w[z]=0;for(y=g=0,$=H-1;0<=$?g<=$:g>=$;y=0<=$?++g:--g){for(ha=ia[y],G=Number.MAX_VALUE,z=h=0,aa=c-1;0<=aa?h<=aa:h>=aa;z=0<=aa?++h:--h)(x=l(u[z]-ha))<G&&(G=x,t=z);w[t]++,r[y]=t}for(J=new Array(c),z=i=0,ba=c-1;0<=ba?i<=ba:i>=ba;z=0<=ba?++i:--i)J[z]=null;for(y=j=0,ca=H-1;0<=ca?j<=ca:j>=ca;y=0<=ca?++j:--j)v=r[y],null===J[v]?J[v]=ia[y]:J[v]+=ia[y];for(z=k=0,da=c-1;0<=da?k<=da:k>=da;z=0<=da?++k:--k)J[z]*=1/w[z];for(ea=!1,z=m=0,Q=c-1;0<=Q?m<=Q:m>=Q;z=0<=Q?++m:--m)if(J[z]!==u[y]){ea=!0;break}u=J,I++,I>200&&(ea=!1)}for(B={},z=n=0,R=c-1;0<=R?n<=R:n>=R;z=0<=R?++n:--n)B[z]=[];for(y=o=0,S=H-1;0<=S?o<=S:o>=S;y=0<=S?++o:--o)v=r[y],B[v].push(ia[y]);for(fa=[],z=p=0,U=c-1;0<=U?p<=U:p>=U;z=0<=U?++p:--p)fa.push(B[z][0]),fa.push(B[z][B[z].length-1]);for(fa=fa.sort(function(a,b){return a-b}),C.push(fa[0]),y=q=1,V=fa.length-1;q<=V;y=q+=2)ga=fa[y],isNaN(ga)||C.indexOf(ga)!==-1||C.push(ga)}return C},D=function(a,b,c){var d,f,h,i;return d=wa(arguments),a=d[0],b=d[1],c=d[2],isNaN(a)&&(a=0),a/=360,a<1/3?(f=(1-b)/3,i=(1+b*v(g*a)/v(e-g*a))/3,h=1-(f+i)):a<2/3?(a-=1/3,i=(1-b)/3,h=(1+b*v(g*a)/v(e-g*a))/3,f=1-(i+h)):(a-=2/3,h=(1-b)/3,f=(1+b*v(g*a)/v(e-g*a))/3,i=1-(h+f)),i=S(c*i*3),h=S(c*h*3),f=S(c*f*3),[255*i,255*h,255*f,d.length>3?d[3]:1]},ea=function(){var a,b,c,d,e,f,h,i;return h=wa(arguments),f=h[0],b=h[1],a=h[2],g=2*Math.PI,f/=255,b/=255,a/=255,e=Math.min(f,b,a),d=(f+b+a)/3,i=1-e/d,0===i?c=0:(c=(f-b+(f-a))/2,c/=Math.sqrt((f-b)*(f-b)+(f-a)*(b-a)),c=Math.acos(c),a>b&&(c=g-c),c/=g),[360*c,i,d]},s.hsi=function(){return function(a,b,c){c.prototype=a.prototype;var d=new c,e=a.apply(d,b);return Object(e)===e?e:d}(a,Aa.call(arguments).concat(["hsi"]),function(){})},j.hsi=D,a.prototype.hsi=function(){return ea(this._rgb)},I=function(a,b,c,d){var e,f,g,h,i,j,k,l,m,n,o,p;return"hsl"===d?(o=a.hsl(),p=b.hsl()):"hsv"===d?(o=a.hsv(),p=b.hsv()):"hcg"===d?(o=a.hcg(),p=b.hcg()):"hsi"===d?(o=a.hsi(),p=b.hsi()):"lch"!==d&&"hcl"!==d||(d="hcl",o=a.hcl(),p=b.hcl()),"h"===d.substr(0,1)&&(g=o[0],m=o[1],j=o[2],h=p[0],n=p[1],k=p[2]),isNaN(g)||isNaN(h)?isNaN(g)?isNaN(h)?f=Number.NaN:(f=h,1!==j&&0!==j||"hsv"===d||(l=n)):(f=g,1!==k&&0!==k||"hsv"===d||(l=m)):(e=h>g&&h-g>180?h-(g+360):h<g&&g-h>180?h+360-g:h-g,f=g+c*e),null==l&&(l=m+c*(n-m)),i=j+c*(k-j),s[d](f,l,i)},k=k.concat(function(){var a,b,c,d;for(c=["hsv","hsl","hsi","hcl","lch","hcg"],d=[],b=0,a=c.length;b<a;b++)V=c[b],d.push([V,I]);return d}()),K=function(a,b,c,d){var e,f;return e=a.num(),f=b.num(),s.num(e+(f-e)*c,"num")},k.push(["num",K]),J=function(b,c,d,e){var f,g;return f=b.lab(),g=c.lab(),new a(f[0]+d*(g[0]-f[0]),f[1]+d*(g[1]-f[1]),f[2]+d*(g[2]-f[2]),e)},k.push(["lab",J])}).call(this);</script>
<script>/*! jQuery v3.2.1 | (c) JS Foundation and other contributors | jquery.org/license */
!function(a,b){"use strict";"object"==typeof module&&"object"==typeof module.exports?module.exports=a.document?b(a,!0):function(a){if(!a.document)throw new Error("jQuery requires a window with a document");return b(a)}:b(a)}("undefined"!=typeof window?window:this,function(a,b){"use strict";var c=[],d=a.document,e=Object.getPrototypeOf,f=c.slice,g=c.concat,h=c.push,i=c.indexOf,j={},k=j.toString,l=j.hasOwnProperty,m=l.toString,n=m.call(Object),o={};function p(a,b){b=b||d;var c=b.createElement("script");c.text=a,b.head.appendChild(c).parentNode.removeChild(c)}var q="3.2.1",r=function(a,b){return new r.fn.init(a,b)},s=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,t=/^-ms-/,u=/-([a-z])/g,v=function(a,b){return b.toUpperCase()};r.fn=r.prototype={jquery:q,constructor:r,length:0,toArray:function(){return f.call(this)},get:function(a){return null==a?f.call(this):a<0?this[a+this.length]:this[a]},pushStack:function(a){var b=r.merge(this.constructor(),a);return b.prevObject=this,b},each:function(a){return r.each(this,a)},map:function(a){return this.pushStack(r.map(this,function(b,c){return a.call(b,c,b)}))},slice:function(){return this.pushStack(f.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(a){var b=this.length,c=+a+(a<0?b:0);return this.pushStack(c>=0&&c<b?[this[c]]:[])},end:function(){return this.prevObject||this.constructor()},push:h,sort:c.sort,splice:c.splice},r.extend=r.fn.extend=function(){var a,b,c,d,e,f,g=arguments[0]||{},h=1,i=arguments.length,j=!1;for("boolean"==typeof g&&(j=g,g=arguments[h]||{},h++),"object"==typeof g||r.isFunction(g)||(g={}),h===i&&(g=this,h--);h<i;h++)if(null!=(a=arguments[h]))for(b in a)c=g[b],d=a[b],g!==d&&(j&&d&&(r.isPlainObject(d)||(e=Array.isArray(d)))?(e?(e=!1,f=c&&Array.isArray(c)?c:[]):f=c&&r.isPlainObject(c)?c:{},g[b]=r.extend(j,f,d)):void 0!==d&&(g[b]=d));return g},r.extend({expando:"jQuery"+(q+Math.random()).replace(/\D/g,""),isReady:!0,error:function(a){throw new Error(a)},noop:function(){},isFunction:function(a){return"function"===r.type(a)},isWindow:function(a){return null!=a&&a===a.window},isNumeric:function(a){var b=r.type(a);return("number"===b||"string"===b)&&!isNaN(a-parseFloat(a))},isPlainObject:function(a){var b,c;return!(!a||"[object Object]"!==k.call(a))&&(!(b=e(a))||(c=l.call(b,"constructor")&&b.constructor,"function"==typeof c&&m.call(c)===n))},isEmptyObject:function(a){var b;for(b in a)return!1;return!0},type:function(a){return null==a?a+"":"object"==typeof a||"function"==typeof a?j[k.call(a)]||"object":typeof a},globalEval:function(a){p(a)},camelCase:function(a){return a.replace(t,"ms-").replace(u,v)},each:function(a,b){var c,d=0;if(w(a)){for(c=a.length;d<c;d++)if(b.call(a[d],d,a[d])===!1)break}else for(d in a)if(b.call(a[d],d,a[d])===!1)break;return a},trim:function(a){return null==a?"":(a+"").replace(s,"")},makeArray:function(a,b){var c=b||[];return null!=a&&(w(Object(a))?r.merge(c,"string"==typeof a?[a]:a):h.call(c,a)),c},inArray:function(a,b,c){return null==b?-1:i.call(b,a,c)},merge:function(a,b){for(var c=+b.length,d=0,e=a.length;d<c;d++)a[e++]=b[d];return a.length=e,a},grep:function(a,b,c){for(var d,e=[],f=0,g=a.length,h=!c;f<g;f++)d=!b(a[f],f),d!==h&&e.push(a[f]);return e},map:function(a,b,c){var d,e,f=0,h=[];if(w(a))for(d=a.length;f<d;f++)e=b(a[f],f,c),null!=e&&h.push(e);else for(f in a)e=b(a[f],f,c),null!=e&&h.push(e);return g.apply([],h)},guid:1,proxy:function(a,b){var c,d,e;if("string"==typeof b&&(c=a[b],b=a,a=c),r.isFunction(a))return d=f.call(arguments,2),e=function(){return a.apply(b||this,d.concat(f.call(arguments)))},e.guid=a.guid=a.guid||r.guid++,e},now:Date.now,support:o}),"function"==typeof Symbol&&(r.fn[Symbol.iterator]=c[Symbol.iterator]),r.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(a,b){j["[object "+b+"]"]=b.toLowerCase()});function w(a){var b=!!a&&"length"in a&&a.length,c=r.type(a);return"function"!==c&&!r.isWindow(a)&&("array"===c||0===b||"number"==typeof b&&b>0&&b-1 in a)}var x=function(a){var b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u="sizzle"+1*new Date,v=a.document,w=0,x=0,y=ha(),z=ha(),A=ha(),B=function(a,b){return a===b&&(l=!0),0},C={}.hasOwnProperty,D=[],E=D.pop,F=D.push,G=D.push,H=D.slice,I=function(a,b){for(var c=0,d=a.length;c<d;c++)if(a[c]===b)return c;return-1},J="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",K="[\\x20\\t\\r\\n\\f]",L="(?:\\\\.|[\\w-]|[^\0-\\xa0])+",M="\\["+K+"*("+L+")(?:"+K+"*([*^$|!~]?=)"+K+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+L+"))|)"+K+"*\\]",N=":("+L+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+M+")*)|.*)\\)|)",O=new RegExp(K+"+","g"),P=new RegExp("^"+K+"+|((?:^|[^\\\\])(?:\\\\.)*)"+K+"+$","g"),Q=new RegExp("^"+K+"*,"+K+"*"),R=new RegExp("^"+K+"*([>+~]|"+K+")"+K+"*"),S=new RegExp("="+K+"*([^\\]'\"]*?)"+K+"*\\]","g"),T=new RegExp(N),U=new RegExp("^"+L+"$"),V={ID:new RegExp("^#("+L+")"),CLASS:new RegExp("^\\.("+L+")"),TAG:new RegExp("^("+L+"|[*])"),ATTR:new RegExp("^"+M),PSEUDO:new RegExp("^"+N),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+K+"*(even|odd|(([+-]|)(\\d*)n|)"+K+"*(?:([+-]|)"+K+"*(\\d+)|))"+K+"*\\)|)","i"),bool:new RegExp("^(?:"+J+")$","i"),needsContext:new RegExp("^"+K+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+K+"*((?:-\\d)?\\d*)"+K+"*\\)|)(?=[^-]|$)","i")},W=/^(?:input|select|textarea|button)$/i,X=/^h\d$/i,Y=/^[^{]+\{\s*\[native \w/,Z=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,$=/[+~]/,_=new RegExp("\\\\([\\da-f]{1,6}"+K+"?|("+K+")|.)","ig"),aa=function(a,b,c){var d="0x"+b-65536;return d!==d||c?b:d<0?String.fromCharCode(d+65536):String.fromCharCode(d>>10|55296,1023&d|56320)},ba=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,ca=function(a,b){return b?"\0"===a?"\ufffd":a.slice(0,-1)+"\\"+a.charCodeAt(a.length-1).toString(16)+" ":"\\"+a},da=function(){m()},ea=ta(function(a){return a.disabled===!0&&("form"in a||"label"in a)},{dir:"parentNode",next:"legend"});try{G.apply(D=H.call(v.childNodes),v.childNodes),D[v.childNodes.length].nodeType}catch(fa){G={apply:D.length?function(a,b){F.apply(a,H.call(b))}:function(a,b){var c=a.length,d=0;while(a[c++]=b[d++]);a.length=c-1}}}function ga(a,b,d,e){var f,h,j,k,l,o,r,s=b&&b.ownerDocument,w=b?b.nodeType:9;if(d=d||[],"string"!=typeof a||!a||1!==w&&9!==w&&11!==w)return d;if(!e&&((b?b.ownerDocument||b:v)!==n&&m(b),b=b||n,p)){if(11!==w&&(l=Z.exec(a)))if(f=l[1]){if(9===w){if(!(j=b.getElementById(f)))return d;if(j.id===f)return d.push(j),d}else if(s&&(j=s.getElementById(f))&&t(b,j)&&j.id===f)return d.push(j),d}else{if(l[2])return G.apply(d,b.getElementsByTagName(a)),d;if((f=l[3])&&c.getElementsByClassName&&b.getElementsByClassName)return G.apply(d,b.getElementsByClassName(f)),d}if(c.qsa&&!A[a+" "]&&(!q||!q.test(a))){if(1!==w)s=b,r=a;else if("object"!==b.nodeName.toLowerCase()){(k=b.getAttribute("id"))?k=k.replace(ba,ca):b.setAttribute("id",k=u),o=g(a),h=o.length;while(h--)o[h]="#"+k+" "+sa(o[h]);r=o.join(","),s=$.test(a)&&qa(b.parentNode)||b}if(r)try{return G.apply(d,s.querySelectorAll(r)),d}catch(x){}finally{k===u&&b.removeAttribute("id")}}}return i(a.replace(P,"$1"),b,d,e)}function ha(){var a=[];function b(c,e){return a.push(c+" ")>d.cacheLength&&delete b[a.shift()],b[c+" "]=e}return b}function ia(a){return a[u]=!0,a}function ja(a){var b=n.createElement("fieldset");try{return!!a(b)}catch(c){return!1}finally{b.parentNode&&b.parentNode.removeChild(b),b=null}}function ka(a,b){var c=a.split("|"),e=c.length;while(e--)d.attrHandle[c[e]]=b}function la(a,b){var c=b&&a,d=c&&1===a.nodeType&&1===b.nodeType&&a.sourceIndex-b.sourceIndex;if(d)return d;if(c)while(c=c.nextSibling)if(c===b)return-1;return a?1:-1}function ma(a){return function(b){var c=b.nodeName.toLowerCase();return"input"===c&&b.type===a}}function na(a){return function(b){var c=b.nodeName.toLowerCase();return("input"===c||"button"===c)&&b.type===a}}function oa(a){return function(b){return"form"in b?b.parentNode&&b.disabled===!1?"label"in b?"label"in b.parentNode?b.parentNode.disabled===a:b.disabled===a:b.isDisabled===a||b.isDisabled!==!a&&ea(b)===a:b.disabled===a:"label"in b&&b.disabled===a}}function pa(a){return ia(function(b){return b=+b,ia(function(c,d){var e,f=a([],c.length,b),g=f.length;while(g--)c[e=f[g]]&&(c[e]=!(d[e]=c[e]))})})}function qa(a){return a&&"undefined"!=typeof a.getElementsByTagName&&a}c=ga.support={},f=ga.isXML=function(a){var b=a&&(a.ownerDocument||a).documentElement;return!!b&&"HTML"!==b.nodeName},m=ga.setDocument=function(a){var b,e,g=a?a.ownerDocument||a:v;return g!==n&&9===g.nodeType&&g.documentElement?(n=g,o=n.documentElement,p=!f(n),v!==n&&(e=n.defaultView)&&e.top!==e&&(e.addEventListener?e.addEventListener("unload",da,!1):e.attachEvent&&e.attachEvent("onunload",da)),c.attributes=ja(function(a){return a.className="i",!a.getAttribute("className")}),c.getElementsByTagName=ja(function(a){return a.appendChild(n.createComment("")),!a.getElementsByTagName("*").length}),c.getElementsByClassName=Y.test(n.getElementsByClassName),c.getById=ja(function(a){return o.appendChild(a).id=u,!n.getElementsByName||!n.getElementsByName(u).length}),c.getById?(d.filter.ID=function(a){var b=a.replace(_,aa);return function(a){return a.getAttribute("id")===b}},d.find.ID=function(a,b){if("undefined"!=typeof b.getElementById&&p){var c=b.getElementById(a);return c?[c]:[]}}):(d.filter.ID=function(a){var b=a.replace(_,aa);return function(a){var c="undefined"!=typeof a.getAttributeNode&&a.getAttributeNode("id");return c&&c.value===b}},d.find.ID=function(a,b){if("undefined"!=typeof b.getElementById&&p){var c,d,e,f=b.getElementById(a);if(f){if(c=f.getAttributeNode("id"),c&&c.value===a)return[f];e=b.getElementsByName(a),d=0;while(f=e[d++])if(c=f.getAttributeNode("id"),c&&c.value===a)return[f]}return[]}}),d.find.TAG=c.getElementsByTagName?function(a,b){return"undefined"!=typeof b.getElementsByTagName?b.getElementsByTagName(a):c.qsa?b.querySelectorAll(a):void 0}:function(a,b){var c,d=[],e=0,f=b.getElementsByTagName(a);if("*"===a){while(c=f[e++])1===c.nodeType&&d.push(c);return d}return f},d.find.CLASS=c.getElementsByClassName&&function(a,b){if("undefined"!=typeof b.getElementsByClassName&&p)return b.getElementsByClassName(a)},r=[],q=[],(c.qsa=Y.test(n.querySelectorAll))&&(ja(function(a){o.appendChild(a).innerHTML="<a id='"+u+"'></a><select id='"+u+"-\r\\' msallowcapture=''><option selected=''></option></select>",a.querySelectorAll("[msallowcapture^='']").length&&q.push("[*^$]="+K+"*(?:''|\"\")"),a.querySelectorAll("[selected]").length||q.push("\\["+K+"*(?:value|"+J+")"),a.querySelectorAll("[id~="+u+"-]").length||q.push("~="),a.querySelectorAll(":checked").length||q.push(":checked"),a.querySelectorAll("a#"+u+"+*").length||q.push(".#.+[+~]")}),ja(function(a){a.innerHTML="<a href='' disabled='disabled'></a><select disabled='disabled'><option/></select>";var b=n.createElement("input");b.setAttribute("type","hidden"),a.appendChild(b).setAttribute("name","D"),a.querySelectorAll("[name=d]").length&&q.push("name"+K+"*[*^$|!~]?="),2!==a.querySelectorAll(":enabled").length&&q.push(":enabled",":disabled"),o.appendChild(a).disabled=!0,2!==a.querySelectorAll(":disabled").length&&q.push(":enabled",":disabled"),a.querySelectorAll("*,:x"),q.push(",.*:")})),(c.matchesSelector=Y.test(s=o.matches||o.webkitMatchesSelector||o.mozMatchesSelector||o.oMatchesSelector||o.msMatchesSelector))&&ja(function(a){c.disconnectedMatch=s.call(a,"*"),s.call(a,"[s!='']:x"),r.push("!=",N)}),q=q.length&&new RegExp(q.join("|")),r=r.length&&new RegExp(r.join("|")),b=Y.test(o.compareDocumentPosition),t=b||Y.test(o.contains)?function(a,b){var c=9===a.nodeType?a.documentElement:a,d=b&&b.parentNode;return a===d||!(!d||1!==d.nodeType||!(c.contains?c.contains(d):a.compareDocumentPosition&&16&a.compareDocumentPosition(d)))}:function(a,b){if(b)while(b=b.parentNode)if(b===a)return!0;return!1},B=b?function(a,b){if(a===b)return l=!0,0;var d=!a.compareDocumentPosition-!b.compareDocumentPosition;return d?d:(d=(a.ownerDocument||a)===(b.ownerDocument||b)?a.compareDocumentPosition(b):1,1&d||!c.sortDetached&&b.compareDocumentPosition(a)===d?a===n||a.ownerDocument===v&&t(v,a)?-1:b===n||b.ownerDocument===v&&t(v,b)?1:k?I(k,a)-I(k,b):0:4&d?-1:1)}:function(a,b){if(a===b)return l=!0,0;var c,d=0,e=a.parentNode,f=b.parentNode,g=[a],h=[b];if(!e||!f)return a===n?-1:b===n?1:e?-1:f?1:k?I(k,a)-I(k,b):0;if(e===f)return la(a,b);c=a;while(c=c.parentNode)g.unshift(c);c=b;while(c=c.parentNode)h.unshift(c);while(g[d]===h[d])d++;return d?la(g[d],h[d]):g[d]===v?-1:h[d]===v?1:0},n):n},ga.matches=function(a,b){return ga(a,null,null,b)},ga.matchesSelector=function(a,b){if((a.ownerDocument||a)!==n&&m(a),b=b.replace(S,"='$1']"),c.matchesSelector&&p&&!A[b+" "]&&(!r||!r.test(b))&&(!q||!q.test(b)))try{var d=s.call(a,b);if(d||c.disconnectedMatch||a.document&&11!==a.document.nodeType)return d}catch(e){}return ga(b,n,null,[a]).length>0},ga.contains=function(a,b){return(a.ownerDocument||a)!==n&&m(a),t(a,b)},ga.attr=function(a,b){(a.ownerDocument||a)!==n&&m(a);var e=d.attrHandle[b.toLowerCase()],f=e&&C.call(d.attrHandle,b.toLowerCase())?e(a,b,!p):void 0;return void 0!==f?f:c.attributes||!p?a.getAttribute(b):(f=a.getAttributeNode(b))&&f.specified?f.value:null},ga.escape=function(a){return(a+"").replace(ba,ca)},ga.error=function(a){throw new Error("Syntax error, unrecognized expression: "+a)},ga.uniqueSort=function(a){var b,d=[],e=0,f=0;if(l=!c.detectDuplicates,k=!c.sortStable&&a.slice(0),a.sort(B),l){while(b=a[f++])b===a[f]&&(e=d.push(f));while(e--)a.splice(d[e],1)}return k=null,a},e=ga.getText=function(a){var b,c="",d=0,f=a.nodeType;if(f){if(1===f||9===f||11===f){if("string"==typeof a.textContent)return a.textContent;for(a=a.firstChild;a;a=a.nextSibling)c+=e(a)}else if(3===f||4===f)return a.nodeValue}else while(b=a[d++])c+=e(b);return c},d=ga.selectors={cacheLength:50,createPseudo:ia,match:V,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(a){return a[1]=a[1].replace(_,aa),a[3]=(a[3]||a[4]||a[5]||"").replace(_,aa),"~="===a[2]&&(a[3]=" "+a[3]+" "),a.slice(0,4)},CHILD:function(a){return a[1]=a[1].toLowerCase(),"nth"===a[1].slice(0,3)?(a[3]||ga.error(a[0]),a[4]=+(a[4]?a[5]+(a[6]||1):2*("even"===a[3]||"odd"===a[3])),a[5]=+(a[7]+a[8]||"odd"===a[3])):a[3]&&ga.error(a[0]),a},PSEUDO:function(a){var b,c=!a[6]&&a[2];return V.CHILD.test(a[0])?null:(a[3]?a[2]=a[4]||a[5]||"":c&&T.test(c)&&(b=g(c,!0))&&(b=c.indexOf(")",c.length-b)-c.length)&&(a[0]=a[0].slice(0,b),a[2]=c.slice(0,b)),a.slice(0,3))}},filter:{TAG:function(a){var b=a.replace(_,aa).toLowerCase();return"*"===a?function(){return!0}:function(a){return a.nodeName&&a.nodeName.toLowerCase()===b}},CLASS:function(a){var b=y[a+" "];return b||(b=new RegExp("(^|"+K+")"+a+"("+K+"|$)"))&&y(a,function(a){return b.test("string"==typeof a.className&&a.className||"undefined"!=typeof a.getAttribute&&a.getAttribute("class")||"")})},ATTR:function(a,b,c){return function(d){var e=ga.attr(d,a);return null==e?"!="===b:!b||(e+="","="===b?e===c:"!="===b?e!==c:"^="===b?c&&0===e.indexOf(c):"*="===b?c&&e.indexOf(c)>-1:"$="===b?c&&e.slice(-c.length)===c:"~="===b?(" "+e.replace(O," ")+" ").indexOf(c)>-1:"|="===b&&(e===c||e.slice(0,c.length+1)===c+"-"))}},CHILD:function(a,b,c,d,e){var f="nth"!==a.slice(0,3),g="last"!==a.slice(-4),h="of-type"===b;return 1===d&&0===e?function(a){return!!a.parentNode}:function(b,c,i){var j,k,l,m,n,o,p=f!==g?"nextSibling":"previousSibling",q=b.parentNode,r=h&&b.nodeName.toLowerCase(),s=!i&&!h,t=!1;if(q){if(f){while(p){m=b;while(m=m[p])if(h?m.nodeName.toLowerCase()===r:1===m.nodeType)return!1;o=p="only"===a&&!o&&"nextSibling"}return!0}if(o=[g?q.firstChild:q.lastChild],g&&s){m=q,l=m[u]||(m[u]={}),k=l[m.uniqueID]||(l[m.uniqueID]={}),j=k[a]||[],n=j[0]===w&&j[1],t=n&&j[2],m=n&&q.childNodes[n];while(m=++n&&m&&m[p]||(t=n=0)||o.pop())if(1===m.nodeType&&++t&&m===b){k[a]=[w,n,t];break}}else if(s&&(m=b,l=m[u]||(m[u]={}),k=l[m.uniqueID]||(l[m.uniqueID]={}),j=k[a]||[],n=j[0]===w&&j[1],t=n),t===!1)while(m=++n&&m&&m[p]||(t=n=0)||o.pop())if((h?m.nodeName.toLowerCase()===r:1===m.nodeType)&&++t&&(s&&(l=m[u]||(m[u]={}),k=l[m.uniqueID]||(l[m.uniqueID]={}),k[a]=[w,t]),m===b))break;return t-=e,t===d||t%d===0&&t/d>=0}}},PSEUDO:function(a,b){var c,e=d.pseudos[a]||d.setFilters[a.toLowerCase()]||ga.error("unsupported pseudo: "+a);return e[u]?e(b):e.length>1?(c=[a,a,"",b],d.setFilters.hasOwnProperty(a.toLowerCase())?ia(function(a,c){var d,f=e(a,b),g=f.length;while(g--)d=I(a,f[g]),a[d]=!(c[d]=f[g])}):function(a){return e(a,0,c)}):e}},pseudos:{not:ia(function(a){var b=[],c=[],d=h(a.replace(P,"$1"));return d[u]?ia(function(a,b,c,e){var f,g=d(a,null,e,[]),h=a.length;while(h--)(f=g[h])&&(a[h]=!(b[h]=f))}):function(a,e,f){return b[0]=a,d(b,null,f,c),b[0]=null,!c.pop()}}),has:ia(function(a){return function(b){return ga(a,b).length>0}}),contains:ia(function(a){return a=a.replace(_,aa),function(b){return(b.textContent||b.innerText||e(b)).indexOf(a)>-1}}),lang:ia(function(a){return U.test(a||"")||ga.error("unsupported lang: "+a),a=a.replace(_,aa).toLowerCase(),function(b){var c;do if(c=p?b.lang:b.getAttribute("xml:lang")||b.getAttribute("lang"))return c=c.toLowerCase(),c===a||0===c.indexOf(a+"-");while((b=b.parentNode)&&1===b.nodeType);return!1}}),target:function(b){var c=a.location&&a.location.hash;return c&&c.slice(1)===b.id},root:function(a){return a===o},focus:function(a){return a===n.activeElement&&(!n.hasFocus||n.hasFocus())&&!!(a.type||a.href||~a.tabIndex)},enabled:oa(!1),disabled:oa(!0),checked:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&!!a.checked||"option"===b&&!!a.selected},selected:function(a){return a.parentNode&&a.parentNode.selectedIndex,a.selected===!0},empty:function(a){for(a=a.firstChild;a;a=a.nextSibling)if(a.nodeType<6)return!1;return!0},parent:function(a){return!d.pseudos.empty(a)},header:function(a){return X.test(a.nodeName)},input:function(a){return W.test(a.nodeName)},button:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&"button"===a.type||"button"===b},text:function(a){var b;return"input"===a.nodeName.toLowerCase()&&"text"===a.type&&(null==(b=a.getAttribute("type"))||"text"===b.toLowerCase())},first:pa(function(){return[0]}),last:pa(function(a,b){return[b-1]}),eq:pa(function(a,b,c){return[c<0?c+b:c]}),even:pa(function(a,b){for(var c=0;c<b;c+=2)a.push(c);return a}),odd:pa(function(a,b){for(var c=1;c<b;c+=2)a.push(c);return a}),lt:pa(function(a,b,c){for(var d=c<0?c+b:c;--d>=0;)a.push(d);return a}),gt:pa(function(a,b,c){for(var d=c<0?c+b:c;++d<b;)a.push(d);return a})}},d.pseudos.nth=d.pseudos.eq;for(b in{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})d.pseudos[b]=ma(b);for(b in{submit:!0,reset:!0})d.pseudos[b]=na(b);function ra(){}ra.prototype=d.filters=d.pseudos,d.setFilters=new ra,g=ga.tokenize=function(a,b){var c,e,f,g,h,i,j,k=z[a+" "];if(k)return b?0:k.slice(0);h=a,i=[],j=d.preFilter;while(h){c&&!(e=Q.exec(h))||(e&&(h=h.slice(e[0].length)||h),i.push(f=[])),c=!1,(e=R.exec(h))&&(c=e.shift(),f.push({value:c,type:e[0].replace(P," ")}),h=h.slice(c.length));for(g in d.filter)!(e=V[g].exec(h))||j[g]&&!(e=j[g](e))||(c=e.shift(),f.push({value:c,type:g,matches:e}),h=h.slice(c.length));if(!c)break}return b?h.length:h?ga.error(a):z(a,i).slice(0)};function sa(a){for(var b=0,c=a.length,d="";b<c;b++)d+=a[b].value;return d}function ta(a,b,c){var d=b.dir,e=b.next,f=e||d,g=c&&"parentNode"===f,h=x++;return b.first?function(b,c,e){while(b=b[d])if(1===b.nodeType||g)return a(b,c,e);return!1}:function(b,c,i){var j,k,l,m=[w,h];if(i){while(b=b[d])if((1===b.nodeType||g)&&a(b,c,i))return!0}else while(b=b[d])if(1===b.nodeType||g)if(l=b[u]||(b[u]={}),k=l[b.uniqueID]||(l[b.uniqueID]={}),e&&e===b.nodeName.toLowerCase())b=b[d]||b;else{if((j=k[f])&&j[0]===w&&j[1]===h)return m[2]=j[2];if(k[f]=m,m[2]=a(b,c,i))return!0}return!1}}function ua(a){return a.length>1?function(b,c,d){var e=a.length;while(e--)if(!a[e](b,c,d))return!1;return!0}:a[0]}function va(a,b,c){for(var d=0,e=b.length;d<e;d++)ga(a,b[d],c);return c}function wa(a,b,c,d,e){for(var f,g=[],h=0,i=a.length,j=null!=b;h<i;h++)(f=a[h])&&(c&&!c(f,d,e)||(g.push(f),j&&b.push(h)));return g}function xa(a,b,c,d,e,f){return d&&!d[u]&&(d=xa(d)),e&&!e[u]&&(e=xa(e,f)),ia(function(f,g,h,i){var j,k,l,m=[],n=[],o=g.length,p=f||va(b||"*",h.nodeType?[h]:h,[]),q=!a||!f&&b?p:wa(p,m,a,h,i),r=c?e||(f?a:o||d)?[]:g:q;if(c&&c(q,r,h,i),d){j=wa(r,n),d(j,[],h,i),k=j.length;while(k--)(l=j[k])&&(r[n[k]]=!(q[n[k]]=l))}if(f){if(e||a){if(e){j=[],k=r.length;while(k--)(l=r[k])&&j.push(q[k]=l);e(null,r=[],j,i)}k=r.length;while(k--)(l=r[k])&&(j=e?I(f,l):m[k])>-1&&(f[j]=!(g[j]=l))}}else r=wa(r===g?r.splice(o,r.length):r),e?e(null,g,r,i):G.apply(g,r)})}function ya(a){for(var b,c,e,f=a.length,g=d.relative[a[0].type],h=g||d.relative[" "],i=g?1:0,k=ta(function(a){return a===b},h,!0),l=ta(function(a){return I(b,a)>-1},h,!0),m=[function(a,c,d){var e=!g&&(d||c!==j)||((b=c).nodeType?k(a,c,d):l(a,c,d));return b=null,e}];i<f;i++)if(c=d.relative[a[i].type])m=[ta(ua(m),c)];else{if(c=d.filter[a[i].type].apply(null,a[i].matches),c[u]){for(e=++i;e<f;e++)if(d.relative[a[e].type])break;return xa(i>1&&ua(m),i>1&&sa(a.slice(0,i-1).concat({value:" "===a[i-2].type?"*":""})).replace(P,"$1"),c,i<e&&ya(a.slice(i,e)),e<f&&ya(a=a.slice(e)),e<f&&sa(a))}m.push(c)}return ua(m)}function za(a,b){var c=b.length>0,e=a.length>0,f=function(f,g,h,i,k){var l,o,q,r=0,s="0",t=f&&[],u=[],v=j,x=f||e&&d.find.TAG("*",k),y=w+=null==v?1:Math.random()||.1,z=x.length;for(k&&(j=g===n||g||k);s!==z&&null!=(l=x[s]);s++){if(e&&l){o=0,g||l.ownerDocument===n||(m(l),h=!p);while(q=a[o++])if(q(l,g||n,h)){i.push(l);break}k&&(w=y)}c&&((l=!q&&l)&&r--,f&&t.push(l))}if(r+=s,c&&s!==r){o=0;while(q=b[o++])q(t,u,g,h);if(f){if(r>0)while(s--)t[s]||u[s]||(u[s]=E.call(i));u=wa(u)}G.apply(i,u),k&&!f&&u.length>0&&r+b.length>1&&ga.uniqueSort(i)}return k&&(w=y,j=v),t};return c?ia(f):f}return h=ga.compile=function(a,b){var c,d=[],e=[],f=A[a+" "];if(!f){b||(b=g(a)),c=b.length;while(c--)f=ya(b[c]),f[u]?d.push(f):e.push(f);f=A(a,za(e,d)),f.selector=a}return f},i=ga.select=function(a,b,c,e){var f,i,j,k,l,m="function"==typeof a&&a,n=!e&&g(a=m.selector||a);if(c=c||[],1===n.length){if(i=n[0]=n[0].slice(0),i.length>2&&"ID"===(j=i[0]).type&&9===b.nodeType&&p&&d.relative[i[1].type]){if(b=(d.find.ID(j.matches[0].replace(_,aa),b)||[])[0],!b)return c;m&&(b=b.parentNode),a=a.slice(i.shift().value.length)}f=V.needsContext.test(a)?0:i.length;while(f--){if(j=i[f],d.relative[k=j.type])break;if((l=d.find[k])&&(e=l(j.matches[0].replace(_,aa),$.test(i[0].type)&&qa(b.parentNode)||b))){if(i.splice(f,1),a=e.length&&sa(i),!a)return G.apply(c,e),c;break}}}return(m||h(a,n))(e,b,!p,c,!b||$.test(a)&&qa(b.parentNode)||b),c},c.sortStable=u.split("").sort(B).join("")===u,c.detectDuplicates=!!l,m(),c.sortDetached=ja(function(a){return 1&a.compareDocumentPosition(n.createElement("fieldset"))}),ja(function(a){return a.innerHTML="<a href='#'></a>","#"===a.firstChild.getAttribute("href")})||ka("type|href|height|width",function(a,b,c){if(!c)return a.getAttribute(b,"type"===b.toLowerCase()?1:2)}),c.attributes&&ja(function(a){return a.innerHTML="<input/>",a.firstChild.setAttribute("value",""),""===a.firstChild.getAttribute("value")})||ka("value",function(a,b,c){if(!c&&"input"===a.nodeName.toLowerCase())return a.defaultValue}),ja(function(a){return null==a.getAttribute("disabled")})||ka(J,function(a,b,c){var d;if(!c)return a[b]===!0?b.toLowerCase():(d=a.getAttributeNode(b))&&d.specified?d.value:null}),ga}(a);r.find=x,r.expr=x.selectors,r.expr[":"]=r.expr.pseudos,r.uniqueSort=r.unique=x.uniqueSort,r.text=x.getText,r.isXMLDoc=x.isXML,r.contains=x.contains,r.escapeSelector=x.escape;var y=function(a,b,c){var d=[],e=void 0!==c;while((a=a[b])&&9!==a.nodeType)if(1===a.nodeType){if(e&&r(a).is(c))break;d.push(a)}return d},z=function(a,b){for(var c=[];a;a=a.nextSibling)1===a.nodeType&&a!==b&&c.push(a);return c},A=r.expr.match.needsContext;function B(a,b){return a.nodeName&&a.nodeName.toLowerCase()===b.toLowerCase()}var C=/^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i,D=/^.[^:#\[\.,]*$/;function E(a,b,c){return r.isFunction(b)?r.grep(a,function(a,d){return!!b.call(a,d,a)!==c}):b.nodeType?r.grep(a,function(a){return a===b!==c}):"string"!=typeof b?r.grep(a,function(a){return i.call(b,a)>-1!==c}):D.test(b)?r.filter(b,a,c):(b=r.filter(b,a),r.grep(a,function(a){return i.call(b,a)>-1!==c&&1===a.nodeType}))}r.filter=function(a,b,c){var d=b[0];return c&&(a=":not("+a+")"),1===b.length&&1===d.nodeType?r.find.matchesSelector(d,a)?[d]:[]:r.find.matches(a,r.grep(b,function(a){return 1===a.nodeType}))},r.fn.extend({find:function(a){var b,c,d=this.length,e=this;if("string"!=typeof a)return this.pushStack(r(a).filter(function(){for(b=0;b<d;b++)if(r.contains(e[b],this))return!0}));for(c=this.pushStack([]),b=0;b<d;b++)r.find(a,e[b],c);return d>1?r.uniqueSort(c):c},filter:function(a){return this.pushStack(E(this,a||[],!1))},not:function(a){return this.pushStack(E(this,a||[],!0))},is:function(a){return!!E(this,"string"==typeof a&&A.test(a)?r(a):a||[],!1).length}});var F,G=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]+))$/,H=r.fn.init=function(a,b,c){var e,f;if(!a)return this;if(c=c||F,"string"==typeof a){if(e="<"===a[0]&&">"===a[a.length-1]&&a.length>=3?[null,a,null]:G.exec(a),!e||!e[1]&&b)return!b||b.jquery?(b||c).find(a):this.constructor(b).find(a);if(e[1]){if(b=b instanceof r?b[0]:b,r.merge(this,r.parseHTML(e[1],b&&b.nodeType?b.ownerDocument||b:d,!0)),C.test(e[1])&&r.isPlainObject(b))for(e in b)r.isFunction(this[e])?this[e](b[e]):this.attr(e,b[e]);return this}return f=d.getElementById(e[2]),f&&(this[0]=f,this.length=1),this}return a.nodeType?(this[0]=a,this.length=1,this):r.isFunction(a)?void 0!==c.ready?c.ready(a):a(r):r.makeArray(a,this)};H.prototype=r.fn,F=r(d);var I=/^(?:parents|prev(?:Until|All))/,J={children:!0,contents:!0,next:!0,prev:!0};r.fn.extend({has:function(a){var b=r(a,this),c=b.length;return this.filter(function(){for(var a=0;a<c;a++)if(r.contains(this,b[a]))return!0})},closest:function(a,b){var c,d=0,e=this.length,f=[],g="string"!=typeof a&&r(a);if(!A.test(a))for(;d<e;d++)for(c=this[d];c&&c!==b;c=c.parentNode)if(c.nodeType<11&&(g?g.index(c)>-1:1===c.nodeType&&r.find.matchesSelector(c,a))){f.push(c);break}return this.pushStack(f.length>1?r.uniqueSort(f):f)},index:function(a){return a?"string"==typeof a?i.call(r(a),this[0]):i.call(this,a.jquery?a[0]:a):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(a,b){return this.pushStack(r.uniqueSort(r.merge(this.get(),r(a,b))))},addBack:function(a){return this.add(null==a?this.prevObject:this.prevObject.filter(a))}});function K(a,b){while((a=a[b])&&1!==a.nodeType);return a}r.each({parent:function(a){var b=a.parentNode;return b&&11!==b.nodeType?b:null},parents:function(a){return y(a,"parentNode")},parentsUntil:function(a,b,c){return y(a,"parentNode",c)},next:function(a){return K(a,"nextSibling")},prev:function(a){return K(a,"previousSibling")},nextAll:function(a){return y(a,"nextSibling")},prevAll:function(a){return y(a,"previousSibling")},nextUntil:function(a,b,c){return y(a,"nextSibling",c)},prevUntil:function(a,b,c){return y(a,"previousSibling",c)},siblings:function(a){return z((a.parentNode||{}).firstChild,a)},children:function(a){return z(a.firstChild)},contents:function(a){return B(a,"iframe")?a.contentDocument:(B(a,"template")&&(a=a.content||a),r.merge([],a.childNodes))}},function(a,b){r.fn[a]=function(c,d){var e=r.map(this,b,c);return"Until"!==a.slice(-5)&&(d=c),d&&"string"==typeof d&&(e=r.filter(d,e)),this.length>1&&(J[a]||r.uniqueSort(e),I.test(a)&&e.reverse()),this.pushStack(e)}});var L=/[^\x20\t\r\n\f]+/g;function M(a){var b={};return r.each(a.match(L)||[],function(a,c){b[c]=!0}),b}r.Callbacks=function(a){a="string"==typeof a?M(a):r.extend({},a);var b,c,d,e,f=[],g=[],h=-1,i=function(){for(e=e||a.once,d=b=!0;g.length;h=-1){c=g.shift();while(++h<f.length)f[h].apply(c[0],c[1])===!1&&a.stopOnFalse&&(h=f.length,c=!1)}a.memory||(c=!1),b=!1,e&&(f=c?[]:"")},j={add:function(){return f&&(c&&!b&&(h=f.length-1,g.push(c)),function d(b){r.each(b,function(b,c){r.isFunction(c)?a.unique&&j.has(c)||f.push(c):c&&c.length&&"string"!==r.type(c)&&d(c)})}(arguments),c&&!b&&i()),this},remove:function(){return r.each(arguments,function(a,b){var c;while((c=r.inArray(b,f,c))>-1)f.splice(c,1),c<=h&&h--}),this},has:function(a){return a?r.inArray(a,f)>-1:f.length>0},empty:function(){return f&&(f=[]),this},disable:function(){return e=g=[],f=c="",this},disabled:function(){return!f},lock:function(){return e=g=[],c||b||(f=c=""),this},locked:function(){return!!e},fireWith:function(a,c){return e||(c=c||[],c=[a,c.slice?c.slice():c],g.push(c),b||i()),this},fire:function(){return j.fireWith(this,arguments),this},fired:function(){return!!d}};return j};function N(a){return a}function O(a){throw a}function P(a,b,c,d){var e;try{a&&r.isFunction(e=a.promise)?e.call(a).done(b).fail(c):a&&r.isFunction(e=a.then)?e.call(a,b,c):b.apply(void 0,[a].slice(d))}catch(a){c.apply(void 0,[a])}}r.extend({Deferred:function(b){var c=[["notify","progress",r.Callbacks("memory"),r.Callbacks("memory"),2],["resolve","done",r.Callbacks("once memory"),r.Callbacks("once memory"),0,"resolved"],["reject","fail",r.Callbacks("once memory"),r.Callbacks("once memory"),1,"rejected"]],d="pending",e={state:function(){return d},always:function(){return f.done(arguments).fail(arguments),this},"catch":function(a){return e.then(null,a)},pipe:function(){var a=arguments;return r.Deferred(function(b){r.each(c,function(c,d){var e=r.isFunction(a[d[4]])&&a[d[4]];f[d[1]](function(){var a=e&&e.apply(this,arguments);a&&r.isFunction(a.promise)?a.promise().progress(b.notify).done(b.resolve).fail(b.reject):b[d[0]+"With"](this,e?[a]:arguments)})}),a=null}).promise()},then:function(b,d,e){var f=0;function g(b,c,d,e){return function(){var h=this,i=arguments,j=function(){var a,j;if(!(b<f)){if(a=d.apply(h,i),a===c.promise())throw new TypeError("Thenable self-resolution");j=a&&("object"==typeof a||"function"==typeof a)&&a.then,r.isFunction(j)?e?j.call(a,g(f,c,N,e),g(f,c,O,e)):(f++,j.call(a,g(f,c,N,e),g(f,c,O,e),g(f,c,N,c.notifyWith))):(d!==N&&(h=void 0,i=[a]),(e||c.resolveWith)(h,i))}},k=e?j:function(){try{j()}catch(a){r.Deferred.exceptionHook&&r.Deferred.exceptionHook(a,k.stackTrace),b+1>=f&&(d!==O&&(h=void 0,i=[a]),c.rejectWith(h,i))}};b?k():(r.Deferred.getStackHook&&(k.stackTrace=r.Deferred.getStackHook()),a.setTimeout(k))}}return r.Deferred(function(a){c[0][3].add(g(0,a,r.isFunction(e)?e:N,a.notifyWith)),c[1][3].add(g(0,a,r.isFunction(b)?b:N)),c[2][3].add(g(0,a,r.isFunction(d)?d:O))}).promise()},promise:function(a){return null!=a?r.extend(a,e):e}},f={};return r.each(c,function(a,b){var g=b[2],h=b[5];e[b[1]]=g.add,h&&g.add(function(){d=h},c[3-a][2].disable,c[0][2].lock),g.add(b[3].fire),f[b[0]]=function(){return f[b[0]+"With"](this===f?void 0:this,arguments),this},f[b[0]+"With"]=g.fireWith}),e.promise(f),b&&b.call(f,f),f},when:function(a){var b=arguments.length,c=b,d=Array(c),e=f.call(arguments),g=r.Deferred(),h=function(a){return function(c){d[a]=this,e[a]=arguments.length>1?f.call(arguments):c,--b||g.resolveWith(d,e)}};if(b<=1&&(P(a,g.done(h(c)).resolve,g.reject,!b),"pending"===g.state()||r.isFunction(e[c]&&e[c].then)))return g.then();while(c--)P(e[c],h(c),g.reject);return g.promise()}});var Q=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;r.Deferred.exceptionHook=function(b,c){a.console&&a.console.warn&&b&&Q.test(b.name)&&a.console.warn("jQuery.Deferred exception: "+b.message,b.stack,c)},r.readyException=function(b){a.setTimeout(function(){throw b})};var R=r.Deferred();r.fn.ready=function(a){return R.then(a)["catch"](function(a){r.readyException(a)}),this},r.extend({isReady:!1,readyWait:1,ready:function(a){(a===!0?--r.readyWait:r.isReady)||(r.isReady=!0,a!==!0&&--r.readyWait>0||R.resolveWith(d,[r]))}}),r.ready.then=R.then;function S(){d.removeEventListener("DOMContentLoaded",S),
a.removeEventListener("load",S),r.ready()}"complete"===d.readyState||"loading"!==d.readyState&&!d.documentElement.doScroll?a.setTimeout(r.ready):(d.addEventListener("DOMContentLoaded",S),a.addEventListener("load",S));var T=function(a,b,c,d,e,f,g){var h=0,i=a.length,j=null==c;if("object"===r.type(c)){e=!0;for(h in c)T(a,b,h,c[h],!0,f,g)}else if(void 0!==d&&(e=!0,r.isFunction(d)||(g=!0),j&&(g?(b.call(a,d),b=null):(j=b,b=function(a,b,c){return j.call(r(a),c)})),b))for(;h<i;h++)b(a[h],c,g?d:d.call(a[h],h,b(a[h],c)));return e?a:j?b.call(a):i?b(a[0],c):f},U=function(a){return 1===a.nodeType||9===a.nodeType||!+a.nodeType};function V(){this.expando=r.expando+V.uid++}V.uid=1,V.prototype={cache:function(a){var b=a[this.expando];return b||(b={},U(a)&&(a.nodeType?a[this.expando]=b:Object.defineProperty(a,this.expando,{value:b,configurable:!0}))),b},set:function(a,b,c){var d,e=this.cache(a);if("string"==typeof b)e[r.camelCase(b)]=c;else for(d in b)e[r.camelCase(d)]=b[d];return e},get:function(a,b){return void 0===b?this.cache(a):a[this.expando]&&a[this.expando][r.camelCase(b)]},access:function(a,b,c){return void 0===b||b&&"string"==typeof b&&void 0===c?this.get(a,b):(this.set(a,b,c),void 0!==c?c:b)},remove:function(a,b){var c,d=a[this.expando];if(void 0!==d){if(void 0!==b){Array.isArray(b)?b=b.map(r.camelCase):(b=r.camelCase(b),b=b in d?[b]:b.match(L)||[]),c=b.length;while(c--)delete d[b[c]]}(void 0===b||r.isEmptyObject(d))&&(a.nodeType?a[this.expando]=void 0:delete a[this.expando])}},hasData:function(a){var b=a[this.expando];return void 0!==b&&!r.isEmptyObject(b)}};var W=new V,X=new V,Y=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,Z=/[A-Z]/g;function $(a){return"true"===a||"false"!==a&&("null"===a?null:a===+a+""?+a:Y.test(a)?JSON.parse(a):a)}function _(a,b,c){var d;if(void 0===c&&1===a.nodeType)if(d="data-"+b.replace(Z,"-$&").toLowerCase(),c=a.getAttribute(d),"string"==typeof c){try{c=$(c)}catch(e){}X.set(a,b,c)}else c=void 0;return c}r.extend({hasData:function(a){return X.hasData(a)||W.hasData(a)},data:function(a,b,c){return X.access(a,b,c)},removeData:function(a,b){X.remove(a,b)},_data:function(a,b,c){return W.access(a,b,c)},_removeData:function(a,b){W.remove(a,b)}}),r.fn.extend({data:function(a,b){var c,d,e,f=this[0],g=f&&f.attributes;if(void 0===a){if(this.length&&(e=X.get(f),1===f.nodeType&&!W.get(f,"hasDataAttrs"))){c=g.length;while(c--)g[c]&&(d=g[c].name,0===d.indexOf("data-")&&(d=r.camelCase(d.slice(5)),_(f,d,e[d])));W.set(f,"hasDataAttrs",!0)}return e}return"object"==typeof a?this.each(function(){X.set(this,a)}):T(this,function(b){var c;if(f&&void 0===b){if(c=X.get(f,a),void 0!==c)return c;if(c=_(f,a),void 0!==c)return c}else this.each(function(){X.set(this,a,b)})},null,b,arguments.length>1,null,!0)},removeData:function(a){return this.each(function(){X.remove(this,a)})}}),r.extend({queue:function(a,b,c){var d;if(a)return b=(b||"fx")+"queue",d=W.get(a,b),c&&(!d||Array.isArray(c)?d=W.access(a,b,r.makeArray(c)):d.push(c)),d||[]},dequeue:function(a,b){b=b||"fx";var c=r.queue(a,b),d=c.length,e=c.shift(),f=r._queueHooks(a,b),g=function(){r.dequeue(a,b)};"inprogress"===e&&(e=c.shift(),d--),e&&("fx"===b&&c.unshift("inprogress"),delete f.stop,e.call(a,g,f)),!d&&f&&f.empty.fire()},_queueHooks:function(a,b){var c=b+"queueHooks";return W.get(a,c)||W.access(a,c,{empty:r.Callbacks("once memory").add(function(){W.remove(a,[b+"queue",c])})})}}),r.fn.extend({queue:function(a,b){var c=2;return"string"!=typeof a&&(b=a,a="fx",c--),arguments.length<c?r.queue(this[0],a):void 0===b?this:this.each(function(){var c=r.queue(this,a,b);r._queueHooks(this,a),"fx"===a&&"inprogress"!==c[0]&&r.dequeue(this,a)})},dequeue:function(a){return this.each(function(){r.dequeue(this,a)})},clearQueue:function(a){return this.queue(a||"fx",[])},promise:function(a,b){var c,d=1,e=r.Deferred(),f=this,g=this.length,h=function(){--d||e.resolveWith(f,[f])};"string"!=typeof a&&(b=a,a=void 0),a=a||"fx";while(g--)c=W.get(f[g],a+"queueHooks"),c&&c.empty&&(d++,c.empty.add(h));return h(),e.promise(b)}});var aa=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,ba=new RegExp("^(?:([+-])=|)("+aa+")([a-z%]*)$","i"),ca=["Top","Right","Bottom","Left"],da=function(a,b){return a=b||a,"none"===a.style.display||""===a.style.display&&r.contains(a.ownerDocument,a)&&"none"===r.css(a,"display")},ea=function(a,b,c,d){var e,f,g={};for(f in b)g[f]=a.style[f],a.style[f]=b[f];e=c.apply(a,d||[]);for(f in b)a.style[f]=g[f];return e};function fa(a,b,c,d){var e,f=1,g=20,h=d?function(){return d.cur()}:function(){return r.css(a,b,"")},i=h(),j=c&&c[3]||(r.cssNumber[b]?"":"px"),k=(r.cssNumber[b]||"px"!==j&&+i)&&ba.exec(r.css(a,b));if(k&&k[3]!==j){j=j||k[3],c=c||[],k=+i||1;do f=f||".5",k/=f,r.style(a,b,k+j);while(f!==(f=h()/i)&&1!==f&&--g)}return c&&(k=+k||+i||0,e=c[1]?k+(c[1]+1)*c[2]:+c[2],d&&(d.unit=j,d.start=k,d.end=e)),e}var ga={};function ha(a){var b,c=a.ownerDocument,d=a.nodeName,e=ga[d];return e?e:(b=c.body.appendChild(c.createElement(d)),e=r.css(b,"display"),b.parentNode.removeChild(b),"none"===e&&(e="block"),ga[d]=e,e)}function ia(a,b){for(var c,d,e=[],f=0,g=a.length;f<g;f++)d=a[f],d.style&&(c=d.style.display,b?("none"===c&&(e[f]=W.get(d,"display")||null,e[f]||(d.style.display="")),""===d.style.display&&da(d)&&(e[f]=ha(d))):"none"!==c&&(e[f]="none",W.set(d,"display",c)));for(f=0;f<g;f++)null!=e[f]&&(a[f].style.display=e[f]);return a}r.fn.extend({show:function(){return ia(this,!0)},hide:function(){return ia(this)},toggle:function(a){return"boolean"==typeof a?a?this.show():this.hide():this.each(function(){da(this)?r(this).show():r(this).hide()})}});var ja=/^(?:checkbox|radio)$/i,ka=/<([a-z][^\/\0>\x20\t\r\n\f]+)/i,la=/^$|\/(?:java|ecma)script/i,ma={option:[1,"<select multiple='multiple'>","</select>"],thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};ma.optgroup=ma.option,ma.tbody=ma.tfoot=ma.colgroup=ma.caption=ma.thead,ma.th=ma.td;function na(a,b){var c;return c="undefined"!=typeof a.getElementsByTagName?a.getElementsByTagName(b||"*"):"undefined"!=typeof a.querySelectorAll?a.querySelectorAll(b||"*"):[],void 0===b||b&&B(a,b)?r.merge([a],c):c}function oa(a,b){for(var c=0,d=a.length;c<d;c++)W.set(a[c],"globalEval",!b||W.get(b[c],"globalEval"))}var pa=/<|&#?\w+;/;function qa(a,b,c,d,e){for(var f,g,h,i,j,k,l=b.createDocumentFragment(),m=[],n=0,o=a.length;n<o;n++)if(f=a[n],f||0===f)if("object"===r.type(f))r.merge(m,f.nodeType?[f]:f);else if(pa.test(f)){g=g||l.appendChild(b.createElement("div")),h=(ka.exec(f)||["",""])[1].toLowerCase(),i=ma[h]||ma._default,g.innerHTML=i[1]+r.htmlPrefilter(f)+i[2],k=i[0];while(k--)g=g.lastChild;r.merge(m,g.childNodes),g=l.firstChild,g.textContent=""}else m.push(b.createTextNode(f));l.textContent="",n=0;while(f=m[n++])if(d&&r.inArray(f,d)>-1)e&&e.push(f);else if(j=r.contains(f.ownerDocument,f),g=na(l.appendChild(f),"script"),j&&oa(g),c){k=0;while(f=g[k++])la.test(f.type||"")&&c.push(f)}return l}!function(){var a=d.createDocumentFragment(),b=a.appendChild(d.createElement("div")),c=d.createElement("input");c.setAttribute("type","radio"),c.setAttribute("checked","checked"),c.setAttribute("name","t"),b.appendChild(c),o.checkClone=b.cloneNode(!0).cloneNode(!0).lastChild.checked,b.innerHTML="<textarea>x</textarea>",o.noCloneChecked=!!b.cloneNode(!0).lastChild.defaultValue}();var ra=d.documentElement,sa=/^key/,ta=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,ua=/^([^.]*)(?:\.(.+)|)/;function va(){return!0}function wa(){return!1}function xa(){try{return d.activeElement}catch(a){}}function ya(a,b,c,d,e,f){var g,h;if("object"==typeof b){"string"!=typeof c&&(d=d||c,c=void 0);for(h in b)ya(a,h,c,d,b[h],f);return a}if(null==d&&null==e?(e=c,d=c=void 0):null==e&&("string"==typeof c?(e=d,d=void 0):(e=d,d=c,c=void 0)),e===!1)e=wa;else if(!e)return a;return 1===f&&(g=e,e=function(a){return r().off(a),g.apply(this,arguments)},e.guid=g.guid||(g.guid=r.guid++)),a.each(function(){r.event.add(this,b,e,d,c)})}r.event={global:{},add:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,n,o,p,q=W.get(a);if(q){c.handler&&(f=c,c=f.handler,e=f.selector),e&&r.find.matchesSelector(ra,e),c.guid||(c.guid=r.guid++),(i=q.events)||(i=q.events={}),(g=q.handle)||(g=q.handle=function(b){return"undefined"!=typeof r&&r.event.triggered!==b.type?r.event.dispatch.apply(a,arguments):void 0}),b=(b||"").match(L)||[""],j=b.length;while(j--)h=ua.exec(b[j])||[],n=p=h[1],o=(h[2]||"").split(".").sort(),n&&(l=r.event.special[n]||{},n=(e?l.delegateType:l.bindType)||n,l=r.event.special[n]||{},k=r.extend({type:n,origType:p,data:d,handler:c,guid:c.guid,selector:e,needsContext:e&&r.expr.match.needsContext.test(e),namespace:o.join(".")},f),(m=i[n])||(m=i[n]=[],m.delegateCount=0,l.setup&&l.setup.call(a,d,o,g)!==!1||a.addEventListener&&a.addEventListener(n,g)),l.add&&(l.add.call(a,k),k.handler.guid||(k.handler.guid=c.guid)),e?m.splice(m.delegateCount++,0,k):m.push(k),r.event.global[n]=!0)}},remove:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,n,o,p,q=W.hasData(a)&&W.get(a);if(q&&(i=q.events)){b=(b||"").match(L)||[""],j=b.length;while(j--)if(h=ua.exec(b[j])||[],n=p=h[1],o=(h[2]||"").split(".").sort(),n){l=r.event.special[n]||{},n=(d?l.delegateType:l.bindType)||n,m=i[n]||[],h=h[2]&&new RegExp("(^|\\.)"+o.join("\\.(?:.*\\.|)")+"(\\.|$)"),g=f=m.length;while(f--)k=m[f],!e&&p!==k.origType||c&&c.guid!==k.guid||h&&!h.test(k.namespace)||d&&d!==k.selector&&("**"!==d||!k.selector)||(m.splice(f,1),k.selector&&m.delegateCount--,l.remove&&l.remove.call(a,k));g&&!m.length&&(l.teardown&&l.teardown.call(a,o,q.handle)!==!1||r.removeEvent(a,n,q.handle),delete i[n])}else for(n in i)r.event.remove(a,n+b[j],c,d,!0);r.isEmptyObject(i)&&W.remove(a,"handle events")}},dispatch:function(a){var b=r.event.fix(a),c,d,e,f,g,h,i=new Array(arguments.length),j=(W.get(this,"events")||{})[b.type]||[],k=r.event.special[b.type]||{};for(i[0]=b,c=1;c<arguments.length;c++)i[c]=arguments[c];if(b.delegateTarget=this,!k.preDispatch||k.preDispatch.call(this,b)!==!1){h=r.event.handlers.call(this,b,j),c=0;while((f=h[c++])&&!b.isPropagationStopped()){b.currentTarget=f.elem,d=0;while((g=f.handlers[d++])&&!b.isImmediatePropagationStopped())b.rnamespace&&!b.rnamespace.test(g.namespace)||(b.handleObj=g,b.data=g.data,e=((r.event.special[g.origType]||{}).handle||g.handler).apply(f.elem,i),void 0!==e&&(b.result=e)===!1&&(b.preventDefault(),b.stopPropagation()))}return k.postDispatch&&k.postDispatch.call(this,b),b.result}},handlers:function(a,b){var c,d,e,f,g,h=[],i=b.delegateCount,j=a.target;if(i&&j.nodeType&&!("click"===a.type&&a.button>=1))for(;j!==this;j=j.parentNode||this)if(1===j.nodeType&&("click"!==a.type||j.disabled!==!0)){for(f=[],g={},c=0;c<i;c++)d=b[c],e=d.selector+" ",void 0===g[e]&&(g[e]=d.needsContext?r(e,this).index(j)>-1:r.find(e,this,null,[j]).length),g[e]&&f.push(d);f.length&&h.push({elem:j,handlers:f})}return j=this,i<b.length&&h.push({elem:j,handlers:b.slice(i)}),h},addProp:function(a,b){Object.defineProperty(r.Event.prototype,a,{enumerable:!0,configurable:!0,get:r.isFunction(b)?function(){if(this.originalEvent)return b(this.originalEvent)}:function(){if(this.originalEvent)return this.originalEvent[a]},set:function(b){Object.defineProperty(this,a,{enumerable:!0,configurable:!0,writable:!0,value:b})}})},fix:function(a){return a[r.expando]?a:new r.Event(a)},special:{load:{noBubble:!0},focus:{trigger:function(){if(this!==xa()&&this.focus)return this.focus(),!1},delegateType:"focusin"},blur:{trigger:function(){if(this===xa()&&this.blur)return this.blur(),!1},delegateType:"focusout"},click:{trigger:function(){if("checkbox"===this.type&&this.click&&B(this,"input"))return this.click(),!1},_default:function(a){return B(a.target,"a")}},beforeunload:{postDispatch:function(a){void 0!==a.result&&a.originalEvent&&(a.originalEvent.returnValue=a.result)}}}},r.removeEvent=function(a,b,c){a.removeEventListener&&a.removeEventListener(b,c)},r.Event=function(a,b){return this instanceof r.Event?(a&&a.type?(this.originalEvent=a,this.type=a.type,this.isDefaultPrevented=a.defaultPrevented||void 0===a.defaultPrevented&&a.returnValue===!1?va:wa,this.target=a.target&&3===a.target.nodeType?a.target.parentNode:a.target,this.currentTarget=a.currentTarget,this.relatedTarget=a.relatedTarget):this.type=a,b&&r.extend(this,b),this.timeStamp=a&&a.timeStamp||r.now(),void(this[r.expando]=!0)):new r.Event(a,b)},r.Event.prototype={constructor:r.Event,isDefaultPrevented:wa,isPropagationStopped:wa,isImmediatePropagationStopped:wa,isSimulated:!1,preventDefault:function(){var a=this.originalEvent;this.isDefaultPrevented=va,a&&!this.isSimulated&&a.preventDefault()},stopPropagation:function(){var a=this.originalEvent;this.isPropagationStopped=va,a&&!this.isSimulated&&a.stopPropagation()},stopImmediatePropagation:function(){var a=this.originalEvent;this.isImmediatePropagationStopped=va,a&&!this.isSimulated&&a.stopImmediatePropagation(),this.stopPropagation()}},r.each({altKey:!0,bubbles:!0,cancelable:!0,changedTouches:!0,ctrlKey:!0,detail:!0,eventPhase:!0,metaKey:!0,pageX:!0,pageY:!0,shiftKey:!0,view:!0,"char":!0,charCode:!0,key:!0,keyCode:!0,button:!0,buttons:!0,clientX:!0,clientY:!0,offsetX:!0,offsetY:!0,pointerId:!0,pointerType:!0,screenX:!0,screenY:!0,targetTouches:!0,toElement:!0,touches:!0,which:function(a){var b=a.button;return null==a.which&&sa.test(a.type)?null!=a.charCode?a.charCode:a.keyCode:!a.which&&void 0!==b&&ta.test(a.type)?1&b?1:2&b?3:4&b?2:0:a.which}},r.event.addProp),r.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(a,b){r.event.special[a]={delegateType:b,bindType:b,handle:function(a){var c,d=this,e=a.relatedTarget,f=a.handleObj;return e&&(e===d||r.contains(d,e))||(a.type=f.origType,c=f.handler.apply(this,arguments),a.type=b),c}}}),r.fn.extend({on:function(a,b,c,d){return ya(this,a,b,c,d)},one:function(a,b,c,d){return ya(this,a,b,c,d,1)},off:function(a,b,c){var d,e;if(a&&a.preventDefault&&a.handleObj)return d=a.handleObj,r(a.delegateTarget).off(d.namespace?d.origType+"."+d.namespace:d.origType,d.selector,d.handler),this;if("object"==typeof a){for(e in a)this.off(e,b,a[e]);return this}return b!==!1&&"function"!=typeof b||(c=b,b=void 0),c===!1&&(c=wa),this.each(function(){r.event.remove(this,a,c,b)})}});var za=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([a-z][^\/\0>\x20\t\r\n\f]*)[^>]*)\/>/gi,Aa=/<script|<style|<link/i,Ba=/checked\s*(?:[^=]|=\s*.checked.)/i,Ca=/^true\/(.*)/,Da=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g;function Ea(a,b){return B(a,"table")&&B(11!==b.nodeType?b:b.firstChild,"tr")?r(">tbody",a)[0]||a:a}function Fa(a){return a.type=(null!==a.getAttribute("type"))+"/"+a.type,a}function Ga(a){var b=Ca.exec(a.type);return b?a.type=b[1]:a.removeAttribute("type"),a}function Ha(a,b){var c,d,e,f,g,h,i,j;if(1===b.nodeType){if(W.hasData(a)&&(f=W.access(a),g=W.set(b,f),j=f.events)){delete g.handle,g.events={};for(e in j)for(c=0,d=j[e].length;c<d;c++)r.event.add(b,e,j[e][c])}X.hasData(a)&&(h=X.access(a),i=r.extend({},h),X.set(b,i))}}function Ia(a,b){var c=b.nodeName.toLowerCase();"input"===c&&ja.test(a.type)?b.checked=a.checked:"input"!==c&&"textarea"!==c||(b.defaultValue=a.defaultValue)}function Ja(a,b,c,d){b=g.apply([],b);var e,f,h,i,j,k,l=0,m=a.length,n=m-1,q=b[0],s=r.isFunction(q);if(s||m>1&&"string"==typeof q&&!o.checkClone&&Ba.test(q))return a.each(function(e){var f=a.eq(e);s&&(b[0]=q.call(this,e,f.html())),Ja(f,b,c,d)});if(m&&(e=qa(b,a[0].ownerDocument,!1,a,d),f=e.firstChild,1===e.childNodes.length&&(e=f),f||d)){for(h=r.map(na(e,"script"),Fa),i=h.length;l<m;l++)j=e,l!==n&&(j=r.clone(j,!0,!0),i&&r.merge(h,na(j,"script"))),c.call(a[l],j,l);if(i)for(k=h[h.length-1].ownerDocument,r.map(h,Ga),l=0;l<i;l++)j=h[l],la.test(j.type||"")&&!W.access(j,"globalEval")&&r.contains(k,j)&&(j.src?r._evalUrl&&r._evalUrl(j.src):p(j.textContent.replace(Da,""),k))}return a}function Ka(a,b,c){for(var d,e=b?r.filter(b,a):a,f=0;null!=(d=e[f]);f++)c||1!==d.nodeType||r.cleanData(na(d)),d.parentNode&&(c&&r.contains(d.ownerDocument,d)&&oa(na(d,"script")),d.parentNode.removeChild(d));return a}r.extend({htmlPrefilter:function(a){return a.replace(za,"<$1></$2>")},clone:function(a,b,c){var d,e,f,g,h=a.cloneNode(!0),i=r.contains(a.ownerDocument,a);if(!(o.noCloneChecked||1!==a.nodeType&&11!==a.nodeType||r.isXMLDoc(a)))for(g=na(h),f=na(a),d=0,e=f.length;d<e;d++)Ia(f[d],g[d]);if(b)if(c)for(f=f||na(a),g=g||na(h),d=0,e=f.length;d<e;d++)Ha(f[d],g[d]);else Ha(a,h);return g=na(h,"script"),g.length>0&&oa(g,!i&&na(a,"script")),h},cleanData:function(a){for(var b,c,d,e=r.event.special,f=0;void 0!==(c=a[f]);f++)if(U(c)){if(b=c[W.expando]){if(b.events)for(d in b.events)e[d]?r.event.remove(c,d):r.removeEvent(c,d,b.handle);c[W.expando]=void 0}c[X.expando]&&(c[X.expando]=void 0)}}}),r.fn.extend({detach:function(a){return Ka(this,a,!0)},remove:function(a){return Ka(this,a)},text:function(a){return T(this,function(a){return void 0===a?r.text(this):this.empty().each(function(){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||(this.textContent=a)})},null,a,arguments.length)},append:function(){return Ja(this,arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=Ea(this,a);b.appendChild(a)}})},prepend:function(){return Ja(this,arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=Ea(this,a);b.insertBefore(a,b.firstChild)}})},before:function(){return Ja(this,arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this)})},after:function(){return Ja(this,arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this.nextSibling)})},empty:function(){for(var a,b=0;null!=(a=this[b]);b++)1===a.nodeType&&(r.cleanData(na(a,!1)),a.textContent="");return this},clone:function(a,b){return a=null!=a&&a,b=null==b?a:b,this.map(function(){return r.clone(this,a,b)})},html:function(a){return T(this,function(a){var b=this[0]||{},c=0,d=this.length;if(void 0===a&&1===b.nodeType)return b.innerHTML;if("string"==typeof a&&!Aa.test(a)&&!ma[(ka.exec(a)||["",""])[1].toLowerCase()]){a=r.htmlPrefilter(a);try{for(;c<d;c++)b=this[c]||{},1===b.nodeType&&(r.cleanData(na(b,!1)),b.innerHTML=a);b=0}catch(e){}}b&&this.empty().append(a)},null,a,arguments.length)},replaceWith:function(){var a=[];return Ja(this,arguments,function(b){var c=this.parentNode;r.inArray(this,a)<0&&(r.cleanData(na(this)),c&&c.replaceChild(b,this))},a)}}),r.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(a,b){r.fn[a]=function(a){for(var c,d=[],e=r(a),f=e.length-1,g=0;g<=f;g++)c=g===f?this:this.clone(!0),r(e[g])[b](c),h.apply(d,c.get());return this.pushStack(d)}});var La=/^margin/,Ma=new RegExp("^("+aa+")(?!px)[a-z%]+$","i"),Na=function(b){var c=b.ownerDocument.defaultView;return c&&c.opener||(c=a),c.getComputedStyle(b)};!function(){function b(){if(i){i.style.cssText="box-sizing:border-box;position:relative;display:block;margin:auto;border:1px;padding:1px;top:1%;width:50%",i.innerHTML="",ra.appendChild(h);var b=a.getComputedStyle(i);c="1%"!==b.top,g="2px"===b.marginLeft,e="4px"===b.width,i.style.marginRight="50%",f="4px"===b.marginRight,ra.removeChild(h),i=null}}var c,e,f,g,h=d.createElement("div"),i=d.createElement("div");i.style&&(i.style.backgroundClip="content-box",i.cloneNode(!0).style.backgroundClip="",o.clearCloneStyle="content-box"===i.style.backgroundClip,h.style.cssText="border:0;width:8px;height:0;top:0;left:-9999px;padding:0;margin-top:1px;position:absolute",h.appendChild(i),r.extend(o,{pixelPosition:function(){return b(),c},boxSizingReliable:function(){return b(),e},pixelMarginRight:function(){return b(),f},reliableMarginLeft:function(){return b(),g}}))}();function Oa(a,b,c){var d,e,f,g,h=a.style;return c=c||Na(a),c&&(g=c.getPropertyValue(b)||c[b],""!==g||r.contains(a.ownerDocument,a)||(g=r.style(a,b)),!o.pixelMarginRight()&&Ma.test(g)&&La.test(b)&&(d=h.width,e=h.minWidth,f=h.maxWidth,h.minWidth=h.maxWidth=h.width=g,g=c.width,h.width=d,h.minWidth=e,h.maxWidth=f)),void 0!==g?g+"":g}function Pa(a,b){return{get:function(){return a()?void delete this.get:(this.get=b).apply(this,arguments)}}}var Qa=/^(none|table(?!-c[ea]).+)/,Ra=/^--/,Sa={position:"absolute",visibility:"hidden",display:"block"},Ta={letterSpacing:"0",fontWeight:"400"},Ua=["Webkit","Moz","ms"],Va=d.createElement("div").style;function Wa(a){if(a in Va)return a;var b=a[0].toUpperCase()+a.slice(1),c=Ua.length;while(c--)if(a=Ua[c]+b,a in Va)return a}function Xa(a){var b=r.cssProps[a];return b||(b=r.cssProps[a]=Wa(a)||a),b}function Ya(a,b,c){var d=ba.exec(b);return d?Math.max(0,d[2]-(c||0))+(d[3]||"px"):b}function Za(a,b,c,d,e){var f,g=0;for(f=c===(d?"border":"content")?4:"width"===b?1:0;f<4;f+=2)"margin"===c&&(g+=r.css(a,c+ca[f],!0,e)),d?("content"===c&&(g-=r.css(a,"padding"+ca[f],!0,e)),"margin"!==c&&(g-=r.css(a,"border"+ca[f]+"Width",!0,e))):(g+=r.css(a,"padding"+ca[f],!0,e),"padding"!==c&&(g+=r.css(a,"border"+ca[f]+"Width",!0,e)));return g}function $a(a,b,c){var d,e=Na(a),f=Oa(a,b,e),g="border-box"===r.css(a,"boxSizing",!1,e);return Ma.test(f)?f:(d=g&&(o.boxSizingReliable()||f===a.style[b]),"auto"===f&&(f=a["offset"+b[0].toUpperCase()+b.slice(1)]),f=parseFloat(f)||0,f+Za(a,b,c||(g?"border":"content"),d,e)+"px")}r.extend({cssHooks:{opacity:{get:function(a,b){if(b){var c=Oa(a,"opacity");return""===c?"1":c}}}},cssNumber:{animationIterationCount:!0,columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{"float":"cssFloat"},style:function(a,b,c,d){if(a&&3!==a.nodeType&&8!==a.nodeType&&a.style){var e,f,g,h=r.camelCase(b),i=Ra.test(b),j=a.style;return i||(b=Xa(h)),g=r.cssHooks[b]||r.cssHooks[h],void 0===c?g&&"get"in g&&void 0!==(e=g.get(a,!1,d))?e:j[b]:(f=typeof c,"string"===f&&(e=ba.exec(c))&&e[1]&&(c=fa(a,b,e),f="number"),null!=c&&c===c&&("number"===f&&(c+=e&&e[3]||(r.cssNumber[h]?"":"px")),o.clearCloneStyle||""!==c||0!==b.indexOf("background")||(j[b]="inherit"),g&&"set"in g&&void 0===(c=g.set(a,c,d))||(i?j.setProperty(b,c):j[b]=c)),void 0)}},css:function(a,b,c,d){var e,f,g,h=r.camelCase(b),i=Ra.test(b);return i||(b=Xa(h)),g=r.cssHooks[b]||r.cssHooks[h],g&&"get"in g&&(e=g.get(a,!0,c)),void 0===e&&(e=Oa(a,b,d)),"normal"===e&&b in Ta&&(e=Ta[b]),""===c||c?(f=parseFloat(e),c===!0||isFinite(f)?f||0:e):e}}),r.each(["height","width"],function(a,b){r.cssHooks[b]={get:function(a,c,d){if(c)return!Qa.test(r.css(a,"display"))||a.getClientRects().length&&a.getBoundingClientRect().width?$a(a,b,d):ea(a,Sa,function(){return $a(a,b,d)})},set:function(a,c,d){var e,f=d&&Na(a),g=d&&Za(a,b,d,"border-box"===r.css(a,"boxSizing",!1,f),f);return g&&(e=ba.exec(c))&&"px"!==(e[3]||"px")&&(a.style[b]=c,c=r.css(a,b)),Ya(a,c,g)}}}),r.cssHooks.marginLeft=Pa(o.reliableMarginLeft,function(a,b){if(b)return(parseFloat(Oa(a,"marginLeft"))||a.getBoundingClientRect().left-ea(a,{marginLeft:0},function(){return a.getBoundingClientRect().left}))+"px"}),r.each({margin:"",padding:"",border:"Width"},function(a,b){r.cssHooks[a+b]={expand:function(c){for(var d=0,e={},f="string"==typeof c?c.split(" "):[c];d<4;d++)e[a+ca[d]+b]=f[d]||f[d-2]||f[0];return e}},La.test(a)||(r.cssHooks[a+b].set=Ya)}),r.fn.extend({css:function(a,b){return T(this,function(a,b,c){var d,e,f={},g=0;if(Array.isArray(b)){for(d=Na(a),e=b.length;g<e;g++)f[b[g]]=r.css(a,b[g],!1,d);return f}return void 0!==c?r.style(a,b,c):r.css(a,b)},a,b,arguments.length>1)}});function _a(a,b,c,d,e){return new _a.prototype.init(a,b,c,d,e)}r.Tween=_a,_a.prototype={constructor:_a,init:function(a,b,c,d,e,f){this.elem=a,this.prop=c,this.easing=e||r.easing._default,this.options=b,this.start=this.now=this.cur(),this.end=d,this.unit=f||(r.cssNumber[c]?"":"px")},cur:function(){var a=_a.propHooks[this.prop];return a&&a.get?a.get(this):_a.propHooks._default.get(this)},run:function(a){var b,c=_a.propHooks[this.prop];return this.options.duration?this.pos=b=r.easing[this.easing](a,this.options.duration*a,0,1,this.options.duration):this.pos=b=a,this.now=(this.end-this.start)*b+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),c&&c.set?c.set(this):_a.propHooks._default.set(this),this}},_a.prototype.init.prototype=_a.prototype,_a.propHooks={_default:{get:function(a){var b;return 1!==a.elem.nodeType||null!=a.elem[a.prop]&&null==a.elem.style[a.prop]?a.elem[a.prop]:(b=r.css(a.elem,a.prop,""),b&&"auto"!==b?b:0)},set:function(a){r.fx.step[a.prop]?r.fx.step[a.prop](a):1!==a.elem.nodeType||null==a.elem.style[r.cssProps[a.prop]]&&!r.cssHooks[a.prop]?a.elem[a.prop]=a.now:r.style(a.elem,a.prop,a.now+a.unit)}}},_a.propHooks.scrollTop=_a.propHooks.scrollLeft={set:function(a){a.elem.nodeType&&a.elem.parentNode&&(a.elem[a.prop]=a.now)}},r.easing={linear:function(a){return a},swing:function(a){return.5-Math.cos(a*Math.PI)/2},_default:"swing"},r.fx=_a.prototype.init,r.fx.step={};var ab,bb,cb=/^(?:toggle|show|hide)$/,db=/queueHooks$/;function eb(){bb&&(d.hidden===!1&&a.requestAnimationFrame?a.requestAnimationFrame(eb):a.setTimeout(eb,r.fx.interval),r.fx.tick())}function fb(){return a.setTimeout(function(){ab=void 0}),ab=r.now()}function gb(a,b){var c,d=0,e={height:a};for(b=b?1:0;d<4;d+=2-b)c=ca[d],e["margin"+c]=e["padding"+c]=a;return b&&(e.opacity=e.width=a),e}function hb(a,b,c){for(var d,e=(kb.tweeners[b]||[]).concat(kb.tweeners["*"]),f=0,g=e.length;f<g;f++)if(d=e[f].call(c,b,a))return d}function ib(a,b,c){var d,e,f,g,h,i,j,k,l="width"in b||"height"in b,m=this,n={},o=a.style,p=a.nodeType&&da(a),q=W.get(a,"fxshow");c.queue||(g=r._queueHooks(a,"fx"),null==g.unqueued&&(g.unqueued=0,h=g.empty.fire,g.empty.fire=function(){g.unqueued||h()}),g.unqueued++,m.always(function(){m.always(function(){g.unqueued--,r.queue(a,"fx").length||g.empty.fire()})}));for(d in b)if(e=b[d],cb.test(e)){if(delete b[d],f=f||"toggle"===e,e===(p?"hide":"show")){if("show"!==e||!q||void 0===q[d])continue;p=!0}n[d]=q&&q[d]||r.style(a,d)}if(i=!r.isEmptyObject(b),i||!r.isEmptyObject(n)){l&&1===a.nodeType&&(c.overflow=[o.overflow,o.overflowX,o.overflowY],j=q&&q.display,null==j&&(j=W.get(a,"display")),k=r.css(a,"display"),"none"===k&&(j?k=j:(ia([a],!0),j=a.style.display||j,k=r.css(a,"display"),ia([a]))),("inline"===k||"inline-block"===k&&null!=j)&&"none"===r.css(a,"float")&&(i||(m.done(function(){o.display=j}),null==j&&(k=o.display,j="none"===k?"":k)),o.display="inline-block")),c.overflow&&(o.overflow="hidden",m.always(function(){o.overflow=c.overflow[0],o.overflowX=c.overflow[1],o.overflowY=c.overflow[2]})),i=!1;for(d in n)i||(q?"hidden"in q&&(p=q.hidden):q=W.access(a,"fxshow",{display:j}),f&&(q.hidden=!p),p&&ia([a],!0),m.done(function(){p||ia([a]),W.remove(a,"fxshow");for(d in n)r.style(a,d,n[d])})),i=hb(p?q[d]:0,d,m),d in q||(q[d]=i.start,p&&(i.end=i.start,i.start=0))}}function jb(a,b){var c,d,e,f,g;for(c in a)if(d=r.camelCase(c),e=b[d],f=a[c],Array.isArray(f)&&(e=f[1],f=a[c]=f[0]),c!==d&&(a[d]=f,delete a[c]),g=r.cssHooks[d],g&&"expand"in g){f=g.expand(f),delete a[d];for(c in f)c in a||(a[c]=f[c],b[c]=e)}else b[d]=e}function kb(a,b,c){var d,e,f=0,g=kb.prefilters.length,h=r.Deferred().always(function(){delete i.elem}),i=function(){if(e)return!1;for(var b=ab||fb(),c=Math.max(0,j.startTime+j.duration-b),d=c/j.duration||0,f=1-d,g=0,i=j.tweens.length;g<i;g++)j.tweens[g].run(f);return h.notifyWith(a,[j,f,c]),f<1&&i?c:(i||h.notifyWith(a,[j,1,0]),h.resolveWith(a,[j]),!1)},j=h.promise({elem:a,props:r.extend({},b),opts:r.extend(!0,{specialEasing:{},easing:r.easing._default},c),originalProperties:b,originalOptions:c,startTime:ab||fb(),duration:c.duration,tweens:[],createTween:function(b,c){var d=r.Tween(a,j.opts,b,c,j.opts.specialEasing[b]||j.opts.easing);return j.tweens.push(d),d},stop:function(b){var c=0,d=b?j.tweens.length:0;if(e)return this;for(e=!0;c<d;c++)j.tweens[c].run(1);return b?(h.notifyWith(a,[j,1,0]),h.resolveWith(a,[j,b])):h.rejectWith(a,[j,b]),this}}),k=j.props;for(jb(k,j.opts.specialEasing);f<g;f++)if(d=kb.prefilters[f].call(j,a,k,j.opts))return r.isFunction(d.stop)&&(r._queueHooks(j.elem,j.opts.queue).stop=r.proxy(d.stop,d)),d;return r.map(k,hb,j),r.isFunction(j.opts.start)&&j.opts.start.call(a,j),j.progress(j.opts.progress).done(j.opts.done,j.opts.complete).fail(j.opts.fail).always(j.opts.always),r.fx.timer(r.extend(i,{elem:a,anim:j,queue:j.opts.queue})),j}r.Animation=r.extend(kb,{tweeners:{"*":[function(a,b){var c=this.createTween(a,b);return fa(c.elem,a,ba.exec(b),c),c}]},tweener:function(a,b){r.isFunction(a)?(b=a,a=["*"]):a=a.match(L);for(var c,d=0,e=a.length;d<e;d++)c=a[d],kb.tweeners[c]=kb.tweeners[c]||[],kb.tweeners[c].unshift(b)},prefilters:[ib],prefilter:function(a,b){b?kb.prefilters.unshift(a):kb.prefilters.push(a)}}),r.speed=function(a,b,c){var d=a&&"object"==typeof a?r.extend({},a):{complete:c||!c&&b||r.isFunction(a)&&a,duration:a,easing:c&&b||b&&!r.isFunction(b)&&b};return r.fx.off?d.duration=0:"number"!=typeof d.duration&&(d.duration in r.fx.speeds?d.duration=r.fx.speeds[d.duration]:d.duration=r.fx.speeds._default),null!=d.queue&&d.queue!==!0||(d.queue="fx"),d.old=d.complete,d.complete=function(){r.isFunction(d.old)&&d.old.call(this),d.queue&&r.dequeue(this,d.queue)},d},r.fn.extend({fadeTo:function(a,b,c,d){return this.filter(da).css("opacity",0).show().end().animate({opacity:b},a,c,d)},animate:function(a,b,c,d){var e=r.isEmptyObject(a),f=r.speed(b,c,d),g=function(){var b=kb(this,r.extend({},a),f);(e||W.get(this,"finish"))&&b.stop(!0)};return g.finish=g,e||f.queue===!1?this.each(g):this.queue(f.queue,g)},stop:function(a,b,c){var d=function(a){var b=a.stop;delete a.stop,b(c)};return"string"!=typeof a&&(c=b,b=a,a=void 0),b&&a!==!1&&this.queue(a||"fx",[]),this.each(function(){var b=!0,e=null!=a&&a+"queueHooks",f=r.timers,g=W.get(this);if(e)g[e]&&g[e].stop&&d(g[e]);else for(e in g)g[e]&&g[e].stop&&db.test(e)&&d(g[e]);for(e=f.length;e--;)f[e].elem!==this||null!=a&&f[e].queue!==a||(f[e].anim.stop(c),b=!1,f.splice(e,1));!b&&c||r.dequeue(this,a)})},finish:function(a){return a!==!1&&(a=a||"fx"),this.each(function(){var b,c=W.get(this),d=c[a+"queue"],e=c[a+"queueHooks"],f=r.timers,g=d?d.length:0;for(c.finish=!0,r.queue(this,a,[]),e&&e.stop&&e.stop.call(this,!0),b=f.length;b--;)f[b].elem===this&&f[b].queue===a&&(f[b].anim.stop(!0),f.splice(b,1));for(b=0;b<g;b++)d[b]&&d[b].finish&&d[b].finish.call(this);delete c.finish})}}),r.each(["toggle","show","hide"],function(a,b){var c=r.fn[b];r.fn[b]=function(a,d,e){return null==a||"boolean"==typeof a?c.apply(this,arguments):this.animate(gb(b,!0),a,d,e)}}),r.each({slideDown:gb("show"),slideUp:gb("hide"),slideToggle:gb("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(a,b){r.fn[a]=function(a,c,d){return this.animate(b,a,c,d)}}),r.timers=[],r.fx.tick=function(){var a,b=0,c=r.timers;for(ab=r.now();b<c.length;b++)a=c[b],a()||c[b]!==a||c.splice(b--,1);c.length||r.fx.stop(),ab=void 0},r.fx.timer=function(a){r.timers.push(a),r.fx.start()},r.fx.interval=13,r.fx.start=function(){bb||(bb=!0,eb())},r.fx.stop=function(){bb=null},r.fx.speeds={slow:600,fast:200,_default:400},r.fn.delay=function(b,c){return b=r.fx?r.fx.speeds[b]||b:b,c=c||"fx",this.queue(c,function(c,d){var e=a.setTimeout(c,b);d.stop=function(){a.clearTimeout(e)}})},function(){var a=d.createElement("input"),b=d.createElement("select"),c=b.appendChild(d.createElement("option"));a.type="checkbox",o.checkOn=""!==a.value,o.optSelected=c.selected,a=d.createElement("input"),a.value="t",a.type="radio",o.radioValue="t"===a.value}();var lb,mb=r.expr.attrHandle;r.fn.extend({attr:function(a,b){return T(this,r.attr,a,b,arguments.length>1)},removeAttr:function(a){return this.each(function(){r.removeAttr(this,a)})}}),r.extend({attr:function(a,b,c){var d,e,f=a.nodeType;if(3!==f&&8!==f&&2!==f)return"undefined"==typeof a.getAttribute?r.prop(a,b,c):(1===f&&r.isXMLDoc(a)||(e=r.attrHooks[b.toLowerCase()]||(r.expr.match.bool.test(b)?lb:void 0)),void 0!==c?null===c?void r.removeAttr(a,b):e&&"set"in e&&void 0!==(d=e.set(a,c,b))?d:(a.setAttribute(b,c+""),c):e&&"get"in e&&null!==(d=e.get(a,b))?d:(d=r.find.attr(a,b),
null==d?void 0:d))},attrHooks:{type:{set:function(a,b){if(!o.radioValue&&"radio"===b&&B(a,"input")){var c=a.value;return a.setAttribute("type",b),c&&(a.value=c),b}}}},removeAttr:function(a,b){var c,d=0,e=b&&b.match(L);if(e&&1===a.nodeType)while(c=e[d++])a.removeAttribute(c)}}),lb={set:function(a,b,c){return b===!1?r.removeAttr(a,c):a.setAttribute(c,c),c}},r.each(r.expr.match.bool.source.match(/\w+/g),function(a,b){var c=mb[b]||r.find.attr;mb[b]=function(a,b,d){var e,f,g=b.toLowerCase();return d||(f=mb[g],mb[g]=e,e=null!=c(a,b,d)?g:null,mb[g]=f),e}});var nb=/^(?:input|select|textarea|button)$/i,ob=/^(?:a|area)$/i;r.fn.extend({prop:function(a,b){return T(this,r.prop,a,b,arguments.length>1)},removeProp:function(a){return this.each(function(){delete this[r.propFix[a]||a]})}}),r.extend({prop:function(a,b,c){var d,e,f=a.nodeType;if(3!==f&&8!==f&&2!==f)return 1===f&&r.isXMLDoc(a)||(b=r.propFix[b]||b,e=r.propHooks[b]),void 0!==c?e&&"set"in e&&void 0!==(d=e.set(a,c,b))?d:a[b]=c:e&&"get"in e&&null!==(d=e.get(a,b))?d:a[b]},propHooks:{tabIndex:{get:function(a){var b=r.find.attr(a,"tabindex");return b?parseInt(b,10):nb.test(a.nodeName)||ob.test(a.nodeName)&&a.href?0:-1}}},propFix:{"for":"htmlFor","class":"className"}}),o.optSelected||(r.propHooks.selected={get:function(a){var b=a.parentNode;return b&&b.parentNode&&b.parentNode.selectedIndex,null},set:function(a){var b=a.parentNode;b&&(b.selectedIndex,b.parentNode&&b.parentNode.selectedIndex)}}),r.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){r.propFix[this.toLowerCase()]=this});function pb(a){var b=a.match(L)||[];return b.join(" ")}function qb(a){return a.getAttribute&&a.getAttribute("class")||""}r.fn.extend({addClass:function(a){var b,c,d,e,f,g,h,i=0;if(r.isFunction(a))return this.each(function(b){r(this).addClass(a.call(this,b,qb(this)))});if("string"==typeof a&&a){b=a.match(L)||[];while(c=this[i++])if(e=qb(c),d=1===c.nodeType&&" "+pb(e)+" "){g=0;while(f=b[g++])d.indexOf(" "+f+" ")<0&&(d+=f+" ");h=pb(d),e!==h&&c.setAttribute("class",h)}}return this},removeClass:function(a){var b,c,d,e,f,g,h,i=0;if(r.isFunction(a))return this.each(function(b){r(this).removeClass(a.call(this,b,qb(this)))});if(!arguments.length)return this.attr("class","");if("string"==typeof a&&a){b=a.match(L)||[];while(c=this[i++])if(e=qb(c),d=1===c.nodeType&&" "+pb(e)+" "){g=0;while(f=b[g++])while(d.indexOf(" "+f+" ")>-1)d=d.replace(" "+f+" "," ");h=pb(d),e!==h&&c.setAttribute("class",h)}}return this},toggleClass:function(a,b){var c=typeof a;return"boolean"==typeof b&&"string"===c?b?this.addClass(a):this.removeClass(a):r.isFunction(a)?this.each(function(c){r(this).toggleClass(a.call(this,c,qb(this),b),b)}):this.each(function(){var b,d,e,f;if("string"===c){d=0,e=r(this),f=a.match(L)||[];while(b=f[d++])e.hasClass(b)?e.removeClass(b):e.addClass(b)}else void 0!==a&&"boolean"!==c||(b=qb(this),b&&W.set(this,"__className__",b),this.setAttribute&&this.setAttribute("class",b||a===!1?"":W.get(this,"__className__")||""))})},hasClass:function(a){var b,c,d=0;b=" "+a+" ";while(c=this[d++])if(1===c.nodeType&&(" "+pb(qb(c))+" ").indexOf(b)>-1)return!0;return!1}});var rb=/\r/g;r.fn.extend({val:function(a){var b,c,d,e=this[0];{if(arguments.length)return d=r.isFunction(a),this.each(function(c){var e;1===this.nodeType&&(e=d?a.call(this,c,r(this).val()):a,null==e?e="":"number"==typeof e?e+="":Array.isArray(e)&&(e=r.map(e,function(a){return null==a?"":a+""})),b=r.valHooks[this.type]||r.valHooks[this.nodeName.toLowerCase()],b&&"set"in b&&void 0!==b.set(this,e,"value")||(this.value=e))});if(e)return b=r.valHooks[e.type]||r.valHooks[e.nodeName.toLowerCase()],b&&"get"in b&&void 0!==(c=b.get(e,"value"))?c:(c=e.value,"string"==typeof c?c.replace(rb,""):null==c?"":c)}}}),r.extend({valHooks:{option:{get:function(a){var b=r.find.attr(a,"value");return null!=b?b:pb(r.text(a))}},select:{get:function(a){var b,c,d,e=a.options,f=a.selectedIndex,g="select-one"===a.type,h=g?null:[],i=g?f+1:e.length;for(d=f<0?i:g?f:0;d<i;d++)if(c=e[d],(c.selected||d===f)&&!c.disabled&&(!c.parentNode.disabled||!B(c.parentNode,"optgroup"))){if(b=r(c).val(),g)return b;h.push(b)}return h},set:function(a,b){var c,d,e=a.options,f=r.makeArray(b),g=e.length;while(g--)d=e[g],(d.selected=r.inArray(r.valHooks.option.get(d),f)>-1)&&(c=!0);return c||(a.selectedIndex=-1),f}}}}),r.each(["radio","checkbox"],function(){r.valHooks[this]={set:function(a,b){if(Array.isArray(b))return a.checked=r.inArray(r(a).val(),b)>-1}},o.checkOn||(r.valHooks[this].get=function(a){return null===a.getAttribute("value")?"on":a.value})});var sb=/^(?:focusinfocus|focusoutblur)$/;r.extend(r.event,{trigger:function(b,c,e,f){var g,h,i,j,k,m,n,o=[e||d],p=l.call(b,"type")?b.type:b,q=l.call(b,"namespace")?b.namespace.split("."):[];if(h=i=e=e||d,3!==e.nodeType&&8!==e.nodeType&&!sb.test(p+r.event.triggered)&&(p.indexOf(".")>-1&&(q=p.split("."),p=q.shift(),q.sort()),k=p.indexOf(":")<0&&"on"+p,b=b[r.expando]?b:new r.Event(p,"object"==typeof b&&b),b.isTrigger=f?2:3,b.namespace=q.join("."),b.rnamespace=b.namespace?new RegExp("(^|\\.)"+q.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,b.result=void 0,b.target||(b.target=e),c=null==c?[b]:r.makeArray(c,[b]),n=r.event.special[p]||{},f||!n.trigger||n.trigger.apply(e,c)!==!1)){if(!f&&!n.noBubble&&!r.isWindow(e)){for(j=n.delegateType||p,sb.test(j+p)||(h=h.parentNode);h;h=h.parentNode)o.push(h),i=h;i===(e.ownerDocument||d)&&o.push(i.defaultView||i.parentWindow||a)}g=0;while((h=o[g++])&&!b.isPropagationStopped())b.type=g>1?j:n.bindType||p,m=(W.get(h,"events")||{})[b.type]&&W.get(h,"handle"),m&&m.apply(h,c),m=k&&h[k],m&&m.apply&&U(h)&&(b.result=m.apply(h,c),b.result===!1&&b.preventDefault());return b.type=p,f||b.isDefaultPrevented()||n._default&&n._default.apply(o.pop(),c)!==!1||!U(e)||k&&r.isFunction(e[p])&&!r.isWindow(e)&&(i=e[k],i&&(e[k]=null),r.event.triggered=p,e[p](),r.event.triggered=void 0,i&&(e[k]=i)),b.result}},simulate:function(a,b,c){var d=r.extend(new r.Event,c,{type:a,isSimulated:!0});r.event.trigger(d,null,b)}}),r.fn.extend({trigger:function(a,b){return this.each(function(){r.event.trigger(a,b,this)})},triggerHandler:function(a,b){var c=this[0];if(c)return r.event.trigger(a,b,c,!0)}}),r.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(a,b){r.fn[b]=function(a,c){return arguments.length>0?this.on(b,null,a,c):this.trigger(b)}}),r.fn.extend({hover:function(a,b){return this.mouseenter(a).mouseleave(b||a)}}),o.focusin="onfocusin"in a,o.focusin||r.each({focus:"focusin",blur:"focusout"},function(a,b){var c=function(a){r.event.simulate(b,a.target,r.event.fix(a))};r.event.special[b]={setup:function(){var d=this.ownerDocument||this,e=W.access(d,b);e||d.addEventListener(a,c,!0),W.access(d,b,(e||0)+1)},teardown:function(){var d=this.ownerDocument||this,e=W.access(d,b)-1;e?W.access(d,b,e):(d.removeEventListener(a,c,!0),W.remove(d,b))}}});var tb=a.location,ub=r.now(),vb=/\?/;r.parseXML=function(b){var c;if(!b||"string"!=typeof b)return null;try{c=(new a.DOMParser).parseFromString(b,"text/xml")}catch(d){c=void 0}return c&&!c.getElementsByTagName("parsererror").length||r.error("Invalid XML: "+b),c};var wb=/\[\]$/,xb=/\r?\n/g,yb=/^(?:submit|button|image|reset|file)$/i,zb=/^(?:input|select|textarea|keygen)/i;function Ab(a,b,c,d){var e;if(Array.isArray(b))r.each(b,function(b,e){c||wb.test(a)?d(a,e):Ab(a+"["+("object"==typeof e&&null!=e?b:"")+"]",e,c,d)});else if(c||"object"!==r.type(b))d(a,b);else for(e in b)Ab(a+"["+e+"]",b[e],c,d)}r.param=function(a,b){var c,d=[],e=function(a,b){var c=r.isFunction(b)?b():b;d[d.length]=encodeURIComponent(a)+"="+encodeURIComponent(null==c?"":c)};if(Array.isArray(a)||a.jquery&&!r.isPlainObject(a))r.each(a,function(){e(this.name,this.value)});else for(c in a)Ab(c,a[c],b,e);return d.join("&")},r.fn.extend({serialize:function(){return r.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var a=r.prop(this,"elements");return a?r.makeArray(a):this}).filter(function(){var a=this.type;return this.name&&!r(this).is(":disabled")&&zb.test(this.nodeName)&&!yb.test(a)&&(this.checked||!ja.test(a))}).map(function(a,b){var c=r(this).val();return null==c?null:Array.isArray(c)?r.map(c,function(a){return{name:b.name,value:a.replace(xb,"\r\n")}}):{name:b.name,value:c.replace(xb,"\r\n")}}).get()}});var Bb=/%20/g,Cb=/#.*$/,Db=/([?&])_=[^&]*/,Eb=/^(.*?):[ \t]*([^\r\n]*)$/gm,Fb=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,Gb=/^(?:GET|HEAD)$/,Hb=/^\/\//,Ib={},Jb={},Kb="*/".concat("*"),Lb=d.createElement("a");Lb.href=tb.href;function Mb(a){return function(b,c){"string"!=typeof b&&(c=b,b="*");var d,e=0,f=b.toLowerCase().match(L)||[];if(r.isFunction(c))while(d=f[e++])"+"===d[0]?(d=d.slice(1)||"*",(a[d]=a[d]||[]).unshift(c)):(a[d]=a[d]||[]).push(c)}}function Nb(a,b,c,d){var e={},f=a===Jb;function g(h){var i;return e[h]=!0,r.each(a[h]||[],function(a,h){var j=h(b,c,d);return"string"!=typeof j||f||e[j]?f?!(i=j):void 0:(b.dataTypes.unshift(j),g(j),!1)}),i}return g(b.dataTypes[0])||!e["*"]&&g("*")}function Ob(a,b){var c,d,e=r.ajaxSettings.flatOptions||{};for(c in b)void 0!==b[c]&&((e[c]?a:d||(d={}))[c]=b[c]);return d&&r.extend(!0,a,d),a}function Pb(a,b,c){var d,e,f,g,h=a.contents,i=a.dataTypes;while("*"===i[0])i.shift(),void 0===d&&(d=a.mimeType||b.getResponseHeader("Content-Type"));if(d)for(e in h)if(h[e]&&h[e].test(d)){i.unshift(e);break}if(i[0]in c)f=i[0];else{for(e in c){if(!i[0]||a.converters[e+" "+i[0]]){f=e;break}g||(g=e)}f=f||g}if(f)return f!==i[0]&&i.unshift(f),c[f]}function Qb(a,b,c,d){var e,f,g,h,i,j={},k=a.dataTypes.slice();if(k[1])for(g in a.converters)j[g.toLowerCase()]=a.converters[g];f=k.shift();while(f)if(a.responseFields[f]&&(c[a.responseFields[f]]=b),!i&&d&&a.dataFilter&&(b=a.dataFilter(b,a.dataType)),i=f,f=k.shift())if("*"===f)f=i;else if("*"!==i&&i!==f){if(g=j[i+" "+f]||j["* "+f],!g)for(e in j)if(h=e.split(" "),h[1]===f&&(g=j[i+" "+h[0]]||j["* "+h[0]])){g===!0?g=j[e]:j[e]!==!0&&(f=h[0],k.unshift(h[1]));break}if(g!==!0)if(g&&a["throws"])b=g(b);else try{b=g(b)}catch(l){return{state:"parsererror",error:g?l:"No conversion from "+i+" to "+f}}}return{state:"success",data:b}}r.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:tb.href,type:"GET",isLocal:Fb.test(tb.protocol),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":Kb,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/\bxml\b/,html:/\bhtml/,json:/\bjson\b/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":JSON.parse,"text xml":r.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(a,b){return b?Ob(Ob(a,r.ajaxSettings),b):Ob(r.ajaxSettings,a)},ajaxPrefilter:Mb(Ib),ajaxTransport:Mb(Jb),ajax:function(b,c){"object"==typeof b&&(c=b,b=void 0),c=c||{};var e,f,g,h,i,j,k,l,m,n,o=r.ajaxSetup({},c),p=o.context||o,q=o.context&&(p.nodeType||p.jquery)?r(p):r.event,s=r.Deferred(),t=r.Callbacks("once memory"),u=o.statusCode||{},v={},w={},x="canceled",y={readyState:0,getResponseHeader:function(a){var b;if(k){if(!h){h={};while(b=Eb.exec(g))h[b[1].toLowerCase()]=b[2]}b=h[a.toLowerCase()]}return null==b?null:b},getAllResponseHeaders:function(){return k?g:null},setRequestHeader:function(a,b){return null==k&&(a=w[a.toLowerCase()]=w[a.toLowerCase()]||a,v[a]=b),this},overrideMimeType:function(a){return null==k&&(o.mimeType=a),this},statusCode:function(a){var b;if(a)if(k)y.always(a[y.status]);else for(b in a)u[b]=[u[b],a[b]];return this},abort:function(a){var b=a||x;return e&&e.abort(b),A(0,b),this}};if(s.promise(y),o.url=((b||o.url||tb.href)+"").replace(Hb,tb.protocol+"//"),o.type=c.method||c.type||o.method||o.type,o.dataTypes=(o.dataType||"*").toLowerCase().match(L)||[""],null==o.crossDomain){j=d.createElement("a");try{j.href=o.url,j.href=j.href,o.crossDomain=Lb.protocol+"//"+Lb.host!=j.protocol+"//"+j.host}catch(z){o.crossDomain=!0}}if(o.data&&o.processData&&"string"!=typeof o.data&&(o.data=r.param(o.data,o.traditional)),Nb(Ib,o,c,y),k)return y;l=r.event&&o.global,l&&0===r.active++&&r.event.trigger("ajaxStart"),o.type=o.type.toUpperCase(),o.hasContent=!Gb.test(o.type),f=o.url.replace(Cb,""),o.hasContent?o.data&&o.processData&&0===(o.contentType||"").indexOf("application/x-www-form-urlencoded")&&(o.data=o.data.replace(Bb,"+")):(n=o.url.slice(f.length),o.data&&(f+=(vb.test(f)?"&":"?")+o.data,delete o.data),o.cache===!1&&(f=f.replace(Db,"$1"),n=(vb.test(f)?"&":"?")+"_="+ub++ +n),o.url=f+n),o.ifModified&&(r.lastModified[f]&&y.setRequestHeader("If-Modified-Since",r.lastModified[f]),r.etag[f]&&y.setRequestHeader("If-None-Match",r.etag[f])),(o.data&&o.hasContent&&o.contentType!==!1||c.contentType)&&y.setRequestHeader("Content-Type",o.contentType),y.setRequestHeader("Accept",o.dataTypes[0]&&o.accepts[o.dataTypes[0]]?o.accepts[o.dataTypes[0]]+("*"!==o.dataTypes[0]?", "+Kb+"; q=0.01":""):o.accepts["*"]);for(m in o.headers)y.setRequestHeader(m,o.headers[m]);if(o.beforeSend&&(o.beforeSend.call(p,y,o)===!1||k))return y.abort();if(x="abort",t.add(o.complete),y.done(o.success),y.fail(o.error),e=Nb(Jb,o,c,y)){if(y.readyState=1,l&&q.trigger("ajaxSend",[y,o]),k)return y;o.async&&o.timeout>0&&(i=a.setTimeout(function(){y.abort("timeout")},o.timeout));try{k=!1,e.send(v,A)}catch(z){if(k)throw z;A(-1,z)}}else A(-1,"No Transport");function A(b,c,d,h){var j,m,n,v,w,x=c;k||(k=!0,i&&a.clearTimeout(i),e=void 0,g=h||"",y.readyState=b>0?4:0,j=b>=200&&b<300||304===b,d&&(v=Pb(o,y,d)),v=Qb(o,v,y,j),j?(o.ifModified&&(w=y.getResponseHeader("Last-Modified"),w&&(r.lastModified[f]=w),w=y.getResponseHeader("etag"),w&&(r.etag[f]=w)),204===b||"HEAD"===o.type?x="nocontent":304===b?x="notmodified":(x=v.state,m=v.data,n=v.error,j=!n)):(n=x,!b&&x||(x="error",b<0&&(b=0))),y.status=b,y.statusText=(c||x)+"",j?s.resolveWith(p,[m,x,y]):s.rejectWith(p,[y,x,n]),y.statusCode(u),u=void 0,l&&q.trigger(j?"ajaxSuccess":"ajaxError",[y,o,j?m:n]),t.fireWith(p,[y,x]),l&&(q.trigger("ajaxComplete",[y,o]),--r.active||r.event.trigger("ajaxStop")))}return y},getJSON:function(a,b,c){return r.get(a,b,c,"json")},getScript:function(a,b){return r.get(a,void 0,b,"script")}}),r.each(["get","post"],function(a,b){r[b]=function(a,c,d,e){return r.isFunction(c)&&(e=e||d,d=c,c=void 0),r.ajax(r.extend({url:a,type:b,dataType:e,data:c,success:d},r.isPlainObject(a)&&a))}}),r._evalUrl=function(a){return r.ajax({url:a,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,"throws":!0})},r.fn.extend({wrapAll:function(a){var b;return this[0]&&(r.isFunction(a)&&(a=a.call(this[0])),b=r(a,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&b.insertBefore(this[0]),b.map(function(){var a=this;while(a.firstElementChild)a=a.firstElementChild;return a}).append(this)),this},wrapInner:function(a){return r.isFunction(a)?this.each(function(b){r(this).wrapInner(a.call(this,b))}):this.each(function(){var b=r(this),c=b.contents();c.length?c.wrapAll(a):b.append(a)})},wrap:function(a){var b=r.isFunction(a);return this.each(function(c){r(this).wrapAll(b?a.call(this,c):a)})},unwrap:function(a){return this.parent(a).not("body").each(function(){r(this).replaceWith(this.childNodes)}),this}}),r.expr.pseudos.hidden=function(a){return!r.expr.pseudos.visible(a)},r.expr.pseudos.visible=function(a){return!!(a.offsetWidth||a.offsetHeight||a.getClientRects().length)},r.ajaxSettings.xhr=function(){try{return new a.XMLHttpRequest}catch(b){}};var Rb={0:200,1223:204},Sb=r.ajaxSettings.xhr();o.cors=!!Sb&&"withCredentials"in Sb,o.ajax=Sb=!!Sb,r.ajaxTransport(function(b){var c,d;if(o.cors||Sb&&!b.crossDomain)return{send:function(e,f){var g,h=b.xhr();if(h.open(b.type,b.url,b.async,b.username,b.password),b.xhrFields)for(g in b.xhrFields)h[g]=b.xhrFields[g];b.mimeType&&h.overrideMimeType&&h.overrideMimeType(b.mimeType),b.crossDomain||e["X-Requested-With"]||(e["X-Requested-With"]="XMLHttpRequest");for(g in e)h.setRequestHeader(g,e[g]);c=function(a){return function(){c&&(c=d=h.onload=h.onerror=h.onabort=h.onreadystatechange=null,"abort"===a?h.abort():"error"===a?"number"!=typeof h.status?f(0,"error"):f(h.status,h.statusText):f(Rb[h.status]||h.status,h.statusText,"text"!==(h.responseType||"text")||"string"!=typeof h.responseText?{binary:h.response}:{text:h.responseText},h.getAllResponseHeaders()))}},h.onload=c(),d=h.onerror=c("error"),void 0!==h.onabort?h.onabort=d:h.onreadystatechange=function(){4===h.readyState&&a.setTimeout(function(){c&&d()})},c=c("abort");try{h.send(b.hasContent&&b.data||null)}catch(i){if(c)throw i}},abort:function(){c&&c()}}}),r.ajaxPrefilter(function(a){a.crossDomain&&(a.contents.script=!1)}),r.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(a){return r.globalEval(a),a}}}),r.ajaxPrefilter("script",function(a){void 0===a.cache&&(a.cache=!1),a.crossDomain&&(a.type="GET")}),r.ajaxTransport("script",function(a){if(a.crossDomain){var b,c;return{send:function(e,f){b=r("<script>").prop({charset:a.scriptCharset,src:a.url}).on("load error",c=function(a){b.remove(),c=null,a&&f("error"===a.type?404:200,a.type)}),d.head.appendChild(b[0])},abort:function(){c&&c()}}}});var Tb=[],Ub=/(=)\?(?=&|$)|\?\?/;r.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var a=Tb.pop()||r.expando+"_"+ub++;return this[a]=!0,a}}),r.ajaxPrefilter("json jsonp",function(b,c,d){var e,f,g,h=b.jsonp!==!1&&(Ub.test(b.url)?"url":"string"==typeof b.data&&0===(b.contentType||"").indexOf("application/x-www-form-urlencoded")&&Ub.test(b.data)&&"data");if(h||"jsonp"===b.dataTypes[0])return e=b.jsonpCallback=r.isFunction(b.jsonpCallback)?b.jsonpCallback():b.jsonpCallback,h?b[h]=b[h].replace(Ub,"$1"+e):b.jsonp!==!1&&(b.url+=(vb.test(b.url)?"&":"?")+b.jsonp+"="+e),b.converters["script json"]=function(){return g||r.error(e+" was not called"),g[0]},b.dataTypes[0]="json",f=a[e],a[e]=function(){g=arguments},d.always(function(){void 0===f?r(a).removeProp(e):a[e]=f,b[e]&&(b.jsonpCallback=c.jsonpCallback,Tb.push(e)),g&&r.isFunction(f)&&f(g[0]),g=f=void 0}),"script"}),o.createHTMLDocument=function(){var a=d.implementation.createHTMLDocument("").body;return a.innerHTML="<form></form><form></form>",2===a.childNodes.length}(),r.parseHTML=function(a,b,c){if("string"!=typeof a)return[];"boolean"==typeof b&&(c=b,b=!1);var e,f,g;return b||(o.createHTMLDocument?(b=d.implementation.createHTMLDocument(""),e=b.createElement("base"),e.href=d.location.href,b.head.appendChild(e)):b=d),f=C.exec(a),g=!c&&[],f?[b.createElement(f[1])]:(f=qa([a],b,g),g&&g.length&&r(g).remove(),r.merge([],f.childNodes))},r.fn.load=function(a,b,c){var d,e,f,g=this,h=a.indexOf(" ");return h>-1&&(d=pb(a.slice(h)),a=a.slice(0,h)),r.isFunction(b)?(c=b,b=void 0):b&&"object"==typeof b&&(e="POST"),g.length>0&&r.ajax({url:a,type:e||"GET",dataType:"html",data:b}).done(function(a){f=arguments,g.html(d?r("<div>").append(r.parseHTML(a)).find(d):a)}).always(c&&function(a,b){g.each(function(){c.apply(this,f||[a.responseText,b,a])})}),this},r.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(a,b){r.fn[b]=function(a){return this.on(b,a)}}),r.expr.pseudos.animated=function(a){return r.grep(r.timers,function(b){return a===b.elem}).length},r.offset={setOffset:function(a,b,c){var d,e,f,g,h,i,j,k=r.css(a,"position"),l=r(a),m={};"static"===k&&(a.style.position="relative"),h=l.offset(),f=r.css(a,"top"),i=r.css(a,"left"),j=("absolute"===k||"fixed"===k)&&(f+i).indexOf("auto")>-1,j?(d=l.position(),g=d.top,e=d.left):(g=parseFloat(f)||0,e=parseFloat(i)||0),r.isFunction(b)&&(b=b.call(a,c,r.extend({},h))),null!=b.top&&(m.top=b.top-h.top+g),null!=b.left&&(m.left=b.left-h.left+e),"using"in b?b.using.call(a,m):l.css(m)}},r.fn.extend({offset:function(a){if(arguments.length)return void 0===a?this:this.each(function(b){r.offset.setOffset(this,a,b)});var b,c,d,e,f=this[0];if(f)return f.getClientRects().length?(d=f.getBoundingClientRect(),b=f.ownerDocument,c=b.documentElement,e=b.defaultView,{top:d.top+e.pageYOffset-c.clientTop,left:d.left+e.pageXOffset-c.clientLeft}):{top:0,left:0}},position:function(){if(this[0]){var a,b,c=this[0],d={top:0,left:0};return"fixed"===r.css(c,"position")?b=c.getBoundingClientRect():(a=this.offsetParent(),b=this.offset(),B(a[0],"html")||(d=a.offset()),d={top:d.top+r.css(a[0],"borderTopWidth",!0),left:d.left+r.css(a[0],"borderLeftWidth",!0)}),{top:b.top-d.top-r.css(c,"marginTop",!0),left:b.left-d.left-r.css(c,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var a=this.offsetParent;while(a&&"static"===r.css(a,"position"))a=a.offsetParent;return a||ra})}}),r.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(a,b){var c="pageYOffset"===b;r.fn[a]=function(d){return T(this,function(a,d,e){var f;return r.isWindow(a)?f=a:9===a.nodeType&&(f=a.defaultView),void 0===e?f?f[b]:a[d]:void(f?f.scrollTo(c?f.pageXOffset:e,c?e:f.pageYOffset):a[d]=e)},a,d,arguments.length)}}),r.each(["top","left"],function(a,b){r.cssHooks[b]=Pa(o.pixelPosition,function(a,c){if(c)return c=Oa(a,b),Ma.test(c)?r(a).position()[b]+"px":c})}),r.each({Height:"height",Width:"width"},function(a,b){r.each({padding:"inner"+a,content:b,"":"outer"+a},function(c,d){r.fn[d]=function(e,f){var g=arguments.length&&(c||"boolean"!=typeof e),h=c||(e===!0||f===!0?"margin":"border");return T(this,function(b,c,e){var f;return r.isWindow(b)?0===d.indexOf("outer")?b["inner"+a]:b.document.documentElement["client"+a]:9===b.nodeType?(f=b.documentElement,Math.max(b.body["scroll"+a],f["scroll"+a],b.body["offset"+a],f["offset"+a],f["client"+a])):void 0===e?r.css(b,c,h):r.style(b,c,e,h)},b,g?e:void 0,g)}})}),r.fn.extend({bind:function(a,b,c){return this.on(a,null,b,c)},unbind:function(a,b){return this.off(a,null,b)},delegate:function(a,b,c,d){return this.on(b,a,c,d)},undelegate:function(a,b,c){return 1===arguments.length?this.off(a,"**"):this.off(b,a||"**",c)}}),r.holdReady=function(a){a?r.readyWait++:r.ready(!0)},r.isArray=Array.isArray,r.parseJSON=JSON.parse,r.nodeName=B,"function"==typeof define&&define.amd&&define("jquery",[],function(){return r});var Vb=a.jQuery,Wb=a.$;return r.noConflict=function(b){return a.$===r&&(a.$=Wb),b&&a.jQuery===r&&(a.jQuery=Vb),r},b||(a.jQuery=a.$=r),r});
</script>
<script>/* jquery.sparkline 2.1.3 - http://omnipotent.net/jquery.sparkline/
Licensed under the New BSD License - see above site for details */
!function(a,b,c){!function(a){"function"==typeof define&&define.amd?define("jquery.sparkline",["jquery"],a):jQuery&&!jQuery.fn.sparkline&&a(jQuery)}(function(d){"use strict";var e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,A,B,C,D,E,F,G,H,I,J,K,L,M,N={},O=0;e=function(){return{common:{type:"line",lineColor:"#00f",fillColor:"#cdf",defaultPixelsPerValue:3,width:"auto",height:"auto",composite:!1,tagValuesAttribute:"values",tagOptionsPrefix:"spark",enableTagOptions:!1,enableHighlight:!0,highlightLighten:1.4,tooltipSkipNull:!0,tooltipPrefix:"",tooltipSuffix:"",disableHiddenCheck:!1,numberFormatter:!1,numberDigitGroupCount:3,numberDigitGroupSep:",",numberDecimalMark:".",disableTooltips:!1,disableInteraction:!1},line:{spotColor:"#f80",highlightSpotColor:"#5f5",highlightLineColor:"#f22",refLineColor:"#f22",spotRadius:1.5,minSpotColor:"#f80",maxSpotColor:"#f80",lineWidth:1,normalRangeMin:c,normalRangeMax:c,normalRangeColor:"#ccc",drawNormalOnTop:!1,chartRangeMin:c,chartRangeMax:c,chartRangeMinX:c,chartRangeMaxX:c,tooltipFormat:new g('<span style="color: {{color}}">&#9679;</span> {{prefix}}{{y}}{{suffix}}')},bar:{barColor:"#3366cc",negBarColor:"#f44",stackedBarColor:["#3366cc","#dc3912","#ff9900","#109618","#66aa00","#dd4477","#0099c6","#990099"],zeroColor:c,nullColor:c,zeroAxis:!0,barWidth:4,barSpacing:1,chartRangeMax:c,chartRangeMin:c,chartRangeClip:!1,colorMap:c,tooltipFormat:new g('<span style="color: {{color}}">&#9679;</span> {{prefix}}{{value}}{{suffix}}')},timeline:{width:120,height:3,lineColor:"#6792c6",fillColor:"#bad7fb",orientation:"horizontal",timeMarkInterval:0,begin:new Date(2e3,1,1,0,0),finish:new Date(2e3,1,1,23,59),init:function(a){return{begin:new Date(a.begin),finish:new Date(a.finish),title:a.title,color:a.color}},tooltipFormat:new g('<span style="color: {{color}}">&#9679;</span> {{title}}: {{begin}} / {{finish}}')},tristate:{barWidth:4,barSpacing:1,posBarColor:"#6f6",negBarColor:"#f44",zeroBarColor:"#999",colorMap:{},tooltipFormat:new g('<span style="color: {{color}}">&#9679;</span> {{prefix}}{{value:map}}{{suffix}}'),tooltipValueLookups:{map:{"-1":"Loss",0:"Draw",1:"Win"}}},discrete:{lineHeight:"auto",thresholdColor:c,thresholdValue:0,chartRangeMax:c,chartRangeMin:c,chartRangeClip:!1,tooltipFormat:new g("{{prefix}}{{value}}{{suffix}}")},bullet:{targetColor:"#f33",targetWidth:3,performanceColor:"#33f",rangeColors:["#d3dafe","#a8b6ff","#7f94ff"],base:c,tooltipFormat:new g("{{fieldkey:fields}} - {{value}}"),tooltipValueLookups:{fields:{r:"Range",p:"Performance",t:"Target"}}},pie:{offset:0,sliceColors:["#3366cc","#dc3912","#ff9900","#109618","#66aa00","#dd4477","#0099c6","#990099"],borderWidth:0,borderColor:"#000",tooltipFormat:new g('<span style="color: {{color}}">&#9679;</span> {{prefix}}{{value}} ({{percent.1}}%){{suffix}}')},stack:{offset:0,sliceColors:["#3366cc","#dc3912","#ff9900","#109618","#66aa00","#dd4477","#0099c6","#990099"],borderWidth:0,borderColor:"#000",tooltipFormat:new g('<span style="color: {{color}}">&#9679;</span> {{value}} ({{percent.1}}%)')},box:{raw:!1,boxLineColor:"#000",boxFillColor:"#cdf",whiskerColor:"#000",outlierLineColor:"#333",outlierFillColor:"#fff",medianColor:"#f00",showOutliers:!0,outlierIQR:1.5,spotRadius:1.5,target:c,targetColor:"#4a2",chartRangeMax:c,chartRangeMin:c,tooltipFormat:new g("{{field:fields}}: {{value}}"),tooltipFormatFieldlistKey:"field",tooltipValueLookups:{fields:{lq:"Lower Quartile",med:"Median",uq:"Upper Quartile",lo:"Left Outlier",ro:"Right Outlier",lw:"Left Whisker",rw:"Right Whisker"}}}}};var P="-webkit-box-sizing: content-box !important;-moz-box-sizing: content-box !important;box-sizing: content-box !important;";G='.jqstooltip { position: absolute;left: 0px;top: 0px;visibility: hidden;background: rgb(0, 0, 0) transparent;background-color: rgba(0,0,0,0.6);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr=#99000000, endColorstr=#99000000);-ms-filter: "progid:DXImageTransform.Microsoft.gradient(startColorstr=#99000000, endColorstr=#99000000)";color: white;font: 10px arial, san serif;text-align: left;white-space: nowrap;padding: 5px;border: 1px solid white;z-index: 10000;'+P+"}.jqsfield { color: white;font: 10px arial, san serif;text-align: left;}.jqstooltip:before, .jqstooltip:after { "+P+"}",f=function(){var a,b;return a=function(){this.init.apply(this,arguments)},arguments.length>1?(arguments[0]?(a.prototype=d.extend(new arguments[0],arguments[arguments.length-1]),a._super=arguments[0].prototype):a.prototype=arguments[arguments.length-1],arguments.length>2&&(b=Array.prototype.slice.call(arguments,1,-1),b.unshift(a.prototype),d.extend.apply(d,b))):a.prototype=arguments[0],a.prototype.cls=a,a},d.SPFormatClass=g=f({fre:/\{\{([\w.]+?)(:(.+?))?\}\}/g,precre:/(\w+)\.(\d+)/,init:function(a,b){this.format=a,this.fclass=b},render:function(a,b,d){var e,f,g,h,i,j=this,k=a;return this.format.replace(this.fre,function(){var a;return f=arguments[1],g=arguments[3],e=j.precre.exec(f),e?(i=e[2],f=e[1]):i=!1,h=k[f],h===c?"":g&&b&&b[g]?(a=b[g],a.get?b[g].get(h)||h:b[g][h]||h):(n(h)&&(h=d.get("numberFormatter")?d.get("numberFormatter")(h):s(h,i,d.get("numberDigitGroupCount"),d.get("numberDigitGroupSep"),d.get("numberDecimalMark"))),h)})}}),d.spformat=function(a,b){return new g(a,b)},h=function(a,b,c){return a<b?b:a>c?c:a},i=function(a){var b,c;if(0===a.length%2){var d,e;c=a.length/2,d=a[c-1],e=a[c],b=(d+e)/2}else c=parseInt(a.length/2),b=a[c];return{m:b,idx:c}},j=function(a,b){var c,d,e;if(d=i(a),2===b)c=d.m;else{var f=[];if(e=d.m,null!=e){var g=0;if(1===b){for(;g<d.idx;)f[g]=a[g],g++;f.length||(f=[a[0]])}else if(3===b){for(var h=a.length-1;h>d.idx;)f[g]=a[h],g++,h--;f.length||(f=[a[a.length-1]])}}d=i(f),c=d.m}return c},k=function(a){var b;switch(a){case"undefined":a=c;break;case"null":a=null;break;case"true":a=!0;break;case"false":a=!1;break;default:b=parseFloat(a),a==b&&(a=b)}return a},l=function(a){var b,c=[];for(b=a.length;b--;)c[b]=k(a[b]);return c},m=function(a,b){var c,d,e=[];for(c=0,d=a.length;c<d;c++)a[c]!==b&&e.push(a[c]);return e},n=function(a){return!isNaN(parseFloat(a))&&isFinite(a)},s=function(a,b,c,e,f){var g,h;for(a=(b===!1?parseFloat(a).toString():a.toFixed(b)).split(""),g=(g=d.inArray(".",a))<0?a.length:g,g<a.length&&(a[g]=f),h=g-c;h>0;h-=c)a.splice(h,0,e);return a.join("")},o=function(a,b,c){var d;for(d=b.length;d--;)if((!c||null!==b[d])&&b[d]!==a)return!1;return!0},p=function(a){var b,c=0;for(b=a.length;b--;)c+="number"==typeof a[b]?a[b]:0;return c},r=function(a){return d.isArray(a)?a:[a]},q=function(b){var c,d;if(a.createStyleSheet)try{return void(a.createStyleSheet().cssText=b)}catch(e){d=!0}c=a.createElement("style"),c.type="text/css",a.getElementsByTagName("head")[0].appendChild(c),d?a.styleSheets[a.styleSheets.length-1].cssText=b:c["string"==typeof a.body.style.WebkitAppearance?"innerText":"innerHTML"]=b},d.fn.simpledraw=function(b,e,f,g){var h,i;if(f&&(h=this.data("_jqs_vcanvas")))return h;if(d.fn.sparkline.canvas===!1)return!1;if(d.fn.sparkline.canvas===c){var j=a.createElement("canvas");if(j.getContext&&j.getContext("2d"))d.fn.sparkline.canvas=function(a,b,c,d){return new K(a,b,c,d)};else{if(!a.namespaces||a.namespaces.v)return d.fn.sparkline.canvas=!1,!1;a.namespaces.add("v","urn:schemas-microsoft-com:vml","#default#VML"),d.fn.sparkline.canvas=function(a,b,c,d){return new L(a,b,c)}}}return b===c&&(b=d(this).innerWidth()),e===c&&(e=d(this).innerHeight()),h=d.fn.sparkline.canvas(b,e,this,g),i=d(this).data("_jqs_mhandler"),i&&i.registerCanvas(h),h},d.fn.cleardraw=function(){var a=this.data("_jqs_vcanvas");a&&a.reset()},d.RangeMapClass=t=f({init:function(a){var b,c,d=[];for(b in a)a.hasOwnProperty(b)&&"string"==typeof b&&b.indexOf(":")>-1&&(c=b.split(":"),c[0]=0===c[0].length?-(1/0):parseFloat(c[0]),c[1]=0===c[1].length?1/0:parseFloat(c[1]),c[2]=a[b],d.push(c));this.map=a,this.rangelist=d||!1},get:function(a){var b,d,e,f=this.rangelist;if((e=this.map[a])!==c)return e;if(f)for(b=f.length;b--;)if(d=f[b],d[0]<=a&&d[1]>=a)return d[2];return c}}),d.range_map=function(a){return new t(a)},u=f({init:function(a,b){var c=d(a);this.$el=c,this.options=b,this.currentPageX=0,this.currentPageY=0,this.el=a,this.splist=[],this.tooltip=null,this.over=!1,this.displayTooltips=!b.get("disableTooltips"),this.highlightEnabled=!b.get("disableHighlight")},registerSparkline:function(a){this.splist.push(a),this.over&&this.updateDisplay()},registerCanvas:function(a){var b=d(a.canvas);this.canvas=a,this.$canvas=b,b.mouseenter(d.proxy(this.mouseenter,this)),b.mouseleave(d.proxy(this.mouseleave,this)),b.click(d.proxy(this.mouseclick,this))},reset:function(a){this.splist=[],this.tooltip&&a&&(this.tooltip.remove(),this.tooltip=c)},mouseclick:function(a){var b=d.Event("sparklineClick");b.originalEvent=a,b.sparklines=this.splist,this.$el.trigger(b)},mouseenter:function(b){d(a.body).unbind("mousemove.jqs"),d(a.body).bind("mousemove.jqs",d.proxy(this.mousemove,this)),this.over=!0,this.currentPageX=b.pageX,this.currentPageY=b.pageY,this.currentEl=b.target,!this.tooltip&&this.displayTooltips&&(this.tooltip=new v(this.options),this.tooltip.updatePosition(b.pageX,b.pageY)),this.updateDisplay()},mouseleave:function(){d(a.body).unbind("mousemove.jqs");var b,c,e=this.splist,f=e.length,g=!1;for(this.over=!1,this.currentEl=null,this.tooltip&&(this.tooltip.remove(),this.tooltip=null),c=0;c<f;c++)b=e[c],b.clearRegionHighlight()&&(g=!0);g&&this.canvas.render()},mousemove:function(a){this.currentPageX=a.pageX,this.currentPageY=a.pageY,this.currentEl=a.target,this.tooltip&&this.tooltip.updatePosition(a.pageX,a.pageY),this.updateDisplay()},updateDisplay:function(){var a,c,e,f,g,h=this.splist,i=h.length,j=!1,k=this.$canvas.offset(),l=b.round(this.currentPageX-k.left),m=b.round(this.currentPageY-k.top);if(this.over){for(e=0;e<i;e++)c=h[e],f=c.setRegionHighlight(this.currentEl,l,m),f&&(j=!0);if(j){if(g=d.Event("sparklineRegionChange"),g.sparklines=this.splist,this.$el.trigger(g),this.tooltip){for(a="",e=0;e<i;e++)c=h[e],a+=c.getCurrentRegionTooltip();this.tooltip.setContent(a)}this.disableHighlight||this.canvas.render()}null===f&&this.mouseleave()}}}),v=f({sizeStyle:"position: static !important;display: block !important;visibility: hidden !important;float: left !important;",init:function(b){var c,e=b.get("tooltipClassname","jqstooltip"),f=this.sizeStyle;this.container=b.get("tooltipContainer")||a.body,this.tooltipOffsetX=b.get("tooltipOffsetX",10),this.tooltipOffsetY=b.get("tooltipOffsetY",12),this.displayOnLeft="left"===b.get("toolTipPosition"),d("#jqssizetip").remove(),d("#jqstooltip").remove(),this.sizetip=d("<div/>",{id:"jqssizetip",style:f,class:e}),this.tooltip=d("<div/>",{id:"jqstooltip",class:e}).appendTo(this.container),c=this.tooltip.offset(),this.offsetLeft=c.left,this.offsetTop=c.top,this.hidden=!0,d(window).unbind("resize.jqs scroll.jqs"),d(window).bind("resize.jqs scroll.jqs",d.proxy(this.updateWindowDims,this)),this.updateWindowDims()},updateWindowDims:function(){this.scrollTop=d(window).scrollTop(),this.scrollLeft=d(window).scrollLeft(),this.scrollRight=this.scrollLeft+d(window).width(),this.updatePosition()},getSize:function(a){this.sizetip.html(a).appendTo(this.container);var b=parseInt(this.sizetip.css("padding-left"),10),c=parseInt(this.sizetip.css("padding-right"),10);this.padding=b+c+1,this.width=this.sizetip.width()+1,this.height=this.sizetip.height(),this.sizetip.remove()},setContent:function(a){return a?(this.getSize(a),this.tooltip.html(a).css({width:this.width,height:this.height,visibility:"visible"}),void(this.hidden&&(this.hidden=!1,this.updatePosition()))):(this.tooltip.css("visibility","hidden"),void(this.hidden=!0))},updatePosition:function(a,b){if(a===c){if(this.mousex===c)return;a=this.mousex-this.offsetLeft,b=this.mousey-this.offsetTop}else this.mousex=a-=this.offsetLeft,this.mousey=b-=this.offsetTop;this.height&&this.width&&!this.hidden&&(b-=this.height+this.tooltipOffsetY,b<this.scrollTop&&(b=this.scrollTop),this.displayOnLeft?a-=this.tooltipOffsetX+this.width+this.padding:a+=this.tooltipOffsetX,a<this.scrollLeft?a=this.scrollLeft:a+this.width>this.scrollRight&&(a=this.scrollRight-this.width),this.tooltip.css({left:a,top:b}))},remove:function(){this.tooltip.remove(),this.sizetip.remove(),this.sizetip=this.tooltip=c,d(window).unbind("resize.jqs scroll.jqs")}}),H=function(){q(G)},d(H),M=[],d.fn.sparkline=function(b,e){return this.each(function(){var f,g,h=new d.fn.sparkline.options(this,e),i=d(this);if(f=function(){var e,f,g,j,k,l,m;return"html"===b||b===c?(m=this.getAttribute(h.get("tagValuesAttribute")),m!==c&&null!==m||(m=i.html()),e=m.replace(/(^\s*<!--)|(-->\s*$)|\s+/g,"").split(",")):e=b,f="auto"===h.get("width")?e.length*h.get("defaultPixelsPerValue"):h.get("width"),"auto"===h.get("height")?h.get("composite")&&d.data(this,"_jqs_vcanvas")||(j=a.createElement("span"),j.innerHTML="a",i.html(j),g=d(j).innerHeight()||d(j).height(),d(j).remove(),j=null):g=h.get("height"),h.get("disableInteraction")?k=!1:(k=d.data(this,"_jqs_mhandler"),k?h.get("composite")||k.reset():(k=new u(this,h),d.data(this,"_jqs_mhandler",k))),h.get("composite")&&!d.data(this,"_jqs_vcanvas")?void(d.data(this,"_jqs_errnotify")||(alert("Attempted to attach a composite sparkline to an element with no existing sparkline"),d.data(this,"_jqs_errnotify",!0))):(l=new(d.fn.sparkline[h.get("type")])(this,e,h,f,g),l.render(),void(k&&k.registerSparkline(l)))},d(this).html()&&!h.get("disableHiddenCheck")&&d(this).is(":hidden")||!d(this).parents("body").length){if(!h.get("composite")&&d.data(this,"_jqs_pending"))for(g=M.length;g;g--)M[g-1][0]==this&&M.splice(g-1,1);M.push([this,f]),d.data(this,"_jqs_pending",!0)}else f.call(this)})},d.fn.sparkline.defaults=e(),d.sparkline_display_visible=function(){var a,b,c,e=[];for(b=0,c=M.length;b<c;b++)a=M[b][0],d(a).is(":visible")&&!d(a).parents().is(":hidden")?(M[b][1].call(a),d.data(M[b][0],"_jqs_pending",!1),e.push(b)):d(a).closest("html").length||d.data(a,"_jqs_pending")||(d.data(M[b][0],"_jqs_pending",!1),e.push(b));for(b=e.length;b;b--)M.splice(e[b-1],1)},d.fn.sparkline.options=f({init:function(a,b){var c,e,f,g;this.userOptions=b=b||{},this.tag=a,this.tagValCache={},e=d.fn.sparkline.defaults,f=e.common,this.tagOptionsPrefix=b.enableTagOptions&&(b.tagOptionsPrefix||f.tagOptionsPrefix),g=this.getTagSetting("type"),c=g===N?e[b.type||f.type]:e[g],this.mergedOptions=d.extend({},f,c,b)},getTagSetting:function(a){var b,d,e,f,g=this.tagOptionsPrefix;if(g===!1||g===c)return N;if(this.tagValCache.hasOwnProperty(a))b=this.tagValCache.key;else{if(b=this.tag.getAttribute(g+a),b===c||null===b)b=N;else if("["===b.substr(0,1))for(b=b.substr(1,b.length-2).split(","),d=b.length;d--;)b[d]=k(b[d].replace(/(^\s*)|(\s*$)/g,""));else if("{"===b.substr(0,1))for(e=b.substr(1,b.length-2).split(","),b={},d=e.length;d--;)f=e[d].split(":",2),b[f[0].replace(/(^\s*)|(\s*$)/g,"")]=k(f[1].replace(/(^\s*)|(\s*$)/g,""));else b=k(b);this.tagValCache.key=b}return b},get:function(a,b){var d,e=this.getTagSetting(a);return e!==N?e:(d=this.mergedOptions[a])===c?b:d}}),d.fn.sparkline._base=f({disabled:!1,init:function(a,b,e,f,g){this.el=a,this.$el=d(a),this.values=b,this.options=e,this.width=f,this.height=g,this.currentRegion=c},initTarget:function(){var a=!this.options.get("disableInteraction");(this.target=this.$el.simpledraw(this.width,this.height,this.options.get("composite"),a))?(this.canvasWidth=this.target.pixelWidth,this.canvasHeight=this.target.pixelHeight):this.disabled=!0},initColorMap:function(){var a=this.options.get("colorMap");d.isFunction(a)?this.colorMapFunction=a:d.isArray(a)?this.colorMapFunction=function(b,c,d,e){if(d<a.length)return a[d]}:a&&(a.get===c&&(a=new t(a)),this.colorMapFunction=function(b,c,d,e){return a.get(e)})},render:function(){return!this.disabled||(this.el.innerHTML="",!1)},getRegion:function(a,b){},setRegionHighlight:function(a,b,e){var f,g=this.currentRegion,h=!this.options.get("disableHighlight"),i=d("canvas",this.el).width()+parseInt(d("canvas",this.el).css("padding-left"))+parseInt(d("canvas",this.el).css("padding-right"));return b>i||e>this.canvasHeight||b<0||e<0?null:(f=this.getRegion(a,b,e),g!==f&&(g!==c&&h&&this.removeHighlight(),this.currentRegion=f,f!==c&&h&&this.renderHighlight(),!0))},clearRegionHighlight:function(){return this.currentRegion!==c&&(this.removeHighlight(),this.currentRegion=c,!0)},renderHighlight:function(){this.changeHighlight(!0)},removeHighlight:function(){this.changeHighlight(!1)},changeHighlight:function(a){},getCurrentRegionTooltip:function(){var a,b,e,f,h,i,j,k,l,m,n,o,p,q,r,s,t=this.options,u="",v=[];if(this.currentRegion===c)return"";if(a=this.getCurrentRegionFields(),n=t.get("tooltipFormatter"))return n(this,t,a);if(t.get("tooltipChartTitle")&&(u+='<div class="jqs jqstitle">'+t.get("tooltipChartTitle")+"</div>\n"),b=this.options.get("tooltipFormat"),!b)return"";if(d.isArray(b)||(b=[b]),d.isArray(a)||(a=[a]),j=this.options.get("tooltipFormatFieldlist"),k=this.options.get("tooltipFormatFieldlistKey"),j&&k){for(l=[],i=a.length;i--;)m=a[i][k],(q=d.inArray(m,j))!=-1&&(l[q]=a[i]);a=l}for(e=b.length,p=a.length,i=0;i<e;i++)for(o=b[i],"string"==typeof o&&(o=new g(o)),f=o.fclass||"jqsfield",q=0;q<p;q++)a[q].isNull&&t.get("tooltipSkipNull")||(r="",s="",t.get("tooltipPrefixBinLabels")&&t.get("tooltipPrefixBinLabels").length>a[q].offset&&(r=t.get("tooltipPrefixBinLabels")[a[q].offset]),t.get("tooltipSuffixBinLabels")&&t.get("tooltipSuffixBinLabels").length>a[q].offset&&(s=t.get("tooltipSuffixBinLabels")[a[q].offset]),d.extend(a[q],{prefix:r+t.get("tooltipPrefix"),suffix:t.get("tooltipSuffix")+s}),h=o.render(a[q],t.get("tooltipValueLookups"),t),v.push('<div class="'+f+'">'+h+"</div>"));return v.length?u+v.join("\n"):""},getCurrentRegionFields:function(){},calcHighlightColor:function(a,c){var d,e,f,g,i=c.get("highlightColor"),j=c.get("highlightLighten");if(i)return i;if(j&&(d=/^#([0-9a-f])([0-9a-f])([0-9a-f])$/i.exec(a)||/^#([0-9a-f]{2})([0-9a-f]{2})([0-9a-f]{2})$/i.exec(a))){for(f=[],e=4===a.length?16:1,g=0;g<3;g++)f[g]=h(b.round(parseInt(d[g+1],16)*e*j),0,255);return"rgb("+f.join(",")+")"}return a}}),w={changeHighlight:function(a){var b,c=this.currentRegion,e=this.target,f=this.regionShapes[c];f>=0&&(b=this.renderRegion(c,a),d.isArray(b)||d.isArray(f)?(e.replaceWithShapes(f,b),this.regionShapes[c]=d.map(b,function(a){return a.id})):(e.replaceWithShape(f,b),this.regionShapes[c]=b.id))},render:function(){var a,b,c,e,f=this.values,g=this.target,h=this.regionShapes;if(this.cls._super.render.call(this)){for(c=f.length;c--;)if(a=this.renderRegion(c))if(d.isArray(a)){for(b=[],e=a.length;e--;)a[e].append(),b.push(a[e].id);h[c]=b}else a.append(),h[c]=a.id;else h[c]=null;g.render()}}},d.fn.sparkline.line=x=f(d.fn.sparkline._base,{type:"line",init:function(a,b,c,d,e){x._super.init.call(this,a,b,c,d,e),this.vertices=[],this.regionMap=[],this.xvalues=[],this.yvalues=[],this.yminmax=[],this.hightlightSpotId=null,this.lastShapeId=null,this.initTarget()},getRegion:function(a,b,d){var e,f=this.regionMap;for(e=f.length;e--;)if(null!==f[e]&&b*this.target.ratio>=f[e][0]&&b*this.target.ratio<=f[e][1])return f[e][2];return c},getCurrentRegionFields:function(){var a=this.currentRegion;return{isNull:null===this.yvalues[a],x:this.xvalues[a],y:this.yvalues[a],color:this.options.get("lineColor"),fillColor:this.options.get("fillColor"),offset:a}},renderHighlight:function(){var a,b,d=this.currentRegion,e=this.target,f=this.vertices[d],g=this.options,h=g.get("spotRadius"),i=g.get("highlightSpotColor"),j=g.get("highlightLineColor");f&&(h&&i&&(a=e.drawCircle(f[0],f[1],h,c,i),this.highlightSpotId=a.id,e.insertAfterShape(this.lastShapeId,a)),j&&(b=e.drawLine(f[0],this.canvasTop,f[0],this.canvasTop+this.canvasHeight,j),this.highlightLineId=b.id,e.insertAfterShape(this.lastShapeId,b)))},removeHighlight:function(){var a=this.target;this.highlightSpotId&&(a.removeShapeId(this.highlightSpotId),this.highlightSpotId=null),this.highlightLineId&&(a.removeShapeId(this.highlightLineId),this.highlightLineId=null)},scanValues:function(){var a,c,d,e,f,g=this.values,h=g.length,i=this.xvalues,j=this.yvalues,k=this.yminmax;for(a=0;a<h;a++)c=g[a],d="string"==typeof g[a],e="object"==typeof g[a]&&g[a]instanceof Array,f=d&&g[a].split(":"),d&&2===f.length?(i.push(Number(f[0])),j.push(Number(f[1])),k.push(Number(f[1]))):e?(i.push(c[0]),j.push(c[1]),k.push(c[1])):(i.push(a),null===g[a]||"null"===g[a]?j.push(null):(j.push(Number(c)),k.push(Number(c))));this.options.get("xvalues")&&(i=this.options.get("xvalues")),this.maxy=this.maxyorg=b.max.apply(b,k),this.miny=this.minyorg=b.min.apply(b,k),this.maxx=b.max.apply(b,i),this.minx=b.min.apply(b,i),this.xvalues=i,this.yvalues=j,this.yminmax=k},processRangeOptions:function(){var a=this.options,b=a.get("normalRangeMin"),d=a.get("normalRangeMax");b!==c&&(b<this.miny&&(this.miny=b),d>this.maxy&&(this.maxy=d)),a.get("chartRangeMin")!==c&&(a.get("chartRangeClip")||a.get("chartRangeMin")<this.miny)&&(this.miny=a.get("chartRangeMin")),a.get("chartRangeMax")!==c&&(a.get("chartRangeClip")||a.get("chartRangeMax")>this.maxy)&&(this.maxy=a.get("chartRangeMax")),a.get("chartRangeMinX")!==c&&(a.get("chartRangeClipX")||a.get("chartRangeMinX")<this.minx)&&(this.minx=a.get("chartRangeMinX")),a.get("chartRangeMaxX")!==c&&(a.get("chartRangeClipX")||a.get("chartRangeMaxX")>this.maxx)&&(this.maxx=a.get("chartRangeMaxX"))},drawNormalRange:function(a,d,e,f,g){var h=this.options.get("normalRangeMin"),i=this.options.get("normalRangeMax"),j=d+b.round(e-e*((i-this.miny)/g)),k=b.round(e*(i-h)/g);this.target.drawRect(a,j,f,k,c,this.options.get("normalRangeColor")).append()},render:function(){var a,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,u,v,w,y,z,A,B,C,D,E=this.options,F=this.target,G=this.canvasWidth,H=this.canvasHeight,I=this.vertices,J=E.get("spotRadius"),K=this.regionMap;if(x._super.render.call(this)&&(this.scanValues(),this.processRangeOptions(),B=this.xvalues,C=this.yvalues,this.yminmax.length&&!(this.yvalues.length<2))){for(g=h=0,a=this.maxx-this.minx===0?1:this.maxx-this.minx,e=this.maxy-this.miny===0?1:this.maxy-this.miny,f=this.yvalues.length-1,J&&(G<4*J||H<4*J)&&(J=0),J&&(z=E.get("highlightSpotColor")&&!E.get("disableInteraction"),(z||E.get("minSpotColor")||E.get("spotColor")&&C[f]===this.miny)&&(H-=b.ceil(J)),(z||E.get("maxSpotColor")||E.get("spotColor")&&C[f]===this.maxy)&&(H-=b.ceil(J),g+=b.ceil(J)),(z||(E.get("minSpotColor")||E.get("maxSpotColor"))&&(C[0]===this.miny||C[0]===this.maxy))&&(h+=b.ceil(J),G-=b.ceil(J)),(z||E.get("spotColor")||E.get("minSpotColor")||E.get("maxSpotColor")&&(C[f]===this.miny||C[f]===this.maxy))&&(G-=b.ceil(J))),H--,E.get("normalRangeMin")===c||E.get("drawNormalOnTop")||this.drawNormalRange(h,g,H,G,e),j=[],k=[j],q=r=null,s=C.length,D=0;D<s;D++)l=B[D],n=B[D+1],m=C[D],o=h+b.round((l-this.minx)*(G/a)),p=D<s-1?h+b.round((n-this.minx)*(G/a)):G,r=o+(p-o)/2,K[D]=[q||0,r,D],q=r,null===m?D&&(null!==C[D-1]&&(j=[],k.push(j)),I.push(null)):(m<this.miny&&(m=this.miny),m>this.maxy&&(m=this.maxy),j.length||j.push([o,g+H]),i=[o,g+b.round(H-H*((m-this.miny)/e))],j.push(i),I.push(i));for(u=[],v=[],w=k.length,D=0;D<w;D++)j=k[D],j.length&&(E.get("fillColor")&&(j.push([j[j.length-1][0],g+H]),v.push(j.slice(0)),j.pop()),j.length>2&&(j[0]=[j[0][0],j[1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment